Skip to content

Commit

Permalink
Merge pull request #621 from qiboteam/fix_msr
Browse files Browse the repository at this point in the history
msr->signal in runcards
  • Loading branch information
Edoardo-Pedicillo authored Nov 13, 2023
2 parents c246183 + 27f92f3 commit 1909add
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions runcards/monitor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ actions:

- id: t1
priority: 00
operation: t1_msr
operation: t1_signal
main: t2
parameters:
delay_before_readout_start: 50
Expand All @@ -13,7 +13,7 @@ actions:

- id: t2
priority: 10
operation: t2_msr
operation: t2_signal
main: readout characterization
parameters:
delay_between_pulses_start: 50
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ class QubitFluxResults(Results):
[
("freq", np.float64),
("bias", np.float64),
("msr", np.float64),
("signal", np.float64),
("phase", np.float64),
]
)
Expand All @@ -87,14 +87,14 @@ class QubitFluxData(Data):
data: dict[QubitId, npt.NDArray[QubitFluxType]] = field(default_factory=dict)
"""Raw data acquired."""

def register_qubit_track(self, qubit, freq, bias, msr, phase):
def register_qubit_track(self, qubit, freq, bias, signal, phase):
"""Store output for single qubit."""
# to be able to handle the 1D sweeper case
size = len(freq)
ar = np.empty(size, dtype=QubitFluxType)
ar["freq"] = freq
ar["bias"] = [bias] * size
ar["msr"] = msr
ar["signal"] = signal
ar["phase"] = phase
if qubit in self.data:
self.data[qubit] = np.rec.array(np.concatenate((self.data[qubit], ar)))
Expand Down Expand Up @@ -201,7 +201,7 @@ def _acquisition(
result = results[ro_pulses[qubit].serial]
data.register_qubit_track(
qubit,
msr=result.magnitude,
signal=result.magnitude,
phase=result.phase,
freq=delta_frequency_range + qd_pulses[qubit].frequency,
bias=bias + qubits[qubit].sweetspot,
Expand Down Expand Up @@ -240,13 +240,13 @@ def _fit(data: QubitFluxData) -> QubitFluxResults:

biases = qubit_data.bias
frequencies = qubit_data.freq
msr = qubit_data.msr
signal = qubit_data.signal

if data.resonator_type == "2D":
msr = -msr
signal = -signal

frequencies, biases = utils.image_to_curve(
frequencies, biases, msr, msr_mask=0.3
frequencies, biases, signal, signal_mask=0.3
)
max_c = biases[np.argmax(frequencies)]
min_c = biases[np.argmin(frequencies)]
Expand Down

0 comments on commit 1909add

Please sign in to comment.