Spaces:
Runtime error
Runtime error
Serhiy Stetskovych
commited on
Commit
·
fffaa2a
1
Parent(s):
2ccf6b5
Move to device text.
Browse files
app.py
CHANGED
@@ -166,12 +166,12 @@ def synthesise(text, temperature, speed):
|
|
166 |
text_processed = process_text(text.strip(), device)
|
167 |
|
168 |
output = model.synthesise(
|
169 |
-
text_processed["x"],
|
170 |
-
text_processed["x_lengths"],
|
171 |
n_timesteps=40,
|
172 |
temperature=temperature,
|
173 |
length_scale=1/speed,
|
174 |
-
prompt=
|
175 |
)
|
176 |
waveform = to_waveform(output["mel"], vocoder, denoiser)
|
177 |
|
|
|
166 |
text_processed = process_text(text.strip(), device)
|
167 |
|
168 |
output = model.synthesise(
|
169 |
+
text_processed["x"].to(device),
|
170 |
+
text_processed["x_lengths"].to(device),
|
171 |
n_timesteps=40,
|
172 |
temperature=temperature,
|
173 |
length_scale=1/speed,
|
174 |
+
prompt=normalize(prompt, model.mel_mean, model.mel_std)
|
175 |
)
|
176 |
waveform = to_waveform(output["mel"], vocoder, denoiser)
|
177 |
|