def canonical_coords(gate: Gate) -> Sequence[float]:
    """Returns the canonical coordinates of a 2-qubit gate"""
    circ = canonical_decomposition(gate)
    gate = circ.elements[6]  # type: ignore
    params = [gate.params[key] for key in ('tx', 'ty', 'tz')]
    return params
def canonical_coords ( gate : Gate ) -> Sequence [ float ] : circ = canonical_decomposition ( gate ) gate = circ . elements [ 6 ] params = [ gate . params [ key ] for key in ( 'tx' , 'ty' , 'tz' ) ] return params
Returns the canonical coordinates of a 2-qubit gate