Skip to content

Cross resonance protocols for 0.2 version#1131

Closed
andrea-pasquale wants to merge 41 commits into
mainfrom
cr_gate
Closed

Cross resonance protocols for 0.2 version#1131
andrea-pasquale wants to merge 41 commits into
mainfrom
cr_gate

Conversation

@andrea-pasquale

Copy link
Copy Markdown
Contributor

In this PR I'm planning to convert the protocols for cross-resonance to the 0.2 version.
Right now this PR includes only one routine where I sweep the duration of the cross-resonance pulse cross_resonance_length.
I was able to verify the implementation of the protocol using qiboteam/qibolab#1186 with the platform qutrits which I have uploaded in this PR (which is based on some parameters from IBM chips).
Here is a report with the protocol: http://login.qrccluster.com:9000/V_RjRIyXT66pwqcRvCdukQ==/

@codecov

codecov Bot commented Apr 4, 2025

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 97.80%. Comparing base (66b0441) to head (695ee29).
⚠️ Report is 285 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #1131      +/-   ##
==========================================
+ Coverage   97.69%   97.80%   +0.10%     
==========================================
  Files         126      134       +8     
  Lines        9293     9736     +443     
==========================================
+ Hits         9079     9522     +443     
  Misses        214      214              
Flag Coverage Δ
unittests 97.80% <100.00%> (+0.10%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
src/qibocal/auto/transpile.py 88.73% <100.00%> (ø)
src/qibocal/protocols/rabi/utils.py 100.00% <100.00%> (ø)
...ibocal/protocols/two_qubit_interaction/__init__.py 100.00% <100.00%> (ø)
.../two_qubit_interaction/cross_resonance/__init__.py 100.00% <100.00%> (ø)
...two_qubit_interaction/cross_resonance/amplitude.py 100.00% <100.00%> (ø)
...cross_resonance/hamiltonian_tomography/__init__.py 100.00% <100.00%> (ø)
.../cross_resonance/hamiltonian_tomography/fitting.py 100.00% <100.00%> (ø)
...n/cross_resonance/hamiltonian_tomography/length.py 100.00% <100.00%> (ø)
...on/cross_resonance/hamiltonian_tomography/utils.py 100.00% <100.00%> (ø)
...ls/two_qubit_interaction/cross_resonance/length.py 100.00% <100.00%> (ø)
... and 1 more

... and 1 file with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@andrea-pasquale andrea-pasquale changed the base branch from main to drive_extra April 8, 2025 14:13
Base automatically changed from drive_extra to main April 11, 2025 09:04
@andrea-pasquale

Copy link
Copy Markdown
Contributor Author

In 92fc0ac I added the possibility to run the CR calibration experiments with the echoCR from this paper.
It seems to work as expected (since the target qubit now oscillates roughly at the same frequency).
Screenshot 2025-04-18 at 10 17 59
I'm planning to verify a preliminary CNOT gate which the eCR and later adding the cancellation tone on the target qubit presented in https://arxiv.org/abs/1603.04821

@andrea-pasquale

Copy link
Copy Markdown
Contributor Author

Just a quick update.
Through some protocols that perform also state tomography I was able to compute all terms in the effective Hamiltonian (using the emulator).
http://login.qrccluster.com:9000/9UYS4YKvS6WsPvFBLjYqVg==/
These are relevant when calibrating the CR gate.

@andrea-pasquale andrea-pasquale changed the title Cross resonance protocol for 0.2 version Cross resonance protocols for 0.2 version Apr 28, 2025
@andrea-pasquale

andrea-pasquale commented Apr 29, 2025

Copy link
Copy Markdown
Contributor Author

Using the echo CR gate I just pushed to the emulator a preliminary CNOT gate with which I was able to generate a Bell state with roughly 93% fidelity.
http://login.qrccluster.com:9000/S27TXCdVSqKHXtEy7Wxf3g==/
Results can (and should be) improved using several things which are already available in this PR such has:

  1. Use GaussianSquare pulses instead of Rectangular ones to reduce leakage
  2. Calibrate the phase of the CR pulse
  3. Calibrate the cancellation tone on the target qubit

Finally, we are missing the calibration of the Drag component which I will probably do in another PR. For the time being I will try to polish the code, so that people can review the PR as soon as possible.

@andrea-pasquale andrea-pasquale marked this pull request as ready for review April 30, 2025 06:57
@andrea-pasquale andrea-pasquale self-assigned this Apr 30, 2025
@andrea-pasquale andrea-pasquale linked an issue Apr 30, 2025 that may be closed by this pull request

@Edoardo-Pedicillo Edoardo-Pedicillo left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @andrea-pasquale , it looks good to me.

@alecandido

Copy link
Copy Markdown
Member

In 92fc0ac I added the possibility to run the CR calibration experiments with the echoCR from this paper. It seems to work as expected (since the target qubit now oscillates roughly at the same frequency). Screenshot 2025-04-18 at 10 17 59 I'm planning to verify a preliminary CNOT gate which the eCR and later adding the cancellation tone on the target qubit presented in arxiv.org/abs/1603.04821

I know this is not the only protocol in which it is done, but I'd propose to start changing it in here: could we use a scatter plot for the data, and a reserve the line plot just for the fit?
(i.e. 4 lines in the picture should correspond to data, and I'm proposing to plot them as individual points - while the last 2 lines should correspond to fits, and those are fine as lines, as they are right now)

@Edoardo-Pedicillo Edoardo-Pedicillo added this to the Qibocal 0.2.3 milestone Jun 19, 2025
@Edoardo-Pedicillo Edoardo-Pedicillo modified the milestones: Qibocal 0.2.3, Qibocal 0.2.4 Jul 21, 2025
@jevillegasd jevillegasd requested review from jevillegasd and removed request for jevillegasdatTII February 4, 2026 08:46
@alecandido

Copy link
Copy Markdown
Member

Superseded by #1414

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Cross Resonance Routine

5 participants