qat.experimental.conversion.pulse_to_q1.passes module

Pass and pipeline definitions for the Pulse-to-Q1 conversion.

class PulseToQ1LoweringPass(target_data=QbloxTargetData(max_acquisitions=10000, default_shots=1000, QUBIT_DATA=QubitDescription(sample_time=1e-09, samples_per_clock_cycle=1, instruction_memory_size=50000, waveform_memory_size=1500, pulse_duration_min=6.4e-08, pulse_duration_max=0.001, pulse_channel_lo_freq_min=1000000, pulse_channel_lo_freq_max=10000000000, pulse_channel_if_freq_min=0, pulse_channel_if_freq_max=10000000000, passive_reset_time=0.001), RESONATOR_DATA=ResonatorDescription(sample_time=1e-09, samples_per_clock_cycle=1, instruction_memory_size=50000, waveform_memory_size=1500, pulse_duration_min=6.4e-08, pulse_duration_max=0.001, pulse_channel_lo_freq_min=1000000, pulse_channel_lo_freq_max=10000000000, pulse_channel_if_freq_min=0, pulse_channel_if_freq_max=10000000000), driver_version=SemanticVersion(major=1, minor=2, patch=2, prerelease=None, build=None), fw_version=SemanticVersion(major=0, minor=13, patch=0, prerelease=None, build=None), Q1ASM_DATA=Q1asmDescription(min_gain=-32768, max_gain=32767, min_offset=-32768, max_offset=32767, max_wait_time=65532, register_size=4294967295, loop_unroll_threshold=4), CONTROL_SEQUENCER_DATA=ControlSequencerDescription(grid_time=4, nco_min_freq=-500000000.0, nco_max_freq=500000000.0, nco_max_phase_steps=1000000000, nco_phase_steps_per_deg=2777777.777777778, nco_freq_steps_per_hz=4, nco_freq_limit_steps=2000000000.0, number_of_registers=64, min_acq_integration_length=4, max_acq_integration_length=16777212, min_acq_threshold=-16777212, max_acq_threshold=16777212, max_sample_size_waveforms=16384, max_num_instructions=16384), READOUT_SEQUENCER_DATA=ReadoutSequencerDescription(grid_time=4, nco_min_freq=-500000000.0, nco_max_freq=500000000.0, nco_max_phase_steps=1000000000, nco_phase_steps_per_deg=2777777.777777778, nco_freq_steps_per_hz=4, nco_freq_limit_steps=2000000000.0, number_of_registers=64, min_acq_integration_length=4, max_acq_integration_length=16777212, min_acq_threshold=-16777212, max_acq_threshold=16777212, max_sample_size_waveforms=16384, max_num_instructions=12288), QCM_DATA=QcmDescription(number_of_sequencers=6, min_qcm_offset_v=-2.5, max_qcm_offset_v=2.5, output_connections={0: [0, 1, 2, 3, 4, 5], 1: [0, 1, 2, 3, 4, 5], 2: [0, 1, 2, 3, 4, 5], 3: [0, 1, 2, 3, 4, 5]}), QCM_RF_DATA=QcmRfDescription(number_of_sequencers=6, min_qcm_rf_offset_mv=-84, max_qcm_rf_offset_mv=73, min_out_att_db=0, max_out_att_db=60, output_connections={0: [0, 1, 2, 3, 4, 5], 1: [0, 1, 2, 3, 4, 5]}), QRM_DATA=QrmDescription(number_of_sequencers=6, min_sample_size_scope_acquisitions=4, max_sample_size_scope_acquisitions=16384, max_binned_acquisitions=3000000, min_qrm_offset_v=-0.09, max_qrm_offset_v=0.09, output_connections={0: [0, 1, 2, 3, 4, 5], 1: [0, 1, 2, 3, 4, 5]}, input_connections={0: [0, 1, 2, 3, 4, 5], 1: [0, 1, 2, 3, 4, 5]}), QRM_RF_DATA=QrmRfDescription(number_of_sequencers=6, min_sample_size_scope_acquisitions=4, max_sample_size_scope_acquisitions=16384, max_binned_acquisitions=3000000, min_qrm_rf_offset_v=-0.09, max_qrm_rf_offset_v=0.09, min_out_att_db=0, max_out_att_db=60, min_in_att_db=0, max_in_att_db=30, output_connections={0: [0, 1, 2, 3, 4, 5]}, input_connections={0: [0, 1, 2, 3, 4, 5]}), QRC_DATA=QrcDescription(number_of_sequencers=12, min_sample_size_scope_acquisitions=4, max_sample_size_scope_acquisitions=16384, max_binned_acquisitions=7000000, number_of_readout_sequencers=8, number_of_control_sequencers=4, min_out_att_db=0.0, max_out_att_db=31.5, min_in_att_db=0.0, max_in_att_db=31.5, output_connections={0: [0, 1, 2, 3, 4, 5, 6, 7], 1: [0, 1, 2, 3, 4, 5, 6, 7], 2: [0, 4, 8, 9, 10, 11], 3: [1, 5, 8, 9, 10, 11], 4: [2, 6, 8, 9, 10, 11], 5: [3, 7, 8, 9, 10, 11]}, input_connections={0: [0, 1, 2, 3, 4, 5, 6, 7], 1: [0, 1, 2, 3, 4, 5, 6, 7]})))

