pulse_factories#

Module containing factory functions for pulses on the quantum-device layer.

These factories take a parametrized representation of an operation and create an instance of the operation itself. The created operations make use of Qblox-specific hardware features.

Module Contents#

Functions#

long_square_pulse(...)

Create a long square pulse using DC voltage offsets.

staircase_pulse(...)

Create a staircase-shaped pulse using DC voltage offsets.

long_ramp_pulse(...)

Creates a long ramp pulse by stitching together shorter ramps.

long_square_pulse(amp: float, duration: float, port: str, clock: str = BasebandClockResource.IDENTITY, t0: float = 0, reference_magnitude: quantify_scheduler.operations.pulse_library.ReferenceMagnitude | None = None) quantify_scheduler.backends.qblox.operations.stitched_pulse.StitchedPulse[source]#

Create a long square pulse using DC voltage offsets.

Warning

This function creates a StitchedPulse object, containing a combination of voltage offsets and waveforms. Overlapping StitchedPulses on the same port and clock may lead to unexpected results.

Parameters:
  • amp (float) – Amplitude of the envelope.

  • duration (float) – The pulse duration in seconds.

  • port (str) – Port of the pulse, must be capable of playing a complex waveform.

  • clock (str, optional) – Clock used to modulate the pulse. By default the baseband clock.

  • t0 (float, optional) – Time in seconds when to start the pulses relative to the start time of the Operation in the Schedule. By default 0.

  • reference_magnitude (optional) – Scaling value and unit for the unitless amplitude. Uses settings in hardware config if not provided.

Returns:

A StitchedPulse object containing an offset instruction with the specified amplitude.

Return type:

StitchedPulse

Raises:

ValueError – When the duration of the pulse is not a multiple of grid_time_ns.

staircase_pulse(start_amp: float, final_amp: float, num_steps: int, duration: float, port: str, clock: str = BasebandClockResource.IDENTITY, t0: float = 0, min_operation_time_ns: int = constants.MIN_TIME_BETWEEN_OPERATIONS, reference_magnitude: quantify_scheduler.operations.pulse_library.ReferenceMagnitude | None = None) quantify_scheduler.backends.qblox.operations.stitched_pulse.StitchedPulse[source]#

Create a staircase-shaped pulse using DC voltage offsets.

This function generates a real valued staircase pulse, which reaches its final amplitude in discrete steps. In between it will maintain a plateau.

Warning

This function creates a StitchedPulse object, containing a combination of voltage offsets and waveforms. Overlapping StitchedPulses on the same port and clock may lead to unexpected results.

Parameters:
  • start_amp (float) – Starting amplitude of the staircase envelope function.

  • final_amp (float) – Final amplitude of the staircase envelope function.

  • num_steps (int) – The number of plateaus.

  • duration (float) – Duration of the pulse in seconds.

  • port (str) – Port of the pulse.

  • clock (str, optional) – Clock used to modulate the pulse. By default the baseband clock.

  • t0 (float, optional) – Time in seconds when to start the pulses relative to the start time of the Operation in the Schedule. By default 0.

  • min_operation_time_ns (int, optional) – Min operation time in ns. The duration of the long_square_pulse must be a multiple of this. By default equal to the min operation time time of Qblox modules.

  • reference_magnitude (optional) – Scaling value and unit for the unitless amplitude. Uses settings in hardware config if not provided.

Returns:

A StitchedPulse object containing incrementing or decrementing offset instructions.

Return type:

StitchedPulse

Raises:

ValueError – When the duration of a step is not a multiple of grid_time_ns.

long_ramp_pulse(amp: float, duration: float, port: str, offset: float = 0, clock: str = BasebandClockResource.IDENTITY, t0: float = 0, part_duration_ns: int = constants.STITCHED_PULSE_PART_DURATION_NS, reference_magnitude: quantify_scheduler.operations.pulse_library.ReferenceMagnitude | None = None) quantify_scheduler.backends.qblox.operations.stitched_pulse.StitchedPulse[source]#

Creates a long ramp pulse by stitching together shorter ramps.

This function creates a long ramp pulse by stitching together ramp pulses of the specified duration part_duration_ns, with DC voltage offset instructions placed in between.

Warning

This function creates a StitchedPulse object, containing a combination of voltage offsets and waveforms. Overlapping StitchedPulses on the same port and clock may lead to unexpected results.

Parameters:
  • amp (float) – Amplitude of the ramp envelope function.

  • duration (float) – The pulse duration in seconds.

  • port (str) – Port of the pulse.

  • offset (float, optional) – Starting point of the ramp pulse. By default 0.

  • clock (str, optional) – Clock used to modulate the pulse, by default the baseband clock.

  • t0 (float, optional) – Time in seconds when to start the pulses relative to the start time of the Operation in the Schedule. By default 0.

  • part_duration_ns (int, optional) – Duration of each partial ramp in nanoseconds, by default STITCHED_PULSE_PART_DURATION_NS.

  • reference_magnitude (optional) – Scaling value and unit for the unitless amplitude. Uses settings in hardware config if not provided.

Returns:

A StitchedPulse composed of shorter ramp pulses with varying DC offsets, forming one long ramp pulse.

Return type:

StitchedPulse