quantumlib/qsim
Fast C++ and Python library for state-vector simulation of quantum circuits.
What it solves
qsim is a high-performance state-vector simulator for quantum circuits. It allows researchers and developers to simulate the evolution of quantum states over time by representing the state as a vector of complex-valued amplitudes and applying matrix-vector multiplication to simulate transformations.
How it works
As a full state-vector (Schrödinger) simulator, qsim computes all $2^n$ amplitudes of the state vector, where $n$ is the number of qubits. To achieve high performance, it employs several optimization techniques:
- Gate Fusion: Reduces the number of operations by combining multiple quantum gates into a single operation.
- Hardware Acceleration: Utilizes AVX/FMA instructions for vectorization, OpenMP for multithreading, and GPU support for faster computation.
- Precision: Uses single-precision arithmetic to speed up simulation.
Who it’s for
It is designed for users who need to simulate quantum circuits, including those using the C++ library directly or Python users via the qsimcirq interface, particularly those working with the Cirq framework for modeling Noisy Intermediate-Scale Quantum (NISQ) circuits.
Highlights
- High Performance: Highly tuned for vector arithmetic and multithreading on CPUs and GPUs.
- Cirq Integration: Includes a dedicated interface (
qsimcirq) for simulating circuits written in Cirq. - Proven Track Record: Used to produce landmark cross-entropy benchmark results published in Nature (2019).
- Flexible API: Available as both a C++ library and a Python package.
Related
- Project
- Project
- Project
- Project
- Project