GenericPass¶
- class qiskit.passmanager.GenericPass[source]¶
Bases:
Task
,ABC
Base class of a single pass manager task.
A pass instance can read and write to the provided
PropertySet
, and may modify the input pass manager IR.Methods
- execute(passmanager_ir, state, callback=None)[source]¶
Execute optimization task for input Qiskit IR.
- Parameters:
passmanager_ir (Any) – Qiskit IR to optimize.
state (PassManagerState) – State associated with workflow execution by the pass manager itself.
callback (Callable | None) – A callback function which is caller per execution of optimization task.
- Returns:
Optimized Qiskit IR and state of the workflow.
- Return type:
tuple[Any, qiskit.passmanager.compilation_status.PassManagerState]
- update_status(state, run_state)[source]¶
Update workflow status.
- Parameters:
state (PassManagerState) – Pass manager state to update.
run_state (RunState) – Completion status of current task.
- Returns:
Updated pass manager state.
- Return type: