benchmark_gate

SimphonyBackend.benchmark_gate(gate, gateset, angle=1.5707963267948966, phase=0.0, verbose=False)

Benchmark the pulse implementation of a single native gate.

Builds the gate’s pulses on a copy of the bound model, simulates them, and compares the result against the gate they were meant to realize. A gate whose angle is free is benchmarked at the angle and axis given here.

Parameters:
  • gate (Gate) – Native gate to benchmark; must be one of gateset’s.

  • gateset (GateSet) – Gate set the gate belongs to.

  • angle (float) – Rotation angle to evaluate the gate at. Ignored by a gate whose angle is fixed.

  • phase (float) – Phase of the rotation axis to evaluate the gate at. Ignored by a gate that has no axis to place.

  • verbose (bool) – Whether the simulation prints its progress.

Return type:

float

Returns:

Average gate fidelity of the simulated pulse against the ideal gate, from

0 to 1.