SoniTranslate
SoniTranslate copied to clipboard
IndexError in text_to_speech.py when Processing Certain WAV Files
Hi, I ran into a problem when trying to manage a specific audio file. The trouble comes up exactly when the code tries to manage a WAV document called "XTTS/AUTOMATIC_SPEAKER_00.wav". Below is the traceback providing more information:
[INFO] >> XTTS/AUTOMATIC_SPEAKER_00.wav
Traceback (most recent call last):
File "/home/lapo/anaconda3/envs/sonitr/lib/python3.10/site-packages/gradio/queueing.py", line 495, in call_prediction
output = await route_utils.call_process_api(
...
File "/home/lapo/SoniTranslate/soni_translate/text_to_speech.py", line 474, in create_new_files_for_vc
if filtered_speaker[0]["tts_name"] == "XTTS/AUTOMATIC.wav":
IndexError: list index out of range
It seems like the code running the text-to-speech process has a bug. Specifically, when it makes new audio files for changing the voice, it tries to use an index for a list that does not exist. This causes an 'IndexError' error.
Could you please take a look into this issue? I'm unsure if the problem is with how the audio files are named or somewhere else in the steps used.
Thank you for your assistance on this project and the great work you've done so far.
Hi, I've made some adjustments that might resolve the problem