Update app.py
Browse files
app.py
CHANGED
|
@@ -40,7 +40,7 @@ def process_video(video_frame):
|
|
| 40 |
# Gradio interface
|
| 41 |
iface = gr.Interface(
|
| 42 |
fn=process_video, # Function that processes each frame
|
| 43 |
-
inputs=gr.Video(
|
| 44 |
outputs=gr.Video(), # Output is also a video
|
| 45 |
live=True, # Stream the video in real time
|
| 46 |
title="Suspicious Activity Detection" # Interface title
|
|
|
|
| 40 |
# Gradio interface
|
| 41 |
iface = gr.Interface(
|
| 42 |
fn=process_video, # Function that processes each frame
|
| 43 |
+
inputs=gr.Video(type="webcam", streaming=True), # Use webcam as input
|
| 44 |
outputs=gr.Video(), # Output is also a video
|
| 45 |
live=True, # Stream the video in real time
|
| 46 |
title="Suspicious Activity Detection" # Interface title
|