eotdl 2025.4.22__py3-none-any.whl → 2025.4.22.post2__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.
- eotdl/__init__.py +1 -1
- eotdl/commands/datasets.py +11 -0
- eotdl/commands/models.py +12 -0
- eotdl/commands/stac.py +2 -2
- eotdl/curation/stac/api.py +2 -2
- eotdl/datasets/__init__.py +1 -0
- eotdl/datasets/update.py +8 -0
- eotdl/models/__init__.py +1 -0
- eotdl/models/update.py +7 -0
- eotdl/repos/APIRepo.py +2 -2
- eotdl/repos/DatasetsAPIRepo.py +6 -0
- eotdl/repos/ModelsAPIRepo.py +5 -1
- eotdl/repos/STACAPIRepo.py +2 -2
- {eotdl-2025.4.22.dist-info → eotdl-2025.4.22.post2.dist-info}/METADATA +1 -1
- {eotdl-2025.4.22.dist-info → eotdl-2025.4.22.post2.dist-info}/RECORD +17 -17
- {eotdl-2025.4.22.dist-info → eotdl-2025.4.22.post2.dist-info}/WHEEL +0 -0
- {eotdl-2025.4.22.dist-info → eotdl-2025.4.22.post2.dist-info}/entry_points.txt +0 -0
eotdl/__init__.py
CHANGED
@@ -1 +1 @@
|
|
1
|
-
__version__ = "2025.04.22"
|
1
|
+
__version__ = "2025.04.22-2"
|
eotdl/commands/datasets.py
CHANGED
@@ -5,6 +5,7 @@ from ..datasets import (
|
|
5
5
|
retrieve_datasets,
|
6
6
|
ingest_dataset,
|
7
7
|
stage_dataset,
|
8
|
+
deactivate_dataset,
|
8
9
|
)
|
9
10
|
|
10
11
|
app = typer.Typer(help="Explore, ingest and download training datasets.")
|
@@ -141,5 +142,15 @@ def get(
|
|
141
142
|
typer.echo(e)
|
142
143
|
|
143
144
|
|
145
|
+
@app.command()
|
146
|
+
def deactivate(
|
147
|
+
dataset_id: str = typer.Argument(None, help="ID of the dataset to deactivate")
|
148
|
+
):
|
149
|
+
try:
|
150
|
+
deactivate_dataset(dataset_id)
|
151
|
+
typer.echo(f"Dataset {dataset_id} deactivated")
|
152
|
+
except Exception as e:
|
153
|
+
typer.echo(e)
|
154
|
+
|
144
155
|
if __name__ == "__main__":
|
145
156
|
app()
|
eotdl/commands/models.py
CHANGED
@@ -5,6 +5,7 @@ from ..models import (
|
|
5
5
|
retrieve_models,
|
6
6
|
ingest_model,
|
7
7
|
stage_model,
|
8
|
+
deactivate_model
|
8
9
|
)
|
9
10
|
|
10
11
|
app = typer.Typer(help="Explore, ingest and download ML models.")
|
@@ -132,5 +133,16 @@ def get(
|
|
132
133
|
typer.echo(e)
|
133
134
|
|
134
135
|
|
136
|
+
@app.command()
|
137
|
+
def deactivate(
|
138
|
+
model_id: str = typer.Argument(None, help="ID of the model to deactivate")
|
139
|
+
):
|
140
|
+
try:
|
141
|
+
deactivate_model(model_id)
|
142
|
+
typer.echo(f"Model {model_id} deactivated")
|
143
|
+
except Exception as e:
|
144
|
+
typer.echo(e)
|
145
|
+
|
146
|
+
|
135
147
|
if __name__ == "__main__":
|
136
148
|
app()
|
eotdl/commands/stac.py
CHANGED
@@ -24,9 +24,9 @@ def collections():
|
|
24
24
|
raise typer.Abort()
|
25
25
|
|
26
26
|
@app.command()
|
27
|
-
def collection(
|
27
|
+
def collection(collection_name: str):
|
28
28
|
try:
|
29
|
-
data = retrieve_stac_collection(
|
29
|
+
data = retrieve_stac_collection(collection_name)
|
30
30
|
typer.echo(data)
|
31
31
|
except Exception as e:
|
32
32
|
typer.echo(e)
|
eotdl/curation/stac/api.py
CHANGED
@@ -16,9 +16,9 @@ def retrieve_stac_collections():
|
|
16
16
|
raise Exception(error)
|
17
17
|
return data
|
18
18
|
|
19
|
-
def retrieve_stac_collection(
|
19
|
+
def retrieve_stac_collection(collection_name):
|
20
20
|
repo = STACAPIRepo()
|
21
|
-
data, error = repo.collection(
|
21
|
+
data, error = repo.collection(collection_name)
|
22
22
|
if error:
|
23
23
|
raise Exception(error)
|
24
24
|
return data
|
eotdl/datasets/__init__.py
CHANGED
eotdl/datasets/update.py
CHANGED
@@ -15,3 +15,11 @@ def update_dataset(dataset_id, metadata, content, user):
|
|
15
15
|
if error:
|
16
16
|
raise Exception(error)
|
17
17
|
return data
|
18
|
+
|
19
|
+
|
20
|
+
def deactivate_dataset(dataset_id):
|
21
|
+
repo = DatasetsAPIRepo()
|
22
|
+
data, error = repo.deactivate_dataset(dataset_id)
|
23
|
+
if error:
|
24
|
+
raise Exception(error)
|
25
|
+
return data
|
eotdl/models/__init__.py
CHANGED
eotdl/models/update.py
CHANGED
@@ -15,3 +15,10 @@ def update_model(model_id, metadata, content, user):
|
|
15
15
|
if error:
|
16
16
|
raise Exception(error)
|
17
17
|
return data
|
18
|
+
|
19
|
+
def deactivate_model(model_id):
|
20
|
+
repo = ModelsAPIRepo()
|
21
|
+
data, error = repo.deactivate_model(model_id)
|
22
|
+
if error:
|
23
|
+
raise Exception(error)
|
24
|
+
return data
|
eotdl/repos/APIRepo.py
CHANGED
@@ -4,8 +4,8 @@ import requests
|
|
4
4
|
|
5
5
|
class APIRepo:
|
6
6
|
def __init__(self, url=None):
|
7
|
-
default_url = "https://api.eotdl.com/"
|
8
|
-
|
7
|
+
# default_url = "https://api.eotdl.com/"
|
8
|
+
default_url = "http://localhost:8000/"
|
9
9
|
self.url = url if url else os.getenv("EOTDL_API_URL", default_url)
|
10
10
|
|
11
11
|
def format_response(self, response):
|
eotdl/repos/DatasetsAPIRepo.py
CHANGED
@@ -41,3 +41,9 @@ class DatasetsAPIRepo(APIRepo):
|
|
41
41
|
headers=self.generate_headers(user),
|
42
42
|
)
|
43
43
|
return self.format_response(response)
|
44
|
+
|
45
|
+
def deactivate_dataset(self, dataset_name):
|
46
|
+
response = requests.patch(
|
47
|
+
self.url + "datasets/deactivate/" + dataset_name
|
48
|
+
)
|
49
|
+
return self.format_response(response)
|
eotdl/repos/ModelsAPIRepo.py
CHANGED
eotdl/repos/STACAPIRepo.py
CHANGED
@@ -15,8 +15,8 @@ class STACAPIRepo(APIRepo):
|
|
15
15
|
response = requests.get(self.url + "stac/collections")
|
16
16
|
return self.format_response(response)
|
17
17
|
|
18
|
-
def collection(self,
|
19
|
-
response = requests.get(self.url + f"stac/collections/{
|
18
|
+
def collection(self, collection_name):
|
19
|
+
response = requests.get(self.url + f"stac/collections/{collection_name}")
|
20
20
|
return self.format_response(response)
|
21
21
|
|
22
22
|
def items(self, collection_id):
|
@@ -1,4 +1,4 @@
|
|
1
|
-
eotdl/__init__.py,sha256
|
1
|
+
eotdl/__init__.py,sha256=-O7BvxY9Mzl3TA3wOKD1uu7C0__yrYkBF7J9kAF4jts,29
|
2
2
|
eotdl/cli.py,sha256=BAI3HuDf1WohaWeA5y1bUJMABDkqmfttOCa7FY5P3Hk,701
|
3
3
|
eotdl/access/__init__.py,sha256=k-zmTwB6VLoWt_AsXx9CnEKdtONBZAaC8T6vqPMPSjk,436
|
4
4
|
eotdl/access/download.py,sha256=e5H8LUkCfIVkFxJFM5EwCMG-R5DHVSHDGLvuNM5DNc8,2815
|
@@ -19,35 +19,35 @@ eotdl/auth/is_logged.py,sha256=QREuhkoDnarZoUZwCxVCNoESGb_Yukh0lJo1pXvrV9Q,115
|
|
19
19
|
eotdl/auth/logout.py,sha256=P_Sp6WmVvnG3R9V1L9541KNyHFko9DtQPqAKD2vaguw,161
|
20
20
|
eotdl/commands/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
21
21
|
eotdl/commands/auth.py,sha256=WzA0aFGRoscy7fPKQTxiphBc0LJztJxBBl7rjDBRVfI,1544
|
22
|
-
eotdl/commands/datasets.py,sha256=
|
23
|
-
eotdl/commands/models.py,sha256=
|
24
|
-
eotdl/commands/stac.py,sha256=
|
22
|
+
eotdl/commands/datasets.py,sha256=gE9CcHq4KyMsBhj28j1TfkLsMVG2CPBqvAANqAvxn0Y,5503
|
23
|
+
eotdl/commands/models.py,sha256=iXy9XNgrYvi0_vZamDFbF69OQ-ApxSTCxmKeIvp9Q0g,5145
|
24
|
+
eotdl/commands/stac.py,sha256=jgjjkGw9tIvuovyAwfEu6B4ZMoMvEj5lrj_lO-9IqrE,1444
|
25
25
|
eotdl/curation/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
26
26
|
eotdl/curation/stac/__init__.py,sha256=FMi-qzd6v1sdsqZsBRRnedccaJFXJGCPCH3uTctyLYU,37
|
27
|
-
eotdl/curation/stac/api.py,sha256=
|
27
|
+
eotdl/curation/stac/api.py,sha256=5XW9yzSxiuML70bBbzJ0DGx0GmplmhYtgeGZg029Qjk,1428
|
28
28
|
eotdl/curation/stac/stac.py,sha256=4f7xrh2CcXTkTs3or1UMVxiFfwtVfTqH4YwTGsbi6No,1013
|
29
|
-
eotdl/datasets/__init__.py,sha256=
|
29
|
+
eotdl/datasets/__init__.py,sha256=g2WBJa_EVVXtktxqZRJEAQPHADU0qVaLkjDYZnojDgc,256
|
30
30
|
eotdl/datasets/ingest.py,sha256=7LI4eENRxhGDjgfAlgLqTY96jiX5iRB0_SlU63NboOM,1414
|
31
31
|
eotdl/datasets/retrieve.py,sha256=dhNbBJu0vE0l-LsGQNQF5Vc_WzZDRbXPzvd66GNlV6U,691
|
32
32
|
eotdl/datasets/stage.py,sha256=pcU1AsjbczzMHdhCxjKfCuuuLo1OZMMWNAUqj-3SxKc,2162
|
33
|
-
eotdl/datasets/update.py,sha256=
|
33
|
+
eotdl/datasets/update.py,sha256=pHHutyGf0ALTuGmq2TYSyJ3VaLmY0WMNgHw_pKUn2zI,567
|
34
34
|
eotdl/files/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
35
35
|
eotdl/files/ingest.bck,sha256=dgjZfd-ACCKradDo2B02CPahwEhFtWvnKvTm372K5eo,6185
|
36
36
|
eotdl/files/ingest.py,sha256=mepe-RmweWaM_4fUZjyGWpwjrg6EIlc_B7GwxRR7Br4,9379
|
37
37
|
eotdl/files/metadata.py,sha256=C-NDr-zjM58fP8QcHB1N1QyLRUeYyMbT6wPPnxGk8LI,1370
|
38
|
-
eotdl/models/__init__.py,sha256=
|
38
|
+
eotdl/models/__init__.py,sha256=b6t1Z377On1F56c-GSy7FM_nBWRLHh1Ph2R24rPFiVY,239
|
39
39
|
eotdl/models/download.py,sha256=rRT3fG-qS3-SXfzFdqy0cuiDnOIV9Du74JCnsbbA9Ps,3475
|
40
40
|
eotdl/models/ingest.py,sha256=xpDoY4Tn0y94bIDXgk2No6fGLydPbKYcc9NsPj-yFms,1372
|
41
41
|
eotdl/models/retrieve.py,sha256=-Ij7dT4J1p7MW4n13OlPB9OW4tBaBXPwk9dW8IuCZPc,664
|
42
42
|
eotdl/models/stage.py,sha256=rvWN8vcBz7qHhu0TzJ90atw1kEr3JPKF0k2S-Sv-JVs,1944
|
43
|
-
eotdl/models/update.py,sha256=
|
44
|
-
eotdl/repos/APIRepo.py,sha256=
|
43
|
+
eotdl/models/update.py,sha256=0N6S_n_DXWaS2A56lHjukBgLLZDxygB8jN2WfZyJwaQ,545
|
44
|
+
eotdl/repos/APIRepo.py,sha256=s9w29Cnk5Pu4NvjyHAfcpM69a2lODICJ-Gn_iosxsPg,791
|
45
45
|
eotdl/repos/AuthAPIRepo.py,sha256=vYCqFawe3xUm2cx4SqVXCvzl8J_sr9rs_MkipYC0bXE,957
|
46
46
|
eotdl/repos/AuthRepo.py,sha256=jpzzhINCcDZHRCyrPDsp49h17IlXp2HvX3BB3f5cnb4,1154
|
47
|
-
eotdl/repos/DatasetsAPIRepo.py,sha256=
|
47
|
+
eotdl/repos/DatasetsAPIRepo.py,sha256=Wx8xkQHT53h7AZATNSCLaDmkHYMoSGDVoyo_beqpgGo,1639
|
48
48
|
eotdl/repos/FilesAPIRepo.py,sha256=PNNS5LGxksZpkg-49_r3r2H0iQWkCeb7iiL6j-S4wLY,4757
|
49
|
-
eotdl/repos/ModelsAPIRepo.py,sha256=
|
50
|
-
eotdl/repos/STACAPIRepo.py,sha256=
|
49
|
+
eotdl/repos/ModelsAPIRepo.py,sha256=i2T1mJwlWu2mpexUVOE9ha5JRyHdf6_6n36TraL3-BU,1438
|
50
|
+
eotdl/repos/STACAPIRepo.py,sha256=GJIrLkgVB-donToJlgOmaJbxDmXzIuwlmCb9R2yoRIA,1387
|
51
51
|
eotdl/repos/__init__.py,sha256=GIzk62681dvNzYgVzvJgrMzVRhrep4-kJH6lTOtfnT8,258
|
52
52
|
eotdl/shared/__init__.py,sha256=mF7doJC8Z5eTPmB01UQvPivThZac32DRY33T6qshXfg,41
|
53
53
|
eotdl/shared/checksum.py,sha256=4IB6N9jRO0chMDNJzpdnFDhC9wcFF9bO5oHq2HodcHw,479
|
@@ -60,7 +60,7 @@ eotdl/tools/time_utils.py,sha256=JHrQ3PxXkhwor8zcOFccf26zOG9WBtb9xHb6j-Fqa9k,466
|
|
60
60
|
eotdl/tools/tools.py,sha256=Tl4_v2ejkQo_zyZek8oofJwoYcdVosdOwW1C0lvWaNM,6354
|
61
61
|
eotdl/wrappers/__init__.py,sha256=IY3DK_5LMbc5bIQFleQA9kzFbPhWuTLesJ8dwfvpkdA,32
|
62
62
|
eotdl/wrappers/models.py,sha256=kNO4pYw9KKKmElE7bZWWHGs7FIThNUXj8XciKh_3rNw,6432
|
63
|
-
eotdl-2025.4.22.dist-info/METADATA,sha256=
|
64
|
-
eotdl-2025.4.22.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
65
|
-
eotdl-2025.4.22.dist-info/entry_points.txt,sha256=FV4dFIZ5zdWj1q1nUEEip29n3sAgbviVOizEz00gEF0,40
|
66
|
-
eotdl-2025.4.22.dist-info/RECORD,,
|
63
|
+
eotdl-2025.4.22.post2.dist-info/METADATA,sha256=CB8WifWJtYRbDtitqT85iGfIiEe0VD52Mh2EYqHNsq0,3371
|
64
|
+
eotdl-2025.4.22.post2.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
65
|
+
eotdl-2025.4.22.post2.dist-info/entry_points.txt,sha256=FV4dFIZ5zdWj1q1nUEEip29n3sAgbviVOizEz00gEF0,40
|
66
|
+
eotdl-2025.4.22.post2.dist-info/RECORD,,
|
File without changes
|
File without changes
|