soujanyaporia commited on
Commit
8b43f70
1 Parent(s): 9a3ee3f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -89,11 +89,11 @@ def gradio_generate(prompt, output_format, steps, guidance):
89
  # output_filename = f"{prompt.replace(' ', '_')}_{steps}_{guidance}"[:250] + ".wav"
90
 
91
  output_filename_1 = "tmp1.wav"
92
- wavio.write(output_filename_1, output_wave, rate=16000, sampwidth=2)
93
  output_filename_2 = "tmp2.wav"
94
- wavio.write(output_filename_2, output_wave, rate=16000, sampwidth=2)
95
  output_filename_3 = "tmp3.wav"
96
- wavio.write(output_filename_3, output_wave, rate=16000, sampwidth=2)
97
 
98
  if (output_format == "mp3"):
99
  AudioSegment.from_wav("tmp1.wav").export("tmp1.mp3", format = "mp3")
 
89
  # output_filename = f"{prompt.replace(' ', '_')}_{steps}_{guidance}"[:250] + ".wav"
90
 
91
  output_filename_1 = "tmp1.wav"
92
+ wavio.write(output_filename_1, output_wave[0], rate=16000, sampwidth=2)
93
  output_filename_2 = "tmp2.wav"
94
+ wavio.write(output_filename_2, output_wave[1], rate=16000, sampwidth=2)
95
  output_filename_3 = "tmp3.wav"
96
+ wavio.write(output_filename_3, output_wave[2], rate=16000, sampwidth=2)
97
 
98
  if (output_format == "mp3"):
99
  AudioSegment.from_wav("tmp1.wav").export("tmp1.mp3", format = "mp3")