How does software even work in quantum computers, and how do you create ‘quantum algorithms’? Those were my opening questions for Nir Minerbicco-founder and CEO of Classican Israeli software company that offers a software development platform for quantum computing.
“Quantum software manipulates the quantum state vector in a way that solves your problem,” replied Minerbi. This is done by multiplying it by a unitary matrix– which, in layman’s terms, means using a lot of math and logic. As a result, quantum software development currently involves programming the physical states on a quantum computer. The company describes it as “a bit like electronic design and a bit like assembly language.”
As you can probably guess by now, writing quantum software is incredibly difficult. As Minerbi put it, in reference to writing a unity matrix, “it’s really hard to think this way, isn’t it?” The second problem developers will have with quantum computing is the sheer size of the computations. “On a 300-qubit machine,” Minerbi explained, “the size of this unitary matrix is 2 to the 300 power, which is greater than the number of atoms in the universe.” That means dividing problems into smaller workloads (1 or 2-qubit operations).
Going a layer above quantum circuits
This is where “quantum circuits” come in. According to Wikipedia“a quantum circuit is a model for quantum computation, similar to classical circuits, where a computation is a series of quantum gates, measurements, initializations of qubits to known values, and possibly other actions.”
“So today,” Minerbi said, “this is basically the level of abstraction in the quantum software stack. You have to design these circuits, which are the software at the gate level.”
To create a quantum circuit, Classiq outlined in a presentation shown to me, “one indicates which ‘qubits’ (wires) are connected to which ‘gates’ (square blocks). This is done in quantum assembly language.”
The circuits are then executed on a quantum computer, which is a physical process. “Eventually, each of these gate-level operations will be compiled into a physical operation — microwave or laser — that will actually be applied to the physical qubits,” Minerbi explained.
What Classiq has done is add a layer of abstraction to the current state of quantum computing – which, as noted, is at the gateway and machine level. “The methods and tools developed in the classical stack over the past 60 years we will bring to the quantum stack,” Minerbi said.
To achieve this layer of abstraction, Classiq has created a high-level functional model that can be translated into quantum assembly language. So as a user you model the circuit design (via Python or VSCode) and then the Classiq platform converts that into actual circuit code. Then run this code on one of the leading quantum computer processing services, such as Qiskit or Amazon Braket.
As stated on Classiq’s platform description page, developers are encouraged to “combine built-in quantum modules with user-defined ones” and then “set constraints such as number of gates, circuit depth, and levels of entanglement.” After all this is done, Classiq will produce a quantum circuit that can be used on Qiskit, Braket or any other platform.
But is there a reason why developers shouldn’t just use Qiskit or Braket directly, I asked Minerbi?
“What Qiskit basically lets you do, which is very important, is to design gate-level circuits in an easy way,” he replied. “But it’s still gate level, because you need to know which gates to place where and which building blocks to use. And we’re on top of that – we’re in the functionality layer of high-level modeling, and our synthesis engine generates the quantum circuit in Qiskit, or in some other language.”
How Python Developers Can Get Started With Quantum Computing
To create the logic for a circuit — what Classiq calls a high-level model — developers can use the company’s VSCode extension (which has drag-and-drop functionality) or a Python SDK.
I asked Minerbi how hard is it for a web developer familiar with Python to start building quantum computer software on Classiq?
“So we actually have two types of users,” he replied. “The first kind is a quantum expert. These people […] are very familiar with quantum algorithms and use the platform to achieve state-of-the-art results that they could not achieve with Qiskit and other platforms. And the second [kind of user] are Python developers or Machine Learning developers and so on who are using Classiq to enter quantum computing.”
Usually, the Python and ML developers start with a few use cases that are good for newcomers to quantum computing. An example is: Grover’s algorithm, which is often used to speed up unstructured searches. It’s a good one to start with, Minerbi said, “because it’s about embedding classical logic into a quantum circuit.”
While Python and ML developers don’t necessarily need to understand quantum information theory to understand an algorithm like Grover’s, it helps if they have a background in algebra, Minerbi added.
Because quantum computing is still very new – especially in the field of software development – there are currently more physicists than computer scientists in the industry. However, this is changing and more and more computer scientists are entering the field.
“For example, in our company there are about 45 people,” Minerbi said. “Some of them are PhDs and postdocs in quantum information, others are computer scientists with no background in physics — and the combination is powerful.”
The classical computer industry has added layers of abstraction over the years, with each new layer making it easier to develop software. It went from assembler to higher-level languages (like Python), but we’ve seen this happen in the web world too – in the early to mid-1990s you had to code a web page in “raw” HTML, but now you can you can do it in any number of drag and drop design tools. So it’s gratifying to see this same level of abstraction being added to quantum computers.
However, it is clear that we are still in the early days of defining the quantum software stack. Classiq has some competition. A company called Horizon Quantum Computing is “developing a complete compiler stack” for quantum software, and the major service providers such as IBM and Amazon offer their own SDKs. But Classiq’s solution appears to be one of the most compelling layers of abstraction to date.