sub-to-audio
sub-to-audio copied to clipboard
Faiseq doesn't work
Code:
from subtoaudio import SubToAudio
sub = SubToAudio(fairseq_language="ru")
subtitle = sub.subtitle("texts/1-1.srt")
sub.convert_to_audio(sub_data=subtitle)
(virtual) F:\whisper>python tts.py Traceback (most recent call last): File "F:\whisper\virtual\lib\site-packages\subtoaudio\subtoaudio.py", line 29, in init self.apitts = TTS(model_name=model_name, progress_bar=progress_bar, **kwargs).to(device) File "F:\whisper\virtual\lib\site-packages\TTS\api.py", line 81, in init self.load_tts_model_by_name(model_name, gpu) File "F:\whisper\virtual\lib\site-packages\TTS\api.py", line 195, in load_tts_model_by_name model_path, config_path, vocoder_path, vocoder_config_path, model_dir = self.download_model_by_name( File "F:\whisper\virtual\lib\site-packages\TTS\api.py", line 149, in download_model_by_name model_path, config_path, model_item = self.manager.download_model(model_name) File "F:\whisper\virtual\lib\site-packages\TTS\utils\manage.py", line 407, in download_model model_item, model_full_name, model, md5sum = self._set_model_item(model_name) File "F:\whisper\virtual\lib\site-packages\TTS\utils\manage.py", line 326, in _set_model_item model_full_name = f"{model_type}--{lang}--{dataset}--{model}" UnboundLocalError: local variable 'dataset' referenced before assignment
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "F:\whisper\tts.py", line 55, in
current version TTS have bug for fairseq model. downgrading tts to previos version maybe will solve the problem or wait for future update.
https://github.com/coqui-ai/TTS/issues/3361