This module represents the Q-Profile quantum control electronics profiler.
ProfiledScheduleGettable is currently only tested to support Qblox hardware.
To be used in place of
Decorator that reports the execution time of the decorated function
Decorator that reports the execution time of the decorated function and stores this in
func (Callable) – Target function to be profiled.
- class ProfiledInstrumentCoordinator(name: str, parent_ic: quantify_scheduler.instrument_coordinator.instrument_coordinator.InstrumentCoordinator)#
InstrumentCoordinatorthat implements a profiling tool to log timing results. Time results are stored in
ic = InstrumentCoordinator(name="instrument_coordinator") quantum_device = QuantumDevice(name="quantum_device") quantum_device.instr_instrument_coordinator(ic.name) profiled_gettable = ProfiledScheduleGettable( quantum_device=quantum_device, schedule_function=..., schedule_kwargs=..., ) profiled_gettable.initialize() profiled_ic = ( profiled_gettable.quantum_device.instr_instrument_coordinator.get_instr() )
- add_component(component) None #
Adds a component to the components collection.
- prepare(compiled_schedule) None #
Prepares each component for execution of a schedule.
It attempts to configure all instrument coordinator components for which compiled instructions, typically consisting of a combination of sequence programs, waveforms and other instrument settings, are available in the compiled schedule.
Start all of the components.
The components are started in the order in which they were added.
Stops all components.
The components are stopped in the order in which they were added.
allow_failure – By default it is set to False. When set to True, the AttributeErrors raised by a component are demoted to warnings to allow other components to stop.
Retrieves the latest acquisition results of the components with acquisition capabilities.
The acquisition data in an
xarray.Dataset. For each acquisition channel it contains an
- class ProfiledScheduleGettable(*args, **kwargs)#
Overwrite compile step for profiling.
Cleanup new profiling instruments to avoid future conflicts.
- log_profile(obj=None, path='profiling_logs', filename=None, indent: int = 4, separators=None)#
Store profiling logs to json file.
- plot_profile(path=None, filename='average_runtimes.pdf')#
Create barplot of accumulated profiling data.