Computing Library › Quantum Ml
Quantum Ml

Shot Noise and Sampling

Every quantum expectation value is estimated from a finite number of measurements, so shot noise sets the precision and the runtime of quantum machine learning.

Measurement is sampling

A quantum circuit does not report an expectation value directly. It reports a single measurement outcome per run, and the expectation must be estimated by averaging over many runs, called shots. Because each shot is a random draw, the estimate carries statistical error. This shot noise is unavoidable and is one of the defining practical costs of quantum machine learning.

How precision scales

Kronos motion — lego machine

For an observable with outcomes bounded in a fixed range, the standard error of the estimated expectation falls off as one over the square root of the number of shots. To halve the error you must quadruple the shots. Reaching precision epsilon needs on the order of one over epsilon squared shots. This quadratic scaling makes high-precision estimates expensive and shapes every design choice downstream.

python
# Estimating <Z> and its shot-noise error (schematic)
import numpy as np
outcomes = measure_Z(theta, shots=N)   # array of +1 / -1
est = outcomes.mean()
stderr = outcomes.std(ddof=1) / np.sqrt(N)   # ~ 1/sqrt(N)
print(f'<Z> = {est:.3f} +/- {stderr:.3f}')

Where the cost compounds

Reducing the shot bill

Several techniques cut shots. Grouping commuting observables lets several Pauli terms be measured together. Classical shadows estimate many observables from few measurements by randomizing the measurement basis. Adaptive shot allocation spends more shots where the loss is sensitive and fewer where it is flat. Variance-reduced estimators and importance-weighted sampling help for structured observables.

Why it is fundamental

Shot noise is not a hardware defect that better engineering removes; it is intrinsic to quantum measurement. Even a perfect, noiseless quantum computer would still need many shots to read out an expectation to high precision. Any honest runtime or advantage analysis for a quantum model must include the shot budget, which is frequently the dominant term and is easy to overlook in idealized complexity statements.