-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #33 from QuEraComputing/dev_0.3.0
Release 0.3.0
- Loading branch information
Showing
9 changed files
with
269 additions
and
110 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
__version__ = '0.2.0' | ||
__version__ = '0.3.0' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
from pydantic import BaseModel | ||
|
||
__all__ = ["QuEraCapabilities"] | ||
|
||
|
||
class RydbergGlobalCapabilities(BaseModel): | ||
rabi_frequency_min: float | ||
rabi_frequency_max: float | ||
rabi_frequency_resolution: float | ||
rabi_frequency_slew_rate_max: float | ||
detuning_min: float | ||
detuning_max: float | ||
detuning_resolution: float | ||
detuning_slew_rate_max: float | ||
phase_min: float | ||
phase_max: float | ||
phase_resolution: float | ||
time_min: float | ||
time_max: float | ||
time_resolution: float | ||
time_delta_min: float | ||
|
||
class RydbergLocalCapabilities(BaseModel): | ||
detuning_min: float | ||
detuning_max: float | ||
detuning_slew_rate_max: float | ||
site_coefficient_min: float | ||
site_coefficient_max: float | ||
number_local_detuning_sites: int | ||
spacing_radial_min: float | ||
time_resolution: float | ||
time_delta_min: float | ||
|
||
class RydbergCapabilities(BaseModel): | ||
c6_coefficient: float | ||
global_: RydbergGlobalCapabilities | ||
local: RydbergLocalCapabilities | ||
|
||
class Config: | ||
fields = { | ||
'global_': 'global' | ||
} | ||
|
||
class LatticeGeometryCapabilities(BaseModel): | ||
spacing_radial_min: float | ||
spacing_vertical_min: float | ||
position_resolution: float | ||
number_sites_max: int | ||
|
||
class LatticeAreaCapabilities(BaseModel): | ||
width: float | ||
height: float | ||
|
||
class LatticeCapabilities(BaseModel): | ||
number_qubits_max: int | ||
area: LatticeAreaCapabilities | ||
geometry: LatticeGeometryCapabilities | ||
|
||
class TaskCapabilities(BaseModel): | ||
number_shots_min: int | ||
number_shots_max: int | ||
|
||
class DeviceCapabilities(BaseModel): | ||
task: TaskCapabilities | ||
lattice: LatticeCapabilities | ||
rydberg: RydbergCapabilities | ||
|
||
class QuEraCapabilities(BaseModel): | ||
version: str | ||
capabilities: DeviceCapabilities |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
from enum import Enum | ||
from pydantic import BaseModel, conlist, conint | ||
|
||
__all__ = [ | ||
"QuEraTaskResults", | ||
] | ||
|
||
class QuEraShotStatusCode(str, Enum): | ||
Completed = "Completed" | ||
MissingPreSequence = "MissingPreSequence" | ||
MissingPostSequence = "MissingPostSequence" | ||
MissingMeasurement = "MissingMeasurement" | ||
|
||
class QuEraTaskStatusCode(str, Enum): | ||
Created = "Created" | ||
Running = "Running" | ||
Completed = "Completed" | ||
Failed = "Failed" | ||
Cancelled = "Cancelled" | ||
|
||
class QuEraShotResult(BaseModel): | ||
shot_status: QuEraShotStatusCode = QuEraShotStatusCode.MissingMeasurement | ||
pre_sequence: conlist(conint(ge=0, le=1), min_items=0) = [] | ||
post_sequence: conlist(conint(ge=0, le=1), min_items=0) = [] | ||
|
||
class QuEraTaskResults(BaseModel): | ||
task_status: QuEraTaskStatusCode = QuEraTaskStatusCode.Failed | ||
shot_outputs: conlist(QuEraShotResult, min_items=0) = [] | ||
|
||
|
Oops, something went wrong.