Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -4,7 +4,7 @@ from utilities.setup import get_files
|
|
4 |
|
5 |
|
6 |
#@spaces.GPU
|
7 |
-
def process_meeting(audio_input, num_speakers,
|
8 |
if 1 < num_speakers < 6:
|
9 |
answer = "Completed Loading Data", "fl"
|
10 |
else:
|
@@ -27,15 +27,17 @@ def main(conf):
|
|
27 |
|
28 |
audio_input = gr.Audio(type="filepath", label="Upload Audio File")
|
29 |
num_speakers = gr.Number(label="Number of Speakers",
|
30 |
-
info="Please include ",
|
31 |
value=2,
|
32 |
precision=0,
|
33 |
minimum=2,
|
34 |
maximum=5)
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
|
|
|
|
|
|
39 |
|
40 |
process_button = gr.Button("Process")
|
41 |
diarization_output = gr.Textbox(label="Diarization Output")
|
@@ -43,7 +45,7 @@ def main(conf):
|
|
43 |
|
44 |
process_button.click(
|
45 |
fn=process_meeting,
|
46 |
-
inputs=[audio_input, num_speakers,
|
47 |
outputs=[diarization_output, label_file_link]
|
48 |
)
|
49 |
|
|
|
4 |
|
5 |
|
6 |
#@spaces.GPU
|
7 |
+
def process_meeting(audio_input, num_speakers, speaker_names):
|
8 |
if 1 < num_speakers < 6:
|
9 |
answer = "Completed Loading Data", "fl"
|
10 |
else:
|
|
|
27 |
|
28 |
audio_input = gr.Audio(type="filepath", label="Upload Audio File")
|
29 |
num_speakers = gr.Number(label="Number of Speakers",
|
|
|
30 |
value=2,
|
31 |
precision=0,
|
32 |
minimum=2,
|
33 |
maximum=5)
|
34 |
+
speaker_names = gr.Dataframe(
|
35 |
+
label="Names and Additional Info",
|
36 |
+
headers=["Name", "Supporting Details"],
|
37 |
+
datatype=["str", "str"],
|
38 |
+
row_count=(5,"dynamic"),
|
39 |
+
col_count=(2, "fixed"),
|
40 |
+
),
|
41 |
|
42 |
process_button = gr.Button("Process")
|
43 |
diarization_output = gr.Textbox(label="Diarization Output")
|
|
|
45 |
|
46 |
process_button.click(
|
47 |
fn=process_meeting,
|
48 |
+
inputs=[audio_input, num_speakers, speaker_names],
|
49 |
outputs=[diarization_output, label_file_link]
|
50 |
)
|
51 |
|