control_flow_library#

Contains the control flow operations for the Qblox backend.

Module Contents#

Classes#

ConditionalOperation

Conditional over another operation.

class ConditionalOperation(body: quantify_scheduler.operations.operation.Operation | quantify_scheduler.schedules.schedule.Schedule, qubit_name: str, t0: float = 0.0)[source]#

Bases: quantify_scheduler.operations.control_flow_library.ConditionalOperation

Conditional over another operation.

If a preceding thresholded acquisition on qubit_name results in a “1”, the body will be executed, otherwise it will generate a wait time that is equal to the time of the subschedule, to ensure the absolute timing of later operations remains consistent.

Parameters:
  • body – Operation to be conditionally played

  • qubit_name – Name of the qubit on which the body will be conditioned

  • t0 – Time offset, by default 0

Example

A conditional reset can be implemented as follows:

example