Spaces:
Sleeping
Sleeping
tuansunday05
commited on
Commit
•
ada3dea
1
Parent(s):
964c04d
Update during time GPU
Browse files
app.py
CHANGED
@@ -6,7 +6,7 @@ import threading
|
|
6 |
|
7 |
should_continue = True
|
8 |
|
9 |
-
@spaces.GPU(duration=
|
10 |
def yolov9_inference(model_id, image_size, conf_threshold, iou_threshold, img_path=None, vid_path=None):
|
11 |
global should_continue
|
12 |
img_extensions = ['.jpg', '.jpeg', '.png', '.gif'] # Add more image extensions if needed
|
@@ -34,7 +34,6 @@ def yolov9_inference(model_id, image_size, conf_threshold, iou_threshold, img_pa
|
|
34 |
|
35 |
return output_image, output_video, output_path
|
36 |
|
37 |
-
@spaces.GPU(duration=60)
|
38 |
def inference(model_id, image_size, conf_threshold, iou_threshold, img_path=None, vid_path=None):
|
39 |
global should_continue
|
40 |
should_continue = True
|
|
|
6 |
|
7 |
should_continue = True
|
8 |
|
9 |
+
@spaces.GPU(duration=120)
|
10 |
def yolov9_inference(model_id, image_size, conf_threshold, iou_threshold, img_path=None, vid_path=None):
|
11 |
global should_continue
|
12 |
img_extensions = ['.jpg', '.jpeg', '.png', '.gif'] # Add more image extensions if needed
|
|
|
34 |
|
35 |
return output_image, output_video, output_path
|
36 |
|
|
|
37 |
def inference(model_id, image_size, conf_threshold, iou_threshold, img_path=None, vid_path=None):
|
38 |
global should_continue
|
39 |
should_continue = True
|