quantumlib / Cirq

A Python framework for creating, editing, and invoking Noisy Intermediate Scale Quantum (NISQ) circuits.
Apache License 2.0
4.24k stars 1.01k forks source link

Create workflow for Z-phase calibration #6728

Open NoureldinYosri opened 2 weeks ago

NoureldinYosri commented 2 weeks ago

This calibration workflow is created for excitation preserving 2-qubit gates and assumes an error model that can be described with small random z-rotations

0: ───Rz(a)───two_qubit_gate───Rz(c)───
                │
1: ───Rz(b)───two_qubit_gate───Rz(d)───

for some small angles a, b, c, and d.


when the error model doesn't apply the workflow may give absured numbers (e.g. fidilities $\notin [0, 1]$). The fidilities can be slightly outside the $[0, 1]$ interval because it's a statistical estimate as can be seen in the following figure which compares the estimated fidelity of a CZ surrounded by random z rotations before and after calibration image

test notebook: https://colab.sandbox.google.com/drive/10gZ5dggYKH_xSsCJFpg__GakxvoaZDIi

codecov[bot] commented 1 week ago

Codecov Report

Attention: Patch coverage is 96.03960% with 4 lines in your changes missing coverage. Please review.

Project coverage is 97.83%. Comparing base (bb24dae) to head (87cb95a). Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
cirq-core/cirq/experiments/z_phase_calibration.py 89.65% 3 Missing :warning:
cirq-core/cirq/experiments/two_qubit_xeb.py 0.00% 1 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #6728 +/- ## ========================================== - Coverage 97.83% 97.83% -0.01% ========================================== Files 1077 1079 +2 Lines 92537 92659 +122 ========================================== + Hits 90535 90652 +117 - Misses 2002 2007 +5 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.