qiskit_noise_learning.utils.build_with_prep_noise
qiskit_noise_learning.utils.build_with_prep_noise(circuit: QuantumCircuit, prep_noise_ref: str = 'prep', prep_modifier_ref: str = '') → tuple[QuantumCircuit, Samplex]
Build a template circuit with injectable preparation noise.
This function uses the normal samplex build path except adds an additional node for injectable preparation noise at the beginning of the circuit.
Parameters
- circuit – The annotated circuit to build.
- noise_ref – The name of the reference to the noise map.
- modifier_ref – The name used for the argument to modify the rates of the noise map.
Returns
The template circuit and the samplex.
Raises
ValueError – If the circuit does not begin with a left-dressed twirl annotated box.
Was this page helpful?
Report a bug, typo, or request content on GitHub.