Spaces:
Paused
Paused
Added 4 new models
Browse files- perception_roi_server.py +5 -5
- rtdetr-l.pt +3 -0
- rtdetr-x.pt +3 -0
- yolov10l.pt +3 -0
- yolov10x.pt +3 -0
perception_roi_server.py
CHANGED
|
@@ -56,14 +56,14 @@ def root():
|
|
| 56 |
return {"status": "ok", "service": "roi-compression"}
|
| 57 |
|
| 58 |
_model_lock = threading.Lock()
|
| 59 |
-
|
| 60 |
|
| 61 |
def get_model(weights: str) -> YOLO:
|
| 62 |
-
|
| 63 |
with _model_lock:
|
| 64 |
-
if
|
| 65 |
-
|
| 66 |
-
return
|
| 67 |
|
| 68 |
|
| 69 |
def _parse_queries(q: str) -> List[str]:
|
|
|
|
| 56 |
return {"status": "ok", "service": "roi-compression"}
|
| 57 |
|
| 58 |
_model_lock = threading.Lock()
|
| 59 |
+
_models: Dict[str, YOLO] = {}
|
| 60 |
|
| 61 |
def get_model(weights: str) -> YOLO:
|
| 62 |
+
key = str(weights or DEFAULT_WEIGHTS)
|
| 63 |
with _model_lock:
|
| 64 |
+
if key not in _models:
|
| 65 |
+
_models[key] = YOLO(key)
|
| 66 |
+
return _models[key]
|
| 67 |
|
| 68 |
|
| 69 |
def _parse_queries(q: str) -> List[str]:
|
rtdetr-l.pt
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:6de60b10d4bc566f00cda0f5b4d64afe4b66d48dc9695d2171effb7859d8e73f
|
| 3 |
+
size 66511432
|
rtdetr-x.pt
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:81071ffee0986edff2dd2d790da364843b66717cdc61d9491edb50790fd3345b
|
| 3 |
+
size 135755662
|
yolov10l.pt
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:d0685e1e597f73aba8e56bc9651b6bb939c5b2f201dff5de0b9ef2a6207ae301
|
| 3 |
+
size 52425230
|
yolov10x.pt
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:605982e0b2c2ff070351afc8df3ecb38c54cfd7f133813acb366f454eb79b9a6
|
| 3 |
+
size 64395854
|