kira4424 commited on
Commit
dc1f5b6
·
1 Parent(s): fd83b91

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +15 -15
app.py CHANGED
@@ -120,21 +120,21 @@ if __name__ == "__main__":
120
  btn.click(tts_fn,
121
  inputs=[textbox, char_dropdown, language_dropdown, duration_slider,],
122
  outputs=[text_output, audio_output])
123
- with gr.Tab("Voice Conversion"):
124
- gr.Markdown("""
125
- 录制或上传声音,并选择要转换的音色。
126
- """)
127
- with gr.Column():
128
- record_audio = gr.Audio(label="record your voice", source="microphone")
129
- upload_audio = gr.Audio(label="or upload audio here", source="upload")
130
- source_speaker = gr.Dropdown(choices=speakers, value=speakers[0], label="source speaker")
131
- target_speaker = gr.Dropdown(choices=speakers, value=speakers[0], label="target speaker")
132
- with gr.Column():
133
- message_box = gr.Textbox(label="Message")
134
- converted_audio = gr.Audio(label='converted audio')
135
- btn = gr.Button("Convert!")
136
- btn.click(vc_fn, inputs=[source_speaker, target_speaker, record_audio, upload_audio],
137
- outputs=[message_box, converted_audio])
138
  webbrowser.open("http://127.0.0.1:7860")
139
  app.launch(share=args.share)
140
 
 
120
  btn.click(tts_fn,
121
  inputs=[textbox, char_dropdown, language_dropdown, duration_slider,],
122
  outputs=[text_output, audio_output])
123
+ # with gr.Tab("Voice Conversion"):
124
+ # gr.Markdown("""
125
+ # 录制或上传声音,并选择要转换的音色。
126
+ # """)
127
+ # with gr.Column():
128
+ # record_audio = gr.Audio(label="record your voice", source="microphone")
129
+ # upload_audio = gr.Audio(label="or upload audio here", source="upload")
130
+ # source_speaker = gr.Dropdown(choices=speakers, value=speakers[0], label="source speaker")
131
+ # target_speaker = gr.Dropdown(choices=speakers, value=speakers[0], label="target speaker")
132
+ # with gr.Column():
133
+ # message_box = gr.Textbox(label="Message")
134
+ # converted_audio = gr.Audio(label='converted audio')
135
+ # btn = gr.Button("Convert!")
136
+ # btn.click(vc_fn, inputs=[source_speaker, target_speaker, record_audio, upload_audio],
137
+ # outputs=[message_box, converted_audio])
138
  webbrowser.open("http://127.0.0.1:7860")
139
  app.launch(share=args.share)
140