Noise modelling¶
Real hardware is noisy. SimQ’s noise system (in simq-core::noise, exposed
to Python as simq.noise) lets you attach realistic error channels to
simulations.
Noise channels¶
Channel |
Models |
|---|---|
|
Uniform Pauli errors with probability p |
|
Energy relaxation (T₁ decay) |
|
Pure dephasing (T₂) |
|
Bit-flip errors at measurement time |
Each channel has a Monte-Carlo counterpart (DepolarizingMC,
AmplitudeDampingMC, …) used for trajectory-based sampling during shot
simulation.
Hardware noise models¶
HardwareNoiseModel composes per-qubit and per-gate noise into a device
profile:
QubitProperties— T₁/T₂ times and per-qubit error ratesGateTiming— gate durations, so damping is applied for the right timeTwoQubitGatePropertiesandCrosstalkProperties— coupling-dependent errorsGateNoise— attaches channels to specific gate types
Using noise from Python¶
import simq
# Build a device-like noise model
noise_model = simq.HardwareNoiseModel()
noise_model.add_gate_error("cx", simq.DepolarizingChannel(0.01))
# Simulate with noise
config = simq.SimulatorConfig(noise_model=noise_model, shots=1000)
simulator = simq.Simulator(config)
result = simulator.run(circuit)
A complete, commented walkthrough lives in
simq-py/examples/noise_simulation.py —
it builds noise channels, attaches them to a hardware model, and compares
noisy versus ideal measurement distributions.
Tips¶
Start with a single
DepolarizingChannelon two-qubit gates — they dominate error budgets on real devices.Use
SimulatorConfig(seed=...)for reproducible noisy runs when debugging.Readout error is often the largest effect on shallow circuits; model it separately from gate noise.