Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhancements to DRAG calibration #1055

Merged
merged 6 commits into from
Jan 23, 2025
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
94 changes: 94 additions & 0 deletions doc/source/protocols/drag/drag.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
DRAG experiments
================

In this section we show how to run Ramsey experiments using Qibocal
andrea-pasquale marked this conversation as resolved.
Show resolved Hide resolved

.. _drag:


DRAG :cite:p:`Motzoi_2009, Gambetta_2011`: pulses can be used to lower both phase and leakage errors,
it consists in adding a quadrature component to the pulse which is proportional
to the time derivative of the phase component. Given a pulse with a phase component :math:`\Omega_x`
andrea-pasquale marked this conversation as resolved.
Show resolved Hide resolved
the quadrature component :math:`\Omega_y` is evaluated as

.. math::

\Omega_y (t) = \beta \frac{d\Omega_x}{dt} ,

where :math:`\beta` is a scaling parameter.

Qibocal provides two separate protocols to extract :math:`\beta`.
andrea-pasquale marked this conversation as resolved.
Show resolved Hide resolved


Method 1
--------

:math:`\beta` can be extracted by playing the pulse sequence composed by
andrea-pasquale marked this conversation as resolved.
Show resolved Hide resolved
:math:`[R_X(\pi) - R_X(-\pi)]^N` for different values of :math:`\beta` as shown in :cite:p:`Sheldon_2016`.
The post-processing consists in measuring the probability of :math:`\ket{0}` for every :math:`\beta`
andrea-pasquale marked this conversation as resolved.
Show resolved Hide resolved
and fitting the curve with a cosine. The correct :math:`\beta` value is the one which maximizes
the curve.

Parameters
^^^^^^^^^^

.. autoclass:: qibocal.protocols.drag.DragTuningParameters
:noindex:

Example
^^^^^^^

.. code-block:: yaml

- id: drag tuning
operation: drag_tuning
parameters:
beta_start: -1
beta_end: 1
beta_step: 0.1
nflips: 5
unrolling: true


Running this protocol you should get something like this:

.. image:: drag_tuning.png


Method 2
--------

The second method consists in playing two different sequences
:math:`R_Y(\pi) R_X(\pi/2)` and :math:`R_X(\pi) R_Y(\pi/2)` which are two
of the AllXY pulses which exhibit opposite sign of phase error as highlighted
in :cite:p:`reed2013entanglementquantumerrorcorrection`.
andrea-pasquale marked this conversation as resolved.
Show resolved Hide resolved
The post-processing consists in measuring the probability of :math:`\ket{1}` for every :math:`\beta`
andrea-pasquale marked this conversation as resolved.
Show resolved Hide resolved
and performing a linear fit for both sequences. The correct :math:`\beta` value is the one where the two lines
cross.

Parameters
^^^^^^^^^^

.. autoclass:: qibocal.protocols.drag_simple.DragTuningSimpleParameters
:noindex:

Example
^^^^^^^

.. code-block:: yaml

- id: drag simple
operation: drag_simple
parameters:
beta_start: -1
beta_end: 1
beta_step: 0.1
unrolling: true

.. image:: drag_simple.png


Requirements
^^^^^^^^^^^^

- :ref:`single-shot`
Binary file added doc/source/protocols/drag/drag_simple.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/source/protocols/drag/drag_tuning.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions doc/source/protocols/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ In this section we introduce the basics of all protocols supported by ``qibocal`
dispersive_shift
allxy
flipping
drag/drag
readout_mitigation_matrix
readout_optimization
standard_rb
Expand Down
50 changes: 50 additions & 0 deletions doc/source/refs.bib
Original file line number Diff line number Diff line change
Expand Up @@ -190,3 +190,53 @@ @article{Nielsen_2002
author={Nielsen, Michael A},
year={2002},
month=oct, pages={249–252} }

@article{Motzoi_2009,
title={Simple Pulses for Elimination of Leakage in Weakly Nonlinear Qubits},
volume={103},
ISSN={1079-7114},
url={http://dx.doi.org/10.1103/PhysRevLett.103.110501},
DOI={10.1103/physrevlett.103.110501},
number={11},
journal={Physical Review Letters},
publisher={American Physical Society (APS)},
author={Motzoi, F. and Gambetta, J. M. and Rebentrost, P. and Wilhelm, F. K.},
year={2009},
month=sep }


@article{Gambetta_2011,
title={Analytic control methods for high-fidelity unitary operations in a weakly nonlinear oscillator},
volume={83},
ISSN={1094-1622},
url={http://dx.doi.org/10.1103/PhysRevA.83.012308},
DOI={10.1103/physreva.83.012308},
number={1},
journal={Physical Review A},
publisher={American Physical Society (APS)},
author={Gambetta, J. M. and Motzoi, F. and Merkel, S. T. and Wilhelm, F. K.},
year={2011},
month=jan }

@article{Sheldon_2016,
title={Characterizing errors on qubit operations via iterative randomized benchmarking},
volume={93},
ISSN={2469-9934},
url={http://dx.doi.org/10.1103/PhysRevA.93.012301},
DOI={10.1103/physreva.93.012301},
number={1},
journal={Physical Review A},
publisher={American Physical Society (APS)},
author={Sheldon, Sarah and Bishop, Lev S. and Magesan, Easwar and Filipp, Stefan and Chow, Jerry M. and Gambetta, Jay M.},
year={2016},
month=jan }

@misc{reed2013entanglementquantumerrorcorrection,
title={Entanglement and Quantum Error Correction with Superconducting Qubits},
author={Matthew Reed},
year={2013},
eprint={1311.6759},
archivePrefix={arXiv},
primaryClass={quant-ph},
url={https://arxiv.org/abs/1311.6759},
}
2 changes: 2 additions & 0 deletions src/qibocal/protocols/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
from .dispersive_shift import dispersive_shift
from .dispersive_shift_qutrit import dispersive_shift_qutrit
from .drag import drag_tuning
from .drag_simple import drag_simple
from .flipping import flipping
from .flux_dependence.qubit_crosstalk import qubit_crosstalk
from .flux_dependence.qubit_flux_dependence import qubit_flux
Expand Down Expand Up @@ -104,4 +105,5 @@
"standard_rb_2q_inter",
"optimize_two_qubit_gate",
"ramsey_zz",
"drag_simple",
]
16 changes: 12 additions & 4 deletions src/qibocal/protocols/drag.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ class DragTuningParameters(Parameters):
unrolling: bool = False
"""If ``True`` it uses sequence unrolling to deploy multiple sequences in a single instrument call.
Defaults to ``False``."""
nflips: int = 1
"""Repetitions of (Xpi - Xmpi)."""


@dataclass
Expand Down Expand Up @@ -97,11 +99,17 @@ def _acquisition(
)
drag_negative = replace(drag, relative_phase=np.pi)

# TODO: here we can add pairs of this in a for loop
sequence.append((qd_channel, drag))
sequence.append((qd_channel, drag_negative))
for _ in range(params.nflips):
sequence.append((qd_channel, drag))
sequence.append((qd_channel, drag_negative))
sequence.append(
(ro_channel, Delay(duration=drag.duration + drag_negative.duration))
(
ro_channel,
Delay(
duration=params.nflips
* (drag.duration + drag_negative.duration)
),
)
)
sequence.append((ro_channel, ro_pulse))

Expand Down
Loading
Loading