Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -106,7 +106,7 @@ def speech_score(audio):
|
|
106 |
#return text_results, out_prob.squeeze(0).numpy(), text_lab[-1], Audio
|
107 |
prob=out_prob.squeeze(0).numpy()
|
108 |
print(prob)
|
109 |
-
score2=10*
|
110 |
print("score2",score2)
|
111 |
print(text_lab[-1])
|
112 |
text_emo=text_api(text_results)
|
@@ -267,8 +267,8 @@ with gr.Blocks() as speech_all:
|
|
267 |
value="Score", interactive=True, scale=1, elem_classes="submit"
|
268 |
)
|
269 |
with gr.Column(scale=2):
|
270 |
-
score2=gr.Textbox(interactive=False)
|
271 |
-
text_emo=gr.Textbox(interactive=False)
|
272 |
|
273 |
clear_audio.click(
|
274 |
fn=clear_2,
|
|
|
106 |
#return text_results, out_prob.squeeze(0).numpy(), text_lab[-1], Audio
|
107 |
prob=out_prob.squeeze(0).numpy()
|
108 |
print(prob)
|
109 |
+
score2=10*prob[0]-10*prob[1]
|
110 |
print("score2",score2)
|
111 |
print(text_lab[-1])
|
112 |
text_emo=text_api(text_results)
|
|
|
267 |
value="Score", interactive=True, scale=1, elem_classes="submit"
|
268 |
)
|
269 |
with gr.Column(scale=2):
|
270 |
+
score2=gr.Textbox(interactive=False,label="score2")
|
271 |
+
text_emo=gr.Textbox(interactive=False,label="text_emo")
|
272 |
|
273 |
clear_audio.click(
|
274 |
fn=clear_2,
|