This commit is contained in:
mrq 2023-03-06 21:32:20 +00:00
parent 7f98727ad5
commit 7b2aa51abc

View File

@ -542,7 +542,7 @@ class TextToSpeech:
if autoregressive_model is None:
autoregressive_model = self.autoregressive_model_path
elif autoregressive_model != self.autoregressive_model_path:
load_autoregressive_model(autoregressive_model)
self.load_autoregressive_model(autoregressive_model)
text_tokens = torch.IntTensor(self.tokenizer.encode(text)).unsqueeze(0).to(self.device)
text_tokens = F.pad(text_tokens, (0, 1)) # This may not be necessary.