Firsthand Student Experience With the IBM Quantum Challenge 2024

Firsthand Student Experience With the IBM Quantum Challenge 2024

Each year, IBM hosts the IBM Quantum Challenge. People from all around the world, from high school students to seasoned industry professionals, are invited to participate in a series of quantum computing coding challenges over the span of a few short days. These challenges are presented as Python notebooks and access to the program is free of charge, with solutions being released to the public at the conclusion of the challenge. This year, the ten-day IBM challenge began on June 5th and ended on June 14th.

Of course, this label of “free” was eye-catching to an undergraduate student existing in a universe where a college education or even quality online courses come with a hefty price tag. What was more exciting, however, was the promised guidance through IBM’s recent updates to Qiskit language version 1.0, which came with significant rearrangements in how even the most simple circuits were to be run.

As a disclaimer, this blog post is reflective of only one undergraduate student in computer science’s experience and is far from comprehensive. There exist many others out there who may have had a dramatically different experience, and I respect their notes on the IBM challenge.

Remembering the IBM Challenge from 1 Year Ago

Over a year ago, as a high school student transitioning into college, I had attempted the challenge. When I first opened the “Lab 0” notebook, a series of mixed emotions came flooding back. For one, I was a novice when it came to setting up my computer environment a year ago. While the instructions provided in the lab were comprehensive, it was considerably easier to simply run the code in a Google Colab notebook or other browser-based platform. 

Consequently, when it came to the later, more difficult lab notebooks, the old me had hit wall after wall with getting the code to properly compile in the runtime with the additional files. As such, I did not make it far, and retried the challenge this year with humbled expectations.

This time around, however, the set up went much more smoothly. For one, I already had a coding environment put together on my laptop, and thus escaped the panicked confusion as I struggled to “add Python to my PATH” (what path was my computer walking on, I wondered, if it didn’t have legs?) and so on.

IBM Quantum Challenge Structure

The challenges are labeled as labs from 0 (the initial set-up) to 4 (the final challenge) and organized neatly on a central webpage that links to the lab notebook (on a Github page) and its various, translated versions. I worked my way through the challenges that were written in English, but there were languages such as Japanese and Korean, offered right alongside the one I used (although I observed some of them were not accessible until later into the challenge).

Over the course of the challenge, participants work their way through each lab notebook, which comes with plaintext descriptions of some key theories, example code, and several exercises that may be completed and checked by the IBM autograder.

The Introductory Labs: How to do Quantum Computing for Dummies

Labs 0, 1, and 2 were introductory labs. They sought to introduce the standard novice (like me on a good day) to quantum computing, with a gentle push in the direction of how to code basic circuits.

I had long been using older versions of Qiskit – namely in the 0.40 range – to code because most quantum computing tutorials and exercises were written using this or older versions, and the more recent updates were daunting. Sometime in the past year, I began to see the banner indicating I was looking at documentation that was for an “outdated version of Qiskit” pop up all over the page, and when I clicked on the link to view newer versions, the code with the same functionality I was looking for would seemingly disappear. 

As I learned from these labs, the packages did not disappear. They were instead restructured and reorganized to be more functional, but considerably less understandable to someone with limited hardware and compiling knowledge. Jargon, from “transpiling” to the seemingly never-ending list of ways to run a circuit(and seemingly infinite wrong ways to run the same circuit – why can’t my StateVectorSimulator work when I try to attach a FakeBackend?), was overwhelming, but that is necessarily true of any discipline heavily based in the realm of research.

Thankfully, the introductory challenges sought to alleviate that overwhelming feeling. I was especially grateful when the lab walked through the process of transpiling the circuit. Options for the parameters were explored in an iterative manner, and the role of each step in transpilation and optimization were explained in great detail. 

This contrasts significantly with a number of tutorials for Qiskit 1.0 online, where the tutorial walks through ways of running circuits before giving a crash course in why it works – but never truly explaining the terms used in their explanation (and creating an unending loop of confusion for beginners).

With these introductory labs, rather than finding myself always asking, “why this?”, I instead found myself wondering, “what next?” as the labs carefully introduced high-level concepts using accessible analogies, creating a not-too-steep learning curve.

Lab 3: The Quantum Willy Wonka Factory

Lab 3 was simultaneously the most exciting and the most daunting. This section was especially utility-focused and strove to discuss the overlap of quantum computing with other hot topics, such as artificial intelligence and cloud computing. 

