Skip to main contentIBM Quantum Documentation
This page is from an old version of Qiskit SDK Go to the latest version
Important

IBM Quantum Platform is moving and this version will be sunset on July 1. To get started on the new platform, read the migration guide.

Visualizations

qiskit.visualization


Counts and State Visualizations

plot_histogram(data[, figsize, color, …])Plot a histogram of data.
plot_bloch_vector(bloch[, title, ax, …])Plot the Bloch sphere.
plot_bloch_multivector(state[, title, …])Plot the Bloch sphere.
plot_state_city(state[, title, figsize, …])Plot the cityscape of quantum state.
plot_state_hinton(state[, title, figsize, …])Plot a hinton diagram for the density matrix of a quantum state.
plot_state_paulivec(state[, title, figsize, …])Plot the paulivec representation of a quantum state.
plot_state_qsphere(state[, figsize, ax, …])Plot the qsphere representation of a quantum state.

Device Visualizations

plot_gate_map(backend[, figsize, …])Plots the gate map of a device.
plot_error_map(backend[, figsize, …])Plots the error map of a given backend.
plot_circuit_layout(circuit, backend[, …])Plot the layout of a circuit transpiled for a given target backend.
plot_coupling_map(num_qubits, …[, …])Plots an arbitrary coupling map of qubits (embedded in a plane).

Circuit Visualizations

circuit_drawer(circuit[, scale, filename, …])Draw the quantum circuit.
DefaultStyle()Creates a Default Style dictionary

DAG Visualizations

dag_drawer(dag[, scale, filename, style])Plot the directed acyclic graph (dag) to represent operation dependencies in a quantum circuit.

Pass Manager Visualizations

pass_manager_drawer(pass_manager[, …])Draws the pass manager.

Pulse Visualizations

draw(program[, style, backend, time_range, …])Generate visualization data for pulse programs.
IQXStandard(**kwargs)Standard pulse stylesheet.
IQXSimple(**kwargs)Simple pulse stylesheet without channel notation.
IQXDebugging(**kwargs)Pulse stylesheet for pulse programmers.

Timeline Visualizations

timeline_drawer(program[, style, …])Generate visualization data for scheduled circuit programs.
draw(program[, style, time_range, …])Generate visualization data for scheduled circuit programs.

Single Qubit State Transition Visualizations

visualize_transition(circuit[, trace, …])Creates animation showing transitions between states of a single qubit by applying quantum gates.

Array/Matrix Visualizations

array_to_latex(array[, precision, prefix, …])Latex representation of a complex numpy array (with dimension 1 or 2)

Exceptions

VisualizationError(*message)For visualization specific errors.
Was this page helpful?
Report a bug or request content on GitHub.