qbraid.runtime.origin.OriginDevice

class OriginDevice(profile, service, backend=None, **kwargs)[source]

OriginQ QCloud device interface.

Create a QuantumDevice object.

Parameters:
  • profile (TargetProfile) – The device runtime profile.

  • scheme (ConversionScheme | None) – The conversion graph and options passed to the transpiler at runtime.

  • options (RuntimeOptions | None) – Custom options to control the runtime behavior. Adds fields or overrides default values for transpile, transform, and validate. Note that while you can modify these values, their associated validators are fixed and cannot be changed.

__init__(profile, service, backend=None, **kwargs)[source]

Create a QuantumDevice object.

Parameters:
  • profile (TargetProfile) – The device runtime profile.

  • scheme (ConversionScheme | None) – The conversion graph and options passed to the transpiler at runtime.

  • options (RuntimeOptions | None) – Custom options to control the runtime behavior. Adds fields or overrides default values for transpile, transform, and validate. Note that while you can modify these values, their associated validators are fixed and cannot be changed.

Methods

__init__(profile, service[, backend])

Create a QuantumDevice object.

apply_runtime_profile(run_input)

Process quantum program before passing to device run method.

avg_queue_time()

Return the average time (in seconds) a job spends in the queue for the device.

metadata()

Returns a dictionary containing selected metadata about the device.

prepare(run_input)

Convert the quantum program to an intermediate representation (IR) compatible with the submission format required for the target device and its provider API.

queue_depth()

Return the number of jobs in the queue for the device.

run(run_input, *args, **kwargs)

Run a quantum job or a list of quantum jobs on this quantum device.

set_options(**fields)

Update the runtime options for the QuantumDevice.

set_target_program_type(alias)

Set the program type to target during runtime transpile step.

status()

Return the current status of the OriginQ device.

submit(run_input, shots)

Submit a quantum program or list of programs to the OriginQ device.

transform(run_input)

Override this method with any runtime transformations to apply to the run input, e.g. circuit optimizations, device-specific gate set conversions, etc.

transpile(run_input, run_input_spec)

Convert circuit to package compatible with target device and pass through any provider transpile methods to match topology of device and/or optimize as applicable.

update_scheme(**kwargs)

Update the conversion scheme with new values.

validate(run_input_batch[, ...])

Verifies run input compatibility with target device.

Attributes

backend

Return the underlying QCloudBackend.

id

Return the device ID.

num_qubits

The number of qubits supported by the device.

profile

Return the runtime profile.

scheme

Return the conversion scheme.

service

Return the underlying QCloudService.

simulator

The device type, Simulator, Fake_device or QPU.