Technology

SWAP network Optimization for Quantum Computing

SWAP network Optimization for Quantum Computing

SWAP networks are a type of quantum circuit that can be used to swap the state of two qubits in a quantum computing system. These networks can be optimized to reduce the number of gates and increase the speed of the computation. One way to optimize a SWAP network is to use a decomposition technique, such as the Bravyi-Kitaev decomposition, which expresses the SWAP gate as a product of simpler gates. Another technique is to use a different type of gate, such as the Fredkin gate, which can also be used to implement a SWAP operation. Additionally, using quantum error correction can also help to optimize the SWAP network.

Researchers have demonstrated how a smart compiler designed specifically for superconducting quantum hardware can optimize circuits and networks while also executing less error-prone quantum algorithms such as the Quantum Approximate Optimization Algorithm (QAOA), which is critical for quantum computing.

A collaboration between Lawrence Berkeley National Laboratory’s Advanced Quantum Testbed (AQT) and Chicago-based Super.tech (acquired by ColdQuanta in May 2022) demonstrated how to optimize the execution of the ZZ SWAP network protocol, which is important in quantum computing. The team also presented a new quantum error mitigation technique that will improve the network protocol’s implementation in quantum processors. The experimental data was published in Physical Review Research, and more pathways to implement quantum algorithms using gate-based quantum computing will be added in the near future.

One of the toughest challenges in quantum computing is to perform discrete logic operations. Because our control signals are analog and continuous, they’re always imperfect. As we build more complex quantum circuits, the software infrastructure that optimally compiles gates tailored for AQT’s hardware helps us achieve higher operational fidelity.

Akel Hashim

A Smart Compiler for Superconducting Quantum Hardware

Quantum processors with two- or three-dimensional architectures have limited qubit connectivity where each qubit interacts with only a limited number of other qubits. Furthermore, each qubit’s information can only exist for so long before noise and errors cause decoherence, limiting the runtime and fidelity of quantum algorithms. Therefore, when designing and executing a quantum circuit, researchers must optimize the translation of the circuit made up of abstract (logical) gates to physical instructions based on the native hardware gates available in a given quantum processor. Efficient circuit decompositions minimize the operating time because they consider the number of gates and operations natively supported by the hardware to perform the desired logical operations.

SWAP gates – which swap information between qubits – are often introduced in quantum circuits to facilitate interactions between information in non-adjacent qubits. If a quantum device only allows gates between adjacent qubits, swaps are used to move information from one qubit to another non-adjacent qubit.

In noisy intermediate-scale quantum (NISQ) hardware, introducing swap gates can require a large experimental overhead. The swap gate must often be decomposed into native gates, such as controlled-NOT gates. Therefore, when designing quantum circuits with limited qubit connectivity, it is important to use a smart compiler that can search for, decompose, and cancel redundant quantum gates to improve the runtime of a quantum algorithm or application.

SWAP-network-Optimization-for-Quantum-Computing-1
Optimizing SWAP networks for quantum computing

The research partnership used Super.tech’s SuperstaQ software enabling scientists to finely tailor their applications and automate the compilations of circuits for AQT’s superconducting hardware, particularly for a native high-fidelity controlled-S gate, which is not available on most hardware systems. This smart compiling approach with four transmon qubits allows the SWAP networks to be decomposed more efficiently than standard decomposition methods.

Because a network of ZZ SWAP gates requires only minimal linear connectivity between qubits and no additional couplings, it provides practical benefits for the efficient execution of quantum algorithms such as the Quantum Approximate Optimization Algorithm (QAOA). QAOA approximates solutions to combinatorial optimization problems by providing a set of criteria for determining the best solution. A well-known combinatorial optimization problem that can be solved faster with QAOA using quantum circuits is the Maximum-Cut problem, which can be used to arrange hubs on a transportation grid system.

“One of the toughest challenges in quantum computing is to perform discrete logic operations. Because our control signals are analog and continuous, they’re always imperfect. As we build more complex quantum circuits, the software infrastructure that optimally compiles gates tailored for AQT’s hardware helps us achieve higher operational fidelity,” Akel Hashim, the lead AQT researcher on the experiment and a graduate student at the University of California, Berkeley.

“A distinguishing feature of quantum computing is the ability to use partial logic gates. This feature is unique in boolean logic; for example, your laptop computer cannot execute 50% of an AND gate. The ability of AQT to calibrate these partial controlled-S quantum gates allowed us to develop a broader range of novel optimizations to get the most out of the hardware “Rich Rines, formerly of Super.tech and now a software engineer at ColdQuanta, agreed.

“Collaboration remotely was a key software engineering challenge for this experiment, so we iteratively developed quantum circuit optimizations informed by the custom gates calibrated by the AQT team. We optimized from start to finish by figuring out how to serialize these pulses while keeping the hardware in mind. We also discovered how to integrate open-source quantum software packages into our compiler, ensuring that our optimizations do not reinvent the wheel “said Victory Omole, a former Super.tech employee and ColdQuanta software engineer.

As part of the experiment, the team also introduced a novel technique called Equivalent Circuit Averaging (ECA), which randomized the various parameters of the SWAP networks to generate many logically equivalent circuits. ECA randomizes the decomposition of quantum circuits, mitigating the impact of systematic coherent errors – one of the most severe errors in quantum computers and widely studied at AQT.

“I proposed a way to combine my previous experimental work in randomized compiling with Quantum Benchmark (acquired by Keysight) using Super.tech’s smart compiler to study a new way to reduce the impact of crosstalk errors,” Hashim explained. “I would not have had this idea if I had not collaborated with other researchers as part of AQT’s user program. As someone who is about to enter the workforce, networking is critical to developing a network of people I know in the field who are experts in various fields and to whom I can pitch research ideas.”

The performance accuracy of QAOA improved by up to 88% as a result of these experimental optimizations. Researchers are looking to continue to explore and refine the methods in this work and apply them to other applications.