Tools and features index
Map problem to circuits
AQC-Tensor
A Qiskit addon for building time evolution circuits
AQC-Tensor is a Qiskit addon that uses tensor network methods to compile the initial portion of a circuit into a nearly equivalent approximation, with many fewer layers. In addition to simulating the time evolution of a quantum system, this addon can also be useful in these cases:
-
A circuit for which tensor-network simulation achieves a great intermediate state
-
A good circuit that prepares an approximation to the target state, but with fewer layers when compiled to the target hardware device
Relevant resources
Qiskit circuit library
The standard library of gates and circuit instructions in the Qiskit SDK
Start with the Qiskit circuit library when beginning the process of constructing circuits and workloads. Available features range from standard single- and multi-qubit gates to pre-built ansatze, and also include custom unitary gates.
Relevant resources
- Circuit library overview
- Circuit library API reference
- Fractional gates
- Synthesize custom unitary operators
Optimization mapper
A Qiskit addon for mapping optimization problems to circuits and operators
Optimization mapper is a Qiskit addon that contains the functionality to model optimization problems. For example, you can use it to create models of binary optimization problems to solve with Qiskit.
Relevant resources
Quantum optimization best practices
A collection of guidelines to run quantum optimization workloads
To get started building quantum workloads to solve optimization problems, refer to the following community repository, which containing guidelines, best practices, and reference implementations for running quantum optimization algorithms. Also listed is a reference QAOA training pipeline.
Relevant links:
Device benchmarking
Qiskit device benchmarking is a respository for code to run various device-level benchmarks through Qiskit. It is not intended to define a benchmark standard, but instead provides code examples to replicate benchmarking metrics that have been reported in literature or elsewhere.
Relevant links:
Prepare and optimize workloads
Transpiler
Translate circuit instructions to execute on quantum hardware, with options for efficient layout and routing
Once your circuits have been created, they then need to be transpiled against the QPU that will execute your workload. The Qiskit SDK has robust tooling for building custom transpilation pipelines that allow you to carefully tune which transformation and analysis passes are executed (and in which sequence). Note that the simplest way to get started is to use the pre-built pass managers.
Relevant resources
- Introduction to transpilation
- Write custom transpilation passes
- Utilize transpiler plugins
- Configure the preset pass managers
- Tutorial on qubit selection
Dynamic circuits
Perform certain tasks, such as long-range entanglement and state preparation, at constant depth
Dynamic circuits are powerful tools for measuring qubits in the middle of a quantum circuit execution - and based on the outcome of those mid-circuit measurements, you can then perform classical logic operations within the circuit. Some common uses cases include efficient quantum state preparation, long-range entanglement, and sampling of instantaneous quantum polynomial-like circuits.
Relevant resources
- Classical feed-forward and control flow (This is the primary way to integrate dynamic circuits into your workloads)
- Tutorial on using dynamic circuits to generate long-range entanglement
Dynamical decoupling
Reduce decoherence errors on idle qubits
Dynamical decoupling (DD) is a technique for suppressing errors due to qubit decoherence. It is primarily useful in regions within a quantum circuit in which one or more qubits site idle while other instructions are being executed. Both Sampler and Estimator primitives have built-in support for applying DD. Alternatively, you can use the PadDynamicalDecoupling transpiler pass in Qiskit, or build your own using the new stretch instruction.
Relevant resources
- Overview of DD
- Introduction to primitive options
- Create a pass manager for dynamical decoupling
- Deferred timing resolution using stretch (Especially useful for applying DD in a dynamic circuit)
Operator backpropagation
Reduce circuit depth by trimming operations at the cost of increased measurements
This Qiskit addon utilizes a technique to reduce circuit depth by trimming operations from its end at the cost of more operator measurements. However, this increased cost can be lessened by dropping operators with small coefficients, which don't contribute much to the final estimation. You could experiment with coupling this alongside the AQC-Tensor addon for even lower circuit depths.
Relevant resources
Debug
Noisy estimator analyzer tool
Gauge the expected performance of quantum workloads
The noisy estimator analyzer tool (NEAT) analyzes and predicts the performance of your queries when you are gauging the expected performance of estimator-based workloads. It uses Qiskit Aer to simulate the estimation task classically and efficiently, either exactly or in the presence of noise, and can also convert your Primitive Unified Blocs (PUBs) into Cliffordized circuits.
Relevant resources
Local testing mode
Simulate smaller or Cliffordized circuits to assess performance
Qiskit Runtime can test workloads while fine-tuning them before submitting them to a QPU. To use this feature, simply specify one of the fake backends from qiskit_ibm_runtime.fake_provider or use one from the Qiskit Aer library. To utilize this feature, we suggest either Cliffordizing your circuit, or scale down the number of qubits in your workload.
Relevant resources
Execute on hardware
Estimator and Sampler primitives
Handles hardware execution and returns samples or expectation values, with some built-in error suppression/mitigation support
The Estimator and Sampler primitives are used to execute your circuits on QPUs. Estimator computes expectation values of observables with respect to states prepared by quantum circuits, and Sampler samples the output register from quantum circuit execution. Both primitives have built-in error suppression support, and Estimator also has built-in error mitigation methods.
Relevant resources
- Primitive inputs and outputs
- Introduction to the primitive options
- Primitives examples
- Tutorial on combining error mitigation options with Estimator
Execution modes
Efficiently schedule workload execution
Explore the different execution modes - scheduling strategies for execution - when building quantum workloads, to determine which one is most efficient for a specific workload.
Relevant resources
Executor primitive
Generate and execute circuit variants based on the input samplex directive
Executor allows you to fine-tune error mitigation and other techniques without sacrificing performance, by providing the ingredients to capture design intents on the client-side, and shifting the costly generation of circuit variants to the server-side. With Executor, users will gain a clearer and more composable model for execution workflows, making it easier to experiment with new techniques, reproduce results, and share methods.
Relevant docs links:
Manage noise
Samplomatic
Fine-tune error mitigation in specific circuit regions
Samplomatic is a library for sampling randomizations of your quantum circuits in exactly the way that you specify. It utilizes the Qiskit SDK's Box annotations to specify regions of a circuit that should have similar noise profiles; it can also can group collections of gates to twirl, or use the same noise model from NoiseLearner.
Relevant resources
NoiseLearner
Learn and return the sparse Pauli-Lindblad noise model, which can be used for error mitigation methods like PEA, PEC, and PNA
Many error mitigation techniques, such as PEA and PEC, require an accurate noise model. NoiseLearner is a helper program that returns a Pauli-Lindblad noise model for the input circuit. You can then further tune how PEA and PEC are done in your Estimator job, or re-use the same model in an iterative workload.
Relevant resources
- Overview of noise learning helper
- API reference for
NoiseLearnerandNoiseLearnerOptions - Directed execution model (beta)
Pauli twirling
Convert coherent noise to better characterized stochastic noise
Pauli twirling, also known as randomized compiling, is an error suppression technique used to convert the effects of unknown types of noise into one that can be characterized (and thus mitigated).
Relevant resources
- Explanation and usage of Pauli twirling in primitive options
- Example of a Pauli twirling annotation in a circuit created in Samplomatic
- Error mitigation compatibility in primitive options
Matrix-free measurement mitigation
Reduce measurement errors
The Matrix-free measurement mitigation (M3) Qiskit addon is used to reduce measurement error by finding corrected measurement probabilities. Use it for problems that benefit from workloads that estimate the expectation value of observables. M3 also works in the context of dynamic circuits.
Relevant resources
- M3 addon documentation
- Guide on the basic usage of M3
- Tutorial on using M3 with mid-circuit measurement
- Readout error mitigation for the Sampler primitive using M3
Probabilistic error cancellation (PEC)
Mitigate errors by statistically canceling noise, resulting in an unbiased expectation value at the expense of greater overhead
This error mitigation technique returns an unbiased estimate of the expectation value, at the expense of greater overhead than other techniques such as ZNE. It reproduces the output of the ideal circuit by executing different noisy circuit instances drawn from a random ensemble defined by the linear combination. The Qiskit Runtime Estimator primitive has built-in support for PEC, which you can enable through the Estimator option.
Relevant resources
Zero-noise extrapolation (ZNE)
Mitigate errors by amplifying noise and extrapolating corrected expectation values
This error mitigation technique first computes the expectation value at different noise levels, then estimates the ideal result by extrapolating the noisy expectation value results to the zero-noise limit. Since this can be done in multiple ways, a number of noise amplification and extrapolation techniques are available.
Relevant resources
- Qiskit Runtime primitive options for ZNE
- Introduction to ZNE
- Error mitigation feature compatibility
- ArXiv white paper on best practices for digital ZNE
Gate folding-based ZNE
Gate folding is a noise amplification process that replaces two-qubit gates with equivalent sequences of two-qubit gates and their inverses. This approach is straightforward and simple to use, but can be imperfect.
Relevant resources
Probabilistic error amplification
Probabilistic error amplification (PEA) is a more sophisticated means of amplifying errors for ZNE. It involves running preliminary experiments to learn a twirled noise model of the circuit, and then uses this model to perform a more accurate error amplification.
Relevant resources
Twirled readout error extinction (TREX)
Use twirling to reduce measurement error
This error mitigation technique is used to mitigate the effects of measurement errors by using twirled measurements. It can be used alongside many other techniques that mitigate gate errors, such as ZNE and PEC.
Relevant resources
- Explanation of TREX
- Error mitigation feature compatibility
- API reference for measurement noise learning options
Propagated noise absorption
Characterize and propagate the effects of noise into an observable
This Qiskit addon uses Pauli propagation to characterize Pauli noise affecting different layers of a circuit, by using a learned noise model and propagating its inverse into the target observable to measure.
Relevant resources
Shaded lightcones
Reduce the overhead of PEC error mitigation
The shaded lightcones (SLC) Qiskit addon uses Pauli propagation to reduce the number of error terms accounted for in a noise model, according to the specifics of the target observable. It is useful for reducing the sampling overhead when running PEC-based workloads.
Relevant resources
Post-process results
Sample-based quantum diagonalization
Post-process samples to refine results in simulation workloads
With the Sample-based quantum diagonalization (SQD) Qiskit addon, you can implement a post-processing technique to measure the ground state energies of a quantum system. SQD processes samples from a given circuit to project and diagonalize a target Hamiltonian in a subspace spanned by them, essentially "refining" the results obtained from a workload. Use when you want to obtain the eigenvalues and eigenvectors of quantum systems (such as chemical or lattice models).
Relevant resources
- Overview of SQD
- Getting started with SQD
- Tutorial using SQD for a chemistry Hamiltonian
- Tutorial using SQD and KQD for a lattice model
SQD for HPC: See the following documentation for an HPC-ready implementation of the SQD addon, which is written in modern C++17 standards and is designed to create a single compiled binary for use with MPI.
Multi-product formulas
Refine expectation values in workloads simulating time evolution
The Multi-product formulas (MPF) Qiskit addon is used to post-process workloads that simulate the time evolution of a quantum system. The MPF tool will ingest data such as the number of Trotter steps to prepare and solve an associated system of linear equations, which can then be used to refine the expectation-value measurements of a time-evolved state.
Relevant resources
Measurement post-selection
Refine samples by post-selecting known "bad" bitstrings
The noise models produced by NoiseLearner might not be accurate for Heron backends due to non-Markovian noise on these devices. An internal study has shown this can be alleviated with measurement-based post-selection. This technique adds a series of RX gates followed by a measurement to the circuit, and in post-processing throws away the "bad" bitstrings. The Qiskit addon utilities package contains functionalities to implement this technique, and NoiseLearnerV3 also has built-in support.
Relevant resources
- API reference for post-selection utilities
- API reference for post-selection transpiler passes
- API reference for
NoiseLearnerV3
Qiskit Functions
Algorithmiq Tensor-Network Error Mitigation Function
Algorithmiq's Tensor-network Error Mitigation (TEM) method is a hybrid quantum-classical algorithm designed for automating and performing noise mitigation. It accomplishes this by constructing a tensor network representing an approximate inverse of the noise affecting a circuit to obtain unbiased estimates of an observable. TEM is a novel error mitigation method based on post-processing with tensor networks, and it provides unbiased error mitigation with the lowest possible shot overhead on the quantum hardware, minimizing the runtime and hence the costs of experiments. It requires exponentially less shots than probabilistic error cancellation (PEC) and significantly less shots than zero noise extrapolation (ZNE).
Relevant resources
Q-CTRL Performance Management Function
This Qiskit Function uses AI-powered error suppression and mitigation techniques, and is agnostic to the type of workload being executed.
Relevant docs links:
- Overview of Q-CTRL Performance Management
- Tutorial using Performance Management for TFIM
- Tutorial using Performance Management for QPE
QEDMA Qiskit Function QESEM
The QESEM Qiskit Functioon by QEDMA uses a suite of proprietary error mitigation techniques to improve the results of your workload. These techniques include gate optimization, noise-aware transpilation, error suppression, and unbiased error mitigation.
Relevant resources
Iskay Quantum Optimizer
This Qiskit Function by Kipu Quantum solves unconstrained binary optimization problems with the QUBO (Quadratic Unconstrained Binary Optimization) formulation and higher-order (HUBO) optimization problems.
Relevant resources
- Overview of Iskay Quantum Function
- Solve the Market Split problem with Kipu Quantum's Iskay Quantum Optimizer
Q-CTRL Optimization Solver
This Qiskit Function by Q-CTRL is designed to solve utility-scale optimization problems. It takes in a high-level problem definition, and executes an entire workflow to optimize the problem, without manual configuration.
Relevant resources