Spaces:
Paused
Paused
Update web-demos/hugging_face/app.py
Browse files
web-demos/hugging_face/app.py
CHANGED
@@ -13,7 +13,9 @@ import torch
|
|
13 |
import torchvision
|
14 |
import numpy as np
|
15 |
import gradio as gr
|
16 |
-
|
|
|
|
|
17 |
from tools.painter import mask_painter
|
18 |
from track_anything import TrackingAnything
|
19 |
|
@@ -61,9 +63,7 @@ def get_prompt(click_state, click_input):
|
|
61 |
return prompt
|
62 |
|
63 |
# extract frames from upload video
|
64 |
-
|
65 |
-
import ffmpeg
|
66 |
-
from PIL import Image
|
67 |
def get_frames_from_video(video_input, video_state):
|
68 |
video_path = video_input
|
69 |
frames = []
|
|
|
13 |
import torchvision
|
14 |
import numpy as np
|
15 |
import gradio as gr
|
16 |
+
import tempfile
|
17 |
+
import ffmpeg
|
18 |
+
from PIL import Image
|
19 |
from tools.painter import mask_painter
|
20 |
from track_anything import TrackingAnything
|
21 |
|
|
|
63 |
return prompt
|
64 |
|
65 |
# extract frames from upload video
|
66 |
+
|
|
|
|
|
67 |
def get_frames_from_video(video_input, video_state):
|
68 |
video_path = video_input
|
69 |
frames = []
|