Skip to content

Commit

Permalink
Avoid dtype duplication
Browse files Browse the repository at this point in the history
  • Loading branch information
andrea-pasquale committed Oct 25, 2023
1 parent 7ae98fb commit 60e81e5
Showing 1 changed file with 2 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
)

from .dispersive_shift import DispersiveShiftData, DispersiveShiftParameters
from .resonator_spectroscopy import ResSpecType


@dataclass
Expand Down Expand Up @@ -59,13 +60,6 @@ def state_two(self):
return {key: value for key, value in asdict(self).items() if "two" in key}


DispersiveShiftQutritType = np.dtype(
[
("freq", np.float64),
("msr", np.float64),
("phase", np.float64),
]
)
"""Custom dtype for rabi amplitude."""


Expand Down Expand Up @@ -115,7 +109,6 @@ def _acquisition(
-params.freq_width // 2, params.freq_width // 2, params.freq_step
)

# create a DataUnits objects to store the results
data = DispersiveShiftQutritData(resonator_type=platform.resonator_type)

for state, sequence in enumerate([sequence_0, sequence_1, sequence_2]):
Expand All @@ -142,7 +135,7 @@ def _acquisition(
result = results[sequence.ro_pulses[qubit].serial]
# store the results
data.register_qubit(
DispersiveShiftQutritType,
ResSpecType,
(qubit, state),
dict(
freq=sequence.ro_pulses[qubit].frequency + delta_frequency_range,
Expand Down

0 comments on commit 60e81e5

Please sign in to comment.