Introducing Our Quantum Circuit Optimisation Framework
Open Source

Introducing Our Quantum Circuit Optimisation Framework

Eleanor Chen, Chief Technology OfficerOctober 22, 20259 min read

Today, we're excited to announce the release of our Quantum Circuit Optimisation Framework (QCOF), an open-source tool designed to help researchers and developers get the most out of near-term quantum devices. In this post, I'll explain the motivation behind QCOF, describe its key features, and share some benchmark results that demonstrate its effectiveness.

The Challenge of Near-Term Quantum Computing

Current quantum computers—often called Noisy Intermediate-Scale Quantum (NISQ) devices—have significant limitations. Gate errors, limited connectivity, and short coherence times mean that the circuits we design on paper often perform poorly on real hardware.

Circuit optimisation is essential for practical quantum computing. By reducing circuit depth, minimising the number of two-qubit gates, and adapting circuits to hardware topology, we can dramatically improve the success rate of quantum algorithms.

Key Features of QCOF

Topology-Aware Compilation

QCOF understands the connectivity constraints of different quantum processors. Rather than applying generic optimisations, it tailors its approach to specific hardware:

  • **IBM Quantum devices**: Optimised for heavy-hex topology
  • **Google Sycamore**: Adapted for grid connectivity
  • **IonQ**: Leveraging all-to-all connectivity where beneficial
  • Multi-Stage Optimisation Pipeline

    QCOF applies optimisations in a carefully ordered pipeline:

  • **High-level Synthesis**: Decomposing abstract operations into native gates
  • **Gate Cancellation**: Identifying and removing redundant gate sequences
  • **Routing**: Inserting SWAP gates to respect connectivity constraints
  • **Scheduling**: Parallelising gates to minimise circuit depth
  • Parameterised Circuit Support

    Many quantum algorithms, particularly variational algorithms, use parameterised circuits. QCOF handles these efficiently:

  • Parameters are tracked through the optimisation pipeline
  • Gradient computation is supported for variational optimisation
  • Parameter binding happens at the last possible moment for maximum flexibility
  • Benchmark Results

    We evaluated QCOF on a standard benchmark suite of quantum circuits. Key results:

    Circuit TypeDepth ReductionGate Count ReductionQFT (16 qubits)42%38%QAOA (20 qubits)35%29%VQE Ansatz28%24%

    On real hardware (IBM Quantum), these optimisations translated to significant improvements in output fidelity, with some circuits showing 2-3x improvement in success probability.

    Getting Started

    QCOF is available now on GitHub under the Apache 2.0 licence. To get started:

    pip install qcof

    Basic usage:

    from qcof import optimise_circuit

    from qcof.backends import IBMQuantum

    # Load your circuit

    circuit = load_circuit("my_circuit.qasm")

    # Optimise for specific hardware

    backend = IBMQuantum("ibm_lagos")

    optimised = optimise_circuit(circuit, backend)

    # View optimisation statistics

    print(optimised.stats)

    We welcome contributions from the quantum computing community. Whether it's bug reports, feature requests, or code contributions, we'd love to hear from you.

    Eleanor Chen, Chief Technology Officer

    EC

    Eleanor Chen

    Chief Technology Officer