azure-quantum 1.0.0.dev1__tar.gz → 1.1.0__tar.gz
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.
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/PKG-INFO +12 -13
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/README.md +11 -12
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/__init__.py +6 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/_client/_version.py +1 -1
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/argument_types/__init__.py +3 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/argument_types/types.py +19 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/cirq/__init__.py +6 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/cirq/job.py +9 -1
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/cirq/service.py +25 -12
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/cirq/targets/__init__.py +2 -0
- azure-quantum-1.1.0/azure/quantum/job/__init__.py +28 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/job/base_job.py +25 -17
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/job/filtered_job.py +6 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/job/job.py +4 -4
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/job/session.py +17 -7
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/job/workspace_item.py +7 -2
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/qiskit/backends/__init__.py +2 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/qiskit/backends/backend.py +9 -5
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/qiskit/backends/quantinuum.py +1 -1
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/qiskit/provider.py +13 -10
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/target/__init__.py +11 -5
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/target/ionq.py +3 -3
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/target/microsoft/__init__.py +3 -0
- azure-quantum-1.1.0/azure/quantum/target/microsoft/elements/__init__.py +1 -0
- azure-quantum-1.1.0/azure/quantum/target/microsoft/elements/dft/__init__.py +6 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/target/microsoft/elements/dft/job.py +17 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/target/microsoft/elements/dft/target.py +21 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/target/microsoft/job.py +8 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/target/microsoft/target.py +19 -1
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/target/params.py +3 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/target/pasqal/result.py +11 -5
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/target/pasqal/target.py +2 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/target/quantinuum.py +9 -10
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/target/rigetti/result.py +2 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/target/rigetti/target.py +4 -5
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/target/target.py +38 -3
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/target/target_factory.py +2 -8
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/version.py +1 -1
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/workspace.py +40 -15
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure_quantum.egg-info/PKG-INFO +12 -13
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure_quantum.egg-info/SOURCES.txt +1 -11
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure_quantum.egg-info/requires.txt +4 -4
- azure-quantum-1.1.0/requirements-qiskit.txt +5 -0
- azure-quantum-1.1.0/requirements-qsharp.txt +1 -0
- azure-quantum-1.0.0.dev1/azure/quantum/job/__init__.py +0 -11
- azure-quantum-1.0.0.dev1/azure/quantum/optimization/__init__.py +0 -11
- azure-quantum-1.0.0.dev1/azure/quantum/optimization/online_problem.py +0 -21
- azure-quantum-1.0.0.dev1/azure/quantum/optimization/problem.py +0 -393
- azure-quantum-1.0.0.dev1/azure/quantum/optimization/solvers.py +0 -10
- azure-quantum-1.0.0.dev1/azure/quantum/optimization/streaming_problem.py +0 -387
- azure-quantum-1.0.0.dev1/azure/quantum/optimization/term.py +0 -203
- azure-quantum-1.0.0.dev1/azure/quantum/optimization/toshiba/__init__.py +0 -10
- azure-quantum-1.0.0.dev1/azure/quantum/optimization/toshiba/solvers.py +0 -12
- azure-quantum-1.0.0.dev1/azure/quantum/target/microsoft/elements/dft/__init__.py +0 -4
- azure-quantum-1.0.0.dev1/azure/quantum/target/solvers.py +0 -382
- azure-quantum-1.0.0.dev1/azure/quantum/target/toshiba/__init__.py +0 -7
- azure-quantum-1.0.0.dev1/azure/quantum/target/toshiba/solvers.py +0 -130
- azure-quantum-1.0.0.dev1/requirements-qiskit.txt +0 -6
- azure-quantum-1.0.0.dev1/requirements-qsharp.txt +0 -1
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/_authentication/__init__.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/_authentication/_chained.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/_authentication/_default.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/_authentication/_token.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/_client/__init__.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/_client/_client.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/_client/_configuration.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/_client/_patch.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/_client/_serialization.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/_client/_vendor.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/_client/models/__init__.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/_client/models/_enums.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/_client/models/_models.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/_client/models/_patch.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/_client/operations/__init__.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/_client/operations/_operations.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/_client/operations/_patch.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/chemistry/__init__.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/cirq/targets/ionq.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/cirq/targets/quantinuum.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/cirq/targets/target.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/job/job_failed_with_results_error.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/job/workspace_item_factory.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/qiskit/__init__.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/qiskit/backends/ionq.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/qiskit/backends/microsoft.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/qiskit/backends/qci.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/qiskit/backends/rigetti.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/qiskit/job.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/qiskit/results/__init__.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/qiskit/results/resource_estimator.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/storage.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/target/microsoft/result.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/target/pasqal/__init__.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure/quantum/target/rigetti/__init__.py +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure_quantum.egg-info/dependency_links.txt +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/azure_quantum.egg-info/top_level.txt +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/requirements-cirq.txt +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/requirements-dev.txt +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/requirements-quil.txt +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/requirements.txt +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/setup.cfg +0 -0
- {azure-quantum-1.0.0.dev1 → azure-quantum-1.1.0}/setup.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: azure-quantum
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.1.0
|
|
4
4
|
Summary: Python client for Azure Quantum
|
|
5
5
|
Home-page: https://github.com/microsoft/azure-quantum-python
|
|
6
6
|
Author: Microsoft
|
|
@@ -23,10 +23,9 @@ Provides-Extra: all
|
|
|
23
23
|
|
|
24
24
|
[/_apis/build/status/microsoft.qdk-python?branchName=main)](https://dev.azure.com/ms-quantum-public/Microsoft%20Quantum%20(public)/_build/latest?definitionId=32&branchName=main) [](https://badge.fury.io/py/azure-quantum)
|
|
25
25
|
|
|
26
|
-
Azure Quantum is Microsoft's cloud service for running Quantum Computing
|
|
27
|
-
including creating jobs, listing jobs, and retrieving job results. For more information, view the [Azure Quantum Documentation](https://docs.microsoft.com/azure/quantum).
|
|
26
|
+
Azure Quantum is Microsoft's cloud service for running Quantum Computing programs and circuits with our quantum partners and technologies. The `azure-quantum` package for Python provides functionality for interacting with Azure Quantum workspaces, including creating jobs, listing jobs, and retrieving job results. For more information, view the [Azure Quantum Documentation](https://learn.microsoft.com/en-us/azure/quantum/).
|
|
28
27
|
|
|
29
|
-
This package supports submitting quantum
|
|
28
|
+
This package supports submitting quantum programs or circuits written with Python. To submit quantum programs written with Q#, Microsoft's Domain-specific language for Quantum Programming, view [Submit Q# Jobs to Azure Quantum](https://learn.microsoft.com/azure/quantum/how-to-submit-jobs).
|
|
30
29
|
|
|
31
30
|
## Installation ##
|
|
32
31
|
|
|
@@ -50,13 +49,13 @@ pip install azure-quantum[cirq]
|
|
|
50
49
|
|
|
51
50
|
## Getting started and Quickstart guides ##
|
|
52
51
|
|
|
53
|
-
To work in Azure Quantum, you need an Azure subscription. If you don't have an Azure subscription, create a [free account](https://azure.microsoft.com/free/). Follow the [Create an Azure Quantum workspace](https://
|
|
52
|
+
To work in Azure Quantum, you need an Azure subscription. If you don't have an Azure subscription, create a [free account](https://azure.microsoft.com/free/). Follow the [Create an Azure Quantum workspace](https://learn.microsoft.com/azure/quantum/how-to-create-workspace) how-to guide to set up your Workspace and enable your preferred providers.
|
|
54
53
|
|
|
55
54
|
To get started, visit the following Quickstart guides:
|
|
56
55
|
|
|
57
|
-
- [Quickstart: Submit a circuit with Qiskit](https://
|
|
58
|
-
- [Quickstart: Submit a circuit with Cirq](https://
|
|
59
|
-
- [Quickstart: Submit a circuit with a provider-specific format](https://
|
|
56
|
+
- [Quickstart: Submit a circuit with Qiskit](https://learn.microsoft.com/azure/quantum/quickstart-microsoft-qiskit)
|
|
57
|
+
- [Quickstart: Submit a circuit with Cirq](https://learn.microsoft.com/azure/quantum/quickstart-microsoft-qiskit)
|
|
58
|
+
- [Quickstart: Submit a circuit with a provider-specific format](https://learn.microsoft.com/azure/quantum/quickstart-microsoft-provider-format).
|
|
60
59
|
|
|
61
60
|
## General usage ##
|
|
62
61
|
|
|
@@ -80,16 +79,16 @@ To list all targets that are available to your workspace, run
|
|
|
80
79
|
workspace.get_targets()
|
|
81
80
|
```
|
|
82
81
|
|
|
83
|
-
### Submit a quantum
|
|
82
|
+
### Submit a quantum program or circuit ###
|
|
84
83
|
|
|
85
|
-
First, define a quantum
|
|
84
|
+
First, define a quantum program or circuit, and create a job by submitting it to one of the available targets:
|
|
86
85
|
|
|
87
86
|
```python
|
|
88
87
|
# Enter target name below
|
|
89
|
-
target = workspace.get_targets("")
|
|
88
|
+
target = workspace.get_targets("mytarget")
|
|
90
89
|
|
|
91
|
-
# Submit quantum
|
|
92
|
-
job = target.submit(
|
|
90
|
+
# Submit quantum program or circuit
|
|
91
|
+
job = target.submit(my_quantum_program)
|
|
93
92
|
|
|
94
93
|
# Wait for job to complete and fetch results
|
|
95
94
|
result = job.get_results()
|
|
@@ -4,10 +4,9 @@
|
|
|
4
4
|
|
|
5
5
|
[/_apis/build/status/microsoft.qdk-python?branchName=main)](https://dev.azure.com/ms-quantum-public/Microsoft%20Quantum%20(public)/_build/latest?definitionId=32&branchName=main) [](https://badge.fury.io/py/azure-quantum)
|
|
6
6
|
|
|
7
|
-
Azure Quantum is Microsoft's cloud service for running Quantum Computing
|
|
8
|
-
including creating jobs, listing jobs, and retrieving job results. For more information, view the [Azure Quantum Documentation](https://docs.microsoft.com/azure/quantum).
|
|
7
|
+
Azure Quantum is Microsoft's cloud service for running Quantum Computing programs and circuits with our quantum partners and technologies. The `azure-quantum` package for Python provides functionality for interacting with Azure Quantum workspaces, including creating jobs, listing jobs, and retrieving job results. For more information, view the [Azure Quantum Documentation](https://learn.microsoft.com/en-us/azure/quantum/).
|
|
9
8
|
|
|
10
|
-
This package supports submitting quantum
|
|
9
|
+
This package supports submitting quantum programs or circuits written with Python. To submit quantum programs written with Q#, Microsoft's Domain-specific language for Quantum Programming, view [Submit Q# Jobs to Azure Quantum](https://learn.microsoft.com/azure/quantum/how-to-submit-jobs).
|
|
11
10
|
|
|
12
11
|
## Installation ##
|
|
13
12
|
|
|
@@ -31,13 +30,13 @@ pip install azure-quantum[cirq]
|
|
|
31
30
|
|
|
32
31
|
## Getting started and Quickstart guides ##
|
|
33
32
|
|
|
34
|
-
To work in Azure Quantum, you need an Azure subscription. If you don't have an Azure subscription, create a [free account](https://azure.microsoft.com/free/). Follow the [Create an Azure Quantum workspace](https://
|
|
33
|
+
To work in Azure Quantum, you need an Azure subscription. If you don't have an Azure subscription, create a [free account](https://azure.microsoft.com/free/). Follow the [Create an Azure Quantum workspace](https://learn.microsoft.com/azure/quantum/how-to-create-workspace) how-to guide to set up your Workspace and enable your preferred providers.
|
|
35
34
|
|
|
36
35
|
To get started, visit the following Quickstart guides:
|
|
37
36
|
|
|
38
|
-
- [Quickstart: Submit a circuit with Qiskit](https://
|
|
39
|
-
- [Quickstart: Submit a circuit with Cirq](https://
|
|
40
|
-
- [Quickstart: Submit a circuit with a provider-specific format](https://
|
|
37
|
+
- [Quickstart: Submit a circuit with Qiskit](https://learn.microsoft.com/azure/quantum/quickstart-microsoft-qiskit)
|
|
38
|
+
- [Quickstart: Submit a circuit with Cirq](https://learn.microsoft.com/azure/quantum/quickstart-microsoft-qiskit)
|
|
39
|
+
- [Quickstart: Submit a circuit with a provider-specific format](https://learn.microsoft.com/azure/quantum/quickstart-microsoft-provider-format).
|
|
41
40
|
|
|
42
41
|
## General usage ##
|
|
43
42
|
|
|
@@ -61,16 +60,16 @@ To list all targets that are available to your workspace, run
|
|
|
61
60
|
workspace.get_targets()
|
|
62
61
|
```
|
|
63
62
|
|
|
64
|
-
### Submit a quantum
|
|
63
|
+
### Submit a quantum program or circuit ###
|
|
65
64
|
|
|
66
|
-
First, define a quantum
|
|
65
|
+
First, define a quantum program or circuit, and create a job by submitting it to one of the available targets:
|
|
67
66
|
|
|
68
67
|
```python
|
|
69
68
|
# Enter target name below
|
|
70
|
-
target = workspace.get_targets("")
|
|
69
|
+
target = workspace.get_targets("mytarget")
|
|
71
70
|
|
|
72
|
-
# Submit quantum
|
|
73
|
-
job = target.submit(
|
|
71
|
+
# Submit quantum program or circuit
|
|
72
|
+
job = target.submit(my_quantum_program)
|
|
74
73
|
|
|
75
74
|
# Wait for job to complete and fetch results
|
|
76
75
|
result = job.get_results()
|
|
@@ -3,6 +3,9 @@
|
|
|
3
3
|
# Licensed under the MIT License.
|
|
4
4
|
##
|
|
5
5
|
|
|
6
|
+
"""Defines interfaces for interacting with Azure Quantum"""
|
|
7
|
+
|
|
8
|
+
|
|
6
9
|
import logging
|
|
7
10
|
from .version import __version__
|
|
8
11
|
|
|
@@ -14,3 +17,6 @@ from ._client.models._enums import JobStatus, SessionStatus, SessionJobFailurePo
|
|
|
14
17
|
|
|
15
18
|
logger = logging.getLogger(__name__)
|
|
16
19
|
logger.info(f"version: {__version__}")
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
__all__ = [ "Workspace" ]
|
|
@@ -2,6 +2,9 @@
|
|
|
2
2
|
# Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
3
|
# Licensed under the MIT License.
|
|
4
4
|
##
|
|
5
|
+
|
|
6
|
+
"""Defines argument types for Microsoft Estimator"""
|
|
7
|
+
|
|
5
8
|
from .types import EmptyArray, Pauli, Range, Result
|
|
6
9
|
|
|
7
10
|
__all__ = ['EmptyArray', 'Pauli', 'Range', 'Result']
|
|
@@ -7,6 +7,8 @@ from enum import Enum
|
|
|
7
7
|
from typing import Optional, Type
|
|
8
8
|
|
|
9
9
|
class Pauli(Enum):
|
|
10
|
+
"""Pauli operators"""
|
|
11
|
+
|
|
10
12
|
I = "PauliI"
|
|
11
13
|
X = "PauliX"
|
|
12
14
|
Y = "PauliY"
|
|
@@ -14,18 +16,32 @@ class Pauli(Enum):
|
|
|
14
16
|
|
|
15
17
|
|
|
16
18
|
class Result(Enum):
|
|
19
|
+
"""Result value"""
|
|
20
|
+
|
|
17
21
|
Zero = False
|
|
18
22
|
One = True
|
|
19
23
|
|
|
20
24
|
|
|
21
25
|
@dataclass
|
|
22
26
|
class Range:
|
|
27
|
+
"""Range value
|
|
28
|
+
|
|
29
|
+
:param start: Start
|
|
30
|
+
:type start: int
|
|
31
|
+
:param end: End
|
|
32
|
+
:type end: int
|
|
33
|
+
:param step: Step
|
|
34
|
+
:type step: int
|
|
35
|
+
"""
|
|
36
|
+
|
|
23
37
|
start: int
|
|
24
38
|
end: int
|
|
25
39
|
step: Optional[int] = None
|
|
26
40
|
|
|
27
41
|
@property
|
|
28
42
|
def value(self):
|
|
43
|
+
"""Range value"""
|
|
44
|
+
|
|
29
45
|
if self.step is None:
|
|
30
46
|
return {"start": self.start, "end": self.end}
|
|
31
47
|
else:
|
|
@@ -33,4 +49,7 @@ class Range:
|
|
|
33
49
|
|
|
34
50
|
@dataclass
|
|
35
51
|
class EmptyArray:
|
|
52
|
+
"""Empty array value"""
|
|
53
|
+
|
|
36
54
|
element_type: Type
|
|
55
|
+
"""Element type"""
|
|
@@ -20,7 +20,15 @@ class Job:
|
|
|
20
20
|
program: "cirq.Circuit",
|
|
21
21
|
measurement_dict: dict = None
|
|
22
22
|
):
|
|
23
|
-
"""Construct a Job.
|
|
23
|
+
"""Construct a Job.
|
|
24
|
+
|
|
25
|
+
:param azure_job: Job
|
|
26
|
+
:type azure_job: azure.quantum.job.Job
|
|
27
|
+
:param program: Cirq program
|
|
28
|
+
:type program: cirq.Circuit
|
|
29
|
+
:param measurement_dict: Measurments
|
|
30
|
+
:type measurement_dict: dict
|
|
31
|
+
"""
|
|
24
32
|
self._azure_job = azure_job
|
|
25
33
|
self._program = program
|
|
26
34
|
self._measurement_dict = measurement_dict
|
|
@@ -39,9 +39,9 @@ class AzureQuantumService:
|
|
|
39
39
|
"""AzureQuantumService class
|
|
40
40
|
|
|
41
41
|
:param workspace: Azure Quantum workspace. If missing it will create a new Workspace passing `kwargs` to the constructor. Defaults to None.
|
|
42
|
-
:type workspace: Workspace
|
|
42
|
+
:type workspace: Workspace
|
|
43
43
|
:param default_target: Default target name, defaults to None
|
|
44
|
-
:type default_target: Optional[str]
|
|
44
|
+
:type default_target: Optional[str]
|
|
45
45
|
"""
|
|
46
46
|
if kwargs is not None and len(kwargs) > 0:
|
|
47
47
|
from warnings import warn
|
|
@@ -80,9 +80,9 @@ class AzureQuantumService:
|
|
|
80
80
|
"""Get all quantum computing targets available in the Azure Quantum Workspace.
|
|
81
81
|
|
|
82
82
|
:param name: Target name, defaults to None
|
|
83
|
-
:type name: str
|
|
83
|
+
:type name: str
|
|
84
84
|
:return: Target instance or list thereof
|
|
85
|
-
:rtype: Union[Target, List[Target]]
|
|
85
|
+
:rtype: typing.Union[Target, typing.List[Target]]
|
|
86
86
|
"""
|
|
87
87
|
return self._target_factory.get_targets(
|
|
88
88
|
name=name,
|
|
@@ -95,7 +95,7 @@ class AzureQuantumService:
|
|
|
95
95
|
:param name: Target name
|
|
96
96
|
:type name: str
|
|
97
97
|
:return: Cirq target
|
|
98
|
-
:rtype:
|
|
98
|
+
:rtype: Target
|
|
99
99
|
"""
|
|
100
100
|
if name is None:
|
|
101
101
|
if self._default_target is None:
|
|
@@ -111,7 +111,7 @@ class AzureQuantumService:
|
|
|
111
111
|
:param job_id: Job ID
|
|
112
112
|
:type job_id: str
|
|
113
113
|
:return: Job
|
|
114
|
-
:rtype: azure.quantum.cirq.Job
|
|
114
|
+
:rtype: azure.quantum.cirq.Job
|
|
115
115
|
"""
|
|
116
116
|
job = self._workspace.get_job(job_id=job_id)
|
|
117
117
|
target : CirqTarget = self._target_factory.create_target(
|
|
@@ -168,6 +168,19 @@ see https://aka.ms/AQ/Docs/AddProvider")
|
|
|
168
168
|
param_resolver: cirq.ParamResolverOrSimilarType = cirq.ParamResolver({}),
|
|
169
169
|
**kwargs
|
|
170
170
|
):
|
|
171
|
+
"""
|
|
172
|
+
Estimate the cost for a given circuit.
|
|
173
|
+
|
|
174
|
+
:param program: Cirq program or circuit
|
|
175
|
+
:type program: cirq.Circuit
|
|
176
|
+
:param repetitions: Number of measurement repetitions
|
|
177
|
+
:type repetitions: int
|
|
178
|
+
:param target: Target name, defaults to default_target
|
|
179
|
+
:type target: str
|
|
180
|
+
:param param_resolver: Cirq parameters, defaults to `cirq.ParamResolver({})`
|
|
181
|
+
:type param_resolver: cirq.ParamResolverOrSimilarType
|
|
182
|
+
"""
|
|
183
|
+
|
|
171
184
|
# Resolve parameters
|
|
172
185
|
resolved_circuit = cirq.resolve_parameters(program, param_resolver)
|
|
173
186
|
target = self.get_target(name=target)
|
|
@@ -194,15 +207,15 @@ see https://aka.ms/AQ/Docs/AddProvider")
|
|
|
194
207
|
:param repetitions: Number of measurement repetitions
|
|
195
208
|
:type repetitions: int
|
|
196
209
|
:param target: Target name, defaults to default_target
|
|
197
|
-
:type target: str
|
|
210
|
+
:type target: str
|
|
198
211
|
:param name: Program name, defaults to "cirq-job"
|
|
199
|
-
:type name: str
|
|
200
|
-
:param param_resolver: Cirq parameters, defaults to cirq.ParamResolver({})
|
|
201
|
-
:type param_resolver: cirq.ParamResolverOrSimilarType
|
|
212
|
+
:type name: str
|
|
213
|
+
:param param_resolver: Cirq parameters, defaults to `cirq.ParamResolver({})`
|
|
214
|
+
:type param_resolver: cirq.ParamResolverOrSimilarType
|
|
202
215
|
:param seed: Random seed for simulator results, defaults to None
|
|
203
|
-
:type seed: cirq.RANDOM_STATE_OR_SEED_LIKE
|
|
216
|
+
:type seed: cirq.RANDOM_STATE_OR_SEED_LIKE
|
|
204
217
|
:param timeout_seconds: Timeout in seconds, defaults to None
|
|
205
|
-
:type timeout_seconds: int
|
|
218
|
+
:type timeout_seconds: int
|
|
206
219
|
:return: Measurement results
|
|
207
220
|
:rtype: cirq.Result
|
|
208
221
|
"""
|
|
@@ -3,6 +3,8 @@
|
|
|
3
3
|
# Licensed under the MIT License.
|
|
4
4
|
##
|
|
5
5
|
|
|
6
|
+
"""Defines set of Cirq targets for interacting with Azure Quantum"""
|
|
7
|
+
|
|
6
8
|
from azure.quantum.cirq.targets.target import Target
|
|
7
9
|
from azure.quantum.cirq.targets.quantinuum import QuantinuumTarget
|
|
8
10
|
from azure.quantum.cirq.targets.ionq import IonQTarget
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
##
|
|
2
|
+
# Copyright (c) Microsoft Corporation.
|
|
3
|
+
# Licensed under the MIT License.
|
|
4
|
+
##
|
|
5
|
+
|
|
6
|
+
"""Defines Azure Quantum job model"""
|
|
7
|
+
|
|
8
|
+
from azure.quantum._client.models import JobDetails
|
|
9
|
+
from .base_job import BaseJob
|
|
10
|
+
from .filtered_job import FilteredJob
|
|
11
|
+
from .job import Job
|
|
12
|
+
from .job_failed_with_results_error import JobFailedWithResultsError
|
|
13
|
+
from .workspace_item import WorkspaceItem
|
|
14
|
+
from .workspace_item_factory import WorkspaceItemFactory
|
|
15
|
+
from .session import Session, SessionHost, SessionDetails, SessionStatus, SessionJobFailurePolicy
|
|
16
|
+
|
|
17
|
+
__all__ = [
|
|
18
|
+
"Job",
|
|
19
|
+
"JobDetails",
|
|
20
|
+
"BaseJob",
|
|
21
|
+
"FilteredJob",
|
|
22
|
+
"WorkspaceItem",
|
|
23
|
+
"Session",
|
|
24
|
+
"SessionHost",
|
|
25
|
+
"SessionDetails",
|
|
26
|
+
"SessionStatus",
|
|
27
|
+
"SessionJobFailurePolicy"
|
|
28
|
+
]
|
|
@@ -33,6 +33,12 @@ class BaseJob(WorkspaceItem):
|
|
|
33
33
|
"""
|
|
34
34
|
Base job class with methods to create a job from raw blob data,
|
|
35
35
|
upload blob data and download results.
|
|
36
|
+
|
|
37
|
+
:param workspace: Workspace instance of the job
|
|
38
|
+
:type workspace: Workspace
|
|
39
|
+
:param details: Item details model,
|
|
40
|
+
contains item ID, name and other details
|
|
41
|
+
:type details: ItemDetails
|
|
36
42
|
"""
|
|
37
43
|
|
|
38
44
|
@staticmethod
|
|
@@ -42,6 +48,7 @@ class BaseJob(WorkspaceItem):
|
|
|
42
48
|
|
|
43
49
|
@property
|
|
44
50
|
def details(self) -> JobDetails:
|
|
51
|
+
"""Job details"""
|
|
45
52
|
return self._details
|
|
46
53
|
|
|
47
54
|
@details.setter
|
|
@@ -50,6 +57,7 @@ class BaseJob(WorkspaceItem):
|
|
|
50
57
|
|
|
51
58
|
@property
|
|
52
59
|
def container_name(self):
|
|
60
|
+
"""Job input/output data container name"""
|
|
53
61
|
return f"job-{self.id}"
|
|
54
62
|
|
|
55
63
|
@classmethod
|
|
@@ -74,7 +82,7 @@ class BaseJob(WorkspaceItem):
|
|
|
74
82
|
"""Create a new Azure Quantum job based on a raw input_data payload.
|
|
75
83
|
|
|
76
84
|
:param workspace: Azure Quantum workspace to submit the input_data to
|
|
77
|
-
:type workspace:
|
|
85
|
+
:type workspace: Workspace
|
|
78
86
|
:param name: Name of the job
|
|
79
87
|
:type name: str
|
|
80
88
|
:param target: Azure Quantum target
|
|
@@ -88,17 +96,17 @@ class BaseJob(WorkspaceItem):
|
|
|
88
96
|
:param encoding: input_data encoding, e.g. "gzip", defaults to empty string
|
|
89
97
|
:type encoding: str
|
|
90
98
|
:param job_id: Job ID, defaults to None
|
|
91
|
-
:type job_id: str
|
|
99
|
+
:type job_id: str
|
|
92
100
|
:param container_name: Container name, defaults to None
|
|
93
101
|
:type container_name: str
|
|
94
102
|
:param provider_id: Provider ID, defaults to None
|
|
95
|
-
:type provider_id: str
|
|
103
|
+
:type provider_id: str
|
|
96
104
|
:param input_data_format: Input data format, defaults to None
|
|
97
|
-
:type input_data_format: str
|
|
105
|
+
:type input_data_format: str
|
|
98
106
|
:param output_data_format: Output data format, defaults to None
|
|
99
|
-
:type output_data_format: str
|
|
107
|
+
:type output_data_format: str
|
|
100
108
|
:param input_params: Input parameters, defaults to None
|
|
101
|
-
:type input_params: Dict[str, Any]
|
|
109
|
+
:type input_params: Dict[str, Any]
|
|
102
110
|
:param input_params: Input params for job
|
|
103
111
|
:type input_params: Dict[str, Any]
|
|
104
112
|
:return: Azure Quantum Job
|
|
@@ -161,7 +169,7 @@ class BaseJob(WorkspaceItem):
|
|
|
161
169
|
to blob storage
|
|
162
170
|
|
|
163
171
|
:param workspace: Azure Quantum workspace to submit the blob to
|
|
164
|
-
:type workspace:
|
|
172
|
+
:type workspace: Workspace
|
|
165
173
|
:param name: Job name
|
|
166
174
|
:type name: str
|
|
167
175
|
:param target: Azure Quantum target
|
|
@@ -169,17 +177,17 @@ class BaseJob(WorkspaceItem):
|
|
|
169
177
|
:param input_data_uri: Input data URI
|
|
170
178
|
:type input_data_uri: str
|
|
171
179
|
:param provider_id: Provider ID
|
|
172
|
-
:type provider_id: str
|
|
180
|
+
:type provider_id: str
|
|
173
181
|
:param input_data_format: Input data format
|
|
174
|
-
:type input_data_format: str
|
|
182
|
+
:type input_data_format: str
|
|
175
183
|
:param output_data_format: Output data format
|
|
176
|
-
:type output_data_format: str
|
|
184
|
+
:type output_data_format: str
|
|
177
185
|
:param container_uri: Container URI, defaults to None
|
|
178
186
|
:type container_uri: str
|
|
179
187
|
:param job_id: Pre-generated job ID, defaults to None
|
|
180
188
|
:type job_id: str
|
|
181
189
|
:param input_params: Input parameters, defaults to None
|
|
182
|
-
:type input_params: Dict[str, Any]
|
|
190
|
+
:type input_params: Dict[str, Any]
|
|
183
191
|
:param submit_job: If job should be submitted to the service, defaults to True
|
|
184
192
|
:type submit_job: bool
|
|
185
193
|
:return: Job instance
|
|
@@ -212,7 +220,7 @@ class BaseJob(WorkspaceItem):
|
|
|
212
220
|
job = cls(workspace, details, **kwargs)
|
|
213
221
|
|
|
214
222
|
logger.info(
|
|
215
|
-
f"Submitting
|
|
223
|
+
f"Submitting job '{name}'. \
|
|
216
224
|
Using payload from: '{job.details.input_data_uri}'"
|
|
217
225
|
)
|
|
218
226
|
|
|
@@ -240,11 +248,11 @@ class BaseJob(WorkspaceItem):
|
|
|
240
248
|
:param content_type: Content type, e.g. "application/json"
|
|
241
249
|
:type content_type: Optional, ContentType
|
|
242
250
|
:param blob_name: Blob name, defaults to "inputData"
|
|
243
|
-
:type blob_name: str
|
|
251
|
+
:type blob_name: str
|
|
244
252
|
:param encoding: Encoding, e.g. "gzip", defaults to ""
|
|
245
|
-
:type encoding: str
|
|
253
|
+
:type encoding: str
|
|
246
254
|
:param return_sas_token: Flag to return SAS token as part of URI, defaults to False
|
|
247
|
-
:type return_sas_token: bool
|
|
255
|
+
:type return_sas_token: bool
|
|
248
256
|
:return: Uploaded data URI
|
|
249
257
|
:rtype: str
|
|
250
258
|
"""
|
|
@@ -306,7 +314,7 @@ class BaseJob(WorkspaceItem):
|
|
|
306
314
|
:param data: Attachment data in binary format
|
|
307
315
|
:type input_data: bytes
|
|
308
316
|
:param container_uri: Container URI, defaults to the job's linked container.
|
|
309
|
-
:type container_uri: str
|
|
317
|
+
:type container_uri: str
|
|
310
318
|
|
|
311
319
|
:return: Uploaded data URI
|
|
312
320
|
:rtype: str
|
|
@@ -336,7 +344,7 @@ class BaseJob(WorkspaceItem):
|
|
|
336
344
|
:param name: Attachment name
|
|
337
345
|
:type name: str
|
|
338
346
|
:param container_uri: Container URI, defaults to the job's linked container.
|
|
339
|
-
:type container_uri: str
|
|
347
|
+
:type container_uri: str
|
|
340
348
|
|
|
341
349
|
:return: Attachment data
|
|
342
350
|
:rtype: bytes
|
|
@@ -22,9 +22,15 @@ class FilteredJob(abc.ABC):
|
|
|
22
22
|
created_after: Optional[datetime] = None
|
|
23
23
|
) -> bool:
|
|
24
24
|
"""Checks if job (self) matches the given properties if any.
|
|
25
|
+
|
|
25
26
|
:param name_match: regex expression for job name matching
|
|
27
|
+
:type name_match: str
|
|
26
28
|
:param status: filter by job status
|
|
29
|
+
:type status: Optional[JobStatus]
|
|
27
30
|
:param created_after: filter jobs after time of job creation
|
|
31
|
+
:type status: Optional[datetime]
|
|
32
|
+
:return: Is filter match
|
|
33
|
+
:rtype: bool
|
|
28
34
|
"""
|
|
29
35
|
if name_match is not None and re.search(name_match, self.details.name) is None:
|
|
30
36
|
return False
|
|
@@ -74,11 +74,11 @@ class Job(BaseJob, FilteredJob):
|
|
|
74
74
|
until it reaches a finished status.
|
|
75
75
|
|
|
76
76
|
:param max_poll_wait_secs: Maximum poll wait time, defaults to 30
|
|
77
|
-
:type max_poll_wait_secs: int
|
|
77
|
+
:type max_poll_wait_secs: int
|
|
78
78
|
:param timeout_secs: Timeout in seconds, defaults to None
|
|
79
|
-
:type timeout_secs: int
|
|
79
|
+
:type timeout_secs: int
|
|
80
80
|
:param print_progress: Print "." to stdout to display progress
|
|
81
|
-
:type print_progress: bool
|
|
81
|
+
:type print_progress: bool
|
|
82
82
|
:raises TimeoutError: If the total poll time exceeds timeout, raise
|
|
83
83
|
"""
|
|
84
84
|
self.refresh()
|
|
@@ -107,7 +107,7 @@ class Job(BaseJob, FilteredJob):
|
|
|
107
107
|
storage container linked via the workspace.
|
|
108
108
|
|
|
109
109
|
:param timeout_secs: Timeout in seconds, defaults to 300
|
|
110
|
-
:type timeout_secs:
|
|
110
|
+
:type timeout_secs: float
|
|
111
111
|
:raises RuntimeError: Raises RuntimeError if job execution failed
|
|
112
112
|
:return: Results dictionary with histogram shots, or raw results if not a json object.
|
|
113
113
|
"""
|
|
@@ -103,6 +103,7 @@ class Session(WorkspaceItem):
|
|
|
103
103
|
@property
|
|
104
104
|
def details(self) -> SessionDetails:
|
|
105
105
|
"""Get the session details.
|
|
106
|
+
|
|
106
107
|
:return: The details about the session.
|
|
107
108
|
:rtype: SessionDetails
|
|
108
109
|
"""
|
|
@@ -111,6 +112,7 @@ class Session(WorkspaceItem):
|
|
|
111
112
|
@details.setter
|
|
112
113
|
def details(self, value: SessionDetails):
|
|
113
114
|
"""Set session details.
|
|
115
|
+
|
|
114
116
|
:param value: The details about the session
|
|
115
117
|
:type value: SessionDetails
|
|
116
118
|
"""
|
|
@@ -119,6 +121,7 @@ class Session(WorkspaceItem):
|
|
|
119
121
|
@property
|
|
120
122
|
def target(self) -> "Target":
|
|
121
123
|
"""Get the target associated with the session.
|
|
124
|
+
|
|
122
125
|
:return: The target associated with the session.
|
|
123
126
|
:rtype: Target
|
|
124
127
|
"""
|
|
@@ -157,7 +160,7 @@ class Session(WorkspaceItem):
|
|
|
157
160
|
"""Lists all jobs associated with this session.
|
|
158
161
|
|
|
159
162
|
:return: A list of all jobs associated with this session.
|
|
160
|
-
:rtype: List[Job]
|
|
163
|
+
:rtype: typing.List[Job]
|
|
161
164
|
"""
|
|
162
165
|
return self.workspace.list_session_jobs(session_id=self.id)
|
|
163
166
|
|
|
@@ -199,10 +202,15 @@ class SessionHost(Protocol):
|
|
|
199
202
|
with that session.
|
|
200
203
|
|
|
201
204
|
Example (job 1 to 3 will be associated the session "MySession"):
|
|
202
|
-
|
|
205
|
+
|
|
206
|
+
.. highlight:: python
|
|
207
|
+
.. code-block::
|
|
208
|
+
|
|
209
|
+
with target.open_session(name="MySession") as session:
|
|
203
210
|
job1 = target.submit(input_data=input_data, job_name="Job 1")
|
|
204
211
|
job2 = target.submit(input_data=input_data, job_name="Job 2")
|
|
205
212
|
job3 = target.submit(input_data=input_data, job_name="Job 3")
|
|
213
|
+
|
|
206
214
|
"""
|
|
207
215
|
|
|
208
216
|
_latest_session: Optional[Session] = None
|
|
@@ -212,7 +220,7 @@ class SessionHost(Protocol):
|
|
|
212
220
|
"""Get the latest (open) session associated with this object.
|
|
213
221
|
|
|
214
222
|
:return: The latest session object.
|
|
215
|
-
:rtype: Optional[Session]
|
|
223
|
+
:rtype: typing.Optional[Session]
|
|
216
224
|
"""
|
|
217
225
|
return self._latest_session
|
|
218
226
|
|
|
@@ -229,7 +237,7 @@ class SessionHost(Protocol):
|
|
|
229
237
|
This id is used to associate jobs to the latest (open) session.
|
|
230
238
|
|
|
231
239
|
:return: The latest session id.
|
|
232
|
-
:rtype: Optional[str]
|
|
240
|
+
:rtype: typing.Optional[str]
|
|
233
241
|
"""
|
|
234
242
|
return self.latest_session.id if self.latest_session else None
|
|
235
243
|
|
|
@@ -258,7 +266,11 @@ class SessionHost(Protocol):
|
|
|
258
266
|
after exiting a `with` block).
|
|
259
267
|
|
|
260
268
|
Example (job 1 to 3 will be associated the session "MySession"):
|
|
261
|
-
|
|
269
|
+
|
|
270
|
+
.. highlight:: python
|
|
271
|
+
.. code-block::
|
|
272
|
+
|
|
273
|
+
with target.open_session(name="MySession") as session:
|
|
262
274
|
job1 = target.submit(input_data=input_data, job_name="Job 1")
|
|
263
275
|
job2 = target.submit(input_data=input_data, job_name="Job 2")
|
|
264
276
|
job3 = target.submit(input_data=input_data, job_name="Job 3")
|
|
@@ -273,7 +285,6 @@ class SessionHost(Protocol):
|
|
|
273
285
|
Either this parameter should be passed containing all
|
|
274
286
|
the session detail values, the same values should be
|
|
275
287
|
passed as individual parameters.
|
|
276
|
-
:type details: Optional[SessionDetails]
|
|
277
288
|
|
|
278
289
|
:param id: The id of the session. If not passed, one random uuid will used.
|
|
279
290
|
:type id: Optional[str]
|
|
@@ -284,7 +295,6 @@ class SessionHost(Protocol):
|
|
|
284
295
|
|
|
285
296
|
:param job_failure_policy: The policy that determines when a session would fail,
|
|
286
297
|
close and not accept further jobs.
|
|
287
|
-
:type job_failure_policy: Union[str, SessionJobFailurePolicy, None]
|
|
288
298
|
|
|
289
299
|
:return: The session object with updated details after its opening.
|
|
290
300
|
:rtype: Session
|
|
@@ -16,12 +16,13 @@ __all__ = ["WorkspaceItem"]
|
|
|
16
16
|
|
|
17
17
|
class WorkspaceItem(abc.ABC):
|
|
18
18
|
"""
|
|
19
|
+
Workspace item base class.
|
|
19
20
|
|
|
20
21
|
:param workspace: Workspace instance to submit job to
|
|
21
22
|
:type workspace: Workspace
|
|
22
|
-
:param
|
|
23
|
+
:param details: Item details model,
|
|
23
24
|
contains item ID, name and other details
|
|
24
|
-
:type
|
|
25
|
+
:type details: ItemDetails
|
|
25
26
|
"""
|
|
26
27
|
|
|
27
28
|
def __init__(self, workspace: "Workspace", details: ItemDetails, **kwargs):
|
|
@@ -31,16 +32,20 @@ class WorkspaceItem(abc.ABC):
|
|
|
31
32
|
|
|
32
33
|
@property
|
|
33
34
|
def workspace(self) -> "Workspace":
|
|
35
|
+
"""Workspace of the Workspace item"""
|
|
34
36
|
return self._workspace
|
|
35
37
|
|
|
36
38
|
@property
|
|
37
39
|
def details(self) -> Union[SessionDetails, JobDetails]:
|
|
40
|
+
"""Workspace item details"""
|
|
38
41
|
return self._details
|
|
39
42
|
|
|
40
43
|
@property
|
|
41
44
|
def id(self) -> str:
|
|
45
|
+
"""Id of the Workspace item"""
|
|
42
46
|
return self._details.id
|
|
43
47
|
|
|
44
48
|
@property
|
|
45
49
|
def item_type(self) -> ItemType:
|
|
50
|
+
"""Workspace item type"""
|
|
46
51
|
return self._item_type
|