CosyVoice commited on
Commit
6be8d0f
·
1 Parent(s): 9504c3f

add server_name

Browse files
Files changed (1) hide show
  1. webui.py +2 -2
webui.py CHANGED
@@ -132,7 +132,7 @@ def generate_audio(tts_text, mode_checkbox_group, sft_dropdown, prompt_text, pro
132
  logging.info('get instruct inference request')
133
  set_all_random_seed(seed)
134
  output = cosyvoice.inference_instruct(tts_text, sft_dropdown, instruct_text)
135
-
136
  if speed_factor != 1.0:
137
  try:
138
  audio_data, sample_rate = speed_change(output["tts_speech"], target_sr, str(speed_factor))
@@ -175,7 +175,7 @@ def main():
175
  outputs=[audio_output])
176
  mode_checkbox_group.change(fn=change_instruction, inputs=[mode_checkbox_group], outputs=[instruction_text])
177
  demo.queue(max_size=4, default_concurrency_limit=2)
178
- demo.launch(server_port=args.port)
179
 
180
  if __name__ == '__main__':
181
  parser = argparse.ArgumentParser()
 
132
  logging.info('get instruct inference request')
133
  set_all_random_seed(seed)
134
  output = cosyvoice.inference_instruct(tts_text, sft_dropdown, instruct_text)
135
+
136
  if speed_factor != 1.0:
137
  try:
138
  audio_data, sample_rate = speed_change(output["tts_speech"], target_sr, str(speed_factor))
 
175
  outputs=[audio_output])
176
  mode_checkbox_group.change(fn=change_instruction, inputs=[mode_checkbox_group], outputs=[instruction_text])
177
  demo.queue(max_size=4, default_concurrency_limit=2)
178
+ demo.launch(server_name='0.0.0.0', server_port=args.port)
179
 
180
  if __name__ == '__main__':
181
  parser = argparse.ArgumentParser()