akhaliq HF Staff commited on
Commit
4f3df06
·
1 Parent(s): 39f4972

fix: update run_inference to accept dictionary input for video path extraction

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -175,8 +175,8 @@ def get_examples() -> List[FileData]:
175
 
176
  @app.api()
177
  @spaces.GPU(duration=120)
178
- def run_inference(video_file: FileData) -> dict:
179
- video_path = video_file.path
180
  if not os.path.exists(video_path):
181
  return {"error": "Video file not found"}
182
 
 
175
 
176
  @app.api()
177
  @spaces.GPU(duration=120)
178
+ def run_inference(video_file: dict) -> dict:
179
+ video_path = video_file["path"]
180
  if not os.path.exists(video_path):
181
  return {"error": "Video file not found"}
182