The lab was broken down into a series of shorter sections, each of which introduced some functionality of Qiskit currently in the beta-testing phase. As such, we participants were told to expect to run into some bugs. While I did not bump into Madagascar roach-sized issues, there were a few frustrations with inputting parameters into the methods. 

The first section of the lab walked through a demonstration of AI-powered transpilation. In another, the concept of circuit “knitting” (which decomposes a circuit into smaller subproblems that may be run separately before results as knitted together) was discussed. While working on the latter, I felt like a teenager fumbling while learning how to use knitting needles. The description on the theory was sufficient (albeit in-depth, which I will discuss in a moment), but when it came to coding, the autograder was my archnemesis, as the seemingly smallest of parameters had to be absolutely correct (and some assumed defaults, I found, were not sufficient to fit the strict requirements of the grader).

As for the theory, I was intrigued. It seemed as though prior knowledge in cloud computing and error mitigation was assumed, and any confusion would invariably result in the words, “please refer to,” followed by the insertion of a link to a paper on the Internet somewhere. While wonderful, my reason for wanting to participate in these challenges was to understand what was written on these research papers in the first place, and I recognize at times the steep curve required to understand these papers would take more time than I could allot to traverse.

Nonetheless, I fully enjoyed reading about the potential fully-fledged functionality that was to come. As someone looking to delve further into quantum computing research, it was interesting to explore my options on what is considered cutting edge development in the industry and to have the opportunity to poke around using hands-on activities.

Lab 4: The Final Stretch of the Challenge

According to the README file, the final few labs were meant to “test your [my] Qiskit knowledge.” And indeed, they did test me quite a bit.

Lab 4 was the final lab in the sequence of challenges and focused on a Variational Quantum Classifier (VQC) – and as the last challenge in the set, I was worried the knowledge required would be beyond my current limits as a student.

To my surprise, the lab was anything but terrifying. The notebook built on past knowledge covered from labs 0 through 3, pulling together snippets of knowledge on how to prepare the code, set up optimization functions, and ultimately train the VQC.

I spent far too many hours putting together the optimization function, which revealed to me that my limited understanding and struggle to understand the linked papers in previous labs may have been detrimental to my completion of this one. 

I did eventually meet the criteria to pass through the first part of the lab (after much trial and error, to my own chagrin). Ultimately, however, what stopped me from completing every exercise in the notebook was one, final run-in with the quantum Estimator. In spite of countless attempts, I ran into the repeated issue, “TypeError: Object of type UnsetType is not JSON serializable.” Try as I might, I struggled to interpret the Qiskit documentation and its listed parameters to understand which input was not JSON serializable.

A few weeks later, I would learn that I was missing some parameter (one, to my knowledge, not discussed in-depth in any of the labs), and the autograder would not let participants pass this stage otherwise.

A frustrating, but humbling, end to the IBM quantum challenge.

Concluding Thoughts

All in all, I thoroughly enjoyed the IBM Quantum Challenges. I especially appreciated the gentle introductions to Qiskit 1.0, and in light of the significant changes made to the Qiskit functions, I believe I will be referencing these notebooks repeatedly for use in future projects.

While I would have hoped to see more patience when describing the more complex theory in higher level notebooks – and a less finicky autograder – these small run-ins were not significant enough to completely take away from the experience. Indeed, I found the notebooks informative and helpful – and the extensive range of topics curated refreshing. 

I recognize I, as only a student, have much left to learn when it comes to quantum computing. My struggles with the theory could be remedied with additional, targeted study, and I appreciate the direction working through these notebooks have provided as I learn about fallacies in my knowledge, which I hope to patch. I look forward to conquering next year’s IBM Quantum Challenge, one year older and (hopefully) one year wiser, and I would encourage you, too, to give the challenges a try.

IBM Quantum Challenge notebooks and solutions are released here.

Disclaimer: This blog post was not sponsored in any way. The thoughts written are representative of only my (the author’s) opinions and perspectives and do not represent the opinion of Q-munity Tech or The Quantum Insider as a whole.

Content Creator @ Q-munity

Subscribe to the newsletter

Get a weekly digest of our most important stories direct to your inbox.

No spam. Never ever.

A weekly quantum digest. Delivered to your inbox.

Every week, our team curates the most important news, events, and opportunities in the quantum space. Our subscribers gain early access to opportunities and exclusive interviews with prominent individuals. You don't want to miss out.