matrice-analytics 0.1.41__py3-none-any.whl → 0.1.42__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.
Potentially problematic release.
This version of matrice-analytics might be problematic. Click here for more details.
- matrice_analytics/post_processing/usecases/color/clip.py +27 -10
- {matrice_analytics-0.1.41.dist-info → matrice_analytics-0.1.42.dist-info}/METADATA +1 -1
- {matrice_analytics-0.1.41.dist-info → matrice_analytics-0.1.42.dist-info}/RECORD +6 -6
- {matrice_analytics-0.1.41.dist-info → matrice_analytics-0.1.42.dist-info}/WHEEL +0 -0
- {matrice_analytics-0.1.41.dist-info → matrice_analytics-0.1.42.dist-info}/licenses/LICENSE.txt +0 -0
- {matrice_analytics-0.1.41.dist-info → matrice_analytics-0.1.42.dist-info}/top_level.txt +0 -0
|
@@ -247,15 +247,26 @@ def load_model_from_checkpoint(checkpoint_url: str, providers: Optional[List] =
|
|
|
247
247
|
# Resolve providers
|
|
248
248
|
available = ort.get_available_providers()
|
|
249
249
|
print("Available providers:", available)
|
|
250
|
-
use_providers = ["CUDAExecutionProvider"] #providers or
|
|
251
250
|
|
|
252
|
-
#
|
|
253
|
-
if
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
251
|
+
# Use provided providers or default to CUDA if available, else use first available
|
|
252
|
+
if providers is None:
|
|
253
|
+
if "CUDAExecutionProvider" in available:
|
|
254
|
+
use_providers = ["CUDAExecutionProvider"]
|
|
255
|
+
elif available:
|
|
256
|
+
use_providers = [available[0]]
|
|
257
|
+
print(f"CUDA not available, using: {use_providers[0]}")
|
|
258
|
+
else:
|
|
259
|
+
use_providers = ["CPUExecutionProvider"]
|
|
260
|
+
print("No providers detected, using CPUExecutionProvider")
|
|
261
|
+
else:
|
|
262
|
+
use_providers = providers
|
|
263
|
+
|
|
264
|
+
# Warn if requested provider is not available
|
|
265
|
+
for provider in use_providers:
|
|
266
|
+
provider_name = provider[0] if isinstance(provider, tuple) else provider
|
|
267
|
+
if provider_name not in available:
|
|
268
|
+
print(f"Warning: Requested provider '{provider_name}' not in available providers: {available}")
|
|
269
|
+
print(f"Will attempt to use it anyway, may fall back to available providers")
|
|
259
270
|
|
|
260
271
|
# Load ONNX model from bytes with enforced providers
|
|
261
272
|
model = ort.InferenceSession(
|
|
@@ -330,8 +341,14 @@ class ClipProcessor:
|
|
|
330
341
|
if "CUDAExecutionProvider" in available:
|
|
331
342
|
self.providers = ["CUDAExecutionProvider"]
|
|
332
343
|
else:
|
|
333
|
-
#
|
|
334
|
-
print("CUDAExecutionProvider not available;
|
|
344
|
+
# CUDA not available, fall back to CPU or other available providers
|
|
345
|
+
print("CUDAExecutionProvider not available; falling back to available providers")
|
|
346
|
+
if available:
|
|
347
|
+
self.providers = [available[0]] # Use first available provider
|
|
348
|
+
print(f"Using provider: {self.providers[0]}")
|
|
349
|
+
else:
|
|
350
|
+
self.providers = ["CPUExecutionProvider"] # Ultimate fallback
|
|
351
|
+
print("No providers detected, using CPUExecutionProvider")
|
|
335
352
|
else:
|
|
336
353
|
self.providers = providers
|
|
337
354
|
|
|
@@ -166,7 +166,7 @@ matrice_analytics/post_processing/usecases/weld_defect_detection.py,sha256=b0dAJ
|
|
|
166
166
|
matrice_analytics/post_processing/usecases/wildlife_monitoring.py,sha256=TMVHJ5GLezmqG7DywmqbLggqNXgpsb63MD7IR6kvDkk,43446
|
|
167
167
|
matrice_analytics/post_processing/usecases/windmill_maintenance.py,sha256=G1eqo3Z-HYmGJ6oeZYrpZwhpvqQ9Lc_T-6S7BLBXHeA,40498
|
|
168
168
|
matrice_analytics/post_processing/usecases/wound_segmentation.py,sha256=ehNX6VuWMB3xAnCySO3ra3Tf_5FUNg5LCSdq_91h374,38342
|
|
169
|
-
matrice_analytics/post_processing/usecases/color/clip.py,sha256=
|
|
169
|
+
matrice_analytics/post_processing/usecases/color/clip.py,sha256=3pA_Oaw3hnMcuuyZLG5-1w1Kt04H04AHGy2d8463mzg,25741
|
|
170
170
|
matrice_analytics/post_processing/usecases/color/color_map_utils.py,sha256=SP-AEVcjLmL8rxblu-ixqUJC2fqlcr7ab4hWo4Fcr_k,2677
|
|
171
171
|
matrice_analytics/post_processing/usecases/color/color_mapper.py,sha256=nKPc28mJLlrl2HPua5EUUMweRRSI6WrrUBkeitTm7ms,17459
|
|
172
172
|
matrice_analytics/post_processing/usecases/color/clip_processor/merges.txt,sha256=n9aR98gDkhDg_O0VhlRmxlgg0JtjmIsBdL_iXeKZBRo,524619
|
|
@@ -188,8 +188,8 @@ matrice_analytics/post_processing/utils/format_utils.py,sha256=UTF7A5h9j0_S12xH9
|
|
|
188
188
|
matrice_analytics/post_processing/utils/geometry_utils.py,sha256=BWfdM6RsdJTTLR1GqkWfdwpjMEjTCJyuBxA4zVGKdfk,9623
|
|
189
189
|
matrice_analytics/post_processing/utils/smoothing_utils.py,sha256=78U-yucAcjUiZ0NIAc9NOUSIT0PWP1cqyIPA_Fdrjp0,14699
|
|
190
190
|
matrice_analytics/post_processing/utils/tracking_utils.py,sha256=rWxuotnJ3VLMHIBOud2KLcu4yZfDp7hVPWUtNAq_2xw,8288
|
|
191
|
-
matrice_analytics-0.1.
|
|
192
|
-
matrice_analytics-0.1.
|
|
193
|
-
matrice_analytics-0.1.
|
|
194
|
-
matrice_analytics-0.1.
|
|
195
|
-
matrice_analytics-0.1.
|
|
191
|
+
matrice_analytics-0.1.42.dist-info/licenses/LICENSE.txt,sha256=_uQUZpgO0mRYL5-fPoEvLSbNnLPv6OmbeEDCHXhK6Qc,1066
|
|
192
|
+
matrice_analytics-0.1.42.dist-info/METADATA,sha256=OLJohdXLb8RHXTcSxR5eUb1fcj85xYhpceBOMFEXnj4,14378
|
|
193
|
+
matrice_analytics-0.1.42.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
194
|
+
matrice_analytics-0.1.42.dist-info/top_level.txt,sha256=STAPEU-e-rWTerXaspdi76T_eVRSrEfFpURSP7_Dt8E,18
|
|
195
|
+
matrice_analytics-0.1.42.dist-info/RECORD,,
|
|
File without changes
|
{matrice_analytics-0.1.41.dist-info → matrice_analytics-0.1.42.dist-info}/licenses/LICENSE.txt
RENAMED
|
File without changes
|
|
File without changes
|