supervisely 6.73.414__py3-none-any.whl → 6.73.416__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/app/fastapi/subapp.py +2 -2
- supervisely/nn/model/model_api.py +4 -2
- {supervisely-6.73.414.dist-info → supervisely-6.73.416.dist-info}/METADATA +1 -1
- {supervisely-6.73.414.dist-info → supervisely-6.73.416.dist-info}/RECORD +8 -8
- {supervisely-6.73.414.dist-info → supervisely-6.73.416.dist-info}/LICENSE +0 -0
- {supervisely-6.73.414.dist-info → supervisely-6.73.416.dist-info}/WHEEL +0 -0
- {supervisely-6.73.414.dist-info → supervisely-6.73.416.dist-info}/entry_points.txt +0 -0
- {supervisely-6.73.414.dist-info → supervisely-6.73.416.dist-info}/top_level.txt +0 -0
|
@@ -82,7 +82,7 @@ class ResponseTimeFilter(logging.Filter):
|
|
|
82
82
|
if getattr(record, "name", "") == "uvicorn.access":
|
|
83
83
|
response_time = response_time_ctx.get(None)
|
|
84
84
|
if response_time is not None:
|
|
85
|
-
record.responseTime =
|
|
85
|
+
record.responseTime = int(response_time)
|
|
86
86
|
return True
|
|
87
87
|
|
|
88
88
|
|
|
@@ -849,7 +849,7 @@ def _init(
|
|
|
849
849
|
need_to_handle_error = is_production()
|
|
850
850
|
response = await process_server_error(request, exc, need_to_handle_error)
|
|
851
851
|
# Calculate response time and set it for uvicorn logger in ms
|
|
852
|
-
elapsed_ms = (time.perf_counter() - start_time) * 1000
|
|
852
|
+
elapsed_ms = round((time.perf_counter() - start_time) * 1000)
|
|
853
853
|
response_time_ctx.set(elapsed_ms)
|
|
854
854
|
return response
|
|
855
855
|
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
"""load and inference models"""
|
|
3
3
|
|
|
4
4
|
from __future__ import annotations
|
|
5
|
+
|
|
5
6
|
import os
|
|
6
7
|
from os import PathLike
|
|
7
8
|
from typing import List, Union
|
|
@@ -11,6 +12,7 @@ import requests
|
|
|
11
12
|
|
|
12
13
|
import supervisely.io.env as sly_env
|
|
13
14
|
import supervisely.io.json as sly_json
|
|
15
|
+
from supervisely.api.api import Api
|
|
14
16
|
from supervisely.api.module_api import ApiField
|
|
15
17
|
from supervisely.api.task_api import TaskApi
|
|
16
18
|
from supervisely.nn.experiments import ExperimentInfo
|
|
@@ -18,7 +20,6 @@ from supervisely.nn.model.prediction import Prediction
|
|
|
18
20
|
from supervisely.nn.model.prediction_session import PredictionSession
|
|
19
21
|
from supervisely.nn.utils import ModelSource
|
|
20
22
|
from supervisely.project.project_meta import ProjectMeta
|
|
21
|
-
from supervisely.api.api import Api
|
|
22
23
|
|
|
23
24
|
|
|
24
25
|
class ModelAPI:
|
|
@@ -126,7 +127,8 @@ class ModelAPI:
|
|
|
126
127
|
device: str = None,
|
|
127
128
|
runtime: str = None,
|
|
128
129
|
):
|
|
129
|
-
if self.
|
|
130
|
+
if self.task_id is None:
|
|
131
|
+
# TODO: proper check
|
|
130
132
|
if os.path.exists(model):
|
|
131
133
|
self._load_local_custom_model(model, device, runtime)
|
|
132
134
|
else:
|
|
@@ -99,7 +99,7 @@ supervisely/app/fastapi/index.html,sha256=dz_e-0RE5ZbOU0ToUaEHe1ROI6Tc3SPL-mHt1C
|
|
|
99
99
|
supervisely/app/fastapi/no_html_main.html,sha256=NhQP7noyORBx72lFh1CQKgBRupkWjiq6Gaw-9Hkvg7c,37
|
|
100
100
|
supervisely/app/fastapi/offline.py,sha256=CwMMkJ1frD6wiZS-SEoNDtQ1UJcJe1Ob6ohE3r4CQL8,7414
|
|
101
101
|
supervisely/app/fastapi/request.py,sha256=NU7rKmxJ1pfkDZ7_yHckRcRAueJRQIqCor11UO2OHr8,766
|
|
102
|
-
supervisely/app/fastapi/subapp.py,sha256=
|
|
102
|
+
supervisely/app/fastapi/subapp.py,sha256=GxMeYMy7lCkef8R_61F2XqxKjJjtyAk7CNDSCIc07ZY,50127
|
|
103
103
|
supervisely/app/fastapi/templating.py,sha256=pcghBW2OWVrNtplZuYa-mx04ektLiSvnBg-mhmyCoJc,2929
|
|
104
104
|
supervisely/app/fastapi/utils.py,sha256=t_UquzlFrdkKtAJmH6eJ279pE8Aa3BaIu4XjX-SEaIE,946
|
|
105
105
|
supervisely/app/fastapi/websocket.py,sha256=TlRSPOAhRItTv1HGvdukK1ZvhRjMUxRa-lJlsRR9rJw,1308
|
|
@@ -969,7 +969,7 @@ supervisely/nn/legacy/pytorch/weights.py,sha256=Zb9kcpUCg6ykr7seO53CkKSQa2K44wo8
|
|
|
969
969
|
supervisely/nn/legacy/training/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
970
970
|
supervisely/nn/legacy/training/eval_planner.py,sha256=zN9b0_CX7sWGdC8e6riTvD-NOUc3_Xduyhj00S7PEIo,1311
|
|
971
971
|
supervisely/nn/model/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
972
|
-
supervisely/nn/model/model_api.py,sha256=
|
|
972
|
+
supervisely/nn/model/model_api.py,sha256=jR1vCVHj70xbuYyYrpcBhUZYdnw8w5DsP_ZcQlo24qE,9945
|
|
973
973
|
supervisely/nn/model/prediction.py,sha256=N3oO9s3NDiC5CFvW8utfU8rz3bfpCl37Sk4VEBH94Bc,11307
|
|
974
974
|
supervisely/nn/model/prediction_session.py,sha256=sy0FSQaWSmT8i0RkR4J8oIn3Ek4IDVJNBR1Tg4mulkM,25523
|
|
975
975
|
supervisely/nn/tracker/__init__.py,sha256=LiojByb5kGsTQ49lWuboEh7B4JUwM1vfz81J8kJlLYo,337
|
|
@@ -1115,9 +1115,9 @@ supervisely/worker_proto/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZ
|
|
|
1115
1115
|
supervisely/worker_proto/worker_api_pb2.py,sha256=VQfi5JRBHs2pFCK1snec3JECgGnua3Xjqw_-b3aFxuM,59142
|
|
1116
1116
|
supervisely/worker_proto/worker_api_pb2_grpc.py,sha256=3BwQXOaP9qpdi0Dt9EKG--Lm8KGN0C5AgmUfRv77_Jk,28940
|
|
1117
1117
|
supervisely_lib/__init__.py,sha256=7-3QnN8Zf0wj8NCr2oJmqoQWMKKPKTECvjH9pd2S5vY,159
|
|
1118
|
-
supervisely-6.73.
|
|
1119
|
-
supervisely-6.73.
|
|
1120
|
-
supervisely-6.73.
|
|
1121
|
-
supervisely-6.73.
|
|
1122
|
-
supervisely-6.73.
|
|
1123
|
-
supervisely-6.73.
|
|
1118
|
+
supervisely-6.73.416.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
|
1119
|
+
supervisely-6.73.416.dist-info/METADATA,sha256=gbhnsm3ewbE-qIpKgVl161piBYh5d5izbnKa75VLDFQ,35254
|
|
1120
|
+
supervisely-6.73.416.dist-info/WHEEL,sha256=iAkIy5fosb7FzIOwONchHf19Qu7_1wCWyFNR5gu9nU0,91
|
|
1121
|
+
supervisely-6.73.416.dist-info/entry_points.txt,sha256=U96-5Hxrp2ApRjnCoUiUhWMqijqh8zLR03sEhWtAcms,102
|
|
1122
|
+
supervisely-6.73.416.dist-info/top_level.txt,sha256=kcFVwb7SXtfqZifrZaSE3owHExX4gcNYe7Q2uoby084,28
|
|
1123
|
+
supervisely-6.73.416.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|