Ansatz-Independent Variational Quantum Classifiers and the Price of Ansatz

Hideyuki Miyahara, Vwani Roychowdhury

Abstract

The paradigm of variational quantum classifiers (VQCs) encodes classical information as quantum states, followed by quantum processing and then measurements to generate classical predictions. VQCs are promising candidates for efficient utilizations of noisy intermediate scale quantum (NISQ) devices: classifiers involving $M$-dimensional datasets can be implemented with only $\lceil \log_2 M \rceil$ qubits by using an amplitude encoding. A general framework for designing and training VQCs, however, is lacking. An encouraging specific embodiment of VQCs, quantum circuit learning (QCL), utilizes an ansatz: a circuit with a predetermined circuit geometry and parametrized gates expressing a time-evolution unitary operator. The representational power of QCL depends strongly on the choice of the ansatz, as it limits the range of possible unitary operators that a VQC can search over. This paper develops a computational framework to address the "price of ansatz"—the performance gap between QCL and ansatz-independent VQCs—and the "price of quantum"—the gap between VQCs and equivalent classical classifiers. We introduce the Unitary Kernel Method (UKM) for designing ansatz-independent VQCs and the Variational Circuit Realization (VCR) for decomposing unitaries into circuits. Numerical results show an ansatz-induced gap of 10–20% and a VQC-induced gap of 10–16%.

Introduction

Variational quantum classifiers (VQCs) are a cornerstone of near-term quantum machine learning. By leveraging amplitude encoding, they can process high-dimensional data with a logarithmic number of qubits, making them ideal for Noisy Intermediate-Scale Quantum (NISQ) devices. However, most current implementations rely on a fixed "ansatz"—a pre-defined arrangement of quantum gates where only rotation angles are trained. This approach faces two major hurdles: a representation gap, where the circuit cannot represent the optimal transformation, and an optimization gap, where training leads to "barren plateaus." This paper seeks to quantify the performance lost due to these constraints, termed the "price of ansatz."

The Variational Quantum Classifier (VQC) Framework

A standard VQC architecture involves encoding input data $x_i$ into a quantum state $|\psi^{\text{in}}(x_i)\rangle$, applying a unitary transformation $\hat{U}$, and performing measurements to obtain observables.

General architecture of a Variational Quantum Classifier (VQC) using amplitude encoding.

The primary advantage of this framework is hardware efficiency. For a dataset with $M$ features, amplitude encoding requires only $n = \lceil \log_2 M \rceil$ qubits. However, the choice of $\hat{U}$ is typically restricted by the chosen ansatz, which can significantly limit classification accuracy.

Methodology: UKM and VCR

To overcome the limitations of fixed ansätze, the authors developed a two-step computational framework:

  1. Unitary Kernel Method (UKM): Instead of optimizing gate parameters, UKM directly optimizes the entire unitary matrix $\hat{U}$. By treating the problem as an optimization over the space of all possible unitary operators using the Splitting Orthogonal Constraints (SOC) method, UKM provides an "ansatz-independent" upper bound on quantum classifier performance.
  2. Variational Circuit Realization (VCR): Once the optimal unitary is found via UKM, VCR decomposes that matrix back into a layered quantum circuit. This identifies the minimum number of layers required to approximate the target unitary with a specific precision.
The computational framework: (a) VQC architecture, (b) QCL with fixed ansatz, (c) the proposed Unitary Kernel Method (UKM), and (d) Variational Circuit Realization (VCR).

Key Results and Insights

The framework was evaluated on standard benchmarks (Iris, Breast Cancer, Sonar, Wine, MNIST256). Several profound insights emerged:

  • VQCs as Constrained Kernels: The paper mathematically proves that a VQC is essentially a classical kernel classifier with a "unitarity constraint." Consequently, a quantum classifier cannot mathematically outperform an unconstrained classical kernel method using the same data encoding.
  • The Steep Price of Ansatz: Numerical results show that using a fixed circuit (QCL) results in a 10% to 20% drop in accuracy compared to the optimal ansatz-independent unitary found by UKM.
  • The VQC-Induced Gap: The difference between the best possible quantum classifier and a classical kernel method ranges from 10% to 16%.
  • Circuit Depth and Stability: Unlike standard variational algorithms where more layers often degrade performance due to barren plateaus, the UKM/VCR approach allows for deeper circuits that perform better because the target unitary is already known. Furthermore, UKM demonstrates stable convergence compared to the sensitivity of random initialization in QCL.

Conclusion

The introduction of UKM and VCR provides a rigorous framework for determining the ultimate performance limits of variational quantum classifiers. The results highlight that the "price of ansatz" is significant, and that the primary advantage of current VQCs lies in their logarithmic qubit efficiency rather than superior classification accuracy over classical kernel methods.

Summary updated

BibTeX
@inproceedings{miyahara2022ansatz,
  author = {Hideyuki Miyahara and Vwani Roychowdhury},
  title = {{Ansatz-Independent Variational Quantum Classifiers and the Price of Ansatz}},
  booktitle = {Scientific},
  year = {2022},
  doi = {10.1038/s41598-022-20688-5},
}
Figure