Source-linked AI summary
A Comparison of Various Classical Optimizers for a Variational Quantum Linear Solver
Aidan Pellow-Jarman, Ilya Sinayskiy, Anban Pillay, Francesco Petruccione
TL;DR
Noisy, shallow-circuit settings make optimization difficult for variational quantum algorithms, motivating a practical comparison of classical optimizers in VQLS. Across the tested noise conditions, realistic noise substantially worsens optimizer performance, while SPSA performs best overall in the noisy simulation.
Problem
High noise and shallow ansatz circuits with limited overlap make classical optimization difficult in near-term variational quantum algorithms.
Source: §1 · p. 2Method
Results
Under realistic simulated noise, all optimizers perform significantly worse, while SPSA appears best overall and Powell’s method performs comparatively well.
Source: §4 · p. 10Takeaways & Limitations
SPSA appears less affected by realistic noise than the other methods, while COBYLA and Conjugate-Gradient perform worst in the noisy simulation.
Source: §4 · pp. 10–11The comparison used quantum simulators, kept hyper-parameters mostly standard, and tested only VQLS, leaving hardware validation and other variational algorithms for future work.
Source: §5 · pp. 12–13
Abstract
from arXiv · showhide
Variational Hybrid Quantum Classical Algorithms (VHQCAs) are a class of quantum algorithms intended to run on noisy intermediate-scale quantum (NISQ) devices. These algorithms employ a parameterized quantum circuit (ansatz) and a quantum-classical feedback loop. A classical device is used to optimize the parameters in order to minimize a cost function that can be computed far more efficiently on a quantum device. The cost function is constructed such that finding the ansatz parameters that minimize its value, solves some problem of interest. We focus specifically on the Variational Quantum Linear Solver (VQLS), and examine the effect of several gradient-free and gradient-based classical optimizers on performance. We focus on both the average rate of convergence of the classical optimizers studied, as well as the distribution of their average termination cost values, and how these are affected by noise. Our work demonstrates that realistic noise levels on NISQ devices present a challenge to the optimization process. All classical optimizers appear to be very negatively affected by the presence of realistic noise. If noise levels are significantly improved, there may be a good reason for preferring gradient-based methods in the future, which performed better than the gradient-free methods with the only shot-noise present. The gradient-free optimizers, Simultaneous Perturbation Stochastic Approximation (SPSA) and Powell's method, and the gradient-based optimizers, AMSGrad and BFGS performed the best in the noisy simulation, and appear to be less affected by noise than the rest of the methods. SPSA appears to be the best performing method. COBYLA, Nelder-Mead and Conjugate-Gradient methods appear to be the most heavily affected by noise, with even slight noise levels significantly impacting their performance.
1 Introduction
NISQ devices are not yet practical for many promising quantum algorithms, motivating variational approaches and careful selection of classical optimizers. This study compares optimizers for VQLS with attention to noise and the resources required for cost evaluations.
1 Introduction
- Current quantum devices have too much noise and too few qubits for several promising algorithms to be realized in practice.The introduction cites Shor’s algorithm [1], the Quantum Fourier Transform [2], and HHL [3] as examples of algorithms demonstrating quantum computing’s potential on fault-tolerant devices.Source: §1 · p. 2
- VHQCAs use a parameterized circuit and quantum-classical feedback loop to minimize a cost function, with VQLS targeting the quantum linear systems problem.These algorithms were proposed for possible implementation on noisy intermediate-scale quantum devices.Source: §1 · p. 2
- Optimizer choice is especially important when high noise and shallow ansatz circuits with limited overlap make optimization difficult.The study compares gradient-based and gradient-free methods for VQLS, using a practical cost comparison based on resources needed for cost-function evaluations.Source: §1 · pp. 2–3
- Earlier optimizer comparisons studied other VHQCAs and problems, including VQE, single-qubit optimal control, and combinatorial optimization.Prior work also highlighted the need for relevant cost models and hyper-parameter optimization.Source: §1 · p. 3
- This work distinguishes its comparison by considering noise, optimizer type, evaluation-resource costs, a selected optimizer set, and VQLS as the target problem.The study aims to make a practical comparison across a large selection of classical optimizers.Source: §1 · p. 3
2 Variational Quantum Linear Solver
VQLS encodes a linear-system problem into quantum inputs and uses a classical optimizer to tune an ansatz circuit until its output approximates the solution state. The section also distinguishes ansatz choices and describes gradient-based and gradient-free optimizer implementations.
2 Variational Quantum Linear Solver
- VQLS represents A as a linear combination of unitary matrices and supplies b through a unitary gate that prepares |b⟩.The matrix representation is equivalent to a linear combination of Pauli operators.Source: §2 · p. 4
- The VQLS feedback loop updates ansatz parameters from quantum cost evaluations until its output state approximates the exact linear-system solution within ε.The target is V(α*)|0⟩ = |x′⟩, with |||x⟩−|x′⟩||₂ ≤ ε.Source: §2 · p. 4, Figure 1 · p. 5
- Hardware-efficient ansätze are optimized for available hardware and more noise-resistant, but may not contain a close approximation of the solution; problem-specific ansätze use problem structure.QAOA is given as a problem-specific example, but its Hamiltonian-simulation requirement is less near-term than the hardware-efficient approach.Source: §2 · pp. 4–5
2.1 Classical Optimizers
- Gradient-based optimizers use gradient information, while gradient-free methods treat cost evaluations as a black box; this comparison uses analytic quantum gradients and mostly standard hyper-parameters.COBYLA’s rhobeg is set to π, and ADAM and AMSGrad use a learning rate of 0.1.Source: §2.1 · pp. 5–6
- The optimizer set is implemented using SciPy and Qiskit libraries, with references listed in Table 1.The implementations use scipy.optimize.minimize and qiskit.aqua.components.optimizers.Source: Table 1 · p. 6
3 Comparison Setup
The comparison setup defines three VQLS test instances and their ansatz and cost-function choices, then evaluates optimizers under three noise regimes using cost-function evaluations as a resource measure.
3 Comparison Setup
- The comparison setup introduces the test instances, ansatz and cost function, noise simulations, and a resource measure for optimizer comparisons.The quantum simulations use qiskit.Source: §3 · p. 6
3.1 Test Problem Instances
- Three real-valued instances use 8 × 8, 16 × 16, and 32 × 32 matrices, with |b⟩ = H^⊗n|0⟩^n and 3-, 4-, and 5-qubit ansatze, respectively.The matrices are specified as combinations of identity and tensor-product Z, H, and X operators.Source: §3.1 · pp. 6–7, Figure 2 · p. 7
3.2 Test Ansatz and Cost Function Choice
- The study uses simple hardware-efficient ansatze with parameterized Ry rotations and controlled-X gates, limited two-qubit gates, and shared random initializations across 100 runs.The ansatze are not tailored to the test instances; the same initial parameters are used across optimizers and noise levels for fair comparison.Source: §3.2 · pp. 7–8, Figure 2 · p. 7
- The selected local cost function is intended to avoid exponentially vanishing gradients as qubit count increases and does not require controlled ansatz application, making it more noise-resistant.The cost function was proposed in [12].Source: §3.2 · p. 8
3.3 Effect of Noise
- Three simulations represent zero noise, shot noise alone with 10 000 shots, and shot noise plus a realistic noise model sampled from IBM Vigo.The state-vector simulation corresponds to infinitely many shots; the realistic-noise simulation is intended as the most difficult and realistic optimization challenge.Source: §3.3 · p. 8
3.4 Resource Comparison
- The resource comparison counts cost-function evaluations, equates each gradient evaluation to two cost evaluations per ansatz parameter, and imposes limits of 600, 800, and 1000 evaluations for 3-, 4-, and 5-qubit instances.Optimizers stop when they reach the applicable evaluation limit.Source: §3.4 · p. 9
4 Results and Discussion
Realistic noise substantially worsens optimizer performance, but the methods vary in how well they handle it. Across problem instances, SPSA performs best overall, while convergence speed is generally similar across approaches.
Statevector simulation
- In statevector simulations, nearly all optimizers perform similarly, with ADAM and AMSGrad slightly underperforming and BFGS, L-BFGS, SLSQP, and COBYLA slightly outperforming the rest.There is little overall difference between gradient-based and gradient-free approaches without noise.Source: §4 · p. 9
Shot-noise
- With shot-noise alone, gradient-based optimizers generally outperform gradient-free methods, except SPSA, which performs best on average across all problem instances.BFGS, L-BFGS, and SLSQP are the strongest gradient-based methods; ADAM and AMSGrad underperform within that group.Source: §4 · pp. 9–10
Realistic noise
- Under realistic noise, all optimizers perform significantly worse; SPSA performs best overall, with Powell, AMSGrad, and BFGS also handling noise comparatively well.COBYLA, Nelder-Mead, and Conjugate-Gradient perform worst in the noisy simulation.Source: §4 · pp. 10–11, Figure 3 · p. 10, Figure 4 · p. 11
Convergence rate
- Convergence is near-equally fast across approaches, while ADAM and AMSGrad are consistently slowest and COBYLA fastest, terminating early when noise is present.The reported trends are similar across problem instances and noise levels.Source: §4 · p. 11
5 Conclusion
Realistic NISQ noise challenges optimization: SPSA performs best, while performance varies widely across both gradient-free and gradient-based optimizers. The comparison is an initial investigation, with hyperparameter settings and validation beyond quantum simulators left for future work.
5 Conclusion
- Under realistic noise, SPSA performs best; Powell, AMSGrad, and BFGS also perform relatively well, while COBYLA, Nelder-Mead, and Conjugate Gradient perform exceptionally worse than in the noise-free environment.At very low noise, gradient-based approaches appear to outperform gradient-free optimizers; under realistic noise, there is no clear winner between the two groups.Source: §5 · p. 12
- The results are an initial investigation, and the study paid little attention to setting the optimizers’ hyperparameters.The comparison keeps hyperparameters constant, so selecting appropriate settings could greatly improve some optimizers’ performance.Source: §5 · pp. 12–13
- Figures 6–8 report average convergence rates across the 50 best attempts for all optimizers at each noise level in the 3-, 4-, and 5-qubit problem instances.Source: Figure 6 · p. 13, Figure 7 · p. 14, Figure 8 · p. 15
- The findings are based on quantum simulators and a variational quantum linear solver; confirmation on real hardware and investigation of other variational algorithms remain future work.Source: §5 · p. 13