arXiv:2609.02186quant-phSep 2026

Manuscript Offprint

arXiv:2609.02186

Quantum MeanFlow: single-shot generative sampling on NISQ hardware

Ashish Joshi, Eshaan Mistry, Takahiko Koyama

Abstract

Quantum generative models offer a promising framework for exploring whether quantum computation can enhance generative machine learning. Flow matching is a generative method in which samples are generated by transporting a simple, known distribution to the target data distribution with a learned velocity field. Its quantum counterpart, known as quantum flow matching (QFM), was introduced recently, and, like its classical counterpart, requires integrating an ordinary differential equation over many time steps during inference. As each step requires the output from the previous step, the circuit submission is sequential and a drawback on quantum computers as they have high input/output costs. To alleviate this problem, we introduce Quantum MeanFlow (QMF), the quantum analogue of the MeanFlow formulation, which allows single-step sample generation. While the QFM learns an instantaneous velocity field at each time step, QMF learns the average velocity over a time interval. We use a parameterized quantum circuit to learn these velocity fields and benchmark the two methods on the MNIST dataset. We show that while single-step QMF has lower image quality compared to multi-step QFM, it performs better than the single-step QFM sampling at every shot count. Both of our models are executed on IBM quantum computers and best-of-NN rejection sampling recovers most of the accuracy lost to device noise without modifying the circuit. This is especially advantageous for QMF which has only one circuit evaluation per image. Here, We establish QMF as a viable method for single-step quantum generative sampling, saving on quantum circuit evaluations per generated sample.

1 Introduction

Generative machine learning attempts to learn the underlying probability distribution from a dataset and generate samples from the learned distribution. The modern landscape of generative machine learning started with variational autoencoders (VAEs) [1], generative adversarial networks (GANs) [2] and auto-regressive

*Corresponding author: takahiko.koyama@keio.jp models [3]. Diffusion models [4, 5, 6] improved on several aspects of the previous methods, providing training stability and the ability to generate high-quality data [7]. Diffusion models learn to denoise the data step-by-step and can be described by stochastic differential equations [6]. An equivalent but mathematically simpler formalism is flow matching, which is instead described by ordinary differential equations [8, 9, 10, 11]. The model learns the probability flow between the noise and data distribution, and once trained, inference is much faster because a simple ordinary differential equation (ODE) is integrated to generate samples.

Alongside the developments described above, the disparate field of quantum computing is getting much attention. Quantum computing uses the principles of quantum mechanics as the basis of computation [12] and has the potential to provide speedups over classical algorithms for specific classes of problems [13, 14]. Since machine learning and deep learning methods often have high computational costs, it is natural to consider if quantum computing can provide any benefits for these methods. The relatively new subfield of quantum machine learning (QML) [15, 16] aims to explore the potential of quantum computing in machine learning, with many interesting results over the past few years. Even without an established quantum advantage, implementing generative models on quantum hardware provides a framework for investigating whether quantum circuits can offer useful alternative representations of complex data distributions. Quantum models for generative machine learning have been gaining interest recently, with models for quantum GAN [17, 18, 19, 20], quantum VAE [21, 22], quantum diffusion [23, 24, 25, 26, 27] and quantum flow matching [28, 29]. While quantum diffusion models are being explored for both quantum and classical data, quantum flow matching (QFM) has only been explored in the context of quantum data. The closest work on classical data is a hybrid quantum-classical normalizing flow [30], which learns an invertible map rather than a velocity field. Here, we fill this gap by focusing on QFM for generating classical data.

As we are still far from the era of fault-tolerant quantum computers, most of the QML models are implemented either in simulations or on the currently available noisy intermediate scale quantum (NISQ) devices [31]. However, training a quantum circuit on NISQ devices is not feasible because of high rate of errors, in addition to the vanishing gradients that affect deep variational circuits [32]. Instead, we perform training classically and use the trained quantum models to generate samples on a real device. This still requires sampling for several time steps on a quantum computer, with the output of one step being the input for the next. As data input and output on a quantum computer is expensive [33, 16], the cost of doing this increases with number of steps, which is often required to generate good quality images. Recent work has tackled this problem by proposing single shot sampling in classical flow matching. This method is called MeanFlow [34] and it was shown that it outperforms all the other single and few shot sampling methods [35, 36, 37].

In this work, we present the first QFM model with MeanFlow for classical image generation. We call this Quantum MeanFlow (QMF). We train both QFM and QMF models on the MNIST dataset in simulation and perform inference on quantum hardware. We show that the QMF model can perform single-step sampling on the hardware, requiring only one circuit evaluation to generate one image. We also observed that at lower number of shots, multi-step sampling in both QFM and QMF models can alleviate the effects of sampling noise. Our results establish single-step QMF as a viable approach for quantum generative sampling that eliminates the sequential circuit evaluations required by multi-step QFM, making it better suited to the constraints of current NISQ hardware.

The paper is organized as follows. In section 2, we give the background of classical flow matching and MeanFlow formulations. In section 3, we present our QMF formulation, with data processing steps and classical methods in section 3.1, the quantum ansatz for learning the velocity fields in section 3.2 and training and sampling procedure in section 3.3. The results are presented in section 4 with discussion in section 5.

References (36)