Can't load the dataset after datasets v4.0 release

#17
by nikita-savelyev-intel - opened

After the release of datasets package v4.0 it's no longer possible to load openslr/librispeech_asr dataset. The reason is that custom scripts are no longer supported: https://github.com/huggingface/datasets/releases/tag/4.0.0

import datasets
dataset_id = "openslr/librispeech_asr"
dataset = datasets.load_dataset(dataset_id, "clean", split="validation", streaming=True)
# RuntimeError: Dataset scripts are no longer supported, but found librispeech_asr.py
OpenSLR org

Hi ! it would be cool to convert this dataset to Parquet. This will make it work for datasets>=4.0, enable the Dataset Viewer and make it more reliable to load/stream (currently it uses a loading script in python and those are known for having issues sometimes)

using datasets==3.6.0, here is the command to convert it and open a Pull Request:

datasets-cli convert_to_parquet openslr/librispeech_asr --trust_remote_code

It turns out that there is already a PR converting this dataset to parquet format: https://huggingface.co/datasets/openslr/librispeech_asr/discussions/10 . The new dataset can be loaded by providing revision="refs/convert/parquet" to load_dataset function.

Nevertheless, would be great to merge this PR to avoid the workaround.

OpenSLR org

Ah great ! I managed to merge this branch :)

The dataset is now compatible with datasets v4.0 - thanks !

Sign up or log in to comment