From 131bc0cfc0c9699439628fa1e517793291ad5eb3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Eren=20G=C3=B6lge?= Date: Fri, 7 Jan 2022 15:33:24 +0000 Subject: [PATCH] =?UTF-8?q?Fix=20synthesis.py=20=F0=9F=94=A7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- TTS/tts/utils/synthesis.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/TTS/tts/utils/synthesis.py b/TTS/tts/utils/synthesis.py index 65dcc1ad..e2d9c113 100644 --- a/TTS/tts/utils/synthesis.py +++ b/TTS/tts/utils/synthesis.py @@ -113,8 +113,6 @@ def synthesis( text, CONFIG, use_cuda, - ap, - tokenizer, speaker_id=None, style_wav=None, use_griffin_lim=False, @@ -166,10 +164,10 @@ def synthesis( if isinstance(style_wav, dict): style_mel = style_wav else: - style_mel = compute_style_mel(style_wav, ap, cuda=use_cuda) + style_mel = compute_style_mel(style_wav, model.ap, cuda=use_cuda) # convert text to sequence of token IDs text_inputs = np.asarray( - tokenizer.text_to_ids(text), + model.tokenizer.text_to_ids(text), dtype=np.int32, ) # pass tensors to backend