qi-compute-api-client 0.7.0__py3-none-any.whl → 0.17.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of qi-compute-api-client might be problematic. Click here for more details.
- compute_api_client/__init__.py +22 -19
- compute_api_client/api/__init__.py +5 -6
- compute_api_client/api/algorithms_api.py +1333 -553
- compute_api_client/api/backend_api.py +1501 -0
- compute_api_client/api/backend_types_api.py +684 -0
- compute_api_client/api/batch_jobs_api.py +1937 -0
- compute_api_client/api/commits_api.py +1068 -435
- compute_api_client/api/files_api.py +1075 -435
- compute_api_client/api/final_results_api.py +736 -338
- compute_api_client/api/jobs_api.py +1653 -0
- compute_api_client/api/languages_api.py +556 -217
- compute_api_client/api/members_api.py +1057 -435
- compute_api_client/api/metadata_api.py +736 -337
- compute_api_client/api/permissions_api.py +1055 -421
- compute_api_client/api/projects_api.py +1604 -676
- compute_api_client/api/reservations_api.py +1124 -427
- compute_api_client/api/results_api.py +738 -337
- compute_api_client/api/teams_api.py +567 -220
- compute_api_client/api/transactions_api.py +679 -218
- compute_api_client/api/users_api.py +1090 -435
- compute_api_client/api_client.py +346 -304
- compute_api_client/api_response.py +21 -0
- compute_api_client/configuration.py +54 -67
- compute_api_client/docs/Algorithm.md +20 -3
- compute_api_client/docs/AlgorithmIn.md +20 -3
- compute_api_client/docs/AlgorithmType.md +0 -1
- compute_api_client/docs/AlgorithmsApi.md +78 -77
- compute_api_client/docs/Backend.md +33 -0
- compute_api_client/docs/BackendApi.md +419 -0
- compute_api_client/docs/BackendPatch.md +29 -0
- compute_api_client/docs/{RunStatus.md → BackendStatus.md} +1 -2
- compute_api_client/docs/BackendType.md +36 -0
- compute_api_client/docs/{RuntimeTypesApi.md → BackendTypesApi.md} +58 -31
- compute_api_client/docs/BackendWithAuthentication.md +34 -0
- compute_api_client/docs/BatchJob.md +38 -0
- compute_api_client/docs/BatchJobIn.md +29 -0
- compute_api_client/docs/{RuntimeStatus.md → BatchJobStatus.md} +1 -2
- compute_api_client/docs/{BatchRunsApi.md → BatchJobsApi.md} +170 -147
- compute_api_client/docs/Commit.md +18 -1
- compute_api_client/docs/CommitIn.md +17 -0
- compute_api_client/docs/CommitsApi.md +62 -71
- compute_api_client/docs/CompileStage.md +0 -1
- compute_api_client/docs/Domain.md +0 -1
- compute_api_client/docs/File.md +21 -4
- compute_api_client/docs/FileIn.md +21 -4
- compute_api_client/docs/FilesApi.md +65 -71
- compute_api_client/docs/FinalResult.md +20 -3
- compute_api_client/docs/FinalResultIn.md +19 -2
- compute_api_client/docs/FinalResultsApi.md +44 -71
- compute_api_client/docs/HTTPNotFoundError.md +17 -0
- compute_api_client/docs/HTTPValidationError.md +18 -1
- compute_api_client/docs/Job.md +36 -0
- compute_api_client/docs/JobIn.md +31 -0
- compute_api_client/docs/JobPatch.md +28 -0
- compute_api_client/docs/{BatchRunStatus.md → JobStatus.md} +1 -2
- compute_api_client/docs/{RunsApi.md → JobsApi.md} +137 -122
- compute_api_client/docs/Language.md +17 -0
- compute_api_client/docs/LanguagesApi.md +30 -12
- compute_api_client/docs/LocationInner.md +17 -0
- compute_api_client/docs/Member.md +19 -2
- compute_api_client/docs/MemberIn.md +19 -2
- compute_api_client/docs/MembersApi.md +59 -24
- compute_api_client/docs/Metadata.md +20 -3
- compute_api_client/docs/MetadataApi.md +49 -33
- compute_api_client/docs/MetadataIn.md +19 -2
- compute_api_client/docs/Permission.md +17 -0
- compute_api_client/docs/PermissionGroup.md +17 -0
- compute_api_client/docs/PermissionsApi.md +68 -28
- compute_api_client/docs/Project.md +20 -3
- compute_api_client/docs/ProjectIn.md +18 -1
- compute_api_client/docs/ProjectPatch.md +19 -2
- compute_api_client/docs/ProjectsApi.md +84 -36
- compute_api_client/docs/Reservation.md +21 -4
- compute_api_client/docs/ReservationIn.md +19 -2
- compute_api_client/docs/ReservationsApi.md +66 -24
- compute_api_client/docs/Result.md +23 -6
- compute_api_client/docs/ResultIn.md +19 -2
- compute_api_client/docs/ResultsApi.md +42 -26
- compute_api_client/docs/Role.md +0 -1
- compute_api_client/docs/ShareType.md +0 -1
- compute_api_client/docs/Team.md +18 -1
- compute_api_client/docs/TeamsApi.md +37 -14
- compute_api_client/docs/Transaction.md +21 -4
- compute_api_client/docs/TransactionsApi.md +50 -14
- compute_api_client/docs/User.md +21 -4
- compute_api_client/docs/UserIn.md +17 -0
- compute_api_client/docs/UsersApi.md +62 -24
- compute_api_client/docs/ValidationError.md +18 -1
- compute_api_client/exceptions.py +19 -16
- compute_api_client/models/__init__.py +16 -14
- compute_api_client/models/algorithm.py +78 -237
- compute_api_client/models/algorithm_in.py +76 -204
- compute_api_client/models/algorithm_type.py +21 -87
- compute_api_client/models/backend.py +100 -0
- compute_api_client/models/backend_patch.py +90 -0
- compute_api_client/models/backend_status.py +47 -0
- compute_api_client/models/backend_type.py +105 -0
- compute_api_client/models/backend_with_authentication.py +102 -0
- compute_api_client/models/batch_job.py +129 -0
- compute_api_client/models/batch_job_in.py +89 -0
- compute_api_client/models/batch_job_status.py +48 -0
- compute_api_client/models/commit.py +72 -230
- compute_api_client/models/commit_in.py +67 -169
- compute_api_client/models/compile_stage.py +23 -89
- compute_api_client/models/domain.py +22 -88
- compute_api_client/models/file.py +74 -288
- compute_api_client/models/file_in.py +72 -254
- compute_api_client/models/final_result.py +68 -198
- compute_api_client/models/final_result_in.py +63 -137
- compute_api_client/models/http_not_found_error.py +60 -105
- compute_api_client/models/http_validation_error.py +69 -105
- compute_api_client/models/job.py +120 -0
- compute_api_client/models/job_in.py +99 -0
- compute_api_client/models/job_patch.py +88 -0
- compute_api_client/models/job_status.py +48 -0
- compute_api_client/models/language.py +67 -172
- compute_api_client/models/location_inner.py +125 -84
- compute_api_client/models/member.py +70 -236
- compute_api_client/models/member_in.py +68 -203
- compute_api_client/models/metadata.py +68 -198
- compute_api_client/models/metadata_in.py +68 -137
- compute_api_client/models/permission.py +67 -172
- compute_api_client/models/permission_group.py +65 -142
- compute_api_client/models/project.py +74 -256
- compute_api_client/models/project_in.py +69 -195
- compute_api_client/models/project_patch.py +89 -192
- compute_api_client/models/reservation.py +79 -290
- compute_api_client/models/reservation_in.py +68 -200
- compute_api_client/models/result.py +101 -359
- compute_api_client/models/result_in.py +95 -291
- compute_api_client/models/role.py +21 -87
- compute_api_client/models/share_type.py +22 -88
- compute_api_client/models/team.py +69 -198
- compute_api_client/models/transaction.py +93 -299
- compute_api_client/models/user.py +75 -276
- compute_api_client/models/user_in.py +73 -243
- compute_api_client/models/validation_error.py +73 -160
- compute_api_client/rest.py +55 -114
- {qi_compute_api_client-0.7.0.dist-info → qi_compute_api_client-0.17.0.dist-info}/METADATA +47 -40
- qi_compute_api_client-0.17.0.dist-info/RECORD +142 -0
- compute_api_client/api/batch_runs_api.py +0 -862
- compute_api_client/api/runs_api.py +0 -723
- compute_api_client/api/runtime_api.py +0 -449
- compute_api_client/api/runtime_types_api.py +0 -303
- compute_api_client/docs/BatchRun.md +0 -21
- compute_api_client/docs/BatchRunIn.md +0 -12
- compute_api_client/docs/Run.md +0 -19
- compute_api_client/docs/RunIn.md +0 -14
- compute_api_client/docs/Runtime.md +0 -16
- compute_api_client/docs/RuntimeApi.md +0 -229
- compute_api_client/docs/RuntimeType.md +0 -19
- compute_api_client/docs/RuntimeWithAuthentication.md +0 -17
- compute_api_client/models/batch_run.py +0 -423
- compute_api_client/models/batch_run_in.py +0 -171
- compute_api_client/models/batch_run_status.py +0 -114
- compute_api_client/models/run.py +0 -376
- compute_api_client/models/run_in.py +0 -233
- compute_api_client/models/run_status.py +0 -114
- compute_api_client/models/runtime.py +0 -290
- compute_api_client/models/runtime_status.py +0 -113
- compute_api_client/models/runtime_type.py +0 -357
- compute_api_client/models/runtime_with_authentication.py +0 -320
- qi_compute_api_client-0.7.0.dist-info/RECORD +0 -137
- {qi_compute_api_client-0.7.0.dist-info → qi_compute_api_client-0.17.0.dist-info}/LICENSE.md +0 -0
- {qi_compute_api_client-0.7.0.dist-info → qi_compute_api_client-0.17.0.dist-info}/WHEEL +0 -0
|
@@ -3,315 +3,119 @@
|
|
|
3
3
|
"""
|
|
4
4
|
Quantum Inspire 2
|
|
5
5
|
|
|
6
|
-
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
+
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
7
|
|
|
8
8
|
The version of the OpenAPI document: 0.1.0
|
|
9
|
-
Generated by
|
|
10
|
-
"""
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
11
10
|
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
12
13
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
except ImportError:
|
|
16
|
-
from inspect import getargspec as getfullargspec
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
17
16
|
import pprint
|
|
18
17
|
import re # noqa: F401
|
|
19
|
-
import
|
|
18
|
+
import json
|
|
20
19
|
|
|
21
|
-
from compute_api_client.configuration import Configuration
|
|
22
20
|
|
|
21
|
+
from typing import Any, ClassVar, Dict, List, Optional, Union
|
|
22
|
+
from pydantic import BaseModel, StrictFloat, StrictInt
|
|
23
|
+
from pydantic import Field
|
|
24
|
+
from typing_extensions import Annotated
|
|
25
|
+
try:
|
|
26
|
+
from typing import Self
|
|
27
|
+
except ImportError:
|
|
28
|
+
from typing_extensions import Self
|
|
23
29
|
|
|
24
|
-
class ResultIn(
|
|
25
|
-
"""NOTE: This class is auto generated by OpenAPI Generator.
|
|
26
|
-
Ref: https://openapi-generator.tech
|
|
27
|
-
|
|
28
|
-
Do not edit the class manually.
|
|
29
|
-
"""
|
|
30
|
-
|
|
31
|
-
"""
|
|
32
|
-
Attributes:
|
|
33
|
-
openapi_types (dict): The key is attribute name
|
|
34
|
-
and the value is attribute type.
|
|
35
|
-
attribute_map (dict): The key is attribute name
|
|
36
|
-
and the value is json key in definition.
|
|
30
|
+
class ResultIn(BaseModel):
|
|
37
31
|
"""
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
32
|
+
ResultIn
|
|
33
|
+
""" # noqa: E501
|
|
34
|
+
job_id: StrictInt
|
|
35
|
+
metadata_id: Optional[StrictInt] = None
|
|
36
|
+
number_of_qubits: Annotated[int, Field(strict=True, ge=-32768)]
|
|
37
|
+
execution_time_in_seconds: Union[StrictFloat, StrictInt]
|
|
38
|
+
shots_requested: Optional[StrictInt] = None
|
|
39
|
+
shots_done: Optional[StrictInt] = None
|
|
40
|
+
results: Optional[Union[str, Any]] = None
|
|
41
|
+
__properties: ClassVar[List[str]] = ["job_id", "metadata_id", "number_of_qubits", "execution_time_in_seconds", "shots_requested", "shots_done", "results"]
|
|
42
|
+
|
|
43
|
+
model_config = {
|
|
44
|
+
"populate_by_name": True,
|
|
45
|
+
"validate_assignment": True
|
|
46
46
|
}
|
|
47
47
|
|
|
48
|
-
attribute_map = {
|
|
49
|
-
'number_of_qubits': 'number_of_qubits',
|
|
50
|
-
'execution_time_in_seconds': 'execution_time_in_seconds',
|
|
51
|
-
'shots_requested': 'shots_requested',
|
|
52
|
-
'shots_done': 'shots_done',
|
|
53
|
-
'results': 'results',
|
|
54
|
-
'metadata_id': 'metadata_id',
|
|
55
|
-
'run_id': 'run_id'
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
def __init__(self, number_of_qubits=None, execution_time_in_seconds=None, shots_requested=None, shots_done=None, results=None, metadata_id=None, run_id=None, local_vars_configuration=None): # noqa: E501
|
|
59
|
-
"""ResultIn - a model defined in OpenAPI""" # noqa: E501
|
|
60
|
-
if local_vars_configuration is None:
|
|
61
|
-
local_vars_configuration = Configuration.get_default_copy()
|
|
62
|
-
self.local_vars_configuration = local_vars_configuration
|
|
63
|
-
|
|
64
|
-
self._number_of_qubits = None
|
|
65
|
-
self._execution_time_in_seconds = None
|
|
66
|
-
self._shots_requested = None
|
|
67
|
-
self._shots_done = None
|
|
68
|
-
self._results = None
|
|
69
|
-
self._metadata_id = None
|
|
70
|
-
self._run_id = None
|
|
71
|
-
self.discriminator = None
|
|
72
|
-
|
|
73
|
-
self.number_of_qubits = number_of_qubits
|
|
74
|
-
self.execution_time_in_seconds = execution_time_in_seconds
|
|
75
|
-
self.shots_requested = shots_requested
|
|
76
|
-
self.shots_done = shots_done
|
|
77
|
-
self.results = results
|
|
78
|
-
if metadata_id is not None:
|
|
79
|
-
self.metadata_id = metadata_id
|
|
80
|
-
self.run_id = run_id
|
|
81
|
-
|
|
82
|
-
@property
|
|
83
|
-
def number_of_qubits(self):
|
|
84
|
-
"""Gets the number_of_qubits of this ResultIn. # noqa: E501
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
:return: The number_of_qubits of this ResultIn. # noqa: E501
|
|
88
|
-
:rtype: int
|
|
89
|
-
"""
|
|
90
|
-
return self._number_of_qubits
|
|
91
|
-
|
|
92
|
-
@number_of_qubits.setter
|
|
93
|
-
def number_of_qubits(self, number_of_qubits):
|
|
94
|
-
"""Sets the number_of_qubits of this ResultIn.
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
:param number_of_qubits: The number_of_qubits of this ResultIn. # noqa: E501
|
|
98
|
-
:type number_of_qubits: int
|
|
99
|
-
"""
|
|
100
|
-
if self.local_vars_configuration.client_side_validation and number_of_qubits is None: # noqa: E501
|
|
101
|
-
raise ValueError("Invalid value for `number_of_qubits`, must not be `None`") # noqa: E501
|
|
102
|
-
if (self.local_vars_configuration.client_side_validation and
|
|
103
|
-
number_of_qubits is not None and number_of_qubits > 32767): # noqa: E501
|
|
104
|
-
raise ValueError("Invalid value for `number_of_qubits`, must be a value less than or equal to `32767`") # noqa: E501
|
|
105
|
-
if (self.local_vars_configuration.client_side_validation and
|
|
106
|
-
number_of_qubits is not None and number_of_qubits < -32768): # noqa: E501
|
|
107
|
-
raise ValueError("Invalid value for `number_of_qubits`, must be a value greater than or equal to `-32768`") # noqa: E501
|
|
108
|
-
|
|
109
|
-
self._number_of_qubits = number_of_qubits
|
|
110
|
-
|
|
111
|
-
@property
|
|
112
|
-
def execution_time_in_seconds(self):
|
|
113
|
-
"""Gets the execution_time_in_seconds of this ResultIn. # noqa: E501
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
:return: The execution_time_in_seconds of this ResultIn. # noqa: E501
|
|
117
|
-
:rtype: float
|
|
118
|
-
"""
|
|
119
|
-
return self._execution_time_in_seconds
|
|
120
|
-
|
|
121
|
-
@execution_time_in_seconds.setter
|
|
122
|
-
def execution_time_in_seconds(self, execution_time_in_seconds):
|
|
123
|
-
"""Sets the execution_time_in_seconds of this ResultIn.
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
:param execution_time_in_seconds: The execution_time_in_seconds of this ResultIn. # noqa: E501
|
|
127
|
-
:type execution_time_in_seconds: float
|
|
128
|
-
"""
|
|
129
|
-
if self.local_vars_configuration.client_side_validation and execution_time_in_seconds is None: # noqa: E501
|
|
130
|
-
raise ValueError("Invalid value for `execution_time_in_seconds`, must not be `None`") # noqa: E501
|
|
131
|
-
|
|
132
|
-
self._execution_time_in_seconds = execution_time_in_seconds
|
|
133
|
-
|
|
134
|
-
@property
|
|
135
|
-
def shots_requested(self):
|
|
136
|
-
"""Gets the shots_requested of this ResultIn. # noqa: E501
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
:return: The shots_requested of this ResultIn. # noqa: E501
|
|
140
|
-
:rtype: int
|
|
141
|
-
"""
|
|
142
|
-
return self._shots_requested
|
|
143
|
-
|
|
144
|
-
@shots_requested.setter
|
|
145
|
-
def shots_requested(self, shots_requested):
|
|
146
|
-
"""Sets the shots_requested of this ResultIn.
|
|
147
|
-
|
|
148
48
|
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
if (self.local_vars_configuration.client_side_validation and
|
|
153
|
-
shots_requested is not None and shots_requested > 2147483647): # noqa: E501
|
|
154
|
-
raise ValueError("Invalid value for `shots_requested`, must be a value less than or equal to `2147483647`") # noqa: E501
|
|
155
|
-
if (self.local_vars_configuration.client_side_validation and
|
|
156
|
-
shots_requested is not None and shots_requested < -2147483648): # noqa: E501
|
|
157
|
-
raise ValueError("Invalid value for `shots_requested`, must be a value greater than or equal to `-2147483648`") # noqa: E501
|
|
158
|
-
|
|
159
|
-
self._shots_requested = shots_requested
|
|
160
|
-
|
|
161
|
-
@property
|
|
162
|
-
def shots_done(self):
|
|
163
|
-
"""Gets the shots_done of this ResultIn. # noqa: E501
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
:return: The shots_done of this ResultIn. # noqa: E501
|
|
167
|
-
:rtype: int
|
|
168
|
-
"""
|
|
169
|
-
return self._shots_done
|
|
170
|
-
|
|
171
|
-
@shots_done.setter
|
|
172
|
-
def shots_done(self, shots_done):
|
|
173
|
-
"""Sets the shots_done of this ResultIn.
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
:param shots_done: The shots_done of this ResultIn. # noqa: E501
|
|
177
|
-
:type shots_done: int
|
|
178
|
-
"""
|
|
179
|
-
if (self.local_vars_configuration.client_side_validation and
|
|
180
|
-
shots_done is not None and shots_done > 2147483647): # noqa: E501
|
|
181
|
-
raise ValueError("Invalid value for `shots_done`, must be a value less than or equal to `2147483647`") # noqa: E501
|
|
182
|
-
if (self.local_vars_configuration.client_side_validation and
|
|
183
|
-
shots_done is not None and shots_done < -2147483648): # noqa: E501
|
|
184
|
-
raise ValueError("Invalid value for `shots_done`, must be a value greater than or equal to `-2147483648`") # noqa: E501
|
|
185
|
-
|
|
186
|
-
self._shots_done = shots_done
|
|
187
|
-
|
|
188
|
-
@property
|
|
189
|
-
def results(self):
|
|
190
|
-
"""Gets the results of this ResultIn. # noqa: E501
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
:return: The results of this ResultIn. # noqa: E501
|
|
194
|
-
:rtype: object
|
|
195
|
-
"""
|
|
196
|
-
return self._results
|
|
197
|
-
|
|
198
|
-
@results.setter
|
|
199
|
-
def results(self, results):
|
|
200
|
-
"""Sets the results of this ResultIn.
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
:param results: The results of this ResultIn. # noqa: E501
|
|
204
|
-
:type results: object
|
|
205
|
-
"""
|
|
206
|
-
|
|
207
|
-
self._results = results
|
|
49
|
+
def to_str(self) -> str:
|
|
50
|
+
"""Returns the string representation of the model using alias"""
|
|
51
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
208
52
|
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
53
|
+
def to_json(self) -> str:
|
|
54
|
+
"""Returns the JSON representation of the model using alias"""
|
|
55
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
56
|
+
return json.dumps(self.to_dict())
|
|
212
57
|
|
|
58
|
+
@classmethod
|
|
59
|
+
def from_json(cls, json_str: str) -> Self:
|
|
60
|
+
"""Create an instance of ResultIn from a JSON string"""
|
|
61
|
+
return cls.from_dict(json.loads(json_str))
|
|
213
62
|
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
"""
|
|
217
|
-
return self._metadata_id
|
|
218
|
-
|
|
219
|
-
@metadata_id.setter
|
|
220
|
-
def metadata_id(self, metadata_id):
|
|
221
|
-
"""Sets the metadata_id of this ResultIn.
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
:param metadata_id: The metadata_id of this ResultIn. # noqa: E501
|
|
225
|
-
:type metadata_id: int
|
|
226
|
-
"""
|
|
227
|
-
if (self.local_vars_configuration.client_side_validation and
|
|
228
|
-
metadata_id is not None and metadata_id > 2147483647): # noqa: E501
|
|
229
|
-
raise ValueError("Invalid value for `metadata_id`, must be a value less than or equal to `2147483647`") # noqa: E501
|
|
230
|
-
if (self.local_vars_configuration.client_side_validation and
|
|
231
|
-
metadata_id is not None and metadata_id < 1): # noqa: E501
|
|
232
|
-
raise ValueError("Invalid value for `metadata_id`, must be a value greater than or equal to `1`") # noqa: E501
|
|
233
|
-
|
|
234
|
-
self._metadata_id = metadata_id
|
|
235
|
-
|
|
236
|
-
@property
|
|
237
|
-
def run_id(self):
|
|
238
|
-
"""Gets the run_id of this ResultIn. # noqa: E501
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
:return: The run_id of this ResultIn. # noqa: E501
|
|
242
|
-
:rtype: int
|
|
243
|
-
"""
|
|
244
|
-
return self._run_id
|
|
63
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
64
|
+
"""Return the dictionary representation of the model using alias.
|
|
245
65
|
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
"""Sets the run_id of this ResultIn.
|
|
66
|
+
This has the following differences from calling pydantic's
|
|
67
|
+
`self.model_dump(by_alias=True)`:
|
|
249
68
|
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
69
|
+
* `None` is only added to the output dict for nullable fields that
|
|
70
|
+
were set at model initialization. Other fields with value `None`
|
|
71
|
+
are ignored.
|
|
253
72
|
"""
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
def __repr__(self):
|
|
302
|
-
"""For `print` and `pprint`"""
|
|
303
|
-
return self.to_str()
|
|
304
|
-
|
|
305
|
-
def __eq__(self, other):
|
|
306
|
-
"""Returns true if both objects are equal"""
|
|
307
|
-
if not isinstance(other, ResultIn):
|
|
308
|
-
return False
|
|
309
|
-
|
|
310
|
-
return self.to_dict() == other.to_dict()
|
|
73
|
+
_dict = self.model_dump(
|
|
74
|
+
by_alias=True,
|
|
75
|
+
exclude={
|
|
76
|
+
},
|
|
77
|
+
exclude_none=True,
|
|
78
|
+
)
|
|
79
|
+
# set to None if metadata_id (nullable) is None
|
|
80
|
+
# and model_fields_set contains the field
|
|
81
|
+
if self.metadata_id is None and "metadata_id" in self.model_fields_set:
|
|
82
|
+
_dict['metadata_id'] = None
|
|
83
|
+
|
|
84
|
+
# set to None if shots_requested (nullable) is None
|
|
85
|
+
# and model_fields_set contains the field
|
|
86
|
+
if self.shots_requested is None and "shots_requested" in self.model_fields_set:
|
|
87
|
+
_dict['shots_requested'] = None
|
|
88
|
+
|
|
89
|
+
# set to None if shots_done (nullable) is None
|
|
90
|
+
# and model_fields_set contains the field
|
|
91
|
+
if self.shots_done is None and "shots_done" in self.model_fields_set:
|
|
92
|
+
_dict['shots_done'] = None
|
|
93
|
+
|
|
94
|
+
# set to None if results (nullable) is None
|
|
95
|
+
# and model_fields_set contains the field
|
|
96
|
+
if self.results is None and "results" in self.model_fields_set:
|
|
97
|
+
_dict['results'] = None
|
|
98
|
+
|
|
99
|
+
return _dict
|
|
100
|
+
|
|
101
|
+
@classmethod
|
|
102
|
+
def from_dict(cls, obj: Dict) -> Self:
|
|
103
|
+
"""Create an instance of ResultIn from a dict"""
|
|
104
|
+
if obj is None:
|
|
105
|
+
return None
|
|
106
|
+
|
|
107
|
+
if not isinstance(obj, dict):
|
|
108
|
+
return cls.model_validate(obj)
|
|
109
|
+
|
|
110
|
+
_obj = cls.model_validate({
|
|
111
|
+
"job_id": obj.get("job_id"),
|
|
112
|
+
"metadata_id": obj.get("metadata_id"),
|
|
113
|
+
"number_of_qubits": obj.get("number_of_qubits"),
|
|
114
|
+
"execution_time_in_seconds": obj.get("execution_time_in_seconds"),
|
|
115
|
+
"shots_requested": obj.get("shots_requested"),
|
|
116
|
+
"shots_done": obj.get("shots_done"),
|
|
117
|
+
"results": obj.get("results")
|
|
118
|
+
})
|
|
119
|
+
return _obj
|
|
311
120
|
|
|
312
|
-
def __ne__(self, other):
|
|
313
|
-
"""Returns true if both objects are not equal"""
|
|
314
|
-
if not isinstance(other, ResultIn):
|
|
315
|
-
return True
|
|
316
121
|
|
|
317
|
-
return self.to_dict() != other.to_dict()
|
|
@@ -3,109 +3,43 @@
|
|
|
3
3
|
"""
|
|
4
4
|
Quantum Inspire 2
|
|
5
5
|
|
|
6
|
-
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
+
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
7
|
|
|
8
8
|
The version of the OpenAPI document: 0.1.0
|
|
9
|
-
Generated by
|
|
10
|
-
"""
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
11
10
|
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
12
13
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
from inspect import getargspec as getfullargspec
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import json
|
|
17
17
|
import pprint
|
|
18
18
|
import re # noqa: F401
|
|
19
|
-
import
|
|
19
|
+
from enum import Enum
|
|
20
20
|
|
|
21
|
-
from compute_api_client.configuration import Configuration
|
|
22
21
|
|
|
23
22
|
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
23
|
+
try:
|
|
24
|
+
from typing import Self
|
|
25
|
+
except ImportError:
|
|
26
|
+
from typing_extensions import Self
|
|
27
27
|
|
|
28
|
-
Do not edit the class manually.
|
|
29
|
-
"""
|
|
30
28
|
|
|
29
|
+
class Role(str, Enum):
|
|
31
30
|
"""
|
|
32
|
-
|
|
31
|
+
Role
|
|
33
32
|
"""
|
|
34
|
-
MEMBER = "member"
|
|
35
|
-
ADMIN = "admin"
|
|
36
|
-
|
|
37
|
-
allowable_values = [MEMBER, ADMIN] # noqa: E501
|
|
38
33
|
|
|
39
34
|
"""
|
|
40
|
-
|
|
41
|
-
openapi_types (dict): The key is attribute name
|
|
42
|
-
and the value is attribute type.
|
|
43
|
-
attribute_map (dict): The key is attribute name
|
|
44
|
-
and the value is json key in definition.
|
|
35
|
+
allowed enum values
|
|
45
36
|
"""
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
attribute_map = {
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
def __init__(self, local_vars_configuration=None): # noqa: E501
|
|
53
|
-
"""Role - a model defined in OpenAPI""" # noqa: E501
|
|
54
|
-
if local_vars_configuration is None:
|
|
55
|
-
local_vars_configuration = Configuration.get_default_copy()
|
|
56
|
-
self.local_vars_configuration = local_vars_configuration
|
|
57
|
-
self.discriminator = None
|
|
58
|
-
|
|
59
|
-
def to_dict(self, serialize=False):
|
|
60
|
-
"""Returns the model properties as a dict"""
|
|
61
|
-
result = {}
|
|
62
|
-
|
|
63
|
-
def convert(x):
|
|
64
|
-
if hasattr(x, "to_dict"):
|
|
65
|
-
args = getfullargspec(x.to_dict).args
|
|
66
|
-
if len(args) == 1:
|
|
67
|
-
return x.to_dict()
|
|
68
|
-
else:
|
|
69
|
-
return x.to_dict(serialize)
|
|
70
|
-
else:
|
|
71
|
-
return x
|
|
72
|
-
|
|
73
|
-
for attr, _ in six.iteritems(self.openapi_types):
|
|
74
|
-
value = getattr(self, attr)
|
|
75
|
-
attr = self.attribute_map.get(attr, attr) if serialize else attr
|
|
76
|
-
if isinstance(value, list):
|
|
77
|
-
result[attr] = list(map(
|
|
78
|
-
lambda x: convert(x),
|
|
79
|
-
value
|
|
80
|
-
))
|
|
81
|
-
elif isinstance(value, dict):
|
|
82
|
-
result[attr] = dict(map(
|
|
83
|
-
lambda item: (item[0], convert(item[1])),
|
|
84
|
-
value.items()
|
|
85
|
-
))
|
|
86
|
-
else:
|
|
87
|
-
result[attr] = convert(value)
|
|
88
|
-
|
|
89
|
-
return result
|
|
90
|
-
|
|
91
|
-
def to_str(self):
|
|
92
|
-
"""Returns the string representation of the model"""
|
|
93
|
-
return pprint.pformat(self.to_dict())
|
|
94
|
-
|
|
95
|
-
def __repr__(self):
|
|
96
|
-
"""For `print` and `pprint`"""
|
|
97
|
-
return self.to_str()
|
|
98
|
-
|
|
99
|
-
def __eq__(self, other):
|
|
100
|
-
"""Returns true if both objects are equal"""
|
|
101
|
-
if not isinstance(other, Role):
|
|
102
|
-
return False
|
|
37
|
+
MEMBER = 'member'
|
|
38
|
+
ADMIN = 'admin'
|
|
103
39
|
|
|
104
|
-
|
|
40
|
+
@classmethod
|
|
41
|
+
def from_json(cls, json_str: str) -> Self:
|
|
42
|
+
"""Create an instance of Role from a JSON string"""
|
|
43
|
+
return cls(json.loads(json_str))
|
|
105
44
|
|
|
106
|
-
def __ne__(self, other):
|
|
107
|
-
"""Returns true if both objects are not equal"""
|
|
108
|
-
if not isinstance(other, Role):
|
|
109
|
-
return True
|
|
110
45
|
|
|
111
|
-
return self.to_dict() != other.to_dict()
|
|
@@ -3,110 +3,44 @@
|
|
|
3
3
|
"""
|
|
4
4
|
Quantum Inspire 2
|
|
5
5
|
|
|
6
|
-
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
+
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
7
|
|
|
8
8
|
The version of the OpenAPI document: 0.1.0
|
|
9
|
-
Generated by
|
|
10
|
-
"""
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
11
10
|
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
12
13
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
from inspect import getargspec as getfullargspec
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import json
|
|
17
17
|
import pprint
|
|
18
18
|
import re # noqa: F401
|
|
19
|
-
import
|
|
19
|
+
from enum import Enum
|
|
20
20
|
|
|
21
|
-
from compute_api_client.configuration import Configuration
|
|
22
21
|
|
|
23
22
|
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
23
|
+
try:
|
|
24
|
+
from typing import Self
|
|
25
|
+
except ImportError:
|
|
26
|
+
from typing_extensions import Self
|
|
27
27
|
|
|
28
|
-
Do not edit the class manually.
|
|
29
|
-
"""
|
|
30
28
|
|
|
29
|
+
class ShareType(str, Enum):
|
|
31
30
|
"""
|
|
32
|
-
|
|
31
|
+
ShareType
|
|
33
32
|
"""
|
|
34
|
-
PRIVATE = "private"
|
|
35
|
-
LINK_ONLY = "link_only"
|
|
36
|
-
TEAM = "team"
|
|
37
|
-
|
|
38
|
-
allowable_values = [PRIVATE, LINK_ONLY, TEAM] # noqa: E501
|
|
39
33
|
|
|
40
34
|
"""
|
|
41
|
-
|
|
42
|
-
openapi_types (dict): The key is attribute name
|
|
43
|
-
and the value is attribute type.
|
|
44
|
-
attribute_map (dict): The key is attribute name
|
|
45
|
-
and the value is json key in definition.
|
|
35
|
+
allowed enum values
|
|
46
36
|
"""
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
attribute_map = {
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
def __init__(self, local_vars_configuration=None): # noqa: E501
|
|
54
|
-
"""ShareType - a model defined in OpenAPI""" # noqa: E501
|
|
55
|
-
if local_vars_configuration is None:
|
|
56
|
-
local_vars_configuration = Configuration.get_default_copy()
|
|
57
|
-
self.local_vars_configuration = local_vars_configuration
|
|
58
|
-
self.discriminator = None
|
|
59
|
-
|
|
60
|
-
def to_dict(self, serialize=False):
|
|
61
|
-
"""Returns the model properties as a dict"""
|
|
62
|
-
result = {}
|
|
63
|
-
|
|
64
|
-
def convert(x):
|
|
65
|
-
if hasattr(x, "to_dict"):
|
|
66
|
-
args = getfullargspec(x.to_dict).args
|
|
67
|
-
if len(args) == 1:
|
|
68
|
-
return x.to_dict()
|
|
69
|
-
else:
|
|
70
|
-
return x.to_dict(serialize)
|
|
71
|
-
else:
|
|
72
|
-
return x
|
|
73
|
-
|
|
74
|
-
for attr, _ in six.iteritems(self.openapi_types):
|
|
75
|
-
value = getattr(self, attr)
|
|
76
|
-
attr = self.attribute_map.get(attr, attr) if serialize else attr
|
|
77
|
-
if isinstance(value, list):
|
|
78
|
-
result[attr] = list(map(
|
|
79
|
-
lambda x: convert(x),
|
|
80
|
-
value
|
|
81
|
-
))
|
|
82
|
-
elif isinstance(value, dict):
|
|
83
|
-
result[attr] = dict(map(
|
|
84
|
-
lambda item: (item[0], convert(item[1])),
|
|
85
|
-
value.items()
|
|
86
|
-
))
|
|
87
|
-
else:
|
|
88
|
-
result[attr] = convert(value)
|
|
89
|
-
|
|
90
|
-
return result
|
|
91
|
-
|
|
92
|
-
def to_str(self):
|
|
93
|
-
"""Returns the string representation of the model"""
|
|
94
|
-
return pprint.pformat(self.to_dict())
|
|
95
|
-
|
|
96
|
-
def __repr__(self):
|
|
97
|
-
"""For `print` and `pprint`"""
|
|
98
|
-
return self.to_str()
|
|
99
|
-
|
|
100
|
-
def __eq__(self, other):
|
|
101
|
-
"""Returns true if both objects are equal"""
|
|
102
|
-
if not isinstance(other, ShareType):
|
|
103
|
-
return False
|
|
37
|
+
PRIVATE = 'private'
|
|
38
|
+
LINK_ONLY = 'link_only'
|
|
39
|
+
TEAM = 'team'
|
|
104
40
|
|
|
105
|
-
|
|
41
|
+
@classmethod
|
|
42
|
+
def from_json(cls, json_str: str) -> Self:
|
|
43
|
+
"""Create an instance of ShareType from a JSON string"""
|
|
44
|
+
return cls(json.loads(json_str))
|
|
106
45
|
|
|
107
|
-
def __ne__(self, other):
|
|
108
|
-
"""Returns true if both objects are not equal"""
|
|
109
|
-
if not isinstance(other, ShareType):
|
|
110
|
-
return True
|
|
111
46
|
|
|
112
|
-
return self.to_dict() != other.to_dict()
|