darksakura commited on
Commit
9ebb8fe
·
1 Parent(s): 144e945

Upload app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -3
app.py CHANGED
@@ -182,7 +182,7 @@ with app:
182
 
183
  sid = gr.Dropdown(label="音色", choices=spks, value="HOSHINO_MINAMI")
184
  #sid.change(fn=update_dropdown,inputs=[sid],outputs=[sid])
185
- sid.update(interactive=True)
186
  with gr.Accordion(label="↓切换模型(默认58v1,音色具有抽奖性质,可切换尝试)", open=False):
187
  modelstrs = gr.Dropdown(label = "模型", choices = modelPaths, value = modelPaths[0], type = "value")
188
  btnMod = gr.Button("载入模型")
@@ -193,7 +193,7 @@ with app:
193
  vc_transform = gr.Slider(label="变调(整数,可以正负,半音数量,升高八度就是12)",maximum=16, minimum=-16, step=1, value=0)
194
  f0_predictor = gr.Radio(label="f0预测器(如遇哑音可以尝试更换f0)凭干声干净程度选择。推荐fcpe和rmvpe", choices=["pm","dio","harvest","fcpe","rmvpe"], value="fcpe")
195
  with gr.Row():
196
- cluster_ratio = gr.Slider(label="聚类模型混合比例,0-1之间,默认为0不启用聚类,能提升音色相似度,但会导致咬字下降(如果使用建议0.5左右)",maximum=0, minimum=1, step=0.1, value=0)
197
  output_format = gr.Radio(label="音频输出格式(MP3会导致时间轴多27ms,需合成请选flac)", choices=["flac", "mp3"], value = "flac")#格式
198
  vc_submit = gr.Button("音频转换", variant="primary")
199
 
@@ -202,7 +202,6 @@ with app:
202
 
203
  vc_submit.click(vc_fn, [output_format,sid, vc_input3, vc_transform,auto_f0,cluster_ratio, slice_db,f0_predictor], [vc_output1, vc_output2])
204
  vc_tts_submit.click(tts_fn, [text_input, tts_gender, tts_lang, tts_rate, tts_volume, sid, vc_transform,auto_f0,cluster_ratio, slice_db, f0_predictor], [vc_output1, vc_output2])
205
-
206
  app.launch()
207
 
208
 
 
182
 
183
  sid = gr.Dropdown(label="音色", choices=spks, value="HOSHINO_MINAMI")
184
  #sid.change(fn=update_dropdown,inputs=[sid],outputs=[sid])
185
+ #sid.update(interactive=True)
186
  with gr.Accordion(label="↓切换模型(默认58v1,音色具有抽奖性质,可切换尝试)", open=False):
187
  modelstrs = gr.Dropdown(label = "模型", choices = modelPaths, value = modelPaths[0], type = "value")
188
  btnMod = gr.Button("载入模型")
 
193
  vc_transform = gr.Slider(label="变调(整数,可以正负,半音数量,升高八度就是12)",maximum=16, minimum=-16, step=1, value=0)
194
  f0_predictor = gr.Radio(label="f0预测器(如遇哑音可以尝试更换f0)凭干声干净程度选择。推荐fcpe和rmvpe", choices=["pm","dio","harvest","fcpe","rmvpe"], value="fcpe")
195
  with gr.Row():
196
+ cluster_ratio = gr.Slider(label="聚类模型混合比例,0-1之间,默认为0不启用聚类,能提升音色相似度,但会导致咬字下降(如果使用建议0.5左右)",maximum=1, minimum=0, step=0.1, value=0)
197
  output_format = gr.Radio(label="音频输出格式(MP3会导致时间轴多27ms,需合成请选flac)", choices=["flac", "mp3"], value = "flac")#格式
198
  vc_submit = gr.Button("音频转换", variant="primary")
199
 
 
202
 
203
  vc_submit.click(vc_fn, [output_format,sid, vc_input3, vc_transform,auto_f0,cluster_ratio, slice_db,f0_predictor], [vc_output1, vc_output2])
204
  vc_tts_submit.click(tts_fn, [text_input, tts_gender, tts_lang, tts_rate, tts_volume, sid, vc_transform,auto_f0,cluster_ratio, slice_db, f0_predictor], [vc_output1, vc_output2])
 
205
  app.launch()
206
 
207