Noisy Sci-Fi Freezers: Spinning Qubits in 2019

Nick Doiron
5 min readJan 7, 2019

Over the past year, as quantum computers with more than a dozen physical qubits started appearing in more research labs and startups, the term “NISQ” (Noisy Intermediate-Scale Quantum) emerged, too. We don’t yet have enough qubits to decipher Bitcoin wallets, nor the reliability to trust their output, but after decades of speculation, there are programmable qubits and a cool $1.2 billion offered by the US government for further research. What will ‘the industry’ do with this, and how can a classical software engineer get started?

On a recent hours-long drive across New Mexico, I found myself explaining the current environment to my brother. I’ll narrow down the conversation to four points:

1. It’s getting crowded

First, there are many groups working in this space, to the point it’s now difficult to remember everyone. Here are diagrams (via Twitter) which attempt to sort everyone into neat categories:

Beyond that list, it’s getting fashionable for people with the know-how to set up a startup within their own industry. In Dr. Peter Wittek’s talk at AWS: Reinvent, he says there have been ‘20+ quantum machine learning startups’ each of the past two years, at Creative Destruction Lab.

2. Competing with an endless runway

More significant than the ‘category’ that a quantum company falls into, is its backing. Suppose that it takes ten years before spinning up a QPU is as easy as getting a TPU on a cloud server today. If you’re Google, Microsoft, IBM, Intel, Amazon, or another giant, that timeframe doesn’t affect your decision so much. If quantum computing will ever be viable, the giants want customers to trust them first. They want researchers to have written their algorithms designed to run on their chips.

If you’re a startup then you also want people to come to you first, but it is necessary to have some kind of advantage in customer responsiveness, research adeptness, interesting prizes, types of qubit hardware… something which leads investors and researchers to trust you.
I think that leads startups to be the more likely innovators in the NISQ era — a first test of quantum supremacy, practical applications of noisy qubits, and a ‘hello world’ for skeptical newbies.

Frustratingly, the startups also typically create or depend on one software platform. If you take a closer look at the quantum assembly languages that each compiles to, it’s a series of gates with similar rules. That’s why I’ve recently been working on Quantum Quail, an open source JS library which compiles a circuit for IBM’s QASM, Rigetti’s Quil, Microsoft’s Q#, and Google’s Cirq.
(D-Wave’s API has a different architecture which doesn’t support these gates.)

3. It’s still micro-scale

If the idea of writing out assembly and individual quantum logic gates throws you for a loop, be prepared for more challenges. Chips from IBM, Rigetti, and Google are known to have different topology — the simple layout of what qubits can interact with each other. Suppose that you have three qubits physically placed in a line: A, B, and C. You work on A and B, but then want an interaction between A and C. It might be necessary to run a SWAP of qubits A and B first, and that additional action comes with additional chance of errors (lest you forget the first part of NISQ technology is ‘noisy’).

IBM provides a diagram for each of their public quantum devices. Libraries such as ProjectQ can help align your circuits for pre-programmed and custom topologies.

from IBM’s website

Rigetti has publicly discussed a 100+ qubit computer to launch this year, but if you get started in their API with a 16-qubit version, it might look like this:

from Rigetti’s website

Google’s Cirq library makes an interesting choice of representing their qubits in a 2D grid — this allows for linear and 2D layouts. I clicked around a bit to see if their 72-qubit ‘Bristlecone’ processor had a public diagram somewhere, but no luck. In the meantime, we can suppose that Bristlecone is laid out as a grid (maybe 8 x 9?).

This will improve and simplify over time, as the compilers handle different topologies, as more connections get built into the chips, and more qubits become available, but it may surprise you to discover physical geometry affecting your code for the first time.

4. Developers can retool their brains for quantum

There’s still plenty of time to connect with quantum computing projects, and to apply your skills. Suppose that you’re curious about quantum chemistry: you can find an open source project (OpenFermion) which Google is part of, and the project not only has documentation, it has a 22-page release paper, a Jupyter notebook tutorial, and a list of papers using the software. Though I have minimal understanding of the material, it was still possible to find GitHub Issues related to code, e.g. resource management or consistent APIs, and contribute code!

If you prefer machine learning, there is a document Quantum Machine Learning for Data Scientists (46-page PDF warning).

On retooling: you will need to think differently. Topology, assembly language, papers talking about Hermitian operators — expect many new things. Not everything gets absorbed easily, but if you logic your way through, you can see problems as a abstract code problems. Items of {type} cannot go into {function}. Items need to be in a certain order. Translate their words into a problem you can understand and fix.

If you code in Python plus another language, you might find success in porting code. My older ‘jsQuil’ library went around Rigetti, and they reached out to me personally about speaking at a UC Berkeley meetup. Not every library needs Go, Ruby, and Rust ports, but it’s an option if you are looking for where to start.
Why am I intent on JavaScript tools, then?

  • Quantum devices exist in only a few locations. Experiments happen over the web, and JavaScript is the language of the web.
  • Scientists are partial toward Python, so most public code is Python-only. IBM released Qiskit-js in July 2017, but it doesn’t have feature parity (I recently ported a circuit diagram function).
  • Interactive demos, notebooks (think ObservableHQ), and visualizations (think D3) are poised to make it easier for people to go from thinking of ‘weird quantum stuff’ to ‘ok I am placing these gates and studying this combined output of many iterations’.
  • JavaScript will bring more people power into the industry — necessary to debug issues and add features

Hope this helps! See who’s hiring in quantum computing: https://quantumcomputingreport.com/jobs/

This essay does not represent views of my employer.

--

--