Datasets:
Bug in loading this dataset
#3
by
mfatehi
- opened
When I want to load this dataset, I get:
Traceback (most recent call last):
File "/home/ubuntu/.local/lib/python3.10/site-packages/datasets/builder.py", line 1726, in _prepare_split_single
for key, record in generator:
File "/home/ubuntu/.cache/huggingface/modules/datasets_modules/datasets/SLPL--naab/ab7bc25c8bf01ceff429f5c0f29814c8bf8f9601ebdc0896e70c844fed1f9e76/naab.py", line 126, in _generate_examples
for key, row in enumerate(f):
File "/usr/lib/python3.10/codecs.py", line 322, in decode
(result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xd8 in position 0: unexpected end of data
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/home/ubuntu/get_corpus.py", line 6, in <module>
dataset = load_dataset("SLPL/naab", download_config=None)
File "/home/ubuntu/.local/lib/python3.10/site-packages/datasets/load.py", line 2549, in load_dataset
builder_instance.download_and_prepare(
File "/home/ubuntu/.local/lib/python3.10/site-packages/datasets/builder.py", line 1005, in download_and_prepare
self._download_and_prepare(
File "/home/ubuntu/.local/lib/python3.10/site-packages/datasets/builder.py", line 1767, in _download_and_prepare
super()._download_and_prepare(
File "/home/ubuntu/.local/lib/python3.10/site-packages/datasets/builder.py", line 1100, in _download_and_prepare
self._prepare_split(split_generator, **prepare_split_kwargs)
File "/home/ubuntu/.local/lib/python3.10/site-packages/datasets/builder.py", line 1605, in _prepare_split
for job_id, done, content in self._prepare_split_single(
File "/home/ubuntu/.local/lib/python3.10/site-packages/datasets/builder.py", line 1762, in _prepare_split_single
raise DatasetGenerationError("An error occurred while generating the dataset") from e
datasets.exceptions.DatasetGenerationError: An error occurred while generating the dataset
code:
from datasets import load_dataset
dataset = load_dataset("SLPL/naab", trust_remote_code=True, num_proc=64)
datasets version: 2.16.1
python version: 3.10.12
OS: Ubuntu 22.04.3 LTS