Skip to content

Commit 5aae6de

Browse files
committed
python SDK release v0.3.0: changing minimum python version requirement from 3.9 to v3.7
1 parent 31ca937 commit 5aae6de

File tree

95 files changed

+3309
-3293
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

95 files changed

+3309
-3293
lines changed

PKG-INFO

+6-8
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,27 @@
11
Metadata-Version: 2.1
22
Name: tuneinsight
3-
Version: 0.2.1
3+
Version: 0.3.0
44
Summary: Diapason is the official Python SDK for the Tune Insight Agent API
55
License: Apache-2.0
66
Author: Tune Insight SA
7-
Requires-Python: >=3.9,<3.11
7+
Requires-Python: >=3.7.1,<3.11
88
Classifier: License :: OSI Approved :: Apache Software License
99
Classifier: Programming Language :: Python :: 3
10+
Classifier: Programming Language :: Python :: 3.8
1011
Classifier: Programming Language :: Python :: 3.9
1112
Classifier: Programming Language :: Python :: 3.10
1213
Requires-Dist: PyYAML (>=6.0,<7.0)
1314
Requires-Dist: attrs (>=21.3.0)
1415
Requires-Dist: docker (>=6.0.1,<7.0.0)
1516
Requires-Dist: httpx (>=0.15.4,<0.24.0)
16-
Requires-Dist: matplotlib (>=3.6.0,<4.0.0)
17+
Requires-Dist: matplotlib (>=3.5.0,<4.0.0)
1718
Requires-Dist: notebook (>=6.4.11,<7.0.0)
18-
Requires-Dist: pandas (>=1.4.2,<2.0.0)
19-
Requires-Dist: pylint (>=2.15.2,<3.0.0)
19+
Requires-Dist: pandas (>=1.3.5,<2.0.0)
20+
Requires-Dist: pylint (>=2.13.2,<3.0.0)
2021
Requires-Dist: python-dateutil (>=2.8.0,<3.0.0)
2122
Requires-Dist: python-dotenv (>=0.21.0,<0.22.0)
2223
Requires-Dist: python-keycloak (>=0.27.0,<0.28.0)
2324
Requires-Dist: pyvcf3 (>=1.0.3,<2.0.0)
24-
Requires-Dist: scikit-learn (>=1.1.3,<2.0.0)
25-
Requires-Dist: scipy (>=1.9.3,<2.0.0)
26-
Requires-Dist: seaborn (>=0.12.1,<0.13.0)
2725
Requires-Dist: wheel (>=0.37.1,<0.38.0)
2826
Description-Content-Type: text/markdown
2927

pyproject.toml

+9-12
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,32 @@
11
[tool.poetry]
22
name = "tuneinsight"
3-
version = "0.2.1"
3+
version = "0.3.0"
44
description = "Diapason is the official Python SDK for the Tune Insight Agent API"
55
authors = ["Tune Insight SA"]
66
license = "Apache-2.0"
77
include = ["src/tuneinsight/api/**/*.py"]
88
readme = "src/tuneinsight/README.md"
99

1010
[tool.poetry.dependencies]
11-
python = ">= 3.9, < 3.11"
11+
python = ">= 3.7.1, < 3.11"
1212
python-keycloak = "^0.27.0"
13+
pandas = "^1.3.5"
1314
PyYAML = "^6.0"
14-
pandas = "^1.4.2"
15-
matplotlib = "^3.6.0"
1615
#cloudpickle = "^2.0.0" // TODO: to add in the future to run python on backend
17-
scikit-learn = "^1.1.3"
1816
wheel = "^0.37.1"
19-
pylint = "^2.15.2"
17+
pylint = "^2.13.2"
2018
docker = "^6.0.1"
21-
seaborn = "^0.12.1"
2219
notebook = "^6.4.11"
20+
python-dotenv = "^0.21.0"
21+
pyvcf3 = "^1.0.3"
22+
python-dateutil = "^2.8.0"
23+
matplotlib = "^3.5.0"
2324

2425
# Required by ge_co_rest_api
2526
httpx = ">=0.15.4,<0.24.0"
2627
attrs = ">=21.3.0"
27-
python-dateutil = "^2.8.0"
28-
python-dotenv = "^0.21.0"
29-
pyvcf3 = "^1.0.3"
30-
scipy = "^1.9.3"
3128

