Source-linked AI summary

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. Chong

arXiv:1911.04034v2quant-ph

TL;DR

Full-state quantum simulation is limited by the exponential growth of state amplitudes and resulting memory requirements. The paper combines lossless compression, tailored lossy compression, and adaptive error bounds during simulation, trading computation time and fidelity for memory. On Theta, this reduced the 61-qubit Grover simulation from 32 exabytes to 768 terabytes and supported a reported 2-to-16-qubit increase for general circuits.

  • Problem

    Exponential growth in the number of state amplitudes makes physical memory the limiting factor for full-state simulation of larger quantum circuits.

  • Method

    The approach compresses quantum state amplitudes at runtime using lossless and tailored lossy compression with adaptive error bounds and uncorrelated errors.

  • Results

    32 exabytes to 768 terabytes reduced the reported memory requirement for the 61-qubit Grover’s search simulation on Theta using 4,096 nodes.

  • Takeaways & Limitations

    The technique increased the reported general-circuit simulation size by 2 to 16 qubits, with compression ratios of 4.85X to 21.34X for other applications.

  • Takeaways & Limitations

    Lossy compression decreases overall simulation accuracy, so the method explicitly trades fidelity for memory space.

Abstract

from arXiv · show

Quantum circuit simulations are critical for evaluating quantum algorithms and machines. However, the number of state amplitudes required for full simulation increases exponentially with the number of qubits. In this study, we leverage data compression to reduce memory requirements, trading computation time and fidelity for memory space. Specifically, we develop a hybrid solution by combining the lossless compression and our tailored lossy compression method with adaptive error bounds at each timestep of the simulation. Our approach optimizes for compression speed and makes sure that errors due to lossy compression are uncorrelated, an important property for comparing simulation output with physical machines. Experiments show that our approach reduces the memory requirement of simulating the 61-qubit Grover's search algorithm from 32 exabytes to 768 terabytes of memory on Argonne's Theta supercomputer using 4,096 nodes. The results suggest that our techniques can increase the simulation size by 2 to 16 qubits for general quantum circuits.

1 INTRODUCTION

Full-state quantum simulation is constrained by exponentially growing memory requirements, motivating runtime compression that trades computation time and fidelity for memory space. The proposed approach combines lossless and tailored lossy compression to expand simulation scale while preserving high-fidelity, uncorrelated errors.

  • Motivation: 2^n amplitudes make physical memory the limiting factor for full-state simulation as qubit count increases.The state size is given as 2^n+4 bytes when double-precision complex numbers represent the amplitudes.
  • Approach: Runtime compression of quantum state amplitudes reduces full-state simulation memory requirements for general circuits.The approach applies lossless compression, lossy compression, and adaptive error bounds during simulation.
  • Approach: Uncorrelated lossy-compression errors are designed to avoid resembling correlated errors from physical machines and also speed compression.The paper identifies uncorrelated errors as useful when comparing simulation output with physical machines.
  • Implementation: The method trades computation time and fidelity for memory space while integrating with Intel-QS for distributed supercomputer simulation.The implementation targets intermediate-scale general quantum applications for calibration, verification, and benchmarking.

2 BACKGROUND AND RELATED WORK

Quantum states use exponentially many amplitudes, while existing circuit simulators trade space against time or exploit restricted circuit structure. The paper motivates compression methods tailored to quantum-simulation fidelity and quality requirements.

  • Quantum computation: 2^n amplitudes represent an n-qubit quantum state, with basis-state coefficients constrained by normalization.The amplitudes are complex and their squared magnitudes sum to 1.
  • Related work: Schrödinger-style simulation supports arbitrary-depth circuits but is limited by the exponential memory needed to store the full state vector.The state vector is maintained and updated at every time step.
  • Related work: Feynman-path and tensor-network methods reduce or reorganize resource use but are restricted by circuit depth or graph treewidth.Feynman paths scale exponentially with circuit depth, while tensor-network contraction costs scale exponentially with underlying graph treewidth.
  • Data compression: Error-bounded lossy compression models are categorized as data-prediction-based or domain-transform-based.The data-prediction model predicts values from neighboring data before coding, whereas the domain-transform model decorrelates values in another coefficient domain.
  • Data compression: Existing error-bounded lossy compressors are mainly designed or assessed for visualization rather than quantum-simulation fidelity and compression quality.The paper therefore characterizes existing compressors and investigates pointwise absolute and relative error controls.

3 SIMULATION DESIGN

