Spaces:
Paused
Paused
Update app.py
Browse files
app.py
CHANGED
|
@@ -81,9 +81,10 @@ def speak(text):
|
|
| 81 |
diffusion_conditioning = normalize_tacotron_mel(cond_mel)
|
| 82 |
mel = do_spectrogram_diffusion(diffusion, diffuser, latent, diffusion_conditioning, temperature=1.0).detach().cpu()
|
| 83 |
wav = vocos.decode(mel).detach().cpu().numpy()
|
| 84 |
-
|
| 85 |
-
|
| 86 |
-
|
|
|
|
| 87 |
|
| 88 |
with gr.Blocks() as demo:
|
| 89 |
gr.Markdown('# TTTS\n\nAn **unofficial** demo of [TTTS](https://github.com/adelacvg/ttts) based on XTTS. TTTS only supports Chinese.')
|
|
|
|
| 81 |
diffusion_conditioning = normalize_tacotron_mel(cond_mel)
|
| 82 |
mel = do_spectrogram_diffusion(diffusion, diffuser, latent, diffusion_conditioning, temperature=1.0).detach().cpu()
|
| 83 |
wav = vocos.decode(mel).detach().cpu().numpy()
|
| 84 |
+
return (24000, wav)
|
| 85 |
+
# with tempfile.NamedTemporaryFile(suffix='.wav', delete=False) as f:
|
| 86 |
+
# write(f.name, data=wav, rate=24000)
|
| 87 |
+
# return f.name
|
| 88 |
|
| 89 |
with gr.Blocks() as demo:
|
| 90 |
gr.Markdown('# TTTS\n\nAn **unofficial** demo of [TTTS](https://github.com/adelacvg/ttts) based on XTTS. TTTS only supports Chinese.')
|