Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

list index out of range error right after click training. #42

Open
Maki9009 opened this issue Jul 31, 2024 · 2 comments
Open

list index out of range error right after click training. #42

Maki9009 opened this issue Jul 31, 2024 · 2 comments

Comments

@Maki9009
Copy link

when i run the training i get hit with this,

Traceback (most recent call last):
  File "E:\RVC\xtts-finetune-webui\xtts_demo.py", line 380, in train_model
    speaker_xtts_path,config_path, original_xtts_checkpoint, vocab_file, exp_path, speaker_wav = train_gpt(custom_model,version,language, num_epochs, batch_size, grad_acumm, train_csv, eval_csv, output_path=output_path, max_audio_length=max_audio_length)
  File "E:\RVC\xtts-finetune-webui\utils\gpt_train.py", line 177, in train_gpt
    train_samples, eval_samples = load_tts_samples(
  File "E:\RVC\xtts-finetune-webui\venv\lib\site-packages\TTS\tts\datasets\__init__.py", line 132, in load_tts_samples
    meta_data_eval = formatter(root_path, meta_file_val, ignored_speakers=ignored_speakers)
  File "E:\RVC\xtts-finetune-webui\venv\lib\site-packages\TTS\tts\datasets\formatters.py", line 74, in coqui
    assert all(x in metadata[0] for x in ["audio_file", "text"])
  File "E:\RVC\xtts-finetune-webui\venv\lib\site-packages\TTS\tts\datasets\formatters.py", line 74, in <genexpr>
    assert all(x in metadata[0] for x in ["audio_file", "text"])
IndexError: list index out of range
Traceback (most recent call last):
  File "E:\RVC\xtts-finetune-webui\venv\lib\site-packages\gradio\queueing.py", line 489, in call_prediction
    output = await route_utils.call_process_api(
  File "E:\RVC\xtts-finetune-webui\venv\lib\site-packages\gradio\route_utils.py", line 232, in call_process_api
    output = await app.get_blocks().process_api(
  File "E:\RVC\xtts-finetune-webui\venv\lib\site-packages\gradio\blocks.py", line 1570, in process_api
    data = self.postprocess_data(fn_index, result["prediction"], state)
  File "E:\RVC\xtts-finetune-webui\venv\lib\site-packages\gradio\blocks.py", line 1397, in postprocess_data
    self.validate_outputs(fn_index, predictions)  # type: ignore
  File "E:\RVC\xtts-finetune-webui\venv\lib\site-packages\gradio\blocks.py", line 1371, in validate_outputs
    raise ValueError(
ValueError: An event handler (train_model) didn't receive enough output values (needed: 6, received: 5).
Wanted outputs:
    [label, textbox, textbox, textbox, textbox, textbox]
Received outputs:
    ["The training was interrupted due an error !! Please check the console to check the full error message!
 Error summary: Traceback (most recent call last):
  File "E:\RVC\xtts-finetune-webui\xtts_demo.py", line 380, in train_model
    speaker_xtts_path,config_path, original_xtts_checkpoint, vocab_file, exp_path, speaker_wav = train_gpt(custom_model,version,language, num_epochs, batch_size, grad_acumm, train_csv, eval_csv, output_path=output_path, max_audio_length=max_audio_length)
  File "E:\RVC\xtts-finetune-webui\utils\gpt_train.py", line 177, in train_gpt
    train_samples, eval_samples = load_tts_samples(
  File "E:\RVC\xtts-finetune-webui\venv\lib\site-packages\TTS\tts\datasets\__init__.py", line 132, in load_tts_samples
    meta_data_eval = formatter(root_path, meta_file_val, ignored_speakers=ignored_speakers)
  File "E:\RVC\xtts-finetune-webui\venv\lib\site-packages\TTS\tts\datasets\formatters.py", line 74, in coqui
    assert all(x in metadata[0] for x in ["audio_file", "text"])
  File "E:\RVC\xtts-finetune-webui\venv\lib\site-packages\TTS\tts\datasets\formatters.py", line 74, in <genexpr>
    assert all(x in metadata[0] for x in ["audio_file", "text"])
IndexError: list index out of range
", "", "", "", ""]
@FassihFayyaz
Copy link

Getting the same error also tried reinstalling and stuff.

@FassihFayyaz
Copy link

@Maki9009 Okay so i found a fix the metadata files that whisper model was creating had empty lines mainly metadata_eval.csv in the directory finetune_model/dataset/.

To fix this error you need to delete the dataset folder and try creating the dataset again using different whisper models in my case large and medium did work while the other models were having empty lines into the metadata dataset files.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants