meadevx commited on
Commit
a0252e7
·
verified ·
1 Parent(s): 691908b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -7
app.py CHANGED
@@ -23,15 +23,11 @@ def text_to_speech(text):
23
  audio_array = audio_array.astype(np.int16)
24
 
25
  # Save to WAV file
26
- #output_file = "output/output.wav"
27
- #scipy.io.wavfile.write(output_file, rate=model.config.sampling_rate, data=audio_array)
28
 
29
  # Return the path to the WAV file
30
- #return output_file
31
-
32
- # Return the audio array directly
33
- return audio_array
34
-
35
 
36
  demo = gr.Interface(
37
  text_to_speech,
 
23
  audio_array = audio_array.astype(np.int16)
24
 
25
  # Save to WAV file
26
+ output_file = "output.wav"
27
+ scipy.io.wavfile.write(output_file, rate=model.config.sampling_rate, data=audio_array)
28
 
29
  # Return the path to the WAV file
30
+ return output_file
 
 
 
 
31
 
32
  demo = gr.Interface(
33
  text_to_speech,