3229

3330
[build-system]
3431
requires = ["poetry-core>=1.0.0"]
35-
build-backend = "poetry.core.masonry.api"
32+
build-backend = "poetry.core.masonry.api"

src/tuneinsight/api/sdk/models/aggregated_dataset_length.py

+79-79
Original file line numberDiff line numberDiff line change
@@ -20,77 +20,77 @@ class AggregatedDatasetLength:
2020
"""
2121
Attributes:
2222
type (ComputationType): Type of the computation.
23+
encrypted (Union[Unset, bool]): True if computation result should be encrypted with the collective public key.
24+
local_input_id (Union[Unset, str]): Unique identifier of a data object.
25+
project_id (Union[Unset, str]): Unique identifier of a project.
2326
dp_policy (Union[Unset, DPPolicy]): represents the disclosure prevention policy that enables toggling various
2427
disclosure prevention mechanisms
2528
cohort_id (Union[Unset, str]): Unique identifier of a data object.
29+
wait (Union[Unset, bool]): Whether to wait synchronously for the computation result.
30+
preprocessing_parameters (Union[Unset, ComputationPreprocessingParameters]): dataframe pre-processing parameters
31+
applied to the input retrieved from the datasource, if applicable
32+
timeout (Union[Unset, int]): The maximum amount of time in seconds the computation is allowed to run.
33+
owner (Union[Unset, str]): The username of the user who started the computation.
2634
data_source_parameters (Union[Unset, ComputationDataSourceParameters]): Parameters used to query the datasource
2735
from each node before the computation
28-
encrypted (Union[Unset, bool]): True if computation result should be encrypted with the collective public key.
29-
input_data_object (Union[Unset, str]): Shared identifier of a data object.
30-
join_id (Union[Unset, str]): Unique identifier of a data object.
3136
local (Union[Unset, bool]): True if the project's computation should run only with local data (not configured
3237
the network)
3338
local_input (Union[Unset, LocalInput]): If a local input is provided, the node initiating the computation will
3439
use it instead of querying the datasource. This data is *not* shared to other nodes, only used for the duration
3540
of the computation. The local input columns/values must be in the form {<column1>: [<value1>, <value2>, ...],
3641
...}
37-
local_input_id (Union[Unset, str]): Unique identifier of a data object.
38-
owner (Union[Unset, str]): The username of the user who started the computation.
39-
preprocessing_parameters (Union[Unset, ComputationPreprocessingParameters]): dataframe pre-processing parameters
40-
applied to the input retrieved from the datasource, if applicable
41-
project_id (Union[Unset, str]): Unique identifier of a project.
42-
timeout (Union[Unset, int]): The maximum amount of time in seconds the computation is allowed to run.
43-
wait (Union[Unset, bool]): Whether to wait synchronously for the computation result.
42+
input_data_object (Union[Unset, str]): Shared identifier of a data object.
43+
join_id (Union[Unset, str]): Unique identifier of a data object.
4444
features (Union[Unset, str]): Shared identifier of a data object.
4545
"""
4646

4747
type: ComputationType
48+
encrypted: Union[Unset, bool] = UNSET
49+
local_input_id: Union[Unset, str] = UNSET
50+
project_id: Union[Unset, str] = UNSET
4851
dp_policy: Union[Unset, "DPPolicy"] = UNSET
4952
cohort_id: Union[Unset, str] = UNSET
53+
wait: Union[Unset, bool] = UNSET
54+
preprocessing_parameters: Union[Unset, "ComputationPreprocessingParameters"] = UNSET
55+
timeout: Union[Unset, int] = UNSET
56+
owner: Union[Unset, str] = UNSET
5057
data_source_parameters: Union[Unset, "ComputationDataSourceParameters"] = UNSET
51-
encrypted: Union[Unset, bool] = UNSET
52-
input_data_object: Union[Unset, str] = UNSET
53-
join_id: Union[Unset, str] = UNSET
5458
local: Union[Unset, bool] = UNSET
5559
local_input: Union[Unset, "LocalInput"] = UNSET
56-
local_input_id: Union[Unset, str] = UNSET
57-
owner: Union[Unset, str] = UNSET
58-
preprocessing_parameters: Union[Unset, "ComputationPreprocessingParameters"] = UNSET
59-
project_id: Union[Unset, str] = UNSET
60-
timeout: Union[Unset, int] = UNSET
61-
wait: Union[Unset, bool] = UNSET
60+
input_data_object: Union[Unset, str] = UNSET
61+
join_id: Union[Unset, str] = UNSET
6262
features: Union[Unset, str] = UNSET
6363
additional_properties: Dict[str, Any] = attr.ib(init=False, factory=dict)
6464

