Spaces:
Running
Running
Rivalcoder
commited on
Commit
·
9affd94
1
Parent(s):
9c6982b
New Try
Browse files
app.py
CHANGED
@@ -349,8 +349,7 @@ with gr.Blocks(title="Video Emotion Detection", theme=gr.themes.Soft()) as demo:
|
|
349 |
with gr.Column():
|
350 |
video_input = gr.Video(
|
351 |
label="Upload Video",
|
352 |
-
sources=["upload"]
|
353 |
-
type="filepath"
|
354 |
)
|
355 |
submit_btn = gr.Button("Analyze Video", variant="primary")
|
356 |
|
@@ -370,6 +369,7 @@ with gr.Blocks(title="Video Emotion Detection", theme=gr.themes.Soft()) as demo:
|
|
370 |
api_name="predict"
|
371 |
)
|
372 |
|
|
|
373 |
# FastAPI Endpoints
|
374 |
@app.post("/api/analyze-video")
|
375 |
async def analyze_video(file: UploadFile = File(...)):
|
|
|
349 |
with gr.Column():
|
350 |
video_input = gr.Video(
|
351 |
label="Upload Video",
|
352 |
+
sources=["upload"] # Corrected line
|
|
|
353 |
)
|
354 |
submit_btn = gr.Button("Analyze Video", variant="primary")
|
355 |
|
|
|
369 |
api_name="predict"
|
370 |
)
|
371 |
|
372 |
+
|
373 |
# FastAPI Endpoints
|
374 |
@app.post("/api/analyze-video")
|
375 |
async def analyze_video(file: UploadFile = File(...)):
|