graphix.noise_models.amplitude_damping module

Amplitude damping noise model.

class AmplitudeDampingNoise(prob: float)[source]

Bases: Noise

One-qubit amplitude damping noise with damping parameter prob.

__init__(prob: float) → None[source]

Initialize one-qubit amplitude damping noise.

Parameters:

prob (float) – Damping parameter \(\\gamma\) of the noise, between 0 and 1.

prob

Descriptor for probability (between 0 and 1).

property nqubits: int

Return the number of qubits targetted by the noise element.

to_krauschannel() → KrausChannel[source]

Return the Kraus channel describing the noise element.

class TwoQubitAmplitudeDampingNoise(prob: float)[source]

Bases: Noise

Two-qubit amplitude damping noise with damping parameter prob.

__init__(prob: float) → None[source]

Initialize two-qubit amplitude damping noise.

Parameters:

prob (float) – Damping parameter \(\\gamma\) of the noise, between 0 and 1.

prob

Descriptor for probability (between 0 and 1).

property nqubits: int

Return the number of qubits targetted by the noise element.

to_krauschannel() → KrausChannel[source]

Return the Kraus channel describing the noise element.

class AmplitudeDampingNoiseModel(prepare_error_prob: float = 0.0, x_error_prob: float = 0.0, z_error_prob: float = 0.0, entanglement_error_prob: float = 0.0, measure_channel_prob: float = 0.0, measure_error_prob: float = 0.0)[source]

Bases: NoiseModel

Amplitude damping noise model.

Parameters:

NoiseModel (class) – Parent abstract class class:NoiseModel

__init__(prepare_error_prob: float = 0.0, x_error_prob: float = 0.0, z_error_prob: float = 0.0, entanglement_error_prob: float = 0.0, measure_channel_prob: float = 0.0, measure_error_prob: float = 0.0) → None[source]
input_nodes(nodes: Iterable[int], rng: Generator | None = None, *, stacklevel: int = 1) → list[CommandOrNoise][source]

Return the noise to apply to input nodes.

command(cmd: CommandOrNoise, rng: Generator | None = None, *, stacklevel: int = 1) → list[CommandOrNoise][source]

Return the noise to apply to the command cmd.

confuse_result(cmd: BaseM, result: Outcome, rng: Generator | None = None, *, stacklevel: int = 1) → Outcome[source]

Assign wrong measurement result with probability measure_error_prob.