cathodeDreams commited on
Commit
2662bb7
·
verified ·
1 Parent(s): f4f4889

Update app.py

Browse files

edit video_processor

Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -79,7 +79,8 @@ def is_video_file(filename):
79
 
80
 
81
  def video_processor(video_path):
82
- video_inputs, video_sample_fps = fetch_video({"video": video_path, "max_frames": 8, "max_pixels": 256*28*28}, return_video_sample_fps=True)
 
83
  video_input = video_inputs.permute(0, 2, 3, 1).numpy().astype(np.uint8)
84
 
85
  # encode image with base64
@@ -98,7 +99,6 @@ def video_processor(video_path):
98
  }
99
  return video_info
100
 
101
-
102
  def _launch_demo(args):
103
  EP_URL = os.getenv("ENDPOINT_URL")
104
  HF_TOKEN = os.getenv("HF_TOKEN")
 
79
 
80
 
81
  def video_processor(video_path):
82
+ # Corrected line: removed the argument and adjusted the assignment
83
+ video_inputs = fetch_video({"video": video_path, "max_frames": 8, "max_pixels": 256*28*28})
84
  video_input = video_inputs.permute(0, 2, 3, 1).numpy().astype(np.uint8)
85
 
86
  # encode image with base64
 
99
  }
100
  return video_info
101
 
 
102
  def _launch_demo(args):
103
  EP_URL = os.getenv("ENDPOINT_URL")
104
  HF_TOKEN = os.getenv("HF_TOKEN")