Quantum Diffusion Models for Few-Shot Learning

Ruhan Wang, Ye Wang, Jing Liu, Toshiaki Koike‐Akino2024

Abstract

Quantum Machine Learning (QML) often struggles with data scarcity, requiring large datasets to train effective Variational Quantum Circuits. This paper introduces three novel frameworks—LGGI, LGNAI, and LGDI—that utilize Quantum Diffusion Models (QDMs) to address the few-shot learning (FSL) problem. By employing label-guided generative processes, these methods significantly outperform traditional Quantum Neural Networks (QNNs) in low-data regimes, demonstrating remarkable robustness to hardware noise and zero-shot transfer capabilities.

Introduction

While Quantum Machine Learning holds immense promise, its practical application is often limited by data efficiency. Most state-of-the-art QML models rely on large datasets to optimize Variational Quantum Circuits (VQCs). However, in critical fields like drug discovery or rare disease diagnosis, data is inherently scarce. This challenge, known as Few-Shot Learning (FSL), has been successfully addressed in classical machine learning using diffusion models (e.g., DALL-E). This research explores the application of diffusion-based logic to the quantum realm, tackling the noise and resource constraints of current quantum hardware.

Methodology

The proposed approach centers on the Quantum Denoising Diffusion Model (QDDM). The authors implement a "label-guided" mechanism by adding an auxiliary qubit to the circuit, where a Pauli-X rotation represents the class label.

The Quantum Denoising Diffusion Model (QDDM) process, illustrating the diffusion (noise addition) and denoising (noise prediction) stages.

Three distinct algorithms were developed based on this QDDM architecture:

  1. QDiff-LGGI (Label-Guided Generation Inference): A data-augmentation approach where the QDDM generates synthetic, label-consistent quantum data from a tiny support set to train a standard QNN.
  2. QDiff-LGNAI (Label-Guided Noise Addition Inference): An algorithmic test-time approach. It adds noise to a test sample and uses the noise predictor to estimate it under different label prompts. The label yielding the lowest Mean Squared Error (MSE) is selected.
  3. QDiff-LGDI (Label-Guided Denoising Inference): Operates during the denoising stage by comparing original noisy data with reconstructions under various label prompts to find the most faithful match.

Experimental Setup

The models were evaluated on three benchmark datasets adapted for quantum circuits: Digits MNIST, MNIST, and Fashion MNIST (all resized to 8x8). Testing encompassed 2-way and 3-way classification tasks in both 1-shot (one example per class) and 10-shot settings. Performance was compared against four representative QNN baselines.

Results and Discussion

The proposed methods consistently outperformed traditional QNN architectures across all benchmarks.

Baseline Quantum Neural Network (QNN) architectures used for performance comparison: (a) C14, (b) QMLP, (c) Quantumnat, and (d) OPTIC.

Key Performance Metrics

  • Superior Accuracy: In the 2-way 10-shot Digits MNIST task, QDiff-LGNAI achieved an accuracy of 0.997, significantly higher than the best baseline (QMLP) at 0.892.
  • Average Gains: Across all tasks, QDiff-LGNAI maintained an average accuracy of 0.795, while baseline averages ranged from 0.546 to 0.678.
  • Zero-Shot Capability: The models demonstrated strong cross-domain performance, effectively classifying Digits MNIST images using a model trained only on standard MNIST.

Hardware Robustness

Tests on a real quantum processor (IBM_Almaden) revealed that diffusion-based logic is inherently more robust to decoherence and gate errors than standard QNNs, showing only a marginal performance dip compared to ideal simulators.

Conclusion

Quantum Diffusion Models represent a significant advancement for few-shot learning in QML. By repurposing generative models as classifiers, the authors have created a framework that is both data-efficient and robust to the noise of NISQ-era devices. Future work will focus on scaling these models to higher-resolution data and further optimizing circuit depth for more complex quantum hardware.

Summary updated

BibTeX
@misc{wang2024quantum,
  author = {Ruhan Wang and Ye Wang and Jing Liu and Toshiaki Koike‐Akino},
  title = {{Quantum Diffusion Models for Few-Shot Learning}},
  year = {2024},
  eprint = {2411.04217},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2411.04217},
}
Figure