Update app.py
Browse files
app.py
CHANGED
@@ -410,6 +410,18 @@ def process_speaker(video, speaker_idx, n_participants, meeting_texts, *language
|
|
410 |
outputs.append(meeting_texts)
|
411 |
return outputs
|
412 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
413 |
# Modify the Gradio interface to manage the meeting_texts between function calls
|
414 |
def create_gradio_interface(n_participants, language_choices):
|
415 |
with gr.Blocks() as demo:
|
|
|
410 |
outputs.append(meeting_texts)
|
411 |
return outputs
|
412 |
|
413 |
+
|
414 |
+
def create_participant_row(i, language_choices):
|
415 |
+
"""Creates the UI for a single participant."""
|
416 |
+
with gr.Row():
|
417 |
+
video_input = gr.Video(label=f"Participant {i+1} Video", interactive=True)
|
418 |
+
language_dropdown = gr.Dropdown(choices=language_choices, label=f"Participant {i+1} Language", value=language_choices[i])
|
419 |
+
transcript_output = gr.Textbox(label=f"Participant {i+1} Transcript")
|
420 |
+
translated_text = gr.Textbox(label="Speaker's Translated Text")
|
421 |
+
dubbed_video = gr.Video(label="Speaker's Dubbed Video")
|
422 |
+
return video_input, language_dropdown, transcript_output, translated_text, dubbed_video
|
423 |
+
|
424 |
+
|
425 |
# Modify the Gradio interface to manage the meeting_texts between function calls
|
426 |
def create_gradio_interface(n_participants, language_choices):
|
427 |
with gr.Blocks() as demo:
|