6565
def to_dict(self) -> Dict[str, Any]:
6666
type = self.type.value
6767

68+
encrypted = self.encrypted
69+
local_input_id = self.local_input_id
70+
project_id = self.project_id
6871
dp_policy: Union[Unset, Dict[str, Any]] = UNSET
6972
if not isinstance(self.dp_policy, Unset):
7073
dp_policy = self.dp_policy.to_dict()
7174

7275
cohort_id = self.cohort_id
76+
wait = self.wait
77+
preprocessing_parameters: Union[Unset, Dict[str, Any]] = UNSET
78+
if not isinstance(self.preprocessing_parameters, Unset):
79+
preprocessing_parameters = self.preprocessing_parameters.to_dict()
80+
81+
timeout = self.timeout
82+
owner = self.owner
7383
data_source_parameters: Union[Unset, Dict[str, Any]] = UNSET
7484
if not isinstance(self.data_source_parameters, Unset):
7585
data_source_parameters = self.data_source_parameters.to_dict()
7686

77-
encrypted = self.encrypted
78-
input_data_object = self.input_data_object
79-
join_id = self.join_id
8087
local = self.local
8188
local_input: Union[Unset, Dict[str, Any]] = UNSET
8289
if not isinstance(self.local_input, Unset):
8390
local_input = self.local_input.to_dict()
8491

85-
local_input_id = self.local_input_id
86-
owner = self.owner
87-
preprocessing_parameters: Union[Unset, Dict[str, Any]] = UNSET
88-
if not isinstance(self.preprocessing_parameters, Unset):
89-
preprocessing_parameters = self.preprocessing_parameters.to_dict()
90-
91-
project_id = self.project_id
92-
timeout = self.timeout
93-
wait = self.wait
92+
input_data_object = self.input_data_object
93+
join_id = self.join_id
9494
features = self.features
9595

9696
field_dict: Dict[str, Any] = {}
@@ -100,34 +100,34 @@ def to_dict(self) -> Dict[str, Any]:
100100
"type": type,
101101
}
102102
)
103+
if encrypted is not UNSET:
104+
field_dict["encrypted"] = encrypted
105+
if local_input_id is not UNSET:
106+
field_dict["localInputID"] = local_input_id
107+
if project_id is not UNSET:
108+
field_dict["projectId"] = project_id
103109
if dp_policy is not UNSET:
104110
field_dict["DPPolicy"] = dp_policy
105111
if cohort_id is not UNSET:
106112
field_dict["cohortId"] = cohort_id
113+
if wait is not UNSET:
114+
field_dict["wait"] = wait
115+
if preprocessing_parameters is not UNSET:
116+
field_dict["preprocessingParameters"] = preprocessing_parameters
117+
if timeout is not UNSET:
118+
field_dict["timeout"] = timeout
119+
if owner is not UNSET:
120+
field_dict["owner"] = owner
107121
if data_source_parameters is not UNSET:
108122
field_dict["dataSourceParameters"] = data_source_parameters
109-
if encrypted is not UNSET:
110-
field_dict["encrypted"] = encrypted
111-
if input_data_object is not UNSET:
112-
field_dict["inputDataObject"] = input_data_object
113-
if join_id is not UNSET:
114-
field_dict["joinId"] = join_id
115123
if local is not UNSET:
116124
field_dict["local"] = local
117125
if local_input is not UNSET:
118126
field_dict["localInput"] = local_input
119-
if local_input_id is not UNSET:
120-
field_dict["localInputID"] = local_input_id
121-
if owner is not UNSET:
122-
field_dict["owner"] = owner
123-
if preprocessing_parameters is not UNSET:
124-
field_dict["preprocessingParameters"] = preprocessing_parameters
125-
if project_id is not UNSET:
126-
field_dict["projectId"] = project_id
127-
if timeout is not UNSET:
128-
field_dict["timeout"] = timeout
129-
if wait is not UNSET:
130-
field_dict["wait"] = wait
127+
if input_data_object is not UNSET:
128+
field_dict["inputDataObject"] = input_data_object
129+
if join_id is not UNSET:
130+
field_dict["joinId"] = join_id
131131
if features is not UNSET:
132132
field_dict["features"] = features
133133

