Spaces:
Runtime error
Runtime error
Commit
•
afb20ae
1
Parent(s):
4282661
Update app.py
Browse files
app.py
CHANGED
@@ -165,6 +165,8 @@ def generate_audio(text_prompt, audio_length_in_s=10.0, play_steps_in_s=2.0):
|
|
165 |
|
166 |
set_seed(0)
|
167 |
for new_audio in streamer:
|
|
|
|
|
168 |
yield (sampling_rate, new_audio)
|
169 |
|
170 |
|
|
|
165 |
|
166 |
set_seed(0)
|
167 |
for new_audio in streamer:
|
168 |
+
print(f"Sample of length: {round(new_audio.shape[0] / sampling_rate, 2)} seconds")
|
169 |
+
new_audio = (new_audio * max_range).astype(np.int16)
|
170 |
yield (sampling_rate, new_audio)
|
171 |
|
172 |
|