qilimanjaro-tech / qililab

Qililab is a generic and scalable quantum control library used for fast characterization and calibration of quantum chips. Qililab also offers the ability to execute high-level quantum algorithms with your quantum hardware.
Apache License 2.0
30 stars 2 forks source link

Extracted sync from upload_qpysequence into an independent line #697

Closed jordivallsq closed 6 months ago

jordivallsq commented 6 months ago

Moved the sync outside of upload_qpysequence in Qblox_module into an independent function sync_sequencers located in the same .py file mirroring the function desync_sequencers and added 3 lines in platform.py to also mirror the desync and sync every time the execution is ran.

jordivallsq commented 6 months ago

The code has been checked with 2 different pulses from different sequencers in a software loop. This is the n step of a software loop where we can see how both pulses are in sync: imagen

The sequencers used are:

                wait_sync        4              

main:
                move             200, R0        
avg_0:
                wait             2000           
                wait             4              
                play             0, 1, 4        
                acquire_weighed  0, 0, 0, 0, 2000
                wait             200            
                loop             R0, @avg_0     
                stop                            

[qililab] [0.23.3|INFO|2024-03-06 10:18:25]: Sequence program: 
 setup:
                wait_sync        4              

main:
                move             200, R0        
avg_0:
                play             0, 1, 2000     
                wait             2208           
                loop             R0, @avg_0     
                stop     

We can see how the sequencers structure follow the pulses distribution

Using Qililab main we are not able to see one of the colors in the image, only one is seen because they desync

github-actions[bot] commented 6 months ago

Hello. You may have forgotten to update the changelog! Please edit changelog-dev.md with:

codecov[bot] commented 6 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 96.16%. Comparing base (2e0bf29) to head (f2ebba7).

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #697 +/- ## ======================================= Coverage 96.16% 96.16% ======================================= Files 273 273 Lines 9046 9057 +11 ======================================= + Hits 8699 8710 +11 Misses 347 347 ``` | [Flag](https://app.codecov.io/gh/qilimanjaro-tech/qililab/pull/697/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=qilimanjaro-tech) | Coverage Δ | | |---|---|---| | [unittests](https://app.codecov.io/gh/qilimanjaro-tech/qililab/pull/697/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=qilimanjaro-tech) | `96.16% <100.00%> (+<0.01%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=qilimanjaro-tech#carryforward-flags-in-the-pull-request-comment) to find out more.

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