Spaces:
Sleeping
Sleeping
Update app.py
Browse files
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 |
|