DeviceEmulatorProperties

class braket.emulation.device_emulator_properties.DeviceEmulatorProperties(qubitCount, nativeGateSet, connectivityGraph, oneQubitProperties, twoQubitProperties, supportedResultTypes, supportedActions=None)[source]

Bases: object

Properties for device emulation.

Parameters:
  • qubitCount (int) – Number of qubits in the device

  • nativeGateSet (list[str]) – List of native gates supported by the device. Must be valid Braket gates. Valid gates include: gphase, i, h, x, y, z, cv, cnot, cy, cz, ecr, s, si, t, ti, v, vi, phaseshift, cphaseshift, cphaseshift00, cphaseshift01, cphaseshift10, rx, ry, rz, U, swap, iswap, pswap, xy, xx, yy, zz, ccnot, cswap, gpi, gpi2, prx, ms, unitary

  • connectivityGraph (dict[str, list[str]]) – Graph representing qubit connectivity. If it is an empty dictionary, the device is treated as fully connected.

  • oneQubitProperties (dict[str, OneQubitProperties]) – Properties of one-qubit calibration details

  • twoQubitProperties (dict[str, TwoQubitProperties]) – Properties of two-qubit calibration details

  • supportedResultTypes (list[ResultType]) – List of supported result types.

  • supportedActions (list[DeviceActionType, DeviceActionProperties]) – List of device actions

Initialize a DeviceEmulatorProperties instance.

Parameters:
  • qubitCount (int)

  • nativeGateSet (list[str])

  • connectivityGraph (dict[str, list[str]])

  • oneQubitProperties (dict[str, OneQubitProperties])

  • twoQubitProperties (dict[str, TwoQubitProperties])

  • supportedResultTypes (list[ResultType])

  • supportedActions (dict[DeviceActionType, DeviceActionProperties] | None)

property qubit_labels: list[int]

Get the sorted list of qubit indices.

property fully_connected: bool

Determine if the connectivity graph is fully connected.

Note: We treat the graph as undirected, and determine if it is

a complete graph by counting the number of distinct edges

property directed: bool

Determine if the connectivity graph is a directed graph.

property qubit_count: int
property native_gate_set: list[str]
property connectivity_graph: list[str]
property one_qubit_properties: dict[str, OneQubitProperties]
property two_qubit_properties: dict[str, TwoQubitProperties]
property supported_result_types: list[ResultType]
property supported_specifications: tuple[BraketSchemaBase] | BraketSchemaBase
property supported_actions: dict[str, str]
classmethod from_device_properties(device_properties)[source]

Create a DeviceEmulatorProperties instance from DeviceCapabilities.

Parameters:

device_properties (DeviceCapabilities)

Return type:

DeviceEmulatorProperties

classmethod from_json(device_properties_json)[source]

Create a DeviceEmulatorProperties instance from a JSON string.

Parameters:

device_properties_json (str)

Return type:

DeviceEmulatorProperties