common#

Common python dataclasses for multiple backends.

Module Contents#

Classes#

LatencyCorrection

Latency correction in seconds for a port-clock combination.

DistortionCorrection

Distortion correction information for a port-clock combination.

ModulationFrequencies

Modulation frequencies for a port-clock combination.

MixerCorrections

Mixer corrections for a port-clock combination.

HardwareOptions

Datastructure containing the hardware options for each port-clock combination.

LocalOscillatorDescription

Information needed to specify a Local Oscillator in the CompilationConfig.

HardwareDescription

Specifies a piece of hardware and its instrument-specific settings.

Connectivity

Connectivity between ports on the quantum device and on the control hardware.

HardwareCompilationConfig

Information required to compile a schedule to the control-hardware layer.

class LatencyCorrection[source]#

Bases: float

Latency correction in seconds for a port-clock combination.

Positive values delay the operations on the corresponding port-clock combination, while negative values shift the operation backwards in time with respect to other operations in the schedule.

Note

If the port-clock combination of a signal is not specified in the corrections, it is set to zero in compilation. The minimum correction over all port-clock combinations is then subtracted to allow for negative latency corrections and to ensure minimal wait time (see determine_relative_latency_corrections()).

Initialize self. See help(type(self)) for accurate signature.

class DistortionCorrection(**data: Any)[source]#

Bases: quantify_scheduler.structure.model.DataStructure

Distortion correction information for a port-clock combination.

Create a new model by parsing and validating input data from keyword arguments.

Raises ValidationError if the input data cannot be parsed to form a valid model.

filter_func: str[source]#

The function applied to the waveforms.

input_var_name: str[source]#

The argument to which the waveforms will be passed in the filter_func.

kwargs: Dict[str, Union[List, quantify_scheduler.structure.types.NDArray]][source]#

The keyword arguments that are passed to the filter_func.

clipping_values: Optional[List][source]#

The optional boundaries to which the corrected pulses will be clipped, upon exceeding.

class ModulationFrequencies(**data: Any)[source]#

Bases: quantify_scheduler.structure.model.DataStructure

Modulation frequencies for a port-clock combination.

Create a new model by parsing and validating input data from keyword arguments.

Raises ValidationError if the input data cannot be parsed to form a valid model.

interm_freq: Optional[float][source]#

The intermodulation frequency (IF) used for this port-clock combination.

lo_freq: Optional[float][source]#

The local oscillator frequency (LO) used for this port-clock combination.

class MixerCorrections(**data: Any)[source]#

Bases: quantify_scheduler.structure.model.DataStructure

Mixer corrections for a port-clock combination.

Create a new model by parsing and validating input data from keyword arguments.

Raises ValidationError if the input data cannot be parsed to form a valid model.

dc_offset_i: float = 0.0[source]#

The DC offset on the I channel used for this port-clock combination.

dc_offset_q: float = 0.0[source]#

The DC offset on the Q channel used for this port-clock combination.

amp_ratio: float = 1.0[source]#

The mixer gain ratio used for this port-clock combination.

phase_error: float = 0.0[source]#

The mixer phase error used for this port-clock combination.

class HardwareOptions(**data: Any)[source]#

Bases: quantify_scheduler.structure.model.DataStructure

Datastructure containing the hardware options for each port-clock combination.

This datastructure contains the HardwareOptions that are currently shared among the existing backends. Subclassing is required to add backend-specific options, see e.g., QbloxHardwareOptions, ZIHardwareOptions.

Create a new model by parsing and validating input data from keyword arguments.

Raises ValidationError if the input data cannot be parsed to form a valid model.

latency_corrections: Optional[Dict[str, LatencyCorrection]][source]#

Dictionary containing the latency corrections (values) that should be applied to operations on a certain port-clock combination (keys).

distortion_corrections: Optional[Dict[str, DistortionCorrection]][source]#

Dictionary containing the distortion corrections (values) that should be applied to waveforms on a certain port-clock combination (keys).

modulation_frequencies: Optional[Dict[str, ModulationFrequencies]][source]#

Dictionary containing the modulation frequencies (values) that should be used for signals on a certain port-clock combination (keys).

mixer_corrections: Optional[Dict[str, MixerCorrections]][source]#

Dictionary containing the mixer corrections (values) that should be used for signals on a certain port-clock combination (keys).

class LocalOscillatorDescription(**data: Any)[source]#

Bases: quantify_scheduler.structure.model.DataStructure

Information needed to specify a Local Oscillator in the CompilationConfig.

Create a new model by parsing and validating input data from keyword arguments.

Raises ValidationError if the input data cannot be parsed to form a valid model.

instrument_type: Literal[LocalOscillator][source]#

The field discriminator for this HardwareDescription datastructure.

instrument_name: Optional[str][source]#

The QCoDeS instrument name corresponding to this Local Oscillator.

generic_icc_name: Optional[str][source]#

The name of the GenericInstrumentCoordinatorComponent corresponding to this Local Oscillator.

frequency_param: str = 'frequency'[source]#

The QCoDeS parameter that is used to set the LO frequency.

power_param: str = 'power'[source]#

The QCoDeS parameter that is used to set the LO power.

power: Optional[int][source]#

The power setting for this Local Oscillator.

class HardwareDescription(**data: Any)[source]#

Bases: quantify_scheduler.structure.model.DataStructure

Specifies a piece of hardware and its instrument-specific settings.

Create a new model by parsing and validating input data from keyword arguments.

Raises ValidationError if the input data cannot be parsed to form a valid model.

instrument_type: str[source]#

The instrument type.

class Connectivity(**data: Any)[source]#

Bases: quantify_scheduler.structure.model.DataStructure

Connectivity between ports on the quantum device and on the control hardware.

Create a new model by parsing and validating input data from keyword arguments.

Raises ValidationError if the input data cannot be parsed to form a valid model.

class HardwareCompilationConfig(**data: Any)[source]#

Bases: quantify_scheduler.structure.model.DataStructure

Information required to compile a schedule to the control-hardware layer.

From a point of view of Compilation this information is needed to convert a schedule defined on a quantum-device layer to compiled instructions that can be executed on the control hardware.

This datastructure defines the overall structure of a HardwareCompilationConfig. Specific hardware backends may customize fields within this structure by inheriting from this class, see e.g., QbloxHardwareCompilationConfig, ZIHardwareCompilationConfig.

Create a new model by parsing and validating input data from keyword arguments.

Raises ValidationError if the input data cannot be parsed to form a valid model.

backend: Callable[[quantify_scheduler.schedules.schedule.Schedule, Any], quantify_scheduler.schedules.schedule.Schedule][source]#

A . separated string specifying the location of the compilation backend this configuration is intended for.

hardware_description: Dict[str, HardwareDescription][source]#

Datastructure describing the control hardware instruments in the setup and their high-level settings.

connectivity: Union[Connectivity, Dict][source]#

Datastructure representing how ports on the quantum device are connected to ports on the control hardware.

hardware_options: Optional[HardwareOptions][source]#

The HardwareOptions used in the compilation from the quantum-device layer to the control-hardware layer.

_import_backend_if_str(fun: Callable[[quantify_scheduler.schedules.schedule.Schedule, Any], quantify_scheduler.schedules.schedule.Schedule]) Callable[[quantify_scheduler.schedules.schedule.Schedule, Any], quantify_scheduler.schedules.schedule.Schedule][source]#
_latencies_in_hardware_config(connectivity)[source]#
_distortions_in_hardware_config(connectivity)[source]#