Closed pprobst closed 1 year ago
@Aya-AlJafari can you look at this one?
If anyone is still looking through this issue, you might want to take a look at #1440
@Aya-AlJafari any updates?
@erogol The original issue (#3067) was people trying to use tts.tts_with_vc_to_file()
with XTTS and was "fixed" in #3108#3109. But XTTS has integrated VC and you can just do tts.tts_to_file(..., speaker_wav="...")
, there is no point in passing it through FreeVC afterwards. IMHO, #3109 should be reverted because it breaks tts.tts_with_vc_to_file()
for any model that doesn't have integrated VC, i.e. all models this method is meant for.
Perhaps, tts.tts_with_vc_to_file()
could throw a better error message when it's called for models that already support VC.
Describe the bug
Fix #3108 breaks
tts_with_vc_to_file
at least with VITS.See: https://github.com/coqui-ai/TTS/blob/6fef4f9067c0647258e0cd1d2998716565f59330/TTS/api.py#L463
By changing the line from:
self.tts_to_file(text=text, speaker=None, language=language, file_path=fp.name,speaker_wav=speaker_wav)
To its pre-0.19.1 version:
self.tts_to_file(text=text, speaker=None, language=language, file_path=fp.name)
The issue is solved.
Please take a look at the script below for reproduction.
To Reproduce
Clone the Coqui TTS repository and install the dependencies as specified in the README file. Then, run the following script from TTS's root directory, but replace
speaker_wav
with any audio file you have at hand:Expected behavior
The output audio file defined in
file_path
is generated, saying the sentence intext
with the voice cloned fromspeaker_wav
.Logs
Environment
Additional context
No response