Full-state quantum circuit simulation by using data compression

Xin-Chuan Wu, Sheng Di, Emma Maitreyee Dasgupta, Franck Cappello, Hal Finkel, Yuri Alexeev, Frederic T. ChongSC 2019

TL;DR

This paper tackles the memory bottleneck in simulating large quantum circuits by introducing a novel hybrid data compression technique. By cleverly combining lossless and adaptive lossy compression, they significantly reduce memory requirements, enabling simulations of up to 61 qubits, a substantial leap from previous limitations. This advancement is crucial for verifying and developing quantum hardware and algorithms.

What Problem Does This Paper Address?

Simulating quantum circuits is essential for understanding quantum computation, but it faces a severe scalability challenge: the memory required grows exponentially with the number of qubits. Specifically, simulating an n-qubit system requires storing 2^n complex amplitudes. This "state explosion" limits current full-state simulators to around 47 qubits, far short of the capabilities of emerging Noisy Intermediate-Scale Quantum (NISQ) devices (e.g., 50-72 qubits). While various simulation techniques exist, they often trade off time for space or are limited to specific circuit types. This paper aims to bridge this gap by enabling full-state simulations of larger, more general quantum circuits on existing supercomputing infrastructure.

Methods

The core innovation lies in a hybrid, adaptive compression strategy. The simulation begins with a lossless compressor (Zstd) to maintain perfect fidelity. As the simulation progresses and the quantum state becomes more complex, the lossless compression ratio may decrease. At this point, the system adaptively switches to a custom-designed error-bounded lossy compressor. This lossy compressor is optimized for quantum circuit data, which is often "spiky" and not smooth, making traditional lossy compressors less effective.

The authors developed a novel lossy compression method (Solution C) that combines:

  • XOR leading-zero data reduction: Efficiently encodes repeated byte patterns.
  • Bit-plane truncation: Selectively discards less significant bits based on a user-defined relative error bound, ensuring that errors are uncorrelated.
  • Zstd lossless compression: Applied as a final step to further compress the data.

This approach allows for a trade-off: higher compression ratios (and thus larger simulations) are achieved by accepting a controlled level of error, while maintaining high fidelity for critical parts of the computation. They also leverage MCDRAM (Multichannel DRAM) on the Theta supercomputer for faster decompression and compression operations.

Datasets

The paper evaluates their approach using several quantum circuits:

  • Grover's search algorithm: Used for database search, known for its regular structure.
  • Random circuit sampling: Based on Google's quantum supremacy experiment, characterized by high entanglement.
  • Quantum Approximate Optimization Algorithm (QAOA): A promising algorithm for NISQ devices, often robust to some level of error.
  • Quantum Fourier Transform (QFT): A deep circuit fundamental to many quantum algorithms.

These circuits represent a range of characteristics, from highly structured to highly entangled, to demonstrate the versatility of their compression technique.

Key Insights and Ideas

  • Quantum data is "spiky": Unlike typical scientific data, quantum state amplitudes can exhibit sharp changes and large numbers of zeros, which traditional smooth-data-optimized lossy compressors struggle with.
  • Uncorrelated errors are key: The authors emphasize that their lossy compression introduces uncorrelated errors. This is crucial because correlated errors could fundamentally alter the simulation's outcome and make it difficult to compare with physical hardware.
  • Adaptive compression is essential: A single compression strategy doesn't fit all stages of a quantum simulation. The hybrid approach, switching from lossless to adaptive lossy compression, is vital for balancing fidelity and memory usage.
  • Memory is the primary bottleneck: The paper strongly reinforces that for simulating larger quantum systems, memory capacity, not necessarily computational speed, is the limiting factor. Their compression technique directly addresses this.

Key Results

  • Massive memory reduction: The simulation of a 61-qubit Grover's search algorithm, which would theoretically require 32 exabytes (EB), was successfully performed using only 768 terabytes (TB) on Argonne's Theta supercomputer. This represents a reduction factor of approximately 4.2 x 10^4.
  • Increased qubit count: The techniques can increase the simulation size by 2 to 16 qubits for general quantum applications, achieving an average fidelity of 0.976.
  • Improved compression ratios: Their novel lossy compressor (Solution C) achieved significantly higher compression ratios (28x to 21x for various benchmarks) compared to existing state-of-the-art compressors like SZ and ZFP, especially on quantum circuit data.
  • Practical simulation of NISQ-scale circuits: They demonstrated simulations of 42-45 qubit circuits using manageable memory footprints (48-192 TB).

Limitations and Future Work

  • Trade-off between fidelity and compression: While the approach aims for high fidelity, there is an inherent trade-off. For applications requiring near-perfect fidelity, the compression ratio might be lower, limiting the achievable qubit count.
  • Performance on highly entangled circuits: The paper notes that their technique performs better on circuits with less entanglement. For highly entangled circuits, fidelity might need to be sacrificed to meet memory constraints.
  • Future Work: The authors suggest adapting their lossy compression errors to model noise on real quantum devices, potentially building simulations that naturally incorporate noise. They also plan to implement their simulator on GPU-based supercomputing systems to further reduce compression and decompression times. Integrating their techniques with other simulation methods is also a promising direction.

Summary updated

BibTeX
@inproceedings{wu2019full,
  author = {Xin-Chuan Wu and Sheng Di and Emma Maitreyee Dasgupta and Franck Cappello and Hal Finkel and Yuri Alexeev and Frederic T. Chong},
  title = {{Full-state quantum circuit simulation by using data compression}},
  booktitle = {SC},
  year = {2019},
  doi = {10.1145/3295500.3356155},
}
Figure