Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -7,7 +7,7 @@ import spaces
|
|
| 7 |
from ultralytics import YOLO
|
| 8 |
from tqdm import tqdm
|
| 9 |
from PIL import Image
|
| 10 |
-
|
| 11 |
|
| 12 |
# Prevent config warnings
|
| 13 |
os.environ["YOLO_CONFIG_DIR"] = "/tmp"
|
|
@@ -90,8 +90,7 @@ def process_video(video_path):
|
|
| 90 |
sharp = cv2.addWeighted(selective,2.0,blur,-1.0,0)
|
| 91 |
out_img = "sharpened_board_color.jpg"
|
| 92 |
cv2.imwrite(out_img, sharp)
|
| 93 |
-
|
| 94 |
-
return out_img, caption
|
| 95 |
|
| 96 |
demo = gr.Interface(
|
| 97 |
fn=process_video,
|
|
|
|
| 7 |
from ultralytics import YOLO
|
| 8 |
from tqdm import tqdm
|
| 9 |
from PIL import Image
|
| 10 |
+
|
| 11 |
|
| 12 |
# Prevent config warnings
|
| 13 |
os.environ["YOLO_CONFIG_DIR"] = "/tmp"
|
|
|
|
| 90 |
sharp = cv2.addWeighted(selective,2.0,blur,-1.0,0)
|
| 91 |
out_img = "sharpened_board_color.jpg"
|
| 92 |
cv2.imwrite(out_img, sharp)
|
| 93 |
+
|
|
|
|
| 94 |
|
| 95 |
demo = gr.Interface(
|
| 96 |
fn=process_video,
|