raise RuntimeError("Failed to load audio from {}".format(filepath))
See original GitHub issueSystem Info
i want to run
run_speech_recognition_ctc.py
but i got the error when run the Single GPU CTC script.
python run_speech_recognition_ctc.py \ --dataset_name="common_voice" \ --model_name_or_path="facebook/wav2vec2-large-xlsr-53" \ --dataset_config_name="tr" \ --output_dir="./wav2vec2-common_voice-tr-demo" \ --overwrite_output_dir \ --num_train_epochs="15" \ --per_device_train_batch_size="16" \ --gradient_accumulation_steps="2" \ --learning_rate="3e-4" \ --warmup_steps="500" \ --evaluation_strategy="steps" \ --text_column_name="sentence" \ --length_column_name="input_length" \ --save_steps="400" \ --eval_steps="100" \ --layerdrop="0.0" \ --save_total_limit="3" \ --freeze_feature_encoder \ --gradient_checkpointing \ --chars_to_ignore , ? . ! - \; \: \" “ % ‘ ” � \ --fp16 \ --group_by_length \ --push_to_hub \ --do_train --do_eval
The ERROR :
raise RuntimeError("Failed to load audio from {}".format(filepath))
RuntimeError: Failed to load audio from /root/.cache/huggingface/datasets/downloads/extracted``/05be0c29807a73c9b099873d2f5975dae6d05e9f7d577458a2466ecb9a2b0c6b/cv-corpus-6.1-2020-12-11/tr/clips``/common_voice_tr_17346025.mp3
Who can help?
Information
- The official example scripts
- My own modified scripts
Tasks
- An officially supported task in the
examples
folder (such as GLUE/SQuAD, …) - My own task or dataset (give details below)
Reproduction
i just run the steps written on example folder
Expected behavior
i just want to get the result
Issue Analytics
- State:
- Created a year ago
- Comments:10 (5 by maintainers)
Top GitHub Comments
Hi @mehrdad78, thanks for reporting (and thanks @LysandreJik for drawing my attention to this).
I have manually checked the TAR file, its content and specifically the MP3 file raising the error:
cv-corpus-6.1-2020-12-11/ru/clips/common_voice_ru_18849051.mp3
I can load it without any problem (our Datasets library, under the hood uses
torchaudio
for mp3 files):This makes me think that maybe the source of your issue is
sox
. This is a non-Python dependency that must be installed manually using your operating system package manager, e.g.You have the installation instruction of Datasets with support for Audio in our docs: Installation > Audio
Have you ever encountered this error @albertvillanova @mariosasko ?