I'm getting `ModuleNotFoundError: No module named 'datasets.tasks'`
#2
by
felipemv
- opened
I'm getting:
File ".../.cache/huggingface/modules/datasets_modules/datasets/distil-whisper--peoples_speech-clean/6e90ea241dd7f43bc757e9acfa38bab4bd0cdcf27fd1603c81b1a825229e2b21/peoples_speech-clean.py", line 19, in <module>
from datasets.tasks import AutomaticSpeechRecognition
ModuleNotFoundError: No module named 'datasets.tasks'
With
root@e53bc114bdfc:/opt/conda/lib/python3.11/site-packages/datasets# python3 -m pip freeze | grep datas
datasets==3.0.1
After
python3 -m pip install --upgrade datasets==2.21.0
I got another error:
>>> dataset = load_dataset("distil-whisper/peoples_speech-clean", "clean")
Downloading data:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/opt/conda/lib/python3.11/site-packages/datasets/load.py", line 2628, in load_dataset
⋯
File "/opt/conda/lib/python3.11/site-packages/huggingface_hub/hf_file_system.py", line 540, in info
_raise_file_not_found(path, None)
File "/opt/conda/lib/python3.11/site-packages/huggingface_hub/hf_file_system.py", line 880, in _raise_file_not_found
raise FileNotFoundError(msg) from err
FileNotFoundError: datasets/MLCommons/peoples_speech@main/train/clean/clean_000000.tar
>>> # take the first sample of the validation set
>>> sample = dataset["validation"][0]
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
NameError: name 'dataset' is not defined
And then I just switched to different dataset.