# qiskit_aer.noise.NoiseModel.from_backend¶

classmethod NoiseModel.from_backend(backend, gate_error=True, readout_error=True, thermal_relaxation=True, temperature=0, gate_lengths=None, gate_length_units='ns', warnings=None)[source]

Return a noise model derived from a devices backend properties.

This function generates a noise model based on:

The error (noise) parameters are tuned for each individual qubit based on the $$T_1$$, $$T_2$$, frequency and readout error parameters for each qubit, and the gate error and gate time parameters for each gate obtained from the device backend properties.

Note that if un-physical parameters are supplied, they are internally truncated to the theoretical bound values. For example, if $$T_2 > 2 T_1$$, $$T_2$$ parameter will be truncated to $$2 T_1$$.

The noise model includes the following errors:

For best practice in simulating a backend make sure that the circuit is compiled using the set of basis gates in the noise module by setting basis_gates=noise_model.basis_gates and using the device coupling map with coupling_map=backend.configuration().coupling_map

Specifying custom gate times

The gate_lengths kwarg can be used to specify custom gate times to add gate errors using the $$T_1$$ and $$T_2$$ values from the backend properties. This should be passed as a list of tuples gate_lengths=[(name, value), ...] where name is the gate name string, and value is the gate time in nanoseconds.

If a custom gate is specified that already exists in the backend properties, the gate_lengths value will override the gate time value from the backend properties. If non-default values are used gate_lengths should be a list

Paramètres
• backend (Backend) – backend. For BackendV2, warnings options are ignored, and their default values are used.

• gate_error (bool) – Include depolarizing gate errors (Default: True).

• thermal_relaxation (Bool) – Include thermal relaxation errors (Default: True).

• temperature (double) – qubit temperature in milli-Kelvin (mK) for thermal relaxation errors (Default: 0).

• gate_lengths (list) – Custom gate times for thermal relaxation errors. Used to extend or override the gate times in the backend properties (Default: None))

• gate_length_units (str) – Time units for gate length values in gate_lengths. Can be “ns”, “ms”, “us”, or “s” (Default: “ns”).

• warnings (bool) – DEPRECATED, Display warnings (Default: None).

Renvoie

An approximate noise model for the device backend.

Type renvoyé

NoiseModel

Lève

NoiseError – If the input backend is not valid.