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

[Feature] - Multiple qubit measure lines in UHFQA in spectroscopy mode #10

Closed
1 of 2 tasks
YuanG13 opened this issue Nov 4, 2022 · 11 comments
Closed
1 of 2 tasks
Assignees
Labels
enhancement New feature or request jira Sync the issue to ZI LabOneQ internal issue tracker.

Comments

@YuanG13
Copy link

YuanG13 commented Nov 4, 2022

Describe the bug
with experiment using UHFQA, and spectroscopy mode, get compilation error : Attempting to multiplex several HW-modulated signals (measure_0, measure_1) on uhfqa, which does not support oscillator switching.

in the experiment, there are 2 qubits sharing the same physical measure line, but in SignalCalibration only one is assigned an Oscillator with ModulationType.HARDWARE, the other is assigned an Oscillator with ModulationType.SOFTWARE.

The error raised from laboneq/compiler/code_generator/analyze_events.py", line 418, in analyze_oscillator_switch_events
and the reason is that in line405, hw_oscillators contains both signals even one of them has signals[signal_id].hw_oscillator=None, and the code thinks there are two different hardware oscillators.

To Reproduce
Steps to reproduce the behavior:

  1. Define pulse sequence...
  2. Execute on hardware / in emulation ...
  3. Do additional steps...
  4. See error
    example.zip

Expected behavior
do not add the signal to the dictionary if the hardware oscillator is None

Code & Screenshots
If possible, add example code or serialized LabOne Q data objects, like the Experiment and DeviceSetup, that allow us to reproduce the behavior.
If applicable, add screenshots to help explain your problem.

Versions used:

  • laboneq 1.2

Context

  • Do you know a workaround for the issue? If yes, please provide a short description.
  • Does the issue block your experiments?
@QuantumClemens
Copy link
Collaborator

Hi @YuanG13 - thanks for reporting this.
This may be intended behavior, since in spectroscopy mode, multiplexing of measurement signals is not possible - i.e. the issue here is that in spectroscopy mode it is not possible to use multiple measurement signals.
What exactly are your trying to do with this experiment?

@QuantumClemens QuantumClemens self-assigned this Nov 7, 2022
@YuanG13
Copy link
Author

YuanG13 commented Nov 7, 2022

Yes, but only one qubit is intended and meant to be measured in that experiment. Since we are using qiskit circuits, if a nexperiment contains coupler but only one qubit is measured, which has longer measure pulse time (>2.3us, for example fluxonium), the circuit should contains 2 qubits and the meas_level is spectroscopy.

However regardless the experiment, counting Nonetype as an additional hardware oscillator seems too strict.

@QuantumClemens
Copy link
Collaborator

I agree that we should probably improve the error message in this case, but as I understand the issue, this appears because there are two measurment lines in the experiment?
From the files you provided that is the case, there are measure_0 and measure_1 as well as acquire_0 and acquire_1 - what happens when you remove those additional, unused lines from the experiment?

@YuanG13
Copy link
Author

YuanG13 commented Nov 7, 2022

Yes there are two lines, but only one Hardware oscillator is assigned, the other one is not assigned with any Hardware oscillator(None), as I described in the description. It should not be counted as multiplexing since only one frequency is involved.

@QuantumClemens
Copy link
Collaborator

@YuanG13 using one line with hardware and another one with software oscillator is not possible in spectroscopy mode, you can only use a single readout line with hardware modulation in this mode.
As mentioned earlier, the error message in this case is likely misleading. But it seems what you are trying to do might not be possible on the hardware.

@YuanG13
Copy link
Author

YuanG13 commented Nov 7, 2022

But the experiment I am showing was running correctly before.

Is it possible that we have a measure_1 but do not assign any oscillator to it(None)?

@QuantumClemens
Copy link
Collaborator

Yes, that is possible, if you do not assign an oscillator in the SignalCalibration, it will default to None.
Can you clarify for me again, what you are attempting to do on the second measure line, the one with the software modulation?

@YuanG13
Copy link
Author

YuanG13 commented Nov 7, 2022

Nothing will do on that measure_1 and acquire_1. But the drive_1, flux_1 might have pulses.

So we either assign a None oscillator to the SignalCalibration of measure_1, acquire_1, or do not define SignalCalibration for measure_1, acquire_1 while still keep drive_1, flux_1 the same. Which one should be more reasonable from your perspective?

@QuantumClemens
Copy link
Collaborator

I would suggest to remove the measure_1 and acquire_1 signal lines from the experiment. Then it should work already now, but as long as the lines are defined, their properties will be checked for conflicts with possible behavior. In this case one conflict will be that measurement multiplexing is not possible in spectroscopy mode.

@QuantumClemens QuantumClemens added the enhancement New feature or request label Dec 14, 2022
@QuantumClemens
Copy link
Collaborator

@YuanG13 - I will change this into a feature, since we will be adding functionality here, and I believe there is a simple workaround for the moment. This is planned as part of the integration of qubit objects as high level experiment objects, which is currently being planned

@QuantumClemens QuantumClemens changed the title [BUG] - Multiple qubit measure lines in UHFQA in spectroscopy mode [Feature] - Multiple qubit measure lines in UHFQA in spectroscopy mode Dec 14, 2022
@mforoozandeh mforoozandeh added the jira Sync the issue to ZI LabOneQ internal issue tracker. label Jun 20, 2023
@QianmuZI
Copy link
Collaborator

Hi @YuanG13, as discussed, we close this ticket.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request jira Sync the issue to ZI LabOneQ internal issue tracker.
Projects
None yet
Development

No branches or pull requests

4 participants