id
int64
599M
3.29B
url
stringlengths
58
61
html_url
stringlengths
46
51
number
int64
1
7.72k
title
stringlengths
1
290
state
stringclasses
2 values
comments
int64
0
70
created_at
timestamp[s]date
2020-04-14 10:18:02
2025-08-05 09:28:51
updated_at
timestamp[s]date
2020-04-27 16:04:17
2025-08-05 11:39:56
closed_at
timestamp[s]date
2020-04-14 12:01:40
2025-08-01 05:15:45
user_login
stringlengths
3
26
labels
listlengths
0
4
body
stringlengths
0
228k
is_pull_request
bool
2 classes
1,362,193,587
https://api.github.com/repos/huggingface/datasets/issues/4930
https://github.com/huggingface/datasets/pull/4930
4,930
Add cc-by-nc-2.0 to list of licenses
closed
5
2022-09-05T15:37:32
2022-09-06T16:43:32
2022-09-05T17:01:04
albertvillanova
[]
This PR adds the `cc-by-nc-2.0` to the list of licenses because it is required by `scifact` dataset: https://github.com/allenai/scifact/blob/master/LICENSE.md
true
1,361,508,366
https://api.github.com/repos/huggingface/datasets/issues/4929
https://github.com/huggingface/datasets/pull/4929
4,929
Fixes a typo in loading documentation
closed
0
2022-09-05T07:18:54
2022-09-06T02:11:03
2022-09-05T13:06:38
sighingnow
[]
As show in the [documentation page](https://huggingface.co/docs/datasets/loading) here the `"tr"in` should be `"train`. ![image](https://user-images.githubusercontent.com/7144772/188390445-e1f04d54-e3e3-4762-8686-63ecbe4087e5.png)
true
1,360,941,172
https://api.github.com/repos/huggingface/datasets/issues/4928
https://github.com/huggingface/datasets/pull/4928
4,928
Add ability to read-write to SQL databases.
closed
14
2022-09-03T19:09:08
2022-10-03T16:34:36
2022-10-03T16:32:28
Dref360
[]
Fixes #3094 Add ability to read/write to SQLite files and also read from any SQL database supported by SQLAlchemy. I didn't add SQLAlchemy as a dependence as it is fairly big and it remains optional. I also recorded a Loom to showcase the feature. https://www.loom.com/share/f0e602c2de8a46f58bca4b43333d541f
true
1,360,428,139
https://api.github.com/repos/huggingface/datasets/issues/4927
https://github.com/huggingface/datasets/pull/4927
4,927
fix BLEU metric card
closed
0
2022-09-02T17:00:56
2022-09-09T16:28:15
2022-09-09T16:28:15
antoniolanza1996
[]
I've fixed some typos in BLEU metric card.
true
1,360,384,484
https://api.github.com/repos/huggingface/datasets/issues/4926
https://github.com/huggingface/datasets/pull/4926
4,926
Dataset infos in yaml
closed
6
2022-09-02T16:10:05
2024-05-04T14:52:50
2022-10-03T09:11:12
lhoestq
[ "dataset contribution" ]
To simplify the addition of new datasets, we'd like to have the dataset infos in the YAML and deprecate the dataset_infos.json file. YAML is readable and easy to edit, and the YAML metadata of the readme already contain dataset metadata so we would have everything in one place. To be more specific, I moved these fields from DatasetInfo to the YAML: - config_name (if there are several configs) - download_size - dataset_size - features - splits Here is what I ended up with for `squad`: ```yaml dataset_info: features: - name: id dtype: string - name: title dtype: string - name: context dtype: string - name: question dtype: string - name: answers sequence: - name: text dtype: string - name: answer_start dtype: int32 splits: - name: train num_bytes: 79346360 num_examples: 87599 - name: validation num_bytes: 10473040 num_examples: 10570 config_name: plain_text download_size: 35142551 dataset_size: 89819400 ``` and it can be a list if there are several configs I already did the change for `conll2000` and `crime_and_punish` as an example. ## Implementation details ### Load/Read This is done via `DatasetInfosDict.write_to_directory/from_directory` I had to implement a custom the YAML export logic for `SplitDict`, `Version` and `Features`. The first two are trivial, but the logic for `Features` is more complicated, because I added a simplification step (or the YAML would be too long and less readable): it's just a formatting step to remove unnecessary nesting of YAML data. ### Other changes I had to update the DatasetModule factories to also download the README.md alongside the dataset scripts/data files, and not just the dataset_infos.json ## YAML validation I removed the old validation code that was in metadata.py, now we can just use the Hub YAML validation ## Datasets-cli The `datasets-cli test --save_infos` command now creates a README.md file with the dataset_infos in it, instead of a datasets_infos.json file ## Backward compatibility `dataset_infos.json` files are still supported and loaded if they exist to have full backward compatibility. Though I removed the unnecessary keys when the value is the default (like all the `id: null` from the Value feature types) to make them easier to read. ## TODO - [x] add comments - [x] tests - [x] document the new YAML fields - [x] try to reload the new dataset_infos.json file content with an old version of `datasets` ## EDITS - removed "config_name" when there's only one config - removed "version" for now (?), because it's not useful in general - renamed the yaml field "dataset_info" instead of "dataset_infos", since it only has one by default (and because "infos" is not english) Fix https://github.com/huggingface/datasets/issues/4876 and fix #2773
true
1,360,007,616
https://api.github.com/repos/huggingface/datasets/issues/4925
https://github.com/huggingface/datasets/pull/4925
4,925
Add note about loading image / audio files to docs
closed
9
2022-09-02T10:31:58
2022-09-26T12:21:30
2022-09-23T13:59:07
lewtun
[]
This PR adds a small note about how to load image / audio datasets that have multiple splits in their dataset structure. Related forum thread: https://discuss.huggingface.co/t/loading-train-and-test-splits-with-audiofolder/22447 cc @NielsRogge
true
1,358,611,513
https://api.github.com/repos/huggingface/datasets/issues/4924
https://github.com/huggingface/datasets/issues/4924
4,924
Concatenate_datasets loads everything into RAM
closed
0
2022-09-01T10:25:17
2022-09-01T11:50:54
2022-09-01T11:50:54
louisdeneve
[ "bug" ]
## Describe the bug When loading the datasets seperately and saving them on disk, I want to concatenate them. But `concatenate_datasets` is filling up my RAM and the process gets killed. Is there a way to prevent this from happening or is this intended behaviour? Thanks in advance ## Steps to reproduce the bug ```python gcs = gcsfs.GCSFileSystem(project='project') datasets = [load_from_disk(f'path/to/slice/of/data/{i}', fs=gcs, keep_in_memory=False) for i in range(10)] dataset = concatenate_datasets(datasets) ``` ## Expected results A concatenated dataset which is stored on my disk. ## Actual results Concatenated dataset gets loaded into RAM and overflows it which gets the process killed. ## Environment info <!-- You can run the command `datasets-cli env` and copy-and-paste its output below. --> - `datasets` version: 2.4.0 - Platform: Linux-4.19.0-21-cloud-amd64-x86_64-with-glibc2.10 - Python version: 3.8.13 - PyArrow version: 8.0.1 - Pandas version: 1.4.3
false
1,357,735,287
https://api.github.com/repos/huggingface/datasets/issues/4923
https://github.com/huggingface/datasets/pull/4923
4,923
decode mp3 with librosa if torchaudio is > 0.12 as a temporary workaround
closed
5
2022-08-31T18:57:59
2022-11-02T11:54:33
2022-09-20T13:12:52
polinaeterna
[]
`torchaudio>0.12` fails with decoding mp3 files if `ffmpeg<4`. currently we ask users to downgrade torchaudio, but sometimes it's not possible as torchaudio version is binded to torch version. as a temporary workaround we can decode mp3 with librosa (though it 60 times slower, at least it works) another option would be to ask users to install the required version of `ffmpeg`, but is non-trivial on colab: it's not in apt packages in ubuntu 18 and `conda` is not preinstalled (with `conda` it would be easily installable) - [x] decode with torchaudio anyway if the version of ffmpeg is correct? it's 60 times faster - [x] tests - [x] DO NOT FORGET to get back all the tests see https://github.com/huggingface/datasets/issues/4776 and https://github.com/huggingface/datasets/issues/3663#issuecomment-1225797165 (there is a Colab notebook to reproduce the error)
true
1,357,684,018
https://api.github.com/repos/huggingface/datasets/issues/4922
https://github.com/huggingface/datasets/issues/4922
4,922
I/O error on Google Colab in streaming mode
closed
0
2022-08-31T18:08:26
2022-08-31T18:15:48
2022-08-31T18:15:48
jotterbach
[ "bug" ]
## Describe the bug When trying to load a streaming dataset in Google Colab the loading fails with an I/O error ## Steps to reproduce the bug ```python import datasets from datasets import load_dataset hf_ds = load_dataset(path='wmt19', name='cs-en', streaming=True, split=datasets.Split.VALIDATION) list(hf_ds.take(5)) ``` ## Expected results It should load five data points ## Actual results ``` --------------------------------------------------------------------------- ValueError Traceback (most recent call last) [<ipython-input-13-7b5b8b1e7e58>](https://localhost:8080/#) in <module> 2 from datasets import load_dataset 3 hf_ds = load_dataset(path='wmt19', name='cs-en', streaming=True, split=datasets.Split.VALIDATION) ----> 4 list(hf_ds.take(5)) 6 frames [/usr/local/lib/python3.7/dist-packages/datasets/iterable_dataset.py](https://localhost:8080/#) in __iter__(self) 716 717 def __iter__(self): --> 718 for key, example in self._iter(): 719 if self.features: 720 # `IterableDataset` automatically fills missing columns with None. [/usr/local/lib/python3.7/dist-packages/datasets/iterable_dataset.py](https://localhost:8080/#) in _iter(self) 706 else: 707 ex_iterable = self._ex_iterable --> 708 yield from ex_iterable 709 710 def _iter_shard(self, shard_idx: int): [/usr/local/lib/python3.7/dist-packages/datasets/iterable_dataset.py](https://localhost:8080/#) in __iter__(self) 582 583 def __iter__(self): --> 584 yield from islice(self.ex_iterable, self.n) 585 586 def shuffle_data_sources(self, generator: np.random.Generator) -> "TakeExamplesIterable": [/usr/local/lib/python3.7/dist-packages/datasets/iterable_dataset.py](https://localhost:8080/#) in __iter__(self) 110 111 def __iter__(self): --> 112 yield from self.generate_examples_fn(**self.kwargs) 113 114 def shuffle_data_sources(self, generator: np.random.Generator) -> "ExamplesIterable": [~/.cache/huggingface/modules/datasets_modules/datasets/wmt19/aeadcbe9f1cbf9969e603239d33d3e43670cf250c1158edf74f5f6e74d4f21d0/wmt_utils.py](https://localhost:8080/#) in _generate_examples(self, split_subsets, extraction_map, with_translation) 845 raise ValueError("Invalid number of files: %d" % len(files)) 846 --> 847 for sub_key, ex in sub_generator(*sub_generator_args): 848 if not all(ex.values()): 849 continue [~/.cache/huggingface/modules/datasets_modules/datasets/wmt19/aeadcbe9f1cbf9969e603239d33d3e43670cf250c1158edf74f5f6e74d4f21d0/wmt_utils.py](https://localhost:8080/#) in _parse_parallel_sentences(f1, f2, filename1, filename2) 923 l2_sentences, l2 = parse_file(f2_i, filename2) 924 --> 925 for line_id, (s1, s2) in enumerate(zip(l1_sentences, l2_sentences)): 926 key = f"{f_id}/{line_id}" 927 yield key, {l1: s1, l2: s2} [~/.cache/huggingface/modules/datasets_modules/datasets/wmt19/aeadcbe9f1cbf9969e603239d33d3e43670cf250c1158edf74f5f6e74d4f21d0/wmt_utils.py](https://localhost:8080/#) in gen() 895 896 def gen(): --> 897 with open(path, encoding="utf-8") as f: 898 for line in f: 899 seg_match = re.match(seg_re, line) ValueError: I/O operation on closed file. ``` ## Environment info Copy-and-paste the text below in your GitHub issue. - `datasets` version: 2.4.0 - Platform: Linux-5.4.188+-x86_64-with-Ubuntu-18.04-bionic - Python version: 3.7.13 - PyArrow version: 9.0.0. (the same error happened with PyArrow version 6.0.0) - Pandas version: 1.3.5
false
1,357,609,003
https://api.github.com/repos/huggingface/datasets/issues/4921
https://github.com/huggingface/datasets/pull/4921
4,921
Fix missing tags in dataset cards
closed
1
2022-08-31T16:52:27
2022-09-22T14:34:11
2022-09-01T05:04:53
albertvillanova
[]
Fix missing tags in dataset cards: - eraser_multi_rc - hotpot_qa - metooma - movie_rationales - qanta - quora - quoref - race - ted_hrlr - ted_talks_iwslt This PR partially fixes the missing tags in dataset cards. Subsequent PRs will follow to complete this task. Related to: - #4833 - #4891 - #4896 - #4908
true
1,357,564,589
https://api.github.com/repos/huggingface/datasets/issues/4920
https://github.com/huggingface/datasets/issues/4920
4,920
Unable to load local tsv files through load_dataset method
closed
1
2022-08-31T16:13:39
2022-09-01T05:31:30
2022-09-01T05:31:30
DataNoob0723
[ "bug" ]
## Describe the bug Unable to load local tsv files through load_dataset method. ## Steps to reproduce the bug ```python # Sample code to reproduce the bug data_files = { 'train': 'train.tsv', 'test': 'test.tsv' } raw_datasets = load_dataset('tsv', data_files=data_files) ## Expected results I am pretty sure the data files exist in the current directory. The above code should load them as Datasets, but threw exceptions. ## Actual results --------------------------------------------------------------------------- FileNotFoundError Traceback (most recent call last) [<ipython-input-9-24207899c1af>](https://localhost:8080/#) in <module> ----> 1 raw_datasets = load_dataset('tsv', data_files='train.tsv') 2 frames [/usr/local/lib/python3.7/dist-packages/datasets/load.py](https://localhost:8080/#) in dataset_module_factory(path, revision, download_config, download_mode, dynamic_modules_path, data_dir, data_files, **download_kwargs) 1244 f"Couldn't find a dataset script at {relative_to_absolute_path(combined_path)} or any data file in the same directory. " 1245 f"Couldn't find '{path}' on the Hugging Face Hub either: {type(e1).__name__}: {e1}" -> 1246 ) from None 1247 raise e1 from None 1248 else: FileNotFoundError: Couldn't find a dataset script at /content/tsv/tsv.py or any data file in the same directory. Couldn't find 'tsv' on the Hugging Face Hub either: FileNotFoundError: Couldn't find file at https://raw.githubusercontent.com/huggingface/datasets/main/datasets/tsv/tsv.py ## Environment info <!-- You can run the command `datasets-cli env` and copy-and-paste its output below. --> - `datasets` version: 2.4.0 - Platform: Linux-5.4.188+-x86_64-with-Ubuntu-18.04-bionic - Python version: 3.7.13 - PyArrow version: 6.0.1 - Pandas version: 1.3.5
false
1,357,441,599
https://api.github.com/repos/huggingface/datasets/issues/4919
https://github.com/huggingface/datasets/pull/4919
4,919
feat: improve error message on Keys mismatch. closes #4917
closed
2
2022-08-31T14:41:36
2022-09-05T08:46:01
2022-09-05T08:43:33
PaulLerner
[]
Hi @lhoestq what do you think? Let me give you a code sample: ```py >>> import datasets >>> foo = datasets.Dataset.from_dict({'foo':[0,1], 'bar':[2,3]}) >>> foo.save_to_disk('foo') # edit foo/dataset_info.json e.g. rename the 'foo' feature to 'baz' >>> datasets.load_from_disk('foo') --------------------------------------------------------------------------- ValueError Traceback (most recent call last) <ipython-input-2-4863e606b330> in <module> ----> 1 datasets.load_from_disk('foo') ~/code/datasets/src/datasets/load.py in load_from_disk(dataset_path, fs, keep_in_memory) 1851 raise FileNotFoundError(f"Directory {dataset_path} not found") 1852 if fs.isfile(Path(dest_dataset_path, config.DATASET_INFO_FILENAME).as_posix()): -> 1853 return Dataset.load_from_disk(dataset_path, fs, keep_in_memory=keep_in_memory) 1854 elif fs.isfile(Path(dest_dataset_path, config.DATASETDICT_JSON_FILENAME).as_posix()): 1855 return DatasetDict.load_from_disk(dataset_path, fs, keep_in_memory=keep_in_memory) ~/code/datasets/src/datasets/arrow_dataset.py in load_from_disk(dataset_path, fs, keep_in_memory) 1230 info=dataset_info, 1231 split=split, -> 1232 fingerprint=state["_fingerprint"], 1233 ) 1234 ~/code/datasets/src/datasets/arrow_dataset.py in __init__(self, arrow_table, info, split, indices_table, fingerprint) 687 self.info.features = inferred_features 688 else: # make sure the nested columns are in the right order --> 689 self.info.features = self.info.features.reorder_fields_as(inferred_features) 690 691 # Infer fingerprint if None ~/code/datasets/src/datasets/features/features.py in reorder_fields_as(self, other) 1771 return source 1772 -> 1773 return Features(recursive_reorder(self, other)) 1774 1775 def flatten(self, max_depth=16) -> "Features": ~/code/datasets/src/datasets/features/features.py in recursive_reorder(source, target, stack) 1760 f"{source.keys()-target.keys()} are missing from dataset.arrow " 1761 f"and {target.keys()-source.keys()} are missing from dataset_info.json"+stack_position) -> 1762 raise ValueError(message) 1763 return {key: recursive_reorder(source[key], target[key], stack + f".{key}") for key in target} 1764 elif isinstance(source, list): ValueError: Keys mismatch: between {'baz': Value(dtype='int64', id=None), 'bar': Value(dtype='int64', id=None)} (dataset_info.json) and {'foo': Value(dtype='int64', id=None), 'bar': Value(dtype='int64', id=None)} (inferred from dataset.arrow). {'baz'} are missing from dataset.arrow and {'foo'} are missing from dataset_info.json ```
true
1,357,242,757
https://api.github.com/repos/huggingface/datasets/issues/4918
https://github.com/huggingface/datasets/issues/4918
4,918
Dataset Viewer issue for pysentimiento/spanish-targeted-sentiment-headlines
closed
2
2022-08-31T12:09:07
2022-09-05T21:36:34
2022-09-05T16:32:44
finiteautomata
[ "dataset-viewer" ]
### Link https://huggingface.co/datasets/pysentimiento/spanish-targeted-sentiment-headlines ### Description After moving the dataset from my user (`finiteautomata`) to the `pysentimiento` organization, the dataset viewer says that it doesn't exist. ### Owner _No response_
false
1,357,193,841
https://api.github.com/repos/huggingface/datasets/issues/4917
https://github.com/huggingface/datasets/issues/4917
4,917
Keys mismatch: make error message more informative
closed
4
2022-08-31T11:24:34
2022-09-05T08:43:38
2022-09-05T08:43:38
PaulLerner
[ "enhancement", "good first issue" ]
**Is your feature request related to a problem? Please describe.** When loading a dataset from disk with a defect in its `dataset_info.json` describing its features (I don’t know when/why/how this happens but it deserves its own issue), you will get an error message like: `ValueError: Keys mismatch: between {'bar': Value(dtype='int64', id=None)} and {'foo': Value(dtype='int64', id=None)}` Which is fine when you have only a few features like in the example but it gets very hard to read when you have a lot of features in your dataset. **Describe the solution you'd like** The error message should give the difference between the features (what keys are in A but missing in B and vice-versa). It should also tell which keys are inferred from `dataset.arrow` and which come from `dataset_info.json`. Willing to help :)
false
1,357,076,940
https://api.github.com/repos/huggingface/datasets/issues/4916
https://github.com/huggingface/datasets/issues/4916
4,916
Apache Beam unable to write the downloaded wikipedia dataset
closed
1
2022-08-31T09:39:25
2022-08-31T10:53:19
2022-08-31T10:53:19
Shilpac20
[ "bug" ]
## Describe the bug Hi, I am currently trying to download wikipedia dataset using load_dataset("wikipedia", language="aa", date="20220401", split="train",beam_runner='DirectRunner'). However, I end up in getting filenotfound error. I get this error for any language I try to download. It downloads the file but while saving it in hugging face cache it fails to write. This happens for any available date of any language in wikipedia dump. I had raised another issue earlier #4915 but probably was not that clear and the solution provider misunderstood my problem. Hence raising one more issue. Any help is appreciated. ## Steps to reproduce the bug ```python from datasets import load_dataset load_dataset("wikipedia", language="aa", date="20220401", split="train",beam_runner='DirectRunner') ``` ## Expected results to load the dataset ## Actual results I am pasting the error trace here: Downloading builder script: 35.9kB [00:00, ?B/s] Downloading metadata: 30.4kB [00:00, 1.94MB/s] Using custom data configuration 20220401.aa-date=20220401,language=aa Downloading and preparing dataset wikipedia/20220401.aa to C:\Users\Shilpa.cache\huggingface\datasets\wikipedia\20220401.aa-date=20220401,language=aa\2.0.0\aa542ed919df55cc5d3347f42dd4521d05ca68751f50dbc32bae2a7f1e167559... Downloading data: 100%|████████████████████████████████████████████████████████████| 11.1k/11.1k [00:00<00:00, 712kB/s] Downloading data files: 100%|████████████████████████████████████████████████████████████| 1/1 [00:02<00:00, 2.82s/it] Extracting data files: 100%|█████████████████████████████████████████████████████████████████████| 1/1 [00:00<?, ?it/s] Downloading data: 100%|███████████████████████████████████████████████████████████| 35.6k/35.6k [00:00<00:00, 84.3kB/s] Downloading data files: 100%|████████████████████████████████████████████████████████████| 1/1 [00:02<00:00, 2.93s/it] Traceback (most recent call last): File "apache_beam\runners\common.py", line 1417, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 837, in apache_beam.runners.common.PerWindowInvoker.invoke_process File "apache_beam\runners\common.py", line 981, in apache_beam.runners.common.PerWindowInvoker._invoke_process_per_window File "apache_beam\runners\common.py", line 1571, in apache_beam.runners.common._OutputHandler.handle_process_outputs File "G:\Python3.7\lib\site-packages\apache_beam\io\iobase.py", line 1193, in process self.writer = self.sink.open_writer(init_result, str(uuid.uuid4())) File "G:\Python3.7\lib\site-packages\apache_beam\options\value_provider.py", line 193, in _f return fnc(self, *args, **kwargs) File "G:\Python3.7\lib\site-packages\apache_beam\io\filebasedsink.py", line 202, in open_writer return FileBasedSinkWriter(self, writer_path) File "G:\Python3.7\lib\site-packages\apache_beam\io\filebasedsink.py", line 419, in init self.temp_handle = self.sink.open(temp_shard_path) File "G:\Python3.7\lib\site-packages\apache_beam\io\parquetio.py", line 553, in open self._file_handle = super().open(temp_path) File "G:\Python3.7\lib\site-packages\apache_beam\options\value_provider.py", line 193, in _f return fnc(self, *args, **kwargs) File "G:\Python3.7\lib\site-packages\apache_beam\io\filebasedsink.py", line 139, in open temp_path, self.mime_type, self.compression_type) File "G:\Python3.7\lib\site-packages\apache_beam\io\filesystems.py", line 224, in create return filesystem.create(path, mime_type, compression_type) File "G:\Python3.7\lib\site-packages\apache_beam\io\localfilesystem.py", line 163, in create return self._path_open(path, 'wb', mime_type, compression_type) File "G:\Python3.7\lib\site-packages\apache_beam\io\localfilesystem.py", line 140, in _path_open raw_file = io.open(path, mode) FileNotFoundError: [Errno 2] No such file or directory: 'C:\Users\Shilpa\.cache\huggingface\datasets\wikipedia\20220401.aa-date=20220401,language=aa\2.0.0\aa542ed919df55cc5d3347f42dd4521d05ca68751f50dbc32bae2a7f1e167559.incomplete\beam-temp-wikipedia-train-880233e8287e11edaf9d3ca067f2714e\20a05238-6106-4420-a713-4eca6dd5959a.wikipedia-train' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "G:/abc/temp.py", line 32, in beam_runner='DirectRunner') File "G:\Python3.7\lib\site-packages\datasets\load.py", line 1751, in load_dataset use_auth_token=use_auth_token, File "G:\Python3.7\lib\site-packages\datasets\builder.py", line 705, in download_and_prepare dl_manager=dl_manager, verify_infos=verify_infos, **download_and_prepare_kwargs File "G:\Python3.7\lib\site-packages\datasets\builder.py", line 1394, in _download_and_prepare pipeline_results = pipeline.run() File "G:\Python3.7\lib\site-packages\apache_beam\pipeline.py", line 574, in run return self.runner.run_pipeline(self, self._options) File "G:\Python3.7\lib\site-packages\apache_beam\runners\direct\direct_runner.py", line 131, in run_pipeline return runner.run_pipeline(pipeline, options) File "G:\Python3.7\lib\site-packages\apache_beam\runners\portability\fn_api_runner\fn_runner.py", line 201, in run_pipeline options) File "G:\Python3.7\lib\site-packages\apache_beam\runners\portability\fn_api_runner\fn_runner.py", line 212, in run_via_runner_api return self.run_stages(stage_context, stages) File "G:\Python3.7\lib\site-packages\apache_beam\runners\portability\fn_api_runner\fn_runner.py", line 443, in run_stages runner_execution_context, bundle_context_manager, bundle_input) File "G:\Python3.7\lib\site-packages\apache_beam\runners\portability\fn_api_runner\fn_runner.py", line 776, in _execute_bundle bundle_manager)) File "G:\Python3.7\lib\site-packages\apache_beam\runners\portability\fn_api_runner\fn_runner.py", line 1000, in _run_bundle data_input, data_output, input_timers, expected_timer_output) File "G:\Python3.7\lib\site-packages\apache_beam\runners\portability\fn_api_runner\fn_runner.py", line 1309, in process_bundle result_future = self._worker_handler.control_conn.push(process_bundle_req) File "G:\Python3.7\lib\site-packages\apache_beam\runners\portability\fn_api_runner\worker_handlers.py", line 380, in push response = self.worker.do_instruction(request) File "G:\Python3.7\lib\site-packages\apache_beam\runners\worker\sdk_worker.py", line 598, in do_instruction getattr(request, request_type), request.instruction_id) File "G:\Python3.7\lib\site-packages\apache_beam\runners\worker\sdk_worker.py", line 635, in process_bundle bundle_processor.process_bundle(instruction_id)) File "G:\Python3.7\lib\site-packages\apache_beam\runners\worker\bundle_processor.py", line 1004, in process_bundle element.data) File "G:\Python3.7\lib\site-packages\apache_beam\runners\worker\bundle_processor.py", line 227, in process_encoded self.output(decoded_value) File "apache_beam\runners\worker\operations.py", line 526, in apache_beam.runners.worker.operations.Operation.output File "apache_beam\runners\worker\operations.py", line 528, in apache_beam.runners.worker.operations.Operation.output File "apache_beam\runners\worker\operations.py", line 237, in apache_beam.runners.worker.operations.SingletonElementConsumerSet.receive File "apache_beam\runners\worker\operations.py", line 240, in apache_beam.runners.worker.operations.SingletonElementConsumerSet.receive File "apache_beam\runners\worker\operations.py", line 907, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\worker\operations.py", line 908, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\common.py", line 1419, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 1491, in apache_beam.runners.common.DoFnRunner._reraise_augmented File "apache_beam\runners\common.py", line 1417, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 623, in apache_beam.runners.common.SimpleInvoker.invoke_process File "apache_beam\runners\common.py", line 1581, in apache_beam.runners.common._OutputHandler.handle_process_outputs File "apache_beam\runners\common.py", line 1694, in apache_beam.runners.common._OutputHandler._write_value_to_tag File "apache_beam\runners\worker\operations.py", line 240, in apache_beam.runners.worker.operations.SingletonElementConsumerSet.receive File "apache_beam\runners\worker\operations.py", line 907, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\worker\operations.py", line 908, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\common.py", line 1419, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 1491, in apache_beam.runners.common.DoFnRunner._reraise_augmented File "apache_beam\runners\common.py", line 1417, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 623, in apache_beam.runners.common.SimpleInvoker.invoke_process File "apache_beam\runners\common.py", line 1581, in apache_beam.runners.common._OutputHandler.handle_process_outputs File "apache_beam\runners\common.py", line 1694, in apache_beam.runners.common._OutputHandler._write_value_to_tag File "apache_beam\runners\worker\operations.py", line 240, in apache_beam.runners.worker.operations.SingletonElementConsumerSet.receive File "apache_beam\runners\worker\operations.py", line 907, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\worker\operations.py", line 908, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\common.py", line 1419, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 1491, in apache_beam.runners.common.DoFnRunner._reraise_augmented File "apache_beam\runners\common.py", line 1417, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 837, in apache_beam.runners.common.PerWindowInvoker.invoke_process File "apache_beam\runners\common.py", line 981, in apache_beam.runners.common.PerWindowInvoker._invoke_process_per_window File "apache_beam\runners\common.py", line 1581, in apache_beam.runners.common._OutputHandler.handle_process_outputs File "apache_beam\runners\common.py", line 1694, in apache_beam.runners.common._OutputHandler._write_value_to_tag File "apache_beam\runners\worker\operations.py", line 240, in apache_beam.runners.worker.operations.SingletonElementConsumerSet.receive File "apache_beam\runners\worker\operations.py", line 907, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\worker\operations.py", line 908, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\common.py", line 1419, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 1491, in apache_beam.runners.common.DoFnRunner._reraise_augmented File "apache_beam\runners\common.py", line 1417, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 623, in apache_beam.runners.common.SimpleInvoker.invoke_process File "apache_beam\runners\common.py", line 1581, in apache_beam.runners.common._OutputHandler.handle_process_outputs File "apache_beam\runners\common.py", line 1694, in apache_beam.runners.common._OutputHandler._write_value_to_tag File "apache_beam\runners\worker\operations.py", line 324, in apache_beam.runners.worker.operations.GeneralPurposeConsumerSet.receive File "apache_beam\runners\worker\operations.py", line 905, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\worker\operations.py", line 907, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\worker\operations.py", line 908, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\common.py", line 1419, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 1491, in apache_beam.runners.common.DoFnRunner._reraise_augmented File "apache_beam\runners\common.py", line 1417, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 623, in apache_beam.runners.common.SimpleInvoker.invoke_process File "apache_beam\runners\common.py", line 1581, in apache_beam.runners.common._OutputHandler.handle_process_outputs File "apache_beam\runners\common.py", line 1694, in apache_beam.runners.common._OutputHandler._write_value_to_tag File "apache_beam\runners\worker\operations.py", line 240, in apache_beam.runners.worker.operations.SingletonElementConsumerSet.receive File "apache_beam\runners\worker\operations.py", line 907, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\worker\operations.py", line 908, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\common.py", line 1419, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 1491, in apache_beam.runners.common.DoFnRunner._reraise_augmented File "apache_beam\runners\common.py", line 1417, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 837, in apache_beam.runners.common.PerWindowInvoker.invoke_process File "apache_beam\runners\common.py", line 981, in apache_beam.runners.common.PerWindowInvoker._invoke_process_per_window File "apache_beam\runners\common.py", line 1581, in apache_beam.runners.common._OutputHandler.handle_process_outputs File "apache_beam\runners\common.py", line 1694, in apache_beam.runners.common._OutputHandler._write_value_to_tag File "apache_beam\runners\worker\operations.py", line 240, in apache_beam.runners.worker.operations.SingletonElementConsumerSet.receive File "apache_beam\runners\worker\operations.py", line 907, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\worker\operations.py", line 908, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\common.py", line 1419, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 1507, in apache_beam.runners.common.DoFnRunner._reraise_augmented File "apache_beam\runners\common.py", line 1417, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 837, in apache_beam.runners.common.PerWindowInvoker.invoke_process File "apache_beam\runners\common.py", line 981, in apache_beam.runners.common.PerWindowInvoker._invoke_process_per_window File "apache_beam\runners\common.py", line 1571, in apache_beam.runners.common._OutputHandler.handle_process_outputs File "G:\Python3.7\lib\site-packages\apache_beam\io\iobase.py", line 1193, in process self.writer = self.sink.open_writer(init_result, str(uuid.uuid4())) File "G:\Python3.7\lib\site-packages\apache_beam\options\value_provider.py", line 193, in _f return fnc(self, *args, **kwargs) File "G:\Python3.7\lib\site-packages\apache_beam\io\filebasedsink.py", line 202, in open_writer return FileBasedSinkWriter(self, writer_path) File "G:\Python3.7\lib\site-packages\apache_beam\io\filebasedsink.py", line 419, in init self.temp_handle = self.sink.open(temp_shard_path) File "G:\Python3.7\lib\site-packages\apache_beam\io\parquetio.py", line 553, in open self._file_handle = super().open(temp_path) File "G:\Python3.7\lib\site-packages\apache_beam\options\value_provider.py", line 193, in _f return fnc(self, *args, **kwargs) File "G:\Python3.7\lib\site-packages\apache_beam\io\filebasedsink.py", line 139, in open temp_path, self.mime_type, self.compression_type) File "G:\Python3.7\lib\site-packages\apache_beam\io\filesystems.py", line 224, in create return filesystem.create(path, mime_type, compression_type) File "G:\Python3.7\lib\site-packages\apache_beam\io\localfilesystem.py", line 163, in create return self._path_open(path, 'wb', mime_type, compression_type) File "G:\Python3.7\lib\site-packages\apache_beam\io\localfilesystem.py", line 140, in _path_open raw_file = io.open(path, mode) RuntimeError: FileNotFoundError: [Errno 2] No such file or directory: 'C:\Users\Shilpa\.cache\huggingface\datasets\wikipedia\20220401.aa-date=20220401,language=aa\2.0.0\aa542ed919df55cc5d3347f42dd4521d05ca68751f50dbc32bae2a7f1e167559.incomplete\beam-temp-wikipedia-train-880233e8287e11edaf9d3ca067f2714e\20a05238-6106-4420-a713-4eca6dd5959a.wikipedia-train' [while running 'train/Save to parquet/Write/WriteImpl/WriteBundles'] ## Environment info Python: 3.7.6 Windows 10 Pro datasets :2.4.0 apache_beam: 2.41.0 mwparserfromhell: 0.6.4
false
1,356,009,042
https://api.github.com/repos/huggingface/datasets/issues/4915
https://github.com/huggingface/datasets/issues/4915
4,915
FileNotFoundError while downloading wikipedia dataset for any language
open
5
2022-08-30T16:15:46
2022-12-04T22:20:33
null
Shilpac20
[ "bug" ]
## Describe the bug Hi, I am currently trying to download wikipedia dataset using load_dataset("wikipedia", language="aa", date="20220401", split="train",beam_runner='DirectRunner'). However, I end up in getting filenotfound error. I get this error for any language I try to download. Environment: ## Steps to reproduce the bug ```python from datasets import load_dataset load_dataset("wikipedia", language="aa", date="20220401", split="train",beam_runner='DirectRunner') ``` ## Expected results to load the dataset ## Actual results I am pasting the error trace here: Downloading builder script: 35.9kB [00:00, ?B/s] Downloading metadata: 30.4kB [00:00, 1.94MB/s] Using custom data configuration 20220401.aa-date=20220401,language=aa Downloading and preparing dataset wikipedia/20220401.aa to C:\Users\Shilpa\.cache\huggingface\datasets\wikipedia\20220401.aa-date=20220401,language=aa\2.0.0\aa542ed919df55cc5d3347f42dd4521d05ca68751f50dbc32bae2a7f1e167559... Downloading data: 100%|████████████████████████████████████████████████████████████| 11.1k/11.1k [00:00<00:00, 712kB/s] Downloading data files: 100%|████████████████████████████████████████████████████████████| 1/1 [00:02<00:00, 2.82s/it] Extracting data files: 100%|█████████████████████████████████████████████████████████████████████| 1/1 [00:00<?, ?it/s] Downloading data: 100%|███████████████████████████████████████████████████████████| 35.6k/35.6k [00:00<00:00, 84.3kB/s] Downloading data files: 100%|████████████████████████████████████████████████████████████| 1/1 [00:02<00:00, 2.93s/it] Traceback (most recent call last): File "apache_beam\runners\common.py", line 1417, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 837, in apache_beam.runners.common.PerWindowInvoker.invoke_process File "apache_beam\runners\common.py", line 981, in apache_beam.runners.common.PerWindowInvoker._invoke_process_per_window File "apache_beam\runners\common.py", line 1571, in apache_beam.runners.common._OutputHandler.handle_process_outputs File "G:\Python3.7\lib\site-packages\apache_beam\io\iobase.py", line 1193, in process self.writer = self.sink.open_writer(init_result, str(uuid.uuid4())) File "G:\Python3.7\lib\site-packages\apache_beam\options\value_provider.py", line 193, in _f return fnc(self, *args, **kwargs) File "G:\Python3.7\lib\site-packages\apache_beam\io\filebasedsink.py", line 202, in open_writer return FileBasedSinkWriter(self, writer_path) File "G:\Python3.7\lib\site-packages\apache_beam\io\filebasedsink.py", line 419, in __init__ self.temp_handle = self.sink.open(temp_shard_path) File "G:\Python3.7\lib\site-packages\apache_beam\io\parquetio.py", line 553, in open self._file_handle = super().open(temp_path) File "G:\Python3.7\lib\site-packages\apache_beam\options\value_provider.py", line 193, in _f return fnc(self, *args, **kwargs) File "G:\Python3.7\lib\site-packages\apache_beam\io\filebasedsink.py", line 139, in open temp_path, self.mime_type, self.compression_type) File "G:\Python3.7\lib\site-packages\apache_beam\io\filesystems.py", line 224, in create return filesystem.create(path, mime_type, compression_type) File "G:\Python3.7\lib\site-packages\apache_beam\io\localfilesystem.py", line 163, in create return self._path_open(path, 'wb', mime_type, compression_type) File "G:\Python3.7\lib\site-packages\apache_beam\io\localfilesystem.py", line 140, in _path_open raw_file = io.open(path, mode) FileNotFoundError: [Errno 2] No such file or directory: 'C:\\Users\\Shilpa\\.cache\\huggingface\\datasets\\wikipedia\\20220401.aa-date=20220401,language=aa\\2.0.0\\aa542ed919df55cc5d3347f42dd4521d05ca68751f50dbc32bae2a7f1e167559.incomplete\\beam-temp-wikipedia-train-880233e8287e11edaf9d3ca067f2714e\\20a05238-6106-4420-a713-4eca6dd5959a.wikipedia-train' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "G:/abc/temp.py", line 32, in <module> beam_runner='DirectRunner') File "G:\Python3.7\lib\site-packages\datasets\load.py", line 1751, in load_dataset use_auth_token=use_auth_token, File "G:\Python3.7\lib\site-packages\datasets\builder.py", line 705, in download_and_prepare dl_manager=dl_manager, verify_infos=verify_infos, **download_and_prepare_kwargs File "G:\Python3.7\lib\site-packages\datasets\builder.py", line 1394, in _download_and_prepare pipeline_results = pipeline.run() File "G:\Python3.7\lib\site-packages\apache_beam\pipeline.py", line 574, in run return self.runner.run_pipeline(self, self._options) File "G:\Python3.7\lib\site-packages\apache_beam\runners\direct\direct_runner.py", line 131, in run_pipeline return runner.run_pipeline(pipeline, options) File "G:\Python3.7\lib\site-packages\apache_beam\runners\portability\fn_api_runner\fn_runner.py", line 201, in run_pipeline options) File "G:\Python3.7\lib\site-packages\apache_beam\runners\portability\fn_api_runner\fn_runner.py", line 212, in run_via_runner_api return self.run_stages(stage_context, stages) File "G:\Python3.7\lib\site-packages\apache_beam\runners\portability\fn_api_runner\fn_runner.py", line 443, in run_stages runner_execution_context, bundle_context_manager, bundle_input) File "G:\Python3.7\lib\site-packages\apache_beam\runners\portability\fn_api_runner\fn_runner.py", line 776, in _execute_bundle bundle_manager)) File "G:\Python3.7\lib\site-packages\apache_beam\runners\portability\fn_api_runner\fn_runner.py", line 1000, in _run_bundle data_input, data_output, input_timers, expected_timer_output) File "G:\Python3.7\lib\site-packages\apache_beam\runners\portability\fn_api_runner\fn_runner.py", line 1309, in process_bundle result_future = self._worker_handler.control_conn.push(process_bundle_req) File "G:\Python3.7\lib\site-packages\apache_beam\runners\portability\fn_api_runner\worker_handlers.py", line 380, in push response = self.worker.do_instruction(request) File "G:\Python3.7\lib\site-packages\apache_beam\runners\worker\sdk_worker.py", line 598, in do_instruction getattr(request, request_type), request.instruction_id) File "G:\Python3.7\lib\site-packages\apache_beam\runners\worker\sdk_worker.py", line 635, in process_bundle bundle_processor.process_bundle(instruction_id)) File "G:\Python3.7\lib\site-packages\apache_beam\runners\worker\bundle_processor.py", line 1004, in process_bundle element.data) File "G:\Python3.7\lib\site-packages\apache_beam\runners\worker\bundle_processor.py", line 227, in process_encoded self.output(decoded_value) File "apache_beam\runners\worker\operations.py", line 526, in apache_beam.runners.worker.operations.Operation.output File "apache_beam\runners\worker\operations.py", line 528, in apache_beam.runners.worker.operations.Operation.output File "apache_beam\runners\worker\operations.py", line 237, in apache_beam.runners.worker.operations.SingletonElementConsumerSet.receive File "apache_beam\runners\worker\operations.py", line 240, in apache_beam.runners.worker.operations.SingletonElementConsumerSet.receive File "apache_beam\runners\worker\operations.py", line 907, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\worker\operations.py", line 908, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\common.py", line 1419, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 1491, in apache_beam.runners.common.DoFnRunner._reraise_augmented File "apache_beam\runners\common.py", line 1417, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 623, in apache_beam.runners.common.SimpleInvoker.invoke_process File "apache_beam\runners\common.py", line 1581, in apache_beam.runners.common._OutputHandler.handle_process_outputs File "apache_beam\runners\common.py", line 1694, in apache_beam.runners.common._OutputHandler._write_value_to_tag File "apache_beam\runners\worker\operations.py", line 240, in apache_beam.runners.worker.operations.SingletonElementConsumerSet.receive File "apache_beam\runners\worker\operations.py", line 907, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\worker\operations.py", line 908, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\common.py", line 1419, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 1491, in apache_beam.runners.common.DoFnRunner._reraise_augmented File "apache_beam\runners\common.py", line 1417, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 623, in apache_beam.runners.common.SimpleInvoker.invoke_process File "apache_beam\runners\common.py", line 1581, in apache_beam.runners.common._OutputHandler.handle_process_outputs File "apache_beam\runners\common.py", line 1694, in apache_beam.runners.common._OutputHandler._write_value_to_tag File "apache_beam\runners\worker\operations.py", line 240, in apache_beam.runners.worker.operations.SingletonElementConsumerSet.receive File "apache_beam\runners\worker\operations.py", line 907, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\worker\operations.py", line 908, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\common.py", line 1419, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 1491, in apache_beam.runners.common.DoFnRunner._reraise_augmented File "apache_beam\runners\common.py", line 1417, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 837, in apache_beam.runners.common.PerWindowInvoker.invoke_process File "apache_beam\runners\common.py", line 981, in apache_beam.runners.common.PerWindowInvoker._invoke_process_per_window File "apache_beam\runners\common.py", line 1581, in apache_beam.runners.common._OutputHandler.handle_process_outputs File "apache_beam\runners\common.py", line 1694, in apache_beam.runners.common._OutputHandler._write_value_to_tag File "apache_beam\runners\worker\operations.py", line 240, in apache_beam.runners.worker.operations.SingletonElementConsumerSet.receive File "apache_beam\runners\worker\operations.py", line 907, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\worker\operations.py", line 908, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\common.py", line 1419, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 1491, in apache_beam.runners.common.DoFnRunner._reraise_augmented File "apache_beam\runners\common.py", line 1417, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 623, in apache_beam.runners.common.SimpleInvoker.invoke_process File "apache_beam\runners\common.py", line 1581, in apache_beam.runners.common._OutputHandler.handle_process_outputs File "apache_beam\runners\common.py", line 1694, in apache_beam.runners.common._OutputHandler._write_value_to_tag File "apache_beam\runners\worker\operations.py", line 324, in apache_beam.runners.worker.operations.GeneralPurposeConsumerSet.receive File "apache_beam\runners\worker\operations.py", line 905, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\worker\operations.py", line 907, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\worker\operations.py", line 908, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\common.py", line 1419, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 1491, in apache_beam.runners.common.DoFnRunner._reraise_augmented File "apache_beam\runners\common.py", line 1417, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 623, in apache_beam.runners.common.SimpleInvoker.invoke_process File "apache_beam\runners\common.py", line 1581, in apache_beam.runners.common._OutputHandler.handle_process_outputs File "apache_beam\runners\common.py", line 1694, in apache_beam.runners.common._OutputHandler._write_value_to_tag File "apache_beam\runners\worker\operations.py", line 240, in apache_beam.runners.worker.operations.SingletonElementConsumerSet.receive File "apache_beam\runners\worker\operations.py", line 907, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\worker\operations.py", line 908, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\common.py", line 1419, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 1491, in apache_beam.runners.common.DoFnRunner._reraise_augmented File "apache_beam\runners\common.py", line 1417, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 837, in apache_beam.runners.common.PerWindowInvoker.invoke_process File "apache_beam\runners\common.py", line 981, in apache_beam.runners.common.PerWindowInvoker._invoke_process_per_window File "apache_beam\runners\common.py", line 1581, in apache_beam.runners.common._OutputHandler.handle_process_outputs File "apache_beam\runners\common.py", line 1694, in apache_beam.runners.common._OutputHandler._write_value_to_tag File "apache_beam\runners\worker\operations.py", line 240, in apache_beam.runners.worker.operations.SingletonElementConsumerSet.receive File "apache_beam\runners\worker\operations.py", line 907, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\worker\operations.py", line 908, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam\runners\common.py", line 1419, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 1507, in apache_beam.runners.common.DoFnRunner._reraise_augmented File "apache_beam\runners\common.py", line 1417, in apache_beam.runners.common.DoFnRunner.process File "apache_beam\runners\common.py", line 837, in apache_beam.runners.common.PerWindowInvoker.invoke_process File "apache_beam\runners\common.py", line 981, in apache_beam.runners.common.PerWindowInvoker._invoke_process_per_window File "apache_beam\runners\common.py", line 1571, in apache_beam.runners.common._OutputHandler.handle_process_outputs File "G:\Python3.7\lib\site-packages\apache_beam\io\iobase.py", line 1193, in process self.writer = self.sink.open_writer(init_result, str(uuid.uuid4())) File "G:\Python3.7\lib\site-packages\apache_beam\options\value_provider.py", line 193, in _f return fnc(self, *args, **kwargs) File "G:\Python3.7\lib\site-packages\apache_beam\io\filebasedsink.py", line 202, in open_writer return FileBasedSinkWriter(self, writer_path) File "G:\Python3.7\lib\site-packages\apache_beam\io\filebasedsink.py", line 419, in __init__ self.temp_handle = self.sink.open(temp_shard_path) File "G:\Python3.7\lib\site-packages\apache_beam\io\parquetio.py", line 553, in open self._file_handle = super().open(temp_path) File "G:\Python3.7\lib\site-packages\apache_beam\options\value_provider.py", line 193, in _f return fnc(self, *args, **kwargs) File "G:\Python3.7\lib\site-packages\apache_beam\io\filebasedsink.py", line 139, in open temp_path, self.mime_type, self.compression_type) File "G:\Python3.7\lib\site-packages\apache_beam\io\filesystems.py", line 224, in create return filesystem.create(path, mime_type, compression_type) File "G:\Python3.7\lib\site-packages\apache_beam\io\localfilesystem.py", line 163, in create return self._path_open(path, 'wb', mime_type, compression_type) File "G:\Python3.7\lib\site-packages\apache_beam\io\localfilesystem.py", line 140, in _path_open raw_file = io.open(path, mode) RuntimeError: FileNotFoundError: [Errno 2] No such file or directory: 'C:\\Users\\Shilpa\\.cache\\huggingface\\datasets\\wikipedia\\20220401.aa-date=20220401,language=aa\\2.0.0\\aa542ed919df55cc5d3347f42dd4521d05ca68751f50dbc32bae2a7f1e167559.incomplete\\beam-temp-wikipedia-train-880233e8287e11edaf9d3ca067f2714e\\20a05238-6106-4420-a713-4eca6dd5959a.wikipedia-train' [while running 'train/Save to parquet/Write/WriteImpl/WriteBundles'] ## Environment info Python: 3.7.6 Windows 10 Pro datasets :2.4.0 apache_beam: 2.41.0 mwparserfromhell: 0.6.4
false
1,355,482,624
https://api.github.com/repos/huggingface/datasets/issues/4914
https://github.com/huggingface/datasets/pull/4914
4,914
Support streaming swda dataset
closed
1
2022-08-30T09:46:28
2022-08-30T11:16:33
2022-08-30T11:14:16
albertvillanova
[]
Support streaming swda dataset.
true
1,355,232,007
https://api.github.com/repos/huggingface/datasets/issues/4913
https://github.com/huggingface/datasets/pull/4913
4,913
Add license and citation information to cosmos_qa dataset
closed
1
2022-08-30T06:23:19
2022-08-30T09:49:31
2022-08-30T09:47:35
albertvillanova
[]
This PR adds the license information to `cosmos_qa` dataset, once reported via email by Yejin Choi, the dataset is licensed under CC BY 4.0. This PR also updates the citation information.
true
1,355,078,864
https://api.github.com/repos/huggingface/datasets/issues/4912
https://github.com/huggingface/datasets/issues/4912
4,912
datasets map() handles all data at a stroke and takes long time
closed
7
2022-08-30T02:25:56
2023-04-06T09:43:58
2022-09-06T09:23:35
BruceStayHungry
[]
**1. Background** Huggingface datasets package advises using `map()` to process data in batches. In the example code on pretraining masked language model, they use `map()` to tokenize all data at a stroke before the train loop. The corresponding code: ``` with accelerator.main_process_first(): tokenized_datasets = raw_datasets.map( tokenize_function, batched=True, num_proc=args.preprocessing_num_workers, remove_columns=column_names, load_from_cache_file=not args.overwrite_cache, desc="Running tokenizer on every text in dataset" ) ``` **2. The problem** Thus, when I try the same pertaining code with a much larger corpus, it takes quite a long time to tokenize. Also, we can choose to tokenize data in `data-collator`. In this way, the program only tokenizes one batch in the next training step and avoids getting stuck in tokenization. **3. My question** As described above, my questions are: * **Which is better? Process in `map()` or in `data-collator`** * **Why huggingface advises `map()` function?** There should be some advantages to using `map()` Thanks for your answers!
false
1,354,426,978
https://api.github.com/repos/huggingface/datasets/issues/4911
https://github.com/huggingface/datasets/issues/4911
4,911
[Tests] Ensure `datasets` supports renamed repositories
open
2
2022-08-29T14:46:14
2025-06-19T06:10:52
null
lhoestq
[ "good second issue" ]
On https://hf.co/datasets you can rename a dataset (or sometimes move it to another user/org). The website handles redirections correctly and AFAIK `datasets` does as well. However it would be nice to have an integration test to make sure we don't break support for renamed datasets. To implement this we can use the /api/repos/move endpoint on hub-ci to rename/move a repo (it is documented at https://huggingface.co/docs/hub/api)
false
1,354,374,328
https://api.github.com/repos/huggingface/datasets/issues/4910
https://github.com/huggingface/datasets/issues/4910
4,910
Identical keywords in build_kwargs and config_kwargs lead to TypeError in load_dataset_builder()
open
7
2022-08-29T14:11:48
2022-09-13T11:58:46
null
bablf
[ "bug", "good first issue" ]
## Describe the bug In `load_dataset_builder()`, `build_kwargs` and `config_kwargs` can contain the same keywords leading to a TypeError("type object got multiple values for keyword argument "xyz"). I ran into this problem with the keyword: `base_path`. It might happen with other kwargs as well. I think a quickfix would be ```python builder_cls = import_main_class(dataset_module.module_path) builder_kwargs = dataset_module.builder_kwargs data_files = builder_kwargs.pop("data_files", data_files) config_name = builder_kwargs.pop("config_name", name) hash = builder_kwargs.pop("hash") base_path = builder_kwargs.pop("base_path") ``` and then pass base_path into `builder_cls`. ## Steps to reproduce the bug ```python from datasets import load_dataset load_dataset("rotten_tomatoes", base_path="./sample_data") ``` ## Expected results The docs state: `**config_kwargs` — Keyword arguments to be passed to the [BuilderConfig](https://huggingface.co/docs/datasets/v2.4.0/en/package_reference/builder_classes#datasets.BuilderConfig) and used in the [DatasetBuilder](https://huggingface.co/docs/datasets/v2.4.0/en/package_reference/builder_classes#datasets.DatasetBuilder). So I would expect to be able to pass the base_path into `load_dataset()`. ## Actual results TypeError("type object got multiple values for keyword argument "base_path"). ## Environment info <!-- You can run the command `datasets-cli env` and copy-and-paste its output below. --> - `datasets` version: 2.4.0 - Platform: macOS-12.5-arm64-arm-64bit - Python version: 3.8.9 - PyArrow version: 9.0.0
false
1,353,997,788
https://api.github.com/repos/huggingface/datasets/issues/4909
https://github.com/huggingface/datasets/pull/4909
4,909
Update GLUE evaluation metadata
closed
1
2022-08-29T09:43:44
2022-08-29T14:53:29
2022-08-29T14:51:18
lewtun
[]
This PR updates the evaluation metadata for GLUE to: * Include defaults for all configs except `ax` (which only has a `test` split with no known labels) * Fix the default split from `test` to `validation` since `test` splits in GLUE have no labels (they're private) * Fix the `task_id` for some existing defaults cc @sashavor @douwekiela
true
1,353,995,574
https://api.github.com/repos/huggingface/datasets/issues/4908
https://github.com/huggingface/datasets/pull/4908
4,908
Fix missing tags in dataset cards
closed
1
2022-08-29T09:41:53
2022-09-22T14:35:56
2022-08-29T16:13:07
albertvillanova
[]
Fix missing tags in dataset cards: - asnq - clue - common_gen - cosmos_qa - guardian_authorship - hindi_discourse - py_ast - x_stance This PR partially fixes the missing tags in dataset cards. Subsequent PRs will follow to complete this task. Related to: - #4833 - #4891 - #4896
true
1,353,808,348
https://api.github.com/repos/huggingface/datasets/issues/4907
https://github.com/huggingface/datasets/issues/4907
4,907
None Type error for swda datasets
closed
3
2022-08-29T07:05:20
2022-08-30T14:43:41
2022-08-30T14:43:41
hannan72
[ "bug" ]
## Describe the bug I got `'NoneType' object is not callable` error while calling the swda datasets. ## Steps to reproduce the bug ```python from datasets import load_dataset dataset = load_dataset("swda") ``` ## Expected results Run without error ## Environment info <!-- You can run the command `datasets-cli env` and copy-and-paste its output below. --> - `datasets` version: 2.4.0 - Python version: 3.8.10
false
1,353,223,925
https://api.github.com/repos/huggingface/datasets/issues/4906
https://github.com/huggingface/datasets/issues/4906
4,906
Can't import datasets AttributeError: partially initialized module 'datasets' has no attribute 'utils' (most likely due to a circular import)
closed
7
2022-08-28T02:23:24
2024-11-16T08:59:17
2022-10-03T12:22:50
OPterminator
[ "bug" ]
## Describe the bug A clear and concise description of what the bug is. Not able to import datasets ## Steps to reproduce the bug ```python # Sample code to reproduce the bug import os os.environ["WANDB_API_KEY"] = "0" ## to silence warning import numpy as np import random import sklearn import matplotlib.pyplot as plt import pandas as pd import sys import tensorflow as tf import plotly.express as px import transformers import tokenizers import nlp as nlp import utils import datasets ``` ## Expected results A clear and concise description of the expected results. import should work normal ## Actual results Specify the actual results or traceback. --------------------------------------------------------------------------- AttributeError Traceback (most recent call last) <ipython-input-21-b3b5b0b62103> in <module> 13 import nlp as nlp 14 import utils ---> 15 import datasets ~\anaconda3\lib\site-packages\datasets\__init__.py in <module> 44 from .fingerprint import disable_caching, enable_caching, is_caching_enabled, set_caching_enabled 45 from .info import DatasetInfo, MetricInfo ---> 46 from .inspect import ( 47 get_dataset_config_info, 48 get_dataset_config_names, ~\anaconda3\lib\site-packages\datasets\inspect.py in <module> 28 from .download.streaming_download_manager import StreamingDownloadManager 29 from .info import DatasetInfo ---> 30 from .load import dataset_module_factory, import_main_class, load_dataset_builder, metric_module_factory 31 from .utils.file_utils import relative_to_absolute_path 32 from .utils.logging import get_logger ~\anaconda3\lib\site-packages\datasets\load.py in <module> 53 from .iterable_dataset import IterableDataset 54 from .metric import Metric ---> 55 from .packaged_modules import ( 56 _EXTENSION_TO_MODULE, 57 _MODULE_SUPPORTS_METADATA, ~\anaconda3\lib\site-packages\datasets\packaged_modules\__init__.py in <module> 4 from typing import List 5 ----> 6 from .csv import csv 7 from .imagefolder import imagefolder 8 from .json import json ~\anaconda3\lib\site-packages\datasets\packaged_modules\csv\csv.py in <module> 13 14 ---> 15 logger = datasets.utils.logging.get_logger(__name__) 16 17 _PANDAS_READ_CSV_NO_DEFAULT_PARAMETERS = ["names", "prefix"] AttributeError: partially initialized module 'datasets' has no attribute 'utils' (most likely due to a circular import) ## Environment info <!-- You can run the command `datasets-cli env` and copy-and-paste its output below. --> Copy-and-paste the text below in your GitHub issue. - `datasets` version: 2.4.0 - Platform: Windows-10-10.0.22000-SP0 - Python version: 3.8.8 - PyArrow version: 9.0.0 - Pandas version: 1.2.4
false
1,353,002,837
https://api.github.com/repos/huggingface/datasets/issues/4904
https://github.com/huggingface/datasets/pull/4904
4,904
[LibriSpeech] Fix dev split local_extracted_archive for 'all' config
closed
2
2022-08-27T10:04:57
2022-08-30T10:06:21
2022-08-30T10:03:25
sanchit-gandhi
[]
We define the keys for the `_DL_URLS` of the dev split as `dev.clean` and `dev.other`: https://github.com/huggingface/datasets/blob/2e7142a3c6500b560da45e8d5128e320a09fcbd4/datasets/librispeech_asr/librispeech_asr.py#L60-L61 These keys get forwarded to the `dl_manager` and thus the `local_extracted_archive`. However, when calling `SplitGenerator` for the dev sets, we query the `local_extracted_archive` keys `validation.clean` and `validation.other`: https://github.com/huggingface/datasets/blob/2e7142a3c6500b560da45e8d5128e320a09fcbd4/datasets/librispeech_asr/librispeech_asr.py#L212 https://github.com/huggingface/datasets/blob/2e7142a3c6500b560da45e8d5128e320a09fcbd4/datasets/librispeech_asr/librispeech_asr.py#L219 The consequence of this is that the `local_extracted_archive` arg passed to `_generate_examples` is always `None`, as the keys `validation.clean` and `validation.other` do not exists in the `local_extracted_archive`. When defining the `audio_file` in `_generate_examples`, since `local_extracted_archive` is always `None`, we always omit the `local_extracted_archive` path from the `audio_file` path, **even** if in non-streaming mode: https://github.com/huggingface/datasets/blob/2e7142a3c6500b560da45e8d5128e320a09fcbd4/datasets/librispeech_asr/librispeech_asr.py#L259-L263 Thus, `audio_file` will only ever be the streaming path (`audio_file`, not `os.path.join(local_extracted_archive, audio_file)`). This PR fixes the `.get()` keys for the `local_extracted_archive` for the dev splits.
true
1,352,539,075
https://api.github.com/repos/huggingface/datasets/issues/4903
https://github.com/huggingface/datasets/pull/4903
4,903
Fix CI reporting
closed
1
2022-08-26T17:16:30
2022-08-26T17:49:33
2022-08-26T17:46:59
albertvillanova
[]
Fix CI so that it reports defaults (failed and error) besides the custom (xfailed and xpassed) in the test summary. This PR fixes a regression introduced by: - #4845 This introduced the reporting of xfailed and xpassed, but wrongly removed the reporting of the defaults failed and error.
true
1,352,469,196
https://api.github.com/repos/huggingface/datasets/issues/4902
https://github.com/huggingface/datasets/issues/4902
4,902
Name the default config `default`
closed
1
2022-08-26T16:16:22
2023-07-24T21:15:31
2023-07-24T21:15:31
severo
[ "enhancement", "question" ]
Currently, if a dataset has no configuration, a default configuration is created from the dataset name. For example, for a dataset loaded from the hub repository, such as https://huggingface.co/datasets/user/dataset (repo id is `user/dataset`), the default configuration will be `user--dataset`. It might be easier to handle to set it to `default`, or another reserved word.
false
1,352,438,915
https://api.github.com/repos/huggingface/datasets/issues/4901
https://github.com/huggingface/datasets/pull/4901
4,901
Raise ManualDownloadError from get_dataset_config_info
closed
1
2022-08-26T15:45:56
2022-08-30T10:42:21
2022-08-30T10:40:04
albertvillanova
[]
This PRs raises a specific `ManualDownloadError` when `get_dataset_config_info` is called for a dataset that requires manual download. Related to: - #4898 CC: @severo
true
1,352,405,855
https://api.github.com/repos/huggingface/datasets/issues/4900
https://github.com/huggingface/datasets/issues/4900
4,900
Dataset Viewer issue for asaxena1990/Dummy_dataset
closed
3
2022-08-26T15:15:44
2023-07-24T15:42:09
2023-07-24T15:42:09
ankurcl
[]
### Link _No response_ ### Description _No response_ ### Owner _No response_
false
1,352,031,286
https://api.github.com/repos/huggingface/datasets/issues/4899
https://github.com/huggingface/datasets/pull/4899
4,899
Re-add code and und language tags
closed
1
2022-08-26T09:48:57
2022-08-26T10:27:18
2022-08-26T10:24:20
albertvillanova
[]
This PR fixes the removal of 2 language tags done by: - #4882 The tags are: - "code": this is not a IANA tag but needed - "und": this is one of the special scoped tags removed by 0d53202b9abce6fd0358cb00d06fcfd904b875af - used in "mc4" and "udhr" datasets
true
1,351,851,254
https://api.github.com/repos/huggingface/datasets/issues/4898
https://github.com/huggingface/datasets/issues/4898
4,898
Dataset Viewer issue for timit_asr
closed
5
2022-08-26T07:12:05
2022-10-03T12:40:28
2022-10-03T12:40:27
InayatUllah932
[]
### Link _No response_ ### Description _No response_ ### Owner _No response_
false
1,351,784,727
https://api.github.com/repos/huggingface/datasets/issues/4897
https://github.com/huggingface/datasets/issues/4897
4,897
datasets generate large arrow file
closed
2
2022-08-26T05:51:16
2022-09-18T05:07:52
2022-09-18T05:07:52
jax11235
[ "bug" ]
Checking the large file in disk, and found the large cache file in the cifar10 data directory: ![image](https://user-images.githubusercontent.com/18533904/186830449-ba96cdeb-0fe8-4543-994d-2abe7145933f.png) As we know, the size of cifar10 dataset is ~130MB, but the cache file has almost 30GB size, there may be some problems here.
false
1,351,180,409
https://api.github.com/repos/huggingface/datasets/issues/4896
https://github.com/huggingface/datasets/pull/4896
4,896
Fix missing tags in dataset cards
closed
1
2022-08-25T16:41:43
2022-09-22T14:37:16
2022-08-26T04:41:48
albertvillanova
[]
Fix missing tags in dataset cards: - anli - coarse_discourse - commonsense_qa - cos_e - ilist - lc_quad - web_questions - xsum This PR partially fixes the missing tags in dataset cards. Subsequent PRs will follow to complete this task. Related to: - #4833 - #4891
true
1,350,798,527
https://api.github.com/repos/huggingface/datasets/issues/4895
https://github.com/huggingface/datasets/issues/4895
4,895
load_dataset method returns Unknown split "validation" even if this dir exists
closed
18
2022-08-25T12:11:00
2024-03-26T16:47:48
2022-09-29T08:07:50
SamSamhuns
[ "bug" ]
## Describe the bug The `datasets.load_dataset` returns a `ValueError: Unknown split "validation". Should be one of ['train', 'test'].` when running `load_dataset(local_data_dir_path, split="validation")` even if the `validation` sub-directory exists in the local data path. The data directories are as follows and attached to this issue: ``` test_data1 |_ train |_ 1012.png |_ metadata.jsonl ... |_ test ... |_ validation |_ 234.png |_ metadata.jsonl ... test_data2 |_ train |_ train_1012.png |_ metadata.jsonl ... |_ test ... |_ validation |_ val_234.png |_ metadata.jsonl ... ``` They contain the same image files and `metadata.jsonl` but the images in `test_data2` have the split names prepended i.e. `train_1012.png, val_234.png` and the images in `test_data1` do not have the split names prepended to the image names i.e. `1012.png, 234.png` I actually saw in another issue `val` was not recognized as a split name but here I would expect the files to take the split from the parent directory name i.e. val should become part of the validation split? ## Steps to reproduce the bug ```python import datasets datasets.logging.set_verbosity_error() from datasets import load_dataset, get_dataset_split_names # the following only finds train, validation and test splits correctly path = "./test_data1" print("######################", get_dataset_split_names(path), "######################") dataset_list = [] for spt in ["train", "test", "validation"]: dataset = load_dataset(path, split=spt) dataset_list.append(dataset) # the following only finds train and test splits path = "./test_data2" print("######################", get_dataset_split_names(path), "######################") dataset_list = [] for spt in ["train", "test", "validation"]: dataset = load_dataset(path, split=spt) dataset_list.append(dataset) ``` ## Expected results ``` ###################### ['train', 'test', 'validation'] ###################### ###################### ['train', 'test', 'validation'] ###################### ``` ## Actual results ``` Traceback (most recent call last): File "test_data_loader.py", line 11, in <module> dataset = load_dataset(path, split=spt) File "/home/venv/lib/python3.8/site-packages/datasets/load.py", line 1758, in load_dataset ds = builder_instance.as_dataset(split=split, ignore_verifications=ignore_verifications, in_memory=keep_in_memory) File "/home/venv/lib/python3.8/site-packages/datasets/builder.py", line 893, in as_dataset datasets = map_nested( File "/home/venv/lib/python3.8/site-packages/datasets/utils/py_utils.py", line 385, in map_nested return function(data_struct) File "/home/venv/lib/python3.8/site-packages/datasets/builder.py", line 924, in _build_single_dataset ds = self._as_dataset( File "/home/venv/lib/python3.8/site-packages/datasets/builder.py", line 993, in _as_dataset dataset_kwargs = ArrowReader(self._cache_dir, self.info).read( File "/home/venv/lib/python3.8/site-packages/datasets/arrow_reader.py", line 211, in read files = self.get_file_instructions(name, instructions, split_infos) File "/home/venv/lib/python3.8/site-packages/datasets/arrow_reader.py", line 184, in get_file_instructions file_instructions = make_file_instructions( File "/home/venv/lib/python3.8/site-packages/datasets/arrow_reader.py", line 107, in make_file_instructions absolute_instructions = instruction.to_absolute(name2len) File "/home/venv/lib/python3.8/site-packages/datasets/arrow_reader.py", line 616, in to_absolute return [_rel_to_abs_instr(rel_instr, name2len) for rel_instr in self._relative_instructions] File "/home/venv/lib/python3.8/site-packages/datasets/arrow_reader.py", line 616, in <listcomp> return [_rel_to_abs_instr(rel_instr, name2len) for rel_instr in self._relative_instructions] File "/home/venv/lib/python3.8/site-packages/datasets/arrow_reader.py", line 433, in _rel_to_abs_instr raise ValueError(f'Unknown split "{split}". Should be one of {list(name2len)}.') ValueError: Unknown split "validation". Should be one of ['train', 'test']. ``` ## Environment info <!-- You can run the command `datasets-cli env` and copy-and-paste its output below. --> - `datasets` version: - Platform: Linux Ubuntu 18.04 - Python version: 3.8.12 - PyArrow version: 9.0.0 Data files [test_data1.zip](https://github.com/huggingface/datasets/files/9424463/test_data1.zip) [test_data2.zip](https://github.com/huggingface/datasets/files/9424468/test_data2.zip)
false
1,350,667,270
https://api.github.com/repos/huggingface/datasets/issues/4894
https://github.com/huggingface/datasets/pull/4894
4,894
Add citation information to makhzan dataset
closed
1
2022-08-25T10:16:40
2022-08-30T06:21:54
2022-08-25T13:19:41
albertvillanova
[]
This PR adds the citation information to `makhzan` dataset, once they have replied to our request for that information: - https://github.com/zeerakahmed/makhzan/issues/43
true
1,350,655,674
https://api.github.com/repos/huggingface/datasets/issues/4893
https://github.com/huggingface/datasets/issues/4893
4,893
Oversampling strategy for iterable datasets in `interleave_datasets`
closed
9
2022-08-25T10:06:55
2022-10-03T12:37:46
2022-10-03T12:37:46
lhoestq
[ "good second issue" ]
In https://github.com/huggingface/datasets/pull/4831 @ylacombe added an oversampling strategy for `interleave_datasets`. However right now it doesn't work for datasets loaded using `load_dataset(..., streaming=True)`, which are `IterableDataset` objects. It would be nice to expand `interleave_datasets` for iterable datasets as well to support this oversampling strategy ```python >>> from datasets.iterable_dataset import IterableDataset, ExamplesIterable >>> d1 = IterableDataset(ExamplesIterable(lambda: [(yield i, {"a": i}) for i in [0, 1, 2]], {})) >>> d2 = IterableDataset(ExamplesIterable(lambda: [(yield i, {"a": i}) for i in [10, 11, 12, 13]], {})) >>> d3 = IterableDataset(ExamplesIterable(lambda: [(yield i, {"a": i}) for i in [20, 21, 22, 23, 24]], {})) >>> dataset = interleave_datasets([d1, d2, d3]) # is supported >>> [x["a"] for x in dataset] [0, 10, 20, 1, 11, 21, 2, 12, 22] >>> dataset = interleave_datasets([d1, d2, d3], stopping_strategy="all_exhausted") # is not supported yet >>> [x["a"] for x in dataset] [0, 10, 20, 1, 11, 21, 2, 12, 22, 0, 13, 23, 1, 0, 24] ``` This can be implemented by adding the strategy to both `CyclingMultiSourcesExamplesIterable` and `RandomlyCyclingMultiSourcesExamplesIterable` used in `_interleave_iterable_datasets` in `iterable_dataset.py` I would be happy to share some guidance if anyone would like to give it a shot :)
false
1,350,636,499
https://api.github.com/repos/huggingface/datasets/issues/4892
https://github.com/huggingface/datasets/pull/4892
4,892
Add citation to ro_sts and ro_sts_parallel datasets
closed
1
2022-08-25T09:51:06
2022-08-25T10:49:56
2022-08-25T10:49:56
albertvillanova
[]
This PR adds the citation information to `ro_sts_parallel` and `ro_sts_parallel` datasets, once they have replied our request for that information: - https://github.com/dumitrescustefan/RO-STS/issues/4
true
1,350,589,813
https://api.github.com/repos/huggingface/datasets/issues/4891
https://github.com/huggingface/datasets/pull/4891
4,891
Fix missing tags in dataset cards
closed
0
2022-08-25T09:14:17
2022-09-22T14:39:02
2022-08-25T13:43:34
albertvillanova
[]
Fix missing tags in dataset cards: - aslg_pc12 - librispeech_lm - mwsc - opus100 - qasc - quail - squadshifts - winograd_wsc This PR partially fixes the missing tags in dataset cards. Subsequent PRs will follow to complete this task. Related to: - #4833
true
1,350,578,029
https://api.github.com/repos/huggingface/datasets/issues/4890
https://github.com/huggingface/datasets/pull/4890
4,890
add Dataset.from_list
closed
2
2022-08-25T09:05:58
2022-09-02T10:22:59
2022-09-02T10:20:33
sanderland
[]
As discussed in #4885 I initially added this bit at the end, thinking filling this field was necessary as it is done in from_dict. However, it seems the constructor takes care of filling info when it is empty. ``` if info.features is None: info.features = Features( { col: generate_from_arrow_type(coldata.type) for col, coldata in zip(pa_table.column_names, pa_table.columns) } ) ```
true
1,349,758,525
https://api.github.com/repos/huggingface/datasets/issues/4889
https://github.com/huggingface/datasets/issues/4889
4,889
torchaudio 11.0 yields different results than torchaudio 12.1 when loading MP3
closed
5
2022-08-24T16:54:43
2023-03-02T15:33:05
2023-03-02T15:33:04
patrickvonplaten
[ "bug" ]
## Describe the bug When loading Common Voice with torchaudio 0.11.0 the results are different to 0.12.1 which leads to problems in transformers see: https://github.com/huggingface/transformers/pull/18749 ## Steps to reproduce the bug If you run the following code once with `torchaudio==0.11.0+cu102` and `torchaudio==0.12.1+cu102` you can see that the tensors differ. This is a pretty big breaking change and makes some integration tests fail in Transformers. ```python #!/usr/bin/env python3 from datasets import load_dataset import datasets import numpy as np import torch import torchaudio print("torch vesion", torch.__version__) print("torchaudio vesion", torchaudio.__version__) save_audio = True load_audios = False if save_audio: ds = load_dataset("common_voice", "en", split="train", streaming=True) ds = ds.cast_column("audio", datasets.Audio(sampling_rate=16_000)) ds_iter = iter(ds) sample = next(ds_iter) np.save(f"audio_sample_{torch.__version__}", sample["audio"]["array"]) print(sample["audio"]["array"]) if load_audios: array_torch_11 = np.load("/home/patrick/audio_sample_1.11.0+cu102.npy") print("Array 11 Shape", array_torch_11.shape) print("Array 11 abs sum", np.sum(np.abs(array_torch_11))) array_torch_12 = np.load("/home/patrick/audio_sample_1.12.1+cu102.npy") print("Array 12 Shape", array_torch_12.shape) print("Array 12 abs sum", np.sum(np.abs(array_torch_12))) ``` Having saved the tensors the print output yields: ``` torch vesion 1.12.1+cu102 torchaudio vesion 0.12.1+cu102 Array 11 Shape (122880,) Array 11 abs sum 1396.4988 Array 12 Shape (123264,) Array 12 abs sum 1396.5193 ``` ## Expected results torchaudio 11.0 and 12.1 should yield same results. ## Actual results See above. ## Environment info <!-- You can run the command `datasets-cli env` and copy-and-paste its output below. --> - `datasets` version: 2.1.1.dev0 - Platform: Linux-5.18.10-76051810-generic-x86_64-with-glibc2.34 - Python version: 3.9.7 - PyArrow version: 6.0.1 - Pandas version: 1.4.2
false
1,349,447,521
https://api.github.com/repos/huggingface/datasets/issues/4888
https://github.com/huggingface/datasets/issues/4888
4,888
Dataset Viewer issue for subjqa
closed
2
2022-08-24T13:26:20
2022-09-08T08:23:42
2022-09-08T08:23:42
lewtun
[ "dataset-viewer" ]
### Link https://huggingface.co/datasets/subjqa ### Description Getting the following error for this dataset: ``` Status code: 500 Exception: Status500Error Message: 2 or more items returned, instead of 1 ``` Not sure what's causing it though 🤔 ### Owner Yes
false
1,349,426,693
https://api.github.com/repos/huggingface/datasets/issues/4887
https://github.com/huggingface/datasets/pull/4887
4,887
Add "cc-by-nc-sa-2.0" to list of licenses
closed
2
2022-08-24T13:11:49
2022-08-26T10:31:32
2022-08-26T10:29:20
osanseviero
[]
Datasets side of https://github.com/huggingface/hub-docs/pull/285
true
1,349,285,569
https://api.github.com/repos/huggingface/datasets/issues/4886
https://github.com/huggingface/datasets/issues/4886
4,886
Loading huggan/CelebA-HQ throws pyarrow.lib.ArrowInvalid
open
9
2022-08-24T11:24:21
2023-02-02T02:40:53
null
JeanKaddour
[ "bug" ]
## Describe the bug Loading huggan/CelebA-HQ throws pyarrow.lib.ArrowInvalid ## Steps to reproduce the bug ```python from datasets import load_dataset dataset = load_dataset('huggan/CelebA-HQ') ``` ## Expected results See https://colab.research.google.com/drive/141LJCcM2XyqprPY83nIQ-Zk3BbxWeahq?usp=sharing#scrollTo=N3ml_7f8kzDd ## Actual results ``` File "/home/jean/projects/cold_diffusion/celebA.py", line 4, in <module> dataset = load_dataset('huggan/CelebA-HQ') File "/home/jean/miniconda3/envs/seq/lib/python3.10/site-packages/datasets/load.py", line 1793, in load_dataset builder_instance.download_and_prepare( File "/home/jean/miniconda3/envs/seq/lib/python3.10/site-packages/datasets/builder.py", line 704, in download_and_prepare self._download_and_prepare( File "/home/jean/miniconda3/envs/seq/lib/python3.10/site-packages/datasets/builder.py", line 793, in _download_and_prepare self._prepare_split(split_generator, **prepare_split_kwargs) File "/home/jean/miniconda3/envs/seq/lib/python3.10/site-packages/datasets/builder.py", line 1274, in _prepare_split for key, table in logging.tqdm( File "/home/jean/miniconda3/envs/seq/lib/python3.10/site-packages/tqdm/std.py", line 1195, in __iter__ for obj in iterable: File "/home/jean/miniconda3/envs/seq/lib/python3.10/site-packages/datasets/packaged_modules/parquet/parquet.py", line 67, in _generate_tables parquet_file = pq.ParquetFile(f) File "/home/jean/miniconda3/envs/seq/lib/python3.10/site-packages/pyarrow/parquet/__init__.py", line 286, in __init__ self.reader.open( File "pyarrow/_parquet.pyx", line 1227, in pyarrow._parquet.ParquetReader.open File "pyarrow/error.pxi", line 100, in pyarrow.lib.check_status pyarrow.lib.ArrowInvalid: Parquet magic bytes not found in footer. Either the file is corrupted or this is not a parquet file. ``` ## Environment info <!-- You can run the command `datasets-cli env` and copy-and-paste its output below. --> - `datasets` version: datasets-2.4.1.dev0 - Platform: Ubuntu 18.04 - Python version: 3.10 - PyArrow version: pyarrow 9.0.0
false
1,349,181,448
https://api.github.com/repos/huggingface/datasets/issues/4885
https://github.com/huggingface/datasets/issues/4885
4,885
Create dataset from list of dicts
closed
3
2022-08-24T10:01:24
2022-09-08T16:02:52
2022-09-08T16:02:52
sanderland
[ "enhancement" ]
I often find myself with data from a variety of sources, and a list of dicts is very common among these. However, converting this to a Dataset is a little awkward, requiring either ```Dataset.from_pandas(pd.DataFrame(formatted_training_data))``` Which can error out on some more exotic values as 2-d arrays for reasons that are not entirely clear > ArrowInvalid: ('Can only convert 1-dimensional array values', 'Conversion failed for column labels with type object') Alternatively: ```Dataset.from_dict({k: [s[k] for s in formatted_training_data] for k in formatted_training_data[0].keys()})``` Which works, but is a little ugly. **Describe the solution you'd like** Either `.from_dict` accepting a list of dicts, or a `.from_records` function accepting such. I am happy to PR this, just wanted to check you are happy to accept this I haven't missed something obvious, and which of the solutions would be prefered.
false
1,349,105,946
https://api.github.com/repos/huggingface/datasets/issues/4884
https://github.com/huggingface/datasets/pull/4884
4,884
Fix documentation card of math_qa dataset
closed
1
2022-08-24T09:00:56
2022-08-24T11:33:17
2022-08-24T11:33:16
albertvillanova
[]
Fix documentation card of math_qa dataset.
true
1,349,083,235
https://api.github.com/repos/huggingface/datasets/issues/4883
https://github.com/huggingface/datasets/issues/4883
4,883
With dataloader RSS memory consumed by HF datasets monotonically increases
open
44
2022-08-24T08:42:54
2024-01-23T12:42:40
null
apsdehal
[ "bug" ]
## Describe the bug When the HF datasets is used in conjunction with PyTorch Dataloader, the RSS memory of the process keeps on increasing when it should stay constant. ## Steps to reproduce the bug Run and observe the output of this snippet which logs RSS memory. ```python import psutil import os from transformers import BertTokenizer from datasets import load_dataset from torch.utils.data import DataLoader BATCH_SIZE = 32 NUM_TRIES = 10 tokenizer = BertTokenizer.from_pretrained("bert-base-uncased") def transform(x): x.update(tokenizer(x["text"], return_tensors="pt", max_length=64, padding="max_length", truncation=True)) x.pop("text") x.pop("label") return x dataset = load_dataset("imdb", split="train") dataset.set_transform(transform) train_loader = DataLoader(dataset, batch_size=BATCH_SIZE, shuffle=True, num_workers=4) mem_before = psutil.Process(os.getpid()).memory_info().rss / (1024 * 1024) count = 0 while count < NUM_TRIES: for idx, batch in enumerate(train_loader): mem_after = psutil.Process(os.getpid()).memory_info().rss / (1024 * 1024) print(count, idx, mem_after - mem_before) count += 1 ``` ## Expected results Memory should not increase after initial setup and loading of the dataset ## Actual results Memory continuously increases as can be seen in the log. ## Environment info <!-- You can run the command `datasets-cli env` and copy-and-paste its output below. --> - `datasets` version: 2.3.2 - Platform: Linux-4.19.0-21-cloud-amd64-x86_64-with-glibc2.10 - Python version: 3.8.13 - PyArrow version: 7.0.0
false
1,348,913,665
https://api.github.com/repos/huggingface/datasets/issues/4882
https://github.com/huggingface/datasets/pull/4882
4,882
Fix language tags resource file
closed
1
2022-08-24T06:06:01
2022-08-24T13:58:33
2022-08-24T13:58:30
albertvillanova
[]
This PR fixes/updates/adds ALL language tags from IANA (as of 2022-08-08). This PR also removes all BCP47 suffixes (the languages file only contains language subtags, i.e. ISO 639 1 or 2 codes; no script/region/variant suffixes). See: - #4753
true
1,348,495,777
https://api.github.com/repos/huggingface/datasets/issues/4881
https://github.com/huggingface/datasets/issues/4881
4,881
Language names and language codes: connecting to a big database (rather than slow enrichment of custom list)
open
49
2022-08-23T20:14:24
2024-04-22T15:57:28
null
alexis-michaud
[ "enhancement" ]
**The problem:** Language diversity is an important dimension of the diversity of datasets. To find one's way around datasets, being able to search by language name and by standardized codes appears crucial. Currently the list of language codes is [here](https://github.com/huggingface/datasets/blob/main/src/datasets/utils/resources/languages.json), right? At about 1,500 entries, it is roughly at 1/4th of the world's diversity of extant languages. (Probably less, as the list of 1,418 contains variants that are linguistically very close: 108 varieties of English, for instance.) Looking forward to ever increasing coverage, how will the list of language names and language codes improve over time? Enrichment of the custom list by HFT contributors (like [here](https://github.com/huggingface/datasets/pull/4880)) has several issues: * progress is likely to be slow: ![image](https://user-images.githubusercontent.com/6072524/186253353-62f42168-3d31-4105-be1c-5eb1f818d528.png) (input required from reviewers, etc.) * the more contributors, the less consistency can be expected among contributions. No need to elaborate on how much confusion is likely to ensue as datasets accumulate. * there is no information on which language relates with which: no encoding of the special closeness between the languages of the Northwestern Germanic branch (English+Dutch+German etc.), for instance. Information on phylogenetic closeness can be relevant to run experiments on transfer of technology from one language to its close relatives. **A solution that seems desirable:** Connecting to an established database that (i) aims at full coverage of the world's languages and (ii) has information on higher-level groupings, alternative names, etc. It takes a lot of hard work to do such databases. Two important initiatives are [Ethnologue](https://www.ethnologue.com/) (ISO standard) and [Glottolog](https://glottolog.org/). Both have pros and cons. Glottolog contains references to Ethnologue identifiers, so adopting Glottolog entails getting the advantages of both sets of language codes. Both seem technically accessible & 'developer-friendly'. Glottolog has a [GitHub repo](https://github.com/glottolog/glottolog). For Ethnologue, harvesting tools have been devised (see [here](https://github.com/lyy1994/ethnologue); I did not try it out). In case a conversation with linguists seemed in order here, I'd be happy to participate ('pro bono', of course), & to rustle up more colleagues as useful, to help this useful development happen. With appreciation of HFT,
false
1,348,452,776
https://api.github.com/repos/huggingface/datasets/issues/4880
https://github.com/huggingface/datasets/pull/4880
4,880
Added names of less-studied languages
closed
2
2022-08-23T19:32:38
2022-08-24T12:52:46
2022-08-24T12:52:46
BenjaminGalliot
[]
Added names of less-studied languages (nru – Narua and jya – Japhug) for existing datasets.
true
1,348,346,407
https://api.github.com/repos/huggingface/datasets/issues/4879
https://github.com/huggingface/datasets/pull/4879
4,879
Fix Citation Information section in dataset cards
closed
1
2022-08-23T18:06:43
2022-09-27T14:04:45
2022-08-24T04:09:07
albertvillanova
[]
Fix Citation Information section in dataset cards: - cc_news - conllpp - datacommons_factcheck - gnad10 - id_panl_bppt - jigsaw_toxicity_pred - kinnews_kirnews - kor_sarcasm - makhzan - reasoning_bg - ro_sts - ro_sts_parallel - sanskrit_classic - telugu_news - thaiqa_squad - wiki_movies This PR partially fixes the Citation Information section in dataset cards. Subsequent PRs will follow to complete this task.
true
1,348,270,141
https://api.github.com/repos/huggingface/datasets/issues/4878
https://github.com/huggingface/datasets/issues/4878
4,878
[not really a bug] `identical_ok` is deprecated in huggingface-hub's `upload_file`
closed
1
2022-08-23T17:09:55
2022-09-13T14:00:06
2022-09-13T14:00:05
severo
[ "help wanted", "question" ]
In the huggingface-hub dependency, the `identical_ok` argument has no effect in `upload_file` (and it will be removed soon) See https://github.com/huggingface/huggingface_hub/blob/43499582b19df1ed081a5b2bd7a364e9cacdc91d/src/huggingface_hub/hf_api.py#L2164-L2169 It's used here: https://github.com/huggingface/datasets/blob/fcfcc951a73efbc677f9def9a8707d0af93d5890/src/datasets/dataset_dict.py#L1373-L1381 https://github.com/huggingface/datasets/blob/fdcb8b144ce3ef241410281e125bd03e87b8caa1/src/datasets/arrow_dataset.py#L4354-L4362 https://github.com/huggingface/datasets/blob/fdcb8b144ce3ef241410281e125bd03e87b8caa1/src/datasets/arrow_dataset.py#L4197-L4213 We should remove it. Maybe the third code sample has an unexpected behavior since it uses the non-default value `identical_ok = False`, but the argument is ignored.
false
1,348,246,755
https://api.github.com/repos/huggingface/datasets/issues/4877
https://github.com/huggingface/datasets/pull/4877
4,877
Fix documentation card of covid_qa_castorini dataset
closed
1
2022-08-23T16:52:33
2022-08-23T18:05:01
2022-08-23T18:05:00
albertvillanova
[]
Fix documentation card of covid_qa_castorini dataset.
true
1,348,202,678
https://api.github.com/repos/huggingface/datasets/issues/4876
https://github.com/huggingface/datasets/issues/4876
4,876
Move DatasetInfo from `datasets_infos.json` to the YAML tags in `README.md`
closed
15
2022-08-23T16:16:41
2022-10-03T09:11:13
2022-10-03T09:11:13
lhoestq
[]
Currently there are two places to find metadata for datasets: - datasets_infos.json, which contains **per dataset config** - description - citation - license - splits and sizes - checksums of the data files - feature types - and more - YAML tags, which contain - license - language - train-eval-index - and more It would be nice to have a single place instead. We can rely on the YAML tags more than the JSON file for consistency with models. And it would all be indexed by our back-end directly, which is nice to have. One way would be to move everything to the YAML tags except the checksums (there can be tens of thousands of them). The description/citation is already in the dataset card so we probably don't need to have them in the YAML card, it would be redundant. Here is an example for SQuAD ```yaml download_size: 35142551 dataset_size: 89789763 version: 1.0.0 splits: - name: train num_examples: 87599 num_bytes: 79317110 - name: validation num_examples: 10570 num_bytes: 10472653 features: - name: id dtype: string - name: title dtype: string - name: context dtype: string - name: question dtype: string - name: answers struct: - name: text list: dtype: string - name: answer_start list: dtype: int32 ``` Since there is only one configuration for SQuAD, this structure is ok. For datasets with several configs we can see in a second step, but IMO it would be ok to have these fields per config using another syntax ```yaml configs: - config: unlabeled splits: - name: train num_examples: 10000 features: - name: text dtype: string - config: labeled splits: - name: train num_examples: 100 features: - name: text dtype: string - name: label dtype: ClassLabel names: - negative - positive ``` So in the end you could specify a YAML tag either at the top level (for all configs) or per config in the `configs` field Alternatively we could keep config specific stuff in the `dataset_infos.json` as it it today Not sure yet what's the best approach here but cc @julien-c @mariosasko @albertvillanova @polinaeterna for feedback :)
false
1,348,095,686
https://api.github.com/repos/huggingface/datasets/issues/4875
https://github.com/huggingface/datasets/issues/4875
4,875
`_resolve_features` ignores the token
open
11
2022-08-23T14:57:36
2022-10-17T13:45:47
null
severo
[]
## Describe the bug When calling [`_resolve_features()`](https://github.com/huggingface/datasets/blob/54b532a8a2f5353fdb0207578162153f7b2da2ec/src/datasets/iterable_dataset.py#L1255) on a gated dataset, ie. a dataset which requires a token to be loaded, the token seems to be ignored even if it has been provided to `load_dataset` before. ## Steps to reproduce the bug ```python import os os.environ["HF_ENDPOINT"] = "https://hub-ci.huggingface.co/" hf_token = "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" from datasets import load_dataset # public dataset_name = "__DUMMY_DATASETS_SERVER_USER__/repo_csv_data-16612654226756" config_name = "__DUMMY_DATASETS_SERVER_USER__--repo_csv_data-16612654226756" split_name = "train" iterable_dataset = load_dataset( dataset_name, name=config_name, split=split_name, streaming=True, use_auth_token=hf_token, ) iterable_dataset = iterable_dataset._resolve_features() print(iterable_dataset.features) # gated dataset_name = "__DUMMY_DATASETS_SERVER_USER__/repo_csv_data-16612654317644" config_name = "__DUMMY_DATASETS_SERVER_USER__--repo_csv_data-16612654317644" split_name = "train" iterable_dataset = load_dataset( dataset_name, name=config_name, split=split_name, streaming=True, use_auth_token=hf_token, ) try: iterable_dataset = iterable_dataset._resolve_features() except FileNotFoundError as e: print("FAILS") ``` ## Expected results I expect to have the same result on a public dataset and on a gated (or private) dataset, if the token has been provided. ## Actual results An exception is thrown on gated datasets. ## Environment info - `datasets` version: 2.4.0 - Platform: Linux-5.15.0-1017-aws-x86_64-with-glibc2.35 - Python version: 3.9.6 - PyArrow version: 7.0.0 - Pandas version: 1.4.2
false
1,347,618,197
https://api.github.com/repos/huggingface/datasets/issues/4874
https://github.com/huggingface/datasets/pull/4874
4,874
[docs] Some tiny doc tweaks
closed
1
2022-08-23T09:19:40
2022-08-24T17:27:57
2022-08-24T17:27:56
julien-c
[]
null
true
1,347,592,022
https://api.github.com/repos/huggingface/datasets/issues/4873
https://github.com/huggingface/datasets/issues/4873
4,873
Multiple dataloader memory error
open
3
2022-08-23T08:59:50
2023-01-26T02:01:11
null
cyk1337
[ "bug" ]
For the use of multiple datasets and tasks, we use around more than 200+ dataloaders, then pass it into `dataloader1, dataloader2, ..., dataloader200=accelerate.prepare(dataloader1, dataloader2, ..., dataloader200)` It causes the memory error when generating batches. Any solutions to it? ```bash File "/home/xxx/my_code/src/utils/data_utils.py", line 54, in generate_batch x = next(iterator) File "/home/xxx/anaconda3/envs/pt1.7/lib/python3.7/site-packages/accelerate/data_loader.py", line 301, in __iter__ for batch in super().__iter__(): File "/home/xxx/anaconda3/envs/pt1.7/lib/python3.7/site-packages/torch/utils/data/dataloader.py", line 435, in __next__ data = self._next_data() File "/home/xxx/anaconda3/envs/pt1.7/lib/python3.7/site-packages/torch/utils/data/dataloader.py", line 475, in _next_data data = self._dataset_fetcher.fetch(index) # may raise StopIteration File "/home/xxx/anaconda3/envs/pt1.7/lib/python3.7/site-packages/torch/utils/data/_utils/fetch.py", line 28, in fetch data.append(next(self.dataset_iter)) File "/home/xxx/anaconda3/envs/pt1.7/lib/python3.7/site-packages/accelerate/data_loader.py", line 249, in __iter__ for element in self.dataset: File "/home/xxx/anaconda3/envs/pt1.7/lib/python3.7/site-packages/datasets/iterable_dataset.py", line 503, in __iter__ for key, example in self._iter(): File "/home/xxx/anaconda3/envs/pt1.7/lib/python3.7/site-packages/datasets/iterable_dataset.py", line 500, in _iter yield from ex_iterable File "/home/xxx/anaconda3/envs/pt1.7/lib/python3.7/site-packages/datasets/iterable_dataset.py", line 231, in __iter__ new_key = "_".join(str(key) for key in keys) MemoryError ```
false
1,347,180,765
https://api.github.com/repos/huggingface/datasets/issues/4872
https://github.com/huggingface/datasets/pull/4872
4,872
Docs for creating an audio dataset
closed
6
2022-08-23T01:07:09
2022-09-22T17:19:13
2022-09-21T10:27:04
stevhliu
[ "documentation" ]
This PR is a first draft of how to create audio datasets (`AudioFolder` and loading script). Feel free to let me know if there are any specificities I'm missing for this. 🙂
true
1,346,703,568
https://api.github.com/repos/huggingface/datasets/issues/4871
https://github.com/huggingface/datasets/pull/4871
4,871
Fix: wmt datasets - fix CWMT zh subsets
closed
1
2022-08-22T16:42:09
2022-08-23T10:00:20
2022-08-23T10:00:19
lhoestq
[]
Fix https://github.com/huggingface/datasets/issues/4575 TODO: run `datasets-cli test`: - [x] wmt17 - [x] wmt18 - [x] wmt19
true
1,346,160,498
https://api.github.com/repos/huggingface/datasets/issues/4870
https://github.com/huggingface/datasets/pull/4870
4,870
audio folder check CI
closed
1
2022-08-22T10:15:53
2022-11-02T11:54:35
2022-08-22T12:19:40
polinaeterna
[]
null
true
1,345,513,758
https://api.github.com/repos/huggingface/datasets/issues/4869
https://github.com/huggingface/datasets/pull/4869
4,869
Fix typos in documentation
closed
1
2022-08-21T15:10:03
2022-08-22T09:25:39
2022-08-22T09:09:58
fl-lo
[]
null
true
1,345,191,322
https://api.github.com/repos/huggingface/datasets/issues/4868
https://github.com/huggingface/datasets/pull/4868
4,868
adding mafand to datasets
closed
6
2022-08-20T15:26:14
2022-08-22T11:00:50
2022-08-22T08:52:23
dadelani
[ "wontfix" ]
I'm addding the MAFAND dataset by Masakhane based on the paper/repository below: Paper: https://aclanthology.org/2022.naacl-main.223/ Code: https://github.com/masakhane-io/lafand-mt Please, help merge this Everything works except for creating dummy data file
true
1,344,982,646
https://api.github.com/repos/huggingface/datasets/issues/4867
https://github.com/huggingface/datasets/pull/4867
4,867
Complete tags of superglue dataset card
closed
1
2022-08-19T23:44:39
2022-08-22T09:14:03
2022-08-22T08:58:31
richarddwang
[]
Related to #4479 .
true
1,344,809,132
https://api.github.com/repos/huggingface/datasets/issues/4866
https://github.com/huggingface/datasets/pull/4866
4,866
amend docstring for dunder
open
1
2022-08-19T19:09:15
2022-09-09T16:33:11
null
schafsam
[]
display dunder method in docsting with underlines an not bold markdown.
true
1,344,552,626
https://api.github.com/repos/huggingface/datasets/issues/4865
https://github.com/huggingface/datasets/issues/4865
4,865
Dataset Viewer issue for MoritzLaurer/multilingual_nli
closed
4
2022-08-19T14:55:20
2022-08-22T14:47:14
2022-08-22T06:13:20
MoritzLaurer
[ "dataset-viewer" ]
### Link _No response_ ### Description I've just uploaded a new dataset to the hub and the viewer does not work for some reason, see here: https://huggingface.co/datasets/MoritzLaurer/multilingual_nli It displays the error: ``` Status code: 400 Exception: Status400Error Message: The dataset does not exist. ``` Weirdly enough the dataviewer works for an earlier version of the same dataset. The only difference is that it is smaller, but I'm not aware of other changes I have made: https://huggingface.co/datasets/MoritzLaurer/multilingual_nli_test Do you know why the dataviewer is not working? ### Owner _No response_
false
1,344,410,043
https://api.github.com/repos/huggingface/datasets/issues/4864
https://github.com/huggingface/datasets/issues/4864
4,864
Allow pathlib PoxisPath in Dataset.read_json
open
7
2022-08-19T12:59:17
2025-04-11T17:22:48
null
changjonathanc
[ "enhancement" ]
**Is your feature request related to a problem? Please describe.** ``` from pathlib import Path from datasets import Dataset ds = Dataset.read_json(Path('data.json')) ``` causes an error ``` AttributeError: 'PosixPath' object has no attribute 'decode' ``` **Describe the solution you'd like** It should be able to accept PosixPath and read the json from inside.
false
1,343,737,668
https://api.github.com/repos/huggingface/datasets/issues/4863
https://github.com/huggingface/datasets/issues/4863
4,863
TFDS wiki_dialog dataset to Huggingface dataset
closed
4
2022-08-18T23:06:30
2022-08-22T09:41:45
2022-08-22T05:18:53
djaym7
[ "dataset request" ]
## Adding a Dataset - **Name:** *Wiki_dialog* - **Description: https://github.com/google-research/dialog-inpainting#:~:text=JSON%20object%2C%20for-,example,-%3A - **Paper: https://arxiv.org/abs/2205.09073 - **Data: https://github.com/google-research/dialog-inpainting - **Motivation:** *Research and Development on biggest corpus of dialog data* Instructions to add a new dataset can be found [here](https://github.com/huggingface/datasets/blob/main/ADD_NEW_DATASET.md).
false
1,343,464,699
https://api.github.com/repos/huggingface/datasets/issues/4862
https://github.com/huggingface/datasets/issues/4862
4,862
Got "AttributeError: 'xPath' object has no attribute 'read'" when loading an excel dataset with my own code
closed
5
2022-08-18T18:36:14
2022-08-31T09:25:08
2022-08-31T09:25:08
yana-xuyan
[ "bug" ]
## Describe the bug A clear and concise description of what the bug is. ## Steps to reproduce the bug ```python # Sample code to reproduce the bug # The dataset function is as follows: from pathlib import Path from typing import Dict, List, Tuple import datasets import pandas as pd _CITATION = """\ """ _DATASETNAME = "jadi_ide" _DESCRIPTION = """\ """ _HOMEPAGE = "" _LICENSE = "Unknown" _URLS = { _DATASETNAME: "https://github.com/fathanick/Javanese-Dialect-Identification-from-Twitter-Data/raw/main/Update 16K_Dataset.xlsx", } _SOURCE_VERSION = "1.0.0" class JaDi_Ide(datasets.GeneratorBasedBuilder): SOURCE_VERSION = datasets.Version(_SOURCE_VERSION) BUILDER_CONFIGS = [ NusantaraConfig( name="jadi_ide_source", version=SOURCE_VERSION, description="JaDi-Ide source schema", schema="source", subset_id="jadi_ide", ), ] DEFAULT_CONFIG_NAME = "source" def _info(self) -> datasets.DatasetInfo: if self.config.schema == "source": features = datasets.Features( { "id": datasets.Value("string"), "text": datasets.Value("string"), "label": datasets.Value("string") } ) return datasets.DatasetInfo( description=_DESCRIPTION, features=features, homepage=_HOMEPAGE, license=_LICENSE, citation=_CITATION, ) def _split_generators(self, dl_manager: datasets.DownloadManager) -> List[datasets.SplitGenerator]: """Returns SplitGenerators.""" # Dataset does not have predetermined split, putting all as TRAIN urls = _URLS[_DATASETNAME] base_dir = Path(dl_manager.download_and_extract(urls)) data_files = {"train": base_dir} return [ datasets.SplitGenerator( name=datasets.Split.TRAIN, gen_kwargs={ "filepath": data_files["train"], "split": "train", }, ), ] def _generate_examples(self, filepath: Path, split: str) -> Tuple[int, Dict]: """Yields examples as (key, example) tuples.""" df = pd.read_excel(filepath, engine='openpyxl') df.columns = ["id", "text", "label"] if self.config.schema == "source": for row in df.itertuples(): ex = { "id": str(row.id), "text": row.text, "label": row.label, } yield row.id, ex ``` ## Expected results Expecting to load the dataset smoothly. ## Actual results File "/home/xuyan/anaconda3/lib/python3.7/site-packages/datasets/load.py", line 1751, in load_dataset use_auth_token=use_auth_token, File "/home/xuyan/anaconda3/lib/python3.7/site-packages/datasets/builder.py", line 705, in download_and_prepare dl_manager=dl_manager, verify_infos=verify_infos, **download_and_prepare_kwargs File "/home/xuyan/anaconda3/lib/python3.7/site-packages/datasets/builder.py", line 1227, in _download_and_prepare super()._download_and_prepare(dl_manager, verify_infos, check_duplicate_keys=verify_infos) File "/home/xuyan/anaconda3/lib/python3.7/site-packages/datasets/builder.py", line 793, in _download_and_prepare self._prepare_split(split_generator, **prepare_split_kwargs) File "/home/xuyan/anaconda3/lib/python3.7/site-packages/datasets/builder.py", line 1216, in _prepare_split desc=f"Generating {split_info.name} split", File "/home/xuyan/anaconda3/lib/python3.7/site-packages/tqdm/std.py", line 1195, in __iter__ for obj in iterable: File "/home/xuyan/.cache/huggingface/modules/datasets_modules/datasets/jadi_ide/7a539f2b6f726defea8fbe36ceda17bae66c370f6d6c418e3a08d760ebef7519/jadi_ide.py", line 107, in _generate_examples df = pd.read_excel(filepath, engine='openpyxl') File "/home/xuyan/anaconda3/lib/python3.7/site-packages/datasets/download/streaming_download_manager.py", line 701, in xpandas_read_excel return pd.read_excel(BytesIO(filepath_or_buffer.read()), **kwargs) AttributeError: 'xPath' object has no attribute 'read' ## Environment info <!-- You can run the command `datasets-cli env` and copy-and-paste its output below. --> - `datasets` version: 2.4.0 - Platform: Linux-4.15.0-142-generic-x86_64-with-debian-stretch-sid - Python version: 3.7.4 - PyArrow version: 9.0.0 - Pandas version: 0.25.1
false
1,343,260,220
https://api.github.com/repos/huggingface/datasets/issues/4861
https://github.com/huggingface/datasets/issues/4861
4,861
Using disk for memory with the method `from_dict`
open
1
2022-08-18T15:18:18
2023-01-26T18:36:28
null
HugoLaurencon
[ "enhancement" ]
**Is your feature request related to a problem? Please describe.** I start with an empty dataset. In a loop, at each iteration, I create a new dataset with the method `from_dict` (based on some data I load) and I concatenate this new dataset with the one at the previous iteration. After some iterations, I have an OOM error. **Describe the solution you'd like** The method `from_dict` loads the data in RAM. It could be good to add an option to use the disk instead. **Describe alternatives you've considered** To solve the problem, I have to do an intermediate step where I save the new datasets at each iteration with `save_to_disk`. Once it's done, I open them all and concatenate them.
false
1,342,311,540
https://api.github.com/repos/huggingface/datasets/issues/4860
https://github.com/huggingface/datasets/pull/4860
4,860
Add collection3 dataset
closed
7
2022-08-17T21:31:42
2022-08-23T20:02:45
2022-08-22T09:08:59
pefimov
[ "wontfix" ]
null
true
1,342,231,016
https://api.github.com/repos/huggingface/datasets/issues/4859
https://github.com/huggingface/datasets/issues/4859
4,859
can't install using conda on Windows 10
open
0
2022-08-17T19:57:37
2022-08-17T19:57:37
null
xoffey
[ "bug" ]
## Describe the bug I wanted to install using conda or Anaconda navigator. That didn't work, so I had to install using pip. ## Steps to reproduce the bug conda install -c huggingface -c conda-forge datasets ## Expected results Should have indicated successful installation. ## Actual results Solving environment: failed with initial frozen solve. Retrying with flexible solve. Solving environment: failed with repodata from current_repodata.json, will retry with next repodata source. ... took forever, so I cancelled it with ctrl-c ## Environment info - `datasets` version: 2.4.0 # after installing with pip - Platform: Windows-10-10.0.19044-SP0 - Python version: 3.9.12 - PyArrow version: 9.0.0 - Pandas version: 1.4.2 - conda version: 4.13.0 conda info active environment : base active env location : G:\anaconda2022 shell level : 1 user config file : C:\Users\michael\.condarc populated config files : C:\Users\michael\.condarc conda version : 4.13.0 conda-build version : 3.21.8 python version : 3.9.12.final.0 virtual packages : __cuda=11.1=0 __win=0=0 __archspec=1=x86_64 base environment : G:\anaconda2022 (writable) conda av data dir : G:\anaconda2022\etc\conda conda av metadata url : None channel URLs : https://conda.anaconda.org/pytorch/win-64 https://conda.anaconda.org/pytorch/noarch https://conda.anaconda.org/huggingface/win-64 https://conda.anaconda.org/huggingface/noarch https://conda.anaconda.org/conda-forge/win-64 https://conda.anaconda.org/conda-forge/noarch https://conda.anaconda.org/anaconda-fusion/win-64 https://conda.anaconda.org/anaconda-fusion/noarch https://repo.anaconda.com/pkgs/main/win-64 https://repo.anaconda.com/pkgs/main/noarch https://repo.anaconda.com/pkgs/r/win-64 https://repo.anaconda.com/pkgs/r/noarch https://repo.anaconda.com/pkgs/msys2/win-64 https://repo.anaconda.com/pkgs/msys2/noarch package cache : G:\anaconda2022\pkgs C:\Users\michael\.conda\pkgs C:\Users\michael\AppData\Local\conda\conda\pkgs envs directories : G:\anaconda2022\envs C:\Users\michael\.conda\envs C:\Users\michael\AppData\Local\conda\conda\envs platform : win-64 user-agent : conda/4.13.0 requests/2.27.1 CPython/3.9.12 Windows/10 Windows/10.0.19044 administrator : False netrc file : None offline mode : False
false
1,340,859,853
https://api.github.com/repos/huggingface/datasets/issues/4858
https://github.com/huggingface/datasets/issues/4858
4,858
map() function removes columns when input_columns is not None
closed
3
2022-08-16T20:42:30
2022-09-22T13:55:24
2022-09-22T13:55:24
pramodith
[ "bug" ]
## Describe the bug The map function, removes features from the dataset that are not present in the _input_columns_ list of columns, despite the columns being removed not mentioned in the _remove_columns_ argument. ## Steps to reproduce the bug ```python from datasets import Dataset ds = Dataset.from_dict({"a" : [1,2,3],"b" : [0,1,0], "c" : [2,4,5]}) def double(x,y): x = x*2 y = y*2 return {"d" : x, "e" : y} ds.map(double, input_columns=["a","c"]) ``` ## Expected results ``` Dataset({ features: ['a', 'b', 'c', 'd', 'e'], num_rows: 3 }) ``` ## Actual results ``` Dataset({ features: ['a', 'c', 'd', 'e'], num_rows: 3 }) ``` In this specific example feature **b** should not be removed. ## Environment info <!-- You can run the command `datasets-cli env` and copy-and-paste its output below. --> - `datasets` version: 2.4.0 - Platform: linux (colab) - Python version: 3.7.13 - PyArrow version: 6.0.1
false
1,340,397,153
https://api.github.com/repos/huggingface/datasets/issues/4857
https://github.com/huggingface/datasets/issues/4857
4,857
No preprocessed wikipedia is working on huggingface/datasets
closed
2
2022-08-16T13:55:33
2022-08-17T13:35:08
2022-08-17T13:35:08
aninrusimha
[ "bug" ]
## Describe the bug 20220301 wikipedia dump has been deprecated, so now there is no working wikipedia dump on huggingface https://huggingface.co/datasets/wikipedia https://dumps.wikimedia.org/enwiki/
false
1,339,779,957
https://api.github.com/repos/huggingface/datasets/issues/4856
https://github.com/huggingface/datasets/issues/4856
4,856
file missing when load_dataset with openwebtext on windows
closed
1
2022-08-16T04:04:22
2023-01-04T03:39:12
2023-01-04T03:39:12
xi-loong
[ "bug" ]
## Describe the bug 0015896-b1054262f7da52a0518521e29c8e352c.txt is missing when I run run_mlm.py with openwebtext. I check the cache_path and can not find 0015896-b1054262f7da52a0518521e29c8e352c.txt. but I can find this file in the 17ecf461bfccd469a1fbc264ccb03731f8606eea7b3e2e8b86e13d18040bf5b3/urlsf_subset00-16_data.xz with 7-zip. ## Steps to reproduce the bug ```sh python run_mlm.py --model_type roberta --tokenizer_name roberta-base --dataset_name openwebtext --per_device_train_batch_size 8 --per_device_eval_batch_size 8 --do_train --do_eval --output_dir F:/model/roberta-base ``` or ```python from datasets import load_dataset load_dataset("openwebtext", None, cache_dir=None, use_auth_token=None) ``` ## Expected results Loading is successful ## Actual results Traceback (most recent call last): File "D:\Python\v3.8.5\lib\site-packages\datasets\builder.py", line 704, in download_and_prepare self._download_and_prepare( File "D:\Python\v3.8.5\lib\site-packages\datasets\builder.py", line 1227, in _download_and_prepare super()._download_and_prepare(dl_manager, verify_infos, check_duplicate_keys=verify_infos) File "D:\Python\v3.8.5\lib\site-packages\datasets\builder.py", line 795, in _download_and_prepare raise OSError( OSError: Cannot find data file. Original error: [Errno 22] Invalid argument: 'F://huggingface/datasets/downloads/extracted/0901d27f43b7e9ac0577da0d0061c8c632ba0b70ecd1b4bfb21562d9b7486faa/0015896-b1054262f7da52a0518521e29c8e352c.txt' ## Environment info <!-- You can run the command `datasets-cli env` and copy-and-paste its output below. --> - `datasets` version: 2.4.0 - Platform: windows - Python version: 3.8.5 - PyArrow version: 9.0.0
false
1,339,699,975
https://api.github.com/repos/huggingface/datasets/issues/4855
https://github.com/huggingface/datasets/issues/4855
4,855
Dataset Viewer issue for super_glue
closed
1
2022-08-16T01:34:56
2022-08-22T10:08:01
2022-08-22T10:07:45
wzsxxa
[ "dataset-viewer" ]
### Link https://huggingface.co/datasets/super_glue ### Description can't view super_glue dataset on the web page ### Owner _No response_
false
1,339,456,490
https://api.github.com/repos/huggingface/datasets/issues/4853
https://github.com/huggingface/datasets/pull/4853
4,853
Fix bug and checksums in exams dataset
closed
1
2022-08-15T20:17:57
2022-08-16T06:43:57
2022-08-16T06:29:06
albertvillanova
[]
Fix #4852.
true
1,339,450,991
https://api.github.com/repos/huggingface/datasets/issues/4852
https://github.com/huggingface/datasets/issues/4852
4,852
Bug in multilingual_with_para config of exams dataset and checksums error
closed
2
2022-08-15T20:14:52
2022-09-16T09:50:55
2022-08-16T06:29:07
albertvillanova
[ "bug" ]
## Describe the bug There is a bug for "multilingual_with_para" config in exams dataset: ```python ds = load_dataset("./datasets/exams", split="train") ``` raises: ``` KeyError: 'choices' ``` Moreover, there is a NonMatchingChecksumError: ``` NonMatchingChecksumError: Checksums didn't match for dataset source files: ['https://github.com/mhardalov/exams-qa/raw/main/data/exams/multilingual/with_paragraphs/train_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/multilingual/with_paragraphs/dev_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/multilingual/with_paragraphs/test_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/test_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/train_bg_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/dev_bg_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/train_hr_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/dev_hr_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/train_hu_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/dev_hu_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/train_it_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/dev_it_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/train_mk_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/dev_mk_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/train_pl_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/dev_pl_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/train_pt_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/dev_pt_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/train_sq_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/dev_sq_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/train_sr_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/dev_sr_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/train_tr_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/dev_tr_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/train_vi_with_para.jsonl.tar.gz', 'https://github.com/mhardalov/exams-qa/raw/main/data/exams/cross-lingual/with_paragraphs/dev_vi_with_para.jsonl.tar.gz'] ``` CC: @thesofakillers
false
1,339,085,917
https://api.github.com/repos/huggingface/datasets/issues/4851
https://github.com/huggingface/datasets/pull/4851
4,851
Fix license tag and Source Data section in billsum dataset card
closed
2
2022-08-15T14:37:00
2022-08-22T13:56:24
2022-08-22T13:40:59
kashif
[]
Fixed the data source and license fields
true
1,338,702,306
https://api.github.com/repos/huggingface/datasets/issues/4850
https://github.com/huggingface/datasets/pull/4850
4,850
Fix test of _get_extraction_protocol for TAR files
closed
1
2022-08-15T08:37:58
2022-08-15T09:42:56
2022-08-15T09:28:46
albertvillanova
[]
While working in another PR, I discovered an xpass test (a test that is supposed to xfail but nevertheless passes) when testing `_get_extraction_protocol`: https://github.com/huggingface/datasets/runs/7818845285?check_suite_focus=true ``` XPASS tests/test_streaming_download_manager.py::test_streaming_dl_manager_get_extraction_protocol_throws[https://foo.bar/train.tar] ``` This PR: - refactors the test so that it tests the raise of the exceptions instead of xfailing - fixes the test for TAR files: it does not raise an exception, but returns "tar" - fixes some tests wrongly named: exchange `test_streaming_dl_manager_get_extraction_protocol` with `test_streaming_dl_manager_get_extraction_protocol_gg_drive`
true
1,338,273,900
https://api.github.com/repos/huggingface/datasets/issues/4849
https://github.com/huggingface/datasets/pull/4849
4,849
1.18.x
closed
0
2022-08-14T15:09:19
2022-08-14T15:10:02
2022-08-14T15:10:02
Mr-Robot-001
[]
null
true
1,338,271,833
https://api.github.com/repos/huggingface/datasets/issues/4848
https://github.com/huggingface/datasets/pull/4848
4,848
a
closed
0
2022-08-14T15:01:16
2022-08-14T15:09:59
2022-08-14T15:09:59
Mr-Robot-001
[]
null
true
1,338,270,636
https://api.github.com/repos/huggingface/datasets/issues/4847
https://github.com/huggingface/datasets/pull/4847
4,847
Test win ci
closed
0
2022-08-14T14:57:00
2023-09-24T10:04:13
2022-08-14T14:57:45
Mr-Robot-001
[]
aa
true
1,337,979,897
https://api.github.com/repos/huggingface/datasets/issues/4846
https://github.com/huggingface/datasets/pull/4846
4,846
Update documentation card of miam dataset
closed
4
2022-08-13T14:38:55
2022-08-17T00:50:04
2022-08-14T10:26:08
PierreColombo
[]
Hi ! Paper has been published at EMNLP.
true
1,337,928,283
https://api.github.com/repos/huggingface/datasets/issues/4845
https://github.com/huggingface/datasets/pull/4845
4,845
Mark CI tests as xfail if Hub HTTP error
closed
1
2022-08-13T10:45:11
2022-08-23T04:57:12
2022-08-23T04:42:26
albertvillanova
[]
In order to make testing more robust (and avoid merges to master with red tests), we could mark tests as xfailed (instead of failed) when the Hub raises some temporary HTTP errors. This PR: - marks tests as xfailed only if the Hub raises a 500 error for: - test_upstream_hub - makes pytest report the xfailed/xpassed tests. More tests could also be marked if needed. Examples of CI failures due to temporary Hub HTTP errors: - FAILED tests/test_upstream_hub.py::TestPushToHub::test_push_dataset_dict_to_hub_multiple_files - https://github.com/huggingface/datasets/runs/7806855399?check_suite_focus=true `requests.exceptions.HTTPError: 500 Server Error: Internal Server Error for url: https://hub-ci.huggingface.co/api/datasets/__DUMMY_TRANSFORMERS_USER__/test-16603108028233/commit/main (Request ID: aZeAQ5yLktoGHQYBcJ3zo)` - FAILED tests/test_upstream_hub.py::TestPushToHub::test_push_dataset_dict_to_hub_no_token - https://github.com/huggingface/datasets/runs/7840022996?check_suite_focus=true `requests.exceptions.HTTPError: 500 Server Error: Internal Server Error for url: https://s3.us-east-1.amazonaws.com/lfs-staging.huggingface.co/repos/81/e3/81e3b831fa9bf23190ec041f26ef7ff6d6b71c1a937b8ec1ef1f1f05b508c089/caae596caa179cf45e7c9ac0c6d9a9cb0fe2d305291bfbb2d8b648ae26ed38b6?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Credential=AKIA4N7VTDGOZQA2IKWK%2F20220815%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20220815T144713Z&X-Amz-Expires=900&X-Amz-Signature=5ddddfe8ef2b0601e80ab41c78a4d77d921942b0d8160bcab40ff894095e6823&X-Amz-SignedHeaders=host&x-id=PutObject` - FAILED tests/test_upstream_hub.py::TestPushToHub::test_push_dataset_dict_to_hub_private - https://github.com/huggingface/datasets/runs/7835921082?check_suite_focus=true `requests.exceptions.HTTPError: 500 Server Error: Internal Server Error for url: https://hub-ci.huggingface.co/api/repos/create (Request ID: gL_1I7i2dii9leBhlZen-) - Internal Error - We're working hard to fix that as soon as possible!` - FAILED tests/test_upstream_hub.py::TestPushToHub::test_push_dataset_to_hub_custom_features_image_list - https://github.com/huggingface/datasets/runs/7835920900?check_suite_focus=true - This is not 500, but 404: `requests.exceptions.HTTPError: 404 Client Error: Not Found for url: [https://hub-ci.huggingface.co/datasets/__DUMMY_TRANSFORMERS_USER__/test-16605586458339.git/info/lfs/objects](https://hub-ci.huggingface.co/datasets/__DUMMY_TRANSFORMERS_USER__/test-16605586458339.git/info/lfs/objects/batch)`
true
1,337,878,249
https://api.github.com/repos/huggingface/datasets/issues/4844
https://github.com/huggingface/datasets/pull/4844
4,844
Add 'val' to VALIDATION_KEYWORDS.
closed
5
2022-08-13T06:49:41
2022-08-30T10:17:35
2022-08-30T10:14:54
akt42
[]
This PR fixes #4839 by adding the word `"val"` to the `VALIDATION_KEYWORDS` so that the `load_dataset()` method with `imagefolder` (and probably, some other directives as well) reads folders named `"val"` as well. I think the supported keywords have to be mentioned in the documentation as well, but I couldn't think of a proper place to add that.
true
1,337,668,699
https://api.github.com/repos/huggingface/datasets/issues/4843
https://github.com/huggingface/datasets/pull/4843
4,843
Fix typo in streaming docs
closed
1
2022-08-12T20:18:21
2022-08-14T11:43:30
2022-08-14T11:02:09
flozi00
[]
null
true
1,337,527,764
https://api.github.com/repos/huggingface/datasets/issues/4842
https://github.com/huggingface/datasets/pull/4842
4,842
Update stackexchange license
closed
1
2022-08-12T17:39:06
2022-08-14T10:43:18
2022-08-14T10:28:49
cakiki
[]
The correct license of the stackexchange subset of the Pile is `cc-by-sa-4.0`, as can for example be seen here: https://stackoverflow.com/help/licensing
true
1,337,401,243
https://api.github.com/repos/huggingface/datasets/issues/4841
https://github.com/huggingface/datasets/pull/4841
4,841
Update ted_talks_iwslt license to include ND
closed
1
2022-08-12T16:14:52
2022-08-14T11:15:22
2022-08-14T11:00:22
cakiki
[]
Excerpt from the paper's abstract: "Aside from its cultural and social relevance, this content, which is published under the Creative Commons BY-NC-ND license, also represents a precious language resource for the machine translation research community"
true
1,337,342,672
https://api.github.com/repos/huggingface/datasets/issues/4840
https://github.com/huggingface/datasets/issues/4840
4,840
Dataset Viewer issue for darragh/demo_data_raw3
open
5
2022-08-12T15:22:58
2022-09-08T07:55:44
null
severo
[]
### Link https://huggingface.co/datasets/darragh/demo_data_raw3 ### Description ``` Exception: ValueError Message: Arrow type extension<arrow.py_extension_type<pyarrow.lib.UnknownExtensionType>> does not have a datasets dtype equivalent. ``` reported by @NielsRogge ### Owner No
false
1,337,206,377
https://api.github.com/repos/huggingface/datasets/issues/4839
https://github.com/huggingface/datasets/issues/4839
4,839
ImageFolder dataset builder does not read the validation data set if it is named as "val"
closed
1
2022-08-12T13:26:00
2022-08-30T10:14:55
2022-08-30T10:14:55
akt42
[ "enhancement" ]
**Is your feature request related to a problem? Please describe.** Currently, the `'imagefolder'` data set builder in [`load_dataset()`](https://github.com/huggingface/datasets/blob/2.4.0/src/datasets/load.py#L1541] ) only [supports](https://github.com/huggingface/datasets/blob/6c609a322da994de149b2c938f19439bca99408e/src/datasets/data_files.py#L31) the following names as the validation data set directory name: `["validation", "valid", "dev"]`. When the validation directory is named as `'val'`, the Data set will not have a validation split. I expected this to be a trivial task but ended up spending a lot of time before knowing that only the above names are supported. Here's a minimal example of `val` not being recognized: ```python import os import numpy as np import cv2 from datasets import load_dataset # creating a dummy data set with the following structure: # ROOT # | -- train # | ---- class_1 # | ---- class_2 # | -- val # | ---- class_1 # | ---- class_2 ROOT = "data" for which in ["train", "val"]: for class_name in ["class_1", "class_2"]: dir_name = os.path.join(ROOT, which, class_name) if not os.path.exists(dir_name): os.makedirs(dir_name) for i in range(10): cv2.imwrite( os.path.join(dir_name, f"{i}.png"), np.random.random((224, 224)) ) # trying to create a data set dataset = load_dataset( "imagefolder", data_dir=ROOT ) >> dataset DatasetDict({ train: Dataset({ features: ['image', 'label'], num_rows: 20 }) }) # ^ note how the dataset only has a 'train' subset ``` **Describe the solution you'd like** The suggestion is to include `"val"` to [that list ](https://github.com/huggingface/datasets/blob/6c609a322da994de149b2c938f19439bca99408e/src/datasets/data_files.py#L31) as that's a commonly used phrase to name the validation directory. Also, In the documentation, explicitly mention that only such directory names are supported as train/val/test directories to avoid confusion. **Describe alternatives you've considered** In the documentation, explicitly mention that only such directory names are supported as train/val/test directories without adding `val` to the above list. **Additional context** A question asked in the forum: [ Loading an imagenet-style image dataset with train/val directories](https://discuss.huggingface.co/t/loading-an-imagenet-style-image-dataset-with-train-val-directories/21554)
false
1,337,194,918
https://api.github.com/repos/huggingface/datasets/issues/4838
https://github.com/huggingface/datasets/pull/4838
4,838
Fix documentation card of adv_glue dataset
closed
2
2022-08-12T13:15:26
2022-08-15T10:17:14
2022-08-15T10:02:11
albertvillanova
[]
Fix documentation card of adv_glue dataset.
true
1,337,079,723
https://api.github.com/repos/huggingface/datasets/issues/4837
https://github.com/huggingface/datasets/pull/4837
4,837
Add support for CSV metadata files to ImageFolder
closed
4
2022-08-12T11:19:18
2022-08-31T12:01:27
2022-08-31T11:59:07
mariosasko
[]
Fix #4814
true
1,337,067,632
https://api.github.com/repos/huggingface/datasets/issues/4836
https://github.com/huggingface/datasets/issues/4836
4,836
Is it possible to pass multiple links to a split in load script?
open
0
2022-08-12T11:06:11
2022-08-12T11:06:11
null
sadrasabouri
[ "enhancement" ]
**Is your feature request related to a problem? Please describe.** I wanted to use a python loading script in hugging face datasets that use different sources of text (it's somehow a compilation of multiple datasets + my own dataset) based on how `load_dataset` [works](https://huggingface.co/docs/datasets/loading) I assumed I could do something like bellow in my loading script: ```python ... _URL = "MY_DATASET_URL/resolve/main/data/" _URLS = { "train": [ "FIRST_URL_TO.txt", _URL + "train-00000-of-00001-676bfebbc8742592.parquet" ] } ... ``` but when loading the dataset it raises the following error: ```python File ~/.local/lib/python3.8/site-packages/datasets/builder.py:704, in DatasetBuilder.download_and_prepare(self, download_config, download_mode, ignore_verifications, try_from_hf_gcs, dl_manager, base_path, use_auth_token, **download_and_prepare_kwargs) 702 logger.warning("HF google storage unreachable. Downloading and preparing it from source") 703 if not downloaded_from_gcs: --> 704 self._download_and_prepare( 705 dl_manager=dl_manager, verify_infos=verify_infos, **download_and_prepare_kwargs ... 668 if isinstance(a, str): 669 # Force-cast str subclasses to str (issue #21127) 670 parts.append(str(a)) TypeError: expected str, bytes or os.PathLike object, not list ``` **Describe the solution you'd like** I believe since it's possible for `load_dataset` to get list of URLs instead of just a URL for `train` split it can be possible here too. **Describe alternatives you've considered** An alternative solution would be to download all needed datasets locally and `push_to_hub` them all, but since the datasets I'm talking about are huge it's not among my options. **Additional context** I think loading `text` beside the `parquet` is completely a different issue but I believe I can figure it out by proposing a config for my dataset to load each entry of `_URLS['train']` separately either by `load_dataset("text", ...` or `load_dataset("parquet", ...`.
false
1,336,994,835
https://api.github.com/repos/huggingface/datasets/issues/4835
https://github.com/huggingface/datasets/pull/4835
4,835
Fix documentation card of ethos dataset
closed
1
2022-08-12T09:51:06
2022-08-12T13:13:55
2022-08-12T12:59:39
albertvillanova
[]
Fix documentation card of ethos dataset.
true
1,336,993,511
https://api.github.com/repos/huggingface/datasets/issues/4834
https://github.com/huggingface/datasets/pull/4834
4,834
Fix documentation card of recipe_nlg dataset
closed
1
2022-08-12T09:49:39
2022-08-12T11:28:18
2022-08-12T11:13:40
albertvillanova
[]
Fix documentation card of recipe_nlg dataset
true
1,336,946,965
https://api.github.com/repos/huggingface/datasets/issues/4833
https://github.com/huggingface/datasets/pull/4833
4,833
Fix missing tags in dataset cards
closed
1
2022-08-12T09:04:52
2022-09-22T14:41:23
2022-08-12T09:45:55
albertvillanova
[]
Fix missing tags in dataset cards: - boolq - break_data - definite_pronoun_resolution - emo - kor_nli - pg19 - quartz - sciq - squad_es - wmt14 - wmt15 - wmt16 - wmt17 - wmt18 - wmt19 - wmt_t2t This PR partially fixes the missing tags in dataset cards. Subsequent PRs will follow to complete this task.
true
1,336,727,389
https://api.github.com/repos/huggingface/datasets/issues/4832
https://github.com/huggingface/datasets/pull/4832
4,832
Fix tags in dataset cards
closed
2
2022-08-12T04:11:23
2022-08-12T04:41:55
2022-08-12T04:27:24
albertvillanova
[]
Fix wrong tags in dataset cards.
true
1,336,199,643
https://api.github.com/repos/huggingface/datasets/issues/4831
https://github.com/huggingface/datasets/pull/4831
4,831
Add oversampling strategies to interleave datasets
closed
5
2022-08-11T16:24:51
2023-07-11T15:57:48
2022-08-24T16:46:07
ylacombe
[]
Hello everyone, Here is a proposal to improve `interleave_datasets` function. Following Issue #3064, and @lhoestq [comment](https://github.com/huggingface/datasets/issues/3064#issuecomment-1022333385), I propose here a code that performs oversampling when interleaving a `Dataset` list. I have myself encountered this problem while trying to implement training on a multilingual dataset following a training strategy similar to that of [XLSUM paper](https://arxiv.org/pdf/2106.13822.pdf), a multilingual abstract summary dataset where the multilingual training dataset is created by sampling from the languages following a smoothing strategy. The main idea is to sample languages that have a low number of samples more frequently than other languages. As in Issue #3064, the current default strategy is a undersampling strategy, which stops as soon as a dataset runs out of samples. The new `all_exhausted` strategy stops building the new dataset as soon as all samples in each dataset have been added at least once. How does it work in practice: - if ``probabilities`` is `None` and the strategy is `all_exhausted`, it simply performs a round robin interleaving that stops when the longest dataset is out of samples. Here the new dataset length will be $maxLengthDataset*nbDataset$. - if ``probabilities`` is not `None` and the strategy is `all_exhausted`, it keeps trace of the datasets which were out of samples but continues to add them to the new dataset, and stops as soons as every dataset runs out of samples at least once. - In the other cases, it is supposed to keep the same behaviour as before. Except that this time, when probabilities are precised, it really stops AS SOON AS a dataset is out of samples. More on the last sentence: The previous example of `interleave_datasets` was: >>> from datasets import Dataset, interleave_datasets >>> d1 = Dataset.from_dict({"a": [0, 1, 2]}) >>> d2 = Dataset.from_dict({"a": [10, 11, 12]}) >>> d3 = Dataset.from_dict({"a": [20, 21, 22]}) >>> dataset = interleave_datasets([d1, d2, d3]) >>> dataset["a"] [0, 10, 20, 1, 11, 21, 2, 12, 22] >>> dataset = interleave_datasets([d1, d2, d3], probabilities=[0.7, 0.2, 0.1], seed=42) >>> dataset["a"] [10, 0, 11, 1, 2, 20, 12] With my implementation, `dataset = interleave_datasets([d1, d2, d3], probabilities=[0.7, 0.2, 0.1], seed=42)` gives: >>> dataset["a"] [10, 0, 11, 1, 2] because `d1` is already out of samples just after `2` is added. Example of the results of applying the different strategies: >>> from datasets import Dataset, interleave_datasets >>> d1 = Dataset.from_dict({"a": [0, 1, 2]}) >>> d2 = Dataset.from_dict({"a": [10, 11, 12]}) >>> d3 = Dataset.from_dict({"a": [20, 21, 22]}) >>> dataset = interleave_datasets([d1, d2, d3], probabilities=[0.7, 0.2, 0.1], seed=42, stopping_strategy="all_exhausted") >>> dataset["a"] [10, 0, 11, 1, 2, 20, 12, 10, 0, 1, 2, 21, 0, 11, 1, 2, 0, 1, 12, 2, 10, 0, 22] >>> dataset = interleave_datasets([d1, d2, d3], probabilities=[0.7, 0.2, 0.1], seed=42) >>> dataset["a"] [10, 0, 11, 1, 2] >>> dataset = interleave_datasets([d1, d2, d3]) >>> dataset["a"] [0, 10, 20, 1, 11, 21, 2, 12, 22] >>> dataset = interleave_datasets([d1, d2, d3], stopping_strategy="all_exhausted") >>> dataset["a"] [0, 10, 20, 1, 11, 21, 2, 12, 22] >>> d1 = Dataset.from_dict({"a": [0, 1, 2]}) >>> d2 = Dataset.from_dict({"a": [10, 11, 12, 13]}) >>> d3 = Dataset.from_dict({"a": [20, 21, 22, 23, 24]}) >>> dataset = interleave_datasets([d1, d2, d3]) >>> dataset["a"] [0, 10, 20, 1, 11, 21, 2, 12, 22] >>> dataset = interleave_datasets([d1, d2, d3], stopping_strategy="all_exhausted") >>> dataset["a"] [0, 10, 20, 1, 11, 21, 2, 12, 22, 0, 13, 23, 1, 0, 24] >>> dataset = interleave_datasets([d1, d2, d3], probabilities=[0.7, 0.2, 0.1], seed=42) >>> dataset["a"] [10, 0, 11, 1, 2] >>> dataset = interleave_datasets([d1, d2, d3], probabilities=[0.7, 0.2, 0.1], seed=42, stopping_strategy="all_exhausted") >>> dataset["a"] [10, 0, 11, 1, 2, 20, 12, 13, ..., 0, 1, 2, 0, 24] **Final note:** I've been using that code for a research project involving a large-scale multilingual dataset. One should be careful when using oversampling to avoid to avoid exploding the size of the dataset. For example, if a very large data set has a low probability of being sampled, the final dataset may be several times the size of that large data set.
true
1,336,177,937
https://api.github.com/repos/huggingface/datasets/issues/4830
https://github.com/huggingface/datasets/pull/4830
4,830
Fix task tags in dataset cards
closed
2
2022-08-11T16:06:06
2022-08-11T16:37:27
2022-08-11T16:23:00
albertvillanova
[]
null
true
1,336,068,068
https://api.github.com/repos/huggingface/datasets/issues/4829
https://github.com/huggingface/datasets/issues/4829
4,829
Misalignment between card tag validation and docs
open
2
2022-08-11T14:44:45
2023-07-21T15:38:02
null
albertvillanova
[ "bug" ]
## Describe the bug As pointed out in other issue: https://github.com/huggingface/datasets/pull/4827#discussion_r943536284 the validation of the dataset card tags is not aligned with its documentation: e.g. - implementation: `license: List[str]` - docs: `license: Union[str, List[str]]` They should be aligned. CC: @julien-c
false