Bases: ModulePass

Apply the Pulse-to-Q1 rewrite stage inside outlined sequences.

Q1OutliningPass first isolates one logical sequence envelope for each frame partition. This pass then traverses those envelopes and applies the per-operation rewrite set that converts Pulse-level instructions into the flat Q1 instruction dialect.

apply(ctx, op)
Return type:

None

name: ClassVar[str] = 'pulse-to-q1-lowering'
target_data: QbloxTargetData = QbloxTargetData(max_acquisitions=10000, default_shots=1000, QUBIT_DATA=QubitDescription(sample_time=1e-09, samples_per_clock_cycle=1, instruction_memory_size=50000, waveform_memory_size=1500, pulse_duration_min=6.4e-08, pulse_duration_max=0.001, pulse_channel_lo_freq_min=1000000, pulse_channel_lo_freq_max=10000000000, pulse_channel_if_freq_min=0, pulse_channel_if_freq_max=10000000000, passive_reset_time=0.001), RESONATOR_DATA=ResonatorDescription(sample_time=1e-09, samples_per_clock_cycle=1, instruction_memory_size=50000, waveform_memory_size=1500, pulse_duration_min=6.4e-08, pulse_duration_max=0.001, pulse_channel_lo_freq_min=1000000, pulse_channel_lo_freq_max=10000000000, pulse_channel_if_freq_min=0, pulse_channel_if_freq_max=10000000000), driver_version=SemanticVersion(major=1, minor=2, patch=2, prerelease=None, build=None), fw_version=SemanticVersion(major=0, minor=13, patch=0, prerelease=None, build=None), Q1ASM_DATA=Q1asmDescription(min_gain=-32768, max_gain=32767, min_offset=-32768, max_offset=32767, max_wait_time=65532, register_size=4294967295, loop_unroll_threshold=4), CONTROL_SEQUENCER_DATA=ControlSequencerDescription(grid_time=4, nco_min_freq=-500000000.0, nco_max_freq=500000000.0, nco_max_phase_steps=1000000000, nco_phase_steps_per_deg=2777777.777777778, nco_freq_steps_per_hz=4, nco_freq_limit_steps=2000000000.0, number_of_registers=64, min_acq_integration_length=4, max_acq_integration_length=16777212, min_acq_threshold=-16777212, max_acq_threshold=16777212, max_sample_size_waveforms=16384, max_num_instructions=16384), READOUT_SEQUENCER_DATA=ReadoutSequencerDescription(grid_time=4, nco_min_freq=-500000000.0, nco_max_freq=500000000.0, nco_max_phase_steps=1000000000, nco_phase_steps_per_deg=2777777.777777778, nco_freq_steps_per_hz=4, nco_freq_limit_steps=2000000000.0, number_of_registers=64, min_acq_integration_length=4, max_acq_integration_length=16777212, min_acq_threshold=-16777212, max_acq_threshold=16777212, max_sample_size_waveforms=16384, max_num_instructions=12288), QCM_DATA=QcmDescription(number_of_sequencers=6, min_qcm_offset_v=-2.5, max_qcm_offset_v=2.5, output_connections={0: [0, 1, 2, 3, 4, 5], 1: [0, 1, 2, 3, 4, 5], 2: [0, 1, 2, 3, 4, 5], 3: [0, 1, 2, 3, 4, 5]}), QCM_RF_DATA=QcmRfDescription(number_of_sequencers=6, min_qcm_rf_offset_mv=-84, max_qcm_rf_offset_mv=73, min_out_att_db=0, max_out_att_db=60, output_connections={0: [0, 1, 2, 3, 4, 5], 1: [0, 1, 2, 3, 4, 5]}), QRM_DATA=QrmDescription(number_of_sequencers=6, min_sample_size_scope_acquisitions=4, max_sample_size_scope_acquisitions=16384, max_binned_acquisitions=3000000, min_qrm_offset_v=-0.09, max_qrm_offset_v=0.09, output_connections={0: [0, 1, 2, 3, 4, 5], 1: [0, 1, 2, 3, 4, 5]}, input_connections={0: [0, 1, 2, 3, 4, 5], 1: [0, 1, 2, 3, 4, 5]}), QRM_RF_DATA=QrmRfDescription(number_of_sequencers=6, min_sample_size_scope_acquisitions=4, max_sample_size_scope_acquisitions=16384, max_binned_acquisitions=3000000, min_qrm_rf_offset_v=-0.09, max_qrm_rf_offset_v=0.09, min_out_att_db=0, max_out_att_db=60, min_in_att_db=0, max_in_att_db=30, output_connections={0: [0, 1, 2, 3, 4, 5]}, input_connections={0: [0, 1, 2, 3, 4, 5]}), QRC_DATA=QrcDescription(number_of_sequencers=12, min_sample_size_scope_acquisitions=4, max_sample_size_scope_acquisitions=16384, max_binned_acquisitions=7000000, number_of_readout_sequencers=8, number_of_control_sequencers=4, min_out_att_db=0.0, max_out_att_db=31.5, min_in_att_db=0.0, max_in_att_db=31.5, output_connections={0: [0, 1, 2, 3, 4, 5, 6, 7], 1: [0, 1, 2, 3, 4, 5, 6, 7], 2: [0, 4, 8, 9, 10, 11], 3: [1, 5, 8, 9, 10, 11], 4: [2, 6, 8, 9, 10, 11], 5: [3, 7, 8, 9, 10, 11]}, input_connections={0: [0, 1, 2, 3, 4, 5, 6, 7], 1: [0, 1, 2, 3, 4, 5, 6, 7]}))
create_default_pulse_to_q1_pipeline(target_data=QbloxTargetData(max_acquisitions=10000, default_shots=1000, QUBIT_DATA=QubitDescription(sample_time=1e-09, samples_per_clock_cycle=1, instruction_memory_size=50000, waveform_memory_size=1500, pulse_duration_min=6.4e-08, pulse_duration_max=0.001, pulse_channel_lo_freq_min=1000000, pulse_channel_lo_freq_max=10000000000, pulse_channel_if_freq_min=0, pulse_channel_if_freq_max=10000000000, passive_reset_time=0.001), RESONATOR_DATA=ResonatorDescription(sample_time=1e-09, samples_per_clock_cycle=1, instruction_memory_size=50000, waveform_memory_size=1500, pulse_duration_min=6.4e-08, pulse_duration_max=0.001, pulse_channel_lo_freq_min=1000000, pulse_channel_lo_freq_max=10000000000, pulse_channel_if_freq_min=0, pulse_channel_if_freq_max=10000000000), driver_version=SemanticVersion(major=1, minor=2, patch=2, prerelease=None, build=None), fw_version=SemanticVersion(major=0, minor=13, patch=0, prerelease=None, build=None), Q1ASM_DATA=Q1asmDescription(min_gain=-32768, max_gain=32767, min_offset=-32768, max_offset=32767, max_wait_time=65532, register_size=4294967295, loop_unroll_threshold=4), CONTROL_SEQUENCER_DATA=ControlSequencerDescription(grid_time=4, nco_min_freq=-500000000.0, nco_max_freq=500000000.0, nco_max_phase_steps=1000000000, nco_phase_steps_per_deg=2777777.777777778, nco_freq_steps_per_hz=4, nco_freq_limit_steps=2000000000.0, number_of_registers=64, min_acq_integration_length=4, max_acq_integration_length=16777212, min_acq_threshold=-16777212, max_acq_threshold=16777212, max_sample_size_waveforms=16384, max_num_instructions=16384), READOUT_SEQUENCER_DATA=ReadoutSequencerDescription(grid_time=4, nco_min_freq=-500000000.0, nco_max_freq=500000000.0, nco_max_phase_steps=1000000000, nco_phase_steps_per_deg=2777777.777777778, nco_freq_steps_per_hz=4, nco_freq_limit_steps=2000000000.0, number_of_registers=64, min_acq_integration_length=4, max_acq_integration_length=16777212, min_acq_threshold=-16777212, max_acq_threshold=16777212, max_sample_size_waveforms=16384, max_num_instructions=12288), QCM_DATA=QcmDescription(number_of_sequencers=6, min_qcm_offset_v=-2.5, max_qcm_offset_v=2.5, output_connections={0: [0, 1, 2, 3, 4, 5], 1: [0, 1, 2, 3, 4, 5], 2: [0, 1, 2, 3, 4, 5], 3: [0, 1, 2, 3, 4, 5]}), QCM_RF_DATA=QcmRfDescription(number_of_sequencers=6, min_qcm_rf_offset_mv=-84, max_qcm_rf_offset_mv=73, min_out_att_db=0, max_out_att_db=60, output_connections={0: [0, 1, 2, 3, 4, 5], 1: [0, 1, 2, 3, 4, 5]}), QRM_DATA=QrmDescription(number_of_sequencers=6, min_sample_size_scope_acquisitions=4, max_sample_size_scope_acquisitions=16384, max_binned_acquisitions=3000000, min_qrm_offset_v=-0.09, max_qrm_offset_v=0.09, output_connections={0: [0, 1, 2, 3, 4, 5], 1: [0, 1, 2, 3, 4, 5]}, input_connections={0: [0, 1, 2, 3, 4, 5], 1: [0, 1, 2, 3, 4, 5]}), QRM_RF_DATA=QrmRfDescription(number_of_sequencers=6, min_sample_size_scope_acquisitions=4, max_sample_size_scope_acquisitions=16384, max_binned_acquisitions=3000000, min_qrm_rf_offset_v=-0.09, max_qrm_rf_offset_v=0.09, min_out_att_db=0, max_out_att_db=60, min_in_att_db=0, max_in_att_db=30, output_connections={0: [0, 1, 2, 3, 4, 5]}, input_connections={0: [0, 1, 2, 3, 4, 5]}), QRC_DATA=QrcDescription(number_of_sequencers=12, min_sample_size_scope_acquisitions=4, max_sample_size_scope_acquisitions=16384, max_binned_acquisitions=7000000, number_of_readout_sequencers=8, number_of_control_sequencers=4, min_out_att_db=0.0, max_out_att_db=31.5, min_in_att_db=0.0, max_in_att_db=31.5, output_connections={0: [0, 1, 2, 3, 4, 5, 6, 7], 1: [0, 1, 2, 3, 4, 5, 6, 7], 2: [0, 4, 8, 9, 10, 11], 3: [1, 5, 8, 9, 10, 11], 4: [2, 6, 8, 9, 10, 11], 5: [3, 7, 8, 9, 10, 11]}, input_connections={0: [0, 1, 2, 3, 4, 5, 6, 7], 1: [0, 1, 2, 3, 4, 5, 6, 7]})))

Create the default pass pipeline for Pulse-to-Q1 conversion.

The default pipeline proceeds in two stages. It first outlines the Pulse program into per-frame q1_sequence.sequence envelopes. It then applies the lowering rewrite set within those emitted sequences.

Parameters:

target_data (QbloxTargetData) – Optional QBlox target description used by both stages.

Return type:

PassPipeline

Returns:

Pass pipeline for the default Pulse-to-Q1 conversion flow.