Mahiruoshi
commited on
Commit
•
4cc1f98
1
Parent(s):
a59b779
Update app.py
Browse files
app.py
CHANGED
@@ -144,7 +144,7 @@ def infer(language,text,tts_input2,tts_input3,speaker_id,n_scale= 0.667,n_scale_
|
|
144 |
spending_time = "推理时间:"+str(t2-t1)+"s"
|
145 |
print(spending_time)
|
146 |
return (hps_ms.data.sampling_rate, audio)
|
147 |
-
lan = ["中文","日文"
|
148 |
idols = ["高咲侑(误)","歩夢","かすみ","しずく","果林","愛","彼方","せつ菜","璃奈","栞子","エマ","ランジュ","ミア"]
|
149 |
|
150 |
|
@@ -167,17 +167,15 @@ with app:
|
|
167 |
|
168 |
with gr.TabItem("Basic"):
|
169 |
|
170 |
-
tts_input1 = gr.TextArea(label="
|
171 |
-
|
172 |
-
|
173 |
-
|
174 |
-
|
175 |
-
para_input2 = gr.Slider(minimum= 0.01,maximum=1.0,label="更改噪声偏差", value=0.3)
|
176 |
-
para_input3 = gr.Slider(minimum= 0.1,maximum=10,label="更改时间比例", value=0.6)
|
177 |
tts_submit = gr.Button("Generate", variant="primary")
|
178 |
speaker1 = gr.Dropdown(label="选择说话人",choices=idols, value="かすみ", interactive=True)
|
179 |
tts_output2 = gr.Audio(label="Output")
|
180 |
-
tts_submit.click(infer, [language,tts_input1,
|
181 |
#app.launch(share=True)
|
182 |
app.launch()
|
183 |
'''
|
|
|
144 |
spending_time = "推理时间:"+str(t2-t1)+"s"
|
145 |
print(spending_time)
|
146 |
return (hps_ms.data.sampling_rate, audio)
|
147 |
+
lan = ["中文","日文"]
|
148 |
idols = ["高咲侑(误)","歩夢","かすみ","しずく","果林","愛","彼方","せつ菜","璃奈","栞子","エマ","ランジュ","ミア"]
|
149 |
|
150 |
|
|
|
167 |
|
168 |
with gr.TabItem("Basic"):
|
169 |
|
170 |
+
tts_input1 = gr.TextArea(label="旧模型", value="一次審査、二次審査、それぞれの欄に記入をお願いします。")
|
171 |
+
language = gr.Dropdown(label="选择语言",choices=lan, value="日文", interactive=True)
|
172 |
+
para_input1 = gr.Slider(minimum= 0.01,maximum=1.0,label="更改噪声比例", value=0.667)
|
173 |
+
para_input2 = gr.Slider(minimum= 0.01,maximum=1.0,label="更改噪声偏差", value=0.8)
|
174 |
+
para_input3 = gr.Slider(minimum= 0.1,maximum=10,label="更改时间比例", value=1)
|
|
|
|
|
175 |
tts_submit = gr.Button("Generate", variant="primary")
|
176 |
speaker1 = gr.Dropdown(label="选择说话人",choices=idols, value="かすみ", interactive=True)
|
177 |
tts_output2 = gr.Audio(label="Output")
|
178 |
+
tts_submit.click(infer, [language,tts_input1,speaker1,para_input1,para_input2,para_input3], [tts_output2])
|
179 |
#app.launch(share=True)
|
180 |
app.launch()
|
181 |
'''
|