gulps.analysis.viz.polytope_viz.plot_waypoints

gulps.analysis.viz.polytope_viz.plot_waypoints(decomposer, target)[source]

Draw each backward waypoint selection of a compiled target in its own Weyl chamber.

The panels run from the target toward the identity. Each shows the prefix region, the backward region through the inverse of the next native gate, their intersection, and the class the compiler chose in it. The last panel has no choice: its prefix region is the class of the first native gate, joined to the identity by a dashed segment. The classes are read from the compiled circuit.

Parameters:
  • decomposer (GulpsDecomposer) – The decomposer that compiles target.

  • target (Gate | Operator | np.ndarray) – A two-qubit unitary that decomposer accepts.

Returns:

The figure.

Raises:

ValueError – If the compiled circuit has fewer than two native gates, so there is no backward step to draw.

Return type:

matplotlib.figure.Figure