amir22010 commited on
Commit
5a87964
·
verified ·
1 Parent(s): abd2b7a

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -0
app.py CHANGED
@@ -51,6 +51,7 @@ def text_to_speech(text):
51
  output_file = temp_file.name
52
  with wave.open(f"{output_file}", "w") as fp:
53
  fp.setparams((1, 2, tts.get_sampling_rate(), len(samples), "NONE", "NONE"))
 
54
  fp.writeframes(samples)
55
  return output_file
56
 
 
51
  output_file = temp_file.name
52
  with wave.open(f"{output_file}", "w") as fp:
53
  fp.setparams((1, 2, tts.get_sampling_rate(), len(samples), "NONE", "NONE"))
54
+ samples = np.ascontiguousarray(samples)
55
  fp.writeframes(samples)
56
  return output_file
57