The simulation design stores distributed state-vector blocks in compressed form and decompresses only the blocks needed for each gate operation. It targets high-fidelity scaling by trading computation time and simulation accuracy for memory space.

  • Design goals: The design applies lossy compression to state vectors so Schrödinger-style simulation can trade computation time and accuracy for memory space.Lower error bounds provide higher fidelity, while higher error bounds provide higher compression ratios and support larger qubit counts.
  • System architecture: Intel-QS integrates the compression techniques into a distributed quantum circuit simulator running on a classical computer.The simulator uses MPI for parallel execution.
  • Gate operations: Single-qubit gates apply the unitary to amplitude pairs that differ at the target bit while matching on all other bits.This avoids constructing the full unitary matrix for the gate operation.
  • Compressed execution: Each rank divides its partial state vector into blocks stored in compressed format, with at most two blocks decompressed for a gate operation.After updating the paired vectors, the blocks are recompressed before proceeding to the next pair.

3.2 MCDRAM Memory Configuration

MCDRAM provides high-bandwidth, low-capacity memory for repeatedly decompressing state vectors during simulation, improving compression, gate-operation, and decompression performance.

  • MCDRAM is high-bandwidth, low-capacity memory packaged with the Intel Xeon Phi processor.
  • Decompressed state vectors are placed in MCDRAM to accelerate repeated compression and decompression operations.
  • The simulator uses equal mode with 50% cache and 50% flat memory to allocate MCDRAM.

3.3 Integration Details

The integration stores quantum state vectors as compressed blocks, selectively decompressing and recompressing them during gate operations while determining block locations from amplitude-index segments.

  • Integration Details: The compressor is integrated as a C library into the Intel-QS build process and creates compressed state-vector blocks during initialization.
  • Integration Details: During simulation, updated blocks are decompressed to pre-allocated MCDRAM, modified, recompressed, and processed sequentially.
  • Amplitude index segments: For single-qubit gates, amplitude indices are divided into three segments to identify the corresponding blocks.
  • Amplitude index segments: When q < log2b, both amplitudes share a block; intermediate q values select different blocks on one rank, while larger q values require inter-rank exchange.
  • Amplitude index segments: Two-qubit gates modify amplitudes only when the control qubit is |1⟩, with block or rank updates determined by the control-qubit position.

3.4 Compressed Block Cache

The compressed block cache exploits repeated amplitude values by reusing previously computed compressed-block transformations, reducing repeated compression, computation, and decompression work.

  • Compressed Block Cache: Repeated amplitude values create redundancies that the compressed block cache exploits to reduce computation time.
  • Compressed Block Cache: A cache line stores the gate operation, target-qubit position, input compressed blocks, and output compressed blocks.
  • Compressed Block Cache: Each rank maintains 64 cache lines, and the cache uses least-recently-used replacement.
  • Compressed Block Cache: On a cache hit, the simulator returns the stored output blocks directly, reducing compression, computation, and decompression time.
  • Compressed Block Cache: If the cache hit rate remains zero, the simulator disables the compressed block cache to avoid cache-miss penalties.

3.5 Simulation Checkpoint

The simulation can checkpoint compressed blocks before a supercomputing job reaches its wall-time limit and resume from them in a later submission.

  • Simulation Checkpoint: A 24-hour wall-time limit on many supercomputing systems constrains circuit depth and can terminate a simulation job.
  • Simulation Checkpoint: Saving compressed blocks before termination allows the task to resume by loading them in the next job submission.

3.6 MPI Configuration

The simulation uses 128 MPI ranks per KNL node for best performance and switches from lossless to progressively lossy compression as the quantum state becomes harder to compress.

  • MPI Configuration: 128 MPI ranks per KNL node gives the best performance for the 35-qubit random circuit simulation.Each KNL node has 64 cores and 256 threads.
  • Variable Error Bound Compression: Lossless Zstd is used initially, then lossy compression is activated when compressed blocks no longer fit in memory.The transition preserves fidelity early and enables continued simulation as the state becomes more complex.
  • Variable Error Bound Compression: The pointwise relative error bound constrains each decompressed value to the interval defined by the original value and error bound δ.The method uses error levels 1E-5, 1E-4, 1E-3, 1E-2, and 1E-1, relaxing the bound when needed.

3.8 Lower Bounds on Simulation Accuracy

