catiR
commited on
Commit
·
3948240
1
Parent(s):
0d67145
run clustering
Browse files
app.py
CHANGED
@@ -35,7 +35,7 @@ def f1(voices, sent, indices):
|
|
35 |
#tts_audio, tts_score, graph = scripts.runSQ.run(sent, voices, indices)
|
36 |
tts_audio, tts_score, tts_fig_p, mid_fig_p, bad_fig_p, tts_fig_e, fig_mid_e, fig_bad_e = scripts.runSQ.run(sent, [voices], indices)
|
37 |
score_report = f'Difference from TTS to real speech: {round(tts_score,2)}'
|
38 |
-
return (tts_audio, score_report, tts_fig_p, mid_fig_p, bad_fig_p)
|
39 |
|
40 |
|
41 |
def label_indices(sentence):
|
@@ -76,13 +76,28 @@ with bl:
|
|
76 |
|
77 |
tts_output = gr.Audio(interactive=False)
|
78 |
report_score = gr.Markdown('Difference from TTS to real speech:')
|
79 |
-
|
80 |
-
with gr.
|
81 |
-
|
82 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
83 |
|
84 |
temp_sentmenu.input(label_indices,temp_sentmenu,marked_sentence)
|
85 |
-
temp_button.click(f1,[voiceselect,temp_sentmenu,spanselect],[tts_output,report_score,pl1,pl2,pl3])
|
86 |
|
87 |
|
88 |
if __name__ == "__main__":
|
|
|
35 |
#tts_audio, tts_score, graph = scripts.runSQ.run(sent, voices, indices)
|
36 |
tts_audio, tts_score, tts_fig_p, mid_fig_p, bad_fig_p, tts_fig_e, fig_mid_e, fig_bad_e = scripts.runSQ.run(sent, [voices], indices)
|
37 |
score_report = f'Difference from TTS to real speech: {round(tts_score,2)}'
|
38 |
+
return (tts_audio, score_report, tts_fig_p, mid_fig_p, bad_fig_p, tts_fig_e, fig_mid_e, fig_bad_e)
|
39 |
|
40 |
|
41 |
def label_indices(sentence):
|
|
|
76 |
|
77 |
tts_output = gr.Audio(interactive=False)
|
78 |
report_score = gr.Markdown('Difference from TTS to real speech:')
|
79 |
+
|
80 |
+
with gr.Tabs():
|
81 |
+
with gr.TabItem("Pitch"):
|
82 |
+
|
83 |
+
pl1 = gr.Plot()
|
84 |
+
with gr.Row():
|
85 |
+
pl2 = gr.Plot()
|
86 |
+
pl3 = gr.Plot()
|
87 |
+
|
88 |
+
with gr.TabItem("Energy"):
|
89 |
+
|
90 |
+
pl4 = gr.Plot()
|
91 |
+
with gr.Row():
|
92 |
+
pl5 = gr.Plot()
|
93 |
+
pl6 = gr.Plot()
|
94 |
+
|
95 |
+
|
96 |
+
|
97 |
+
|
98 |
|
99 |
temp_sentmenu.input(label_indices,temp_sentmenu,marked_sentence)
|
100 |
+
temp_button.click(f1,[voiceselect,temp_sentmenu,spanselect],[tts_output,report_score,pl1,pl2,pl3,pl4,pl5,pl6])
|
101 |
|
102 |
|
103 |
if __name__ == "__main__":
|