Table of Contents
Fetching ...

Automatic and effective discovery of quantum kernels

Massimiliano Incudini, Daniele Lizzio Bosco, Francesco Martini, Michele Grossi, Giuseppe Serra, Alessandra Di Pierro

TL;DR

The paper addresses the challenge of engineering effective quantum kernels for specific tasks by introducing an automatic kernel-discovery framework. It models quantum kernels as discrete combinatorial objects representing parameterized quantum circuits and optimizes a task-aware cost function using flexible heuristics, including Bayesian optimization and RL, with expressivity control via bandwidth and projections. Key contributions include formalizing the kernel-design space QK_{n,m}, defining informative criteria (Norm of A, DLA rank, Kernel-target alignment, Task-model alignment, and validation error), and demonstrating that automated kernels can match or surpass manually designed kernels in a high-energy physics anomaly-detection benchmark, sometimes outperforming state-of-the-art quantum kernels. The work shows the practical value of automation in quantum kernel design, provides open-source software, and outlines directions for extending optimization strategies and applying the approach to other tasks. Overall, it advances the feasibility of deploying quantum-kernel methods on NISQ devices by reducing manual engineering and enabling principled, task-aligned kernel discovery, with demonstrated gains in a representative HEP setting.

Abstract

Quantum computing can empower machine learning models by enabling kernel machines to leverage quantum kernels for representing similarity measures between data. Quantum kernels are able to capture relationships in the data that are not efficiently computable on classical devices. However, there is no straightforward method to engineer the optimal quantum kernel for each specific use case. We present an approach to this problem, which employs optimization techniques, similar to those used in neural architecture search and AutoML, to automatically find an optimal kernel in a heuristic manner. To this purpose we define an algorithm for constructing a quantum circuit implementing the similarity measure as a combinatorial object, which is evaluated based on a cost function and then iteratively modified using a meta-heuristic optimization technique. The cost function can encode many criteria ensuring favorable statistical properties of the candidate solution, such as the rank of the Dynamical Lie Algebra. Importantly, our approach is independent of the optimization technique employed. The results obtained by testing our approach on a high-energy physics problem demonstrate that, in the best-case scenario, we can either match or improve testing accuracy with respect to the manual design approach, showing the potential of our technique to deliver superior results with reduced effort.

Automatic and effective discovery of quantum kernels

TL;DR

The paper addresses the challenge of engineering effective quantum kernels for specific tasks by introducing an automatic kernel-discovery framework. It models quantum kernels as discrete combinatorial objects representing parameterized quantum circuits and optimizes a task-aware cost function using flexible heuristics, including Bayesian optimization and RL, with expressivity control via bandwidth and projections. Key contributions include formalizing the kernel-design space QK_{n,m}, defining informative criteria (Norm of A, DLA rank, Kernel-target alignment, Task-model alignment, and validation error), and demonstrating that automated kernels can match or surpass manually designed kernels in a high-energy physics anomaly-detection benchmark, sometimes outperforming state-of-the-art quantum kernels. The work shows the practical value of automation in quantum kernel design, provides open-source software, and outlines directions for extending optimization strategies and applying the approach to other tasks. Overall, it advances the feasibility of deploying quantum-kernel methods on NISQ devices by reducing manual engineering and enabling principled, task-aligned kernel discovery, with demonstrated gains in a representative HEP setting.

Abstract

Quantum computing can empower machine learning models by enabling kernel machines to leverage quantum kernels for representing similarity measures between data. Quantum kernels are able to capture relationships in the data that are not efficiently computable on classical devices. However, there is no straightforward method to engineer the optimal quantum kernel for each specific use case. We present an approach to this problem, which employs optimization techniques, similar to those used in neural architecture search and AutoML, to automatically find an optimal kernel in a heuristic manner. To this purpose we define an algorithm for constructing a quantum circuit implementing the similarity measure as a combinatorial object, which is evaluated based on a cost function and then iteratively modified using a meta-heuristic optimization technique. The cost function can encode many criteria ensuring favorable statistical properties of the candidate solution, such as the rank of the Dynamical Lie Algebra. Importantly, our approach is independent of the optimization technique employed. The results obtained by testing our approach on a high-energy physics problem demonstrate that, in the best-case scenario, we can either match or improve testing accuracy with respect to the manual design approach, showing the potential of our technique to deliver superior results with reduced effort.
Paper Structure (42 sections, 31 equations, 9 figures, 1 table)

This paper contains 42 sections, 31 equations, 9 figures, 1 table.

Figures (9)

  • Figure 1: Pipeline for the automatic discovery of quantum kernels: Prior knowledge of the problem can be employed to propose a sub-optimal educated guess as an initial candidate solution. The cost function that evaluates the quantum kernel at each iteration is based on criteria proposed in the literature and can depend on the problem's data. Various optimization algorithms can be employed to reach the candidate solutions. The same criteria used for the cost function can also be used to further evaluate the candidate solution and explain its performance.
  • Figure 2: The 'overlap test' quantum circuit used to estimate the inner product of two vectors $\bm{x}^{(1)}, \bm{x}^{(2)}$ encoded via the unitary transformation $U$. The probability of measuring $0^n$ as the output of the quantum circuit with infinite precision (shots) is estimated by the means of the formula in Equation \ref{['eq:overlap_quantum_kernel']}.
  • Figure 3: The 'swap test' quantum circuit used to estimate the inner product of two vectors $\bm{x}^{(1)}, \bm{x}^{(2)}$ encoded accordingly to the unitary transformation $U$. It uses $2n+1$ qubits, instead of the $n$ qubits used by the overlap test, but results in shallower circuits. The probability of measuring 0 on the topmost qubit allows us to estimate the inner product via Equation \ref{['eq:swap_test']}. By applying the controlled operation of the swap test to a subset of the $n$ target qubits of each data-related state, we can calculate partial inner products which can be interpreted as a projected quantum kernel (cf. Equation \ref{['eq:overlap_quantum_kernel']}).
  • Figure 4: An example of a quantum kernel constructed using our approach. This quantum kernel is characterized by a feature map operating on a Hilbert space with $n = 3$ qubits and consists of $m = 3$ operations. Each sample is represented as $\bm{x} \in \mathbb{R}^5$ (only the last two features are effectively used in this example). While the bandwidth values are not specified, a common choice is to set $\beta_i = i/10$ for $i \in 1, ..., 10$. The measurement is performed on a subset of the three qubits, making this a projected quantum kernel.
  • Figure 5: ROC-AUC curve comparing our approach (solid line) with the best classical (dashed line, left) and quantum (dashed line, right) kernels from the literature for datasets with a latent dimension of 8. The shaded areas represent a standard deviation of 1 from the average value (solid line). In the displayed configuration, the kernel built with our approach consists of $m=8$ operations.
  • ...and 4 more figures