Two fields are trying to get past the limits of today’s computers. Quantum computing changes what the hardware is. Neuromorphic computing changes how it works, by copying the brain. Each has a problem the other can help with, and this paper is where I first put them together: a spiking neuron that runs on a quantum computer.
Two problems
The first problem is power. GPT-3 has 175 billion parameters and took an estimated 190 000 kWh to train. A human brain has about 100 billion neurons and runs on roughly 20 W. The comparison is rough, but the gap is too wide to blame on the details. Artificial neural networks keep the brain’s wiring diagram and throw away how neurons talk to each other.
Real neurons send short pulses, called spikes. A spike is all or nothing, so what carries information is when spikes arrive and how often. Spiking neural networks keep this. A neuron that receives nothing does nothing and costs nothing, and the timing of the spikes carries information that an ordinary network averages away.
The second problem belongs to quantum computing. Quantum machine learning mostly relies on variational circuits: long chains of gates whose settings are tuned until the circuit gives the right answers. Today’s quantum processors are noisy. A qubit holds its state for a short time, and every extra gate gives the noise another chance to spoil the result. The deeper the circuit, the worse this gets.
So I asked what the smallest useful quantum neuron would look like, and whether the noise could do some of the work.
The classical neuron
The leaky integrate-and-fire neuron dates from 1907 and is still the usual choice for spiking networks, because it is cheap to compute and close enough to biology to be useful. Its name lists what it does.
- Integrate. Each incoming spike raises the neuron’s membrane potential.
- Leak. With no input, the potential decays back towards zero.
- Fire. When the potential crosses a threshold, the neuron sends a spike of its own and resets.
As electronics, this is a resistor and a capacitor side by side. Current charges the capacitor, the resistor drains it, and the voltage across them is the membrane potential.

The same neuron on one qubit
Each of the three behaviours has a natural partner on a quantum computer.
The membrane potential becomes the qubit’s excited-state population: the chance, between 0 and 1, of finding the qubit in its excited state when it is measured.
A spike becomes a rotation gate, RX(θ). It turns the qubit away from its ground state and raises the population. The angle θ sets how hard the spike hits.
The leak costs nothing. An excited qubit that is left alone relaxes to its ground state, because it is never fully cut off from its surroundings. This is T1 relaxation, and it is an exponential decay, which is the exact shape the neuron’s leak needs. When no spike arrives, the circuit waits for a time τ and the hardware supplies the leak.
Firing needs a measurement. After each time step the population is read out. If it is over the threshold, the neuron records an output spike and the qubit is reset.
Remembering without a long circuit
Measuring a qubit destroys its state, so after each readout the neuron has to be put back where it was before the next input arrives. The plain way to do that is to rebuild the whole history of gates at every step, and the circuit then grows without limit.
It does not have to. Every gate in the neuron is a rotation about the same axis, so any state the neuron can reach is one rotation away from the ground state. If the last measured population was α, a single gate with angle φ = 2 arcsin √α restores it. However long the neuron has been running, each step is the same short circuit: one gate for memory, then either a spike or a wait.

Because the neurons never entangle with each other, the cost of simulating them grows in step with their number, where a variational circuit’s cost grows much faster. The circuit is also too short for noise to build up in the way it does in a deep one.
Fed the same train of random input spikes, the classical and quantum neurons behave alike. They rise on a spike, sag between spikes, and fire and reset at the threshold.

From one neuron to a network
The quantum neuron drops into a network wherever a classical spiking neuron would go. An image is turned into spike trains, with brighter pixels spiking more often, and the spikes pass through the layers one time step at a time. At the output, the class whose neuron fires most is the answer.
One thing differs from the classical network. A classical connection has one weight to learn. Here each connection has two: the rotation angle θ, which sets how strongly a spike lands, and the delay τ, which sets how fast the neuron forgets. Both are trained together.

Training uses backpropagation through time. A spike is a step, and a step has no usable gradient, so the backward pass swaps in a smooth stand-in for it. This is the standard fix for classical spiking networks and it carries over unchanged.
What we found
Francesco Petruccione and I built two versions, a fully connected network (QSNN) and a convolutional one (QSCNN). We tested them on three image sets: handwritten digits (MNIST), clothing (Fashion-MNIST) and handwritten Japanese characters (Kuzushiji-MNIST). We ran them against classical networks, classical spiking networks, and two established quantum models: a variational classifier (QNN) and a quanvolutional network (Quanv). Every model was kept small and as alike as we could make them, and all were trained on the same machine.
| Model | MNIST | Fashion | Kuzushiji | Training time |
|---|---|---|---|---|
| ANN | 97.84 | 87.24 | 90.38 | 30 s |
| SNN | 95.84 | 81.73 | 90.02 | 2 m 26 s |
| QNN | 89.65 | 82.90 | 67.18 | 54 m 22 s |
| Noisy QNN | 86.82 | 80.68 | 59.18 | 5 h 27 m |
| QSNN | 88.25 | 75.25 | 60.36 | 2 m 14 s |
| CNN | 96.87 | 81.19 | 81.98 | 1 m 48 s |
| SCNN | 97.75 | 65.81 | 82.06 | 5 m 49 s |
| Quanv | 92.46 | 83.99 | 71.83 | 6 h 27 m |
| Noisy Quanv | 92.35 | 82.87 | 70.58 | 31 h 26 m |
| QSCNN | 90.62 | 70.19 | 66.02 | 5 m 40 s |
Accuracy is the percentage correct on 10 000 test images. The quantum models were run as simulations on a classical computer.
The result is in the last column. On digits the spiking quantum networks score within a few points of the other quantum models, and they train in minutes where the others take hours.
Simulating noise costs the other quantum models hours of training and some of their accuracy. The spiking networks hardly change, because relaxation is already part of how they work.
What it does not show
This is a proof of concept, and I would rather say where it stops than have a reader find out.
- No quantum model here beats the classical networks. On these tasks an ordinary network is still the right tool.
- On the two harder image sets the spiking quantum networks trail the other quantum models by several points. The networks were kept simple on purpose, and nothing was tuned to a dataset.
- The numbers come from simulation. The design is meant for real noisy hardware, but running it there is later work.
- Still images are a poor test of a spiking network. Its strength is data that unfolds in time.
What came next
The neuron has turned out to be a useful building block. I have since used it to classify EEG recordings of brain activity, which is data that really does unfold in time. With Donovan Slabbert I have used it as a kernel for spectral clustering. We have also gone the other way and derived a quantum neuron from the circuit equations of a memristive device, in place of building one from gates.
The code for every model in the table is on GitHub, written in Python with PyTorch.