Simulation fidelity measures similarity between ideal and compressed outputs, and the analysis derives lower bounds by propagating per-compression error bounds across gates. Fidelity decreases as lossy compression errors accumulate.

  • Lower Bounds on Simulation Accuracy: State fidelity quantifies similarity between the ideal and simulated quantum states, ranging from 0 to 1.A fidelity of 1 means the two states are identical.
  • Lower Bounds on Simulation Accuracy: Each lossy compression can reduce fidelity because information is lost during compression.The paper uses fidelity to quantify this accuracy decrease.
  • Lower Bounds on Simulation Accuracy: The lower-bound analysis propagates the maximum error at each gate and combines the resulting fidelity decreases.For a gate with percentage error δ, the bound is reduced by a factor of (1 −δ).
  • Lower Bounds on Simulation Accuracy: When all error bounds δ_i are 0, the simulation fidelity is 1; larger error levels produce fidelity bounds that vary with gate count.The evaluated bounds are 0, 1E-5, 1E-4, 1E-3, 1E-2, and 1E-1.

4 ADAPTIVE COMPRESSION OPTIMIZED FOR QUANTUM CIRCUIT SIMULATION

The paper evaluates error-bounded compressors and develops an adaptive hybrid pipeline for quantum simulation data. Its selected method combines fast bit-plane truncation with Zstd and produces high compression, bounded low errors, and non-correlated errors.

  • 4.1 Assessment of Existing Error-Bounded Lossy Compressors: The study evaluates SZ, FPZIP, and ZFP on 36-qubit QAOA and Google random circuits.The datasets are denoted qaoa_36 and sup_36.
  • 4.1 Assessment of Existing Error-Bounded Lossy Compressors: SZ achieves one or two orders of magnitude higher compression ratios than ZFP under absolute error bounds.On qaoa_36, SZ reaches about 100:1 while ZFP remains below 10:1; on sup_36, their ranges are about 28∼126 and 4.25∼12.6, respectively.
  • 4.1 Assessment of Existing Error-Bounded Lossy Compressors: Quantum simulation data are highly spiky rather than smooth, limiting compressors that rely on smoothness or prediction accuracy.This behavior reduces ZFP’s domain-transform effectiveness and lowers SZ compression ratios in some configurations.
  • 4.2 Optimizing the Compression Strategy: The adaptive pipeline uses lossless Zstd early, when many values are zero, and switches to lossy compression as the state becomes more complex.This avoids early fidelity loss while maintaining compression as lossless ratios decline.
  • 4.2 Optimizing the Compression Strategy: Solution C combines XOR leading-zero reduction, relative-error bit-plane truncation, and Zstd to improve compression speed and memory reduction.The significant bit count is determined from the relative error exponent and sign-and-exponent representation bits.
  • 4.2 Optimizing the Compression Strategy: Solution C provides a trade-off of high compression ratio, low compression and decompression time, low errors, and non-correlated errors.The authors select it as the final error-bounded lossy compressor for their experiments.

5 EVALUATION

The evaluation tests compressed full-state simulation across multiple quantum applications and system scales. Results show substantial memory savings and larger feasible simulations, with performance depending on circuit structure and entanglement.

  • Scalability: Scaling was evaluated for Hadamard-gate simulations on one node and for a 51-qubit circuit across different node counts on Theta.Scaling is expected to be better for applications requiring more compression, decompression, and computation.
  • Experimental Setup: The benchmarks covered shallow- and deep-circuit applications selected to represent arbitrary quantum circuits, including Grover, random circuits, QAOA, and QFT.
  • Experimental Results: 61-qubit Grover simulation used 768 TB instead of 32 EB, extending the demonstrated maximum from 45 to 61 qubits on Theta.The 47-qubit Grover simulation used 24 TB instead of 2 PB.
  • Experimental Results: QFT simulations achieved more than 21X compression with fidelity 0.962 while handling high-depth circuits.
  • Discussion: The method performed better on circuits with less entanglement because greater entanglement produces less-compressible state vectors.
  • Discussion: 4.85X to 21.34X compression ratios supported simulations of other applications with 47 to 49 qubits on Theta.The reported results suggest increases of 2 to 16 qubits for general circuits.

6 CONCLUSION AND FUTURE WORK

The conclusion presents data compression as a way to reduce memory requirements in full-state quantum circuit simulation while trading computation time and fidelity for memory space. Experiments demonstrate larger simulations, and future work targets broader integration and faster compression and decompression.

  • Conclusion: Lossy compression was designed to optimize compression ratios and compression speed, while its errors were uncorrelated with the data.
  • Future Work: The method trades time and simulation fidelity for memory space and can be combined with other simulation techniques.
  • Future Work: Future work includes implementing the simulator on GPU-based supercomputing systems to reduce compression and decompression time.
  • Conclusion: Data compression reduced the memory requirement for 61-qubit Grover simulation from 32 exabytes to 768 terabytes on Theta using 4,096 nodes.
  • Conclusion: The approach increased general-circuit simulation size by 2 to 16 qubits and provided experimental results for random circuits, QAOA, and QFT.
Loading 1911.04034v2…