braket.device_schema.device_service_properties_v1 module¶
-
class
braket.device_schema.device_service_properties_v1.
DeviceCost
[source]¶ Bases:
pydantic.main.BaseModel
This class provides the details on the cost of a device.
-
price
¶ Price of the device in terms of US dollars
Type: float
-
unit
¶ unit for charging the price, eg: minute, hour, task [price per task]
Type: str
Examples
>>> import json >>> input_json = { ... "price": 0.25, ... "unit": "minute" ... } >>> DeviceCost.parse_raw(json.dumps(input_json))
Create a new model by parsing and validating input data from keyword arguments.
Raises ValidationError if the input data cannot be parsed to form a valid model.
-
-
class
braket.device_schema.device_service_properties_v1.
DeviceDocumentation
[source]¶ Bases:
pydantic.main.BaseModel
This class provides the device documentations like image, summary of it and external documentation.
-
imageUrl
¶ URL for the image of the device
Type: Optional[str]
-
summary
¶ brief description on the device
Type: Optional[str]
-
externalDocumentationUrl
¶ external documentation URL
Type: Optional[str]
Examples
>>> import json >>> input_json = { ... "imageUrl": "image_url", ... "summary": "Summary on the device", ... "externalDocumentationUrl": "exter doc link", ... } >>> DeviceDocumentation.parse_raw(json.dumps(input_json))
Create a new model by parsing and validating input data from keyword arguments.
Raises ValidationError if the input data cannot be parsed to form a valid model.
-
-
class
braket.device_schema.device_service_properties_v1.
DeviceServiceProperties
[source]¶ Bases:
braket.schema_common.schema_base.BraketSchemaBase
This class defines the common service properties for each device.
-
executionWindows
¶ List of the execution windows, it tells us which days the device can execute a task.
Type: List[DeviceExecutionWindow]
-
shotsRange
¶ range of the shots for a given device.
Type: Tuple[int, int]
-
deviceCost
¶ cost of the device to run the quantum circuits
Type: Optional[DeviceCost]
-
deviceDocumentation
¶ provides device specific details like image, summary etc.
Type: Optional[DeviceDocumentation]
-
deviceLocation
¶ location fo the device
Type: Optional[str]
-
updatedAt
¶ time when the device properties are last updated.
Type: Optional[datetime]
-
getTaskPollIntervalMillis
¶ (suggested) interval between polling tasks in milliseconds.
Type: Optional[int]
Examples
>>> import json >>> input_json = { ... "braketSchemaHeader": { ... "name": "braket.device_schema.device_service_properties", ... "version": "1", ... }, ... "executionWindows": [ ... { ... "executionDay": "Everyday", ... "windowStartHour": "09:00", ... "windowEndHour": "09:55", ... } ... ], ... "shotsRange": [1,10], ... "deviceCost": { ... "price": 0.25, ... "unit": "minute" ... }, ... "deviceDocumentation": { ... "imageUrl": "image_url", ... "summary": "Summary on the device", ... "externalDocumentationUrl": "exter doc link", ... }, ... "deviceLocation": "us-east-1", ... "updatedAt": "2020-06-16T19:28:02.869136", ... "getTaskPollIntervalMillis": 200, ... } >>> DeviceServiceProperties.parse_raw_schema(json.dumps(input_json))
Create a new model by parsing and validating input data from keyword arguments.
Raises ValidationError if the input data cannot be parsed to form a valid model.
-