qibocal.protocols package#
Subpackages#
- qibocal.protocols.allxy package
- Submodules
- qibocal.protocols.allxy.allxy module
- qibocal.protocols.allxy.allxy_drag_pulse_tuning module
- qibocal.protocols.allxy.allxy_resonator_depletion_tuning module
AllXYResonatorParameters
AllXYResonatorResults
AllXYResonatorData
AllXYResonatorData.delay_param
AllXYResonatorData.data
AllXYResonatorData._to_json()
AllXYResonatorData._to_npz()
AllXYResonatorData.delay_params
AllXYResonatorData.load_data()
AllXYResonatorData.load_params()
AllXYResonatorData.pairs
AllXYResonatorData.params
AllXYResonatorData.qubits
AllXYResonatorData.register_qubit()
AllXYResonatorData.save()
_acquisition()
_fit()
_plot()
allxy_resonator_depletion_tuning
- qibocal.protocols.coherence package
- Submodules
- qibocal.protocols.coherence.spin_echo module
- qibocal.protocols.coherence.spin_echo_signal module
SpinEchoSignalParameters
SpinEchoSignalParameters.delay_between_pulses_start
SpinEchoSignalParameters.delay_between_pulses_end
SpinEchoSignalParameters.delay_between_pulses_step
SpinEchoSignalParameters.unrolling
SpinEchoSignalParameters.single_shot
SpinEchoSignalParameters.hardware_average
SpinEchoSignalParameters.nshots
SpinEchoSignalParameters.relaxation_time
SpinEchoSignalResults
SpinEchoSignalData
SpinEchoSignalData._to_json()
SpinEchoSignalData._to_npz()
SpinEchoSignalData.average
SpinEchoSignalData.load_data()
SpinEchoSignalData.load_params()
SpinEchoSignalData.pairs
SpinEchoSignalData.params
SpinEchoSignalData.qubits
SpinEchoSignalData.register_qubit()
SpinEchoSignalData.save()
SpinEchoSignalData.data
_acquisition()
_fit()
_plot()
_update()
spin_echo_signal
- qibocal.protocols.coherence.t1 module
- qibocal.protocols.coherence.t1_sequences module
- qibocal.protocols.coherence.t1_signal module
- qibocal.protocols.coherence.t2 module
- qibocal.protocols.coherence.t2_sequences module
- qibocal.protocols.coherence.t2_signal module
- qibocal.protocols.coherence.utils module
- qibocal.protocols.coherence.zeno module
- qibocal.protocols.coherence.zeno_signal module
- qibocal.protocols.couplers package
- Submodules
- qibocal.protocols.couplers.coupler_chevron module
- qibocal.protocols.couplers.coupler_qubit_spectroscopy module
CouplerSpectroscopyParametersQubit
CouplerSpectroscopyParametersQubit.drive_duration
CouplerSpectroscopyParametersQubit.amplitude
CouplerSpectroscopyParametersQubit.bias_step
CouplerSpectroscopyParametersQubit.bias_width
CouplerSpectroscopyParametersQubit.hardware_average
CouplerSpectroscopyParametersQubit.measured_qubits
CouplerSpectroscopyParametersQubit.freq_width
CouplerSpectroscopyParametersQubit.freq_step
CouplerSpectroscopyParametersQubit.nshots
CouplerSpectroscopyParametersQubit.relaxation_time
_acquisition()
coupler_qubit_spectroscopy
- qibocal.protocols.couplers.coupler_resonator_spectroscopy module
- qibocal.protocols.couplers.utils module
CouplerSpectroscopyParameters
CouplerSpectroscopyParameters.measured_qubits
CouplerSpectroscopyParameters.amplitude
CouplerSpectroscopyParameters.bias_step
CouplerSpectroscopyParameters.bias_width
CouplerSpectroscopyParameters.hardware_average
CouplerSpectroscopyParameters.freq_width
CouplerSpectroscopyParameters.freq_step
CouplerSpectroscopyParameters.nshots
CouplerSpectroscopyParameters.relaxation_time
CouplerSpecType
CouplerSpectroscopyResults
CouplerSpectroscopyResults.sweetspot
CouplerSpectroscopyResults.pulse_amp
CouplerSpectroscopyResults._to_json()
CouplerSpectroscopyResults._to_npz()
CouplerSpectroscopyResults.load_data()
CouplerSpectroscopyResults.load_params()
CouplerSpectroscopyResults.params
CouplerSpectroscopyResults.save()
CouplerSpectroscopyResults.fitted_parameters
CouplerSpectroscopyData
CouplerSpectroscopyData._to_json()
CouplerSpectroscopyData._to_npz()
CouplerSpectroscopyData.load_data()
CouplerSpectroscopyData.load_params()
CouplerSpectroscopyData.pairs
CouplerSpectroscopyData.params
CouplerSpectroscopyData.qubits
CouplerSpectroscopyData.save()
CouplerSpectroscopyData.resonator_type
CouplerSpectroscopyData.offset
CouplerSpectroscopyData.data
CouplerSpectroscopyData.register_qubit()
- qibocal.protocols.flux_dependence package
- Submodules
- qibocal.protocols.flux_dependence.avoided_crossing module
AvoidedCrossingParameters
AvoidedCrossingParameters.bias_step
AvoidedCrossingParameters.bias_width
AvoidedCrossingParameters.drive_amplitude
AvoidedCrossingParameters.drive_duration
AvoidedCrossingParameters.hardware_average
AvoidedCrossingParameters.transition
AvoidedCrossingParameters.freq_width
AvoidedCrossingParameters.freq_step
AvoidedCrossingParameters.nshots
AvoidedCrossingParameters.relaxation_time
AvoidedCrossingResults
AvoidedCrossingResults.parabolas
AvoidedCrossingResults.fits
AvoidedCrossingResults.cz
AvoidedCrossingResults.iswap
AvoidedCrossingResults._to_json()
AvoidedCrossingResults._to_npz()
AvoidedCrossingResults.load_data()
AvoidedCrossingResults.load_params()
AvoidedCrossingResults.params
AvoidedCrossingResults.save()
AvoidedCrossingData
AvoidedCrossingData.qubit_pairs
AvoidedCrossingData.drive_frequency_low
AvoidedCrossingData.data
AvoidedCrossingData._to_json()
AvoidedCrossingData._to_npz()
AvoidedCrossingData.load_data()
AvoidedCrossingData.load_params()
AvoidedCrossingData.pairs
AvoidedCrossingData.params
AvoidedCrossingData.qubits
AvoidedCrossingData.register_qubit()
AvoidedCrossingData.save()
_acquisition()
_fit()
_plot()
find_parabola()
solve_eq()
index()
Excitations
plot_heatmap()
plot_curves()
plot_intersections()
- qibocal.protocols.flux_dependence.qubit_crosstalk module
QubitCrosstalkParameters
QubitCrosstalkParameters.bias_point
QubitCrosstalkParameters.flux_qubits
QubitCrosstalkParameters.bias_step
QubitCrosstalkParameters.bias_width
QubitCrosstalkParameters.drive_amplitude
QubitCrosstalkParameters.drive_duration
QubitCrosstalkParameters.hardware_average
QubitCrosstalkParameters.transition
QubitCrosstalkParameters.freq_width
QubitCrosstalkParameters.freq_step
QubitCrosstalkParameters.nshots
QubitCrosstalkParameters.relaxation_time
QubitCrosstalkData
QubitCrosstalkData.matrix_element
QubitCrosstalkData.bias_point
QubitCrosstalkData.offset
QubitCrosstalkData.qubit_frequency
QubitCrosstalkData.data
QubitCrosstalkData.register_qubit()
QubitCrosstalkData.diagonal
QubitCrosstalkData._to_json()
QubitCrosstalkData._to_npz()
QubitCrosstalkData.load_data()
QubitCrosstalkData.load_params()
QubitCrosstalkData.pairs
QubitCrosstalkData.params
QubitCrosstalkData.qubits
QubitCrosstalkData.save()
QubitCrosstalkData.resonator_type
QubitCrosstalkData.charging_energy
QubitCrosstalkResults
QubitCrosstalkResults.qubit_frequency_bias_point
QubitCrosstalkResults._to_json()
QubitCrosstalkResults._to_npz()
QubitCrosstalkResults.load_data()
QubitCrosstalkResults.load_params()
QubitCrosstalkResults.params
QubitCrosstalkResults.save()
QubitCrosstalkResults.sweetspot
QubitCrosstalkResults.frequency
QubitCrosstalkResults.matrix_element
QubitCrosstalkResults.crosstalk_matrix
QubitCrosstalkResults.fitted_parameters
_acquisition()
_fit()
_plot()
_update()
qubit_crosstalk
- qibocal.protocols.flux_dependence.qubit_flux_dependence module
QubitFluxParameters
QubitFluxParameters.drive_amplitude
QubitFluxParameters.transition
QubitFluxParameters.drive_duration
QubitFluxParameters.bias_step
QubitFluxParameters.bias_width
QubitFluxParameters.hardware_average
QubitFluxParameters.freq_width
QubitFluxParameters.freq_step
QubitFluxParameters.nshots
QubitFluxParameters.relaxation_time
QubitFluxResults
QubitFluxType
QubitFluxData
QubitFluxData.resonator_type
QubitFluxData._to_json()
QubitFluxData._to_npz()
QubitFluxData.load_data()
QubitFluxData.load_params()
QubitFluxData.pairs
QubitFluxData.params
QubitFluxData.qubits
QubitFluxData.save()
QubitFluxData.charging_energy
QubitFluxData.qubit_frequency
QubitFluxData.data
QubitFluxData.register_qubit()
_acquisition()
_fit()
_plot()
_update()
qubit_flux
- qibocal.protocols.flux_dependence.qubit_flux_tracking module
QubitFluxTrackParameters
QubitFluxTrackParameters.bias_step
QubitFluxTrackParameters.bias_width
QubitFluxTrackParameters.drive_amplitude
QubitFluxTrackParameters.drive_duration
QubitFluxTrackParameters.hardware_average
QubitFluxTrackParameters.transition
QubitFluxTrackParameters.freq_width
QubitFluxTrackParameters.freq_step
QubitFluxTrackParameters.nshots
QubitFluxTrackParameters.relaxation_time
QubitFluxTrackResults
QubitFluxTrackResults.bias_step
QubitFluxTrackResults.bias_width
QubitFluxTrackResults.drive_amplitude
QubitFluxTrackResults.drive_duration
QubitFluxTrackResults.hardware_average
QubitFluxTrackResults.transition
QubitFluxTrackResults.freq_width
QubitFluxTrackResults.freq_step
QubitFluxTrackResults.nshots
QubitFluxTrackResults.relaxation_time
QubitFluxTrackData
QubitFluxTrackData.register_qubit_track()
QubitFluxTrackData._to_json()
QubitFluxTrackData._to_npz()
QubitFluxTrackData.load_data()
QubitFluxTrackData.load_params()
QubitFluxTrackData.pairs
QubitFluxTrackData.params
QubitFluxTrackData.qubits
QubitFluxTrackData.register_qubit()
QubitFluxTrackData.save()
QubitFluxTrackData.resonator_type
QubitFluxTrackData.charging_energy
QubitFluxTrackData.qubit_frequency
QubitFluxTrackData.data
_acquisition()
qubit_flux_tracking
- qibocal.protocols.flux_dependence.resonator_crosstalk module
ResCrosstalkParameters
ResCrosstalkParameters.bias_point
ResCrosstalkParameters.flux_qubits
ResCrosstalkParameters.bias_step
ResCrosstalkParameters.bias_width
ResCrosstalkParameters.hardware_average
ResCrosstalkParameters.freq_width
ResCrosstalkParameters.freq_step
ResCrosstalkParameters.nshots
ResCrosstalkParameters.relaxation_time
ResCrosstalkResults
ResCrosstalkResults.resonator_frequency_bias_point
ResCrosstalkResults.crosstalk_matrix
ResCrosstalkResults.fitted_parameters
ResCrosstalkResults._to_json()
ResCrosstalkResults._to_npz()
ResCrosstalkResults.load_data()
ResCrosstalkResults.load_params()
ResCrosstalkResults.params
ResCrosstalkResults.save()
ResCrosstalkResults.resonator_freq
ResCrosstalkResults.coupling
ResCrosstalkResults.asymmetry
ResCrosstalkResults.sweetspot
ResCrosstalkResults.matrix_element
ResCrosstalkData
ResCrosstalkData.coupling
ResCrosstalkData.bias_point
ResCrosstalkData.bare_resonator_frequency
ResCrosstalkData.resonator_frequency
ResCrosstalkData.matrix_element
ResCrosstalkData._to_json()
ResCrosstalkData._to_npz()
ResCrosstalkData.load_data()
ResCrosstalkData.load_params()
ResCrosstalkData.pairs
ResCrosstalkData.params
ResCrosstalkData.qubits
ResCrosstalkData.save()
ResCrosstalkData.resonator_type
ResCrosstalkData.qubit_frequency
ResCrosstalkData.charging_energy
ResCrosstalkData.offset
ResCrosstalkData.asymmetry
ResCrosstalkData.data
ResCrosstalkData.register_qubit()
ResCrosstalkData.diagonal
_acquisition()
_fit()
_plot()
_update()
resonator_crosstalk
- qibocal.protocols.flux_dependence.resonator_flux_dependence module
ResonatorFluxParameters
ResonatorFluxResults
ResonatorFluxResults.resonator_freq
ResonatorFluxResults.coupling
ResonatorFluxResults.asymmetry
ResonatorFluxResults.sweetspot
ResonatorFluxResults.matrix_element
ResonatorFluxResults.fitted_parameters
ResonatorFluxResults._to_json()
ResonatorFluxResults._to_npz()
ResonatorFluxResults.load_data()
ResonatorFluxResults.load_params()
ResonatorFluxResults.params
ResonatorFluxResults.save()
ResFluxType
ResonatorFluxData
ResonatorFluxData._to_json()
ResonatorFluxData._to_npz()
ResonatorFluxData.load_data()
ResonatorFluxData.load_params()
ResonatorFluxData.pairs
ResonatorFluxData.params
ResonatorFluxData.qubits
ResonatorFluxData.save()
ResonatorFluxData.resonator_type
ResonatorFluxData.qubit_frequency
ResonatorFluxData.bare_resonator_frequency
ResonatorFluxData.charging_energy
ResonatorFluxData.data
ResonatorFluxData.register_qubit()
_acquisition()
_fit()
_plot()
_update()
resonator_flux
- qibocal.protocols.flux_dependence.utils module
- qibocal.protocols.rabi package
- Submodules
- qibocal.protocols.rabi.amplitude module
RabiAmplitudeParameters
RabiAmplitudeResults
RabiAmplitudeResults.chi2
RabiAmplitudeResults._to_json()
RabiAmplitudeResults._to_npz()
RabiAmplitudeResults.load_data()
RabiAmplitudeResults.load_params()
RabiAmplitudeResults.params
RabiAmplitudeResults.save()
RabiAmplitudeResults.amplitude
RabiAmplitudeResults.length
RabiAmplitudeResults.fitted_parameters
RabiAmpType
RabiAmplitudeData
RabiAmplitudeData.durations
RabiAmplitudeData.data
RabiAmplitudeData._to_json()
RabiAmplitudeData._to_npz()
RabiAmplitudeData.load_data()
RabiAmplitudeData.load_params()
RabiAmplitudeData.pairs
RabiAmplitudeData.params
RabiAmplitudeData.qubits
RabiAmplitudeData.register_qubit()
RabiAmplitudeData.save()
_acquisition()
_fit()
_plot()
_update()
rabi_amplitude
- qibocal.protocols.rabi.amplitude_frequency module
RabiAmplitudeFrequencyParameters
RabiAmplitudeFrequencyParameters.hardware_average
RabiAmplitudeFrequencyParameters.pulse_length
RabiAmplitudeFrequencyParameters.min_amp_factor
RabiAmplitudeFrequencyParameters.max_amp_factor
RabiAmplitudeFrequencyParameters.step_amp_factor
RabiAmplitudeFrequencyParameters.min_freq
RabiAmplitudeFrequencyParameters.max_freq
RabiAmplitudeFrequencyParameters.step_freq
RabiAmplitudeFrequencyParameters.nshots
RabiAmplitudeFrequencyParameters.relaxation_time
RabiAmplitudeFrequencyResults
RabiAmplitudeFrequencyResults.chi2
RabiAmplitudeFrequencyResults._to_json()
RabiAmplitudeFrequencyResults._to_npz()
RabiAmplitudeFrequencyResults.load_data()
RabiAmplitudeFrequencyResults.load_params()
RabiAmplitudeFrequencyResults.params
RabiAmplitudeFrequencyResults.save()
RabiAmplitudeFrequencyResults.frequency
RabiAmplitudeFrequencyResults.amplitude
RabiAmplitudeFrequencyResults.length
RabiAmplitudeFrequencyResults.fitted_parameters
RabiAmpFreqType
RabiAmplitudeFreqData
RabiAmplitudeFreqData.data
RabiAmplitudeFreqData.register_qubit()
RabiAmplitudeFreqData._to_json()
RabiAmplitudeFreqData._to_npz()
RabiAmplitudeFreqData.amplitudes()
RabiAmplitudeFreqData.frequencies()
RabiAmplitudeFreqData.load_data()
RabiAmplitudeFreqData.load_params()
RabiAmplitudeFreqData.pairs
RabiAmplitudeFreqData.params
RabiAmplitudeFreqData.qubits
RabiAmplitudeFreqData.save()
RabiAmplitudeFreqData.durations
_acquisition()
_fit()
_plot()
rabi_amplitude_frequency
- qibocal.protocols.rabi.amplitude_frequency_signal module
RabiAmplitudeFrequencySignalParameters
RabiAmplitudeFrequencySignalParameters.min_amp_factor
RabiAmplitudeFrequencySignalParameters.max_amp_factor
RabiAmplitudeFrequencySignalParameters.step_amp_factor
RabiAmplitudeFrequencySignalParameters.min_freq
RabiAmplitudeFrequencySignalParameters.max_freq
RabiAmplitudeFrequencySignalParameters.step_freq
RabiAmplitudeFrequencySignalParameters.pulse_length
RabiAmplitudeFrequencySignalParameters.hardware_average
RabiAmplitudeFrequencySignalParameters.nshots
RabiAmplitudeFrequencySignalParameters.relaxation_time
RabiAmplitudeFrequencySignalResults
RabiAmplitudeFrequencySignalResults.frequency
RabiAmplitudeFrequencySignalResults._to_json()
RabiAmplitudeFrequencySignalResults._to_npz()
RabiAmplitudeFrequencySignalResults.load_data()
RabiAmplitudeFrequencySignalResults.load_params()
RabiAmplitudeFrequencySignalResults.params
RabiAmplitudeFrequencySignalResults.save()
RabiAmplitudeFrequencySignalResults.amplitude
RabiAmplitudeFrequencySignalResults.length
RabiAmplitudeFrequencySignalResults.fitted_parameters
RabiAmpFreqSignalType
RabiAmplitudeFreqSignalData
RabiAmplitudeFreqSignalData._to_json()
RabiAmplitudeFreqSignalData._to_npz()
RabiAmplitudeFreqSignalData.load_data()
RabiAmplitudeFreqSignalData.load_params()
RabiAmplitudeFreqSignalData.pairs
RabiAmplitudeFreqSignalData.params
RabiAmplitudeFreqSignalData.qubits
RabiAmplitudeFreqSignalData.save()
RabiAmplitudeFreqSignalData.durations
RabiAmplitudeFreqSignalData.data
RabiAmplitudeFreqSignalData.register_qubit()
RabiAmplitudeFreqSignalData.amplitudes()
RabiAmplitudeFreqSignalData.frequencies()
_acquisition()
_fit()
_plot()
_update()
rabi_amplitude_frequency_signal
- qibocal.protocols.rabi.amplitude_signal module
RabiAmplitudeSignalParameters
RabiAmplitudeSignalParameters.min_amp_factor
RabiAmplitudeSignalParameters.max_amp_factor
RabiAmplitudeSignalParameters.step_amp_factor
RabiAmplitudeSignalParameters.pulse_length
RabiAmplitudeSignalParameters.hardware_average
RabiAmplitudeSignalParameters.nshots
RabiAmplitudeSignalParameters.relaxation_time
RabiAmplitudeSignalResults
RabiAmplitudeSignalResults.amplitude
RabiAmplitudeSignalResults.length
RabiAmplitudeSignalResults.fitted_parameters
RabiAmplitudeSignalResults._to_json()
RabiAmplitudeSignalResults._to_npz()
RabiAmplitudeSignalResults.load_data()
RabiAmplitudeSignalResults.load_params()
RabiAmplitudeSignalResults.params
RabiAmplitudeSignalResults.save()
RabiAmpSignalType
RabiAmplitudeSignalData
RabiAmplitudeSignalData._to_json()
RabiAmplitudeSignalData._to_npz()
RabiAmplitudeSignalData.load_data()
RabiAmplitudeSignalData.load_params()
RabiAmplitudeSignalData.pairs
RabiAmplitudeSignalData.params
RabiAmplitudeSignalData.qubits
RabiAmplitudeSignalData.register_qubit()
RabiAmplitudeSignalData.save()
RabiAmplitudeSignalData.durations
RabiAmplitudeSignalData.data
_acquisition()
_fit()
_plot()
_update()
rabi_amplitude_signal
- qibocal.protocols.rabi.ef module
RabiAmplitudeEFParameters
RabiAmplitudeEFResults
RabiAmplitudeEFResults._to_json()
RabiAmplitudeEFResults._to_npz()
RabiAmplitudeEFResults.load_data()
RabiAmplitudeEFResults.load_params()
RabiAmplitudeEFResults.params
RabiAmplitudeEFResults.save()
RabiAmplitudeEFResults.amplitude
RabiAmplitudeEFResults.length
RabiAmplitudeEFResults.fitted_parameters
RabiAmplitudeEFData
RabiAmplitudeEFData._to_json()
RabiAmplitudeEFData._to_npz()
RabiAmplitudeEFData.load_data()
RabiAmplitudeEFData.load_params()
RabiAmplitudeEFData.pairs
RabiAmplitudeEFData.params
RabiAmplitudeEFData.qubits
RabiAmplitudeEFData.register_qubit()
RabiAmplitudeEFData.save()
RabiAmplitudeEFData.durations
RabiAmplitudeEFData.data
_acquisition()
_plot()
_update()
rabi_amplitude_ef
- qibocal.protocols.rabi.length module
- qibocal.protocols.rabi.length_frequency module
RabiLengthFrequencyParameters
RabiLengthFrequencyParameters.hardware_average
RabiLengthFrequencyParameters.pulse_amplitude
RabiLengthFrequencyParameters.pulse_duration_start
RabiLengthFrequencyParameters.pulse_duration_end
RabiLengthFrequencyParameters.pulse_duration_step
RabiLengthFrequencyParameters.min_freq
RabiLengthFrequencyParameters.max_freq
RabiLengthFrequencyParameters.step_freq
RabiLengthFrequencyParameters.nshots
RabiLengthFrequencyParameters.relaxation_time
RabiLengthFrequencyResults
RabiLengthFrequencyResults.chi2
RabiLengthFrequencyResults._to_json()
RabiLengthFrequencyResults._to_npz()
RabiLengthFrequencyResults.load_data()
RabiLengthFrequencyResults.load_params()
RabiLengthFrequencyResults.params
RabiLengthFrequencyResults.save()
RabiLengthFrequencyResults.frequency
RabiLengthFrequencyResults.length
RabiLengthFrequencyResults.amplitude
RabiLengthFrequencyResults.fitted_parameters
RabiLenFreqType
RabiLengthFreqData
RabiLengthFreqData.data
RabiLengthFreqData.register_qubit()
RabiLengthFreqData._to_json()
RabiLengthFreqData._to_npz()
RabiLengthFreqData.durations()
RabiLengthFreqData.frequencies()
RabiLengthFreqData.load_data()
RabiLengthFreqData.load_params()
RabiLengthFreqData.pairs
RabiLengthFreqData.params
RabiLengthFreqData.qubits
RabiLengthFreqData.save()
RabiLengthFreqData.amplitudes
_acquisition()
_fit()
_plot()
rabi_length_frequency
- qibocal.protocols.rabi.length_frequency_signal module
RabiLengthFrequencySignalParameters
RabiLengthFrequencySignalParameters.pulse_duration_start
RabiLengthFrequencySignalParameters.pulse_duration_end
RabiLengthFrequencySignalParameters.pulse_duration_step
RabiLengthFrequencySignalParameters.min_freq
RabiLengthFrequencySignalParameters.max_freq
RabiLengthFrequencySignalParameters.step_freq
RabiLengthFrequencySignalParameters.pulse_amplitude
RabiLengthFrequencySignalParameters.hardware_average
RabiLengthFrequencySignalParameters.nshots
RabiLengthFrequencySignalParameters.relaxation_time
RabiLengthFrequencySignalResults
RabiLengthFrequencySignalResults.frequency
RabiLengthFrequencySignalResults._to_json()
RabiLengthFrequencySignalResults._to_npz()
RabiLengthFrequencySignalResults.load_data()
RabiLengthFrequencySignalResults.load_params()
RabiLengthFrequencySignalResults.params
RabiLengthFrequencySignalResults.save()
RabiLengthFrequencySignalResults.length
RabiLengthFrequencySignalResults.amplitude
RabiLengthFrequencySignalResults.fitted_parameters
RabiLenFreqSignalType
RabiLengthFreqSignalData
RabiLengthFreqSignalData._to_json()
RabiLengthFreqSignalData._to_npz()
RabiLengthFreqSignalData.load_data()
RabiLengthFreqSignalData.load_params()
RabiLengthFreqSignalData.pairs
RabiLengthFreqSignalData.params
RabiLengthFreqSignalData.qubits
RabiLengthFreqSignalData.save()
RabiLengthFreqSignalData.amplitudes
RabiLengthFreqSignalData.data
RabiLengthFreqSignalData.register_qubit()
RabiLengthFreqSignalData.durations()
RabiLengthFreqSignalData.frequencies()
_acquisition()
_fit()
_plot()
_update()
rabi_length_frequency_signal
- qibocal.protocols.rabi.length_sequences module
- qibocal.protocols.rabi.length_signal module
RabiLengthSignalParameters
RabiLengthSignalParameters.pulse_duration_start
RabiLengthSignalParameters.pulse_duration_end
RabiLengthSignalParameters.pulse_duration_step
RabiLengthSignalParameters.pulse_amplitude
RabiLengthSignalParameters.hardware_average
RabiLengthSignalParameters.nshots
RabiLengthSignalParameters.relaxation_time
RabiLengthSignalResults
RabiLengthSignalResults.length
RabiLengthSignalResults.amplitude
RabiLengthSignalResults.fitted_parameters
RabiLengthSignalResults._to_json()
RabiLengthSignalResults._to_npz()
RabiLengthSignalResults.load_data()
RabiLengthSignalResults.load_params()
RabiLengthSignalResults.params
RabiLengthSignalResults.save()
RabiLenSignalType
RabiLengthSignalData
RabiLengthSignalData._to_json()
RabiLengthSignalData._to_npz()
RabiLengthSignalData.load_data()
RabiLengthSignalData.load_params()
RabiLengthSignalData.pairs
RabiLengthSignalData.params
RabiLengthSignalData.qubits
RabiLengthSignalData.register_qubit()
RabiLengthSignalData.save()
RabiLengthSignalData.amplitudes
RabiLengthSignalData.data
_acquisition()
_fit()
_update()
_plot()
rabi_length_signal
- qibocal.protocols.rabi.utils module
- qibocal.protocols.ramsey package
- Submodules
- qibocal.protocols.ramsey.ramsey module
RamseyParameters
RamseyResults
RamseyResults.chi2
RamseyResults._to_json()
RamseyResults._to_npz()
RamseyResults.load_data()
RamseyResults.load_params()
RamseyResults.params
RamseyResults.save()
RamseyResults.detuning
RamseyResults.frequency
RamseyResults.t2
RamseyResults.delta_phys
RamseyResults.delta_fitting
RamseyResults.fitted_parameters
RamseyType
RamseyData
_acquisition()
_fit()
_plot()
ramsey
- qibocal.protocols.ramsey.ramsey_signal module
RamseySignalParameters
RamseySignalParameters.delay_between_pulses_start
RamseySignalParameters.delay_between_pulses_end
RamseySignalParameters.delay_between_pulses_step
RamseySignalParameters.detuning
RamseySignalParameters.unrolling
RamseySignalParameters.hardware_average
RamseySignalParameters.nshots
RamseySignalParameters.relaxation_time
RamseySignalResults
RamseySignalResults.detuning
RamseySignalResults.frequency
RamseySignalResults.t2
RamseySignalResults.delta_phys
RamseySignalResults.delta_fitting
RamseySignalResults.fitted_parameters
RamseySignalResults._to_json()
RamseySignalResults._to_npz()
RamseySignalResults.load_data()
RamseySignalResults.load_params()
RamseySignalResults.params
RamseySignalResults.save()
RamseySignalType
RamseySignalData
RamseySignalData._to_json()
RamseySignalData._to_npz()
RamseySignalData.load_data()
RamseySignalData.load_params()
RamseySignalData.pairs
RamseySignalData.params
RamseySignalData.qubits
RamseySignalData.register_qubit()
RamseySignalData.save()
RamseySignalData.detuning
RamseySignalData.qubit_freqs
RamseySignalData.data
RamseySignalData.waits
_acquisition()
_fit()
_plot()
_update()
ramsey_signal
- qibocal.protocols.ramsey.ramsey_zz module
RamseyZZParameters
RamseyZZParameters.target_qubit
RamseyZZParameters.detuning
RamseyZZParameters.hardware_average
RamseyZZParameters.unrolling
RamseyZZParameters.delay_between_pulses_start
RamseyZZParameters.delay_between_pulses_end
RamseyZZParameters.delay_between_pulses_step
RamseyZZParameters.nshots
RamseyZZParameters.relaxation_time
RamseyZZResults
RamseyZZResults._to_json()
RamseyZZResults._to_npz()
RamseyZZResults.load_data()
RamseyZZResults.load_params()
RamseyZZResults.params
RamseyZZResults.save()
RamseyZZResults.detuning
RamseyZZResults.frequency
RamseyZZResults.t2
RamseyZZResults.delta_phys
RamseyZZResults.delta_fitting
RamseyZZResults.fitted_parameters
RamseyZZData
RamseyZZData.target_qubit
RamseyZZData.data
RamseyZZData._to_json()
RamseyZZData._to_npz()
RamseyZZData.detuning
RamseyZZData.load_data()
RamseyZZData.load_params()
RamseyZZData.pairs
RamseyZZData.params
RamseyZZData.qubits
RamseyZZData.register_qubit()
RamseyZZData.save()
RamseyZZData.waits
RamseyZZData.qubit_freqs
_acquisition()
_fit()
_plot()
ramsey_zz
- qibocal.protocols.ramsey.utils module
- qibocal.protocols.randomized_benchmarking package
- Submodules
- qibocal.protocols.randomized_benchmarking.dict_utils module
- qibocal.protocols.randomized_benchmarking.filtered_rb module
FilteredRBParameters
FilteredRBParameters.hardware_average
FilteredRBParameters.noise_model
FilteredRBParameters.nshots
FilteredRBParameters.seed
FilteredRBParameters.uncertainties
FilteredRBParameters.unrolling
FilteredRBParameters.depths
FilteredRBParameters.niter
FilteredRBParameters.noise_params
FilteredRBParameters.relaxation_time
FilteredRBResult
_acquisition()
_fit()
_plot()
- qibocal.protocols.randomized_benchmarking.fitting module
- qibocal.protocols.randomized_benchmarking.noisemodels module
- qibocal.protocols.randomized_benchmarking.standard_rb module
Depthsdict
StandardRBParameters
StandardRBParameters.depths
StandardRBParameters.niter
StandardRBParameters.uncertainties
StandardRBParameters.unrolling
StandardRBParameters.seed
StandardRBParameters.noise_model
StandardRBParameters.hardware_average
StandardRBParameters.noise_params
StandardRBParameters.relaxation_time
StandardRBParameters.nshots
_acquisition()
_fit()
_plot()
- qibocal.protocols.randomized_benchmarking.standard_rb_2q module
StandardRB2QParameters
StandardRB2QParameters.file
StandardRB2QParameters.file_inv
StandardRB2QParameters.hardware_average
StandardRB2QParameters.noise_model
StandardRB2QParameters.nshots
StandardRB2QParameters.seed
StandardRB2QParameters.uncertainties
StandardRB2QParameters.unrolling
StandardRB2QParameters.depths
StandardRB2QParameters.niter
StandardRB2QParameters.noise_params
StandardRB2QParameters.relaxation_time
_acquisition()
_fit()
- qibocal.protocols.randomized_benchmarking.standard_rb_2q_inter module
StandardRB2QInterParameters
StandardRB2QInterParameters.interleave
StandardRB2QInterParameters.file
StandardRB2QInterParameters.file_inv
StandardRB2QInterParameters.hardware_average
StandardRB2QInterParameters.noise_model
StandardRB2QInterParameters.nshots
StandardRB2QInterParameters.seed
StandardRB2QInterParameters.uncertainties
StandardRB2QInterParameters.unrolling
StandardRB2QInterParameters.depths
StandardRB2QInterParameters.niter
StandardRB2QInterParameters.noise_params
StandardRB2QInterParameters.relaxation_time
StandardRB2QInterResult
StandardRB2QInterResult.fidelity_cz
StandardRB2QInterResult._to_json()
StandardRB2QInterResult._to_npz()
StandardRB2QInterResult.load_data()
StandardRB2QInterResult.load_params()
StandardRB2QInterResult.params
StandardRB2QInterResult.save()
StandardRB2QInterResult.fidelity
StandardRB2QInterResult.pulse_fidelity
StandardRB2QInterResult.fit_parameters
StandardRB2QInterResult.fit_uncertainties
StandardRB2QInterResult.error_bars
_acquisition()
_fit()
- qibocal.protocols.randomized_benchmarking.utils module
NPULSES_PER_CLIFFORD
RBType
random_clifford()
random_2q_clifford()
random_circuits()
number_to_str()
data_uncertainties()
RB_Generator
RBData
RBData.depths
RBData.uncertainties
RBData.seed
RBData.nshots
RBData.niter
RBData.data
RBData.circuits
RBData.npulses_per_clifford
RBData.extract_probabilities()
RBData._to_json()
RBData._to_npz()
RBData.load_data()
RBData.load_params()
RBData.pairs
RBData.params
RBData.qubits
RBData.register_qubit()
RBData.save()
RB2QData
RB2QData.npulses_per_clifford
RB2QData.extract_probabilities()
RB2QData._to_json()
RB2QData._to_npz()
RB2QData.load_data()
RB2QData.load_params()
RB2QData.pairs
RB2QData.params
RB2QData.qubits
RB2QData.register_qubit()
RB2QData.save()
RB2QData.depths
RB2QData.uncertainties
RB2QData.seed
RB2QData.nshots
RB2QData.niter
RB2QData.data
RB2QData.circuits
RB2QInterData
RB2QInterData.fidelity
RB2QInterData._to_json()
RB2QInterData._to_npz()
RB2QInterData.extract_probabilities()
RB2QInterData.load_data()
RB2QInterData.load_params()
RB2QInterData.npulses_per_clifford
RB2QInterData.pairs
RB2QInterData.params
RB2QInterData.qubits
RB2QInterData.register_qubit()
RB2QInterData.save()
RB2QInterData.depths
RB2QInterData.uncertainties
RB2QInterData.seed
RB2QInterData.nshots
RB2QInterData.niter
RB2QInterData.data
RB2QInterData.circuits
StandardRBResult
StandardRBResult.fidelity
StandardRBResult._to_json()
StandardRBResult._to_npz()
StandardRBResult.load_data()
StandardRBResult.load_params()
StandardRBResult.params
StandardRBResult.save()
StandardRBResult.pulse_fidelity
StandardRBResult.fit_parameters
StandardRBResult.fit_uncertainties
StandardRBResult.error_bars
setup()
get_circuits()
execute_circuits()
rb_acquisition()
twoq_rb_acquisition()
layer_circuit()
add_inverse_layer()
add_measurement_layer()
fit()
- qibocal.protocols.two_qubit_interaction package
- Subpackages
- Submodules
- qibocal.protocols.two_qubit_interaction.optimize module
OptimizeTwoQubitGateParameters
OptimizeTwoQubitGateParameters.theta_start
OptimizeTwoQubitGateParameters.theta_end
OptimizeTwoQubitGateParameters.theta_step
OptimizeTwoQubitGateParameters.flux_pulse_amplitude_min
OptimizeTwoQubitGateParameters.flux_pulse_amplitude_max
OptimizeTwoQubitGateParameters.flux_pulse_amplitude_step
OptimizeTwoQubitGateParameters.duration_min
OptimizeTwoQubitGateParameters.duration_max
OptimizeTwoQubitGateParameters.duration_step
OptimizeTwoQubitGateParameters.dt
OptimizeTwoQubitGateParameters.parking
OptimizeTwoQubitGateParameters.native
OptimizeTwoQubitGateParameters.hardware_average
OptimizeTwoQubitGateParameters.nshots
OptimizeTwoQubitGateParameters.relaxation_time
OptimizeTwoQubitGateResults
OptimizeTwoQubitGateResults.fitted_parameters
OptimizeTwoQubitGateResults.native
OptimizeTwoQubitGateResults.angles
OptimizeTwoQubitGateResults.virtual_phases
OptimizeTwoQubitGateResults.leakages
OptimizeTwoQubitGateResults._to_json()
OptimizeTwoQubitGateResults._to_npz()
OptimizeTwoQubitGateResults.load_data()
OptimizeTwoQubitGateResults.load_params()
OptimizeTwoQubitGateResults.params
OptimizeTwoQubitGateResults.save()
OptimizeTwoQubitGateResults.best_amp
OptimizeTwoQubitGateResults.best_dur
OptimizeTwoQubitGateResults.best_virtual_phase
OptimizeTwoQubitGateData
OptimizeTwoQubitGateData._to_json()
OptimizeTwoQubitGateData._to_npz()
OptimizeTwoQubitGateData.load_data()
OptimizeTwoQubitGateData.load_params()
OptimizeTwoQubitGateData.pairs
OptimizeTwoQubitGateData.params
OptimizeTwoQubitGateData.qubits
OptimizeTwoQubitGateData.save()
OptimizeTwoQubitGateData.data
OptimizeTwoQubitGateData.thetas
OptimizeTwoQubitGateData.native
OptimizeTwoQubitGateData.amplitudes
OptimizeTwoQubitGateData.durations
OptimizeTwoQubitGateData.register_qubit()
_acquisition()
_fit()
_plot()
_update()
optimize_two_qubit_gate
- qibocal.protocols.two_qubit_interaction.utils module
- qibocal.protocols.two_qubit_interaction.virtual_z_phases module
VirtualZPhasesParameters
VirtualZPhasesParameters.theta_start
VirtualZPhasesParameters.theta_end
VirtualZPhasesParameters.theta_step
VirtualZPhasesParameters.native
VirtualZPhasesParameters.flux_pulse_amplitude
VirtualZPhasesParameters.flux_pulse_duration
VirtualZPhasesParameters.dt
VirtualZPhasesParameters.parking
VirtualZPhasesParameters.hardware_average
VirtualZPhasesParameters.nshots
VirtualZPhasesParameters.relaxation_time
VirtualZPhasesResults
VirtualZPhasesResults.fitted_parameters
VirtualZPhasesResults.native
VirtualZPhasesResults.angle
VirtualZPhasesResults.virtual_phase
VirtualZPhasesResults.leakage
VirtualZPhasesResults.flux_pulse_amplitude
VirtualZPhasesResults.flux_pulse_duration
VirtualZPhasesResults._to_json()
VirtualZPhasesResults._to_npz()
VirtualZPhasesResults.load_data()
VirtualZPhasesResults.load_params()
VirtualZPhasesResults.params
VirtualZPhasesResults.save()
VirtualZPhasesData
VirtualZPhasesData._to_json()
VirtualZPhasesData._to_npz()
VirtualZPhasesData.load_data()
VirtualZPhasesData.load_params()
VirtualZPhasesData.pairs
VirtualZPhasesData.params
VirtualZPhasesData.qubits
VirtualZPhasesData.register_qubit()
VirtualZPhasesData.save()
VirtualZPhasesData.data
VirtualZPhasesData.native
VirtualZPhasesData.thetas
VirtualZPhasesData.amplitudes
VirtualZPhasesData.durations
create_sequence()
_acquisition()
fit_function()
_fit()
_plot()
_update()
correct_virtual_z_phases
- qibocal.protocols.two_qubit_interaction.virtual_z_phases_signal module
VirtualZPhasesSignalParameters
VirtualZPhasesSignalParameters.dt
VirtualZPhasesSignalParameters.flux_pulse_amplitude
VirtualZPhasesSignalParameters.flux_pulse_duration
VirtualZPhasesSignalParameters.hardware_average
VirtualZPhasesSignalParameters.native
VirtualZPhasesSignalParameters.parking
VirtualZPhasesSignalParameters.theta_start
VirtualZPhasesSignalParameters.theta_end
VirtualZPhasesSignalParameters.theta_step
VirtualZPhasesSignalParameters.nshots
VirtualZPhasesSignalParameters.relaxation_time
VirtualZPhasesSignalResults
VirtualZPhasesSignalResults._to_json()
VirtualZPhasesSignalResults._to_npz()
VirtualZPhasesSignalResults.load_data()
VirtualZPhasesSignalResults.load_params()
VirtualZPhasesSignalResults.params
VirtualZPhasesSignalResults.save()
VirtualZPhasesSignalResults.fitted_parameters
VirtualZPhasesSignalResults.native
VirtualZPhasesSignalResults.angle
VirtualZPhasesSignalResults.virtual_phase
VirtualZPhasesSignalResults.leakage
VirtualZPhasesSignalResults.flux_pulse_amplitude
VirtualZPhasesSignalResults.flux_pulse_duration
VirtualZPhasesSignalData
VirtualZPhasesSignalData._to_json()
VirtualZPhasesSignalData._to_npz()
VirtualZPhasesSignalData.load_data()
VirtualZPhasesSignalData.load_params()
VirtualZPhasesSignalData.native
VirtualZPhasesSignalData.pairs
VirtualZPhasesSignalData.params
VirtualZPhasesSignalData.qubits
VirtualZPhasesSignalData.register_qubit()
VirtualZPhasesSignalData.save()
VirtualZPhasesSignalData.data
VirtualZPhasesSignalData.thetas
VirtualZPhasesSignalData.amplitudes
VirtualZPhasesSignalData.durations
_acquisition()
_plot()
correct_virtual_z_phases_signal
Submodules#
qibocal.protocols.classification module#
- class qibocal.protocols.classification.SingleShotClassificationParameters(unrolling: bool = False, classifiers_list: ~typing.Optional[list[str]] = <factory>, savedir: ~typing.Optional[str] = ' ')[source]#
Bases:
Parameters
SingleShotClassification runcard inputs.
- qibocal.protocols.classification.ClassificationType = dtype([('i', '<f8'), ('q', '<f8'), ('state', '<i8')])#
Custom dtype for rabi amplitude.
- class qibocal.protocols.classification.SingleShotClassificationData(nshots: int, savedir: str, qubit_frequencies: dict[typing.Union[str, int], float] = <factory>, data: dict[typing.Union[str, int], numpy.ndarray[typing.Any, numpy.dtype[+_ScalarType_co]]] = <factory>, classifiers_list: Optional[list[str]] = <factory>)[source]#
Bases:
Data
- data: dict[typing.Union[str, int], numpy.ndarray[typing.Any, numpy.dtype[+_ScalarType_co]]]#
Raw data acquired.
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- property pairs#
Access qubit pairs ordered alphanumerically from data structure.
- property qubits#
Access qubits from data structure.
- register_qubit(dtype, data_keys, data_dict)#
Store output for single qubit.
- class qibocal.protocols.classification.SingleShotClassificationResults(names: list, savedir: str, y_preds: dict[typing.Union[str, int], list], grid_preds: dict[typing.Union[str, int], list], threshold: dict[typing.Union[str, int], float] = <factory>, rotation_angle: dict[typing.Union[str, int], float] = <factory>, mean_gnd_states: dict[typing.Union[str, int], list[float]] = <factory>, mean_exc_states: dict[typing.Union[str, int], list[float]] = <factory>, fidelity: dict[typing.Union[str, int], float] = <factory>, assignment_fidelity: dict[typing.Union[str, int], float] = <factory>, effective_temperature: dict[typing.Union[str, int], float] = <factory>, models: dict[typing.Union[str, int], list] = <factory>, benchmark_table: ~typing.Optional[dict[typing.Union[str, int], pandas.core.frame.DataFrame]] = <factory>, classifiers_hpars: ~typing.Optional[dict[typing.Union[str, int], dict]] = <factory>, x_tests: dict[typing.Union[str, int], list] = <factory>, y_tests: dict[typing.Union[str, int], list] = <factory>)[source]#
Bases:
Results
SingleShotClassification outputs.
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- assignment_fidelity: dict[Union[str, int], float]#
Assignment fidelity evaluated only with the qubit_fit model.
- qibocal.protocols.classification._acquisition(params: SingleShotClassificationParameters, platform: Platform, targets: list[Union[str, int]]) SingleShotClassificationData [source]#
- Parameters:
nshots (int) – number of times the pulse sequence will be repeated.
classifiers (list) – list of classifiers, the available ones are: - qubit_fit - qblox_fit.
["qubit_fit"]. (The default value is) –
savedir (str) – Dumping folder of the classification results.
one. (If not given the dumping folder will be the report) –
relaxation_time (float) – Relaxation time.
Example –
code-block: (..) – yaml:
id (-) – single_shot_classification_1 operation: single_shot_classification parameters: nshots: 5000 savedir: “single_shot” classifiers_list: [“qubit_fit”]
- qibocal.protocols.classification._fit(data: SingleShotClassificationData) SingleShotClassificationResults [source]#
- qibocal.protocols.classification._plot(data: SingleShotClassificationData, target: Union[str, int], fit: SingleShotClassificationResults)[source]#
- qibocal.protocols.classification._update(results: SingleShotClassificationResults, platform: Platform, target: Union[str, int])[source]#
- qibocal.protocols.classification.single_shot_classification = Routine(acquisition=<function _acquisition>, fit=<function _fit>, report=<function _plot>, update=<function _update>, two_qubit_gates=False)#
Qubit classification routine object.
qibocal.protocols.dispersive_shift module#
- class qibocal.protocols.dispersive_shift.DispersiveShiftParameters(freq_width: int, freq_step: int)[source]#
Bases:
Parameters
Dispersive shift inputs.
- class qibocal.protocols.dispersive_shift.DispersiveShiftResults(frequencies: dict[Union[str, int], list[float]], fitted_parameters: dict[Union[str, int], list[list[float]]], best_freq: dict[Union[str, int], float])[source]#
Bases:
Results
Dispersive shift outputs.
- fitted_parameters: dict[Union[str, int], list[list[float]]]#
Fitted parameters. The first element is the resonator frequency when the qubit is in the ground state, the second one when the qubit is in the first excited state.
- best_freq: dict[Union[str, int], float]#
Readout frequency that maximizes the distance of ground and excited states in iq-plane
- qibocal.protocols.dispersive_shift.DispersiveShiftType = dtype([('freq', '<f8'), ('i', '<f8'), ('q', '<f8'), ('signal', '<f8'), ('phase', '<f8')])#
Custom dtype for dispersive shift.
- class qibocal.protocols.dispersive_shift.DispersiveShiftData(resonator_type: str, data: dict[tuple[typing.Union[str, int], int], numpy.ndarray[typing.Any, numpy.dtype[dtype([('freq', '<f8'), ('i', '<f8'), ('q', '<f8'), ('signal', '<f8'), ('phase', '<f8')])]]] = <factory>)[source]#
Bases:
Data
Dispersive shift acquisition outputs.
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- property pairs#
Access qubit pairs ordered alphanumerically from data structure.
- property qubits#
Access qubits from data structure.
- register_qubit(dtype, data_keys, data_dict)#
Store output for single qubit.
- data: dict[tuple[typing.Union[str, int], int], numpy.ndarray[typing.Any, numpy.dtype[dtype([('freq', '<f8'), ('i', '<f8'), ('q', '<f8'), ('signal', '<f8'), ('phase', '<f8')])]]]#
- qibocal.protocols.dispersive_shift._acquisition(params: DispersiveShiftParameters, platform: Platform, targets: list[Union[str, int]]) DispersiveShiftData [source]#
Data acquisition for dispersive shift experiment. Perform spectroscopy on the readout resonator, with the qubit in ground and excited state, showing the resonator shift produced by the coupling between the resonator and the qubit.
- Parameters:
params (DispersiveShiftParameters) – experiment’s parameters
platform (Platform) – Qibolab platform object
targets (list) – list of target qubits to perform the action
- qibocal.protocols.dispersive_shift._fit(data: DispersiveShiftData) DispersiveShiftResults [source]#
Post-Processing for dispersive shift
- qibocal.protocols.dispersive_shift._plot(data: DispersiveShiftData, target: Union[str, int], fit: DispersiveShiftResults)[source]#
Plotting function for dispersive shift.
- qibocal.protocols.dispersive_shift._update(results: DispersiveShiftResults, platform: Platform, target: Union[str, int])[source]#
- qibocal.protocols.dispersive_shift.dispersive_shift = Routine(acquisition=<function _acquisition>, fit=<function _fit>, report=<function _plot>, update=<function _update>, two_qubit_gates=False)#
Dispersive shift Routine object.
qibocal.protocols.dispersive_shift_qutrit module#
- class qibocal.protocols.dispersive_shift_qutrit.DispersiveShiftQutritParameters(freq_width: int, freq_step: int)[source]#
Bases:
DispersiveShiftParameters
Dispersive shift inputs.
- class qibocal.protocols.dispersive_shift_qutrit.DispersiveShiftQutritResults(frequency_state_zero: dict[Union[str, int], float], frequency_state_one: dict[Union[str, int], float], frequency_state_two: dict[Union[str, int], float], fitted_parameters_state_zero: dict[Union[str, int], list[float]], fitted_parameters_state_one: dict[Union[str, int], list[float]], fitted_parameters_state_two: dict[Union[str, int], list[float]])[source]#
Bases:
Results
Dispersive shift outputs.
- property state_zero#
- property state_one#
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- property state_two#
- class qibocal.protocols.dispersive_shift_qutrit.DispersiveShiftQutritData(resonator_type: str, data: dict[tuple[typing.Union[str, int], int], numpy.ndarray[typing.Any, numpy.dtype[dtype([('freq', '<f8'), ('i', '<f8'), ('q', '<f8'), ('signal', '<f8'), ('phase', '<f8')])]]] = <factory>)[source]#
Bases:
DispersiveShiftData
Dipsersive shift acquisition outputs.
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- property pairs#
Access qubit pairs ordered alphanumerically from data structure.
- property qubits#
Access qubits from data structure.
- register_qubit(dtype, data_keys, data_dict)#
Store output for single qubit.
- qibocal.protocols.dispersive_shift_qutrit._acquisition(params: DispersiveShiftParameters, platform: Platform, targets: list[Union[str, int]]) DispersiveShiftQutritData [source]#
Data acquisition for dispersive shift experiment. Perform spectroscopy on the readout resonator, with the qubit in ground and excited state, showing the resonator shift produced by the coupling between the resonator and the qubit.
- Parameters:
params (DispersiveShiftParameters) – experiment’s parameters
platform (Platform) – Qibolab platform object
targets (list) – list of target qubits to perform the action
- qibocal.protocols.dispersive_shift_qutrit._fit(data: DispersiveShiftQutritData) DispersiveShiftQutritResults [source]#
Post-Processing for dispersive shift
- qibocal.protocols.dispersive_shift_qutrit._plot(data: DispersiveShiftQutritData, target: Union[str, int], fit: DispersiveShiftQutritResults)[source]#
Plotting function for dispersive shift.
qibocal.protocols.drag module#
- class qibocal.protocols.drag.DragTuningParameters(beta_start: float, beta_end: float, beta_step: float, unrolling: bool = False)[source]#
Bases:
Parameters
DragTuning runcard inputs.
- class qibocal.protocols.drag.DragTuningResults(betas: dict[typing.Union[str, int], float], fitted_parameters: dict[typing.Union[str, int], dict[str, float]], chi2: dict[typing.Union[str, int], tuple[float, typing.Optional[float]]] = <factory>)[source]#
Bases:
Results
DragTuning outputs.
- class qibocal.protocols.drag.DragTuningData(anharmonicity: dict[typing.Union[str, int], float] = <factory>, data: dict[typing.Union[str, int], numpy.ndarray[typing.Any, numpy.dtype[dtype([('prob', '<f8'), ('error', '<f8'), ('beta', '<f8')])]]] = <factory>)[source]#
Bases:
Data
DragTuning acquisition outputs.
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- property pairs#
Access qubit pairs ordered alphanumerically from data structure.
- property qubits#
Access qubits from data structure.
- register_qubit(dtype, data_keys, data_dict)#
Store output for single qubit.
- data: dict[typing.Union[str, int], numpy.ndarray[typing.Any, numpy.dtype[dtype([('prob', '<f8'), ('error', '<f8'), ('beta', '<f8')])]]]#
Raw data acquired.
- qibocal.protocols.drag._acquisition(params: DragTuningParameters, platform: Platform, targets: list[Union[str, int]]) DragTuningData [source]#
Data acquisition for drag pulse tuning experiment. See https://arxiv.org/pdf/1504.06597.pdf Fig. 2 (c).
- qibocal.protocols.drag._fit(data: DragTuningData) DragTuningResults [source]#
- qibocal.protocols.drag._plot(data: DragTuningData, target: Union[str, int], fit: DragTuningResults)[source]#
Plotting function for DragTuning.
- qibocal.protocols.drag._update(results: DragTuningResults, platform: Platform, target: Union[str, int])[source]#
- qibocal.protocols.drag.drag_tuning = Routine(acquisition=<function _acquisition>, fit=<function _fit>, report=<function _plot>, update=<function _update>, two_qubit_gates=False)#
DragTuning Routine object.
qibocal.protocols.flipping module#
- class qibocal.protocols.flipping.FlippingParameters(nflips_max: int, nflips_step: int, unrolling: bool = False, delta_amplitude: float = 0)[source]#
Bases:
FlippingSignalParameters
Flipping runcard inputs.
- class qibocal.protocols.flipping.FlippingResults(amplitude: dict[typing.Union[str, int], typing.Union[float, list[float]]], delta_amplitude: dict[typing.Union[str, int], typing.Union[float, list[float]]], delta_amplitude_detuned: dict[typing.Union[str, int], typing.Union[float, list[float]]], fitted_parameters: dict[typing.Union[str, int], dict[str, float]], chi2: dict[typing.Union[str, int], list[float]] = <factory>)[source]#
Bases:
FlippingSignalResults
Flipping outputs.
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- delta_amplitude: dict[QubitId, Union[float, list[float]]]#
Difference in amplitude between initial value and fit.
- class qibocal.protocols.flipping.FlippingData(resonator_type: str, delta_amplitude: float, pi_pulse_amplitudes: dict[typing.Union[str, int], float], data: dict[typing.Union[str, int], numpy.ndarray[typing.Any, numpy.dtype[dtype([('flips', '<f8'), ('prob', '<f8'), ('error', '<f8')])]]] = <factory>)[source]#
Bases:
FlippingSignalData
Flipping acquisition outputs.
- data: dict[typing.Union[str, int], numpy.ndarray[typing.Any, numpy.dtype[dtype([('flips', '<f8'), ('prob', '<f8'), ('error', '<f8')])]]]#
Raw data acquired.
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- property pairs#
Access qubit pairs ordered alphanumerically from data structure.
- property qubits#
Access qubits from data structure.
- register_qubit(dtype, data_keys, data_dict)#
Store output for single qubit.
- qibocal.protocols.flipping._acquisition(params: FlippingParameters, platform: Platform, targets: list[Union[str, int]]) FlippingData [source]#
Data acquisition for flipping.
The flipping experiment correct the delta amplitude in the qubit drive pulse. We measure a qubit after applying a Rx(pi/2) and N flips (Rx(pi) rotations). After fitting we can obtain the delta amplitude to refine pi pulses.
- Parameters:
params (
SingleShotClassificationParameters
) – input parametersplatform (
Platform
) – Qibolab’s platformqubits (dict) – dict of target
Qubit
objects to be characterized
- Returns:
data (
FlippingData
)
- qibocal.protocols.flipping._fit(data: FlippingData) FlippingResults [source]#
Post-processing function for Flipping.
The used model is
\[y = p_0 sin\Big(\frac{2 \pi x}{p_2} + p_3\Big) + p_1.\]
- qibocal.protocols.flipping._plot(data: FlippingData, target: Union[str, int], fit: Optional[FlippingResults] = None)[source]#
Plotting function for Flipping.
- qibocal.protocols.flipping.flipping = Routine(acquisition=<function _acquisition>, fit=<function _fit>, report=<function _plot>, update=<function _update>, two_qubit_gates=False)#
Flipping Routine object.
qibocal.protocols.flipping_signal module#
- class qibocal.protocols.flipping_signal.FlippingSignalParameters(nflips_max: int, nflips_step: int, unrolling: bool = False, delta_amplitude: float = 0)[source]#
Bases:
Parameters
Flipping runcard inputs.
- class qibocal.protocols.flipping_signal.FlippingSignalResults(amplitude: dict[Union[str, int], Union[float, list[float]]], delta_amplitude: dict[Union[str, int], Union[float, list[float]]], delta_amplitude_detuned: dict[Union[str, int], Union[float, list[float]]], fitted_parameters: dict[Union[str, int], dict[str, float]])[source]#
Bases:
Results
Flipping outputs.
- delta_amplitude: dict[Union[str, int], Union[float, list[float]]]#
Difference in amplitude between initial value and fit.
- delta_amplitude_detuned: dict[Union[str, int], Union[float, list[float]]]#
Difference in amplitude between detuned value and fit.
- class qibocal.protocols.flipping_signal.FlippingSignalData(resonator_type: str, delta_amplitude: float, pi_pulse_amplitudes: dict[typing.Union[str, int], float], data: dict[typing.Union[str, int], numpy.ndarray[typing.Any, numpy.dtype[dtype([('flips', '<f8'), ('signal', '<f8')])]]] = <factory>)[source]#
Bases:
Data
Flipping acquisition outputs.
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- property pairs#
Access qubit pairs ordered alphanumerically from data structure.
- property qubits#
Access qubits from data structure.
- register_qubit(dtype, data_keys, data_dict)#
Store output for single qubit.
- data: dict[typing.Union[str, int], numpy.ndarray[typing.Any, numpy.dtype[dtype([('flips', '<f8'), ('signal', '<f8')])]]]#
Raw data acquired.
- qibocal.protocols.flipping_signal.flipping_sequence(platform: Platform, qubit: Union[str, int], delta_amplitude: float, flips: int)[source]#
- qibocal.protocols.flipping_signal._acquisition(params: FlippingSignalParameters, platform: Platform, targets: list[Union[str, int]]) FlippingSignalData [source]#
Data acquisition for flipping.
The flipping experiment correct the delta amplitude in the qubit drive pulse. We measure a qubit after applying a Rx(pi/2) and N flips (Rx(pi) rotations). After fitting we can obtain the delta amplitude to refine pi pulses.
- Parameters:
params (
FlippingSignalParameters
) – input parametersplatform (
Platform
) – Qibolab’s platformqubits (dict) – dict of target
Qubit
objects to be characterized
- Returns:
data (
FlippingSignalData
)
- qibocal.protocols.flipping_signal._fit(data: FlippingSignalData) FlippingSignalResults [source]#
Post-processing function for Flipping.
The used model is
\[y = p_0 sin\Big(\frac{2 \pi x}{p_2} + p_3\Big)*\exp{-x*p4} + p_1.\]
- qibocal.protocols.flipping_signal._plot(data: FlippingSignalData, target, fit: Optional[FlippingSignalResults] = None)[source]#
Plotting function for Flipping.
- qibocal.protocols.flipping_signal._update(results: FlippingSignalResults, platform: Platform, qubit: Union[str, int])[source]#
- qibocal.protocols.flipping_signal.flipping_signal = Routine(acquisition=<function _acquisition>, fit=<function _fit>, report=<function _plot>, update=<function _update>, two_qubit_gates=False)#
Flipping Routine object.
qibocal.protocols.qubit_power_spectroscopy module#
- class qibocal.protocols.qubit_power_spectroscopy.QubitPowerSpectroscopyParameters(freq_width: int, freq_step: int, min_amp_factor: float, max_amp_factor: float, step_amp_factor: float, duration: int, amplitude: Optional[float] = None)[source]#
Bases:
Parameters
QubitPowerSpectroscopy runcard inputs.
- class qibocal.protocols.qubit_power_spectroscopy.QubitPowerSpectroscopyData(resonator_type: str, amplitudes: dict[typing.Union[str, int], float], data: dict[typing.Union[str, int], numpy.ndarray[typing.Any, numpy.dtype[dtype([('freq', '<f8'), ('amp', '<f8'), ('signal', '<f8'), ('phase', '<f8')])]]] = <factory>)[source]#
Bases:
ResonatorPunchoutData
QubitPowerSpectroscopy data acquisition.
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- property pairs#
Access qubit pairs ordered alphanumerically from data structure.
- property qubits#
Access qubits from data structure.
- register_qubit(qubit, freq, amp, signal, phase)#
Store output for single qubit.
- qibocal.protocols.qubit_power_spectroscopy._acquisition(params: QubitPowerSpectroscopyParameters, platform: Platform, targets: list[Union[str, int]]) QubitPowerSpectroscopyData [source]#
Perform a qubit spectroscopy experiment with different amplitudes.
For high amplitude it should be possible to see more peaks: corresponding to the (0-2)/2 frequency and the 1-2. This experiment can be used also to test if a peak is a qubit: if it is, the peak will get larger while increasing the power of the drive.
- qibocal.protocols.qubit_power_spectroscopy._fit(data: QubitPowerSpectroscopyData) Results [source]#
Do not perform any fitting procedure.
- qibocal.protocols.qubit_power_spectroscopy._plot(data: ResonatorPunchoutData, target: Union[str, int], fit: Optional[QubitSpectroscopyResults] = None)[source]#
Plot QubitPunchout.
- qibocal.protocols.qubit_power_spectroscopy.qubit_power_spectroscopy = Routine(acquisition=<function _acquisition>, fit=<function _fit>, report=<function _plot>, update=<function _dummy_update>, two_qubit_gates=False)#
QubitPowerSpectroscopy Routine object.
qibocal.protocols.qubit_spectroscopy module#
- class qibocal.protocols.qubit_spectroscopy.QubitSpectroscopyParameters(freq_width: int, freq_step: int, drive_duration: int, drive_amplitude: Optional[float] = None, hardware_average: bool = True)[source]#
Bases:
Parameters
QubitSpectroscopy runcard inputs.
- class qibocal.protocols.qubit_spectroscopy.QubitSpectroscopyResults(frequency: dict[typing.Union[str, int], dict[str, float]], amplitude: dict[typing.Union[str, int], float], fitted_parameters: dict[typing.Union[str, int], list[float]], chi2_reduced: dict[typing.Union[str, int], tuple[float, typing.Optional[float]]] = <factory>, error_fit_pars: dict[typing.Union[str, int], list] = <factory>)[source]#
Bases:
Results
QubitSpectroscopy outputs.
- class qibocal.protocols.qubit_spectroscopy.QubitSpectroscopyData(resonator_type: str, amplitudes: dict[typing.Union[str, int], float], fit_function: str = 'lorentzian', phase_sign: bool = False, data: dict[typing.Union[str, int], numpy.ndarray[typing.Any, numpy.dtype[dtype([('freq', '<f8'), ('signal', '<f8'), ('phase', '<f8'), ('error_signal', '<f8'), ('error_phase', '<f8')])]]] = <factory>, power_level: ~typing.Optional[~qibocal.protocols.utils.PowerLevel] = None, attenuations: ~typing.Optional[dict[typing.Union[str, int], int]] = <factory>)[source]#
Bases:
ResonatorSpectroscopyData
QubitSpectroscopy acquisition outputs.
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- property pairs#
Access qubit pairs ordered alphanumerically from data structure.
- phase_sign: bool = False#
Several instruments have their convention about the sign of the phase. If True, the routine will apply a minus to the phase data.
- power_level: Optional[PowerLevel] = None#
Power regime of the resonator.
- property qubits#
Access qubits from data structure.
- register_qubit(dtype, data_keys, data_dict)#
Store output for single qubit.
- qibocal.protocols.qubit_spectroscopy._acquisition(params: QubitSpectroscopyParameters, platform: Platform, targets: list[Union[str, int]]) QubitSpectroscopyData [source]#
Data acquisition for qubit spectroscopy.
- qibocal.protocols.qubit_spectroscopy._fit(data: QubitSpectroscopyData) QubitSpectroscopyResults [source]#
Post-processing function for QubitSpectroscopy.
- qibocal.protocols.qubit_spectroscopy._plot(data: QubitSpectroscopyData, target: Union[str, int], fit: QubitSpectroscopyResults)[source]#
Plotting function for QubitSpectroscopy.
- qibocal.protocols.qubit_spectroscopy._update(results: QubitSpectroscopyResults, platform: Platform, target: Union[str, int])[source]#
- qibocal.protocols.qubit_spectroscopy.qubit_spectroscopy = Routine(acquisition=<function _acquisition>, fit=<function _fit>, report=<function _plot>, update=<function _update>, two_qubit_gates=False)#
QubitSpectroscopy Routine object.
qibocal.protocols.qubit_spectroscopy_ef module#
- qibocal.protocols.qubit_spectroscopy_ef.DEFAULT_ANHARMONICITY = 300000000.0#
Initial guess for anharmonicity.
- class qibocal.protocols.qubit_spectroscopy_ef.QubitSpectroscopyEFParameters(freq_width: int, freq_step: int, drive_duration: int, drive_amplitude: Optional[float] = None, hardware_average: bool = True)[source]#
Bases:
QubitSpectroscopyParameters
QubitSpectroscopyEF runcard inputs.
- class qibocal.protocols.qubit_spectroscopy_ef.QubitSpectroscopyEFResults(frequency: dict[typing.Union[str, int], dict[str, float]], amplitude: dict[typing.Union[str, int], float], fitted_parameters: dict[typing.Union[str, int], list[float]], chi2_reduced: dict[typing.Union[str, int], tuple[float, typing.Optional[float]]] = <factory>, error_fit_pars: dict[typing.Union[str, int], list] = <factory>, anharmonicity: dict[typing.Union[str, int], float] = <factory>)[source]#
Bases:
QubitSpectroscopyResults
QubitSpectroscopyEF outputs.
- class qibocal.protocols.qubit_spectroscopy_ef.QubitSpectroscopyEFData(resonator_type: str, amplitudes: dict[typing.Union[str, int], float], fit_function: str = 'lorentzian', phase_sign: bool = False, data: dict[typing.Union[str, int], numpy.ndarray[typing.Any, numpy.dtype[dtype([('freq', '<f8'), ('signal', '<f8'), ('phase', '<f8'), ('error_signal', '<f8'), ('error_phase', '<f8')])]]] = <factory>, power_level: ~typing.Optional[~qibocal.protocols.utils.PowerLevel] = None, attenuations: ~typing.Optional[dict[typing.Union[str, int], int]] = <factory>, drive_frequencies: dict[typing.Union[str, int], float] = <factory>)[source]#
Bases:
QubitSpectroscopyData
QubitSpectroscopy acquisition outputs.
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- property pairs#
Access qubit pairs ordered alphanumerically from data structure.
- phase_sign: bool = False#
Several instruments have their convention about the sign of the phase. If True, the routine will apply a minus to the phase data.
- power_level: Optional[PowerLevel] = None#
Power regime of the resonator.
- property qubits#
Access qubits from data structure.
- register_qubit(dtype, data_keys, data_dict)#
Store output for single qubit.
- qibocal.protocols.qubit_spectroscopy_ef.fit_ef(data: QubitSpectroscopyEFData) QubitSpectroscopyEFResults [source]#
- qibocal.protocols.qubit_spectroscopy_ef._acquisition(params: QubitSpectroscopyEFParameters, platform: Platform, targets: list[Union[str, int]]) QubitSpectroscopyEFData [source]#
Data acquisition for qubit spectroscopy ef protocol.
Similar to a qubit spectroscopy with the difference that the qubit is first excited to the state 1. This protocols aims at finding the transition frequency between state 1 and the state 2. The anharmonicity is also computed.
If the RX12 frequency is not present in the runcard the sweep is performed around the qubit drive frequency shifted by DEFAULT_ANHARMONICITY, an hardcoded parameter editable in this file.
- qibocal.protocols.qubit_spectroscopy_ef._plot(data: QubitSpectroscopyEFData, target: Union[str, int], fit: QubitSpectroscopyEFResults)[source]#
Plotting function for QubitSpectroscopy.
- qibocal.protocols.qubit_spectroscopy_ef._update(results: QubitSpectroscopyEFResults, platform: Platform, target: Union[str, int])[source]#
Update w12 frequency
- qibocal.protocols.qubit_spectroscopy_ef.qubit_spectroscopy_ef = Routine(acquisition=<function _acquisition>, fit=<function fit_ef>, report=<function _plot>, update=<function _update>, two_qubit_gates=False)#
QubitSpectroscopyEF Routine object.
qibocal.protocols.qutrit_classification module#
- class qibocal.protocols.qutrit_classification.QutritClassificationParameters(unrolling: bool = False, classifiers_list: ~typing.Optional[list[str]] = <factory>, savedir: ~typing.Optional[str] = ' ')[source]#
Bases:
SingleShotClassificationParameters
SingleShotClassification runcard inputs.
- class qibocal.protocols.qutrit_classification.QutritClassificationData(nshots: int, savedir: str, qubit_frequencies: dict[typing.Union[str, int], float] = <factory>, data: dict[typing.Union[str, int], numpy.ndarray[typing.Any, numpy.dtype[+_ScalarType_co]]] = <factory>, classifiers_list: Optional[list[str]] = <factory>)[source]#
Bases:
SingleShotClassificationData
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- property pairs#
Access qubit pairs ordered alphanumerically from data structure.
- property qubits#
Access qubits from data structure.
- register_qubit(dtype, data_keys, data_dict)#
Store output for single qubit.
- class qibocal.protocols.qutrit_classification.QutritClassificationResults[source]#
Bases:
Results
Qutrit classification results
- qibocal.protocols.qutrit_classification._acquisition(params: QutritClassificationParameters, platform: Platform, targets: list[Union[str, int]]) QutritClassificationData [source]#
This Routine prepares the qubits in 0,1 and 2 states and measures their respective I, Q values.
- Parameters:
nshots (int) – number of times the pulse sequence will be repeated.
classifiers (list) – list of classifiers, the available ones are: - naive_bayes - nn - random_forest - decision_tree
["naive_bayes"]. (The default value is) –
savedir (str) – Dumping folder of the classification results.
given (If not) –
one. (the dumping folder will be the report) –
relaxation_time (float) – Relaxation time.
- qibocal.protocols.qutrit_classification._fit(data: QutritClassificationData) QutritClassificationResults [source]#
- qibocal.protocols.qutrit_classification._plot(data: QutritClassificationData, target: Union[str, int], fit: QutritClassificationResults)[source]#
- qibocal.protocols.qutrit_classification.qutrit_classification = Routine(acquisition=<function _acquisition>, fit=<function _fit>, report=<function _plot>, update=<function _dummy_update>, two_qubit_gates=False)#
Qutrit classification Routine object.
qibocal.protocols.readout_characterization module#
- class qibocal.protocols.readout_characterization.ReadoutCharacterizationParameters(delay: float = 0)[source]#
Bases:
Parameters
ReadoutCharacterization runcard inputs.
- class qibocal.protocols.readout_characterization.ReadoutCharacterizationResults(fidelity: dict[Union[str, int], float], assignment_fidelity: dict[Union[str, int], float], qnd: dict[Union[str, int], float], effective_temperature: dict[Union[str, int], list[float]], Lambda_M: dict[Union[str, int], float], Lambda_M2: dict[Union[str, int], float])[source]#
Bases:
Results
ReadoutCharacterization outputs.
- Lambda_M: dict[Union[str, int], float]#
Mapping between a given initial state to an outcome after the measurement
- Lambda_M2: dict[Union[str, int], float]#
Mapping between the outcome after the measurement and it still being that outcame after another measurement
- qibocal.protocols.readout_characterization.ReadoutCharacterizationType = dtype([('i', '<f8'), ('q', '<f8')])#
Custom dtype for ReadoutCharacterization.
- class qibocal.protocols.readout_characterization.ReadoutCharacterizationData(qubit_frequencies: dict[typing.Union[str, int], float] = <factory>, delay: float = 0, data: dict[tuple, numpy.ndarray[typing.Any, numpy.dtype[dtype([('i', '<f8'), ('q', '<f8')])]]] = <factory>, samples: dict[tuple, numpy.ndarray[typing.Any, numpy.dtype[+_ScalarType_co]]] = <factory>)[source]#
Bases:
Data
ReadoutCharacterization acquisition outputs.
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- property pairs#
Access qubit pairs ordered alphanumerically from data structure.
- property qubits#
Access qubits from data structure.
- register_qubit(dtype, data_keys, data_dict)#
Store output for single qubit.
- data: dict[tuple, numpy.ndarray[typing.Any, numpy.dtype[dtype([('i', '<f8'), ('q', '<f8')])]]]#
Raw data acquired.
- samples: dict[tuple, numpy.ndarray[typing.Any, numpy.dtype[+_ScalarType_co]]]#
Raw data acquired.
- qibocal.protocols.readout_characterization._acquisition(params: ReadoutCharacterizationParameters, platform: Platform, targets: list[Union[str, int]]) ReadoutCharacterizationData [source]#
Data acquisition for resonator spectroscopy.
- qibocal.protocols.readout_characterization._fit(data: ReadoutCharacterizationData) ReadoutCharacterizationResults [source]#
Post-processing function for ReadoutCharacterization.
- qibocal.protocols.readout_characterization._plot(data: ReadoutCharacterizationData, fit: ReadoutCharacterizationResults, target: Union[str, int])[source]#
Plotting function for ReadoutCharacterization.
- qibocal.protocols.readout_characterization._update(results: ReadoutCharacterizationResults, platform: Platform, target: Union[str, int])[source]#
- qibocal.protocols.readout_characterization.readout_characterization = Routine(acquisition=<function _acquisition>, fit=<function _fit>, report=<function _plot>, update=<function _update>, two_qubit_gates=False)#
ReadoutCharacterization Routine object.
qibocal.protocols.readout_mitigation_matrix module#
- class qibocal.protocols.readout_mitigation_matrix.ReadoutMitigationMatrixParameters(nshots: Optional[int] = None, relaxation_time: Optional[int] = None)[source]#
Bases:
Parameters
ReadoutMitigationMatrix matrix inputs.
- class qibocal.protocols.readout_mitigation_matrix.ReadoutMitigationMatrixResults(readout_mitigation_matrix: dict[tuple[typing.Union[str, int], ...], numpy.ndarray[typing.Any, numpy.dtype[numpy.float64]]] = <factory>)[source]#
Bases:
Results
- readout_mitigation_matrix: dict[tuple[Union[str, int], ...], numpy.ndarray[Any, numpy.dtype[numpy.float64]]]#
Readout mitigation matrices (inverse of measurement matrix).
- class qibocal.protocols.readout_mitigation_matrix.ReadoutMitigationMatrixData(qubit_list: list[typing.Union[str, int]], nshots: int, data: dict = <factory>)[source]#
Bases:
Data
ReadoutMitigationMatrix acquisition outputs.
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- property pairs#
Access qubit pairs ordered alphanumerically from data structure.
- property qubits#
Access qubits from data structure.
- register_qubit(dtype, data_keys, data_dict)#
Store output for single qubit.
- qibocal.protocols.readout_mitigation_matrix._acquisition(params: ReadoutMitigationMatrixParameters, platform: Platform, targets: list[list[Union[str, int]]]) ReadoutMitigationMatrixData [source]#
- qibocal.protocols.readout_mitigation_matrix._fit(data: ReadoutMitigationMatrixData) ReadoutMitigationMatrixResults [source]#
Post processing for readout mitigation matrix protocol.
- qibocal.protocols.readout_mitigation_matrix._plot(data: ReadoutMitigationMatrixData, fit: ReadoutMitigationMatrixResults, target: list[Union[str, int]])[source]#
Plotting function for readout mitigation matrix.
- qibocal.protocols.readout_mitigation_matrix.readout_mitigation_matrix = Routine(acquisition=<function _acquisition>, fit=<function _fit>, report=<function _plot>, update=<function _dummy_update>, two_qubit_gates=False)#
Readout mitigation matrix protocol.
qibocal.protocols.resonator_punchout module#
- class qibocal.protocols.resonator_punchout.ResonatorPunchoutParameters(freq_width: int, freq_step: int, min_amp_factor: float, max_amp_factor: float, step_amp_factor: float, amplitude: Optional[float] = None)[source]#
Bases:
Parameters
ResonatorPunchout runcard inputs.
- class qibocal.protocols.resonator_punchout.ResonatorPunchoutResults(readout_frequency: dict[Union[str, int], float], bare_frequency: Optional[dict[Union[str, int], float]], readout_amplitude: dict[Union[str, int], float])[source]#
Bases:
Results
ResonatorPunchout outputs.
- bare_frequency: Optional[dict[Union[str, int], float]]#
Bare resonator frequency [GHz] for each qubit.
- qibocal.protocols.resonator_punchout.ResPunchoutType = dtype([('freq', '<f8'), ('amp', '<f8'), ('signal', '<f8'), ('phase', '<f8')])#
Custom dtype for resonator punchout.
- class qibocal.protocols.resonator_punchout.ResonatorPunchoutData(resonator_type: str, amplitudes: dict[typing.Union[str, int], float], data: dict[typing.Union[str, int], numpy.ndarray[typing.Any, numpy.dtype[dtype([('freq', '<f8'), ('amp', '<f8'), ('signal', '<f8'), ('phase', '<f8')])]]] = <factory>)[source]#
Bases:
Data
ResonatorPunchout data acquisition.
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- property pairs#
Access qubit pairs ordered alphanumerically from data structure.
- property qubits#
Access qubits from data structure.
- data: dict[typing.Union[str, int], numpy.ndarray[typing.Any, numpy.dtype[dtype([('freq', '<f8'), ('amp', '<f8'), ('signal', '<f8'), ('phase', '<f8')])]]]#
Raw data acquired.
- qibocal.protocols.resonator_punchout._acquisition(params: ResonatorPunchoutParameters, platform: Platform, targets: list[Union[str, int]]) ResonatorPunchoutData [source]#
Data acquisition for Punchout over amplitude.
- qibocal.protocols.resonator_punchout._fit(data: ResonatorPunchoutData, fit_type='amp') ResonatorPunchoutResults [source]#
Fit frequency and attenuation at high and low power for a given resonator.
- qibocal.protocols.resonator_punchout._plot(data: ResonatorPunchoutData, target: Union[str, int], fit: Optional[ResonatorPunchoutResults] = None)[source]#
Plotting function for ResonatorPunchout.
- qibocal.protocols.resonator_punchout._update(results: ResonatorPunchoutResults, platform: Platform, target: Union[str, int])[source]#
- qibocal.protocols.resonator_punchout.resonator_punchout = Routine(acquisition=<function _acquisition>, fit=<function _fit>, report=<function _plot>, update=<function _update>, two_qubit_gates=False)#
ResonatorPunchout Routine object.
qibocal.protocols.resonator_punchout_attenuation module#
- class qibocal.protocols.resonator_punchout_attenuation.ResonatorPunchoutAttenuationParameters(freq_width: int, freq_step: int, min_att: int, max_att: int, step_att: int)[source]#
Bases:
Parameters
ResonatorPunchoutAttenuation runcard inputs.
- class qibocal.protocols.resonator_punchout_attenuation.ResonatorPunchoutAttenuationResults(readout_frequency: dict[Union[str, int], float], bare_frequency: Optional[dict[Union[str, int], float]], readout_attenuation: dict[Union[str, int], int])[source]#
Bases:
Results
ResonatorPunchoutAttenation outputs.
- bare_frequency: Optional[dict[Union[str, int], float]]#
Bare resonator frequency [GHZ] for each qubit.
- qibocal.protocols.resonator_punchout_attenuation.ResPunchoutAttType = dtype([('freq', '<f8'), ('att', '<f8'), ('signal', '<f8'), ('phase', '<f8')])#
Custom dtype for resonator punchout.
- class qibocal.protocols.resonator_punchout_attenuation.ResonatorPunchoutAttenuationData(resonator_type: str, data: dict[typing.Union[str, int], numpy.ndarray[typing.Any, numpy.dtype[dtype([('freq', '<f8'), ('att', '<f8'), ('signal', '<f8'), ('phase', '<f8')])]]] = <factory>)[source]#
Bases:
Data
ResonatorPunchoutAttenuation data acquisition.
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- property pairs#
Access qubit pairs ordered alphanumerically from data structure.
- property qubits#
Access qubits from data structure.
- data: dict[typing.Union[str, int], numpy.ndarray[typing.Any, numpy.dtype[dtype([('freq', '<f8'), ('att', '<f8'), ('signal', '<f8'), ('phase', '<f8')])]]]#
Raw data acquired.
- qibocal.protocols.resonator_punchout_attenuation._acquisition(params: ResonatorPunchoutAttenuationParameters, platform: Platform, targets: list[Union[str, int]]) ResonatorPunchoutAttenuationData [source]#
Data acquisition for Punchout over attenuation.
- qibocal.protocols.resonator_punchout_attenuation._fit(data: ResonatorPunchoutAttenuationData, fit_type='att') ResonatorPunchoutAttenuationResults [source]#
Fit frequency and attenuation at high and low power for a given resonator.
- qibocal.protocols.resonator_punchout_attenuation._plot(data: ResonatorPunchoutAttenuationData, target: Union[str, int], fit: Optional[ResonatorPunchoutAttenuationResults] = None)[source]#
Plotting for ResonatorPunchoutAttenuation.
- qibocal.protocols.resonator_punchout_attenuation._update(results: ResonatorPunchoutAttenuationResults, platform: Platform, target: Union[str, int])[source]#
- qibocal.protocols.resonator_punchout_attenuation.resonator_punchout_attenuation = Routine(acquisition=<function _acquisition>, fit=<function _fit>, report=<function _plot>, update=<function _update>, two_qubit_gates=False)#
ResonatorPunchoutAttenuation Routine object.
qibocal.protocols.resonator_spectroscopy module#
- qibocal.protocols.resonator_spectroscopy.ResSpecType = dtype([('freq', '<f8'), ('signal', '<f8'), ('phase', '<f8'), ('error_signal', '<f8'), ('error_phase', '<f8')])#
Custom dtype for resonator spectroscopy.
- class qibocal.protocols.resonator_spectroscopy.ResonatorSpectroscopyFit(function: Callable, fit: Callable, chi2: Callable, values: Callable, errors: Callable, plot: Callable)[source]#
Bases:
object
ResonatorSpectroscopy fit.
- qibocal.protocols.resonator_spectroscopy.FITS = {'lorentzian': ResonatorSpectroscopyFit(function=<function lorentzian>, fit=<function lorentzian_fit>, chi2=<function chi2_reduced>, values=<function <lambda>>, errors=<function <lambda>>, plot=<function spectroscopy_plot>), 's21': ResonatorSpectroscopyFit(function=<function s21>, fit=<function s21_fit>, chi2=<function chi2_reduced_complex>, values=<function <lambda>>, errors=<function <lambda>>, plot=<function s21_spectroscopy_plot>)}#
Dictionary of available fitting routines for ResonatorSpectroscopy.
- class qibocal.protocols.resonator_spectroscopy.ResonatorSpectroscopyParameters(freq_width: int, freq_step: int, power_level: Union[PowerLevel, str], fit_function: str = 'lorentzian', phase_sign: bool = True, amplitude: Optional[float] = None, attenuation: Optional[int] = None, hardware_average: bool = True)[source]#
Bases:
Parameters
ResonatorSpectroscopy runcard inputs.
- power_level: Union[PowerLevel, str]#
Power regime (low or high). If low the readout frequency will be updated. If high both the readout frequency and the bare resonator frequency will be updated.
- phase_sign: bool = True#
Several instruments have their convention about the sign of the phase. If True, the routine will apply a minus to the phase data.
- amplitude: Optional[float] = None#
Readout amplitude (optional). If defined, same amplitude will be used in all qubits. Otherwise the default amplitude defined on the platform runcard will be used
- class qibocal.protocols.resonator_spectroscopy.ResonatorSpectroscopyResults(frequency: dict[typing.Union[str, int], float], fitted_parameters: dict[typing.Union[str, int], list[float]], bare_frequency: ~typing.Optional[dict[typing.Union[str, int], float]] = <factory>, error_fit_pars: dict[typing.Union[str, int], list] = <factory>, chi2_reduced: dict[typing.Union[str, int], tuple[float, typing.Optional[float]]] = <factory>, amplitude: ~typing.Optional[dict[typing.Union[str, int], float]] = <factory>, attenuation: ~typing.Optional[dict[typing.Union[str, int], int]] = <factory>)[source]#
Bases:
Results
ResonatorSpectroscopy outputs.
- bare_frequency: Optional[dict[Union[str, int], float]]#
Bare resonator frequency [Hz] for each qubit.
- class qibocal.protocols.resonator_spectroscopy.ResonatorSpectroscopyData(resonator_type: str, amplitudes: dict[typing.Union[str, int], float], fit_function: str = 'lorentzian', phase_sign: bool = False, data: dict[typing.Union[str, int], numpy.ndarray[typing.Any, numpy.dtype[dtype([('freq', '<f8'), ('signal', '<f8'), ('phase', '<f8'), ('error_signal', '<f8'), ('error_phase', '<f8')])]]] = <factory>, power_level: ~typing.Optional[~qibocal.protocols.utils.PowerLevel] = None, attenuations: ~typing.Optional[dict[typing.Union[str, int], int]] = <factory>)[source]#
Bases:
Data
Data structure for resonator spectroscopy with attenuation.
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- property pairs#
Access qubit pairs ordered alphanumerically from data structure.
- property qubits#
Access qubits from data structure.
- register_qubit(dtype, data_keys, data_dict)#
Store output for single qubit.
- phase_sign: bool = False#
Several instruments have their convention about the sign of the phase. If True, the routine will apply a minus to the phase data.
- data: dict[typing.Union[str, int], numpy.ndarray[typing.Any, numpy.dtype[dtype([('freq', '<f8'), ('signal', '<f8'), ('phase', '<f8'), ('error_signal', '<f8'), ('error_phase', '<f8')])]]]#
Raw data acquired.
- power_level: Optional[PowerLevel] = None#
Power regime of the resonator.
- qibocal.protocols.resonator_spectroscopy._acquisition(params: ResonatorSpectroscopyParameters, platform: Platform, targets: list[Union[str, int]]) ResonatorSpectroscopyData [source]#
Data acquisition for resonator spectroscopy.
- qibocal.protocols.resonator_spectroscopy._fit(data: ResonatorSpectroscopyData) ResonatorSpectroscopyResults [source]#
Post-processing function for ResonatorSpectroscopy.
- qibocal.protocols.resonator_spectroscopy._plot(data: ResonatorSpectroscopyData, target: Union[str, int], fit: ResonatorSpectroscopyResults)[source]#
Plotting function for ResonatorSpectroscopy.
- qibocal.protocols.resonator_spectroscopy._update(results: ResonatorSpectroscopyResults, platform: Platform, target: Union[str, int])[source]#
- qibocal.protocols.resonator_spectroscopy.resonator_spectroscopy = Routine(acquisition=<function _acquisition>, fit=<function _fit>, report=<function _plot>, update=<function _update>, two_qubit_gates=False)#
ResonatorSpectroscopy Routine object.
qibocal.protocols.resonator_utils module#
- qibocal.protocols.resonator_utils.PHASES_THRESHOLD_PERCENTAGE = 80#
pi circle.
- Type:
Threshold percentage to ensure the phase data covers a significant portion of the full 2
- Type:
math
- qibocal.protocols.resonator_utils.STD_DEV_GAUSSIAN_KERNEL = 30#
Standard deviation for the Gaussian kernel.
- qibocal.protocols.resonator_utils.PHASE_ELEMENTS = 5#
Number of values to better guess :math:` heta` (in rad) in the phase fit function.
- qibocal.protocols.resonator_utils.cable_delay(frequencies: ndarray[Any, dtype[_ScalarType_co]], phases: ndarray[Any, dtype[_ScalarType_co]], num_points: int) float [source]#
Evaluates the cable delay :math:` au` (in s).
The cable delay :math:` au` (in s) is caused by the length of the cable and the finite speed of light. This is estimated fitting a first-grade polynomial fit of the phases (in rad) as a function of the frequencies (in Hz), and extracting the angular coefficient, which is then expressed in seconds.
The num_points is used to select how many points should be fitted, from both the start and the end of the frequency range.
- qibocal.protocols.resonator_utils.remove_cable_delay(frequencies: ndarray[Any, dtype[_ScalarType_co]], z: ndarray[Any, dtype[_ScalarType_co]], tau: float) ndarray[Any, dtype[_ScalarType_co]] [source]#
Corrects the cable delay :math:` au` (in s).
The cable delay :math:` au` (in s) is removed from the scattering matrix element array z by performing an exponential product which also depends from the frequencies (in Hz).
- qibocal.protocols.resonator_utils.circle_fit(z: ndarray[Any, dtype[_ScalarType_co]]) tuple[complex, float] [source]#
Fits the circle of a scattering matrix element array.
The circle fit exploits the algebraic fit described in “Efficient and robust analysis of complex scattering data under noise in microwave resonators” (https://doi.org/10.1063/1.4907935) by S. Probst et al and “The physics of superconducting microwave resonators” (https://doi.org/10.7907/RAT0-VM75) by J. Gao.
The function, from the scattering matrix element array, evaluates the center coordinates x_c and y_c and the radius of the circle r_0.
- qibocal.protocols.resonator_utils.phase_fit(frequencies: ndarray[Any, dtype[_ScalarType_co]], phases: ndarray[Any, dtype[_ScalarType_co]]) ndarray[Any, dtype[_ScalarType_co]] [source]#
Fits the phase response of a resonator.
The phase fit firstly ensure the phase data (in rad) covers a significant portion of the full 2 \(\pi\) circle evaluating a roll_off. If the data do not cover a full circle it is possible to increase the frequency span around the resonance. Data are smoothed using a Gaussian filter and the derivative is evaluated while initial guesses for the parameters (resonance_guess (in Hz)), q_loaded_guess, tau_guess (in s) and theta_guess (in rad) are computed with frequencies (in Hz).
The parameter estimation is done through an iterative least squares process to optimize the model parameters. The defined functions: residuals_q_loaded, residuals_resonance_theta residuals_resonance_theta, residuals_tau, residuals_resonance_q_loaded, residuals_full take the parameters to be fitted and return the residuals calculated by subtracting the phase centered model from the phase data (in rad).
- qibocal.protocols.resonator_utils.phase_dist(phases: ndarray[Any, dtype[_ScalarType_co]]) ndarray[Any, dtype[_ScalarType_co]] [source]#
Maps phases (in rad) [-2pi, 2pi] to phase distance on circle [0, pi].
- qibocal.protocols.resonator_utils.phase_centered(frequencies: ndarray[Any, dtype[_ScalarType_co]], resonance: float, q_loaded: float, theta: float, tau: float = 0.0) ndarray[Any, dtype[_ScalarType_co]] [source]#
Evaluates the phase (in rad) response of a resonator.
The phase centered evaluates the phase angle (in rad) of a circle centered around the origin accounting for a phase offset :math:` heta` (in rad), a linear background slope :math: 2pi ` au` (in s) (frequencies (in Hz) - resonance (in Hz)) (if needed) and a dependency on the q_loaded.
qibocal.protocols.state_tomography module#
- qibocal.protocols.state_tomography.BASIS = ['X', 'Y', 'Z']#
Single qubit measurement basis.
- qibocal.protocols.state_tomography.CIRCUIT_PATH = 'circuit.json'#
Path where circuit is stored.
- class qibocal.protocols.state_tomography.StateTomographyParameters(circuit: Optional[Union[str, Circuit]] = None)[source]#
Bases:
Parameters
Tomography input parameters
- qibocal.protocols.state_tomography.TomographyType = dtype([('samples', '<i8')])#
Custom dtype for tomography.
- class qibocal.protocols.state_tomography.StateTomographyData(targets: dict[typing.Union[str, int], int], circuit: ~qibo.models.circuit.Circuit, data: dict[tuple[typing.Union[str, int], str], numpy.int64] = <factory>)[source]#
Bases:
Data
Tomography data
- circuit: Circuit#
Circuit where tomography will be executed.
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- property pairs#
Access qubit pairs ordered alphanumerically from data structure.
- property qubits#
Access qubits from data structure.
- class qibocal.protocols.state_tomography.StateTomographyResults(measured_density_matrix_real: dict[Union[str, int], list], measured_density_matrix_imag: dict[Union[str, int], list], target_density_matrix_real: dict[Union[str, int], list], target_density_matrix_imag: dict[Union[str, int], list], fidelity: dict[Union[str, int], float])[source]#
Bases:
Results
Tomography results
- measured_density_matrix_imag: dict[Union[str, int], list]#
Imaginary part of measured density matrix.
- qibocal.protocols.state_tomography._acquisition(params: StateTomographyParameters, platform: Platform, targets: list[Union[str, int]]) StateTomographyData [source]#
Acquisition protocol for single qubit state tomography experiment.
- qibocal.protocols.state_tomography._fit(data: StateTomographyData) StateTomographyResults [source]#
Post-processing for State tomography.
- qibocal.protocols.state_tomography.plot_parallelogram(a, e, pos_x, pos_y, **options)[source]#
Plotting single histogram in 3d plot.
- qibocal.protocols.state_tomography.plot_rho(fig, zz, trace_options, figure_options, showlegend=None)[source]#
Plot density matrix
- qibocal.protocols.state_tomography.plot_reconstruction(ideal, measured)[source]#
Plot 3D plot with reconstruction of ideal and measured density matrix.
- qibocal.protocols.state_tomography._plot(data: StateTomographyData, fit: StateTomographyResults, target: Union[str, int])[source]#
Plotting for state tomography
qibocal.protocols.two_qubit_state_tomography module#
- qibocal.protocols.two_qubit_state_tomography.SIMULATED_DENSITY_MATRIX = 'ideal'#
Filename for simulated density matrix.
- qibocal.protocols.two_qubit_state_tomography.TomographyType = dtype([('frequencies', '<i8'), ('simulation_probabilities', '<f8')])#
Custom dtype for tomography.
- class qibocal.protocols.two_qubit_state_tomography.StateTomographyData(data: dict[tuple[typing.Union[str, int], typing.Union[str, int], str, str], numpy.int64] = <factory>, ideal: dict[typing.Tuple[typing.Union[str, int], typing.Union[str, int]], numpy.ndarray] = <factory>, simulated: ~typing.Optional[~qibo.result.QuantumState] = None)[source]#
Bases:
Data
Tomography data.
- _to_npz(path: Path, filename: str)#
Helper function to use np.savez while converting keys into strings.
- property pairs#
Access qubit pairs ordered alphanumerically from data structure.
- property qubits#
Access qubits from data structure.
- class qibocal.protocols.two_qubit_state_tomography.StateTomographyResults(measured_raw_density_matrix_real: dict[typing.Tuple[typing.Union[str, int], typing.Union[str, int]], list] = <factory>, measured_raw_density_matrix_imag: dict[typing.Tuple[typing.Union[str, int], typing.Union[str, int]], list] = <factory>, measured_density_matrix_real: dict[typing.Tuple[typing.Union[str, int], typing.Union[str, int]], list] = <factory>, measured_density_matrix_imag: dict[typing.Tuple[typing.Union[str, int], typing.Union[str, int]], list] = <factory>, fidelity: dict[typing.Union[str, int], float] = <factory>)[source]#
Bases:
Results
Tomography results.
- measured_raw_density_matrix_real: dict[Tuple[Union[str, int], Union[str, int]], list]#
Real part of measured density matrix before projecting.
- measured_raw_density_matrix_imag: dict[Tuple[Union[str, int], Union[str, int]], list]#
Imaginary part of measured density matrix before projecting.
- measured_density_matrix_real: dict[Tuple[Union[str, int], Union[str, int]], list]#
Real part of measured density matrix after projecting.
- measured_density_matrix_imag: dict[Tuple[Union[str, int], Union[str, int]], list]#
Imaginary part of measured density matrix after projecting.
- qibocal.protocols.two_qubit_state_tomography._acquisition(params: StateTomographyParameters, platform: Platform, targets: list[Tuple[Union[str, int], Union[str, int]]]) StateTomographyData [source]#
Acquisition protocol for two qubit state tomography experiment.
- qibocal.protocols.two_qubit_state_tomography.rotation_matrix(basis)[source]#
Matrix of the gate implementing the rotation to the given basis.
- Parameters:
basis (str) – One of Pauli basis: X, Y or Z.
- qibocal.protocols.two_qubit_state_tomography.project_psd(matrix)[source]#
Project matrix to the space of positive semidefinite matrices.
- qibocal.protocols.two_qubit_state_tomography._fit(data: StateTomographyData) StateTomographyResults [source]#
Post-processing for two qubit state tomography.
Uses a linear inversion algorithm to reconstruct the density matrix from measurements, with the following steps: 1. Construct a linear transformation M, from density matrix to Born-probabilities in the space of all two-qubit measurement bases (in our case XX, XY, XZ, YX, YY, YZ, ZX, ZY, ZZ). 2. Invert M to get the transformation from Born-probabilities to density matrices. 3. Calculate vector of Born-probabilities from experimental measurements (frequencies). 4. Map this vector to a density matrix (
measured_raw_density_matrix
) using the inverse of M from step 2. 5. Project the calculated density matrix to the space of positive semidefinite matrices (measured_density_matrix
) using the functionproject_psd
.
qibocal.protocols.utils module#
- qibocal.protocols.utils.HBAR = 1.0545718176461565e-34#
Chi2 output when errors list contains zero elements
- qibocal.protocols.utils.CONFIDENCE_INTERVAL_FIRST_MASK = 99#
Confidence interval used to mask flux data.
- qibocal.protocols.utils.CONFIDENCE_INTERVAL_SECOND_MASK = 70#
Confidence interval used to clean outliers.
- qibocal.protocols.utils.DELAY_FIT_PERCENTAGE = 10#
Percentage of the first and last points used to fit the cable delay.
- qibocal.protocols.utils.effective_qubit_temperature(prob_0: ndarray[Any, dtype[_ScalarType_co]], prob_1: ndarray[Any, dtype[_ScalarType_co]], qubit_frequency: float, nshots: int)[source]#
Calculates the qubit effective temperature.
The formula used is the following one:
kB Teff = - hbar qubit_freq / ln(prob_1/prob_0)
- qibocal.protocols.utils.calculate_frequencies(results, qubit_list)[source]#
Calculates outcome frequencies from individual shots. :param results: return of execute_pulse_sequence :type results: dict :param qubit_list: list of qubit ids executed in pulse sequence. :type qubit_list: list
- Returns:
dictionary containing frequencies.
- class qibocal.protocols.utils.PowerLevel(value)[source]#
-
Power Regime for Resonator Spectroscopy
- high = 'high'#
- low = 'low'#
- _generate_next_value_(start, count, last_values)#
Generate the next value when not given.
name: the name of the member start: the initial start value or None count: the number of existing members last_value: the last value assigned or None
- _member_names_ = ['high', 'low']#
- _member_map_ = {'high': PowerLevel.high, 'low': PowerLevel.low}#
- _value2member_map_ = {'high': PowerLevel.high, 'low': PowerLevel.low}#
- qibocal.protocols.utils.s21(frequencies: ndarray[Any, dtype[_ScalarType_co]], resonance: float, q_loaded: float, q_coupling: float, phi: float = 0.0, amplitude: float = 1.0, alpha: float = 0.0, tau: float = 0.0) ndarray[Any, dtype[_ScalarType_co]] [source]#
Full model of the S21 notch resonator based on eq. (1) described in: “Efficient and robust analysis of complex scattering data under noise in microwave resonators” (https://doi.org/10.1063/1.4907935) by S. Probst et al and on eq. (E.1) described in: “The Physics of Superconducting Microwave Resonators” (https://doi.org/10.7907/RAT0-VM75) by J. Gao.
The equation is split into two parts describing the ideal resonator and the environment.
- Parameters:
frequencies (NDArray[float]) – frequencies (Hz) at which the measurement was taken.
resonance (float) – resonance frequency (Hz).
q_loaded (float) – loaded quality factor.
q_coupling (float) – coupling quality factor.
phi (float) – quantifies the impedance mismatch (Fano interference).
amplitude (float) – accounts for additional attenuation/amplification present in the setup.
alpha (float) – accounts for a additional phase shift.
tau (float) – cable delay caused by the length of the cable and finite speed of light.
- Returns:
S21 resonance profile array (NDArray) of a notch resonator.
- qibocal.protocols.utils.s21_fit(data: ndarray[Any, dtype[_ScalarType_co]], resonator_type=None, fit=None) tuple[float, list[float], list[float]] [source]#
Calibrates the S21 profile of a notch resonator, based on https://github.com/qkitgroup/qkit.
- Args:
data (NDArray[complex]): S21 scattering matrix element.
- Returns:
Model parameters
- qibocal.protocols.utils.cumulative(input_data, points)[source]#
Evaluates in data the cumulative distribution function of points.
- qibocal.protocols.utils.fit_punchout(data: Data, fit_type: str)[source]#
Punchout fitting function.
Args:
data (Data): Punchout acquisition data. fit_type (str): Punchout type, it could be amp (amplitude) or att (attenuation).
Return:
List of dictionaries containing the low, high amplitude (attenuation) frequencies and the readout amplitude (attenuation) for each qubit.
- qibocal.protocols.utils.round_report(measure: list) tuple[list, list] [source]#
Rounds the measured values and their errors according to their significant digits.
- Parameters:
measure (list) – Variable-Errors couples.
- Returns:
A tuple with the lists of values and errors in the correct string format.
- qibocal.protocols.utils.format_error_single_cell(measure: tuple)[source]#
Helper function to print mean value and error in one line.
- qibocal.protocols.utils.chi2_reduced(observed: ndarray[Any, dtype[_ScalarType_co]], estimated: ndarray[Any, dtype[_ScalarType_co]], errors: ndarray[Any, dtype[_ScalarType_co]], dof: Optional[float] = None)[source]#
- qibocal.protocols.utils.chi2_reduced_complex(observed: tuple[numpy.ndarray[typing.Any, numpy.dtype[+_ScalarType_co]], numpy.ndarray[typing.Any, numpy.dtype[+_ScalarType_co]]], estimated: ndarray[Any, dtype[_ScalarType_co]], errors: tuple[numpy.ndarray[typing.Any, numpy.dtype[+_ScalarType_co]], numpy.ndarray[typing.Any, numpy.dtype[+_ScalarType_co]]], dof: Optional[float] = None)[source]#
- qibocal.protocols.utils.significant_digit(number: float)[source]#
Computes the position of the first significant digit of a given number.
- Parameters:
number (Number) – number for which the significant digit is computed. Can be complex.
- Returns:
- position of the first significant digit. Returns
-1
if the given number is
>= 1
,= 0
orinf
.
- position of the first significant digit. Returns
- Return type:
- qibocal.protocols.utils.evaluate_grid(data: ndarray[Any, dtype[_ScalarType_co]])[source]#
This function returns a matrix grid evaluated from the datapoints data.
- qibocal.protocols.utils.plot_results(data: Data, qubit: Union[str, int], qubit_states: list, fit: Results)[source]#
Plots for the qubit and qutrit classification.
- qibocal.protocols.utils.table_dict(qubit: Union[list[Union[str, int]], str, int], names: list[str], values: list, display_error=False) dict [source]#
Build a dictionary to generate HTML table with table_html.
- Parameters:
qubit (Union[list[QubitId], QubitId]) – If qubit is a scalar value,
repeated. (the "Qubit" entries will have only this value) –
values (list) – List of the values of the parameters.
display_errors (bool) – if True, it means that values is a list of value-error couples,
False. (so an Errors key will be displayed in the dictionary. The function will round the couples according to their significant digits. Default) –
- Returns:
A dictionary with keys Qubit, Parameters, Values (Errors).
- qibocal.protocols.utils.table_html(data: dict) str [source]#
This function converts a dictionary into an HTML table.
- Parameters:
data (dict) – the keys will be converted into table entries and the
table. (values will be the columns of the) –
strings. (Values must be valid HTML) –
- Returns:
str
- qibocal.protocols.utils.extract_feature(x: ndarray, y: ndarray, z: ndarray, feat: str, ci_first_mask: float = 99, ci_second_mask: float = 70)[source]#
Extract feature using confidence intervals.
Given a dataset of the form (x, y, z) where a spike or a valley is expected, this function discriminate the points (x, y) with a signal, from the pure noise and return the first ones.
A first mask is construct by looking at ci_first_mask confidence interval for each y bin. A second mask is applied by looking at ci_second_mask confidence interval to remove outliers. feat could be min or max, in the first case the function will look for valleys, otherwise for peaks.