supervisely 6.73.385__py3-none-any.whl → 6.73.386__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.
- supervisely/api/nn/deploy_api.py +13 -11
- {supervisely-6.73.385.dist-info → supervisely-6.73.386.dist-info}/METADATA +1 -1
- {supervisely-6.73.385.dist-info → supervisely-6.73.386.dist-info}/RECORD +7 -7
- {supervisely-6.73.385.dist-info → supervisely-6.73.386.dist-info}/LICENSE +0 -0
- {supervisely-6.73.385.dist-info → supervisely-6.73.386.dist-info}/WHEEL +0 -0
- {supervisely-6.73.385.dist-info → supervisely-6.73.386.dist-info}/entry_points.txt +0 -0
- {supervisely-6.73.385.dist-info → supervisely-6.73.386.dist-info}/top_level.txt +0 -0
supervisely/api/nn/deploy_api.py
CHANGED
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
from __future__ import annotations
|
|
5
5
|
|
|
6
|
+
import os
|
|
6
7
|
import time
|
|
7
8
|
from dataclasses import asdict
|
|
8
9
|
from pathlib import Path
|
|
@@ -708,16 +709,12 @@ class DeployApi:
|
|
|
708
709
|
)
|
|
709
710
|
|
|
710
711
|
runtime = get_runtime(runtime)
|
|
711
|
-
|
|
712
|
-
experiment_task_info = self._api.task.get_info_by_id(experiment_task_id)
|
|
713
|
-
if experiment_task_info is None:
|
|
714
|
-
raise ValueError(f"Task with ID '{experiment_task_id}' not found")
|
|
715
|
-
|
|
712
|
+
module = None
|
|
716
713
|
module_id = None
|
|
717
714
|
serve_app_name = None
|
|
718
715
|
if with_module:
|
|
719
|
-
|
|
720
|
-
module = self.
|
|
716
|
+
framework_name = experiment_info.framework_name
|
|
717
|
+
module = self.find_serving_app_by_framework(framework_name)
|
|
721
718
|
serve_app_name = module["name"]
|
|
722
719
|
module_id = module["id"]
|
|
723
720
|
logger.debug(f"Serving app detected: '{serve_app_name}'. Module ID: '{module_id}'")
|
|
@@ -768,10 +765,15 @@ class DeployApi:
|
|
|
768
765
|
"runtime": runtime,
|
|
769
766
|
}
|
|
770
767
|
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
768
|
+
for file_key, file_path in experiment_info.model_files.items():
|
|
769
|
+
full_file_path = os.path.join(experiment_info.artifacts_dir, file_path)
|
|
770
|
+
if not self._api.file.exists(team_id, full_file_path):
|
|
771
|
+
logger.debug(f"Model file not found: '{full_file_path}'. Trying to find it by checkpoint path.")
|
|
772
|
+
full_file_path = os.path.join(artifacts_dir, file_path)
|
|
773
|
+
if not self._api.file.exists(team_id, full_file_path):
|
|
774
|
+
raise ValueError(f"Model file not found: '{full_file_path}'. Make sure that the file exists in the artifacts directory.")
|
|
775
|
+
deploy_params["model_files"][file_key] = full_file_path
|
|
776
|
+
logger.debug(f"Model file added: {full_file_path}")
|
|
775
777
|
return module_id, serve_app_name, deploy_params
|
|
776
778
|
|
|
777
779
|
def _set_auto_runtime_by_checkpoint(self, checkpoint_path: str) -> str:
|
|
@@ -55,7 +55,7 @@ supervisely/api/entity_annotation/figure_api.py,sha256=rmsE3L_JfqN94sLN637pQ0syi
|
|
|
55
55
|
supervisely/api/entity_annotation/object_api.py,sha256=gbcNvN_KY6G80Me8fHKQgryc2Co7VU_kfFd1GYILZ4E,8875
|
|
56
56
|
supervisely/api/entity_annotation/tag_api.py,sha256=IapvSZmakjdOn0yvqP2tQRY8gkZg0bcvIZBwWRcafrg,18996
|
|
57
57
|
supervisely/api/nn/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
58
|
-
supervisely/api/nn/deploy_api.py,sha256=
|
|
58
|
+
supervisely/api/nn/deploy_api.py,sha256=yxTfi_B8KfKFxv410n4nt4OJiy18lJoZVScXnVCRYgA,37236
|
|
59
59
|
supervisely/api/nn/neural_network_api.py,sha256=VYqpHb6xqCeEUofTNfOGUhvjI_5Di3T26qwVp5Z-0hE,10643
|
|
60
60
|
supervisely/api/pointcloud/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
61
61
|
supervisely/api/pointcloud/pointcloud_annotation_api.py,sha256=xIXqCu0rKYsGt5ezh2EFT2utwsVrr2Xo-MOWUCnbvXc,11259
|
|
@@ -1103,9 +1103,9 @@ supervisely/worker_proto/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZ
|
|
|
1103
1103
|
supervisely/worker_proto/worker_api_pb2.py,sha256=VQfi5JRBHs2pFCK1snec3JECgGnua3Xjqw_-b3aFxuM,59142
|
|
1104
1104
|
supervisely/worker_proto/worker_api_pb2_grpc.py,sha256=3BwQXOaP9qpdi0Dt9EKG--Lm8KGN0C5AgmUfRv77_Jk,28940
|
|
1105
1105
|
supervisely_lib/__init__.py,sha256=7-3QnN8Zf0wj8NCr2oJmqoQWMKKPKTECvjH9pd2S5vY,159
|
|
1106
|
-
supervisely-6.73.
|
|
1107
|
-
supervisely-6.73.
|
|
1108
|
-
supervisely-6.73.
|
|
1109
|
-
supervisely-6.73.
|
|
1110
|
-
supervisely-6.73.
|
|
1111
|
-
supervisely-6.73.
|
|
1106
|
+
supervisely-6.73.386.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
|
1107
|
+
supervisely-6.73.386.dist-info/METADATA,sha256=pAcUu38hzyDhqOlzLArYsO0AzNHXluQ4MbM0UtAm1nk,35154
|
|
1108
|
+
supervisely-6.73.386.dist-info/WHEEL,sha256=iAkIy5fosb7FzIOwONchHf19Qu7_1wCWyFNR5gu9nU0,91
|
|
1109
|
+
supervisely-6.73.386.dist-info/entry_points.txt,sha256=U96-5Hxrp2ApRjnCoUiUhWMqijqh8zLR03sEhWtAcms,102
|
|
1110
|
+
supervisely-6.73.386.dist-info/top_level.txt,sha256=kcFVwb7SXtfqZifrZaSE3owHExX4gcNYe7Q2uoby084,28
|
|
1111
|
+
supervisely-6.73.386.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|