Rammohan0504 commited on
Commit
c391431
·
verified ·
1 Parent(s): 94e0da7

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -186,7 +186,7 @@ def analyze_face(image):
186
 
187
  # Generate Health Card HTML
188
  health_card_html = build_health_card("profile_image_placeholder_base64", test_results, summary)
189
- return health_card_html
190
 
191
  # Create Gradio interface
192
  with gr.Blocks() as demo:
@@ -202,7 +202,8 @@ with gr.Blocks() as demo:
202
  result_image = gr.Image(label="📷 Key Frame Snapshot")
203
 
204
  def route_inputs(mode, image, video):
205
- return analyze_face(image) if mode == "Image" else analyze_face(video)
 
206
 
207
  submit_btn.click(fn=route_inputs, inputs=[mode_selector, image_input, video_input], outputs=[result_html, result_image])
208
 
 
186
 
187
  # Generate Health Card HTML
188
  health_card_html = build_health_card("profile_image_placeholder_base64", test_results, summary)
189
+ return health_card_html, frame_rgb
190
 
191
  # Create Gradio interface
192
  with gr.Blocks() as demo:
 
202
  result_image = gr.Image(label="📷 Key Frame Snapshot")
203
 
204
  def route_inputs(mode, image, video):
205
+ health_card_html, frame_rgb = analyze_face(image) if mode == "Image" else analyze_face(video)
206
+ return health_card_html, frame_rgb
207
 
208
  submit_btn.click(fn=route_inputs, inputs=[mode_selector, image_input, video_input], outputs=[result_html, result_image])
209