qrisp.interface.Backend.run_async#

abstractmethod Backend.run_async(circuits: QuantumCircuit | Sequence[QuantumCircuit], shots: int | list[int] | None = None) Job[source]#

Submit one or more circuits for execution and return a Job.

The returned job must not be in INITIALIZING state: by the time run_async returns, execution must have been handed off to the backend. The exact state the job enters depends on the backend type:

  • QUEUED: for asynchronous or remote backends where the job waits in a queue before execution begins.

  • RUNNING or DONE: for synchronous simulators that begin (or complete) execution before returning.

Parameters:
circuitsQuantumCircuit or Sequence[QuantumCircuit]

A single circuit or a sequence of circuits to execute. No validation or introspection is performed at the base-class level.

When a sequence is provided, the backend decides internally how to handle the circuit execution. Hardware backends may impose a limit on how many circuits a single job may contain. This is a backend-defined constraint.

shotsint or list[int] or None, optional

Number of shots (repetitions) for the execution. If None, the value from the backend’s runtime options should be used. When a list[int] is provided, each entry specifies the shot count for the circuit at the corresponding index.

Backends whose SDK does not natively support per-circuit shot counts should fall back to max(shots) and issue a UserWarning.

Returns:
Job

A handle to the submitted execution. Call Job.result to wait for completion and retrieve the JobResult.