Note

This is the documentation for the current state of the development branch of Qiskit Experiments. The documentation or APIs here can change prior to being released.

LocalReadoutErrorAnalysis

class LocalReadoutErrorAnalysis[source]

Local readout error characterization analysis

Overview

This class generates the assignment matrices characterizing the readout error for each of the given qubits from the experiment result, and returns the resulting LocalReadoutMitigator

Each such matrix is a 2×2 matrix A. Such that Ay,x is the probability to observe y given the true outcome should be x, where x,y{0,1} can be 0 and 1.

In the experiment, two circuits are constructed - one for 0 outcome for all qubits and one for 1 outcome. From the observed results on the circuit, the probability for each x,y is determined, and Ay,x is set accordingly.

Analysis Results:
Analysis Figures:
  • (Optional) A figure of the assignment matrix. Note: producing this figure scales exponentially with the number of qubits.

References

[1] Sergey Bravyi, Sarah Sheldon, Abhinav Kandala, David C. Mckay, Jay M. Gambetta, Mitigating measurement errors in multi-qubit experiments, Phys. Rev. A 103, 042605 (2021), doi: 10.1103/PhysRevA.103.042605 (open)

Analysis options

These are the keyword arguments of run() method.

Options
  • Defined in the class LocalReadoutErrorAnalysis:

    • plot (bool)

      Default value: False
      Set True to create figure for fit result.
    • ax (AxesSubplot)

      Default value: None
      Optional. A matplotlib axis object to draw.
  • Defined in the class BaseAnalysis:

    • figure_names (str or List[str])

      Default value: None
      Identifier of figures that appear in the experiment data to sort figures by name.

Initialization

Initialize the analysis object.

Attributes

LocalReadoutErrorAnalysis.options

Return the analysis options for run() method.

Methods

LocalReadoutErrorAnalysis.config()

Return the config dataclass for this analysis

LocalReadoutErrorAnalysis.copy()

Return a copy of the analysis

LocalReadoutErrorAnalysis.from_config(config)

Initialize an analysis class from analysis config

LocalReadoutErrorAnalysis.run(experiment_data)

Run analysis and update ExperimentData with analysis result.

LocalReadoutErrorAnalysis.set_options(**fields)

Set the analysis options for run() method.