Update app.py
Browse files
app.py
CHANGED
@@ -190,14 +190,15 @@ with gr.Blocks() as demo:
|
|
190 |
""")
|
191 |
with gr.Row():
|
192 |
with gr.Column():
|
193 |
-
|
194 |
-
|
195 |
-
|
196 |
with gr.Column():
|
197 |
result_html = gr.HTML(label="π§ͺ Health Report Table")
|
198 |
result_image = gr.Image(label="π· Key Frame Snapshot")
|
199 |
-
|
200 |
-
submit_btn.click(fn=lambda mode, video, image: analyze_video(video) if mode=="Video" else analyze_face(image), inputs=[mode_selector, video_input, video_input], outputs=[result_html, result_image])
|
|
|
201 |
gr.Markdown("""---
|
202 |
β
Table Format β’ AI Prediction β’ rPPG-based HR β’ Dynamic Summary β’ Multilingual Support β’ CTA""")
|
203 |
|
|
|
190 |
""")
|
191 |
with gr.Row():
|
192 |
with gr.Column():
|
193 |
+
mode_selector = gr.Radio(label="Choose Input Mode", choices=["Image", "Video"], value="Image")
|
194 |
+
video_input = gr.Video(label="π½ Upload Face Video or Image", sources=["upload", "webcam"])
|
195 |
+
submit_btn = gr.Button("π Analyze")
|
196 |
with gr.Column():
|
197 |
result_html = gr.HTML(label="π§ͺ Health Report Table")
|
198 |
result_image = gr.Image(label="π· Key Frame Snapshot")
|
199 |
+
|
200 |
+
submit_btn.click(fn=lambda mode, video, image: analyze_video(video) if mode=="Video" else analyze_face(image), inputs=[mode_selector, video_input, video_input], outputs=[result_html, result_image])
|
201 |
+
|
202 |
gr.Markdown("""---
|
203 |
β
Table Format β’ AI Prediction β’ rPPG-based HR β’ Dynamic Summary β’ Multilingual Support β’ CTA""")
|
204 |
|