@@ -143,6 +143,12 @@ def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
143143
d = src_dict.copy()
144144
type = ComputationType(d.pop("type"))
145145

146+
encrypted = d.pop("encrypted", UNSET)
147+
148+
local_input_id = d.pop("localInputID", UNSET)
149+
150+
project_id = d.pop("projectId", UNSET)
151+
146152
_dp_policy = d.pop("DPPolicy", UNSET)
147153
dp_policy: Union[Unset, DPPolicy]
148154
if isinstance(_dp_policy, Unset):
@@ -152,19 +158,26 @@ def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
152158

153159
cohort_id = d.pop("cohortId", UNSET)
154160

161+
wait = d.pop("wait", UNSET)
162+
163+
_preprocessing_parameters = d.pop("preprocessingParameters", UNSET)
164+
preprocessing_parameters: Union[Unset, ComputationPreprocessingParameters]
165+
if isinstance(_preprocessing_parameters, Unset):
166+
preprocessing_parameters = UNSET
167+
else:
168+
preprocessing_parameters = ComputationPreprocessingParameters.from_dict(_preprocessing_parameters)
169+
170+
timeout = d.pop("timeout", UNSET)
171+
172+
owner = d.pop("owner", UNSET)
173+
155174
_data_source_parameters = d.pop("dataSourceParameters", UNSET)
156175
data_source_parameters: Union[Unset, ComputationDataSourceParameters]
157176
if isinstance(_data_source_parameters, Unset):
158177
data_source_parameters = UNSET
159178
else:
160179
data_source_parameters = ComputationDataSourceParameters.from_dict(_data_source_parameters)
161180

162-
encrypted = d.pop("encrypted", UNSET)
163-
164-
input_data_object = d.pop("inputDataObject", UNSET)
165-
166-
join_id = d.pop("joinId", UNSET)
167-
168181
local = d.pop("local", UNSET)
169182

170183
_local_input = d.pop("localInput", UNSET)
@@ -174,41 +187,28 @@ def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
174187
else:
175188
local_input = LocalInput.from_dict(_local_input)
176189

177-
local_input_id = d.pop("localInputID", UNSET)
178-
179-
owner = d.pop("owner", UNSET)
180-
181-
_preprocessing_parameters = d.pop("preprocessingParameters", UNSET)
182-
preprocessing_parameters: Union[Unset, ComputationPreprocessingParameters]
183-
if isinstance(_preprocessing_parameters, Unset):
184-
preprocessing_parameters = UNSET
185-
else:
186-
preprocessing_parameters = ComputationPreprocessingParameters.from_dict(_preprocessing_parameters)
187-
188-
project_id = d.pop("projectId", UNSET)
189-
190-
timeout = d.pop("timeout", UNSET)
190+
input_data_object = d.pop("inputDataObject", UNSET)
191191

192-
wait = d.pop("wait", UNSET)
192+
join_id = d.pop("joinId", UNSET)
193193

194194
features = d.pop("features", UNSET)
195195

196196
aggregated_dataset_length = cls(
197197
type=type,
198+
encrypted=encrypted,
199+
local_input_id=local_input_id,
200+
project_id=project_id,
198201
dp_policy=dp_policy,
199202
cohort_id=cohort_id,
203+
wait=wait,
204+
preprocessing_parameters=preprocessing_parameters,
205+
timeout=timeout,
206+
owner=owner,
200207
data_source_parameters=data_source_parameters,
201-
encrypted=encrypted,
202-
input_data_object=input_data_object,
203-
join_id=join_id,
204208
local=local,
205209
local_input=local_input,
206-
local_input_id=local_input_id,
207-
owner=owner,
208-
preprocessing_parameters=preprocessing_parameters,
209-
project_id=project_id,
210-
timeout=timeout,
211-
wait=wait,
210+
input_data_object=input_data_object,
211+
join_id=join_id,
212212
features=features,
213213
)
214214

0 commit comments

Comments
 (0)