Source-linked AI summary
Performance comparison of optimization methods on variational quantum algorithms
Xavier Bonet-Monroig, Hao Wang, Diederick Vermetten, Bruno Senjean, Charles Moussa, Thomas Bäck, Vedran Dunjko, Thomas E. O'Brien
TL;DR
Noisy VQAs require classical optimizers whose settings are adapted to problem and sampling conditions. The paper compares four gradient-free methods, tests telescoping sampling, tunes CMA-ES and SPSA, and evaluates estimates against the sampling noise floor. Tuned CMA-ES becomes competitive with SPSA and can outperform it, while telescoping sampling has mixed effects.
Problem
The study addresses limited evidence about how commonly used classical optimizers perform under VQA sampling noise and whether default hyperparameters provide fair comparisons.
Source: §I · p. 1Method
The authors compare SLSQP, COBYLA, CMA-ES, and SPSA, test one- and three-stage sampling, tune CMA-ES and SPSA, and compare best-observed values with CMA-ES's statistical favorite.
Source: §I · p. 1, §III · p. 3, §IV · p. 5Results
After tuning, CMA-ES and SPSA show comparable performance across problems, with CMA-ES sometimes outperforming SPSA, while three-stage sampling has mixed effects.
Source: §I · p. 2, §IV · p. 5Takeaways & Limitations
Optimizer selection, hyperparameters, and sampling strategy should be tailored to the VQA problem and system.
Source: §I · p. 2, §IV · p. 5, §VI · p. 6
Abstract
from arXiv · showhide
Variational quantum algorithms (VQAs) offer a promising path toward using near-term quantum hardware for applications in academic and industrial research. These algorithms aim to find approximate solutions to quantum problems by optimizing a parametrized quantum circuit using a classical optimization algorithm. A successful VQA requires fast and reliable classical optimization algorithms. Understanding and optimizing how off-the-shelf optimization methods perform in this context is important for the future of the field. In this work, we study the performance of four commonly used gradient-free optimization methods: SLSQP, COBYLA, CMA-ES, and SPSA, at finding ground-state energies of a range of small chemistry and material science problems. We test a telescoping sampling scheme (where the accuracy of the cost-function estimate provided to the optimizer is increased as the optimization converges) on all methods, demonstrating mixed results across our range of optimizers and problems chosen. We further hyperparameter tune two of the four optimizers (CMA-ES and SPSA) across a large range of models and demonstrate that with appropriate hyperparameter tuning, CMA-ES is competitive with and sometimes outperforms SPSA (which is not observed in the absence of hyperparameter tuning). Finally, we investigate the ability of an optimizer to beat the `sampling noise floor' given by the sampling noise on each cost-function estimate provided to the optimizer. Our results demonstrate the necessity for tailoring and hyperparameter-tuning known optimization techniques for inherently-noisy variational quantum algorithms and that the variational landscape that one finds in a VQA is highly problem- and system-dependent. This provides guidance for future implementations of these algorithms in the experiment.
I. INTRODUCTION
The paper examines how classical optimizers perform in noisy VQAs, emphasizing that default hyperparameters can obscure optimizer limitations. It compares sampling strategies and tuned optimizers across quantum problems.
- Default-hyperparameter studies may misrepresent optimizer limitations because optimal settings vary drastically across cost functions.Source: §I · p. 1
- The study systematically tunes classical optimizers and compares their performance across problem sizes and sampling-noise strengths.Source: §I · p. 1
- Three-stage sampling sometimes improves and sometimes significantly decreases performance, so the number of stages should be treated as a variational-optimizer hyperparameter.Source: §I · p. 2
- After tuning, CMA-ES and SPSA achieve very similar performance across seven problems, contrary to classical noisy-optimization benchmarks where CMA-ES often outperforms SPSA.Source: §I · p. 2
- CMA-ES's favorite statistical estimate outperforms the lowest observed energy in all considered cases, while standard errors for the latter are statistically unsound.Source: §I · p. 2
II. BACKGROUND
A VQA prepares an approximate ground state with a parametrized circuit and passes noisy cost estimates to a classical optimizer. The paper therefore focuses on four gradient-free methods under sampling noise.
- A VQA tunes circuit parameters to produce an approximate ground state of an N-qubit system.Source: §II · p. 2
- The circuit parameters control single- and two-qubit gate rotations, while the cost function is the expectation value of a Hermitian observable.Source: §II · p. 2
- Expectation values are estimated by repeated Pauli-basis measurements, producing a sampling-noisy cost estimator whose distribution depends on the repetition count M.Source: §II · p. 2
- The study compares four gradient-free optimizers because noisy gradient-based strategies can converge more slowly and may not escape local optima under simple noise.Source: §II · p. 2
- SLSQP uses constrained second-order local approximations, COBYLA uses linear trust-region simplex models, CMA-ES adapts a Gaussian population, and SPSA estimates gradients from stochastic perturbations.Source: §II · pp. 2–3
- The algorithms are evaluated across systems with different sizes and numbers of parameters.Source: §II · p. 3
III. THREE-STAGE SAMPLING COMPARISON
The study compares fixed-shot and telescoping three-stage optimization under a shared shot budget. Three-stage sampling has no consistent advantage and its effect depends on the problem and optimizer.
III. THREE-STAGE SAMPLING COMPARISON
- The three-stage protocol uses 100, 1000, and 10000 shots per Pauli operator, with function-call ratios of 10:3:1 under a total budget of 10^7 shots.Source: §III · p. 3
- The comparison measures relative energy error using noiseless cost evaluation at parameters obtained from noisy optimization.Source: §III · p. 3
- The experiments use total shot budgets of 10^7, 10^8, and 10^9 per Pauli operator, while SLSQP and COBYLA often terminate before spending the full budget.Source: §III · p. 3
- Across three 8-qubit systems, three-stage optimization has no statistically significant overall advantage over one-stage optimization and remains highly problem- and optimizer-dependent.Individual switches can produce a 5x performance increase or decrease.Source: §III · p. 3
- Only three-stage COBYLA consistently improves over its one-stage counterpart across all problems, but the authors consider this likely a fluke.Source: §III · p. 3
- With default hyperparameters, SPSA has significantly smaller error than the other optimizers in two of three problems and converges faster in the third.Source: §III · p. 3, Figure 1 · p. 4
IV. HYPERPARAMETER TUNING
The study tunes optimizer hyperparameters for VQA problems and finds that tuning substantially improves CMA-ES, while its advantage over SPSA remains problem- and accuracy-dependent.
- Hyperparameter tuning significantly improves CMA-ES across the tested problems, whereas SPSA receives only a moderate boost.Source: §IV · p. 5
- At 10^9 total shots, tuned CMA-ES and SPSA have comparable performance, except for a median 5-fold CMA-ES gain on the 2 × 2 Hubbard model.Source: §IV · p. 5
- CMA-ES has minor advantages on 2×3 Hubbard and stretched H2O, while SPSA has minor gains on 1 × 6 Hubbard, H4 chain, and equilibrium H2O.Source: §IV · p. 5
- No clear performance trend with parameter count or qubit number appears, possibly because the tested problem sizes are insufficiently large.Source: §IV · p. 5
- CMA-ES converges more slowly than SPSA and typically shows a wider spread in final energy error because it explores larger regions and builds a covariance matrix.Source: §IV · p. 5
- For sufficiently low accuracy, SPSA may be preferable, while CMA-ES may suit high-accuracy settings when hyperparameter tuning is affordable.Source: §IV · p. 5
V. THE SAMPLING NOISE FLOOR
Sampling noise can make the best observed cost estimate misleading: it may violate the variational principle and produce unreliable error bars. CMA-ES’s favorite candidate instead provides a more accurate statistical estimate.
- Selecting the minimum among many noisy evaluations produces skewed estimates and can choose parameters that poorly approximate the ground state.Source: §V · p. 5
- CMA-ES’s favorite candidate aggregates measurements as a statistical estimator, unlike the best-ever evaluation, and can beat the sampling noise floor.Source: §V · p. 5
- Figure 3 compares noisy and noiseless evaluations of the best-ever candidate with noiseless evaluation of the favorite candidate using optimization traces from Fig. 2.Source: §V · p. 5, Figure 3 · p. 6
- The best-ever noisy evaluation can fall below the variational minimum and below zero, while its error exceeds the standard deviation implied by sampling noise.Source: §V · p. 5
- Across the considered problems, the favorite candidate has lower median cost than the best-ever candidate, with gains up to ten-fold over the sampling noise floor.Source: §V · p. 6
VI. CONCLUSION
The paper benchmarks four gradient-free optimizers for noisy VQA ground-state estimation and evaluates staged sampling, hyperparameter tuning, and candidate selection. It finds that performance is problem-dependent, tuned CMA-ES is only slightly better than tuned SPSA, and statistical parameter estimates outperform single noisy evaluations.
- Across seven quantum simulation problems, hyperparameter tuning significantly improves CMA-ES but yields only a slight performance improvement over tuned SPSA.Source: §VI · p. 6
- Three-stage sampling produces performance changes that depend strongly on the optimizer and problem, so it should be treated as a discrete hyperparameter.Source: §VI · p. 6
- The best cost estimate from a noisy optimization trace is statistically unsound, whereas statistical parameter estimates such as CMA-ES’s favorite candidate perform better under noiseless evaluation.Source: §VI · p. 6
- CMA-ES may be preferable for high-cost, high-accuracy settings, while SPSA may be preferable otherwise.Source: §VI · p. 6
- The study identifies larger system sizes as a target for future work when assessing CMA-ES relative to SPSA.Source: §VI · p. 6
Appendix A: Details on optimization algorithms
Appendix A describes four gradient-free optimization algorithms used for VQA experiments, spanning stochastic approximation, linear and quadratic approximations, and evolutionary direct search.
SPSA
- SPSA estimates all partial derivatives with two cost-function evaluations by applying a stochastic perturbation vector simultaneously.This reduces evaluations relative to finite differences, which require 2d evaluations, although the estimated direction is not exactly the gradient.Source: Appendix A · p. 7
COBYLA
- COBYLA optimizes linear approximations of objective and constraint functions within a trust region.The approximations use M + 1 points forming a simplex.Source: Appendix A · p. 7
SLSQP
- SLSQP applies sequential quadratic programming by solving local subproblems with second-order objective and affine constraint approximations.Without constraints, the method degenerates to Newton’s method.Source: Appendix A · p. 7
CMA-ES
- CMA-ES adapts a multivariate Gaussian search distribution online according to evaluated points and the evolving energy landscape.Its adapted distribution includes the covariance matrix and location.Source: Appendix A · p. 7
Appendix B: Numerical experiments
Appendix B specifies the simulated noisy VQA experiments, including software, noise generation, system settings, and the target-problem configurations and ansatz sizes.
Experimental setup
- The numerical experiments use OpenFermion and Psi4 to generate molecular problems, Cirq for simulation, and separate software implementations for the four optimizers.COBYLA and SLSQP use SciPy, CMA-ES uses PyCMA, and SPSA uses an in-house implementation based on prior code.Source: Appendix B · p. 7
Noise model
- The experiments simulate sampling noise by estimating each Pauli expectation value with a fixed number of shots and combining the noisy estimates into the Hamiltonian expectation.The procedure samples a binomial variable for each Pauli term and computes ⟨˜H⟩ = ∑i ci⟨˜Pi⟩; it approximates hardware sampling noise when shot counts are sufficiently large.Source: Appendix B · p. 7
Hubbard systems
- The benchmark includes Hubbard models with fixed t = 1.0 and U = 2.0, using VHA layer counts selected to achieve 0.99 ground-state fidelity in Ref..The layer counts are five for 1 × 6, two for 2 × 2, and four for 2 × 3 Hubbard models.Source: Appendix B · p. 7
Molecular systems
- Molecular systems use reduced active spaces, including H4 chain and square geometries and water configurations whose atomic coordinates are specified separately.The lowest two orbitals are frozen in the molecular problems described here.Source: Appendix B · p. 7, Table I · p. 8
Problem dimensions
- The target problems differ in ansatz parameter counts, which are tabulated for each system.The experiments compare algorithms across systems of different sizes and numbers of parameters.Source: Table II · p. 8
Appendix C: Optimization algorithms hyperparameters
Appendix C explains how IRACE tunes SPSA and CMA-ES hyperparameters while COBYLA and SLSQP retain defaults, with final settings reported in dedicated tables.
IRACE procedure
- IRACE ranks sampled hyperparameter configurations through repeated races, eliminating less favorable settings with statistical tests and updating the candidate-generation model.Surviving configurations are raced again until the evaluation budget or a configuration threshold is reached, and the survivors are returned as optimal settings.Source: Appendix C · p. 8
Reported configurations
- Tables III and IV report the SPSA and CMA-ES settings used for default and tuned experiments, with CMA-ES parameters expressed partly as functions of the free-parameter count m.SPSA tuning is performed only on selected molecular systems and reused across corresponding geometries, while Hubbard settings remain default according to Ref. [22].Source: Table III · p. 8, Table IV · p. 9
Tuned hyperparameters
- SPSA tuning varies a, α, c, and γ over predefined ranges, while CMA-ES tuning varies population size, c mean, µ, Damp. factor, and σ0.The appendix lists the search ranges for each optimizer’s tuned parameters.Source: Appendix C · p. 8
Tuning budget
- IRACE uses a 500-evaluation hyperparameter budget, a seven-day runtime limit, and four independent runs whose best elites determine the suggested configurations.Two evaluations are used for each configuration at the beginning of each race, and the F-test eliminates worse configurations.Source: Appendix C · p. 8
Default settings
- COBYLA and SLSQP use default hyperparameter settings rather than IRACE-tuned configurations.The appendix specifies default initial radius and tolerance values for COBYLA and epsilon and tolerance values for SLSQP.Source: Appendix C · pp. 8–9
Appendix D: Unitary Coupled-Cluster ansatz based on coupled-cluster amplitudes
Appendix D constructs a reduced, trotterized UCC ansatz from classically computed coupled-cluster amplitudes, reducing operators while preserving an amplitude-based ordering.
Amplitude computation
- Coupled-cluster amplitudes are obtained by solving nonlinear projected equations rather than by direct variational optimization.The linked formulation makes the BCH expansion tractable, with a natural truncation at fourth order.Source: Appendix D · p. 9
Amplitude-selected UCC
- The ansatz retains only excitation operators with non-zero classical coupled-cluster amplitudes, substantially reducing the number of operators and circuit parameters.The coupled-cluster amplitudes are computed for H4 chain, H4 square, and H2O molecular systems before defining the UCC ansatz.Source: Appendix D · p. 9
Trotterization
- The trotterized UCC approximation orders operators by descending coupled-cluster amplitude, placing the largest-amplitude operator first.The approximation depends on operator ordering and may be mitigated by classical optimization.Source: Appendix D · p. 9
Relation to ADAPT-VQE
- Compared with ADAPT-VQE, the selected operators coincide in these ansätze, but ADAPT-VQE can add or repeat operators to pursue higher accuracy.The amplitude-based strategy can therefore precede a few ADAPT-VQE steps to expand the operator pool.Source: Appendix D · pp. 9–10
Initialization
- The approach uses the Hartree–Fock state as the initial state and initializes all circuit parameters at 0.0.This initialization is used in the numerical experiments.Source: Appendix D · p. 10
Appendix E: Variational Hamiltonian ansatz for the Hubbard model
The Hubbard-model ansatz is built from parametrized hopping and interaction dynamics, using parallelizable horizontal and vertical terms and a specified Gaussian initial state.
- The Fermi-Hubbard Hamiltonian models fermions on an n_x × n_y lattice with nearest-neighbor hopping and on-site Coulomb repulsion.Source: Appendix E · p. 10
- The hopping term is decomposed into vertical and horizontal contributions, H_t = H_v + H_h.Source: Appendix E · p. 10
- The variational Hamiltonian ansatz constructs parametrized states motivated by Trotterized time evolution, with horizontal and vertical terms implementable in parallel.Source: Appendix E · p. 10
- The circuit starts from the Gaussian ground state of the noninteracting Hamiltonian, with all circuit parameters initialized to 0.0.Source: Appendix E · p. 10
- The Fermi-Hubbard Hamiltonian is generated using the open-source OpenFermion package.Source: Appendix E · p. 10
Appendix F: Optimization convergence traces
The appendix presents convergence traces for hyperparameter-tuned SPSA and CMA-ES across Hubbard and stretched-water problems, comparing one-stage with three-stage sampling.
- The traces compare hyperparameter-tuned SPSA and CMA-ES on 2 × 2 Hubbard, 2 × 3 Hubbard, and stretched water-molecule problems.Source: Appendix F · p. 10, Figure 4 · p. 10, Figure 5 · p. 11
- Each experiment uses 10^8 total shots, with thin lines for independent runs and a thick line showing the median of 15 runs.Source: Appendix F · pp. 10–11
- For every problem, the top panel shows one-stage sampling and the bottom panel shows three-stage sampling.Source: Appendix F · pp. 10–11