Spaces:
Sleeping
Sleeping
Rename app (3).py to app.py
Browse files- app (3).py → app.py +3 -3
app (3).py → app.py
RENAMED
@@ -3,12 +3,12 @@ import cv2
|
|
3 |
import numpy as np
|
4 |
from ultralytics import YOLO
|
5 |
|
6 |
-
model = YOLO('best
|
7 |
|
8 |
def predict_image(img):
|
9 |
|
10 |
-
model = YOLO('best
|
11 |
-
result = model.predict(img,conf=0.
|
12 |
res_plotted = result[0].plot()
|
13 |
#cv2.imshow( res_plotted)
|
14 |
return res_plotted
|
|
|
3 |
import numpy as np
|
4 |
from ultralytics import YOLO
|
5 |
|
6 |
+
model = YOLO('best.pt')
|
7 |
|
8 |
def predict_image(img):
|
9 |
|
10 |
+
model = YOLO('best.pt')
|
11 |
+
result = model.predict(img,conf=0.9)
|
12 |
res_plotted = result[0].plot()
|
13 |
#cv2.imshow( res_plotted)
|
14 |
return res_plotted
|