Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -9,17 +9,10 @@ import numpy as np
|
|
9 |
import requests
|
10 |
from PIL import Image
|
11 |
|
12 |
-
|
13 |
-
|
14 |
-
|
15 |
-
|
16 |
-
os.system("pip install -e .")
|
17 |
-
|
18 |
-
import super_gradients
|
19 |
-
from super_gradients.common.object_names import Models
|
20 |
-
from super_gradients.training import models
|
21 |
-
from super_gradients.training.utils.visualization.detection import draw_bbox
|
22 |
-
|
23 |
|
24 |
# Initialize your pose estimation model
|
25 |
yolo_nas_pose = models.get("best.pt",
|
|
|
9 |
import requests
|
10 |
from PIL import Image
|
11 |
|
12 |
+
# Load the YOLO model
|
13 |
+
model_path = "./best-model.torchscript"
|
14 |
+
model = torch.jit.load(model_path, map_location=torch.device("cpu"))
|
15 |
+
model.eval()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
16 |
|
17 |
# Initialize your pose estimation model
|
18 |
yolo_nas_pose = models.get("best.pt",
|