iqm.benchmarks.utils_plots.plot_layout_fidelity_graph

iqm.benchmarks.utils_plots.plot_layout_fidelity_graph#

iqm.benchmarks.utils_plots.plot_layout_fidelity_graph(backend: str | IQMBackendBase, qubit_layouts: list[list[int]] | None = None, sq_metric: str = 'coherence', show_ghz_path: bool = False) Figure#

Plot a graph showing the quantum chip layout with fidelity information.

Creates a visualization of the quantum chip topology where nodes represent qubits and edges represent connections between qubits. Edge thickness indicates gate errors (thinner edges mean better fidelity) and selected qubits are highlighted in orange.

Parameters:
  • backend (str | IQMBackendBase) – The backend to visualize, either as a string name or an IQMBackendBase instance.

  • qubit_layouts (list[list[int]] | None) – List of qubit layouts where each layout is a list of qubit indices

  • sq_metric (str) – Optional single qubit metric to use for the visualization, can be either “fidelity”, “coherence”, or “readout”.

  • show_ghz_path (bool) – Whether to highlight the edges that are part of the GHZ state creation tree path.

Returns:

The generated figure object containing the graph visualization

Return type:

matplotlib.figure.Figure