url
stringlengths
61
61
repository_url
stringclasses
1 value
labels_url
stringlengths
75
75
comments_url
stringlengths
70
70
events_url
stringlengths
68
68
html_url
stringlengths
49
51
id
int64
758M
1.95B
node_id
stringlengths
18
32
number
int64
1.2k
6.31k
title
stringlengths
1
290
user
dict
labels
listlengths
0
3
state
stringclasses
2 values
locked
bool
1 class
assignee
dict
assignees
listlengths
0
4
milestone
dict
comments
sequencelengths
0
30
created_at
unknown
updated_at
unknown
closed_at
unknown
author_association
stringclasses
3 values
active_lock_reason
float64
draft
float64
0
1
pull_request
dict
body
stringlengths
0
36.2k
reactions
dict
timeline_url
stringlengths
70
70
performed_via_github_app
float64
state_reason
stringclasses
3 values
is_pull_request
bool
2 classes
https://api.github.com/repos/huggingface/datasets/issues/2258
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/2258/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/2258/comments
https://api.github.com/repos/huggingface/datasets/issues/2258/events
https://github.com/huggingface/datasets/pull/2258
866,870,588
MDExOlB1bGxSZXF1ZXN0NjIyNjcxNTQy
2,258
Fix incorrect update_metadata_with_features calls in ArrowDataset
{ "avatar_url": "https://avatars.githubusercontent.com/u/47462742?v=4", "events_url": "https://api.github.com/users/mariosasko/events{/privacy}", "followers_url": "https://api.github.com/users/mariosasko/followers", "following_url": "https://api.github.com/users/mariosasko/following{/other_user}", "gists_url": "https://api.github.com/users/mariosasko/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mariosasko", "id": 47462742, "login": "mariosasko", "node_id": "MDQ6VXNlcjQ3NDYyNzQy", "organizations_url": "https://api.github.com/users/mariosasko/orgs", "received_events_url": "https://api.github.com/users/mariosasko/received_events", "repos_url": "https://api.github.com/users/mariosasko/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mariosasko/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mariosasko/subscriptions", "type": "User", "url": "https://api.github.com/users/mariosasko" }
[]
closed
false
null
[]
null
[ "@lhoestq Maybe a test that runs the functions that call `update_metadata_with_features` and checks if metadata was updated would be nice to prevent this from happening in the future." ]
"2021-04-25T00:48:38Z"
"2021-04-26T17:16:30Z"
"2021-04-26T16:54:04Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/2258.diff", "html_url": "https://github.com/huggingface/datasets/pull/2258", "merged_at": "2021-04-26T16:54:04Z", "patch_url": "https://github.com/huggingface/datasets/pull/2258.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/2258" }
Fixes bugs in the `unpdate_metadata_with_features` calls (caused by changes in #2151)
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/2258/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/2258/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/3634
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/3634/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/3634/comments
https://api.github.com/repos/huggingface/datasets/issues/3634/events
https://github.com/huggingface/datasets/issues/3634
1,115,133,279
I_kwDODunzps5Cd5Vf
3,634
Dataset.shuffle(seed=None) gives fixed row permutation
{ "avatar_url": "https://avatars.githubusercontent.com/u/18127060?v=4", "events_url": "https://api.github.com/users/elisno/events{/privacy}", "followers_url": "https://api.github.com/users/elisno/followers", "following_url": "https://api.github.com/users/elisno/following{/other_user}", "gists_url": "https://api.github.com/users/elisno/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/elisno", "id": 18127060, "login": "elisno", "node_id": "MDQ6VXNlcjE4MTI3MDYw", "organizations_url": "https://api.github.com/users/elisno/orgs", "received_events_url": "https://api.github.com/users/elisno/received_events", "repos_url": "https://api.github.com/users/elisno/repos", "site_admin": false, "starred_url": "https://api.github.com/users/elisno/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/elisno/subscriptions", "type": "User", "url": "https://api.github.com/users/elisno" }
[ { "color": "d73a4a", "default": true, "description": "Something isn't working", "id": 1935892857, "name": "bug", "node_id": "MDU6TGFiZWwxOTM1ODkyODU3", "url": "https://api.github.com/repos/huggingface/datasets/labels/bug" } ]
closed
false
{ "avatar_url": "https://avatars.githubusercontent.com/u/47462742?v=4", "events_url": "https://api.github.com/users/mariosasko/events{/privacy}", "followers_url": "https://api.github.com/users/mariosasko/followers", "following_url": "https://api.github.com/users/mariosasko/following{/other_user}", "gists_url": "https://api.github.com/users/mariosasko/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mariosasko", "id": 47462742, "login": "mariosasko", "node_id": "MDQ6VXNlcjQ3NDYyNzQy", "organizations_url": "https://api.github.com/users/mariosasko/orgs", "received_events_url": "https://api.github.com/users/mariosasko/received_events", "repos_url": "https://api.github.com/users/mariosasko/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mariosasko/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mariosasko/subscriptions", "type": "User", "url": "https://api.github.com/users/mariosasko" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/47462742?v=4", "events_url": "https://api.github.com/users/mariosasko/events{/privacy}", "followers_url": "https://api.github.com/users/mariosasko/followers", "following_url": "https://api.github.com/users/mariosasko/following{/other_user}", "gists_url": "https://api.github.com/users/mariosasko/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mariosasko", "id": 47462742, "login": "mariosasko", "node_id": "MDQ6VXNlcjQ3NDYyNzQy", "organizations_url": "https://api.github.com/users/mariosasko/orgs", "received_events_url": "https://api.github.com/users/mariosasko/received_events", "repos_url": "https://api.github.com/users/mariosasko/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mariosasko/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mariosasko/subscriptions", "type": "User", "url": "https://api.github.com/users/mariosasko" } ]
null
[ "I'm not sure if this is expected behavior.\r\n\r\nAm I supposed to work with a copy of the dataset, i.e. `shuffled_dataset = data.shuffle(seed=None)`?\r\n\r\n```diff\r\nimport datasets\r\n\r\n# Some toy example\r\ndata = datasets.Dataset.from_dict(\r\n {\"feature\": [1, 2, 3, 4, 5], \"label\": [\"a\", \"b\", \"c\", \"d\", \"e\"]}\r\n)\r\n\r\n+shuffled_data = data.shuffle(seed=None)\r\n\r\n# Doesn't work as expected\r\nprint(\"Shuffle dataset\")\r\nfor _ in range(3):\r\n+ shuffled_data = shuffled_data.shuffle(seed=None)\r\n+ print(shuffled_data[:])\r\n- print(data.shuffle(seed=None)[:])\r\n\r\n# This seems to work with pandas\r\nprint(\"\\nShuffle via pandas\")\r\nfor _ in range(3):\r\n df = data.to_pandas().sample(frac=1.0)\r\n print(datasets.Dataset.from_pandas(df, preserve_index=False)[:])\r\n\r\n```\r\n\r\nor provide a `generator` instead?\r\n\r\n```diff\r\nimport datasets\r\n+from numpy.random import default_rng\r\n\r\n# Some toy example\r\ndata = datasets.Dataset.from_dict(\r\n {\"feature\": [1, 2, 3, 4, 5], \"label\": [\"a\", \"b\", \"c\", \"d\", \"e\"]}\r\n)\r\n\r\n+rng = default_rng()\r\n\r\n# Doesn't work as expected\r\nprint(\"Shuffle dataset\")\r\nfor _ in range(3):\r\n+ print(data.shuffle(generator=rng)[:])\r\n- print(data.shuffle(seed=None)[:])\r\n\r\n# This seems to work with pandas\r\nprint(\"\\nShuffle via pandas\")\r\nfor _ in range(3):\r\n df = data.to_pandas().sample(frac=1.0)\r\n print(datasets.Dataset.from_pandas(df, preserve_index=False)[:])\r\n\r\n```", "Hi! Thanks for reporting! Yes, this is not expected behavior. I've opened a PR with the fix." ]
"2022-01-26T15:13:08Z"
"2022-01-27T18:16:07Z"
"2022-01-27T18:16:07Z"
NONE
null
null
null
## Describe the bug Repeated attempts to `shuffle` a dataset without specifying a seed give the same results. ## Steps to reproduce the bug ```python import datasets # Some toy example data = datasets.Dataset.from_dict( {"feature": [1, 2, 3, 4, 5], "label": ["a", "b", "c", "d", "e"]} ) # Doesn't work as expected print("Shuffle dataset") for _ in range(3): print(data.shuffle(seed=None)[:]) # This seems to work with pandas print("\nShuffle via pandas") for _ in range(3): df = data.to_pandas().sample(frac=1.0) print(datasets.Dataset.from_pandas(df, preserve_index=False)[:]) ``` ## Expected results I assumed that the default setting would initialize a new/random state of a `np.random.BitGenerator` (see [docs](https://huggingface.co/docs/datasets/package_reference/main_classes.html?highlight=shuffle#datasets.Dataset.shuffle)). Wouldn't that reshuffle the rows each time I call `data.shuffle()`? ## Actual results ```bash Shuffle dataset {'feature': [5, 1, 3, 2, 4], 'label': ['e', 'a', 'c', 'b', 'd']} {'feature': [5, 1, 3, 2, 4], 'label': ['e', 'a', 'c', 'b', 'd']} {'feature': [5, 1, 3, 2, 4], 'label': ['e', 'a', 'c', 'b', 'd']} Shuffle via pandas {'feature': [4, 2, 3, 1, 5], 'label': ['d', 'b', 'c', 'a', 'e']} {'feature': [2, 5, 3, 4, 1], 'label': ['b', 'e', 'c', 'd', 'a']} {'feature': [5, 2, 3, 1, 4], 'label': ['e', 'b', 'c', 'a', 'd']} ``` ## Environment info <!-- You can run the command `datasets-cli env` and copy-and-paste its output below. --> - `datasets` version: 1.18.0 - Platform: Linux-5.13.0-27-generic-x86_64-with-glibc2.17 - Python version: 3.8.12 - PyArrow version: 6.0.1
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/3634/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/3634/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/1314
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/1314/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/1314/comments
https://api.github.com/repos/huggingface/datasets/issues/1314/events
https://github.com/huggingface/datasets/pull/1314
759,541,937
MDExOlB1bGxSZXF1ZXN0NTM0NTMwMDE5
1,314
Add snips built in intents 2016 12
{ "avatar_url": "https://avatars.githubusercontent.com/u/8405335?v=4", "events_url": "https://api.github.com/users/bduvenhage/events{/privacy}", "followers_url": "https://api.github.com/users/bduvenhage/followers", "following_url": "https://api.github.com/users/bduvenhage/following{/other_user}", "gists_url": "https://api.github.com/users/bduvenhage/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/bduvenhage", "id": 8405335, "login": "bduvenhage", "node_id": "MDQ6VXNlcjg0MDUzMzU=", "organizations_url": "https://api.github.com/users/bduvenhage/orgs", "received_events_url": "https://api.github.com/users/bduvenhage/received_events", "repos_url": "https://api.github.com/users/bduvenhage/repos", "site_admin": false, "starred_url": "https://api.github.com/users/bduvenhage/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/bduvenhage/subscriptions", "type": "User", "url": "https://api.github.com/users/bduvenhage" }
[]
closed
false
null
[]
null
[ "It is not clear how to automatically add the dummy data if the source data is a more complex json format. Should I manually take a fraction of the source data and include it as dummy data?\r\n", "Added a fraction of the real data as dummy data.", "merging since the CI is fixed on master" ]
"2020-12-08T15:30:19Z"
"2020-12-14T09:59:07Z"
"2020-12-14T09:59:07Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/1314.diff", "html_url": "https://github.com/huggingface/datasets/pull/1314", "merged_at": "2020-12-14T09:59:06Z", "patch_url": "https://github.com/huggingface/datasets/pull/1314.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/1314" }
This PR proposes to add the Snips.ai built in intents dataset. The first configuration added is for the intent labels only, but the dataset includes entity slots that may in future be added as alternate configurations.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/1314/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/1314/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/5315
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5315/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5315/comments
https://api.github.com/repos/huggingface/datasets/issues/5315/events
https://github.com/huggingface/datasets/issues/5315
1,470,026,797
I_kwDODunzps5XntQt
5,315
Adding new splits to a dataset script with existing old splits info in metadata's `dataset_info` fails
{ "avatar_url": "https://avatars.githubusercontent.com/u/16348744?v=4", "events_url": "https://api.github.com/users/polinaeterna/events{/privacy}", "followers_url": "https://api.github.com/users/polinaeterna/followers", "following_url": "https://api.github.com/users/polinaeterna/following{/other_user}", "gists_url": "https://api.github.com/users/polinaeterna/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/polinaeterna", "id": 16348744, "login": "polinaeterna", "node_id": "MDQ6VXNlcjE2MzQ4NzQ0", "organizations_url": "https://api.github.com/users/polinaeterna/orgs", "received_events_url": "https://api.github.com/users/polinaeterna/received_events", "repos_url": "https://api.github.com/users/polinaeterna/repos", "site_admin": false, "starred_url": "https://api.github.com/users/polinaeterna/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/polinaeterna/subscriptions", "type": "User", "url": "https://api.github.com/users/polinaeterna" }
[ { "color": "d73a4a", "default": true, "description": "Something isn't working", "id": 1935892857, "name": "bug", "node_id": "MDU6TGFiZWwxOTM1ODkyODU3", "url": "https://api.github.com/repos/huggingface/datasets/labels/bug" } ]
open
false
{ "avatar_url": "https://avatars.githubusercontent.com/u/16348744?v=4", "events_url": "https://api.github.com/users/polinaeterna/events{/privacy}", "followers_url": "https://api.github.com/users/polinaeterna/followers", "following_url": "https://api.github.com/users/polinaeterna/following{/other_user}", "gists_url": "https://api.github.com/users/polinaeterna/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/polinaeterna", "id": 16348744, "login": "polinaeterna", "node_id": "MDQ6VXNlcjE2MzQ4NzQ0", "organizations_url": "https://api.github.com/users/polinaeterna/orgs", "received_events_url": "https://api.github.com/users/polinaeterna/received_events", "repos_url": "https://api.github.com/users/polinaeterna/repos", "site_admin": false, "starred_url": "https://api.github.com/users/polinaeterna/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/polinaeterna/subscriptions", "type": "User", "url": "https://api.github.com/users/polinaeterna" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/16348744?v=4", "events_url": "https://api.github.com/users/polinaeterna/events{/privacy}", "followers_url": "https://api.github.com/users/polinaeterna/followers", "following_url": "https://api.github.com/users/polinaeterna/following{/other_user}", "gists_url": "https://api.github.com/users/polinaeterna/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/polinaeterna", "id": 16348744, "login": "polinaeterna", "node_id": "MDQ6VXNlcjE2MzQ4NzQ0", "organizations_url": "https://api.github.com/users/polinaeterna/orgs", "received_events_url": "https://api.github.com/users/polinaeterna/received_events", "repos_url": "https://api.github.com/users/polinaeterna/repos", "site_admin": false, "starred_url": "https://api.github.com/users/polinaeterna/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/polinaeterna/subscriptions", "type": "User", "url": "https://api.github.com/users/polinaeterna" } ]
null
[ "EDIT:\r\nI think in this case, the metadata files (either README or JSON) should not be read (i.e. `self.info.splits` should be None).\r\n\r\nOne idea: \r\n- I think ideally we should set this behavior when we pass `--save_info` to the CLI `test`\r\n- However, currently, the builder is unaware of this: `save_info` arg is not passed to it", "> I think in this case\r\n\r\n@albertvillanova You mean in cases when the script was changed? \r\n\r\nI suggest that we:\r\n* add a check on the slice (like 'split_name[n%]) kind of format here: https://github.com/huggingface/datasets/blob/main/src/datasets/splits.py#L523 to catch things like this. \r\n* Error here happens before splits verification, but in `_prepare_split`, and `_prepare_split` doesn't perform any verification and don't know about it. so we can pass this parameter and take splits from `split_generator`, not from `split.info` in case when `verify_infos` is False\r\n* we can check if split **names** from split_generators and self.info.splits are the same **before** preparing splits (if `verify_info=True`) so that we don't spend time on generating unwanted data. \r\n* provide some user-friendly warnings about `ignore_verifications` parameter so that users know that if something is not matching they can ignore it\r\n\r\nI started it here: https://github.com/huggingface/datasets/pull/5327/files\r\n\r\nWhat do you think @albertvillanova ?", "I edited my previous comment:\r\n- First I proposed setting `self.info.splits` to None when `ignore_verifications=True`\r\n - I thought it was the easiest implementation because `ignore_verifications` is passed to `DatasetBuilder.download_and_prepare`\r\n - However, afterwards, I realized this might not be a good idea for this use case:\r\n - A user wants to optimize the loading of the dataset, and passes `ignore_verifications=False` to avoid all the verifications\r\n - In this case, we want `self.info.splits` to be read from metadata file\r\n- Then, I thought that it might be better to set `self.info.splits` to None when we pass `--save_info` to the CLI test: if we are going to save the info to the metadata file, it makes no sense to read the info from the metadata file\r\n - This implementation is not so easy because the Builder knows nothing about `--save_info`\r\n\r\nI agree with you there are 2 things to be addressed here:\r\n- One is what I have just commented: `self.info.splits` should be None in this case\r\n- The other, a validation should be implemented when calling `make_file_instructions` and/or `SplitDict.__getitem__`, so that when passing \"training\" to it, we get a more descriptive error other than `TypeError: expected str, bytes or os.PathLike object, not NoneType` " ]
"2022-11-30T18:02:15Z"
"2022-12-02T07:02:53Z"
null
CONTRIBUTOR
null
null
null
### Describe the bug If you first create a custom dataset with a specific set of splits, generate metadata with `datasets-cli test ... --save_info`, then change your script to include more splits, it fails. That's what happened in https://huggingface.co/datasets/mrdbourke/food_vision_199_classes/discussions/2#6385fd1269634850f8ddff48. ### Steps to reproduce the bug 1. create a dataset with a custom split that returns, for example, only `"train"` split in `_splits_generators'`. specifically, if really want to reproduce, copy `https://huggingface.co/datasets/mrdbourke/food_vision_199_classes/blob/main/food_vision_199_classes.py 2. run `datasets-cli test dataset_script.py --save_info --all_configs` - this would generate metadata yaml in `README.md` that would contain info about splits, for example, like this: ``` splits: - name: train num_bytes: 2973286 num_examples: 19747 ``` 3. make changes to your script so that it returns another set of splits, for example, `"train"` and `"test"` (uncomment [these lines](https://huggingface.co/datasets/mrdbourke/food_vision_199_classes/blob/main/food_vision_199_classes.py#L271)) 4. run `load_dataset` and get the following error: ```python Traceback (most recent call last): File "/home/daniel/code/pytorch/env/bin/datasets-cli", line 8, in <module> sys.exit(main()) File "/home/daniel/code/pytorch/env/lib/python3.8/site-packages/datasets/commands/datasets_cli.py", line 39, in main service.run() File "/home/daniel/code/pytorch/env/lib/python3.8/site-packages/datasets/commands/test.py", line 141, in run builder.download_and_prepare( File "/home/daniel/code/pytorch/env/lib/python3.8/site-packages/datasets/builder.py", line 822, in download_and_prepare self._download_and_prepare( File "/home/daniel/code/pytorch/env/lib/python3.8/site-packages/datasets/builder.py", line 1555, in _download_and_prepare super()._download_and_prepare( File "/home/daniel/code/pytorch/env/lib/python3.8/site-packages/datasets/builder.py", line 913, in _download_and_prepare self._prepare_split(split_generator, **prepare_split_kwargs) File "/home/daniel/code/pytorch/env/lib/python3.8/site-packages/datasets/builder.py", line 1356, in _prepare_split split_info = self.info.splits[split_generator.name] File "/home/daniel/code/pytorch/env/lib/python3.8/site-packages/datasets/splits.py", line 525, in __getitem__ instructions = make_file_instructions( File "/home/daniel/code/pytorch/env/lib/python3.8/site-packages/datasets/arrow_reader.py", line 111, in make_file_instructions name2filenames = { File "/home/daniel/code/pytorch/env/lib/python3.8/site-packages/datasets/arrow_reader.py", line 112, in <dictcomp> info.name: filenames_for_dataset_split( File "/home/daniel/code/pytorch/env/lib/python3.8/site-packages/datasets/naming.py", line 78, in filenames_for_dataset_split prefix = filename_prefix_for_split(dataset_name, split) File "/home/daniel/code/pytorch/env/lib/python3.8/site-packages/datasets/naming.py", line 57, in filename_prefix_for_split if os.path.basename(name) != name: File "/home/daniel/code/pytorch/env/lib/python3.8/posixpath.py", line 143, in basename p = os.fspath(p) TypeError: expected str, bytes or os.PathLike object, not NoneType ``` 5. bonus: try to regenerate metadata in `README.md` with `datasets-cli` as in step 2 and get the same error. This is because `dataset.info.splits` contains only `"train"` split so when we are doing `self.info.splits[split_generator.name]` it tries to infer smth like `info.splits['train[50%]']` and that's not the case and it fails. ### Expected behavior to be discussed? This can be solved by removing splits information from metadata file first. But I wonder if there is a better way. ### Environment info - Datasets version: 2.7.1 - Python version: 3.8.13
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/5315/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5315/timeline
null
null
false
https://api.github.com/repos/huggingface/datasets/issues/4093
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/4093/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/4093/comments
https://api.github.com/repos/huggingface/datasets/issues/4093/events
https://github.com/huggingface/datasets/issues/4093
1,192,523,161
I_kwDODunzps5HFHWZ
4,093
elena-soare/crawled-ecommerce: missing dataset
{ "avatar_url": "https://avatars.githubusercontent.com/u/17519354?v=4", "events_url": "https://api.github.com/users/seevaratnam/events{/privacy}", "followers_url": "https://api.github.com/users/seevaratnam/followers", "following_url": "https://api.github.com/users/seevaratnam/following{/other_user}", "gists_url": "https://api.github.com/users/seevaratnam/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/seevaratnam", "id": 17519354, "login": "seevaratnam", "node_id": "MDQ6VXNlcjE3NTE5MzU0", "organizations_url": "https://api.github.com/users/seevaratnam/orgs", "received_events_url": "https://api.github.com/users/seevaratnam/received_events", "repos_url": "https://api.github.com/users/seevaratnam/repos", "site_admin": false, "starred_url": "https://api.github.com/users/seevaratnam/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/seevaratnam/subscriptions", "type": "User", "url": "https://api.github.com/users/seevaratnam" }
[ { "color": "E5583E", "default": false, "description": "Related to the dataset viewer on huggingface.co", "id": 3470211881, "name": "dataset-viewer", "node_id": "LA_kwDODunzps7O1zsp", "url": "https://api.github.com/repos/huggingface/datasets/labels/dataset-viewer" } ]
closed
false
{ "avatar_url": "https://avatars.githubusercontent.com/u/1676121?v=4", "events_url": "https://api.github.com/users/severo/events{/privacy}", "followers_url": "https://api.github.com/users/severo/followers", "following_url": "https://api.github.com/users/severo/following{/other_user}", "gists_url": "https://api.github.com/users/severo/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/severo", "id": 1676121, "login": "severo", "node_id": "MDQ6VXNlcjE2NzYxMjE=", "organizations_url": "https://api.github.com/users/severo/orgs", "received_events_url": "https://api.github.com/users/severo/received_events", "repos_url": "https://api.github.com/users/severo/repos", "site_admin": false, "starred_url": "https://api.github.com/users/severo/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/severo/subscriptions", "type": "User", "url": "https://api.github.com/users/severo" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/1676121?v=4", "events_url": "https://api.github.com/users/severo/events{/privacy}", "followers_url": "https://api.github.com/users/severo/followers", "following_url": "https://api.github.com/users/severo/following{/other_user}", "gists_url": "https://api.github.com/users/severo/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/severo", "id": 1676121, "login": "severo", "node_id": "MDQ6VXNlcjE2NzYxMjE=", "organizations_url": "https://api.github.com/users/severo/orgs", "received_events_url": "https://api.github.com/users/severo/received_events", "repos_url": "https://api.github.com/users/severo/repos", "site_admin": false, "starred_url": "https://api.github.com/users/severo/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/severo/subscriptions", "type": "User", "url": "https://api.github.com/users/severo" } ]
null
[ "It's a bug! Thanks for reporting, I'm looking at it.", "By the way, the error on our part is due to the huge size of every row (~90MB). The dataset viewer does not support such big dataset rows for the moment.\r\nAnyway, we're working to give a hint about this in the dataset viewer.", "Fixed. See https://huggingface.co/datasets/elena-soare/crawled-ecommerce/viewer/elena-soare--crawled-ecommerce/train.\r\n\r\n<img width=\"1552\" alt=\"Capture d’écran 2022-04-12 à 11 23 51\" src=\"https://user-images.githubusercontent.com/1676121/162929722-2e2b80e2-154a-4b61-87bd-e341bd6c46e6.png\">\r\n\r\nThanks for reporting!" ]
"2022-04-05T02:25:19Z"
"2022-04-12T09:34:53Z"
"2022-04-12T09:34:53Z"
NONE
null
null
null
elena-soare/crawled-ecommerce **Link:** *link to the dataset viewer page* *short description of the issue* Am I the one who added this dataset ? Yes-No
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/4093/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/4093/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/5942
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5942/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5942/comments
https://api.github.com/repos/huggingface/datasets/issues/5942/events
https://github.com/huggingface/datasets/pull/5942
1,752,021,681
PR_kwDODunzps5Su-V4
5,942
Pass datasets-cli additional args as kwargs to DatasetBuilder in `run_beam.py`
{ "avatar_url": "https://avatars.githubusercontent.com/u/84066822?v=4", "events_url": "https://api.github.com/users/graelo/events{/privacy}", "followers_url": "https://api.github.com/users/graelo/followers", "following_url": "https://api.github.com/users/graelo/following{/other_user}", "gists_url": "https://api.github.com/users/graelo/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/graelo", "id": 84066822, "login": "graelo", "node_id": "MDQ6VXNlcjg0MDY2ODIy", "organizations_url": "https://api.github.com/users/graelo/orgs", "received_events_url": "https://api.github.com/users/graelo/received_events", "repos_url": "https://api.github.com/users/graelo/repos", "site_admin": false, "starred_url": "https://api.github.com/users/graelo/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/graelo/subscriptions", "type": "User", "url": "https://api.github.com/users/graelo" }
[]
open
false
null
[]
null
[]
"2023-06-12T06:50:50Z"
"2023-06-30T09:15:00Z"
null
NONE
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/5942.diff", "html_url": "https://github.com/huggingface/datasets/pull/5942", "merged_at": null, "patch_url": "https://github.com/huggingface/datasets/pull/5942.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/5942" }
Hi, Following this <https://discuss.huggingface.co/t/how-to-preprocess-a-wikipedia-dataset-using-dataflowrunner/41991/3>, here is a simple PR to pass any additional args to datasets-cli as kwargs in the DatasetBuilder in `run_beam.py`. I also took the liberty to add missing setup steps to the `beam.mdx` docs in order to help everyone. @lhoestq
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/5942/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5942/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/1641
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/1641/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/1641/comments
https://api.github.com/repos/huggingface/datasets/issues/1641/events
https://github.com/huggingface/datasets/issues/1641
775,110,872
MDU6SXNzdWU3NzUxMTA4NzI=
1,641
muchocine dataset cannot be dowloaded
{ "avatar_url": "https://avatars.githubusercontent.com/u/3653789?v=4", "events_url": "https://api.github.com/users/mrm8488/events{/privacy}", "followers_url": "https://api.github.com/users/mrm8488/followers", "following_url": "https://api.github.com/users/mrm8488/following{/other_user}", "gists_url": "https://api.github.com/users/mrm8488/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mrm8488", "id": 3653789, "login": "mrm8488", "node_id": "MDQ6VXNlcjM2NTM3ODk=", "organizations_url": "https://api.github.com/users/mrm8488/orgs", "received_events_url": "https://api.github.com/users/mrm8488/received_events", "repos_url": "https://api.github.com/users/mrm8488/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mrm8488/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mrm8488/subscriptions", "type": "User", "url": "https://api.github.com/users/mrm8488" }
[ { "color": "ffffff", "default": true, "description": "This will not be worked on", "id": 1935892913, "name": "wontfix", "node_id": "MDU6TGFiZWwxOTM1ODkyOTEz", "url": "https://api.github.com/repos/huggingface/datasets/labels/wontfix" }, { "color": "2edb81", "default": false, "description": "A bug in a dataset script provided in the library", "id": 2067388877, "name": "dataset bug", "node_id": "MDU6TGFiZWwyMDY3Mzg4ODc3", "url": "https://api.github.com/repos/huggingface/datasets/labels/dataset%20bug" } ]
closed
false
null
[]
null
[ "I have encountered the same error with `v1.0.1` and `v1.0.2` on both Windows and Linux environments. However, cloning the repo and using the path to the dataset's root directory worked for me. Even after having the dataset cached - passing the path is the only way (for now) to load the dataset.\r\n\r\n```python\r\nfrom datasets import load_dataset\r\n\r\ndataset = load_dataset(\"squad\") # Works\r\ndataset = load_dataset(\"code_search_net\", \"python\") # Error\r\ndataset = load_dataset(\"covid_qa_deepset\") # Error\r\n\r\npath = \"/huggingface/datasets/datasets/{}/\"\r\ndataset = load_dataset(path.format(\"code_search_net\"), \"python\") # Works\r\ndataset = load_dataset(path.format(\"covid_qa_deepset\")) # Works\r\n```\r\n\r\n", "Hi @mrm8488 and @amoux!\r\n The datasets you are trying to load have been added to the library during the community sprint for v2 last month. They will be available with the v2 release!\r\nFor now, there are still a couple of solutions to load the datasets:\r\n1. As suggested by @amoux, you can clone the git repo and pass the local path to the script\r\n2. You can also install the latest (master) version of `datasets` using pip: `pip install git+https://github.com/huggingface/datasets.git@master`", "If you don't want to clone entire `datasets` repo, just download the `muchocine` directory and pass the local path to the directory. Cheers!", "Muchocine was added recently, that's why it wasn't available yet.\r\n\r\nTo load it you can just update `datasets`\r\n```\r\npip install --upgrade datasets\r\n```\r\n\r\nand then you can load `muchocine` with\r\n\r\n```python\r\nfrom datasets import load_dataset\r\n\r\ndataset = load_dataset(\"muchocine\", split=\"train\")\r\n```", "Thanks @lhoestq " ]
"2020-12-27T21:26:28Z"
"2021-08-03T05:07:29Z"
"2021-08-03T05:07:29Z"
CONTRIBUTOR
null
null
null
```python --------------------------------------------------------------------------- FileNotFoundError Traceback (most recent call last) /usr/local/lib/python3.6/dist-packages/datasets/load.py in prepare_module(path, script_version, download_config, download_mode, dataset, force_local_path, **download_kwargs) 267 try: --> 268 local_path = cached_path(file_path, download_config=download_config) 269 except FileNotFoundError: 7 frames FileNotFoundError: Couldn't find file at https://raw.githubusercontent.com/huggingface/datasets/1.0.2/datasets/muchocine/muchocine.py During handling of the above exception, another exception occurred: FileNotFoundError Traceback (most recent call last) FileNotFoundError: Couldn't find file at https://s3.amazonaws.com/datasets.huggingface.co/datasets/datasets/muchocine/muchocine.py During handling of the above exception, another exception occurred: FileNotFoundError Traceback (most recent call last) /usr/local/lib/python3.6/dist-packages/datasets/load.py in prepare_module(path, script_version, download_config, download_mode, dataset, force_local_path, **download_kwargs) 281 raise FileNotFoundError( 282 "Couldn't find file locally at {}, or remotely at {} or {}".format( --> 283 combined_path, github_file_path, file_path 284 ) 285 ) FileNotFoundError: Couldn't find file locally at muchocine/muchocine.py, or remotely at https://raw.githubusercontent.com/huggingface/datasets/1.0.2/datasets/muchocine/muchocine.py or https://s3.amazonaws.com/datasets.huggingface.co/datasets/datasets/muchocine/muchocine.py ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/1641/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/1641/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/5782
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5782/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5782/comments
https://api.github.com/repos/huggingface/datasets/issues/5782/events
https://github.com/huggingface/datasets/issues/5782
1,679,622,367
I_kwDODunzps5kHQDf
5,782
Support for various audio-loading backends instead of always relying on SoundFile
{ "avatar_url": "https://avatars.githubusercontent.com/u/129098876?v=4", "events_url": "https://api.github.com/users/BoringDonut/events{/privacy}", "followers_url": "https://api.github.com/users/BoringDonut/followers", "following_url": "https://api.github.com/users/BoringDonut/following{/other_user}", "gists_url": "https://api.github.com/users/BoringDonut/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/BoringDonut", "id": 129098876, "login": "BoringDonut", "node_id": "U_kgDOB7HkfA", "organizations_url": "https://api.github.com/users/BoringDonut/orgs", "received_events_url": "https://api.github.com/users/BoringDonut/received_events", "repos_url": "https://api.github.com/users/BoringDonut/repos", "site_admin": false, "starred_url": "https://api.github.com/users/BoringDonut/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/BoringDonut/subscriptions", "type": "User", "url": "https://api.github.com/users/BoringDonut" }
[ { "color": "a2eeef", "default": true, "description": "New feature or request", "id": 1935892871, "name": "enhancement", "node_id": "MDU6TGFiZWwxOTM1ODkyODcx", "url": "https://api.github.com/repos/huggingface/datasets/labels/enhancement" } ]
closed
false
null
[]
null
[ "Hi! \r\n\r\nYou can use `set_transform`/`with_transform` to define a custom decoding for audio formats not supported by `soundfile`:\r\n```python\r\naudio_dataset_amr = Dataset.from_dict({\"audio\": [\"audio_samples/audio.amr\"]})\r\n\r\ndef decode_audio(batch):\r\n batch[\"audio\"] = [read_ffmpeg(audio_path) for audio_path in batch[\"audio\"]]\r\n return batch\r\n\r\naudio_dataset_amr.set_transform(decode_amr) \r\n```\r\n\r\nSupporting multiple backends is more work to maintain, but we could consider this if we get more requests such as this one.", "Could it be put somewhere as an example tip or something?", "Considering the number of times a custom decoding transform has been suggested as a solution, an example in the [docs](https://huggingface.co/docs/datasets/process#format-transform) would be nice.\r\n\r\ncc @stevhliu " ]
"2023-04-22T17:09:25Z"
"2023-05-10T20:23:04Z"
"2023-05-10T20:23:04Z"
NONE
null
null
null
### Feature request Introduce an option to select from a variety of audio-loading backends rather than solely relying on the SoundFile library. For instance, if the ffmpeg library is installed, it can serve as a fallback loading option. ### Motivation - The SoundFile library, used in [features/audio.py](https://github.com/huggingface/datasets/blob/649d5a3315f9e7666713b6affe318ee00c7163a0/src/datasets/features/audio.py#L185), supports only a [limited number of audio formats](https://pysoundfile.readthedocs.io/en/latest/index.html?highlight=supported#soundfile.available_formats). - However, current methods for creating audio datasets permit the inclusion of audio files in formats not supported by SoundFile. - As a result, developers may potentially create a dataset they cannot read back. In my most recent project, I dealt with phone call recordings in `.amr` or `.gsm` formats and was genuinely surprised when I couldn't read the dataset I had just packaged a minute prior. Nonetheless, I can still accurately read these files using the librosa library, which employs the audioread library that internally leverages ffmpeg to read such files. Example: ```python audio_dataset_amr = Dataset.from_dict({"audio": ["audio_samples/audio.amr"]}).cast_column("audio", Audio()) audio_dataset_amr.save_to_disk("audio_dataset_amr") audio_dataset_amr = Dataset.load_from_disk("audio_dataset_amr") print(audio_dataset_amr[0]) ``` Results in: ``` Traceback (most recent call last): ... raise LibsndfileError(err, prefix="Error opening {0!r}: ".format(self.name)) soundfile.LibsndfileError: Error opening <_io.BytesIO object at 0x7f316323e4d0>: Format not recognised. ``` While I acknowledge that support for these rare file types may not be a priority, I believe it's quite unfortunate that it's possible to create an unreadable dataset in this manner. ### Your contribution I've created a [simple demo repository](https://github.com/BoringDonut/hf-datasets-ffmpeg-audio) that highlights the mentioned issue. It demonstrates how to create an .amr dataset that results in an error when attempting to read it just a few lines later. Additionally, I've made a [fork with a rudimentary solution](https://github.com/BoringDonut/datasets/blob/fea73a8fbbc8876467c7e6422c9360546c6372d8/src/datasets/features/audio.py#L189) that utilizes ffmpeg to load files not supported by SoundFile. Here you may see github actions fails to read `.amr` dataset using the version of the current dataset, but will work with the patched version: - https://github.com/BoringDonut/hf-datasets-ffmpeg-audio/actions/runs/4773780420/jobs/8487063785 - https://github.com/BoringDonut/hf-datasets-ffmpeg-audio/actions/runs/4773780420/jobs/8487063829 As evident from the GitHub action above, this solution resolves the previously mentioned problem. I'd be happy to create a proper pull request, provide runtime benchmarks and tests if you could offer some guidance on the following: - Where should I incorporate the ffmpeg (or other backends) code? For example, should I create a new file or simply add a function within the Audio class? - Is it feasible to pass the audio-loading function as an argument within the current architecture? This would be useful if I know in advance that I'll be reading files not supported by SoundFile. A few more notes: - In theory, it's possible to load audio using librosa/audioread since librosa is already expected to be installed. However, librosa [will soon discontinue audioread support](https://github.com/librosa/librosa/blob/aacb4c134002903ae56bbd4b4a330519a5abacc0/librosa/core/audio.py#L227). Moreover, using audioread on its own seems inconvenient because it requires a file [path as input](https://github.com/beetbox/audioread/blob/ff9535df934c48038af7be9617fdebb12078cc07/audioread/__init__.py#L108) and cannot work with bytes already loaded into memory or an open file descriptor (as mentioned in [librosa docs](https://librosa.org/doc/main/generated/librosa.load.html#librosa.load), only SoundFile backend supports an open file descriptor as an input).
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 1, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 1, "url": "https://api.github.com/repos/huggingface/datasets/issues/5782/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5782/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/6152
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/6152/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/6152/comments
https://api.github.com/repos/huggingface/datasets/issues/6152/events
https://github.com/huggingface/datasets/issues/6152
1,852,494,646
I_kwDODunzps5uatM2
6,152
FolderBase Dataset automatically resolves under current directory when data_dir is not specified
{ "avatar_url": "https://avatars.githubusercontent.com/u/11533479?v=4", "events_url": "https://api.github.com/users/npuichigo/events{/privacy}", "followers_url": "https://api.github.com/users/npuichigo/followers", "following_url": "https://api.github.com/users/npuichigo/following{/other_user}", "gists_url": "https://api.github.com/users/npuichigo/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/npuichigo", "id": 11533479, "login": "npuichigo", "node_id": "MDQ6VXNlcjExNTMzNDc5", "organizations_url": "https://api.github.com/users/npuichigo/orgs", "received_events_url": "https://api.github.com/users/npuichigo/received_events", "repos_url": "https://api.github.com/users/npuichigo/repos", "site_admin": false, "starred_url": "https://api.github.com/users/npuichigo/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/npuichigo/subscriptions", "type": "User", "url": "https://api.github.com/users/npuichigo" }
[ { "color": "7057ff", "default": true, "description": "Good for newcomers", "id": 1935892877, "name": "good first issue", "node_id": "MDU6TGFiZWwxOTM1ODkyODc3", "url": "https://api.github.com/repos/huggingface/datasets/labels/good%20first%20issue" } ]
open
false
{ "avatar_url": "https://avatars.githubusercontent.com/u/126772439?v=4", "events_url": "https://api.github.com/users/debrupf2946/events{/privacy}", "followers_url": "https://api.github.com/users/debrupf2946/followers", "following_url": "https://api.github.com/users/debrupf2946/following{/other_user}", "gists_url": "https://api.github.com/users/debrupf2946/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/debrupf2946", "id": 126772439, "login": "debrupf2946", "node_id": "U_kgDOB45k1w", "organizations_url": "https://api.github.com/users/debrupf2946/orgs", "received_events_url": "https://api.github.com/users/debrupf2946/received_events", "repos_url": "https://api.github.com/users/debrupf2946/repos", "site_admin": false, "starred_url": "https://api.github.com/users/debrupf2946/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/debrupf2946/subscriptions", "type": "User", "url": "https://api.github.com/users/debrupf2946" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/126772439?v=4", "events_url": "https://api.github.com/users/debrupf2946/events{/privacy}", "followers_url": "https://api.github.com/users/debrupf2946/followers", "following_url": "https://api.github.com/users/debrupf2946/following{/other_user}", "gists_url": "https://api.github.com/users/debrupf2946/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/debrupf2946", "id": 126772439, "login": "debrupf2946", "node_id": "U_kgDOB45k1w", "organizations_url": "https://api.github.com/users/debrupf2946/orgs", "received_events_url": "https://api.github.com/users/debrupf2946/received_events", "repos_url": "https://api.github.com/users/debrupf2946/repos", "site_admin": false, "starred_url": "https://api.github.com/users/debrupf2946/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/debrupf2946/subscriptions", "type": "User", "url": "https://api.github.com/users/debrupf2946" } ]
null
[ "@lhoestq ", "Makes sense, I guess this can be fixed in the load_dataset_builder method.\r\nIt concerns every packaged builder I think (see values in `_PACKAGED_DATASETS_MODULES`)", "I think the behavior is related to these lines, which short circuited the error handling.\r\nhttps://github.com/huggingface/datasets/blob/664a1cb72ea1e6ef7c47e671e2686ca4a35e8d63/src/datasets/load.py#L946-L952\r\n\r\nSo should data_dir be checked here or still delegating to actual `DatasetModule`? In that case, how to properly set `data_files` here.", "This is location in PackagedDatasetModuleFactory.get_module seems the be the right place to check if at least data_dir or data_files are passed", "@mariosasko can you please assign this issue to me,I want to work on this", "#self-assign", "@mariosasko is this issue still open? i would love to kickstart my journey to open source with this issue!\r\nRegards\r\nzutarich", "@zutarich It is unless @debrupf2946 is working on it." ]
"2023-08-16T04:38:09Z"
"2023-10-10T16:30:19Z"
null
CONTRIBUTOR
null
null
null
### Describe the bug FolderBase Dataset automatically resolves under current directory when data_dir is not specified. For example: ``` load_dataset("audiofolder") ``` takes long time to resolve and collect data_files from current directory. But I think it should reach out to this line for error handling https://github.com/huggingface/datasets/blob/cb8c5de5145c7e7eee65391cb7f4d92f0d565d62/src/datasets/packaged_modules/folder_based_builder/folder_based_builder.py#L58-L59 ### Steps to reproduce the bug ``` load_dataset("audiofolder") ``` ### Expected behavior Error report ### Environment info - `datasets` version: 2.14.4 - Platform: Linux-5.15.0-78-generic-x86_64-with-glibc2.17 - Python version: 3.8.15 - Huggingface_hub version: 0.16.4 - PyArrow version: 12.0.1 - Pandas version: 1.5.3
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/6152/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/6152/timeline
null
null
false
https://api.github.com/repos/huggingface/datasets/issues/4397
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/4397/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/4397/comments
https://api.github.com/repos/huggingface/datasets/issues/4397/events
https://github.com/huggingface/datasets/pull/4397
1,246,597,632
PR_kwDODunzps44XcG3
4,397
Fix dependency on dill version
{ "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" }
[]
closed
false
null
[]
null
[ "_The documentation is not available anymore as the PR was closed or merged._" ]
"2022-05-24T13:54:23Z"
"2022-10-26T08:45:37Z"
"2022-05-25T13:54:08Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/4397.diff", "html_url": "https://github.com/huggingface/datasets/pull/4397", "merged_at": "2022-05-25T13:54:08Z", "patch_url": "https://github.com/huggingface/datasets/pull/4397.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/4397" }
We had to make a hotfix by pinning dill: - #4380 because from version 0.3.5, our custom `save_function` pickling function was raising an exception: - #4379 This PR fixes this by implementing our custom `save_function` depending on the version of dill. CC: @anivegesana This PR needs first being merged: - [x] #4384 - so that a circular import is fixed It is also convenient to merge first: - [x] #4385
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/4397/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/4397/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/1738
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/1738/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/1738/comments
https://api.github.com/repos/huggingface/datasets/issues/1738/events
https://github.com/huggingface/datasets/pull/1738
786,068,440
MDExOlB1bGxSZXF1ZXN0NTU0OTk2NDU4
1,738
Conda support
{ "avatar_url": "https://avatars.githubusercontent.com/u/30755778?v=4", "events_url": "https://api.github.com/users/LysandreJik/events{/privacy}", "followers_url": "https://api.github.com/users/LysandreJik/followers", "following_url": "https://api.github.com/users/LysandreJik/following{/other_user}", "gists_url": "https://api.github.com/users/LysandreJik/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/LysandreJik", "id": 30755778, "login": "LysandreJik", "node_id": "MDQ6VXNlcjMwNzU1Nzc4", "organizations_url": "https://api.github.com/users/LysandreJik/orgs", "received_events_url": "https://api.github.com/users/LysandreJik/received_events", "repos_url": "https://api.github.com/users/LysandreJik/repos", "site_admin": false, "starred_url": "https://api.github.com/users/LysandreJik/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/LysandreJik/subscriptions", "type": "User", "url": "https://api.github.com/users/LysandreJik" }
[]
closed
false
null
[]
null
[ "Nice thanks :) \r\nNote that in `datasets` the tags are simply the version without the `v`. For example `1.2.1`.", "Do you push tags only for versions?", "Yes I've always used tags only for versions" ]
"2021-01-14T15:11:25Z"
"2021-01-15T10:08:20Z"
"2021-01-15T10:08:19Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/1738.diff", "html_url": "https://github.com/huggingface/datasets/pull/1738", "merged_at": "2021-01-15T10:08:18Z", "patch_url": "https://github.com/huggingface/datasets/pull/1738.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/1738" }
Will push a new version on anaconda cloud every time a tag starting with `v` is pushed (like `v1.2.2`). Will appear here: https://anaconda.org/huggingface/datasets Depends on `conda-forge` for now, so the following is required for installation: ``` conda install -c huggingface -c conda-forge datasets ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 4, "total_count": 4, "url": "https://api.github.com/repos/huggingface/datasets/issues/1738/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/1738/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/5929
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5929/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5929/comments
https://api.github.com/repos/huggingface/datasets/issues/5929/events
https://github.com/huggingface/datasets/issues/5929
1,744,478,456
I_kwDODunzps5n-qD4
5,929
Importing PyTorch reduces multiprocessing performance for map
{ "avatar_url": "https://avatars.githubusercontent.com/u/12814709?v=4", "events_url": "https://api.github.com/users/Maxscha/events{/privacy}", "followers_url": "https://api.github.com/users/Maxscha/followers", "following_url": "https://api.github.com/users/Maxscha/following{/other_user}", "gists_url": "https://api.github.com/users/Maxscha/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Maxscha", "id": 12814709, "login": "Maxscha", "node_id": "MDQ6VXNlcjEyODE0NzA5", "organizations_url": "https://api.github.com/users/Maxscha/orgs", "received_events_url": "https://api.github.com/users/Maxscha/received_events", "repos_url": "https://api.github.com/users/Maxscha/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Maxscha/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Maxscha/subscriptions", "type": "User", "url": "https://api.github.com/users/Maxscha" }
[]
closed
false
null
[]
null
[ "Hi! The times match when I run this code locally or on Colab.\r\n\r\nAlso, we use `multiprocess`, not `multiprocessing`, for parallelization, and torch's `__init__.py` (executed on `import torch` ) slightly modifies the latter.", "Hey Mariosasko,\r\n\r\nThanks for looking into it. We further did some investigations after your comment and figured out it's only affecting some hardware/software configurations with the `pytorch` installation of `conda-forge`. Based on this we found the following issue in PyTorch: https://github.com/pytorch/pytorch/issues/102269 with a quick fix for now.\r\n\r\nSince it seems to be a deeper issue with forking processes, the difference between`multiprocess` and `multiprocessing` didn't make a difference.\r\n\r\nClosing this, since the issue comes from `pytorch` not `dataset`. \r\n" ]
"2023-06-06T19:42:25Z"
"2023-06-16T13:09:12Z"
"2023-06-16T13:09:12Z"
NONE
null
null
null
### Describe the bug I noticed that the performance of my dataset preprocessing with `map(...,num_proc=32)` decreases when PyTorch is imported. ### Steps to reproduce the bug I created two example scripts to reproduce this behavior: ``` import datasets datasets.disable_caching() from datasets import Dataset import time PROC=32 if __name__ == "__main__": dataset = [True] * 10000000 dataset = Dataset.from_dict({'train': dataset}) start = time.time() dataset.map(lambda x: x, num_proc=PROC) end = time.time() print(end - start) ``` Takes around 4 seconds on my machine. While the same code, but with an `import torch`: ``` import datasets datasets.disable_caching() from datasets import Dataset import time import torch PROC=32 if __name__ == "__main__": dataset = [True] * 10000000 dataset = Dataset.from_dict({'train': dataset}) start = time.time() dataset.map(lambda x: x, num_proc=PROC) end = time.time() print(end - start) ``` takes around 22 seconds. ### Expected behavior I would expect that the import of torch to not have such a significant effect on the performance of map using multiprocessing. ### Environment info - `datasets` version: 2.12.0 - Platform: Linux-5.15.0-56-generic-x86_64-with-glibc2.35 - Python version: 3.11.3 - Huggingface_hub version: 0.15.1 - PyArrow version: 12.0.0 - Pandas version: 2.0.2 - torch: 2.0.1
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/5929/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5929/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/1241
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/1241/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/1241/comments
https://api.github.com/repos/huggingface/datasets/issues/1241/events
https://github.com/huggingface/datasets/pull/1241
758,360,643
MDExOlB1bGxSZXF1ZXN0NTMzNTQ1OTQ0
1,241
Opus elhuyar dataset for MT task having languages pair in Spanish to Basque
{ "avatar_url": "https://avatars.githubusercontent.com/u/6419011?v=4", "events_url": "https://api.github.com/users/spatil6/events{/privacy}", "followers_url": "https://api.github.com/users/spatil6/followers", "following_url": "https://api.github.com/users/spatil6/following{/other_user}", "gists_url": "https://api.github.com/users/spatil6/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/spatil6", "id": 6419011, "login": "spatil6", "node_id": "MDQ6VXNlcjY0MTkwMTE=", "organizations_url": "https://api.github.com/users/spatil6/orgs", "received_events_url": "https://api.github.com/users/spatil6/received_events", "repos_url": "https://api.github.com/users/spatil6/repos", "site_admin": false, "starred_url": "https://api.github.com/users/spatil6/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/spatil6/subscriptions", "type": "User", "url": "https://api.github.com/users/spatil6" }
[]
closed
false
null
[]
null
[]
"2020-12-07T10:03:34Z"
"2020-12-19T14:55:12Z"
"2020-12-09T15:12:48Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/1241.diff", "html_url": "https://github.com/huggingface/datasets/pull/1241", "merged_at": "2020-12-09T15:12:48Z", "patch_url": "https://github.com/huggingface/datasets/pull/1241.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/1241" }
Opus elhuyar dataset for MT task having languages pair in Spanish to Basque More info : http://opus.nlpl.eu/Elhuyar.php
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/1241/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/1241/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/4787
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/4787/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/4787/comments
https://api.github.com/repos/huggingface/datasets/issues/4787/events
https://github.com/huggingface/datasets/issues/4787
1,328,243,911
I_kwDODunzps5PK2TH
4,787
NonMatchingChecksumError in mbpp dataset
{ "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" }
[ { "color": "d73a4a", "default": true, "description": "Something isn't working", "id": 1935892857, "name": "bug", "node_id": "MDU6TGFiZWwxOTM1ODkyODU3", "url": "https://api.github.com/repos/huggingface/datasets/labels/bug" } ]
closed
false
{ "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" } ]
null
[]
"2022-08-04T08:15:51Z"
"2022-08-04T17:21:01Z"
"2022-08-04T17:21:01Z"
MEMBER
null
null
null
## Describe the bug As reported on the Hub [Fix Checksum Mismatch](https://huggingface.co/datasets/mbpp/discussions/1), there is a `NonMatchingChecksumError` when loading mbpp dataset ## Steps to reproduce the bug ```python ds = load_dataset("mbpp", "full") ``` ## Expected results Loading of the dataset without any exception raised. ## Actual results ``` NonMatchingChecksumError Traceback (most recent call last) <ipython-input-1-a3fbdd3ed82e> in <module> ----> 1 ds = load_dataset("mbpp", "full") .../huggingface/datasets/src/datasets/load.py in load_dataset(path, name, data_dir, data_files, split, cache_dir, features, download_config, download_mode, ignore_verifications, keep_in_memory, save_infos, revision, use_auth_token, task, streaming, **config_kwargs) 1791 1792 # Download and prepare data -> 1793 builder_instance.download_and_prepare( 1794 download_config=download_config, 1795 download_mode=download_mode, .../huggingface/datasets/src/datasets/builder.py in 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 706 ) .../huggingface/datasets/src/datasets/builder.py in _download_and_prepare(self, dl_manager, verify_infos) 1225 1226 def _download_and_prepare(self, dl_manager, verify_infos): -> 1227 super()._download_and_prepare(dl_manager, verify_infos, check_duplicate_keys=verify_infos) 1228 1229 def _get_examples_iterable_for_split(self, split_generator: SplitGenerator) -> ExamplesIterable: .../huggingface/datasets/src/datasets/builder.py in _download_and_prepare(self, dl_manager, verify_infos, **prepare_split_kwargs) 773 # Checksums verification 774 if verify_infos and dl_manager.record_checksums: --> 775 verify_checksums( 776 self.info.download_checksums, dl_manager.get_recorded_sizes_checksums(), "dataset source files" 777 ) .../huggingface/datasets/src/datasets/utils/info_utils.py in verify_checksums(expected_checksums, recorded_checksums, verification_name) 38 if len(bad_urls) > 0: 39 error_msg = "Checksums didn't match" + for_verification_name + ":\n" ---> 40 raise NonMatchingChecksumError(error_msg + str(bad_urls)) 41 logger.info("All the checksums matched successfully" + for_verification_name) 42 NonMatchingChecksumError: Checksums didn't match for dataset source files: ['https://raw.githubusercontent.com/google-research/google-research/master/mbpp/mbpp.jsonl'] ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/4787/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/4787/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/2800
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/2800/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/2800/comments
https://api.github.com/repos/huggingface/datasets/issues/2800/events
https://github.com/huggingface/datasets/pull/2800
970,819,988
MDExOlB1bGxSZXF1ZXN0NzEyNzExNTcx
2,800
Support streaming tar files
{ "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" }
[]
closed
false
null
[]
null
[ "Hi ! Why do we need the custom `readline` for exactly ? feel free to add a comment to say why it's needed" ]
"2021-08-14T04:40:17Z"
"2021-08-26T10:02:30Z"
"2021-08-14T04:55:57Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/2800.diff", "html_url": "https://github.com/huggingface/datasets/pull/2800", "merged_at": "2021-08-14T04:55:57Z", "patch_url": "https://github.com/huggingface/datasets/pull/2800.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/2800" }
This PR adds support to stream tar files by using the `fsspec` tar protocol. It also uses the custom `readline` implemented in PR #2786. The corresponding test is implemented in PR #2786.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/2800/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/2800/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/5850
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5850/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5850/comments
https://api.github.com/repos/huggingface/datasets/issues/5850/events
https://github.com/huggingface/datasets/pull/5850
1,707,678,911
PR_kwDODunzps5QZALv
5,850
Make packaged builders skip non-supported file formats
{ "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" }
[]
open
false
null
[]
null
[ "The docs for this PR live [here](https://moon-ci-docs.huggingface.co/docs/datasets/pr_5850). All of your documentation changes will be reflected on that endpoint.", "Good idea. @mariosasko!!!\r\n\r\nPlease note that before this PR, the files are not evenly distributed for archives: `_generate_examples` gets a list of iterators, one for each archive (uncompressed to a directory).", "This change could create silent problems when loading files with extensions that are not listed here. For example\r\n\r\n```python\r\nload_dataset(\"text\", data_files=[\"20230515.log\"])\r\n```\r\n\r\nwouldn't even log anything to say that the file was ignored.\r\n\r\nMaybe it's possible to do this at data files patterns resolution ?\r\n\r\ne.g. in get_data_patterns_in_dataset_repository / get_data_patterns_locally we could return patterns that include the most common extension", "@lhoestq the issue you evoke (.log files skipped by text builder if .log is not added to .txt as supported extension) persists whether you perform the skip at the pattern resolution or in the builder itself.\r\n\r\nThe solution is to add the .log extension (besides the .txt) as supported by text, independently of where we perform the skip (at pattern resolution or in the builder itself).\r\n\r\nAdditionally, at the time we call for pattern resolution, we do not know the builder class yet, so that we cannot pass specific file extensions. First we call data files pattern resolution, and afterwards we call `infer_module_for_data_files` and then know the builder class.", "> @lhoestq the issue you evoke (.log files skipped by text builder if .log is not added to .txt as supported extension) persists whether you perform the skip at the pattern resolution or in the builder itself.\r\n\r\nNo I simply think it's a bad breaking change to not support\r\n\r\n```python\r\nload_dataset(\"<builder_name>\", data_files=[\"path/to/file_with_unknown_or_no_extension\"])\r\n# or\r\nload_dataset(\"<builder_name>\", data_files=[\"https://url.to/file_with_unknown_or_no_extension\"])\r\n```\r\n\r\nIdk if it's the easiest solution, but maybe it's possible to do the change only when inferring the patterns of dataset repositories. This should avoid this breaking change.\r\n\r\nFor example it could do something like that in `get_data_patterns_locally`\r\n\r\n```python\r\n Input:\r\n\r\n my_dataset_repository/\r\n ├── README.md\r\n ├── banner.png\r\n ├── data0.csv\r\n ├── data1.csv\r\n └── data2.csv\r\n\r\n Output:\r\n\r\n {\"train\": [\"**.csv\"]}\r\n```\r\n\r\ninstead of \r\n\r\n```python\r\n Output:\r\n\r\n {\"train\": [\"**\"]}\r\n```", "I agree with @lhoestq - it should still be possible to request parsing a file with a specific builder even if the file's extension is \"invalid\" for the builder, and only ignore non-supported file formats when inferring the patterns.", "Therefore, if I understand correctly, what you suggest is:\r\n- if the user passes a packaged builder to `load_dataset` (e.g. `load_dataset(\"csv\",...`), then the *passed* `data_files` should not be filtered to remove unsupported extensions. No breaking change in this case\r\n- if the user passes a no-script repo/folder to `load_dataset` (e.g. `load_dataset(\"my_dataset_repository\",...`), then the *inferred* data files should be filtered to remove the extensions that are not supported by the inferred module name builder\r\n - if the user passes `data_files` as well, then I guess these should not be filtered, to avoid any breaking change as in the first case above", "Yes that would be ideal imo !", "I think this now fulfills all the requirements.", "I find it a bit confusing to still be able to pass data_files that are going to be silently ignored based on the value of `only_supported_extensions`. My suggestion was to have the right data files pattern, not to filter a posteriori (sorry if my last message was confusing).\r\n\r\nHaving the right data files pattern would also allow users to inspect what's actually being loaded with\r\n```\r\nload_dataset_builder(...).config.data_files\r\n```\r\nand it would list exactly what data files are used." ]
"2023-05-12T13:52:34Z"
"2023-06-07T12:26:38Z"
null
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/5850.diff", "html_url": "https://github.com/huggingface/datasets/pull/5850", "merged_at": null, "patch_url": "https://github.com/huggingface/datasets/pull/5850.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/5850" }
This PR makes packaged builders skip non-supported file formats: - Csv builder skips non-CSV files - Analogously for the other builders Fix #5849.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/5850/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5850/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/3265
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/3265/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/3265/comments
https://api.github.com/repos/huggingface/datasets/issues/3265/events
https://github.com/huggingface/datasets/issues/3265
1,052,666,558
I_kwDODunzps4-vmq-
3,265
Checksum error for kilt_task_wow
{ "avatar_url": "https://avatars.githubusercontent.com/u/22296717?v=4", "events_url": "https://api.github.com/users/slyviacassell/events{/privacy}", "followers_url": "https://api.github.com/users/slyviacassell/followers", "following_url": "https://api.github.com/users/slyviacassell/following{/other_user}", "gists_url": "https://api.github.com/users/slyviacassell/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/slyviacassell", "id": 22296717, "login": "slyviacassell", "node_id": "MDQ6VXNlcjIyMjk2NzE3", "organizations_url": "https://api.github.com/users/slyviacassell/orgs", "received_events_url": "https://api.github.com/users/slyviacassell/received_events", "repos_url": "https://api.github.com/users/slyviacassell/repos", "site_admin": false, "starred_url": "https://api.github.com/users/slyviacassell/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/slyviacassell/subscriptions", "type": "User", "url": "https://api.github.com/users/slyviacassell" }
[ { "color": "d73a4a", "default": true, "description": "Something isn't working", "id": 1935892857, "name": "bug", "node_id": "MDU6TGFiZWwxOTM1ODkyODU3", "url": "https://api.github.com/repos/huggingface/datasets/labels/bug" } ]
closed
false
{ "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" } ]
null
[ "Using `dataset = load_dataset(\"kilt_tasks\", \"wow\", ignore_verifications=True)` may fix it, but I do not think it is a elegant solution.", "Hi @slyviacassell, thanks for reporting.\r\n\r\nYes, there is an issue with the checksum verification. I'm fixing it.\r\n\r\nAnd as you pointed out, in the meantime, you can circumvent the problem by passing `ignore_verifications=True`. " ]
"2021-11-13T12:04:17Z"
"2021-11-16T11:23:53Z"
"2021-11-16T11:21:58Z"
NONE
null
null
null
## Describe the bug Checksum failed when downloads kilt_tasks_wow. See error output for details. ## Steps to reproduce the bug ```python import datasets datasets.load_datasets('kilt_tasks','wow') ``` ## Expected results Download successful ## Actual results ``` Downloading and preparing dataset kilt_tasks/wow (download: 72.07 MiB, generated: 61.82 MiB, post-processed: Unknown size, total: 133.89 MiB) to /root/.cache/huggingface/datasets/kilt_tasks/wow/1.0.0/57dc8b2431e76637e0c6ef79689ca4af61ed3a330e2e0cd62c8971465a35db3a... 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 5121.25it/s] 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 1527.42it/s] Traceback (most recent call last): File "kilt_wow.py", line 30, in <module> main() File "kilt_wow.py", line 27, in main train, dev, test = dataset.generate_k_shot_data(k=32, seed=seed, path="../data/") File "/workspace/projects/CrossFit/tasks/fewshot_gym_dataset.py", line 79, in generate_k_shot_data dataset = self.load_dataset() File "kilt_wow.py", line 21, in load_dataset return datasets.load_dataset('kilt_tasks','wow') File "/opt/conda/lib/python3.8/site-packages/datasets/load.py", line 1632, in load_dataset builder_instance.download_and_prepare( File "/opt/conda/lib/python3.8/site-packages/datasets/builder.py", line 607, in download_and_prepare self._download_and_prepare( File "/opt/conda/lib/python3.8/site-packages/datasets/builder.py", line 679, in _download_and_prepare verify_checksums( File "/opt/conda/lib/python3.8/site-packages/datasets/utils/info_utils.py", line 40, in verify_checksums raise NonMatchingChecksumError(error_msg + str(bad_urls)) datasets.utils.info_utils.NonMatchingChecksumError: Checksums didn't match for dataset source files: ['http://dl.fbaipublicfiles.com/KILT/wow-train-kilt.jsonl', 'http://dl.fbaipublicfiles.com/KILT/wow-dev-kilt.jsonl'] ``` ## Environment info <!-- You can run the command `datasets-cli env` and copy-and-paste its output below. --> - `datasets` version: 1.15.1 - Platform: Linux-4.15.0-161-generic-x86_64-with-glibc2.10 - Python version: 3.8.3 - PyArrow version: 4.0.1
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/3265/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/3265/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/3787
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/3787/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/3787/comments
https://api.github.com/repos/huggingface/datasets/issues/3787/events
https://github.com/huggingface/datasets/pull/3787
1,150,235,569
PR_kwDODunzps4zdE7b
3,787
Fix Google Drive URL to avoid Virus scan warning
{ "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" }
[]
closed
false
null
[]
null
[ "Thanks for this @albertvillanova!", "Once this PR merged into master and until our next `datasets` library release, you can get this fix by installing our library from the GitHub master branch:\r\n```shell\r\npip install git+https://github.com/huggingface/datasets#egg=datasets\r\n```\r\nThen, if you had previously tried to load the data and got the checksum error, you should force the redownload of the data (before the fix, you just downloaded and cached the virus scan warning page, instead of the data file):\r\n```shell\r\nload_dataset(\"...\", download_mode=\"force_redownload\")\r\n```", "Thanks, that solved a bunch of problems we had downstream!\r\ncf. https://github.com/ElementAI/picard/issues/61" ]
"2022-02-25T09:35:12Z"
"2022-03-04T20:43:32Z"
"2022-02-25T11:56:35Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/3787.diff", "html_url": "https://github.com/huggingface/datasets/pull/3787", "merged_at": "2022-02-25T11:56:35Z", "patch_url": "https://github.com/huggingface/datasets/pull/3787.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/3787" }
This PR fixes, in the datasets library instead of in every specific dataset, the issue of downloading the Virus scan warning page instead of the actual data file for Google Drive URLs. Fix #3786, fix #3784.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 1, "laugh": 0, "rocket": 0, "total_count": 1, "url": "https://api.github.com/repos/huggingface/datasets/issues/3787/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/3787/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/3739
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/3739/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/3739/comments
https://api.github.com/repos/huggingface/datasets/issues/3739/events
https://github.com/huggingface/datasets/issues/3739
1,140,329,189
I_kwDODunzps5D-Arl
3,739
Pubmed dataset does not work in streaming mode
{ "avatar_url": "https://avatars.githubusercontent.com/u/77638579?v=4", "events_url": "https://api.github.com/users/abhi-mosaic/events{/privacy}", "followers_url": "https://api.github.com/users/abhi-mosaic/followers", "following_url": "https://api.github.com/users/abhi-mosaic/following{/other_user}", "gists_url": "https://api.github.com/users/abhi-mosaic/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/abhi-mosaic", "id": 77638579, "login": "abhi-mosaic", "node_id": "MDQ6VXNlcjc3NjM4NTc5", "organizations_url": "https://api.github.com/users/abhi-mosaic/orgs", "received_events_url": "https://api.github.com/users/abhi-mosaic/received_events", "repos_url": "https://api.github.com/users/abhi-mosaic/repos", "site_admin": false, "starred_url": "https://api.github.com/users/abhi-mosaic/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/abhi-mosaic/subscriptions", "type": "User", "url": "https://api.github.com/users/abhi-mosaic" }
[ { "color": "d73a4a", "default": true, "description": "Something isn't working", "id": 1935892857, "name": "bug", "node_id": "MDU6TGFiZWwxOTM1ODkyODU3", "url": "https://api.github.com/repos/huggingface/datasets/labels/bug" } ]
closed
false
null
[]
null
[ "Thanks for reporting, @abhi-mosaic (related to #3655).\r\n\r\nPlease note that `xml.etree.ElementTree.parse` already supports streaming:\r\n- #3476\r\n\r\nNo need to refactor to use `open`/`xopen`. Is is enough with importing the package `as ET` (instead of `as etree`)." ]
"2022-02-16T17:13:37Z"
"2022-02-18T14:42:13Z"
"2022-02-18T14:42:13Z"
CONTRIBUTOR
null
null
null
## Describe the bug Trying to use the `pubmed` dataset with `streaming=True` fails. ## Steps to reproduce the bug ```python import datasets pubmed_train = datasets.load_dataset('pubmed', split='train', streaming=True) print (next(iter(pubmed_train))) ``` ## Expected results I would expect to see the first training sample from the pubmed dataset. ## Actual results ``` Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/Users/abhinav/Documents/mosaicml/mosaicml_venv/lib/python3.8/site-packages/datasets/iterable_dataset.py", line 367, in __iter__ for key, example in self._iter(): File "/Users/abhinav/Documents/mosaicml/mosaicml_venv/lib/python3.8/site-packages/datasets/iterable_dataset.py", line 364, in _iter yield from ex_iterable File "/Users/abhinav/Documents/mosaicml/mosaicml_venv/lib/python3.8/site-packages/datasets/iterable_dataset.py", line 79, in __iter__ for key, example in self.generate_examples_fn(**self.kwargs): File "/Users/abhinav/.cache/huggingface/modules/datasets_modules/datasets/pubmed/9715addf10c42a7877a2149ae0c5f2fddabefc775cd1bd9b03ac3f012b86ce46/pubmed.py", line 373, in _generate_examples tree = etree.parse(filename) File "/Library/Developer/CommandLineTools/Library/Frameworks/Python3.framework/Versions/3.8/lib/python3.8/xml/etree/ElementTree.py", line 1202, in parse tree.parse(source, parser) File "/Library/Developer/CommandLineTools/Library/Frameworks/Python3.framework/Versions/3.8/lib/python3.8/xml/etree/ElementTree.py", line 584, in parse source = open(source, "rb") FileNotFoundError: [Errno 2] No such file or directory: 'gzip://pubmed21n0001.xml::ftp://ftp.ncbi.nlm.nih.gov/pubmed/baseline/pubmed21n0001.xml.gz' ``` ## Environment info <!-- You can run the command `datasets-cli env` and copy-and-paste its output below. --> - `datasets` version: 1.18.2 - Platform: macOS-11.4-x86_64-i386-64bit - Python version: 3.8.2 - PyArrow version: 6.0.0 ## Comments The error looks like an issue with `open` vs. `xopen` inside the `xml` package. It looks like it's trying to open the remote source URL, which has been edited with prefix `gzip://...`. Maybe there can be an explicit `xopen` before passing the raw data to `etree`, something like: ```python # Before tree = etree.parse(filename) root = tree.getroot() # After with xopen(filename) as f: data_str = f.read() root = etree.fromstring(data_str) ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/3739/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/3739/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/3206
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/3206/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/3206/comments
https://api.github.com/repos/huggingface/datasets/issues/3206/events
https://github.com/huggingface/datasets/pull/3206
1,044,216,270
PR_kwDODunzps4uEZJe
3,206
[WIP] Allow user-defined hash functions via a registry
{ "avatar_url": "https://avatars.githubusercontent.com/u/2779410?v=4", "events_url": "https://api.github.com/users/BramVanroy/events{/privacy}", "followers_url": "https://api.github.com/users/BramVanroy/followers", "following_url": "https://api.github.com/users/BramVanroy/following{/other_user}", "gists_url": "https://api.github.com/users/BramVanroy/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/BramVanroy", "id": 2779410, "login": "BramVanroy", "node_id": "MDQ6VXNlcjI3Nzk0MTA=", "organizations_url": "https://api.github.com/users/BramVanroy/orgs", "received_events_url": "https://api.github.com/users/BramVanroy/received_events", "repos_url": "https://api.github.com/users/BramVanroy/repos", "site_admin": false, "starred_url": "https://api.github.com/users/BramVanroy/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/BramVanroy/subscriptions", "type": "User", "url": "https://api.github.com/users/BramVanroy" }
[]
closed
false
null
[]
null
[ "Hi @BramVanroy, thanks for your PR.\r\n\r\nThere was a bug in TensorFlow/Keras. We have made a temporary fix in master branch. Please, merge master into your PR branch, so that the CI tests pass.\r\n\r\n```\r\ngit checkout registry\r\ngit fetch upstream master\r\ngit merge upstream/master\r\n```", "@albertvillanova Done. Although new tests will need to be added. I am looking for some feedback on my initial proposal in this PR. Reviews and ideas welcome!", "Hi ! Thanks for diving into this :)\r\n\r\nWith this approach you get the right hash when doing `Hasher.hash(nlp)` but if you try to hash an object that has `nlp` as one of its attributes for example you will get different hashes every time.\r\n\r\nThis is because `Hasher.hash` is not recursive itself. Indeed what happens when you try to hash an object is that:\r\n1. it is dumped with our custom `dill` pickler (which is recursive)\r\n2. the bytes of the dump are hashed\r\n\r\nTo fix this we must integrate the custom hashing as a custom pickler dumping instead.\r\n\r\nNote that we're only using the `pickler.dumps` method and not `pickler.loads` since we only use it to get hashes, so it doesn't matter if `loads` doesn't reconstruct the object exactly. What's important it only to capture all the necessary information that defines how the object transforms the data (here `nlp.to_bytes()` determines how the spacy pipeline transforms the text).\r\n\r\nOur pickler already has a registry and you can register new dump functions with:\r\n```python\r\nimport dill\r\nimport spacy\r\nfrom datasets.utils.py_utils import pklregister\r\n\r\n@pklregister(spacy.Language)\r\ndef _save_spacy_language(pickler, nlp):\r\n pickler.save_reduce(...) # I think we can use nlp.to_bytes() here\r\n dill._dill.log.info(...)\r\n```\r\n\r\nYou can find some examples of custom dump functions in `py_utils.py`", "Ah, darn it. Completely missed that register. Time wasted, unfortunately. \r\n\r\nTo better understand what you mean, I figured I'd try the basis of your snippet and I've noticed quite an annoying side-effect of how the pickle dispatch table seems to work. It explicitly uses an object's [`type()`](https://github.com/python/cpython/blob/87032cfa3dc975d7442fd57dea2c6a56d31c911a/Lib/pickle.py#L557-L558), which makes sense for pickling some (primitive) types it is not ideal for more complex ones, I think. `Hasher.hash` has the same issue as far as I can tell.\r\n\r\nhttps://github.com/huggingface/datasets/blob/d21ce54f2c2782f854f975eb1dc2be6f923b4314/src/datasets/fingerprint.py#L187-L191\r\n\r\nThis is very restrictive, and won't work for subclasses. In the case of spaCy, for instance, we register `Language`, but `nlp` is an instance of `English`, which is a _subclass_ of `Language`. These are different types, and so they will not match in the dispatch table. Maybe this is more general approach to cover such cases? Something like this is a start but too broad, but ideally a hierarchy is constructed and traversed of all classes in the table and the lowest class is selected to ensure that the most specific class function is dispatched.\r\n\r\n```python\r\n def hash(cls, value: Any) -> str:\r\n # Try to match the exact type\r\n if type(value) in cls.dispatch:\r\n return cls.dispatch[type(value)](cls, value)\r\n\r\n # Try to match instance (superclass)\r\n for type_cls, func in cls.dispatch.items():\r\n if isinstance(value, type_cls):\r\n return cls.dispatch[type_cls](cls, value)\r\n\r\n return cls.hash_default(value)\r\n```\r\n\r\nThis does not solve the problem for pickling, though. That is quite unfortunate IMO because that implies that users always have to specify the most specific class, which is not always obvious. (For instance, `spacy.load`'s signature returns `Language`, but as said before a subclass might be returned.)\r\n\r\nSecond, I am trying to understand `save_reduce` but I can find very little documentation about it, only the source code which is quite cryptic. Can you explain it a bit? The required arguments are not very clear to me and there is no docstring.\r\n\r\n```python\r\n def save_reduce(self, func, args, state=None, listitems=None, dictitems=None, obj=None):\r\n```", "Here is an example illustrating the problem with sub-classes.\r\n\r\n```python\r\nimport spacy\r\n\r\nfrom spacy import Language\r\nfrom spacy.lang.en import English\r\n\r\nfrom datasets.utils.py_utils import Pickler, pklregister\r\n\r\n# Only useful in the registry (matching with `nlp`)\r\n# if you swap it out for very specific `English`\r\n@pklregister(English)\r\ndef hash_spacy_language(pickler, nlp):\r\n pass\r\n\r\n\r\ndef main():\r\n print(Pickler.dispatch)\r\n nlp = spacy.load(\"en_core_web_sm\")\r\n print(f\"NLP type {type(nlp)} in dispatch table? \", type(nlp) in Pickler.dispatch)\r\n\r\n\r\nif __name__ == '__main__':\r\n main()\r\n```", "Indeed that's not ideal.\r\nMaybe we could integrate all the subclasses directly in `datasets`. That's simple to do but the catch is that if users have new subclasses of `Language` it won't work.\r\n\r\nOtherwise we can see how to make the API simpler for users by allowing subclasses\r\n```python\r\n# if you swap it out for very specific `English`\r\n@pklregister(Language, allow_subclasses=True)\r\ndef hash_spacy_language(pickler, nlp):\r\n pass\r\n```\r\n\r\nHere is an idea how to make this work, let me know what you think:\r\n\r\nWhen `Pickler.dumps` is called, it uses `Pickler.save_global` which is a method that is going to be called recursively on all the objects. We can customize this part, and make it work as we want when it encounters a subclass of `Language`.\r\n\r\nFor example when it encounters a subclass of `Language`, we can dynamically register the hashing function for the subclass (`English` for example) in `Pickler.save_global`, right before calling the actual `dill.Pickler.save_global(self, obj, name=name)`:\r\n```python\r\npklregister(type(obj))(hash_function_registered_for_parent_class)\r\ndill.Pickler.save_global(self, obj, name=name)\r\n```\r\n\r\nIn practice that means we can have an additional dispatch dictionary (similar to `Pickler.dispatch`) to store the hashing functions when `allow_subclasses=True`, and use this dictionary in `Pickler.save_global` to check if we need to use a hashing function registered with `allow_subclasses=True` and get `hash_function_registered_for_parent_class`.", "If I understood you correctly, I do not think that that is enough because you are only doing this for a type and its direct parent class. You could do this for all superclasses (so traverse all ancestors and find the registered function for the first that is encountered). I can work on that, if you agree. The one thing that I am not sure about is how you want to create the secondary dispatch table. An empty dict as class variable in Pickler? (It doesn't have to be a true dispatcher, I think.)\r\n\r\nI do not think that dynamic registration is the ideal situation (it feels a bit hacky). An alternative would be to subclass Pickle and Dill to make sure that instead of just type() checking in the dispatch table also superclasses are considered. But that is probably overkill.", "> You could do this for all superclasses (so traverse all ancestors and find the registered function for the first that is encountered)\r\n\r\nThat makes sense indeed !\r\n\r\n> The one thing that I am not sure about is how you want to create the secondary dispatch table. An empty dict as class variable in Pickler? (It doesn't have to be a true dispatcher, I think.)\r\n\r\nSure, let's try to not use too complicated stuff\r\n\r\n> I do not think that dynamic registration is the ideal situation (it feels a bit hacky). An alternative would be to subclass Pickle and Dill to make sure that instead of just type() checking in the dispatch table also superclasses are considered. But that is probably overkill.\r\n\r\nIndeed that would feel less hacky, but maybe it's too complex just for this. I feel like this part of the library is already hard to understand when you're not familiar with pickle. IMO having only a few changes that are simpler to understand is better than having a rewrite of `dill`'s core code.\r\n\r\nThanks a lot for your insights, it looks like we're going to have something that works well and that unlocks some nice flexibility for users :) Feel free to ping me anytime if I can help on this", "Sure, thanks for brainstorming! I'll try to work on it this weekend. Will also revert the current changes in this PR and rename it. ", "It seems like this is going in the right direction :). \r\n\r\n@BramVanroy Just one small suggestion for future contributions: instead of using `WIP` in the PR title, you can create a draft PR if you're still working on it.", "Maybe I should just create a new (draft) PR then, seeing that I'll have to rename and revert the changes anyway? I'll link to this PR so that the discussion is at least referenced.", "I can convert this PR to a draft PR. Let me know what would you prefer.", "I think reverting my previous commits would make for a dirty (or confusing) commit history, so I'll just create a new one. Thanks." ]
"2021-11-03T23:25:42Z"
"2021-11-05T12:38:11Z"
"2021-11-05T12:38:04Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/3206.diff", "html_url": "https://github.com/huggingface/datasets/pull/3206", "merged_at": null, "patch_url": "https://github.com/huggingface/datasets/pull/3206.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/3206" }
Inspired by the discussion on hashing in https://github.com/huggingface/datasets/issues/3178#issuecomment-959016329, @lhoestq suggested that it would be neat to allow users more control over the hashing process. Specifically, it would be great if users can specify specific hashing functions depending on the **class** of the object. As an example, we found in the linked topic that loaded spaCy models (`Language` objects) have different hashes when `dump`'d, but their byte representation with `Language.to_bytes()` _is_ deterministic. It would therefore be great if we could specify that for `Language` objects, the hasher should hash the objects `to_bytes()` return value instead of the object itself. This PR adds a new, but tiny, dependency to manage the registry, namely [`catalogue`](https://github.com/explosion/catalogue). Two files have been changed (apart from the added dependency in `setup.py`) and one file has been added. **utils.registry** (added) This file defines our custom Registry and builds a registry called "hashers". A Registry is basically dictionary from names (str) to functions. A function can be added to the registry by a decorator, e.g. ```python @hashers.register(spacy.Language) def hash_spacy_language(nlp): return Hasher.hash(nlp.to_bytes()) ``` You'll notice that `spacy.Language` is not a string, even though the registry holds a str->func mapping. To accomplish this with classes in a dynamic way, catalogue.Registry needed to be subclassed and modified as `DatasetsRegistry`. All methods that use a name as an input are now modified so that classes are deterministically converted in strings in such a way that we can later retrieve the actual class from the string (below). **utils.py_utils** (modified) Added two functions to deal with classes and their qualified names, that is, their full descriptive name including the module. On the one hand it allows us to retrieve a string from a given class, e.g. given `Module` class, return `torch.nn.Module` str. Conversly, a function is added to convert such a full qualified name into a class. For instance, given the string `torch.nn.Module`, return the `Module` class. These straightforward methods allow us to interchangeably use classes and strings without any needed user interaction - they can just register a class, and behind the scenes `DatasetsRegistry` converts these to deterministic strings. **fingerprint** (modified) Updated Hasher.hash so that if the object to hash is an instance of a class in the registry, the registered function is used to hash the object instead of the default behavior. To do so we iterate over the registry `hashers` and convert its keys (strings) into classes, and then we can use `isinstance`. ```python # Check if the current object is an instance that is # applicable to the user-defined hashers. If so, hash # with the user-defined function for full_module_name, func in hashers.get_all().items(): registered_cls = get_cls_from_qualname(full_module_name) if isinstance(value, registered_cls): return func(value) ``` **Putting it all together** To test this, you can try the following example with spaCy. First install spaCy from source and checkout a specific commit. ```shell git clone https://github.com/explosion/spaCy.git cd spaCy/ git checkout cab9209c3dfcd1b75dfe5657f10e52c4d847a3cf cd .. git clone https://github.com/BramVanroy/datasets.git cd datasets git checkout registry pip install -e . pip install ../spaCy spacy download en_core_web_sm ``` Now you can run the following script. By default it will use the custom hasher function for the Language object. You can enable the default behavior by commenting out `@hashers.register...`. ```python import spacy from datasets.fingerprint import Hasher from datasets.utils.registry import hashers # Register a function so that when the Hasher encounters a spacy.Language object # it uses this custom function to hash instead of the default @hashers.register(spacy.Language) def hash_spacy_language(nlp): return Hasher.hash(nlp.to_bytes()) def main(): print(hashers.get_all()) nlp = spacy.load("en_core_web_sm") dump1 = Hasher.hash(nlp) nlp = spacy.load("en_core_web_sm") dump2 = Hasher.hash(nlp) print(dump1) # succeeds when using the registered custom function # fails if using the default assert dump1 == dump2 if __name__ == '__main__': main() ``` To do ==== - The above is just a proof-of-concept. I am open to changes/suggestions - Tests still need to be written - We should consider whether we can make `DatasetsRegistry` very restrictive and ONLY allowing classes. That would make testing easier - otherwise we also need to test for other sorts of objects. - Maybe the `hashers` definition is better suited in `fingerprint`? - Documentation/examples need to be updated - Not sure why the logger is not working in `hash()` - `get_cls_from_qualname` might need a fail-safe: is it possible for a full_qualname to not have a module, and if so how do we deal with that?
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/3206/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/3206/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/5980
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5980/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5980/comments
https://api.github.com/repos/huggingface/datasets/issues/5980/events
https://github.com/huggingface/datasets/issues/5980
1,770,255,973
I_kwDODunzps5pg_Zl
5,980
Viewing dataset card returns “502 Bad Gateway”
{ "avatar_url": "https://avatars.githubusercontent.com/u/4241811?v=4", "events_url": "https://api.github.com/users/tbenthompson/events{/privacy}", "followers_url": "https://api.github.com/users/tbenthompson/followers", "following_url": "https://api.github.com/users/tbenthompson/following{/other_user}", "gists_url": "https://api.github.com/users/tbenthompson/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/tbenthompson", "id": 4241811, "login": "tbenthompson", "node_id": "MDQ6VXNlcjQyNDE4MTE=", "organizations_url": "https://api.github.com/users/tbenthompson/orgs", "received_events_url": "https://api.github.com/users/tbenthompson/received_events", "repos_url": "https://api.github.com/users/tbenthompson/repos", "site_admin": false, "starred_url": "https://api.github.com/users/tbenthompson/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tbenthompson/subscriptions", "type": "User", "url": "https://api.github.com/users/tbenthompson" }
[]
closed
false
null
[]
null
[ "Can you try again? Maybe there was a minor outage.", "Yes, it seems to be working now. In case it's helpful, the outage lasted several days. It was failing as late as yesterday morning. ", "we fixed something on the server side, glad it's fixed now" ]
"2023-06-22T19:14:48Z"
"2023-06-27T08:38:19Z"
"2023-06-26T14:42:45Z"
NONE
null
null
null
The url is: https://huggingface.co/datasets/Confirm-Labs/pile_ngrams_trigrams I am able to successfully view the “Files and versions” tab: [Confirm-Labs/pile_ngrams_trigrams at main](https://huggingface.co/datasets/Confirm-Labs/pile_ngrams_trigrams/tree/main) Any help would be appreciated! Thanks! I hope this is the right place to report an issue like this.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/5980/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5980/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/3192
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/3192/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/3192/comments
https://api.github.com/repos/huggingface/datasets/issues/3192/events
https://github.com/huggingface/datasets/issues/3192
1,041,308,086
I_kwDODunzps4-ERm2
3,192
Multiprocessing filter/map (tests) not working on Windows
{ "avatar_url": "https://avatars.githubusercontent.com/u/2779410?v=4", "events_url": "https://api.github.com/users/BramVanroy/events{/privacy}", "followers_url": "https://api.github.com/users/BramVanroy/followers", "following_url": "https://api.github.com/users/BramVanroy/following{/other_user}", "gists_url": "https://api.github.com/users/BramVanroy/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/BramVanroy", "id": 2779410, "login": "BramVanroy", "node_id": "MDQ6VXNlcjI3Nzk0MTA=", "organizations_url": "https://api.github.com/users/BramVanroy/orgs", "received_events_url": "https://api.github.com/users/BramVanroy/received_events", "repos_url": "https://api.github.com/users/BramVanroy/repos", "site_admin": false, "starred_url": "https://api.github.com/users/BramVanroy/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/BramVanroy/subscriptions", "type": "User", "url": "https://api.github.com/users/BramVanroy" }
[ { "color": "d73a4a", "default": true, "description": "Something isn't working", "id": 1935892857, "name": "bug", "node_id": "MDU6TGFiZWwxOTM1ODkyODU3", "url": "https://api.github.com/repos/huggingface/datasets/labels/bug" } ]
open
false
null
[]
null
[]
"2021-11-01T15:36:08Z"
"2021-11-01T15:57:03Z"
null
CONTRIBUTOR
null
null
null
While running the tests, I found that the multiprocessing examples fail on Windows, or rather they do not complete: they cause a deadlock. I haven't dug deep into it, but they do not seem to work as-is. I currently have no time to tests this in detail but at least the tests seem not to run correctly (deadlocking). ## Steps to reproduce the bug ```shell pytest tests/test_arrow_dataset.py -k "test_filter_multiprocessing" pytest tests/test_arrow_dataset.py -k "test_map_multiprocessing" ``` ## Expected results The functionality to work on all platforms. ## Actual results Deadlock. ## Environment info - `datasets` version: 1.14.1.dev0 - Platform: Windows-10-10.0.19041-SP0 - Python version: 3.9.2, also tested with 3.7.9 - PyArrow version: 4.0.1
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/3192/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/3192/timeline
null
null
false
https://api.github.com/repos/huggingface/datasets/issues/6110
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/6110/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/6110/comments
https://api.github.com/repos/huggingface/datasets/issues/6110/events
https://github.com/huggingface/datasets/issues/6110
1,831,110,633
I_kwDODunzps5tJIfp
6,110
[BUG] Dataset initialized from in-memory data does not create cache.
{ "avatar_url": "https://avatars.githubusercontent.com/u/57797966?v=4", "events_url": "https://api.github.com/users/MattYoon/events{/privacy}", "followers_url": "https://api.github.com/users/MattYoon/followers", "following_url": "https://api.github.com/users/MattYoon/following{/other_user}", "gists_url": "https://api.github.com/users/MattYoon/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/MattYoon", "id": 57797966, "login": "MattYoon", "node_id": "MDQ6VXNlcjU3Nzk3OTY2", "organizations_url": "https://api.github.com/users/MattYoon/orgs", "received_events_url": "https://api.github.com/users/MattYoon/received_events", "repos_url": "https://api.github.com/users/MattYoon/repos", "site_admin": false, "starred_url": "https://api.github.com/users/MattYoon/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/MattYoon/subscriptions", "type": "User", "url": "https://api.github.com/users/MattYoon" }
[]
closed
false
null
[]
null
[ "This is expected behavior. You must provide `cache_file_name` when performing `.map` on an in-memory dataset for the result to be cached." ]
"2023-08-01T11:58:58Z"
"2023-08-17T14:03:01Z"
"2023-08-17T14:03:00Z"
NONE
null
null
null
### Describe the bug `Dataset` initialized from in-memory data (dictionary in my case, haven't tested with other types) does not create cache when processed with the `map` method, unlike `Dataset` initialized by other methods such as `load_dataset`. ### Steps to reproduce the bug ```python # below code was run the second time so the map function can be loaded from cache if exists from datasets import load_dataset, Dataset dataset = load_dataset("tatsu-lab/alpaca")['train'] dataset = dataset.map(lambda x: {'input': x['input'] + 'hi'}) # some random map print(len(dataset.cache_files)) # 1 # copy the exact same data but initialize from a dictionary memory_dataset = Dataset.from_dict({ 'instruction': dataset['instruction'], 'input': dataset['input'], 'output': dataset['output'], 'text': dataset['text']}) memory_dataset = memory_dataset.map(lambda x: {'input': x['input'] + 'hi'}) # exact same map print(len(memory_dataset.cache_files)) # Map: 100%|██████████| 52002[/52002] # 0 ``` ### Expected behavior The `map` function should create cache regardless of the method the `Dataset` was created. ### Environment info - `datasets` version: 2.14.2 - Platform: Linux-5.15.0-41-generic-x86_64-with-glibc2.31 - Python version: 3.9.16 - Huggingface_hub version: 0.14.1 - PyArrow version: 11.0.0 - Pandas version: 1.5.3
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/6110/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/6110/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/3943
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/3943/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/3943/comments
https://api.github.com/repos/huggingface/datasets/issues/3943/events
https://github.com/huggingface/datasets/pull/3943
1,171,185,070
PR_kwDODunzps40ipnu
3,943
[Doc] Don't use v for version tags on GitHub
{ "avatar_url": "https://avatars.githubusercontent.com/u/35901082?v=4", "events_url": "https://api.github.com/users/sgugger/events{/privacy}", "followers_url": "https://api.github.com/users/sgugger/followers", "following_url": "https://api.github.com/users/sgugger/following{/other_user}", "gists_url": "https://api.github.com/users/sgugger/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sgugger", "id": 35901082, "login": "sgugger", "node_id": "MDQ6VXNlcjM1OTAxMDgy", "organizations_url": "https://api.github.com/users/sgugger/orgs", "received_events_url": "https://api.github.com/users/sgugger/received_events", "repos_url": "https://api.github.com/users/sgugger/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sgugger/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sgugger/subscriptions", "type": "User", "url": "https://api.github.com/users/sgugger" }
[]
closed
false
null
[]
null
[ "The docs for this PR live [here](https://moon-ci-docs.huggingface.co/docs/datasets/pr_3943). All of your documentation changes will be reflected on that endpoint." ]
"2022-03-16T15:28:30Z"
"2022-03-17T11:46:26Z"
"2022-03-17T11:46:25Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/3943.diff", "html_url": "https://github.com/huggingface/datasets/pull/3943", "merged_at": "2022-03-17T11:46:25Z", "patch_url": "https://github.com/huggingface/datasets/pull/3943.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/3943" }
This removes the `v` automatically used by `doc-builder` for versions.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/3943/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/3943/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/2680
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/2680/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/2680/comments
https://api.github.com/repos/huggingface/datasets/issues/2680/events
https://github.com/huggingface/datasets/pull/2680
948,649,716
MDExOlB1bGxSZXF1ZXN0NjkzNDYyNzY3
2,680
feat: 🎸 add paperswithcode id for qasper dataset
{ "avatar_url": "https://avatars.githubusercontent.com/u/1676121?v=4", "events_url": "https://api.github.com/users/severo/events{/privacy}", "followers_url": "https://api.github.com/users/severo/followers", "following_url": "https://api.github.com/users/severo/following{/other_user}", "gists_url": "https://api.github.com/users/severo/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/severo", "id": 1676121, "login": "severo", "node_id": "MDQ6VXNlcjE2NzYxMjE=", "organizations_url": "https://api.github.com/users/severo/orgs", "received_events_url": "https://api.github.com/users/severo/received_events", "repos_url": "https://api.github.com/users/severo/repos", "site_admin": false, "starred_url": "https://api.github.com/users/severo/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/severo/subscriptions", "type": "User", "url": "https://api.github.com/users/severo" }
[]
closed
false
null
[]
null
[]
"2021-07-20T13:22:29Z"
"2021-07-20T14:04:10Z"
"2021-07-20T14:04:10Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/2680.diff", "html_url": "https://github.com/huggingface/datasets/pull/2680", "merged_at": "2021-07-20T14:04:10Z", "patch_url": "https://github.com/huggingface/datasets/pull/2680.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/2680" }
The reverse reference exists on paperswithcode: https://paperswithcode.com/dataset/qasper
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/2680/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/2680/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/4108
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/4108/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/4108/comments
https://api.github.com/repos/huggingface/datasets/issues/4108/events
https://github.com/huggingface/datasets/pull/4108
1,194,578,584
PR_kwDODunzps41u3j2
4,108
Perplexity Speedup
{ "avatar_url": "https://avatars.githubusercontent.com/u/27527747?v=4", "events_url": "https://api.github.com/users/emibaylor/events{/privacy}", "followers_url": "https://api.github.com/users/emibaylor/followers", "following_url": "https://api.github.com/users/emibaylor/following{/other_user}", "gists_url": "https://api.github.com/users/emibaylor/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/emibaylor", "id": 27527747, "login": "emibaylor", "node_id": "MDQ6VXNlcjI3NTI3NzQ3", "organizations_url": "https://api.github.com/users/emibaylor/orgs", "received_events_url": "https://api.github.com/users/emibaylor/received_events", "repos_url": "https://api.github.com/users/emibaylor/repos", "site_admin": false, "starred_url": "https://api.github.com/users/emibaylor/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/emibaylor/subscriptions", "type": "User", "url": "https://api.github.com/users/emibaylor" }
[]
closed
false
null
[]
null
[ "WRT the high values, can you add some unit tests with some [string, model] pairs and their resulting perplexity code, and @TristanThrush can run the same pairs through his version of the code?", "_The documentation is not available anymore as the PR was closed or merged._", "I thought that the perplexity metric should output the average perplexity value of all the strings that it gets as input (not a perplexity value per string, as the new version does).\r\n@lhoestq , @TristanThrush thoughts?", "> I thought that the perplexity metric should output the average perplexity value of all the strings that it gets as input (not a perplexity value per string, as the new version does). @lhoestq , @TristanThrush thoughts?\r\n\r\nI support this change from Emi. If we have a perplexity function that loads GPT2 and then returns an average over all of the strings, then it is impossible to get multiple perplexities of a batch of strings efficiently. If we have this new perplexity function that is built for batching, then it is possible to get a batch of perplexities efficiently and you can still compute the average efficiently afterwards.", "Thanks a lot for working on this @emibaylor @TristanThrush :)\r\n\r\nFor consistency with the other metrics, I think it's nice if we return the mean perplexity. Though I agree that having the separate perplexities per sample can also be useful. What do you think about returning both ?\r\n```python\r\nreturn {\"perplexities\": ppls, \"mean_perplexity\": np.mean(ppls)}\r\n```\r\nwe're also doing this for the COMET metric.", "> Thanks a lot for working on this @emibaylor @TristanThrush :)\r\n> \r\n> For consistency with the other metrics, I think it's nice if we return the mean perplexity. Though I agree that having the separate perplexities per sample can also be useful. What do you think about returning both ?\r\n> \r\n> ```python\r\n> return {\"perplexities\": ppls, \"mean_perplexity\": np.mean(ppls)}\r\n> ```\r\n> \r\n> we're also doing this for the COMET metric.\r\n\r\nThanks! Sounds great to me.", "The CI fail is unrelated to your PR and has been fixed on master, feel free to merge the master branch into your PR to fix the CI ;)" ]
"2022-04-06T12:57:21Z"
"2022-04-20T13:00:54Z"
"2022-04-20T12:54:42Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/4108.diff", "html_url": "https://github.com/huggingface/datasets/pull/4108", "merged_at": "2022-04-20T12:54:42Z", "patch_url": "https://github.com/huggingface/datasets/pull/4108.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/4108" }
This PR makes necessary changes to perplexity such that: - it runs much faster (via batching) - it throws an error when input is empty, or when input is one word without <BOS> token - it adds the option to add a <BOS> token Issues: - The values returned are extremely high, and I'm worried they aren't correct. Even if they are correct, they are sometimes returned as `inf`, which is not very useful (see [comment below](https://github.com/huggingface/datasets/pull/4108#discussion_r843931094) for some of the output values). - If the values are not correct, can you help me find the error? - If the values are correct, it might be worth it to measure something like perplexity per word, which would allow us to get actual values for the larger perplexities, instead of just `inf` Future: - `stride` is not currently implemented here. I have some thoughts on how to make it happen with batching, but I think it would be better to get another set of eyes to look at any possible errors causing such large values now rather than later.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/4108/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/4108/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/5693
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5693/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5693/comments
https://api.github.com/repos/huggingface/datasets/issues/5693/events
https://github.com/huggingface/datasets/pull/5693
1,649,934,749
PR_kwDODunzps5NYdPS
5,693
[docs] Split pattern search order
{ "avatar_url": "https://avatars.githubusercontent.com/u/59462357?v=4", "events_url": "https://api.github.com/users/stevhliu/events{/privacy}", "followers_url": "https://api.github.com/users/stevhliu/followers", "following_url": "https://api.github.com/users/stevhliu/following{/other_user}", "gists_url": "https://api.github.com/users/stevhliu/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/stevhliu", "id": 59462357, "login": "stevhliu", "node_id": "MDQ6VXNlcjU5NDYyMzU3", "organizations_url": "https://api.github.com/users/stevhliu/orgs", "received_events_url": "https://api.github.com/users/stevhliu/received_events", "repos_url": "https://api.github.com/users/stevhliu/repos", "site_admin": false, "starred_url": "https://api.github.com/users/stevhliu/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/stevhliu/subscriptions", "type": "User", "url": "https://api.github.com/users/stevhliu" }
[]
closed
false
null
[]
null
[ "_The documentation is not available anymore as the PR was closed or merged._", "<details>\n<summary>Show benchmarks</summary>\n\nPyArrow==8.0.0\n\n<details>\n<summary>Show updated benchmarks!</summary>\n\n### Benchmark: benchmark_array_xd.json\n\n| metric | read_batch_formatted_as_numpy after write_array2d | read_batch_formatted_as_numpy after write_flattened_sequence | read_batch_formatted_as_numpy after write_nested_sequence | read_batch_unformated after write_array2d | read_batch_unformated after write_flattened_sequence | read_batch_unformated after write_nested_sequence | read_col_formatted_as_numpy after write_array2d | read_col_formatted_as_numpy after write_flattened_sequence | read_col_formatted_as_numpy after write_nested_sequence | read_col_unformated after write_array2d | read_col_unformated after write_flattened_sequence | read_col_unformated after write_nested_sequence | read_formatted_as_numpy after write_array2d | read_formatted_as_numpy after write_flattened_sequence | read_formatted_as_numpy after write_nested_sequence | read_unformated after write_array2d | read_unformated after write_flattened_sequence | read_unformated after write_nested_sequence | write_array2d | write_flattened_sequence | write_nested_sequence |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.007841 / 0.011353 (-0.003512) | 0.005640 / 0.011008 (-0.005368) | 0.096465 / 0.038508 (0.057957) | 0.036476 / 0.023109 (0.013367) | 0.306431 / 0.275898 (0.030533) | 0.339545 / 0.323480 (0.016065) | 0.006064 / 0.007986 (-0.001922) | 0.004404 / 0.004328 (0.000076) | 0.073130 / 0.004250 (0.068879) | 0.052765 / 0.037052 (0.015713) | 0.309895 / 0.258489 (0.051406) | 0.354037 / 0.293841 (0.060196) | 0.037127 / 0.128546 (-0.091420) | 0.012387 / 0.075646 (-0.063260) | 0.333503 / 0.419271 (-0.085769) | 0.059799 / 0.043533 (0.016266) | 0.305496 / 0.255139 (0.050358) | 0.324122 / 0.283200 (0.040922) | 0.107007 / 0.141683 (-0.034676) | 1.416743 / 1.452155 (-0.035411) | 1.520772 / 1.492716 (0.028055) |\n\n### Benchmark: benchmark_getitem\\_100B.json\n\n| metric | get_batch_of\\_1024\\_random_rows | get_batch_of\\_1024\\_rows | get_first_row | get_last_row |\n|--------|---|---|---|---|\n| new / old (diff) | 0.261233 / 0.018006 (0.243227) | 0.573806 / 0.000490 (0.573316) | 0.000390 / 0.000200 (0.000190) | 0.000058 / 0.000054 (0.000003) |\n\n### Benchmark: benchmark_indices_mapping.json\n\n| metric | select | shard | shuffle | sort | train_test_split |\n|--------|---|---|---|---|---|\n| new / old (diff) | 0.027672 / 0.037411 (-0.009740) | 0.112803 / 0.014526 (0.098278) | 0.121085 / 0.176557 (-0.055471) | 0.176056 / 0.737135 (-0.561080) | 0.127171 / 0.296338 (-0.169167) |\n\n### Benchmark: benchmark_iterating.json\n\n| metric | read 5000 | read 50000 | read_batch 50000 10 | read_batch 50000 100 | read_batch 50000 1000 | read_formatted numpy 5000 | read_formatted pandas 5000 | read_formatted tensorflow 5000 | read_formatted torch 5000 | read_formatted_batch numpy 5000 10 | read_formatted_batch numpy 5000 1000 | shuffled read 5000 | shuffled read 50000 | shuffled read_batch 50000 10 | shuffled read_batch 50000 100 | shuffled read_batch 50000 1000 | shuffled read_formatted numpy 5000 | shuffled read_formatted_batch numpy 5000 10 | shuffled read_formatted_batch numpy 5000 1000 |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.414756 / 0.215209 (0.199547) | 4.148743 / 2.077655 (2.071088) | 1.883940 / 1.504120 (0.379820) | 1.698771 / 1.541195 (0.157576) | 1.811926 / 1.468490 (0.343436) | 0.708293 / 4.584777 (-3.876484) | 3.780456 / 3.745712 (0.034744) | 2.098556 / 5.269862 (-3.171306) | 1.323512 / 4.565676 (-3.242164) | 0.086253 / 0.424275 (-0.338022) | 0.012587 / 0.007607 (0.004980) | 0.514824 / 0.226044 (0.288779) | 5.157415 / 2.268929 (2.888487) | 2.382519 / 55.444624 (-53.062105) | 2.014539 / 6.876477 (-4.861938) | 2.215239 / 2.142072 (0.073166) | 0.847178 / 4.805227 (-3.958049) | 0.170053 / 6.500664 (-6.330611) | 0.066461 / 0.075469 (-0.009008) |\n\n### Benchmark: benchmark_map_filter.json\n\n| metric | filter | map fast-tokenizer batched | map identity | map identity batched | map no-op batched | map no-op batched numpy | map no-op batched pandas | map no-op batched pytorch | map no-op batched tensorflow |\n|--------|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 1.199056 / 1.841788 (-0.642732) | 15.244999 / 8.074308 (7.170691) | 14.661593 / 10.191392 (4.470201) | 0.168855 / 0.680424 (-0.511569) | 0.017889 / 0.534201 (-0.516312) | 0.424961 / 0.579283 (-0.154322) | 0.428632 / 0.434364 (-0.005732) | 0.502680 / 0.540337 (-0.037658) | 0.597827 / 1.386936 (-0.789109) |\n\n</details>\nPyArrow==latest\n\n<details>\n<summary>Show updated benchmarks!</summary>\n\n### Benchmark: benchmark_array_xd.json\n\n| metric | read_batch_formatted_as_numpy after write_array2d | read_batch_formatted_as_numpy after write_flattened_sequence | read_batch_formatted_as_numpy after write_nested_sequence | read_batch_unformated after write_array2d | read_batch_unformated after write_flattened_sequence | read_batch_unformated after write_nested_sequence | read_col_formatted_as_numpy after write_array2d | read_col_formatted_as_numpy after write_flattened_sequence | read_col_formatted_as_numpy after write_nested_sequence | read_col_unformated after write_array2d | read_col_unformated after write_flattened_sequence | read_col_unformated after write_nested_sequence | read_formatted_as_numpy after write_array2d | read_formatted_as_numpy after write_flattened_sequence | read_formatted_as_numpy after write_nested_sequence | read_unformated after write_array2d | read_unformated after write_flattened_sequence | read_unformated after write_nested_sequence | write_array2d | write_flattened_sequence | write_nested_sequence |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.007749 / 0.011353 (-0.003604) | 0.005527 / 0.011008 (-0.005482) | 0.074774 / 0.038508 (0.036266) | 0.035367 / 0.023109 (0.012258) | 0.340594 / 0.275898 (0.064696) | 0.373970 / 0.323480 (0.050490) | 0.006094 / 0.007986 (-0.001892) | 0.004428 / 0.004328 (0.000100) | 0.074120 / 0.004250 (0.069869) | 0.054852 / 0.037052 (0.017800) | 0.357173 / 0.258489 (0.098684) | 0.388877 / 0.293841 (0.095036) | 0.037002 / 0.128546 (-0.091545) | 0.012337 / 0.075646 (-0.063309) | 0.086962 / 0.419271 (-0.332310) | 0.050370 / 0.043533 (0.006837) | 0.342989 / 0.255139 (0.087850) | 0.358065 / 0.283200 (0.074865) | 0.111063 / 0.141683 (-0.030620) | 1.516704 / 1.452155 (0.064549) | 1.634359 / 1.492716 (0.141643) |\n\n### Benchmark: benchmark_getitem\\_100B.json\n\n| metric | get_batch_of\\_1024\\_random_rows | get_batch_of\\_1024\\_rows | get_first_row | get_last_row |\n|--------|---|---|---|---|\n| new / old (diff) | 0.261493 / 0.018006 (0.243487) | 0.566288 / 0.000490 (0.565799) | 0.000439 / 0.000200 (0.000239) | 0.000056 / 0.000054 (0.000002) |\n\n### Benchmark: benchmark_indices_mapping.json\n\n| metric | select | shard | shuffle | sort | train_test_split |\n|--------|---|---|---|---|---|\n| new / old (diff) | 0.030426 / 0.037411 (-0.006985) | 0.114606 / 0.014526 (0.100080) | 0.126134 / 0.176557 (-0.050423) | 0.175324 / 0.737135 (-0.561812) | 0.132766 / 0.296338 (-0.163573) |\n\n### Benchmark: benchmark_iterating.json\n\n| metric | read 5000 | read 50000 | read_batch 50000 10 | read_batch 50000 100 | read_batch 50000 1000 | read_formatted numpy 5000 | read_formatted pandas 5000 | read_formatted tensorflow 5000 | read_formatted torch 5000 | read_formatted_batch numpy 5000 10 | read_formatted_batch numpy 5000 1000 | shuffled read 5000 | shuffled read 50000 | shuffled read_batch 50000 10 | shuffled read_batch 50000 100 | shuffled read_batch 50000 1000 | shuffled read_formatted numpy 5000 | shuffled read_formatted_batch numpy 5000 10 | shuffled read_formatted_batch numpy 5000 1000 |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.426785 / 0.215209 (0.211576) | 4.243555 / 2.077655 (2.165900) | 2.089631 / 1.504120 (0.585511) | 1.994562 / 1.541195 (0.453367) | 2.140284 / 1.468490 (0.671794) | 0.698645 / 4.584777 (-3.886132) | 3.807471 / 3.745712 (0.061759) | 3.275343 / 5.269862 (-1.994519) | 1.796756 / 4.565676 (-2.768921) | 0.085986 / 0.424275 (-0.338289) | 0.012213 / 0.007607 (0.004606) | 0.536815 / 0.226044 (0.310771) | 5.344611 / 2.268929 (3.075683) | 2.498578 / 55.444624 (-52.946047) | 2.153260 / 6.876477 (-4.723217) | 2.251310 / 2.142072 (0.109237) | 0.839104 / 4.805227 (-3.966123) | 0.169639 / 6.500664 (-6.331025) | 0.065880 / 0.075469 (-0.009589) |\n\n### Benchmark: benchmark_map_filter.json\n\n| metric | filter | map fast-tokenizer batched | map identity | map identity batched | map no-op batched | map no-op batched numpy | map no-op batched pandas | map no-op batched pytorch | map no-op batched tensorflow |\n|--------|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 1.268610 / 1.841788 (-0.573178) | 15.624915 / 8.074308 (7.550606) | 15.163684 / 10.191392 (4.972292) | 0.172992 / 0.680424 (-0.507432) | 0.018154 / 0.534201 (-0.516047) | 0.440485 / 0.579283 (-0.138798) | 0.431949 / 0.434364 (-0.002415) | 0.547935 / 0.540337 (0.007597) | 0.662442 / 1.386936 (-0.724494) |\n\n</details>\n</details>\n\n![](https://cml.dev/watermark.png#5c8a6ba43c4aaa0ca0665d8dadd87ef33e28e8e4 \"CML watermark\")\n" ]
"2023-03-31T19:51:38Z"
"2023-04-03T18:43:30Z"
"2023-04-03T18:29:58Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/5693.diff", "html_url": "https://github.com/huggingface/datasets/pull/5693", "merged_at": "2023-04-03T18:29:58Z", "patch_url": "https://github.com/huggingface/datasets/pull/5693.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/5693" }
This PR addresses #5681 about the order of split patterns 🤗 Datasets searches for when generating dataset splits.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/5693/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5693/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/2594
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/2594/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/2594/comments
https://api.github.com/repos/huggingface/datasets/issues/2594/events
https://github.com/huggingface/datasets/pull/2594
937,294,772
MDExOlB1bGxSZXF1ZXN0NjgzODc0NjIz
2,594
Fix BibTeX entry
{ "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" }
[]
closed
false
null
[]
null
[]
"2021-07-05T18:24:10Z"
"2021-07-06T04:59:38Z"
"2021-07-06T04:59:38Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/2594.diff", "html_url": "https://github.com/huggingface/datasets/pull/2594", "merged_at": "2021-07-06T04:59:38Z", "patch_url": "https://github.com/huggingface/datasets/pull/2594.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/2594" }
Fix BibTeX entry.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/2594/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/2594/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/1610
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/1610/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/1610/comments
https://api.github.com/repos/huggingface/datasets/issues/1610/events
https://github.com/huggingface/datasets/issues/1610
771,453,599
MDU6SXNzdWU3NzE0NTM1OTk=
1,610
shuffle does not accept seed
{ "avatar_url": "https://avatars.githubusercontent.com/u/6278280?v=4", "events_url": "https://api.github.com/users/rabeehk/events{/privacy}", "followers_url": "https://api.github.com/users/rabeehk/followers", "following_url": "https://api.github.com/users/rabeehk/following{/other_user}", "gists_url": "https://api.github.com/users/rabeehk/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/rabeehk", "id": 6278280, "login": "rabeehk", "node_id": "MDQ6VXNlcjYyNzgyODA=", "organizations_url": "https://api.github.com/users/rabeehk/orgs", "received_events_url": "https://api.github.com/users/rabeehk/received_events", "repos_url": "https://api.github.com/users/rabeehk/repos", "site_admin": false, "starred_url": "https://api.github.com/users/rabeehk/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/rabeehk/subscriptions", "type": "User", "url": "https://api.github.com/users/rabeehk" }
[ { "color": "d73a4a", "default": true, "description": "Something isn't working", "id": 1935892857, "name": "bug", "node_id": "MDU6TGFiZWwxOTM1ODkyODU3", "url": "https://api.github.com/repos/huggingface/datasets/labels/bug" } ]
closed
false
null
[]
null
[ "Hi, did you check the doc on `shuffle`?\r\nhttps://huggingface.co/docs/datasets/package_reference/main_classes.html?datasets.Dataset.shuffle#datasets.Dataset.shuffle", "Hi Thomas\r\nthanks for reponse, yes, I did checked it, but this does not work for me please see \r\n\r\n```\r\n(internship) rkarimi@italix17:/idiap/user/rkarimi/dev$ python \r\nPython 3.7.9 (default, Aug 31 2020, 12:42:55) \r\n[GCC 7.3.0] :: Anaconda, Inc. on linux\r\nType \"help\", \"copyright\", \"credits\" or \"license\" for more information.\r\n>>> import datasets \r\n2020-12-20 01:48:50.766004: W tensorflow/stream_executor/platform/default/dso_loader.cc:60] Could not load dynamic library 'libcudart.so.11.0'; dlerror: libcudart.so.11.0: cannot open shared object file: No such file or directory\r\n2020-12-20 01:48:50.766029: I tensorflow/stream_executor/cuda/cudart_stub.cc:29] Ignore above cudart dlerror if you do not have a GPU set up on your machine.\r\n>>> data = datasets.load_dataset(\"scitail\", \"snli_format\")\r\ncahce dir /idiap/temp/rkarimi/cache_home_1/datasets\r\ncahce dir /idiap/temp/rkarimi/cache_home_1/datasets\r\nReusing dataset scitail (/idiap/temp/rkarimi/cache_home_1/datasets/scitail/snli_format/1.1.0/fd8ccdfc3134ce86eb4ef10ba7f21ee2a125c946e26bb1dd3625fe74f48d3b90)\r\n>>> data.shuffle(seed=2)\r\nTraceback (most recent call last):\r\n File \"<stdin>\", line 1, in <module>\r\nTypeError: shuffle() got an unexpected keyword argument 'seed'\r\n\r\n```\r\n\r\ndatasets version\r\n`datasets 1.1.2 <pip>\r\n`\r\n", "Thanks for reporting ! \r\n\r\nIndeed it looks like an issue with `suffle` on `DatasetDict`. We're going to fix that.\r\nIn the meantime you can shuffle each split (train, validation, test) separately:\r\n```python\r\nshuffled_train_dataset = data[\"train\"].shuffle(seed=42)\r\n```\r\n" ]
"2020-12-19T20:59:39Z"
"2021-01-04T10:00:03Z"
"2021-01-04T10:00:03Z"
CONTRIBUTOR
null
null
null
Hi I need to shuffle the dataset, but this needs to be based on epoch+seed to be consistent across the cores, when I pass seed to shuffle, this does not accept seed, could you assist me with this? thanks @lhoestq
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/1610/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/1610/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/4160
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/4160/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/4160/comments
https://api.github.com/repos/huggingface/datasets/issues/4160/events
https://github.com/huggingface/datasets/issues/4160
1,202,845,874
I_kwDODunzps5Hsfiy
4,160
RGBA images not showing
{ "avatar_url": "https://avatars.githubusercontent.com/u/15624271?v=4", "events_url": "https://api.github.com/users/cceyda/events{/privacy}", "followers_url": "https://api.github.com/users/cceyda/followers", "following_url": "https://api.github.com/users/cceyda/following{/other_user}", "gists_url": "https://api.github.com/users/cceyda/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/cceyda", "id": 15624271, "login": "cceyda", "node_id": "MDQ6VXNlcjE1NjI0Mjcx", "organizations_url": "https://api.github.com/users/cceyda/orgs", "received_events_url": "https://api.github.com/users/cceyda/received_events", "repos_url": "https://api.github.com/users/cceyda/repos", "site_admin": false, "starred_url": "https://api.github.com/users/cceyda/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/cceyda/subscriptions", "type": "User", "url": "https://api.github.com/users/cceyda" }
[ { "color": "E5583E", "default": false, "description": "Related to the dataset viewer on huggingface.co", "id": 3470211881, "name": "dataset-viewer", "node_id": "LA_kwDODunzps7O1zsp", "url": "https://api.github.com/repos/huggingface/datasets/labels/dataset-viewer" }, { "color": "6C5FC0", "default": false, "description": "", "id": 4030246674, "name": "dataset-viewer-rgba-images", "node_id": "LA_kwDODunzps7wOK8S", "url": "https://api.github.com/repos/huggingface/datasets/labels/dataset-viewer-rgba-images" } ]
closed
false
{ "avatar_url": "https://avatars.githubusercontent.com/u/1676121?v=4", "events_url": "https://api.github.com/users/severo/events{/privacy}", "followers_url": "https://api.github.com/users/severo/followers", "following_url": "https://api.github.com/users/severo/following{/other_user}", "gists_url": "https://api.github.com/users/severo/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/severo", "id": 1676121, "login": "severo", "node_id": "MDQ6VXNlcjE2NzYxMjE=", "organizations_url": "https://api.github.com/users/severo/orgs", "received_events_url": "https://api.github.com/users/severo/received_events", "repos_url": "https://api.github.com/users/severo/repos", "site_admin": false, "starred_url": "https://api.github.com/users/severo/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/severo/subscriptions", "type": "User", "url": "https://api.github.com/users/severo" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/1676121?v=4", "events_url": "https://api.github.com/users/severo/events{/privacy}", "followers_url": "https://api.github.com/users/severo/followers", "following_url": "https://api.github.com/users/severo/following{/other_user}", "gists_url": "https://api.github.com/users/severo/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/severo", "id": 1676121, "login": "severo", "node_id": "MDQ6VXNlcjE2NzYxMjE=", "organizations_url": "https://api.github.com/users/severo/orgs", "received_events_url": "https://api.github.com/users/severo/received_events", "repos_url": "https://api.github.com/users/severo/repos", "site_admin": false, "starred_url": "https://api.github.com/users/severo/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/severo/subscriptions", "type": "User", "url": "https://api.github.com/users/severo" } ]
null
[ "Thanks for reporting. It's a known issue, and we hope to fix it soon.", "Fixed, thanks!" ]
"2022-04-13T06:59:23Z"
"2022-06-21T16:43:11Z"
"2022-06-21T16:43:11Z"
CONTRIBUTOR
null
null
null
## Dataset viewer issue for ceyda/smithsonian_butterflies_transparent [**Link:** *link to the dataset viewer page*](https://huggingface.co/datasets/ceyda/smithsonian_butterflies_transparent) ![image](https://user-images.githubusercontent.com/15624271/163117683-e91edb28-41bf-43d9-b371-5c62e14f40c9.png) Am I the one who added this dataset ? Yes 👉 More of a general issue of 'RGBA' png images not being supported (the dataset itself is just for the huggan sprint and not that important, consider it just an example)
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/4160/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/4160/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/6247
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/6247/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/6247/comments
https://api.github.com/repos/huggingface/datasets/issues/6247/events
https://github.com/huggingface/datasets/pull/6247
1,901,390,945
PR_kwDODunzps5amAQ1
6,247
Update create_dataset.mdx
{ "avatar_url": "https://avatars.githubusercontent.com/u/76403422?v=4", "events_url": "https://api.github.com/users/EswarDivi/events{/privacy}", "followers_url": "https://api.github.com/users/EswarDivi/followers", "following_url": "https://api.github.com/users/EswarDivi/following{/other_user}", "gists_url": "https://api.github.com/users/EswarDivi/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/EswarDivi", "id": 76403422, "login": "EswarDivi", "node_id": "MDQ6VXNlcjc2NDAzNDIy", "organizations_url": "https://api.github.com/users/EswarDivi/orgs", "received_events_url": "https://api.github.com/users/EswarDivi/received_events", "repos_url": "https://api.github.com/users/EswarDivi/repos", "site_admin": false, "starred_url": "https://api.github.com/users/EswarDivi/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/EswarDivi/subscriptions", "type": "User", "url": "https://api.github.com/users/EswarDivi" }
[]
closed
false
null
[]
null
[ "_The documentation is not available anymore as the PR was closed or merged._", "<details>\n<summary>Show benchmarks</summary>\n\nPyArrow==8.0.0\n\n<details>\n<summary>Show updated benchmarks!</summary>\n\n### Benchmark: benchmark_array_xd.json\n\n| metric | read_batch_formatted_as_numpy after write_array2d | read_batch_formatted_as_numpy after write_flattened_sequence | read_batch_formatted_as_numpy after write_nested_sequence | read_batch_unformated after write_array2d | read_batch_unformated after write_flattened_sequence | read_batch_unformated after write_nested_sequence | read_col_formatted_as_numpy after write_array2d | read_col_formatted_as_numpy after write_flattened_sequence | read_col_formatted_as_numpy after write_nested_sequence | read_col_unformated after write_array2d | read_col_unformated after write_flattened_sequence | read_col_unformated after write_nested_sequence | read_formatted_as_numpy after write_array2d | read_formatted_as_numpy after write_flattened_sequence | read_formatted_as_numpy after write_nested_sequence | read_unformated after write_array2d | read_unformated after write_flattened_sequence | read_unformated after write_nested_sequence | write_array2d | write_flattened_sequence | write_nested_sequence |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.008892 / 0.011353 (-0.002461) | 0.005140 / 0.011008 (-0.005868) | 0.110951 / 0.038508 (0.072442) | 0.086159 / 0.023109 (0.063050) | 0.391117 / 0.275898 (0.115218) | 0.440884 / 0.323480 (0.117404) | 0.006562 / 0.007986 (-0.001423) | 0.003711 / 0.004328 (-0.000618) | 0.081848 / 0.004250 (0.077598) | 0.063187 / 0.037052 (0.026135) | 0.369771 / 0.258489 (0.111282) | 0.447685 / 0.293841 (0.153844) | 0.046623 / 0.128546 (-0.081923) | 0.014024 / 0.075646 (-0.061622) | 0.418556 / 0.419271 (-0.000715) | 0.064660 / 0.043533 (0.021127) | 0.379416 / 0.255139 (0.124277) | 0.415800 / 0.283200 (0.132600) | 0.036899 / 0.141683 (-0.104784) | 1.710280 / 1.452155 (0.258125) | 1.932326 / 1.492716 (0.439610) |\n\n### Benchmark: benchmark_getitem\\_100B.json\n\n| metric | get_batch_of\\_1024\\_random_rows | get_batch_of\\_1024\\_rows | get_first_row | get_last_row |\n|--------|---|---|---|---|\n| new / old (diff) | 0.311351 / 0.018006 (0.293345) | 0.621121 / 0.000490 (0.620631) | 0.013677 / 0.000200 (0.013477) | 0.000543 / 0.000054 (0.000488) |\n\n### Benchmark: benchmark_indices_mapping.json\n\n| metric | select | shard | shuffle | sort | train_test_split |\n|--------|---|---|---|---|---|\n| new / old (diff) | 0.031310 / 0.037411 (-0.006102) | 0.099546 / 0.014526 (0.085020) | 0.122100 / 0.176557 (-0.054457) | 0.186477 / 0.737135 (-0.550659) | 0.116634 / 0.296338 (-0.179704) |\n\n### Benchmark: benchmark_iterating.json\n\n| metric | read 5000 | read 50000 | read_batch 50000 10 | read_batch 50000 100 | read_batch 50000 1000 | read_formatted numpy 5000 | read_formatted pandas 5000 | read_formatted tensorflow 5000 | read_formatted torch 5000 | read_formatted_batch numpy 5000 10 | read_formatted_batch numpy 5000 1000 | shuffled read 5000 | shuffled read 50000 | shuffled read_batch 50000 10 | shuffled read_batch 50000 100 | shuffled read_batch 50000 1000 | shuffled read_formatted numpy 5000 | shuffled read_formatted_batch numpy 5000 10 | shuffled read_formatted_batch numpy 5000 1000 |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.574639 / 0.215209 (0.359430) | 5.976678 / 2.077655 (3.899023) | 2.535482 / 1.504120 (1.031362) | 2.248873 / 1.541195 (0.707678) | 2.361696 / 1.468490 (0.893205) | 0.866700 / 4.584777 (-3.718077) | 5.298018 / 3.745712 (1.552306) | 4.753240 / 5.269862 (-0.516622) | 3.124698 / 4.565676 (-1.440979) | 0.101852 / 0.424275 (-0.322423) | 0.009117 / 0.007607 (0.001510) | 0.723730 / 0.226044 (0.497685) | 7.172649 / 2.268929 (4.903720) | 3.400410 / 55.444624 (-52.044214) | 2.626619 / 6.876477 (-4.249857) | 2.948692 / 2.142072 (0.806620) | 0.991589 / 4.805227 (-3.813638) | 0.208902 / 6.500664 (-6.291762) | 0.076172 / 0.075469 (0.000703) |\n\n### Benchmark: benchmark_map_filter.json\n\n| metric | filter | map fast-tokenizer batched | map identity | map identity batched | map no-op batched | map no-op batched numpy | map no-op batched pandas | map no-op batched pytorch | map no-op batched tensorflow |\n|--------|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 1.621880 / 1.841788 (-0.219907) | 22.735673 / 8.074308 (14.661365) | 20.376990 / 10.191392 (10.185598) | 0.232219 / 0.680424 (-0.448204) | 0.028616 / 0.534201 (-0.505585) | 0.455725 / 0.579283 (-0.123558) | 0.562796 / 0.434364 (0.128432) | 0.545344 / 0.540337 (0.005007) | 0.759440 / 1.386936 (-0.627496) |\n\n</details>\nPyArrow==latest\n\n<details>\n<summary>Show updated benchmarks!</summary>\n\n### Benchmark: benchmark_array_xd.json\n\n| metric | read_batch_formatted_as_numpy after write_array2d | read_batch_formatted_as_numpy after write_flattened_sequence | read_batch_formatted_as_numpy after write_nested_sequence | read_batch_unformated after write_array2d | read_batch_unformated after write_flattened_sequence | read_batch_unformated after write_nested_sequence | read_col_formatted_as_numpy after write_array2d | read_col_formatted_as_numpy after write_flattened_sequence | read_col_formatted_as_numpy after write_nested_sequence | read_col_unformated after write_array2d | read_col_unformated after write_flattened_sequence | read_col_unformated after write_nested_sequence | read_formatted_as_numpy after write_array2d | read_formatted_as_numpy after write_flattened_sequence | read_formatted_as_numpy after write_nested_sequence | read_unformated after write_array2d | read_unformated after write_flattened_sequence | read_unformated after write_nested_sequence | write_array2d | write_flattened_sequence | write_nested_sequence |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.009845 / 0.011353 (-0.001508) | 0.005289 / 0.011008 (-0.005719) | 0.083117 / 0.038508 (0.044609) | 0.098467 / 0.023109 (0.075357) | 0.532345 / 0.275898 (0.256447) | 0.571000 / 0.323480 (0.247520) | 0.007223 / 0.007986 (-0.000763) | 0.004442 / 0.004328 (0.000114) | 0.081710 / 0.004250 (0.077459) | 0.071132 / 0.037052 (0.034080) | 0.540093 / 0.258489 (0.281604) | 0.582244 / 0.293841 (0.288403) | 0.048509 / 0.128546 (-0.080038) | 0.013897 / 0.075646 (-0.061749) | 0.092579 / 0.419271 (-0.326692) | 0.073409 / 0.043533 (0.029876) | 0.537369 / 0.255139 (0.282230) | 0.551403 / 0.283200 (0.268203) | 0.038847 / 0.141683 (-0.102835) | 1.940848 / 1.452155 (0.488693) | 2.045597 / 1.492716 (0.552881) |\n\n### Benchmark: benchmark_getitem\\_100B.json\n\n| metric | get_batch_of\\_1024\\_random_rows | get_batch_of\\_1024\\_rows | get_first_row | get_last_row |\n|--------|---|---|---|---|\n| new / old (diff) | 0.303883 / 0.018006 (0.285877) | 0.600237 / 0.000490 (0.599748) | 0.006030 / 0.000200 (0.005830) | 0.000124 / 0.000054 (0.000070) |\n\n### Benchmark: benchmark_indices_mapping.json\n\n| metric | select | shard | shuffle | sort | train_test_split |\n|--------|---|---|---|---|---|\n| new / old (diff) | 0.036633 / 0.037411 (-0.000778) | 0.105853 / 0.014526 (0.091327) | 0.126289 / 0.176557 (-0.050267) | 0.190022 / 0.737135 (-0.547113) | 0.123251 / 0.296338 (-0.173087) |\n\n### Benchmark: benchmark_iterating.json\n\n| metric | read 5000 | read 50000 | read_batch 50000 10 | read_batch 50000 100 | read_batch 50000 1000 | read_formatted numpy 5000 | read_formatted pandas 5000 | read_formatted tensorflow 5000 | read_formatted torch 5000 | read_formatted_batch numpy 5000 10 | read_formatted_batch numpy 5000 1000 | shuffled read 5000 | shuffled read 50000 | shuffled read_batch 50000 10 | shuffled read_batch 50000 100 | shuffled read_batch 50000 1000 | shuffled read_formatted numpy 5000 | shuffled read_formatted_batch numpy 5000 10 | shuffled read_formatted_batch numpy 5000 1000 |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.711893 / 0.215209 (0.496684) | 6.979781 / 2.077655 (4.902126) | 3.491514 / 1.504120 (1.987394) | 3.268077 / 1.541195 (1.726882) | 3.241777 / 1.468490 (1.773287) | 0.875913 / 4.584777 (-3.708864) | 5.458421 / 3.745712 (1.712709) | 4.818355 / 5.269862 (-0.451507) | 3.256046 / 4.565676 (-1.309631) | 0.095000 / 0.424275 (-0.329275) | 0.009072 / 0.007607 (0.001465) | 0.818468 / 0.226044 (0.592424) | 8.027702 / 2.268929 (5.758773) | 4.363234 / 55.444624 (-51.081390) | 3.695269 / 6.876477 (-3.181207) | 3.902601 / 2.142072 (1.760528) | 1.039007 / 4.805227 (-3.766220) | 0.212050 / 6.500664 (-6.288614) | 0.081438 / 0.075469 (0.005969) |\n\n### Benchmark: benchmark_map_filter.json\n\n| metric | filter | map fast-tokenizer batched | map identity | map identity batched | map no-op batched | map no-op batched numpy | map no-op batched pandas | map no-op batched pytorch | map no-op batched tensorflow |\n|--------|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 1.746945 / 1.841788 (-0.094842) | 25.274283 / 8.074308 (17.199975) | 23.514717 / 10.191392 (13.323325) | 0.232580 / 0.680424 (-0.447843) | 0.032083 / 0.534201 (-0.502118) | 0.482873 / 0.579283 (-0.096410) | 0.585730 / 0.434364 (0.151366) | 0.602066 / 0.540337 (0.061729) | 0.796391 / 1.386936 (-0.590546) |\n\n</details>\n</details>\n\n![](https://cml.dev/watermark.png#0d7cb68fe37dbfd81e5f82e19d8f9847c337788d \"CML watermark\")\n" ]
"2023-09-18T17:06:29Z"
"2023-09-19T18:51:49Z"
"2023-09-19T18:40:10Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/6247.diff", "html_url": "https://github.com/huggingface/datasets/pull/6247", "merged_at": "2023-09-19T18:40:10Z", "patch_url": "https://github.com/huggingface/datasets/pull/6247.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/6247" }
modified , as AudioFolder and ImageFolder not in Dataset Library. ``` from datasets import AudioFolder ``` and ```from datasets import ImageFolder``` to ```from datasets import load_dataset``` ``` cannot import name 'AudioFolder' from 'datasets' (/home/eswardivi/miniconda3/envs/Hugformers/lib/python3.10/site-packages/datasets/__init__.py) ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/6247/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/6247/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/1294
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/1294/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/1294/comments
https://api.github.com/repos/huggingface/datasets/issues/1294/events
https://github.com/huggingface/datasets/pull/1294
759,365,246
MDExOlB1bGxSZXF1ZXN0NTM0MzgzMjg5
1,294
adding opus_euconst
{ "avatar_url": "https://avatars.githubusercontent.com/u/27137566?v=4", "events_url": "https://api.github.com/users/patil-suraj/events{/privacy}", "followers_url": "https://api.github.com/users/patil-suraj/followers", "following_url": "https://api.github.com/users/patil-suraj/following{/other_user}", "gists_url": "https://api.github.com/users/patil-suraj/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/patil-suraj", "id": 27137566, "login": "patil-suraj", "node_id": "MDQ6VXNlcjI3MTM3NTY2", "organizations_url": "https://api.github.com/users/patil-suraj/orgs", "received_events_url": "https://api.github.com/users/patil-suraj/received_events", "repos_url": "https://api.github.com/users/patil-suraj/repos", "site_admin": false, "starred_url": "https://api.github.com/users/patil-suraj/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/patil-suraj/subscriptions", "type": "User", "url": "https://api.github.com/users/patil-suraj" }
[]
closed
false
null
[]
null
[]
"2020-12-08T11:24:16Z"
"2020-12-08T18:44:20Z"
"2020-12-08T18:41:23Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/1294.diff", "html_url": "https://github.com/huggingface/datasets/pull/1294", "merged_at": "2020-12-08T18:41:22Z", "patch_url": "https://github.com/huggingface/datasets/pull/1294.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/1294" }
Adding EUconst, a parallel corpus collected from the European Constitution. 21 languages, 210 bitexts
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/1294/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/1294/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/2823
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/2823/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/2823/comments
https://api.github.com/repos/huggingface/datasets/issues/2823/events
https://github.com/huggingface/datasets/issues/2823
976,135,355
MDU6SXNzdWU5NzYxMzUzNTU=
2,823
HF_DATASETS_CACHE variable in Windows
{ "avatar_url": "https://avatars.githubusercontent.com/u/8453798?v=4", "events_url": "https://api.github.com/users/rp2839/events{/privacy}", "followers_url": "https://api.github.com/users/rp2839/followers", "following_url": "https://api.github.com/users/rp2839/following{/other_user}", "gists_url": "https://api.github.com/users/rp2839/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/rp2839", "id": 8453798, "login": "rp2839", "node_id": "MDQ6VXNlcjg0NTM3OTg=", "organizations_url": "https://api.github.com/users/rp2839/orgs", "received_events_url": "https://api.github.com/users/rp2839/received_events", "repos_url": "https://api.github.com/users/rp2839/repos", "site_admin": false, "starred_url": "https://api.github.com/users/rp2839/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/rp2839/subscriptions", "type": "User", "url": "https://api.github.com/users/rp2839" }
[]
closed
false
null
[]
null
[ "Agh - I'm a muppet. No quote marks are needed.\r\nset HF_DATASETS_CACHE = C:\\Datasets\r\nworks as intended." ]
"2021-08-21T13:17:44Z"
"2021-08-21T13:20:11Z"
"2021-08-21T13:20:11Z"
NONE
null
null
null
I can't seem to use a custom Cache directory in Windows. I have tried: set HF_DATASETS_CACHE = "C:\Datasets" set HF_DATASETS_CACHE = "C:/Datasets" set HF_DATASETS_CACHE = "C:\\Datasets" set HF_DATASETS_CACHE = "r'C:\Datasets'" set HF_DATASETS_CACHE = "\Datasets" set HF_DATASETS_CACHE = "/Datasets" In each instance I get the "[WinError 123] The filename, directory name, or volume label syntax is incorrect" error when attempting to load a dataset
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/2823/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/2823/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/4660
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/4660/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/4660/comments
https://api.github.com/repos/huggingface/datasets/issues/4660/events
https://github.com/huggingface/datasets/pull/4660
1,297,128,387
PR_kwDODunzps47AYDq
4,660
Fix _resolve_single_pattern_locally on Windows with multiple drives
{ "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" }
[]
closed
false
null
[]
null
[ "_The documentation is not available anymore as the PR was closed or merged._", "Good catch ! Sorry I forgot (again) about windows paths when writing this x)" ]
"2022-07-07T09:57:30Z"
"2022-07-07T17:03:36Z"
"2022-07-07T16:52:07Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/4660.diff", "html_url": "https://github.com/huggingface/datasets/pull/4660", "merged_at": "2022-07-07T16:52:07Z", "patch_url": "https://github.com/huggingface/datasets/pull/4660.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/4660" }
Currently, when `_resolve_single_pattern_locally` is called from a different drive than the one in `pattern`, it raises an exception: ``` _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ C:\hostedtoolcache\windows\Python\3.6.8\x64\lib\site-packages\datasets\io\parquet.py:35: in __init__ **kwargs, C:\hostedtoolcache\windows\Python\3.6.8\x64\lib\site-packages\datasets\builder.py:287: in __init__ sanitize_patterns(data_files), base_path=base_path, use_auth_token=use_auth_token C:\hostedtoolcache\windows\Python\3.6.8\x64\lib\site-packages\datasets\data_files.py:761: in from_local_or_remote if not isinstance(patterns_for_key, DataFilesList) C:\hostedtoolcache\windows\Python\3.6.8\x64\lib\site-packages\datasets\data_files.py:723: in from_local_or_remote data_files = resolve_patterns_locally_or_by_urls(base_path, patterns, allowed_extensions) C:\hostedtoolcache\windows\Python\3.6.8\x64\lib\site-packages\datasets\data_files.py:321: in resolve_patterns_locally_or_by_urls for path in _resolve_single_pattern_locally(base_path, pattern, allowed_extensions): C:\hostedtoolcache\windows\Python\3.6.8\x64\lib\site-packages\datasets\data_files.py:239: in _resolve_single_pattern_locally for filepath in glob_iter C:\hostedtoolcache\windows\Python\3.6.8\x64\lib\site-packages\datasets\data_files.py:242: in <listcomp> os.path.relpath(filepath, base_path), os.path.relpath(pattern, base_path) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ path = 'C:\\Users\\runneradmin\\AppData\\Local\\Temp\\pytest-of-runneradmin\\pytest-0\\popen-gw0\\data6\\dataset.parquet' start = '/' ... E ValueError: path is on mount 'C:', start on mount 'D:' ``` This PR makes sure that `base_path` is in the same drive as `pattern`.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/4660/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/4660/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/5506
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5506/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5506/comments
https://api.github.com/repos/huggingface/datasets/issues/5506/events
https://github.com/huggingface/datasets/issues/5506
1,571,838,641
I_kwDODunzps5dsFqx
5,506
IterableDataset and Dataset return different batch sizes when using Trainer with multiple GPUs
{ "avatar_url": "https://avatars.githubusercontent.com/u/38166299?v=4", "events_url": "https://api.github.com/users/kheyer/events{/privacy}", "followers_url": "https://api.github.com/users/kheyer/followers", "following_url": "https://api.github.com/users/kheyer/following{/other_user}", "gists_url": "https://api.github.com/users/kheyer/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kheyer", "id": 38166299, "login": "kheyer", "node_id": "MDQ6VXNlcjM4MTY2Mjk5", "organizations_url": "https://api.github.com/users/kheyer/orgs", "received_events_url": "https://api.github.com/users/kheyer/received_events", "repos_url": "https://api.github.com/users/kheyer/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kheyer/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kheyer/subscriptions", "type": "User", "url": "https://api.github.com/users/kheyer" }
[]
closed
false
null
[]
null
[ "Hi ! `datasets` doesn't do batching - the PyTorch DataLoader does and is created by the `Trainer`. Do you pass other arguments to training_args with respect to data loading ?\r\n\r\nAlso we recently released `.to_iterable_dataset` that does pretty much what you implemented, but using contiguous shards to get a better speed:\r\n```python\r\nif use_iterable_dataset:\r\n num_shards = 100\r\n dataset = dataset.to_iterable_dataset(num_shards=num_shards)\r\n```", "This is the full set of training args passed. No training args were changed when switching dataset types.\r\n\r\n```python\r\ntraining_args = TrainingArguments(\r\n output_dir=\"./checkpoints\",\r\n overwrite_output_dir=True,\r\n num_train_epochs=1,\r\n per_device_train_batch_size=256,\r\n save_steps=2000,\r\n save_total_limit=4,\r\n prediction_loss_only=True,\r\n report_to='none',\r\n gradient_accumulation_steps=6,\r\n fp16=True,\r\n max_steps=60000,\r\n lr_scheduler_type='linear',\r\n warmup_ratio=0.1,\r\n logging_steps=100,\r\n weight_decay=0.01,\r\n adam_beta1=0.9,\r\n adam_beta2=0.98,\r\n adam_epsilon=1e-6,\r\n learning_rate=1e-4\r\n)\r\n```", "I think the issue comes from `transformers`: https://github.com/huggingface/transformers/issues/21444", "Makes sense. Given that it's a `transformers` issue and already being tracked, I'll close this out." ]
"2023-02-06T03:26:03Z"
"2023-02-08T18:30:08Z"
"2023-02-08T18:30:07Z"
NONE
null
null
null
### Describe the bug I am training a Roberta model using 2 GPUs and the `Trainer` API with a batch size of 256. Initially I used a standard `Dataset`, but had issues with slow data loading. After reading [this issue](https://github.com/huggingface/datasets/issues/2252), I swapped to loading my dataset as contiguous shards and passing those to an `IterableDataset`. I observed an unexpected drop in GPU memory utilization, and found the batch size returned from the model had been cut in half. When using `Trainer` with 2 GPUs and a batch size of 256, `Dataset` returns a batch of size 512 (256 per GPU), while `IterableDataset` returns a batch size of 256 (256 total). My guess is `IterableDataset` isn't accounting for multiple cards. ### Steps to reproduce the bug ```python import datasets from datasets import IterableDataset from transformers import RobertaConfig from transformers import RobertaTokenizerFast from transformers import RobertaForMaskedLM from transformers import DataCollatorForLanguageModeling from transformers import Trainer, TrainingArguments use_iterable_dataset = True def gen_from_shards(shards): for shard in shards: for example in shard: yield example dataset = datasets.load_from_disk('my_dataset.hf') if use_iterable_dataset: n_shards = 100 shards = [dataset.shard(num_shards=n_shards, index=i) for i in range(n_shards)] dataset = IterableDataset.from_generator(gen_from_shards, gen_kwargs={"shards": shards}) tokenizer = RobertaTokenizerFast.from_pretrained("./my_tokenizer", max_len=160, use_fast=True) config = RobertaConfig( vocab_size=8248, max_position_embeddings=256, num_attention_heads=8, num_hidden_layers=6, type_vocab_size=1) model = RobertaForMaskedLM(config=config) data_collator = DataCollatorForLanguageModeling(tokenizer=tokenizer, mlm=True, mlm_probability=0.15) training_args = TrainingArguments( per_device_train_batch_size=256 # other args removed for brevity ) trainer = Trainer( model=model, args=training_args, data_collator=data_collator, train_dataset=dataset, ) trainer.train() ``` ### Expected behavior Expected `Dataset` and `IterableDataset` to have the same batch size behavior. If the current behavior is intentional, the batch size printout at the start of training should be updated. Currently, both dataset classes result in `Trainer` printing the same total batch size, even though the batch size sent to the GPUs are different. ### Environment info datasets 2.7.1 transformers 4.25.1
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/5506/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5506/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/1576
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/1576/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/1576/comments
https://api.github.com/repos/huggingface/datasets/issues/1576/events
https://github.com/huggingface/datasets/pull/1576
767,080,645
MDExOlB1bGxSZXF1ZXN0NTM5OTE3MTA0
1,576
Remove the contributors section
{ "avatar_url": "https://avatars.githubusercontent.com/u/821155?v=4", "events_url": "https://api.github.com/users/clmnt/events{/privacy}", "followers_url": "https://api.github.com/users/clmnt/followers", "following_url": "https://api.github.com/users/clmnt/following{/other_user}", "gists_url": "https://api.github.com/users/clmnt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/clmnt", "id": 821155, "login": "clmnt", "node_id": "MDQ6VXNlcjgyMTE1NQ==", "organizations_url": "https://api.github.com/users/clmnt/orgs", "received_events_url": "https://api.github.com/users/clmnt/received_events", "repos_url": "https://api.github.com/users/clmnt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/clmnt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/clmnt/subscriptions", "type": "User", "url": "https://api.github.com/users/clmnt" }
[]
closed
false
null
[]
null
[]
"2020-12-15T01:47:15Z"
"2020-12-15T12:53:47Z"
"2020-12-15T12:53:46Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/1576.diff", "html_url": "https://github.com/huggingface/datasets/pull/1576", "merged_at": "2020-12-15T12:53:46Z", "patch_url": "https://github.com/huggingface/datasets/pull/1576.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/1576" }
sourcerer is down
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/1576/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/1576/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/1967
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/1967/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/1967/comments
https://api.github.com/repos/huggingface/datasets/issues/1967/events
https://github.com/huggingface/datasets/pull/1967
819,129,568
MDExOlB1bGxSZXF1ZXN0NTgyMjc5OTEx
1,967
Add Turkish News Category Dataset - 270K - Lite Version
{ "avatar_url": "https://avatars.githubusercontent.com/u/5150963?v=4", "events_url": "https://api.github.com/users/yavuzKomecoglu/events{/privacy}", "followers_url": "https://api.github.com/users/yavuzKomecoglu/followers", "following_url": "https://api.github.com/users/yavuzKomecoglu/following{/other_user}", "gists_url": "https://api.github.com/users/yavuzKomecoglu/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/yavuzKomecoglu", "id": 5150963, "login": "yavuzKomecoglu", "node_id": "MDQ6VXNlcjUxNTA5NjM=", "organizations_url": "https://api.github.com/users/yavuzKomecoglu/orgs", "received_events_url": "https://api.github.com/users/yavuzKomecoglu/received_events", "repos_url": "https://api.github.com/users/yavuzKomecoglu/repos", "site_admin": false, "starred_url": "https://api.github.com/users/yavuzKomecoglu/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/yavuzKomecoglu/subscriptions", "type": "User", "url": "https://api.github.com/users/yavuzKomecoglu" }
[]
closed
false
null
[]
null
[ "Thanks for the change, merging now !" ]
"2021-03-01T18:21:59Z"
"2021-03-02T17:25:00Z"
"2021-03-02T17:25:00Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/1967.diff", "html_url": "https://github.com/huggingface/datasets/pull/1967", "merged_at": "2021-03-02T17:25:00Z", "patch_url": "https://github.com/huggingface/datasets/pull/1967.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/1967" }
This PR adds the Turkish News Categories Dataset (270K - Lite Version) dataset which is a text classification dataset by me, @basakbuluz and @serdarakyol. This dataset contains the same news from the current [interpress_news_category_tr dataset](https://huggingface.co/datasets/interpress_news_category_tr) but contains less information, OCR errors are reduced, can be easily separated, and can be divided into 10 classes ("kültürsanat", "ekonomi", "siyaset", "eğitim", "dünya", "spor", "teknoloji", "magazin", "sağlık", "gündem") were rearranged.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/1967/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/1967/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/1888
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/1888/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/1888/comments
https://api.github.com/repos/huggingface/datasets/issues/1888/events
https://github.com/huggingface/datasets/pull/1888
809,241,123
MDExOlB1bGxSZXF1ZXN0NTc0MTM2MDU4
1,888
Docs for adding new column on formatted dataset
{ "avatar_url": "https://avatars.githubusercontent.com/u/42851186?v=4", "events_url": "https://api.github.com/users/lhoestq/events{/privacy}", "followers_url": "https://api.github.com/users/lhoestq/followers", "following_url": "https://api.github.com/users/lhoestq/following{/other_user}", "gists_url": "https://api.github.com/users/lhoestq/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/lhoestq", "id": 42851186, "login": "lhoestq", "node_id": "MDQ6VXNlcjQyODUxMTg2", "organizations_url": "https://api.github.com/users/lhoestq/orgs", "received_events_url": "https://api.github.com/users/lhoestq/received_events", "repos_url": "https://api.github.com/users/lhoestq/repos", "site_admin": false, "starred_url": "https://api.github.com/users/lhoestq/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/lhoestq/subscriptions", "type": "User", "url": "https://api.github.com/users/lhoestq" }
[]
closed
false
null
[]
null
[ "Close #1872" ]
"2021-02-16T11:45:00Z"
"2021-03-30T14:01:03Z"
"2021-02-16T11:58:57Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/1888.diff", "html_url": "https://github.com/huggingface/datasets/pull/1888", "merged_at": "2021-02-16T11:58:57Z", "patch_url": "https://github.com/huggingface/datasets/pull/1888.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/1888" }
As mentioned in #1872 we should add in the documentation how the format gets updated when new columns are added Close #1872
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/1888/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/1888/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/5550
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5550/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5550/comments
https://api.github.com/repos/huggingface/datasets/issues/5550/events
https://github.com/huggingface/datasets/pull/5550
1,591,409,475
PR_kwDODunzps5KUl5i
5,550
Resolve four broken refs in the docs
{ "avatar_url": "https://avatars.githubusercontent.com/u/37621491?v=4", "events_url": "https://api.github.com/users/tomaarsen/events{/privacy}", "followers_url": "https://api.github.com/users/tomaarsen/followers", "following_url": "https://api.github.com/users/tomaarsen/following{/other_user}", "gists_url": "https://api.github.com/users/tomaarsen/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/tomaarsen", "id": 37621491, "login": "tomaarsen", "node_id": "MDQ6VXNlcjM3NjIxNDkx", "organizations_url": "https://api.github.com/users/tomaarsen/orgs", "received_events_url": "https://api.github.com/users/tomaarsen/received_events", "repos_url": "https://api.github.com/users/tomaarsen/repos", "site_admin": false, "starred_url": "https://api.github.com/users/tomaarsen/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tomaarsen/subscriptions", "type": "User", "url": "https://api.github.com/users/tomaarsen" }
[]
closed
false
null
[]
null
[ "_The documentation is not available anymore as the PR was closed or merged._", "See the resolved changes [here](https://moon-ci-docs.huggingface.co/docs/datasets/pr_5550/en/package_reference/main_classes#datasets.Dataset.class_encode_column), [here](https://moon-ci-docs.huggingface.co/docs/datasets/pr_5550/en/package_reference/main_classes#datasets.Dataset.unique) and [here](https://moon-ci-docs.huggingface.co/docs/datasets/pr_5550/en/package_reference/main_classes#datasets.DatasetDict.class_encode_column), respectively", "<details>\n<summary>Show benchmarks</summary>\n\nPyArrow==6.0.0\n\n<details>\n<summary>Show updated benchmarks!</summary>\n\n### Benchmark: benchmark_array_xd.json\n\n| metric | read_batch_formatted_as_numpy after write_array2d | read_batch_formatted_as_numpy after write_flattened_sequence | read_batch_formatted_as_numpy after write_nested_sequence | read_batch_unformated after write_array2d | read_batch_unformated after write_flattened_sequence | read_batch_unformated after write_nested_sequence | read_col_formatted_as_numpy after write_array2d | read_col_formatted_as_numpy after write_flattened_sequence | read_col_formatted_as_numpy after write_nested_sequence | read_col_unformated after write_array2d | read_col_unformated after write_flattened_sequence | read_col_unformated after write_nested_sequence | read_formatted_as_numpy after write_array2d | read_formatted_as_numpy after write_flattened_sequence | read_formatted_as_numpy after write_nested_sequence | read_unformated after write_array2d | read_unformated after write_flattened_sequence | read_unformated after write_nested_sequence | write_array2d | write_flattened_sequence | write_nested_sequence |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.008256 / 0.011353 (-0.003097) | 0.004400 / 0.011008 (-0.006608) | 0.098676 / 0.038508 (0.060168) | 0.028937 / 0.023109 (0.005828) | 0.302578 / 0.275898 (0.026680) | 0.334170 / 0.323480 (0.010690) | 0.006657 / 0.007986 (-0.001329) | 0.004581 / 0.004328 (0.000253) | 0.076874 / 0.004250 (0.072624) | 0.034401 / 0.037052 (-0.002652) | 0.303928 / 0.258489 (0.045439) | 0.348421 / 0.293841 (0.054580) | 0.033303 / 0.128546 (-0.095243) | 0.011445 / 0.075646 (-0.064202) | 0.322137 / 0.419271 (-0.097135) | 0.041072 / 0.043533 (-0.002461) | 0.306007 / 0.255139 (0.050868) | 0.325945 / 0.283200 (0.042745) | 0.086685 / 0.141683 (-0.054998) | 1.454956 / 1.452155 (0.002801) | 1.545525 / 1.492716 (0.052809) |\n\n### Benchmark: benchmark_getitem\\_100B.json\n\n| metric | get_batch_of\\_1024\\_random_rows | get_batch_of\\_1024\\_rows | get_first_row | get_last_row |\n|--------|---|---|---|---|\n| new / old (diff) | 0.175536 / 0.018006 (0.157530) | 0.400203 / 0.000490 (0.399713) | 0.002103 / 0.000200 (0.001903) | 0.000072 / 0.000054 (0.000018) |\n\n### Benchmark: benchmark_indices_mapping.json\n\n| metric | select | shard | shuffle | sort | train_test_split |\n|--------|---|---|---|---|---|\n| new / old (diff) | 0.022750 / 0.037411 (-0.014661) | 0.095163 / 0.014526 (0.080637) | 0.103995 / 0.176557 (-0.072561) | 0.138806 / 0.737135 (-0.598330) | 0.105711 / 0.296338 (-0.190628) |\n\n### Benchmark: benchmark_iterating.json\n\n| metric | read 5000 | read 50000 | read_batch 50000 10 | read_batch 50000 100 | read_batch 50000 1000 | read_formatted numpy 5000 | read_formatted pandas 5000 | read_formatted tensorflow 5000 | read_formatted torch 5000 | read_formatted_batch numpy 5000 10 | read_formatted_batch numpy 5000 1000 | shuffled read 5000 | shuffled read 50000 | shuffled read_batch 50000 10 | shuffled read_batch 50000 100 | shuffled read_batch 50000 1000 | shuffled read_formatted numpy 5000 | shuffled read_formatted_batch numpy 5000 10 | shuffled read_formatted_batch numpy 5000 1000 |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.427860 / 0.215209 (0.212651) | 4.259594 / 2.077655 (2.181940) | 2.157986 / 1.504120 (0.653866) | 1.913814 / 1.541195 (0.372619) | 1.793455 / 1.468490 (0.324965) | 0.702341 / 4.584777 (-3.882436) | 3.353086 / 3.745712 (-0.392626) | 1.856952 / 5.269862 (-3.412909) | 1.149963 / 4.565676 (-3.415713) | 0.082926 / 0.424275 (-0.341349) | 0.012307 / 0.007607 (0.004700) | 0.524531 / 0.226044 (0.298487) | 5.254766 / 2.268929 (2.985838) | 2.590157 / 55.444624 (-52.854468) | 2.272613 / 6.876477 (-4.603864) | 2.304367 / 2.142072 (0.162294) | 0.819298 / 4.805227 (-3.985929) | 0.152170 / 6.500664 (-6.348494) | 0.066563 / 0.075469 (-0.008906) |\n\n### Benchmark: benchmark_map_filter.json\n\n| metric | filter | map fast-tokenizer batched | map identity | map identity batched | map no-op batched | map no-op batched numpy | map no-op batched pandas | map no-op batched pytorch | map no-op batched tensorflow |\n|--------|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 1.205054 / 1.841788 (-0.636733) | 13.729073 / 8.074308 (5.654765) | 14.061037 / 10.191392 (3.869645) | 0.138020 / 0.680424 (-0.542404) | 0.028042 / 0.534201 (-0.506159) | 0.392260 / 0.579283 (-0.187024) | 0.405632 / 0.434364 (-0.028732) | 0.469583 / 0.540337 (-0.070755) | 0.563110 / 1.386936 (-0.823826) |\n\n</details>\nPyArrow==latest\n\n<details>\n<summary>Show updated benchmarks!</summary>\n\n### Benchmark: benchmark_array_xd.json\n\n| metric | read_batch_formatted_as_numpy after write_array2d | read_batch_formatted_as_numpy after write_flattened_sequence | read_batch_formatted_as_numpy after write_nested_sequence | read_batch_unformated after write_array2d | read_batch_unformated after write_flattened_sequence | read_batch_unformated after write_nested_sequence | read_col_formatted_as_numpy after write_array2d | read_col_formatted_as_numpy after write_flattened_sequence | read_col_formatted_as_numpy after write_nested_sequence | read_col_unformated after write_array2d | read_col_unformated after write_flattened_sequence | read_col_unformated after write_nested_sequence | read_formatted_as_numpy after write_array2d | read_formatted_as_numpy after write_flattened_sequence | read_formatted_as_numpy after write_nested_sequence | read_unformated after write_array2d | read_unformated after write_flattened_sequence | read_unformated after write_nested_sequence | write_array2d | write_flattened_sequence | write_nested_sequence |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.006513 / 0.011353 (-0.004839) | 0.004402 / 0.011008 (-0.006606) | 0.076339 / 0.038508 (0.037831) | 0.027222 / 0.023109 (0.004112) | 0.338968 / 0.275898 (0.063070) | 0.378475 / 0.323480 (0.054995) | 0.005443 / 0.007986 (-0.002542) | 0.003312 / 0.004328 (-0.001016) | 0.075352 / 0.004250 (0.071102) | 0.034951 / 0.037052 (-0.002102) | 0.342268 / 0.258489 (0.083779) | 0.381024 / 0.293841 (0.087183) | 0.031568 / 0.128546 (-0.096979) | 0.011558 / 0.075646 (-0.064088) | 0.085267 / 0.419271 (-0.334005) | 0.041248 / 0.043533 (-0.002284) | 0.340422 / 0.255139 (0.085283) | 0.365497 / 0.283200 (0.082297) | 0.088278 / 0.141683 (-0.053405) | 1.479838 / 1.452155 (0.027683) | 1.554440 / 1.492716 (0.061724) |\n\n### Benchmark: benchmark_getitem\\_100B.json\n\n| metric | get_batch_of\\_1024\\_random_rows | get_batch_of\\_1024\\_rows | get_first_row | get_last_row |\n|--------|---|---|---|---|\n| new / old (diff) | 0.223240 / 0.018006 (0.205234) | 0.394771 / 0.000490 (0.394282) | 0.003022 / 0.000200 (0.002822) | 0.000071 / 0.000054 (0.000016) |\n\n### Benchmark: benchmark_indices_mapping.json\n\n| metric | select | shard | shuffle | sort | train_test_split |\n|--------|---|---|---|---|---|\n| new / old (diff) | 0.024842 / 0.037411 (-0.012570) | 0.099167 / 0.014526 (0.084641) | 0.106376 / 0.176557 (-0.070180) | 0.141397 / 0.737135 (-0.595738) | 0.110355 / 0.296338 (-0.185983) |\n\n### Benchmark: benchmark_iterating.json\n\n| metric | read 5000 | read 50000 | read_batch 50000 10 | read_batch 50000 100 | read_batch 50000 1000 | read_formatted numpy 5000 | read_formatted pandas 5000 | read_formatted tensorflow 5000 | read_formatted torch 5000 | read_formatted_batch numpy 5000 10 | read_formatted_batch numpy 5000 1000 | shuffled read 5000 | shuffled read 50000 | shuffled read_batch 50000 10 | shuffled read_batch 50000 100 | shuffled read_batch 50000 1000 | shuffled read_formatted numpy 5000 | shuffled read_formatted_batch numpy 5000 10 | shuffled read_formatted_batch numpy 5000 1000 |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.437598 / 0.215209 (0.222389) | 4.394964 / 2.077655 (2.317310) | 2.082660 / 1.504120 (0.578540) | 1.868690 / 1.541195 (0.327496) | 1.915190 / 1.468490 (0.446700) | 0.701035 / 4.584777 (-3.883742) | 3.306594 / 3.745712 (-0.439118) | 1.842681 / 5.269862 (-3.427181) | 1.155022 / 4.565676 (-3.410654) | 0.083310 / 0.424275 (-0.340965) | 0.012413 / 0.007607 (0.004806) | 0.543179 / 0.226044 (0.317135) | 5.445605 / 2.268929 (3.176676) | 2.545080 / 55.444624 (-52.899544) | 2.188741 / 6.876477 (-4.687736) | 2.205561 / 2.142072 (0.063489) | 0.804967 / 4.805227 (-4.000261) | 0.151024 / 6.500664 (-6.349640) | 0.066448 / 0.075469 (-0.009021) |\n\n### Benchmark: benchmark_map_filter.json\n\n| metric | filter | map fast-tokenizer batched | map identity | map identity batched | map no-op batched | map no-op batched numpy | map no-op batched pandas | map no-op batched pytorch | map no-op batched tensorflow |\n|--------|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 1.304671 / 1.841788 (-0.537117) | 13.996631 / 8.074308 (5.922323) | 13.617626 / 10.191392 (3.426234) | 0.141512 / 0.680424 (-0.538912) | 0.016527 / 0.534201 (-0.517674) | 0.384981 / 0.579283 (-0.194302) | 0.385198 / 0.434364 (-0.049166) | 0.469033 / 0.540337 (-0.071305) | 0.554738 / 1.386936 (-0.832198) |\n\n</details>\n</details>\n\n![](https://cml.dev/watermark.png#d09dc897e153fed7c7f459a122fb03faa46688ed \"CML watermark\")\n" ]
"2023-02-20T08:52:11Z"
"2023-02-20T15:16:13Z"
"2023-02-20T15:09:13Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/5550.diff", "html_url": "https://github.com/huggingface/datasets/pull/5550", "merged_at": "2023-02-20T15:09:13Z", "patch_url": "https://github.com/huggingface/datasets/pull/5550.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/5550" }
Hello! ## Pull Request overview * Resolve 4 broken references in the docs ## The problems Two broken references [here](https://huggingface.co/docs/datasets/package_reference/main_classes#datasets.Dataset.class_encode_column): ![image](https://user-images.githubusercontent.com/37621491/220056232-366b64dc-33c9-461b-8f82-1ac4aa570280.png) --- One broken reference [here](https://huggingface.co/docs/datasets/package_reference/main_classes#datasets.Dataset.unique): ![image](https://user-images.githubusercontent.com/37621491/220057135-2f249d60-c01d-48b5-82bb-5085a7635198.png) --- One missing reference [here](https://huggingface.co/docs/datasets/v2.9.0/en/package_reference/main_classes#datasets.DatasetDict.class_encode_column): ![image](https://user-images.githubusercontent.com/37621491/220057025-4a8e5556-5041-4ec7-b8d8-ed4fdc266495.png) - Tom Aarsen
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/5550/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5550/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/5051
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5051/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5051/comments
https://api.github.com/repos/huggingface/datasets/issues/5051/events
https://github.com/huggingface/datasets/pull/5051
1,392,559,503
PR_kwDODunzps4_8drw
5,051
Revert task removal in folder-based builders
{ "avatar_url": "https://avatars.githubusercontent.com/u/47462742?v=4", "events_url": "https://api.github.com/users/mariosasko/events{/privacy}", "followers_url": "https://api.github.com/users/mariosasko/followers", "following_url": "https://api.github.com/users/mariosasko/following{/other_user}", "gists_url": "https://api.github.com/users/mariosasko/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mariosasko", "id": 47462742, "login": "mariosasko", "node_id": "MDQ6VXNlcjQ3NDYyNzQy", "organizations_url": "https://api.github.com/users/mariosasko/orgs", "received_events_url": "https://api.github.com/users/mariosasko/received_events", "repos_url": "https://api.github.com/users/mariosasko/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mariosasko/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mariosasko/subscriptions", "type": "User", "url": "https://api.github.com/users/mariosasko" }
[]
closed
false
null
[]
null
[ "_The documentation is not available anymore as the PR was closed or merged._" ]
"2022-09-30T14:50:03Z"
"2022-10-03T12:23:35Z"
"2022-10-03T12:21:31Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/5051.diff", "html_url": "https://github.com/huggingface/datasets/pull/5051", "merged_at": "2022-10-03T12:21:31Z", "patch_url": "https://github.com/huggingface/datasets/pull/5051.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/5051" }
Reverts the removal of `task_templates` in the folder-based builders. I also added the `AudioClassifaction` task for consistency. This is needed to fix https://github.com/huggingface/transformers/issues/19177. I think we should soon deprecate and remove the current task API (and investigate if it's possible to integrate the `train eval index` API), but we need to update the Transformers examples before that so we don't break them. cc @NielsRogge
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/5051/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5051/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/1750
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/1750/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/1750/comments
https://api.github.com/repos/huggingface/datasets/issues/1750/events
https://github.com/huggingface/datasets/pull/1750
788,668,085
MDExOlB1bGxSZXF1ZXN0NTU3MTM1MzM1
1,750
Fix typo in README.md of cnn_dailymail
{ "avatar_url": "https://avatars.githubusercontent.com/u/2755894?v=4", "events_url": "https://api.github.com/users/forest1988/events{/privacy}", "followers_url": "https://api.github.com/users/forest1988/followers", "following_url": "https://api.github.com/users/forest1988/following{/other_user}", "gists_url": "https://api.github.com/users/forest1988/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/forest1988", "id": 2755894, "login": "forest1988", "node_id": "MDQ6VXNlcjI3NTU4OTQ=", "organizations_url": "https://api.github.com/users/forest1988/orgs", "received_events_url": "https://api.github.com/users/forest1988/received_events", "repos_url": "https://api.github.com/users/forest1988/repos", "site_admin": false, "starred_url": "https://api.github.com/users/forest1988/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/forest1988/subscriptions", "type": "User", "url": "https://api.github.com/users/forest1988" }
[]
closed
false
null
[]
null
[ "Good catch, thanks!", "Thank you for merging!" ]
"2021-01-19T03:06:05Z"
"2021-01-19T11:07:29Z"
"2021-01-19T09:48:43Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/1750.diff", "html_url": "https://github.com/huggingface/datasets/pull/1750", "merged_at": "2021-01-19T09:48:43Z", "patch_url": "https://github.com/huggingface/datasets/pull/1750.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/1750" }
When I read the README.md of `CNN/DailyMail Dataset`, there seems to be a typo `CCN`. I am afraid this is a trivial matter, but I would like to make a suggestion for revision.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/1750/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/1750/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/2572
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/2572/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/2572/comments
https://api.github.com/repos/huggingface/datasets/issues/2572/events
https://github.com/huggingface/datasets/issues/2572
934,573,767
MDU6SXNzdWU5MzQ1NzM3Njc=
2,572
Support Zstandard compressed files
{ "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" }
[ { "color": "a2eeef", "default": true, "description": "New feature or request", "id": 1935892871, "name": "enhancement", "node_id": "MDU6TGFiZWwxOTM1ODkyODcx", "url": "https://api.github.com/repos/huggingface/datasets/labels/enhancement" } ]
closed
false
{ "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" } ]
null
[ "I am trying to load a dataset using Hugging Face Datasets load_dataset method. I am getting the value error as show below. Can someone help with this? I am using Windows laptop and Google Colab notebook.\r\n\r\n```\r\n!pip install zstandard\r\nfrom datasets import load_dataset\r\n\r\nlds = load_dataset(\r\n \"json\",\r\n data_files=\"https://the-eye.eu/public/AI/pile_preliminary_components/FreeLaw_Opinions.jsonl.zst\",\r\n split=\"train\",\r\n streaming=True,\r\n)\r\n\r\nWARNING:datasets.builder:Using custom data configuration default-a1d9e8eaedd958cd\r\n---------------------------------------------------------------------------\r\nValueError Traceback (most recent call last)\r\n[<ipython-input-12-5b4fdcb8e6d5>](https://localhost:8080/#) in <module>\r\n 6 )\r\n 7 \r\n----> 8 next(iter(law_dataset_streamed))\r\n\r\n17 frames\r\n[/usr/local/lib/python3.8/dist-packages/fsspec/core.py](https://localhost:8080/#) in get_compression(urlpath, compression)\r\n 485 compression = infer_compression(urlpath)\r\n 486 if compression is not None and compression not in compr:\r\n--> 487 raise ValueError(\"Compression type %s not supported\" % compression)\r\n 488 return compression\r\n 489 \r\n\r\nValueError: Compression type zstd not supported\r\n```", "I just tried on google colab and this works:\r\n```python\r\n!pip install zstandard\r\n!pip install datasets\r\nfrom datasets import load_dataset\r\n\r\nlds = load_dataset(\r\n \"json\",\r\n data_files=\"https://the-eye.eu/public/AI/pile_preliminary_components/FreeLaw_Opinions.jsonl.zst\",\r\n split=\"train\",\r\n streaming=True,\r\n)\r\nnext(iter(lds))\r\n```\r\n\r\nCan you check that you have a correct installation of `zstandard` ?", "@lhoestq please note [this](https://github.com/huggingface/datasets/issues/2572#issuecomment-1363718916) is a duplicate of:\r\n- #5388", "Oh thanks I missed that one !", "> I just tried on google colab and this works:\r\n> \r\n> ```python\r\n> !pip install zstandard\r\n> !pip install datasets\r\n> from datasets import load_dataset\r\n> \r\n> lds = load_dataset(\r\n> \"json\",\r\n> data_files=\"https://the-eye.eu/public/AI/pile_preliminary_components/FreeLaw_Opinions.jsonl.zst\",\r\n> split=\"train\",\r\n> streaming=True,\r\n> )\r\n> next(iter(lds))\r\n> ```\r\n> \r\n> Can you check that you have a correct installation of `zstandard` ?\r\n\r\nI was downloading datasets first then was doing zstandard installation and that was causing the issue. This was highlighted by the Hugging Face staff and that helped. Now the issue is resolved. Thank you." ]
"2021-07-01T08:37:04Z"
"2023-01-03T15:34:01Z"
"2021-07-05T10:50:27Z"
MEMBER
null
null
null
Add support for Zstandard compressed files: https://facebook.github.io/zstd/
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/2572/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/2572/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/2280
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/2280/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/2280/comments
https://api.github.com/repos/huggingface/datasets/issues/2280/events
https://github.com/huggingface/datasets/pull/2280
870,780,431
MDExOlB1bGxSZXF1ZXN0NjI1OTE2Mzcy
2,280
Fixed typo seperate->separate
{ "avatar_url": "https://avatars.githubusercontent.com/u/32505743?v=4", "events_url": "https://api.github.com/users/laksh9950/events{/privacy}", "followers_url": "https://api.github.com/users/laksh9950/followers", "following_url": "https://api.github.com/users/laksh9950/following{/other_user}", "gists_url": "https://api.github.com/users/laksh9950/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/laksh9950", "id": 32505743, "login": "laksh9950", "node_id": "MDQ6VXNlcjMyNTA1NzQz", "organizations_url": "https://api.github.com/users/laksh9950/orgs", "received_events_url": "https://api.github.com/users/laksh9950/received_events", "repos_url": "https://api.github.com/users/laksh9950/repos", "site_admin": false, "starred_url": "https://api.github.com/users/laksh9950/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/laksh9950/subscriptions", "type": "User", "url": "https://api.github.com/users/laksh9950" }
[]
closed
false
null
[]
null
[ "Hi ! Thanks for the fix :)\r\nThe CI fail isn't related to your PR. I opened a PR #2286 to fix the CI.\r\nWe'll wait for #2286 to be merged to master first if you don't mind", "The PR has been merged ! Feel free to merge master into your branch to fix the CI" ]
"2021-04-29T08:55:46Z"
"2021-04-29T16:41:22Z"
"2021-04-29T16:41:16Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/2280.diff", "html_url": "https://github.com/huggingface/datasets/pull/2280", "merged_at": null, "patch_url": "https://github.com/huggingface/datasets/pull/2280.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/2280" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/2280/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/2280/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/6281
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/6281/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/6281/comments
https://api.github.com/repos/huggingface/datasets/issues/6281/events
https://github.com/huggingface/datasets/pull/6281
1,928,456,959
PR_kwDODunzps5cBQPd
6,281
Improve documentation of dataset.from_generator
{ "avatar_url": "https://avatars.githubusercontent.com/u/53510?v=4", "events_url": "https://api.github.com/users/hartmans/events{/privacy}", "followers_url": "https://api.github.com/users/hartmans/followers", "following_url": "https://api.github.com/users/hartmans/following{/other_user}", "gists_url": "https://api.github.com/users/hartmans/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/hartmans", "id": 53510, "login": "hartmans", "node_id": "MDQ6VXNlcjUzNTEw", "organizations_url": "https://api.github.com/users/hartmans/orgs", "received_events_url": "https://api.github.com/users/hartmans/received_events", "repos_url": "https://api.github.com/users/hartmans/repos", "site_admin": false, "starred_url": "https://api.github.com/users/hartmans/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/hartmans/subscriptions", "type": "User", "url": "https://api.github.com/users/hartmans" }
[]
closed
false
null
[]
null
[ "I have looked at the doc failures, and I do not think that my change caused the doc build failure, but I'm not 100% sure about that.\r\nI have high confidence that the integration test failures are not something I introduced:-)", "<details>\n<summary>Show benchmarks</summary>\n\nPyArrow==8.0.0\n\n<details>\n<summary>Show updated benchmarks!</summary>\n\n### Benchmark: benchmark_array_xd.json\n\n| metric | read_batch_formatted_as_numpy after write_array2d | read_batch_formatted_as_numpy after write_flattened_sequence | read_batch_formatted_as_numpy after write_nested_sequence | read_batch_unformated after write_array2d | read_batch_unformated after write_flattened_sequence | read_batch_unformated after write_nested_sequence | read_col_formatted_as_numpy after write_array2d | read_col_formatted_as_numpy after write_flattened_sequence | read_col_formatted_as_numpy after write_nested_sequence | read_col_unformated after write_array2d | read_col_unformated after write_flattened_sequence | read_col_unformated after write_nested_sequence | read_formatted_as_numpy after write_array2d | read_formatted_as_numpy after write_flattened_sequence | read_formatted_as_numpy after write_nested_sequence | read_unformated after write_array2d | read_unformated after write_flattened_sequence | read_unformated after write_nested_sequence | write_array2d | write_flattened_sequence | write_nested_sequence |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.008557 / 0.011353 (-0.002796) | 0.005224 / 0.011008 (-0.005784) | 0.109402 / 0.038508 (0.070893) | 0.075008 / 0.023109 (0.051899) | 0.388910 / 0.275898 (0.113012) | 0.425481 / 0.323480 (0.102002) | 0.005046 / 0.007986 (-0.002939) | 0.004166 / 0.004328 (-0.000162) | 0.079890 / 0.004250 (0.075639) | 0.061992 / 0.037052 (0.024940) | 0.409933 / 0.258489 (0.151444) | 0.444096 / 0.293841 (0.150255) | 0.043958 / 0.128546 (-0.084588) | 0.013655 / 0.075646 (-0.061991) | 0.402620 / 0.419271 (-0.016651) | 0.062784 / 0.043533 (0.019251) | 0.399653 / 0.255139 (0.144514) | 0.432926 / 0.283200 (0.149727) | 0.034631 / 0.141683 (-0.107052) | 1.801450 / 1.452155 (0.349296) | 1.965007 / 1.492716 (0.472290) |\n\n### Benchmark: benchmark_getitem\\_100B.json\n\n| metric | get_batch_of\\_1024\\_random_rows | get_batch_of\\_1024\\_rows | get_first_row | get_last_row |\n|--------|---|---|---|---|\n| new / old (diff) | 0.305744 / 0.018006 (0.287738) | 0.590825 / 0.000490 (0.590335) | 0.014561 / 0.000200 (0.014361) | 0.000430 / 0.000054 (0.000375) |\n\n### Benchmark: benchmark_indices_mapping.json\n\n| metric | select | shard | shuffle | sort | train_test_split |\n|--------|---|---|---|---|---|\n| new / old (diff) | 0.030449 / 0.037411 (-0.006962) | 0.091753 / 0.014526 (0.077227) | 0.106259 / 0.176557 (-0.070298) | 0.174599 / 0.737135 (-0.562537) | 0.107069 / 0.296338 (-0.189269) |\n\n### Benchmark: benchmark_iterating.json\n\n| metric | read 5000 | read 50000 | read_batch 50000 10 | read_batch 50000 100 | read_batch 50000 1000 | read_formatted numpy 5000 | read_formatted pandas 5000 | read_formatted tensorflow 5000 | read_formatted torch 5000 | read_formatted_batch numpy 5000 10 | read_formatted_batch numpy 5000 1000 | shuffled read 5000 | shuffled read 50000 | shuffled read_batch 50000 10 | shuffled read_batch 50000 100 | shuffled read_batch 50000 1000 | shuffled read_formatted numpy 5000 | shuffled read_formatted_batch numpy 5000 10 | shuffled read_formatted_batch numpy 5000 1000 |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.607544 / 0.215209 (0.392335) | 6.182592 / 2.077655 (4.104937) | 2.699782 / 1.504120 (1.195663) | 2.386915 / 1.541195 (0.845720) | 2.441763 / 1.468490 (0.973273) | 0.811360 / 4.584777 (-3.773417) | 5.253799 / 3.745712 (1.508087) | 4.762054 / 5.269862 (-0.507807) | 3.045161 / 4.565676 (-1.520515) | 0.095983 / 0.424275 (-0.328292) | 0.008653 / 0.007607 (0.001046) | 0.714218 / 0.226044 (0.488174) | 7.279325 / 2.268929 (5.010397) | 3.356107 / 55.444624 (-52.088517) | 2.765867 / 6.876477 (-4.110610) | 2.997756 / 2.142072 (0.855684) | 1.008740 / 4.805227 (-3.796487) | 0.201462 / 6.500664 (-6.299202) | 0.075780 / 0.075469 (0.000311) |\n\n### Benchmark: benchmark_map_filter.json\n\n| metric | filter | map fast-tokenizer batched | map identity | map identity batched | map no-op batched | map no-op batched numpy | map no-op batched pandas | map no-op batched pytorch | map no-op batched tensorflow |\n|--------|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 1.677034 / 1.841788 (-0.164754) | 23.546919 / 8.074308 (15.472610) | 21.576985 / 10.191392 (11.385593) | 0.239253 / 0.680424 (-0.441171) | 0.028740 / 0.534201 (-0.505460) | 0.468519 / 0.579283 (-0.110765) | 0.593935 / 0.434364 (0.159571) | 0.536830 / 0.540337 (-0.003507) | 0.779925 / 1.386936 (-0.607011) |\n\n</details>\nPyArrow==latest\n\n<details>\n<summary>Show updated benchmarks!</summary>\n\n### Benchmark: benchmark_array_xd.json\n\n| metric | read_batch_formatted_as_numpy after write_array2d | read_batch_formatted_as_numpy after write_flattened_sequence | read_batch_formatted_as_numpy after write_nested_sequence | read_batch_unformated after write_array2d | read_batch_unformated after write_flattened_sequence | read_batch_unformated after write_nested_sequence | read_col_formatted_as_numpy after write_array2d | read_col_formatted_as_numpy after write_flattened_sequence | read_col_formatted_as_numpy after write_nested_sequence | read_col_unformated after write_array2d | read_col_unformated after write_flattened_sequence | read_col_unformated after write_nested_sequence | read_formatted_as_numpy after write_array2d | read_formatted_as_numpy after write_flattened_sequence | read_formatted_as_numpy after write_nested_sequence | read_unformated after write_array2d | read_unformated after write_flattened_sequence | read_unformated after write_nested_sequence | write_array2d | write_flattened_sequence | write_nested_sequence |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.009582 / 0.011353 (-0.001771) | 0.004971 / 0.011008 (-0.006037) | 0.081304 / 0.038508 (0.042796) | 0.077588 / 0.023109 (0.054478) | 0.486610 / 0.275898 (0.210712) | 0.580228 / 0.323480 (0.256748) | 0.006707 / 0.007986 (-0.001279) | 0.004325 / 0.004328 (-0.000004) | 0.086170 / 0.004250 (0.081920) | 0.060591 / 0.037052 (0.023539) | 0.501723 / 0.258489 (0.243234) | 0.548633 / 0.293841 (0.254793) | 0.050306 / 0.128546 (-0.078240) | 0.017458 / 0.075646 (-0.058188) | 0.093295 / 0.419271 (-0.325977) | 0.064588 / 0.043533 (0.021056) | 0.519395 / 0.255139 (0.264256) | 0.526021 / 0.283200 (0.242821) | 0.035795 / 0.141683 (-0.105888) | 1.792927 / 1.452155 (0.340772) | 1.956499 / 1.492716 (0.463783) |\n\n### Benchmark: benchmark_getitem\\_100B.json\n\n| metric | get_batch_of\\_1024\\_random_rows | get_batch_of\\_1024\\_rows | get_first_row | get_last_row |\n|--------|---|---|---|---|\n| new / old (diff) | 0.296249 / 0.018006 (0.278243) | 0.594482 / 0.000490 (0.593992) | 0.007318 / 0.000200 (0.007118) | 0.000182 / 0.000054 (0.000128) |\n\n### Benchmark: benchmark_indices_mapping.json\n\n| metric | select | shard | shuffle | sort | train_test_split |\n|--------|---|---|---|---|---|\n| new / old (diff) | 0.036110 / 0.037411 (-0.001301) | 0.107924 / 0.014526 (0.093399) | 0.119975 / 0.176557 (-0.056582) | 0.177499 / 0.737135 (-0.559636) | 0.123299 / 0.296338 (-0.173039) |\n\n### Benchmark: benchmark_iterating.json\n\n| metric | read 5000 | read 50000 | read_batch 50000 10 | read_batch 50000 100 | read_batch 50000 1000 | read_formatted numpy 5000 | read_formatted pandas 5000 | read_formatted tensorflow 5000 | read_formatted torch 5000 | read_formatted_batch numpy 5000 10 | read_formatted_batch numpy 5000 1000 | shuffled read 5000 | shuffled read 50000 | shuffled read_batch 50000 10 | shuffled read_batch 50000 100 | shuffled read_batch 50000 1000 | shuffled read_formatted numpy 5000 | shuffled read_formatted_batch numpy 5000 10 | shuffled read_formatted_batch numpy 5000 1000 |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.632994 / 0.215209 (0.417785) | 6.481663 / 2.077655 (4.404008) | 3.231259 / 1.504120 (1.727139) | 2.768298 / 1.541195 (1.227103) | 2.694543 / 1.468490 (1.226053) | 0.837384 / 4.584777 (-3.747393) | 5.405278 / 3.745712 (1.659566) | 4.639424 / 5.269862 (-0.630437) | 2.944251 / 4.565676 (-1.621426) | 0.094978 / 0.424275 (-0.329297) | 0.008716 / 0.007607 (0.001108) | 0.795820 / 0.226044 (0.569776) | 8.514233 / 2.268929 (6.245304) | 3.800463 / 55.444624 (-51.644161) | 3.000005 / 6.876477 (-3.876472) | 3.298853 / 2.142072 (1.156781) | 0.994112 / 4.805227 (-3.811115) | 0.209435 / 6.500664 (-6.291229) | 0.075610 / 0.075469 (0.000141) |\n\n### Benchmark: benchmark_map_filter.json\n\n| metric | filter | map fast-tokenizer batched | map identity | map identity batched | map no-op batched | map no-op batched numpy | map no-op batched pandas | map no-op batched pytorch | map no-op batched tensorflow |\n|--------|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 1.681127 / 1.841788 (-0.160661) | 23.874465 / 8.074308 (15.800156) | 21.638567 / 10.191392 (11.447175) | 0.233303 / 0.680424 (-0.447121) | 0.032504 / 0.534201 (-0.501697) | 0.460462 / 0.579283 (-0.118821) | 0.560043 / 0.434364 (0.125679) | 0.555059 / 0.540337 (0.014721) | 0.831444 / 1.386936 (-0.555492) |\n\n</details>\n</details>\n\n![](https://cml.dev/watermark.png#faada1742e1f25fce9cc5691ec11d3f91d4aa120 \"CML watermark\")\n" ]
"2023-10-05T14:34:49Z"
"2023-10-05T19:09:07Z"
"2023-10-05T18:57:41Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/6281.diff", "html_url": "https://github.com/huggingface/datasets/pull/6281", "merged_at": "2023-10-05T18:57:41Z", "patch_url": "https://github.com/huggingface/datasets/pull/6281.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/6281" }
Improve documentation to clarify sharding behavior (#6270)
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/6281/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/6281/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/4434
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/4434/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/4434/comments
https://api.github.com/repos/huggingface/datasets/issues/4434/events
https://github.com/huggingface/datasets/pull/4434
1,256,207,321
PR_kwDODunzps443mAr
4,434
Fix dummy dataset generation script for handling nested types of _URLs
{ "avatar_url": "https://avatars.githubusercontent.com/u/2529049?v=4", "events_url": "https://api.github.com/users/silverriver/events{/privacy}", "followers_url": "https://api.github.com/users/silverriver/followers", "following_url": "https://api.github.com/users/silverriver/following{/other_user}", "gists_url": "https://api.github.com/users/silverriver/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/silverriver", "id": 2529049, "login": "silverriver", "node_id": "MDQ6VXNlcjI1MjkwNDk=", "organizations_url": "https://api.github.com/users/silverriver/orgs", "received_events_url": "https://api.github.com/users/silverriver/received_events", "repos_url": "https://api.github.com/users/silverriver/repos", "site_admin": false, "starred_url": "https://api.github.com/users/silverriver/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/silverriver/subscriptions", "type": "User", "url": "https://api.github.com/users/silverriver" }
[]
closed
false
null
[]
null
[]
"2022-06-01T14:53:15Z"
"2022-06-07T12:08:28Z"
"2022-06-07T09:24:09Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/4434.diff", "html_url": "https://github.com/huggingface/datasets/pull/4434", "merged_at": "2022-06-07T09:24:09Z", "patch_url": "https://github.com/huggingface/datasets/pull/4434.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/4434" }
It seems that when user specify nested _URLs structures in their dataset script. An error will be raised when generating dummy dataset. I think the types of all elements in `dummy_data_dict.values()` should be checked because they may have different types. Linked to issue #4428 PS: I am not sure whether my code fix this issue in a proper way.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/4434/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/4434/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/5498
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5498/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5498/comments
https://api.github.com/repos/huggingface/datasets/issues/5498/events
https://github.com/huggingface/datasets/issues/5498
1,568,190,529
I_kwDODunzps5deLBB
5,498
TypeError: 'bool' object is not iterable when filtering a datasets.arrow_dataset.Dataset
{ "avatar_url": "https://avatars.githubusercontent.com/u/91255010?v=4", "events_url": "https://api.github.com/users/vmuel/events{/privacy}", "followers_url": "https://api.github.com/users/vmuel/followers", "following_url": "https://api.github.com/users/vmuel/following{/other_user}", "gists_url": "https://api.github.com/users/vmuel/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/vmuel", "id": 91255010, "login": "vmuel", "node_id": "MDQ6VXNlcjkxMjU1MDEw", "organizations_url": "https://api.github.com/users/vmuel/orgs", "received_events_url": "https://api.github.com/users/vmuel/received_events", "repos_url": "https://api.github.com/users/vmuel/repos", "site_admin": false, "starred_url": "https://api.github.com/users/vmuel/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/vmuel/subscriptions", "type": "User", "url": "https://api.github.com/users/vmuel" }
[]
closed
false
null
[]
null
[ "Hi! Instead of a single boolean, your filter function should return an iterable (of booleans) in the batched mode like so:\r\n```python\r\ntrain_dataset = train_dataset.filter(\r\n function=lambda batch: [image is not None for image in batch[\"image\"]], \r\n batched=True,\r\n batch_size=10)\r\n```\r\n\r\nPS: You can make this operation much faster by operating directly on the arrow data to skip the decoding part:\r\n```python\r\ntrain_dataset = train_dataset.with_format(\"arrow\")\r\ntrain_dataset = train_dataset.filter(\r\n function=lambda table: table[\"image\"].is_valid().to_pylist(), \r\n batched=True,\r\n batch_size=100)\r\ntrain_dataset = train_dataset.with_format(None)\r\n```", "Thank a lot!", "I hit the same issue and the error message isn't really clear on what's going wrong. It might be helpful to update the docs with a batched example." ]
"2023-02-02T14:46:49Z"
"2023-10-08T06:12:47Z"
"2023-02-04T17:19:36Z"
NONE
null
null
null
### Describe the bug Hi, Thanks for the amazing work on the library! **Describe the bug** I think I might have noticed a small bug in the filter method. Having loaded a dataset using `load_dataset`, when I try to filter out empty entries with `batched=True`, I get a TypeError. ### Steps to reproduce the bug ``` train_dataset = train_dataset.filter( function=lambda example: example["image"] is not None, batched=True, batch_size=10) ``` Error message: ``` File .../lib/python3.9/site-packages/datasets/fingerprint.py:480, in fingerprint_transform.<locals>._fingerprint.<locals>.wrapper(*args, **kwargs) 476 validate_fingerprint(kwargs[fingerprint_name]) 478 # Call actual function --> 480 out = func(self, *args, **kwargs) ... -> 5666 indices_array = [i for i, to_keep in zip(indices, mask) if to_keep] 5667 if indices_mapping is not None: 5668 indices_array = pa.array(indices_array, type=pa.uint64()) TypeError: 'bool' object is not iterable ``` **Removing batched=True allows to bypass the issue.** ### Expected behavior According to the doc, "[batch_size corresponds to the] number of examples per batch provided to function if batched = True", so we shouldn't need to remove the batchd=True arg? source: https://huggingface.co/docs/datasets/v2.9.0/en/package_reference/main_classes#datasets.Dataset.filter ### Environment info - `datasets` version: 2.9.0 - Platform: Linux-5.4.0-122-generic-x86_64-with-glibc2.31 - Python version: 3.9.10 - PyArrow version: 10.0.1 - Pandas version: 1.5.3
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/5498/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5498/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/5950
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5950/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5950/comments
https://api.github.com/repos/huggingface/datasets/issues/5950/events
https://github.com/huggingface/datasets/issues/5950
1,755,197,946
I_kwDODunzps5onjH6
5,950
Support for data with instance-wise dictionary as features
{ "avatar_url": "https://avatars.githubusercontent.com/u/33274336?v=4", "events_url": "https://api.github.com/users/richardwth/events{/privacy}", "followers_url": "https://api.github.com/users/richardwth/followers", "following_url": "https://api.github.com/users/richardwth/following{/other_user}", "gists_url": "https://api.github.com/users/richardwth/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/richardwth", "id": 33274336, "login": "richardwth", "node_id": "MDQ6VXNlcjMzMjc0MzM2", "organizations_url": "https://api.github.com/users/richardwth/orgs", "received_events_url": "https://api.github.com/users/richardwth/received_events", "repos_url": "https://api.github.com/users/richardwth/repos", "site_admin": false, "starred_url": "https://api.github.com/users/richardwth/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/richardwth/subscriptions", "type": "User", "url": "https://api.github.com/users/richardwth" }
[ { "color": "a2eeef", "default": true, "description": "New feature or request", "id": 1935892871, "name": "enhancement", "node_id": "MDU6TGFiZWwxOTM1ODkyODcx", "url": "https://api.github.com/repos/huggingface/datasets/labels/enhancement" } ]
open
false
null
[]
null
[ "Hi ! We use the Arrow columnar format under the hood, which doesn't support such dictionaries: each field must have a fixed type and exist in each sample.\r\n\r\nInstead you can restructure your data like\r\n```\r\n{\r\n \"index\": 0,\r\n \"keys\": [\"2 * x + y >= 3\"],\r\n \"values\": [[\"2 * x + y >= 3\", \"4 * x + 2 * y >= 6\"]],\r\n }\r\n},\r\n...\r\n{\r\n \"index\": 9999,\r\n \"keys\": [\"x >= 6\"],\r\n \"values\": [[\"x >= 6\", \"x >= 0\", \"x >= -1\"]],\r\n},\r\n...\r\n```" ]
"2023-06-13T15:49:00Z"
"2023-06-14T12:13:38Z"
null
NONE
null
null
null
### Feature request I notice that when loading data instances with feature type of python dictionary, the dictionary keys would be broadcast so that every instance has the same set of keys. Please see an example in the Motivation section. It is possible to avoid this behavior, i.e., load dictionary features as it is and do not broadcast the keys among instances? Please note that these dictionaries would have to be processed dynamically at each training iteration into strings (and tokenized). ### Motivation I am trying to load a dataset from a json file. Each instance of the dataset has a feature that is a dictionary but its keys depend on the instance. Every two instances may have different keys. For example, imagine a dataset that contains a set of math expressions from a bunch of mutually redundant expressions: ``` { "index": 0, "feature": { "2 * x + y >= 3": ["2 * x + y >= 3", "4 * x + 2 * y >= 6"], ... } }, ... { "index": 9999, "feature": { "x >= 6": ["x >= 6", "x >= 0", "x >= -1"], ... } }, ... ``` When directly loading the dataset using `data = load_dataset("json", data_files=file_paths, split='train')`, each instance would have all the keys from other instances and None as values. That is, instance of index 0 becomes: ``` { "index": 0, "feature": { "2 * x + y >= 3": ["2 * x + y >= 3", "4 * x + 2 * y >= 6"], ... "x >= 6": None, # keys from other instances ... } }, ``` This is not desirable. Moreover, issue would be raised if I attempt to combine two such datasets using `data = concatenate_datasets(multi_datasets)`, perhaps because their dictionary features contain different keys. A solution I can think of is to store the dictionary features as a long string, and evaluate it later. Please kindly suggest any other solution using existing methods of datasets. ### Your contribution N/A
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/5950/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5950/timeline
null
null
false
https://api.github.com/repos/huggingface/datasets/issues/5507
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5507/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5507/comments
https://api.github.com/repos/huggingface/datasets/issues/5507/events
https://github.com/huggingface/datasets/issues/5507
1,572,667,036
I_kwDODunzps5dvP6c
5,507
Optimise behaviour in respect to indices mapping
{ "avatar_url": "https://avatars.githubusercontent.com/u/47462742?v=4", "events_url": "https://api.github.com/users/mariosasko/events{/privacy}", "followers_url": "https://api.github.com/users/mariosasko/followers", "following_url": "https://api.github.com/users/mariosasko/following{/other_user}", "gists_url": "https://api.github.com/users/mariosasko/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mariosasko", "id": 47462742, "login": "mariosasko", "node_id": "MDQ6VXNlcjQ3NDYyNzQy", "organizations_url": "https://api.github.com/users/mariosasko/orgs", "received_events_url": "https://api.github.com/users/mariosasko/received_events", "repos_url": "https://api.github.com/users/mariosasko/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mariosasko/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mariosasko/subscriptions", "type": "User", "url": "https://api.github.com/users/mariosasko" }
[ { "color": "a2eeef", "default": true, "description": "New feature or request", "id": 1935892871, "name": "enhancement", "node_id": "MDU6TGFiZWwxOTM1ODkyODcx", "url": "https://api.github.com/repos/huggingface/datasets/labels/enhancement" } ]
open
false
{ "avatar_url": "https://avatars.githubusercontent.com/u/47462742?v=4", "events_url": "https://api.github.com/users/mariosasko/events{/privacy}", "followers_url": "https://api.github.com/users/mariosasko/followers", "following_url": "https://api.github.com/users/mariosasko/following{/other_user}", "gists_url": "https://api.github.com/users/mariosasko/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mariosasko", "id": 47462742, "login": "mariosasko", "node_id": "MDQ6VXNlcjQ3NDYyNzQy", "organizations_url": "https://api.github.com/users/mariosasko/orgs", "received_events_url": "https://api.github.com/users/mariosasko/received_events", "repos_url": "https://api.github.com/users/mariosasko/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mariosasko/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mariosasko/subscriptions", "type": "User", "url": "https://api.github.com/users/mariosasko" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/47462742?v=4", "events_url": "https://api.github.com/users/mariosasko/events{/privacy}", "followers_url": "https://api.github.com/users/mariosasko/followers", "following_url": "https://api.github.com/users/mariosasko/following{/other_user}", "gists_url": "https://api.github.com/users/mariosasko/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mariosasko", "id": 47462742, "login": "mariosasko", "node_id": "MDQ6VXNlcjQ3NDYyNzQy", "organizations_url": "https://api.github.com/users/mariosasko/orgs", "received_events_url": "https://api.github.com/users/mariosasko/received_events", "repos_url": "https://api.github.com/users/mariosasko/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mariosasko/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mariosasko/subscriptions", "type": "User", "url": "https://api.github.com/users/mariosasko" } ]
null
[]
"2023-02-06T14:25:55Z"
"2023-02-28T18:19:18Z"
null
CONTRIBUTOR
null
null
null
_Originally [posted](https://huggingface.slack.com/archives/C02V51Q3800/p1675443873878489?thread_ts=1675418893.373479&cid=C02V51Q3800) on Slack_ Considering all this, perhaps for Datasets 3.0, we can do the following: * [ ] have `continuous=True` by default in `.shard` (requested in the survey and makes more sense for us since it doesn't create an indices mapping) * [x] allow calling `save_to_disk` on "unflattened" datasets * [ ] remove "hidden" expensive calls in `save_to_disk`, `unique`, `concatenate_datasets`, etc. For instance, instead of silently calling `flatten_indices` where it's needed, it's probably better to be explicit (considering how expensive these ops can be) and raise an error instead
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 1, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 1, "url": "https://api.github.com/repos/huggingface/datasets/issues/5507/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5507/timeline
null
null
false
https://api.github.com/repos/huggingface/datasets/issues/1542
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/1542/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/1542/comments
https://api.github.com/repos/huggingface/datasets/issues/1542/events
https://github.com/huggingface/datasets/pull/1542
765,439,746
MDExOlB1bGxSZXF1ZXN0NTM4OTYyMjAx
1,542
fix typo readme
{ "avatar_url": "https://avatars.githubusercontent.com/u/821155?v=4", "events_url": "https://api.github.com/users/clmnt/events{/privacy}", "followers_url": "https://api.github.com/users/clmnt/followers", "following_url": "https://api.github.com/users/clmnt/following{/other_user}", "gists_url": "https://api.github.com/users/clmnt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/clmnt", "id": 821155, "login": "clmnt", "node_id": "MDQ6VXNlcjgyMTE1NQ==", "organizations_url": "https://api.github.com/users/clmnt/orgs", "received_events_url": "https://api.github.com/users/clmnt/received_events", "repos_url": "https://api.github.com/users/clmnt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/clmnt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/clmnt/subscriptions", "type": "User", "url": "https://api.github.com/users/clmnt" }
[]
closed
false
null
[]
null
[]
"2020-12-13T14:41:22Z"
"2020-12-13T17:16:41Z"
"2020-12-13T17:16:40Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/1542.diff", "html_url": "https://github.com/huggingface/datasets/pull/1542", "merged_at": "2020-12-13T17:16:40Z", "patch_url": "https://github.com/huggingface/datasets/pull/1542.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/1542" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/1542/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/1542/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/2875
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/2875/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/2875/comments
https://api.github.com/repos/huggingface/datasets/issues/2875/events
https://github.com/huggingface/datasets/issues/2875
989,919,398
MDU6SXNzdWU5ODk5MTkzOTg=
2,875
Add Congolese Swahili speech datasets
{ "avatar_url": "https://avatars.githubusercontent.com/u/7246357?v=4", "events_url": "https://api.github.com/users/osanseviero/events{/privacy}", "followers_url": "https://api.github.com/users/osanseviero/followers", "following_url": "https://api.github.com/users/osanseviero/following{/other_user}", "gists_url": "https://api.github.com/users/osanseviero/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/osanseviero", "id": 7246357, "login": "osanseviero", "node_id": "MDQ6VXNlcjcyNDYzNTc=", "organizations_url": "https://api.github.com/users/osanseviero/orgs", "received_events_url": "https://api.github.com/users/osanseviero/received_events", "repos_url": "https://api.github.com/users/osanseviero/repos", "site_admin": false, "starred_url": "https://api.github.com/users/osanseviero/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/osanseviero/subscriptions", "type": "User", "url": "https://api.github.com/users/osanseviero" }
[ { "color": "e99695", "default": false, "description": "Requesting to add a new dataset", "id": 2067376369, "name": "dataset request", "node_id": "MDU6TGFiZWwyMDY3Mzc2MzY5", "url": "https://api.github.com/repos/huggingface/datasets/labels/dataset%20request" }, { "color": "d93f0b", "default": false, "description": "", "id": 2725241052, "name": "speech", "node_id": "MDU6TGFiZWwyNzI1MjQxMDUy", "url": "https://api.github.com/repos/huggingface/datasets/labels/speech" } ]
open
false
null
[]
null
[]
"2021-09-07T12:13:50Z"
"2021-09-07T12:13:50Z"
null
MEMBER
null
null
null
## Adding a Dataset - **Name:** Congolese Swahili speech corpora - **Data:** https://gamayun.translatorswb.org/data/ Instructions to add a new dataset can be found [here](https://github.com/huggingface/datasets/blob/master/ADD_NEW_DATASET.md). Also related: https://mobile.twitter.com/OktemAlp/status/1435196393631764482
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/2875/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/2875/timeline
null
null
false
https://api.github.com/repos/huggingface/datasets/issues/4258
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/4258/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/4258/comments
https://api.github.com/repos/huggingface/datasets/issues/4258/events
https://github.com/huggingface/datasets/pull/4258
1,221,637,727
PR_kwDODunzps43Gstg
4,258
Fix/start token mask issue and update documentation
{ "avatar_url": "https://avatars.githubusercontent.com/u/20826878?v=4", "events_url": "https://api.github.com/users/TristanThrush/events{/privacy}", "followers_url": "https://api.github.com/users/TristanThrush/followers", "following_url": "https://api.github.com/users/TristanThrush/following{/other_user}", "gists_url": "https://api.github.com/users/TristanThrush/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/TristanThrush", "id": 20826878, "login": "TristanThrush", "node_id": "MDQ6VXNlcjIwODI2ODc4", "organizations_url": "https://api.github.com/users/TristanThrush/orgs", "received_events_url": "https://api.github.com/users/TristanThrush/received_events", "repos_url": "https://api.github.com/users/TristanThrush/repos", "site_admin": false, "starred_url": "https://api.github.com/users/TristanThrush/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/TristanThrush/subscriptions", "type": "User", "url": "https://api.github.com/users/TristanThrush" }
[]
closed
false
null
[]
null
[ "_The documentation is not available anymore as the PR was closed or merged._", "> Good catch ! Thanks :)\r\n> \r\n> Next time can you describe your fix in the Pull Request description please ?\r\n\r\nThanks. Also whoops, sorry about not being very descriptive. I updated the pull request description, and will keep this in mind for future PRs." ]
"2022-04-29T22:42:44Z"
"2022-05-02T16:33:20Z"
"2022-05-02T16:26:12Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/4258.diff", "html_url": "https://github.com/huggingface/datasets/pull/4258", "merged_at": "2022-05-02T16:26:12Z", "patch_url": "https://github.com/huggingface/datasets/pull/4258.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/4258" }
This pr fixes a couple bugs: 1) the perplexity was calculated with a 0 in the attention mask for the start token, which was causing high perplexity scores that were not correct 2) the documentation was not updated
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/4258/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/4258/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/5160
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5160/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5160/comments
https://api.github.com/repos/huggingface/datasets/issues/5160/events
https://github.com/huggingface/datasets/issues/5160
1,422,193,938
I_kwDODunzps5UxPUS
5,160
Automatically add filename for image/audio folder
{ "avatar_url": "https://avatars.githubusercontent.com/u/23423619?v=4", "events_url": "https://api.github.com/users/patrickvonplaten/events{/privacy}", "followers_url": "https://api.github.com/users/patrickvonplaten/followers", "following_url": "https://api.github.com/users/patrickvonplaten/following{/other_user}", "gists_url": "https://api.github.com/users/patrickvonplaten/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/patrickvonplaten", "id": 23423619, "login": "patrickvonplaten", "node_id": "MDQ6VXNlcjIzNDIzNjE5", "organizations_url": "https://api.github.com/users/patrickvonplaten/orgs", "received_events_url": "https://api.github.com/users/patrickvonplaten/received_events", "repos_url": "https://api.github.com/users/patrickvonplaten/repos", "site_admin": false, "starred_url": "https://api.github.com/users/patrickvonplaten/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/patrickvonplaten/subscriptions", "type": "User", "url": "https://api.github.com/users/patrickvonplaten" }
[ { "color": "a2eeef", "default": true, "description": "New feature or request", "id": 1935892871, "name": "enhancement", "node_id": "MDU6TGFiZWwxOTM1ODkyODcx", "url": "https://api.github.com/repos/huggingface/datasets/labels/enhancement" } ]
open
false
{ "avatar_url": "https://avatars.githubusercontent.com/u/16348744?v=4", "events_url": "https://api.github.com/users/polinaeterna/events{/privacy}", "followers_url": "https://api.github.com/users/polinaeterna/followers", "following_url": "https://api.github.com/users/polinaeterna/following{/other_user}", "gists_url": "https://api.github.com/users/polinaeterna/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/polinaeterna", "id": 16348744, "login": "polinaeterna", "node_id": "MDQ6VXNlcjE2MzQ4NzQ0", "organizations_url": "https://api.github.com/users/polinaeterna/orgs", "received_events_url": "https://api.github.com/users/polinaeterna/received_events", "repos_url": "https://api.github.com/users/polinaeterna/repos", "site_admin": false, "starred_url": "https://api.github.com/users/polinaeterna/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/polinaeterna/subscriptions", "type": "User", "url": "https://api.github.com/users/polinaeterna" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/16348744?v=4", "events_url": "https://api.github.com/users/polinaeterna/events{/privacy}", "followers_url": "https://api.github.com/users/polinaeterna/followers", "following_url": "https://api.github.com/users/polinaeterna/following{/other_user}", "gists_url": "https://api.github.com/users/polinaeterna/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/polinaeterna", "id": 16348744, "login": "polinaeterna", "node_id": "MDQ6VXNlcjE2MzQ4NzQ0", "organizations_url": "https://api.github.com/users/polinaeterna/orgs", "received_events_url": "https://api.github.com/users/polinaeterna/received_events", "repos_url": "https://api.github.com/users/polinaeterna/repos", "site_admin": false, "starred_url": "https://api.github.com/users/polinaeterna/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/polinaeterna/subscriptions", "type": "User", "url": "https://api.github.com/users/polinaeterna" }, { "avatar_url": "https://avatars.githubusercontent.com/u/42851186?v=4", "events_url": "https://api.github.com/users/lhoestq/events{/privacy}", "followers_url": "https://api.github.com/users/lhoestq/followers", "following_url": "https://api.github.com/users/lhoestq/following{/other_user}", "gists_url": "https://api.github.com/users/lhoestq/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/lhoestq", "id": 42851186, "login": "lhoestq", "node_id": "MDQ6VXNlcjQyODUxMTg2", "organizations_url": "https://api.github.com/users/lhoestq/orgs", "received_events_url": "https://api.github.com/users/lhoestq/received_events", "repos_url": "https://api.github.com/users/lhoestq/repos", "site_admin": false, "starred_url": "https://api.github.com/users/lhoestq/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/lhoestq/subscriptions", "type": "User", "url": "https://api.github.com/users/lhoestq" }, { "avatar_url": "https://avatars.githubusercontent.com/u/47462742?v=4", "events_url": "https://api.github.com/users/mariosasko/events{/privacy}", "followers_url": "https://api.github.com/users/mariosasko/followers", "following_url": "https://api.github.com/users/mariosasko/following{/other_user}", "gists_url": "https://api.github.com/users/mariosasko/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mariosasko", "id": 47462742, "login": "mariosasko", "node_id": "MDQ6VXNlcjQ3NDYyNzQy", "organizations_url": "https://api.github.com/users/mariosasko/orgs", "received_events_url": "https://api.github.com/users/mariosasko/received_events", "repos_url": "https://api.github.com/users/mariosasko/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mariosasko/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mariosasko/subscriptions", "type": "User", "url": "https://api.github.com/users/mariosasko" } ]
null
[ "Also cc @anton-l ", "BTW the exact same holds true for the audio folder", "I'm fine with adding a new column with the file name personally. Not sure how breaking this is though", "@patrickvonplaten do you mean just filename or full relative path inside the repo?\r\nI think it shouldn't be breaking, at least I cannot come up with any case where it is. Maybe @mariosasko can?\r\n\r\nalso I think that the problem here and in general is that Image/AudioFolder has default configuration which implies automatic label creation if there is not metadata file. It can be changed when you load the dataset with `load_dataset` but not on it's Hub page. \r\n\r\n", "> also I think that the problem here and in general Image/AudioFolder has default configuration which implies automatic label creation if there is not metadata file\r\n\r\nYea I agree it's often the wrong default. We can also imagine adding the builder's parameters as YAML in the repo.", "@lhoestq yes I also got the idea of some YAML config! not sure of what priority it is though.", "but it would actually also solve this issue: https://github.com/huggingface/datasets/issues/5153", "I meant just the file name (no path) that would already be super helpful IMO :-) (maybe dir+filename if there are dirs in the folder)", "@patrickvonplaten one more time, to be sure I understand you.\r\nFor example, we have data structure like this:\r\n```\r\n├─ data/\r\n│ └─ subdir/\r\n│ └── cats/\r\n│ ├── 0.jpg\r\n│ ├── 1.jpg\r\n│ └── 2.jpg\r\n│ └── dogs/\r\n│ ├── 0.jpg\r\n│ ├── 1.jpg\r\n│ └── 2.jpg\r\n└── another_subdir/\r\n ├── 10.jpg\r\n ├── 11.jpg\r\n └── 12.jpg\r\n```\r\nIs it okay to provide `\"data/subdir/cats/0.jpg\"`, `\"data/subdir/dogs/0.jpg\"`, `\"data/another_subdir/10.jpg\"`?\r\nI think providing just filenames might be confusing if they are not unique, as in this example. ", "Yes I think the relative path as you proposed makes a lot of sense :-) " ]
"2022-10-25T09:56:49Z"
"2022-10-26T16:51:46Z"
null
MEMBER
null
null
null
### Feature request When creating a custom audio of image dataset, it would be great to automatically have access to the filename. It should be both: a) Automatically displayed in the viewer b) Automatically added as a column to the dataset when doing `load_dataset` In `diffusers` our test rely quite heavily on images and audio files now and it's a bit tedious at the moment to download specific images from a datasets repo. E.g. we have a dataset of images for tests in `diffusers`: https://huggingface.co/datasets/hf-internal-testing/diffusers-images where it would be extremely nice to have direct access to the filename both visually on the datasets page (@severo ) as well as via the `load_datasets` function. We currently have some akward functionality to download images by path name: https://github.com/huggingface/diffusers/blob/2fb8fafa4b761f6fc144cf75a6f6f0ea6af3a1c1/src/diffusers/utils/testing_utils.py#L131 It would be much nicer to just go over `load_dataset(...)` ### Motivation Intuitively the filename is something people understand directly. E.g if you upload a folder of images online, it's nice if you recognize the image as well as the filename next to it directly and that you're able to use it right away. The label on the other hand is less intuitive to understand as you haven't added it yourself. ### Your contribution Not sure if I have the time to add it myself anytime soon, but it would help us a lot for `diffusers`.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/5160/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5160/timeline
null
null
false
https://api.github.com/repos/huggingface/datasets/issues/2444
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/2444/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/2444/comments
https://api.github.com/repos/huggingface/datasets/issues/2444/events
https://github.com/huggingface/datasets/issues/2444
911,297,139
MDU6SXNzdWU5MTEyOTcxMzk=
2,444
Sentence Boundaries missing in Dataset: xtreme / udpos
{ "avatar_url": "https://avatars.githubusercontent.com/u/50871412?v=4", "events_url": "https://api.github.com/users/jerryIsHere/events{/privacy}", "followers_url": "https://api.github.com/users/jerryIsHere/followers", "following_url": "https://api.github.com/users/jerryIsHere/following{/other_user}", "gists_url": "https://api.github.com/users/jerryIsHere/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jerryIsHere", "id": 50871412, "login": "jerryIsHere", "node_id": "MDQ6VXNlcjUwODcxNDEy", "organizations_url": "https://api.github.com/users/jerryIsHere/orgs", "received_events_url": "https://api.github.com/users/jerryIsHere/received_events", "repos_url": "https://api.github.com/users/jerryIsHere/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jerryIsHere/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jerryIsHere/subscriptions", "type": "User", "url": "https://api.github.com/users/jerryIsHere" }
[ { "color": "d73a4a", "default": true, "description": "Something isn't working", "id": 1935892857, "name": "bug", "node_id": "MDU6TGFiZWwxOTM1ODkyODU3", "url": "https://api.github.com/repos/huggingface/datasets/labels/bug" } ]
closed
false
null
[]
null
[ "Hi,\r\n\r\nThis is a known issue. More info on this issue can be found in #2061. If you are looking for an open-source contribution, there are step-by-step instructions in the linked issue that you can follow to fix it.", "Closed by #2466." ]
"2021-06-04T09:10:26Z"
"2021-06-18T11:53:43Z"
"2021-06-18T11:53:43Z"
CONTRIBUTOR
null
null
null
I was browsing through annotation guidelines, as suggested by the datasets introduction. The guidlines saids "There must be exactly one blank line after every sentence, including the last sentence in the file. Empty sentences are not allowed." in the [Sentence Boundaries and Comments section](https://universaldependencies.org/format.html#sentence-boundaries-and-comments) But the sentence boundaries seems not to be represented by huggingface datasets features well. I found out that multiple sentence are concatenated together as a 1D array, without any delimiter. PAN-x, which is another token classification subset from xtreme do represent the sentence boundary using a 2D array. You may compare in PAN-x.en and udpos.English in the explorer: https://huggingface.co/datasets/viewer/?dataset=xtreme
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/2444/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/2444/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/1390
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/1390/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/1390/comments
https://api.github.com/repos/huggingface/datasets/issues/1390/events
https://github.com/huggingface/datasets/pull/1390
760,431,051
MDExOlB1bGxSZXF1ZXN0NTM1MjYzNzk1
1,390
Add SPC Dataset
{ "avatar_url": "https://avatars.githubusercontent.com/u/1183441?v=4", "events_url": "https://api.github.com/users/abhishekkrthakur/events{/privacy}", "followers_url": "https://api.github.com/users/abhishekkrthakur/followers", "following_url": "https://api.github.com/users/abhishekkrthakur/following{/other_user}", "gists_url": "https://api.github.com/users/abhishekkrthakur/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/abhishekkrthakur", "id": 1183441, "login": "abhishekkrthakur", "node_id": "MDQ6VXNlcjExODM0NDE=", "organizations_url": "https://api.github.com/users/abhishekkrthakur/orgs", "received_events_url": "https://api.github.com/users/abhishekkrthakur/received_events", "repos_url": "https://api.github.com/users/abhishekkrthakur/repos", "site_admin": false, "starred_url": "https://api.github.com/users/abhishekkrthakur/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/abhishekkrthakur/subscriptions", "type": "User", "url": "https://api.github.com/users/abhishekkrthakur" }
[]
closed
false
null
[]
null
[]
"2020-12-09T15:31:51Z"
"2020-12-14T11:13:53Z"
"2020-12-14T11:13:52Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/1390.diff", "html_url": "https://github.com/huggingface/datasets/pull/1390", "merged_at": "2020-12-14T11:13:52Z", "patch_url": "https://github.com/huggingface/datasets/pull/1390.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/1390" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/1390/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/1390/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/3481
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/3481/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/3481/comments
https://api.github.com/repos/huggingface/datasets/issues/3481/events
https://github.com/huggingface/datasets/pull/3481
1,088,308,343
PR_kwDODunzps4wQoJu
3,481
Fix overriding of filesystem info
{ "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" }
[]
closed
false
null
[]
null
[]
"2021-12-24T10:42:31Z"
"2021-12-24T11:08:59Z"
"2021-12-24T11:08:59Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/3481.diff", "html_url": "https://github.com/huggingface/datasets/pull/3481", "merged_at": "2021-12-24T11:08:59Z", "patch_url": "https://github.com/huggingface/datasets/pull/3481.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/3481" }
Previously, `BaseCompressedFileFileSystem.info` was overridden and transformed from function to dict. This generated a bug for filesystem methods that use `self.info()`, like e.g. `fs.isfile()`. This PR: - Adds tests for `fs.isfile` (that use `fs.info`). - Fixes custom `BaseCompressedFileFileSystem.info` by removing its overriding.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/3481/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/3481/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/2461
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/2461/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/2461/comments
https://api.github.com/repos/huggingface/datasets/issues/2461/events
https://github.com/huggingface/datasets/pull/2461
915,286,150
MDExOlB1bGxSZXF1ZXN0NjY1MTE3MTY4
2,461
Support sliced list arrays in cast
{ "avatar_url": "https://avatars.githubusercontent.com/u/42851186?v=4", "events_url": "https://api.github.com/users/lhoestq/events{/privacy}", "followers_url": "https://api.github.com/users/lhoestq/followers", "following_url": "https://api.github.com/users/lhoestq/following{/other_user}", "gists_url": "https://api.github.com/users/lhoestq/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/lhoestq", "id": 42851186, "login": "lhoestq", "node_id": "MDQ6VXNlcjQyODUxMTg2", "organizations_url": "https://api.github.com/users/lhoestq/orgs", "received_events_url": "https://api.github.com/users/lhoestq/received_events", "repos_url": "https://api.github.com/users/lhoestq/repos", "site_admin": false, "starred_url": "https://api.github.com/users/lhoestq/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/lhoestq/subscriptions", "type": "User", "url": "https://api.github.com/users/lhoestq" }
[]
closed
false
null
[]
null
[]
"2021-06-08T17:38:47Z"
"2021-06-08T17:56:24Z"
"2021-06-08T17:56:23Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/2461.diff", "html_url": "https://github.com/huggingface/datasets/pull/2461", "merged_at": "2021-06-08T17:56:23Z", "patch_url": "https://github.com/huggingface/datasets/pull/2461.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/2461" }
There is this issue in pyarrow: ```python import pyarrow as pa arr = pa.array([[i * 10] for i in range(4)]) arr.cast(pa.list_(pa.int32())) # works arr = arr.slice(1) arr.cast(pa.list_(pa.int32())) # fails # ArrowNotImplementedError("Casting sliced lists (non-zero offset) not yet implemented") ``` However in `Dataset.cast` we slice tables to cast their types (it's memory intensive), so we have the same issue. Because of this it is currently not possible to cast a Dataset with a Sequence feature type (unless the table is small enough to not be sliced). In this PR I fixed this by resetting the offset of `pyarrow.ListArray` arrays to zero in the table before casting. I used `pyarrow.compute.subtract` function to update the offsets of the ListArray. cc @abhi1thakur @SBrandeis
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 1, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 1, "url": "https://api.github.com/repos/huggingface/datasets/issues/2461/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/2461/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/5628
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5628/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5628/comments
https://api.github.com/repos/huggingface/datasets/issues/5628/events
https://github.com/huggingface/datasets/pull/5628
1,619,641,810
PR_kwDODunzps5LzVKi
5,628
add kwargs to index search
{ "avatar_url": "https://avatars.githubusercontent.com/u/55560583?v=4", "events_url": "https://api.github.com/users/SaulLu/events{/privacy}", "followers_url": "https://api.github.com/users/SaulLu/followers", "following_url": "https://api.github.com/users/SaulLu/following{/other_user}", "gists_url": "https://api.github.com/users/SaulLu/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/SaulLu", "id": 55560583, "login": "SaulLu", "node_id": "MDQ6VXNlcjU1NTYwNTgz", "organizations_url": "https://api.github.com/users/SaulLu/orgs", "received_events_url": "https://api.github.com/users/SaulLu/received_events", "repos_url": "https://api.github.com/users/SaulLu/repos", "site_admin": false, "starred_url": "https://api.github.com/users/SaulLu/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SaulLu/subscriptions", "type": "User", "url": "https://api.github.com/users/SaulLu" }
[]
closed
false
null
[]
null
[ "_The documentation is not available anymore as the PR was closed or merged._" ]
"2023-03-10T21:24:58Z"
"2023-03-15T14:48:47Z"
"2023-03-15T14:46:04Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/5628.diff", "html_url": "https://github.com/huggingface/datasets/pull/5628", "merged_at": "2023-03-15T14:46:04Z", "patch_url": "https://github.com/huggingface/datasets/pull/5628.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/5628" }
This PR proposes to add kwargs to index search methods. This is particularly useful for setting the timeout of a query on elasticsearch. A typical use case would be: ```python dset.add_elasticsearch_index("filename", es_client=es_client) scores, examples = dset.get_nearest_examples("filename", "my_name-train_29", request_timeout=60) ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 1, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 1, "url": "https://api.github.com/repos/huggingface/datasets/issues/5628/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5628/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/3893
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/3893/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/3893/comments
https://api.github.com/repos/huggingface/datasets/issues/3893/events
https://github.com/huggingface/datasets/pull/3893
1,166,551,684
PR_kwDODunzps40TmxB
3,893
Add default branch for doc building
{ "avatar_url": "https://avatars.githubusercontent.com/u/35901082?v=4", "events_url": "https://api.github.com/users/sgugger/events{/privacy}", "followers_url": "https://api.github.com/users/sgugger/followers", "following_url": "https://api.github.com/users/sgugger/following{/other_user}", "gists_url": "https://api.github.com/users/sgugger/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sgugger", "id": 35901082, "login": "sgugger", "node_id": "MDQ6VXNlcjM1OTAxMDgy", "organizations_url": "https://api.github.com/users/sgugger/orgs", "received_events_url": "https://api.github.com/users/sgugger/received_events", "repos_url": "https://api.github.com/users/sgugger/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sgugger/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sgugger/subscriptions", "type": "User", "url": "https://api.github.com/users/sgugger" }
[]
closed
false
null
[]
null
[ "The docs for this PR live [here](https://moon-ci-docs.huggingface.co/docs/datasets/pr_3893). All of your documentation changes will be reflected on that endpoint.", "Yes! And when we discovered on the Transformers side that this check fails on the GitHub actions, we added a config attribute to have a default. Setting in Transformers fixed the issue of the doc being deployed to main, so porting the fix here too :-)" ]
"2022-03-11T15:24:27Z"
"2022-03-11T15:34:35Z"
"2022-03-11T15:34:34Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/3893.diff", "html_url": "https://github.com/huggingface/datasets/pull/3893", "merged_at": "2022-03-11T15:34:34Z", "patch_url": "https://github.com/huggingface/datasets/pull/3893.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/3893" }
Since other libraries use `main` as their default branch and it's now the standard default, you have to specify a different name in the doc config if you're using `master` like datasets (`doc-builder` tries to guess it, but in the job, we have weird checkout of merge commits so it doesn't always manage to get it right). This PR makes sure it will always use master for the dev doc (until you decide to switchto main)
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/3893/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/3893/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/1852
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/1852/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/1852/comments
https://api.github.com/repos/huggingface/datasets/issues/1852/events
https://github.com/huggingface/datasets/pull/1852
804,633,033
MDExOlB1bGxSZXF1ZXN0NTcwMzY3NTU1
1,852
Add Arabic Speech Corpus
{ "avatar_url": "https://avatars.githubusercontent.com/u/15667714?v=4", "events_url": "https://api.github.com/users/zaidalyafeai/events{/privacy}", "followers_url": "https://api.github.com/users/zaidalyafeai/followers", "following_url": "https://api.github.com/users/zaidalyafeai/following{/other_user}", "gists_url": "https://api.github.com/users/zaidalyafeai/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/zaidalyafeai", "id": 15667714, "login": "zaidalyafeai", "node_id": "MDQ6VXNlcjE1NjY3NzE0", "organizations_url": "https://api.github.com/users/zaidalyafeai/orgs", "received_events_url": "https://api.github.com/users/zaidalyafeai/received_events", "repos_url": "https://api.github.com/users/zaidalyafeai/repos", "site_admin": false, "starred_url": "https://api.github.com/users/zaidalyafeai/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/zaidalyafeai/subscriptions", "type": "User", "url": "https://api.github.com/users/zaidalyafeai" }
[]
closed
false
null
[]
null
[]
"2021-02-09T15:02:26Z"
"2021-02-11T10:18:55Z"
"2021-02-11T10:18:55Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/1852.diff", "html_url": "https://github.com/huggingface/datasets/pull/1852", "merged_at": "2021-02-11T10:18:54Z", "patch_url": "https://github.com/huggingface/datasets/pull/1852.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/1852" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 2, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 2, "url": "https://api.github.com/repos/huggingface/datasets/issues/1852/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/1852/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/4470
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/4470/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/4470/comments
https://api.github.com/repos/huggingface/datasets/issues/4470/events
https://github.com/huggingface/datasets/pull/4470
1,267,470,051
PR_kwDODunzps45dnYw
4,470
Reorder returned validation/test splits in script template
{ "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" }
[]
closed
false
null
[]
null
[ "_The documentation is not available anymore as the PR was closed or merged._" ]
"2022-06-10T12:21:13Z"
"2022-06-10T18:04:10Z"
"2022-06-10T17:54:50Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/4470.diff", "html_url": "https://github.com/huggingface/datasets/pull/4470", "merged_at": "2022-06-10T17:54:50Z", "patch_url": "https://github.com/huggingface/datasets/pull/4470.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/4470" }
null
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/4470/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/4470/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/5118
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5118/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5118/comments
https://api.github.com/repos/huggingface/datasets/issues/5118/events
https://github.com/huggingface/datasets/issues/5118
1,410,547,373
I_kwDODunzps5UEz6t
5,118
Installing `datasets` on M1 computers
{ "avatar_url": "https://avatars.githubusercontent.com/u/9879252?v=4", "events_url": "https://api.github.com/users/david1542/events{/privacy}", "followers_url": "https://api.github.com/users/david1542/followers", "following_url": "https://api.github.com/users/david1542/following{/other_user}", "gists_url": "https://api.github.com/users/david1542/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/david1542", "id": 9879252, "login": "david1542", "node_id": "MDQ6VXNlcjk4NzkyNTI=", "organizations_url": "https://api.github.com/users/david1542/orgs", "received_events_url": "https://api.github.com/users/david1542/received_events", "repos_url": "https://api.github.com/users/david1542/repos", "site_admin": false, "starred_url": "https://api.github.com/users/david1542/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/david1542/subscriptions", "type": "User", "url": "https://api.github.com/users/david1542" }
[ { "color": "d73a4a", "default": true, "description": "Something isn't working", "id": 1935892857, "name": "bug", "node_id": "MDU6TGFiZWwxOTM1ODkyODU3", "url": "https://api.github.com/repos/huggingface/datasets/labels/bug" } ]
closed
false
{ "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" } ]
null
[ "Thanks for reporting, @david1542." ]
"2022-10-16T16:50:08Z"
"2022-10-19T09:10:08Z"
"2022-10-19T09:10:08Z"
CONTRIBUTOR
null
null
null
## Describe the bug I wanted to install `datasets` dependencies on my M1 (in order to start contributing to the project). However, I got an error regarding `tensorflow`. On M1, `tensorflow-macos` needs to be installed instead. Can we add a conditional requirement, so that `tensorflow-macos` would be installed on M1? ## Steps to reproduce the bug Fresh clone this project (on m1), create a virtualenv and run this: ```python pip install -e ".[dev]" ``` ## Expected results Installation should be smooth, and all the dependencies should be installed on M1. ## Actual results You should receive an error, saying pip couldn't find a version that matches this pattern: ``` tensorflow>=2.3,!=2.6.0,!=2.6.1 ``` ## Environment info <!-- You can run the command `datasets-cli env` and copy-and-paste its output below. --> - `datasets` version: 2.6.2.dev0 - Platform: macOS-12.6-arm64-arm-64bit - Python version: 3.9.6 - PyArrow version: 7.0.0 - Pandas version: 1.5.0
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/5118/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5118/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/5814
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5814/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5814/comments
https://api.github.com/repos/huggingface/datasets/issues/5814/events
https://github.com/huggingface/datasets/pull/5814
1,693,216,778
PR_kwDODunzps5PoOQ9
5,814
Repro windows crash
{ "avatar_url": "https://avatars.githubusercontent.com/u/106995444?v=4", "events_url": "https://api.github.com/users/maddiedawson/events{/privacy}", "followers_url": "https://api.github.com/users/maddiedawson/followers", "following_url": "https://api.github.com/users/maddiedawson/following{/other_user}", "gists_url": "https://api.github.com/users/maddiedawson/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/maddiedawson", "id": 106995444, "login": "maddiedawson", "node_id": "U_kgDOBmCe9A", "organizations_url": "https://api.github.com/users/maddiedawson/orgs", "received_events_url": "https://api.github.com/users/maddiedawson/received_events", "repos_url": "https://api.github.com/users/maddiedawson/repos", "site_admin": false, "starred_url": "https://api.github.com/users/maddiedawson/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/maddiedawson/subscriptions", "type": "User", "url": "https://api.github.com/users/maddiedawson" }
[]
open
false
null
[]
null
[ "The docs for this PR live [here](https://moon-ci-docs.huggingface.co/docs/datasets/pr_5814). All of your documentation changes will be reflected on that endpoint." ]
"2023-05-02T23:30:18Z"
"2023-05-02T23:47:07Z"
null
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/5814.diff", "html_url": "https://github.com/huggingface/datasets/pull/5814", "merged_at": null, "patch_url": "https://github.com/huggingface/datasets/pull/5814.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/5814" }
null
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/5814/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5814/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/3909
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/3909/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/3909/comments
https://api.github.com/repos/huggingface/datasets/issues/3909/events
https://github.com/huggingface/datasets/issues/3909
1,168,578,058
I_kwDODunzps5FpxYK
3,909
Error loading file audio when downloading the Common Voice dataset directly from the Hub
{ "avatar_url": "https://avatars.githubusercontent.com/u/30385910?v=4", "events_url": "https://api.github.com/users/aliceinland/events{/privacy}", "followers_url": "https://api.github.com/users/aliceinland/followers", "following_url": "https://api.github.com/users/aliceinland/following{/other_user}", "gists_url": "https://api.github.com/users/aliceinland/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/aliceinland", "id": 30385910, "login": "aliceinland", "node_id": "MDQ6VXNlcjMwMzg1OTEw", "organizations_url": "https://api.github.com/users/aliceinland/orgs", "received_events_url": "https://api.github.com/users/aliceinland/received_events", "repos_url": "https://api.github.com/users/aliceinland/repos", "site_admin": false, "starred_url": "https://api.github.com/users/aliceinland/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/aliceinland/subscriptions", "type": "User", "url": "https://api.github.com/users/aliceinland" }
[ { "color": "d73a4a", "default": true, "description": "Something isn't working", "id": 1935892857, "name": "bug", "node_id": "MDU6TGFiZWwxOTM1ODkyODU3", "url": "https://api.github.com/repos/huggingface/datasets/labels/bug" } ]
closed
false
null
[]
null
[ "Hi ! It could an issue with torchaudio, which version of torchaudio are you using ? Can you also try updating `datasets` to 2.0.0 and see if it works ?", "I _might_ have a similar issue. I'm trying to use the librispeech_asr dataset and read it with soundfile.\r\n\r\n```python\r\nfrom datasets import load_dataset, load_metric\r\nfrom transformers import Speech2TextForConditionalGeneration, Speech2TextProcessor\r\nimport soundfile as sf\r\n\r\nlibrispeech_eval = load_dataset(\"librispeech_asr\", \"clean\", split=\"test\") # change to \"other\" for other test dataset\r\nwer = load_metric(\"wer\")\r\n\r\nmodel = Speech2TextForConditionalGeneration.from_pretrained(\"facebook/s2t-small-librispeech-asr\").to(\"cuda\")\r\nprocessor = Speech2TextProcessor.from_pretrained(\"facebook/s2t-small-librispeech-asr\", do_upper_case=True)\r\n\r\ndef map_to_array(batch):\r\n speech, _ = sf.read(batch[\"file\"])\r\n batch[\"speech\"] = speech\r\n return batch\r\n\r\nlibrispeech_eval = librispeech_eval.map(map_to_array)\r\n\r\ndef map_to_pred(batch):\r\n features = processor(batch[\"speech\"], sampling_rate=16000, padding=True, return_tensors=\"pt\")\r\n input_features = features.input_features.to(\"cuda\")\r\n attention_mask = features.attention_mask.to(\"cuda\")\r\n\r\n gen_tokens = model.generate(input_ids=input_features, attention_mask=attention_mask)\r\n batch[\"transcription\"] = processor.batch_decode(gen_tokens, skip_special_tokens=True)\r\n return batch\r\n\r\nresult = librispeech_eval.map(map_to_pred, batched=True, batch_size=8, remove_columns=[\"speech\"])\r\n\r\nprint(\"WER:\", wer(predictions=result[\"transcription\"], references=result[\"text\"]))\r\n```\r\n\r\nThe code is taken directly from \"https://huggingface.co/facebook/s2t-small-librispeech-asr\".\r\n\r\nThe short error code is \"RuntimeError: Error opening '6930-75918-0000.flac': System error.\" (it can't find the first file), and I agree, I can't find the file either. The dataset has downloaded correctly (it says), but on the location, there are only \".arrow\" files, no \".flac\" files.\r\n\r\n**Error message:**\r\n\r\n```python\r\nRuntimeError Traceback (most recent call last)\r\nInput In [15], in <cell line: 16>()\r\n 13 batch[\"speech\"] = speech\r\n 14 return batch\r\n---> 16 librispeech_eval = librispeech_eval.map(map_to_array)\r\n 18 def map_to_pred(batch):\r\n 19 features = processor(batch[\"speech\"], sampling_rate=16000, padding=True, return_tensors=\"pt\")\r\n\r\nFile C:\\ProgramData\\Miniconda3\\envs\\noise_cancel\\lib\\site-packages\\datasets\\arrow_dataset.py:1953, in Dataset.map(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, num_proc, suffix_template, new_fingerprint, desc)\r\n 1950 disable_tqdm = not logging.is_progress_bar_enabled()\r\n 1952 if num_proc is None or num_proc == 1:\r\n-> 1953 return self._map_single(\r\n 1954 function=function,\r\n 1955 with_indices=with_indices,\r\n 1956 with_rank=with_rank,\r\n 1957 input_columns=input_columns,\r\n 1958 batched=batched,\r\n 1959 batch_size=batch_size,\r\n 1960 drop_last_batch=drop_last_batch,\r\n 1961 remove_columns=remove_columns,\r\n 1962 keep_in_memory=keep_in_memory,\r\n 1963 load_from_cache_file=load_from_cache_file,\r\n 1964 cache_file_name=cache_file_name,\r\n 1965 writer_batch_size=writer_batch_size,\r\n 1966 features=features,\r\n 1967 disable_nullable=disable_nullable,\r\n 1968 fn_kwargs=fn_kwargs,\r\n 1969 new_fingerprint=new_fingerprint,\r\n 1970 disable_tqdm=disable_tqdm,\r\n 1971 desc=desc,\r\n 1972 )\r\n 1973 else:\r\n 1975 def format_cache_file_name(cache_file_name, rank):\r\n\r\nFile C:\\ProgramData\\Miniconda3\\envs\\noise_cancel\\lib\\site-packages\\datasets\\arrow_dataset.py:519, in transmit_tasks.<locals>.wrapper(*args, **kwargs)\r\n 517 self: \"Dataset\" = kwargs.pop(\"self\")\r\n 518 # apply actual function\r\n--> 519 out: Union[\"Dataset\", \"DatasetDict\"] = func(self, *args, **kwargs)\r\n 520 datasets: List[\"Dataset\"] = list(out.values()) if isinstance(out, dict) else [out]\r\n 521 for dataset in datasets:\r\n 522 # Remove task templates if a column mapping of the template is no longer valid\r\n\r\nFile C:\\ProgramData\\Miniconda3\\envs\\noise_cancel\\lib\\site-packages\\datasets\\arrow_dataset.py:486, in transmit_format.<locals>.wrapper(*args, **kwargs)\r\n 479 self_format = {\r\n 480 \"type\": self._format_type,\r\n 481 \"format_kwargs\": self._format_kwargs,\r\n 482 \"columns\": self._format_columns,\r\n 483 \"output_all_columns\": self._output_all_columns,\r\n 484 }\r\n 485 # apply actual function\r\n--> 486 out: Union[\"Dataset\", \"DatasetDict\"] = func(self, *args, **kwargs)\r\n 487 datasets: List[\"Dataset\"] = list(out.values()) if isinstance(out, dict) else [out]\r\n 488 # re-apply format to the output\r\n\r\nFile C:\\ProgramData\\Miniconda3\\envs\\noise_cancel\\lib\\site-packages\\datasets\\fingerprint.py:458, in fingerprint_transform.<locals>._fingerprint.<locals>.wrapper(*args, **kwargs)\r\n 452 kwargs[fingerprint_name] = update_fingerprint(\r\n 453 self._fingerprint, transform, kwargs_for_fingerprint\r\n 454 )\r\n 456 # Call actual function\r\n--> 458 out = func(self, *args, **kwargs)\r\n 460 # Update fingerprint of in-place transforms + update in-place history of transforms\r\n 462 if inplace: # update after calling func so that the fingerprint doesn't change if the function fails\r\n\r\nFile C:\\ProgramData\\Miniconda3\\envs\\noise_cancel\\lib\\site-packages\\datasets\\arrow_dataset.py:2318, in Dataset._map_single(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, new_fingerprint, rank, offset, disable_tqdm, desc, cache_only)\r\n 2316 if not batched:\r\n 2317 for i, example in enumerate(pbar):\r\n-> 2318 example = apply_function_on_filtered_inputs(example, i, offset=offset)\r\n 2319 if update_data:\r\n 2320 if i == 0:\r\n\r\nFile C:\\ProgramData\\Miniconda3\\envs\\noise_cancel\\lib\\site-packages\\datasets\\arrow_dataset.py:2218, in Dataset._map_single.<locals>.apply_function_on_filtered_inputs(inputs, indices, check_same_num_examples, offset)\r\n 2216 if with_rank:\r\n 2217 additional_args += (rank,)\r\n-> 2218 processed_inputs = function(*fn_args, *additional_args, **fn_kwargs)\r\n 2219 if update_data is None:\r\n 2220 # Check if the function returns updated examples\r\n 2221 update_data = isinstance(processed_inputs, (Mapping, pa.Table))\r\n\r\nFile C:\\ProgramData\\Miniconda3\\envs\\noise_cancel\\lib\\site-packages\\datasets\\arrow_dataset.py:1913, in Dataset.map.<locals>.decorate.<locals>.decorated(item, *args, **kwargs)\r\n 1909 decorated_item = (\r\n 1910 Example(item, features=self.features) if not batched else Batch(item, features=self.features)\r\n 1911 )\r\n 1912 # Use the LazyDict internally, while mapping the function\r\n-> 1913 result = f(decorated_item, *args, **kwargs)\r\n 1914 # Return a standard dict\r\n 1915 return result.data if isinstance(result, LazyDict) else result\r\n\r\nInput In [15], in map_to_array(batch)\r\n 11 def map_to_array(batch):\r\n---> 12 speech, _ = sf.read(batch[\"file\"])\r\n 13 batch[\"speech\"] = speech\r\n 14 return batch\r\n\r\nFile C:\\ProgramData\\Miniconda3\\envs\\noise_cancel\\lib\\site-packages\\soundfile.py:256, in read(file, frames, start, stop, dtype, always_2d, fill_value, out, samplerate, channels, format, subtype, endian, closefd)\r\n 170 def read(file, frames=-1, start=0, stop=None, dtype='float64', always_2d=False,\r\n 171 fill_value=None, out=None, samplerate=None, channels=None,\r\n 172 format=None, subtype=None, endian=None, closefd=True):\r\n 173 \"\"\"Provide audio data from a sound file as NumPy array.\r\n 174 \r\n 175 By default, the whole file is read from the beginning, but the\r\n (...)\r\n 254 \r\n 255 \"\"\"\r\n--> 256 with SoundFile(file, 'r', samplerate, channels,\r\n 257 subtype, endian, format, closefd) as f:\r\n 258 frames = f._prepare_read(start, stop, frames)\r\n 259 data = f.read(frames, dtype, always_2d, fill_value, out)\r\n\r\nFile C:\\ProgramData\\Miniconda3\\envs\\noise_cancel\\lib\\site-packages\\soundfile.py:629, in SoundFile.__init__(self, file, mode, samplerate, channels, subtype, endian, format, closefd)\r\n 626 self._mode = mode\r\n 627 self._info = _create_info_struct(file, mode, samplerate, channels,\r\n 628 format, subtype, endian)\r\n--> 629 self._file = self._open(file, mode_int, closefd)\r\n 630 if set(mode).issuperset('r+') and self.seekable():\r\n 631 # Move write position to 0 (like in Python file objects)\r\n 632 self.seek(0)\r\n\r\nFile C:\\ProgramData\\Miniconda3\\envs\\noise_cancel\\lib\\site-packages\\soundfile.py:1183, in SoundFile._open(self, file, mode_int, closefd)\r\n 1181 else:\r\n 1182 raise TypeError(\"Invalid file: {0!r}\".format(self.name))\r\n-> 1183 _error_check(_snd.sf_error(file_ptr),\r\n 1184 \"Error opening {0!r}: \".format(self.name))\r\n 1185 if mode_int == _snd.SFM_WRITE:\r\n 1186 # Due to a bug in libsndfile version <= 1.0.25, frames != 0\r\n 1187 # when opening a named pipe in SFM_WRITE mode.\r\n 1188 # See http://github.com/erikd/libsndfile/issues/77.\r\n 1189 self._info.frames = 0\r\n\r\nFile C:\\ProgramData\\Miniconda3\\envs\\noise_cancel\\lib\\site-packages\\soundfile.py:1357, in _error_check(err, prefix)\r\n 1355 if err != 0:\r\n 1356 err_str = _snd.sf_error_number(err)\r\n-> 1357 raise RuntimeError(prefix + _ffi.string(err_str).decode('utf-8', 'replace'))\r\n\r\nRuntimeError: Error opening '6930-75918-0000.flac': System error.\r\n```\r\n\r\n**Package versions:**\r\n```python\r\npython: 3.9\r\ntransformers: 4.17.0\r\ndatasets: 2.0.0\r\nSoundFile: 0.10.3.post1\r\n```\r\n", "Hi ! In `datasets` 2.0 can access the audio array with `librispeech_eval[0][\"audio\"][\"array\"]` already, no need to use `map_to_array`. See our documentation on [how to process audio data](https://huggingface.co/docs/datasets/audio_process) :)\r\n\r\ncc @patrickvonplaten we will need to update the readme at [facebook/s2t-small-librispeech-asr](https://huggingface.co/facebook/s2t-small-librispeech-asr) as well as https://huggingface.co/docs/transformers/model_doc/speech_to_text", "Thanks!\r\n\r\nAnd sorry for posting this problem in what turned on to be an unrelated thread.\r\n\r\nI rewrote the code, and the model works. The WER is 0.137 however, so I'm not sure if I have missed a step. I will look further into that at a later point. The transcriptions look good through manual inspection.\r\n\r\nThe rewritten code:\r\n```python\r\nfrom datasets import load_dataset, load_metric\r\nfrom transformers import Speech2TextForConditionalGeneration, Speech2TextProcessor, Wav2Vec2Processor\r\n\r\nlibrispeech_eval = load_dataset(\"librispeech_asr\", \"clean\", split=\"test\") # change to \"other\" for other test dataset\r\nwer = load_metric(\"wer\")\r\n\r\nmodel = Speech2TextForConditionalGeneration.from_pretrained(\"facebook/s2t-small-librispeech-asr\").to(\"cuda\")\r\nprocessor = Speech2TextProcessor.from_pretrained(\"facebook/s2t-small-librispeech-asr\", do_upper_case=True)\r\n\r\ndef map_to_pred(batch):\r\n audio = batch[\"audio\"]\r\n features = processor(audio[\"array\"], sampling_rate=audio[\"sampling_rate\"], padding=True, return_tensors=\"pt\")\r\n input_features = features.input_features.to(\"cuda\")\r\n attention_mask = features.attention_mask.to(\"cuda\")\r\n\r\n gen_tokens = model.generate(input_features=input_features, attention_mask=attention_mask)\r\n batch[\"transcription\"] = processor.batch_decode(gen_tokens, skip_special_tokens=True)\r\n return batch\r\n\r\nresult = librispeech_eval.map(map_to_pred)#, batched=True, batch_size=8)\r\n\r\nprint(\"WER:\", wer.compute(predictions=result[\"transcription\"], references=result[\"text\"]))\r\n```", "I think the issue comes from the fact that you set `batched=False` while `map_to_pred` still returns a list of strings for \"transcription\". You can fix it by adding `[0]` at the end of this line to get the string:\r\n```python\r\nbatch[\"transcription\"] = processor.batch_decode(gen_tokens, skip_special_tokens=True)[0]\r\n```", "Updating as many model cards now as I can find", "https://github.com/huggingface/transformers/pull/16611", "We no longer use `torchaudio` for decoding MP3 files, and the problem with model cards has been addressed, so I'm closing this issue." ]
"2022-03-14T15:53:50Z"
"2023-03-02T15:31:27Z"
"2023-03-02T15:31:26Z"
NONE
null
null
null
## Describe the bug When loading the Common_Voice dataset, by downloading it directly from the Hugging Face hub, some files can not be opened. ## Steps to reproduce the bug ```python import torch import torchaudio from datasets import load_dataset, load_metric from transformers import Wav2Vec2ForCTC, Wav2Vec2Processor import re test_dataset = load_dataset("common_voice", "it", split="test") #test_dataset = load_dataset('csv', data_files = {'test': '/workspace/Dataset/Common_Voice/cv-corpus80/it/test.csv'}) wer = load_metric("wer") processor = Wav2Vec2Processor.from_pretrained("joorock12/wav2vec2-large-xlsr-italian") model = Wav2Vec2ForCTC.from_pretrained("joorock12/wav2vec2-large-xlsr-italian") model.to("cuda") chars_to_ignore_regex = '[\,\?\.\!\-\;\:\"\“\'\�]' resampler = torchaudio.transforms.Resample(48_000, 16_000) ``` ## Expected results The common voice dataset downloaded and correctly loaded whit the use of the hugging face datasets library. ## Actual results The error is: ```python 0ex [00:00, ?ex/s] --------------------------------------------------------------------------- RuntimeError Traceback (most recent call last) <ipython-input-48-ef87f4129e6e> in <module> 7 return batch 8 ----> 9 test_dataset = test_dataset.map(speech_file_to_array_fn) /opt/conda/lib/python3.8/site-packages/datasets/arrow_dataset.py in map(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, num_proc, suffix_template, new_fingerprint, desc) 2107 2108 if num_proc is None or num_proc == 1: -> 2109 return self._map_single( 2110 function=function, 2111 with_indices=with_indices, /opt/conda/lib/python3.8/site-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 516 self: "Dataset" = kwargs.pop("self") 517 # apply actual function --> 518 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 519 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 520 for dataset in datasets: /opt/conda/lib/python3.8/site-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 483 } 484 # apply actual function --> 485 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 486 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 487 # re-apply format to the output /opt/conda/lib/python3.8/site-packages/datasets/fingerprint.py in wrapper(*args, **kwargs) 411 # Call actual function 412 --> 413 out = func(self, *args, **kwargs) 414 415 # Update fingerprint of in-place transforms + update in-place history of transforms /opt/conda/lib/python3.8/site-packages/datasets/arrow_dataset.py in _map_single(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, new_fingerprint, rank, offset, disable_tqdm, desc, cache_only) 2465 if not batched: 2466 for i, example in enumerate(pbar): -> 2467 example = apply_function_on_filtered_inputs(example, i, offset=offset) 2468 if update_data: 2469 if i == 0: /opt/conda/lib/python3.8/site-packages/datasets/arrow_dataset.py in apply_function_on_filtered_inputs(inputs, indices, check_same_num_examples, offset) 2372 if with_rank: 2373 additional_args += (rank,) -> 2374 processed_inputs = function(*fn_args, *additional_args, **fn_kwargs) 2375 if update_data is None: 2376 # Check if the function returns updated examples /opt/conda/lib/python3.8/site-packages/datasets/arrow_dataset.py in decorated(item, *args, **kwargs) 2067 ) 2068 # Use the LazyDict internally, while mapping the function -> 2069 result = f(decorated_item, *args, **kwargs) 2070 # Return a standard dict 2071 return result.data if isinstance(result, LazyDict) else result <ipython-input-48-ef87f4129e6e> in speech_file_to_array_fn(batch) 3 def speech_file_to_array_fn(batch): 4 batch["sentence"] = re.sub(chars_to_ignore_regex, '', batch["sentence"]).lower() ----> 5 speech_array, sampling_rate = torchaudio.load(batch["path"]) 6 batch["speech"] = resampler(speech_array).squeeze().numpy() 7 return batch /opt/conda/lib/python3.8/site-packages/torchaudio/backend/sox_io_backend.py in load(filepath, frame_offset, num_frames, normalize, channels_first, format) 150 filepath, frame_offset, num_frames, normalize, channels_first, format) 151 filepath = os.fspath(filepath) --> 152 return torch.ops.torchaudio.sox_io_load_audio_file( 153 filepath, frame_offset, num_frames, normalize, channels_first, format) 154 RuntimeError: Error loading audio file: failed to open file common_voice_it_17415776.mp3 ``` ## Environment info - `datasets` version: 1.18.4 - Platform: Linux-5.4.0-x86_64-with-glibc2.10 - Python version: 3.8.5 - PyArrow version: 7.0.0
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/3909/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/3909/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/2322
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/2322/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/2322/comments
https://api.github.com/repos/huggingface/datasets/issues/2322/events
https://github.com/huggingface/datasets/issues/2322
876,383,853
MDU6SXNzdWU4NzYzODM4NTM=
2,322
Calls to map are not cached.
{ "avatar_url": "https://avatars.githubusercontent.com/u/2743060?v=4", "events_url": "https://api.github.com/users/villmow/events{/privacy}", "followers_url": "https://api.github.com/users/villmow/followers", "following_url": "https://api.github.com/users/villmow/following{/other_user}", "gists_url": "https://api.github.com/users/villmow/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/villmow", "id": 2743060, "login": "villmow", "node_id": "MDQ6VXNlcjI3NDMwNjA=", "organizations_url": "https://api.github.com/users/villmow/orgs", "received_events_url": "https://api.github.com/users/villmow/received_events", "repos_url": "https://api.github.com/users/villmow/repos", "site_admin": false, "starred_url": "https://api.github.com/users/villmow/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/villmow/subscriptions", "type": "User", "url": "https://api.github.com/users/villmow" }
[ { "color": "d73a4a", "default": true, "description": "Something isn't working", "id": 1935892857, "name": "bug", "node_id": "MDU6TGFiZWwxOTM1ODkyODU3", "url": "https://api.github.com/repos/huggingface/datasets/labels/bug" } ]
closed
false
null
[]
null
[ "I tried upgrading to `datasets==1.6.2` and downgrading to `1.6.0`. Both versions produce the same output.\r\n\r\nDowngrading to `1.5.0` works and produces the following output for me:\r\n\r\n```bash\r\nDownloading: 9.20kB [00:00, 3.94MB/s] \r\nDownloading: 5.99kB [00:00, 3.29MB/s] \r\nNo config specified, defaulting to: sst/default\r\nDownloading and preparing dataset sst/default (download: 6.83 MiB, generated: 3.73 MiB, post-processed: Unknown size, total: 10.56 MiB) to /home/johannes/.cache/huggingface/datasets/sst/default/1.0.0/a16a45566b63b2c3179e6c1d0f8edadde56e45570ee8cf99394fbb738491d34b...\r\n Dataset sst downloaded and prepared to /home/johannes/.cache/huggingface/datasets/sst/default/1.0.0/a16a45566b63b2c3179e6c1d0f8edadde56e45570ee8cf99394fbb738491d34b. Subsequent calls will reuse this data.\r\nexecuted [0, 1]\r\n#0: 0%| | 0/5 [00:00<?, ?ba/s]\r\n#1: 0%| | 0/5 [00:00<?, ?ba/s]\r\nexecuted [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]\r\nexecuted [4272, 4273, 4274, 4275, 4276, 4277, 4278, 4279, 4280, 4281]\r\nexecuted [1000, 1001, 1002, 1003, 1004, 1005, 1006, 1007, 1008, 1009]\r\nexecuted [5272, 5273, 5274, 5275, 5276, 5277, 5278, 5279, 5280, 5281]\r\nexecuted [2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009]\r\nexecuted [6272, 6273, 6274, 6275, 6276, 6277, 6278, 6279, 6280, 6281]\r\nexecuted [3000, 3001, 3002, 3003, 3004, 3005, 3006, 3007, 3008, 3009]\r\nexecuted [7272, 7273, 7274, 7275, 7276, 7277, 7278, 7279, 7280, 7281]\r\nexecuted [4000, 4001, 4002, 4003, 4004, 4005, 4006, 4007, 4008, 4009]\r\n#0: 100%|██████████| 5/5 [00:00<00:00, 94.83ba/s]\r\nexecuted [8272, 8273, 8274, 8275, 8276, 8277, 8278, 8279, 8280, 8281]\r\n#1: 100%|██████████| 5/5 [00:00<00:00, 92.75ba/s]\r\nexecuted [0, 1]\r\n#0: 0%| | 0/1 [00:00<?, ?ba/s]\r\n#1: 0%| | 0/1 [00:00<?, ?ba/s]\r\nexecuted [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]\r\nexecuted [551, 552, 553, 554, 555, 556, 557, 558, 559, 560]\r\n#0: 100%|██████████| 1/1 [00:00<00:00, 118.81ba/s]\r\n#1: 100%|██████████| 1/1 [00:00<00:00, 123.06ba/s]\r\nexecuted [0, 1]\r\n#0: 0%| | 0/2 [00:00<?, ?ba/s]\r\n#1: 0%| | 0/2 [00:00<?, ?ba/s]\r\nexecuted [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]\r\nexecuted [1105, 1106, 1107, 1108, 1109, 1110, 1111, 1112, 1113, 1114]\r\nexecuted [1000, 1001, 1002, 1003, 1004, 1005, 1006, 1007, 1008, 1009]\r\n#0: 100%|██████████| 2/2 [00:00<00:00, 119.42ba/s]\r\nexecuted [2105, 2106, 2107, 2108, 2109, 2110, 2111, 2112, 2113, 2114]\r\n#1: 100%|██████████| 2/2 [00:00<00:00, 123.33ba/s]\r\n\r\n\r\n\r\n ############################## \r\n\r\n\r\n\r\nexecuted [0, 1]\r\nLoading cached processed dataset at /home/johannes/.cache/huggingface/datasets/sst/default/1.0.0/a16a45566b63b2c3179e6c1d0f8edadde56e45570ee8cf99394fbb738491d34b/cache-6079777aa097c8f8.arrow\r\nLoading cached processed dataset at /home/johannes/.cache/huggingface/datasets/sst/default/1.0.0/a16a45566b63b2c3179e6c1d0f8edadde56e45570ee8cf99394fbb738491d34b/cache-2dc05c46f68eda6e.arrow\r\nexecuted [0, 1]\r\nLoading cached processed dataset at /home/johannes/.cache/huggingface/datasets/sst/default/1.0.0/a16a45566b63b2c3179e6c1d0f8edadde56e45570ee8cf99394fbb738491d34b/cache-1ca347e7430b98f1.arrow\r\nLoading cached processed dataset at /home/johannes/.cache/huggingface/datasets/sst/default/1.0.0/a16a45566b63b2c3179e6c1d0f8edadde56e45570ee8cf99394fbb738491d34b/cache-c0f1a73ce3ba40cd.arrow\r\nexecuted [0, 1]\r\nLoading cached processed dataset at /home/johannes/.cache/huggingface/datasets/sst/default/1.0.0/a16a45566b63b2c3179e6c1d0f8edadde56e45570ee8cf99394fbb738491d34b/cache-832a1407bf1ac5b7.arrow\r\nLoading cached processed dataset at /home/johannes/.cache/huggingface/datasets/sst/default/1.0.0/a16a45566b63b2c3179e6c1d0f8edadde56e45570ee8cf99394fbb738491d34b/cache-036316a259b773c4.arrow\r\n- Datasets: 1.5.0\r\n- Python: 3.8.3 (default, May 19 2020, 18:47:26) \r\n[GCC 7.3.0]\r\n- Platform: Linux-5.4.0-72-generic-x86_64-with-glibc2.10\r\n```", "Hi,\r\n\r\nset `keep_in_memory` to False when loading a dataset (`sst = load_dataset(\"sst\", keep_in_memory=False)`) to prevent it from loading in-memory. Currently, in-memory datasets fail to find cached files due to this check (always False for them):\r\n\r\nhttps://github.com/huggingface/datasets/blob/241a0b4a3a868778ee91e767ad406f9da7610df2/src/datasets/arrow_dataset.py#L1718\r\n\r\n@albertvillanova It seems like this behavior was overlooked in #2182.\r\n\r\n", "Hi @villmow, thanks for reporting. \r\n\r\nAs @mariosasko has pointed out, we did not consider this case when introducing the feature of automatic in-memory for small datasets. This needs to be fixed.", "Hi ! Currently a dataset that is in memory doesn't know doesn't know in which directory it has to read/write cache files.\r\nOn the other hand, a dataset that loaded from the disk (via memory mapping) uses the directory from which the dataset is located to read/write cache files.\r\n\r\nBecause of that, currently in-memory datasets simply don't use caching.\r\n\r\nMaybe a Dataset object could have a `cache_dir` that is set to the directory where the arrow files are created during `load_dataset` ?", "Fixed once reverted the default in-memory feature:\r\nClosed by #2460 (to close issue #2458).", "Please @villmow, feel free to update to `Datasets` latest version (1.8)." ]
"2021-05-05T12:11:27Z"
"2021-06-08T19:10:02Z"
"2021-06-08T19:08:21Z"
NONE
null
null
null
## Describe the bug Somehow caching does not work for me anymore. Am I doing something wrong, or is there anything that I missed? ## Steps to reproduce the bug ```python import datasets datasets.set_caching_enabled(True) sst = datasets.load_dataset("sst") def foo(samples, i): print("executed", i[:10]) return samples # first call x = sst.map(foo, batched=True, with_indices=True, num_proc=2) print('\n'*3, "#" * 30, '\n'*3) # second call y = sst.map(foo, batched=True, with_indices=True, num_proc=2) # print version import sys import platform print(f""" - Datasets: {datasets.__version__} - Python: {sys.version} - Platform: {platform.platform()} """) ``` ## Actual results This code prints the following output for me: ```bash No config specified, defaulting to: sst/default Reusing dataset sst (/home/johannes/.cache/huggingface/datasets/sst/default/1.0.0/b8a7889ef01c5d3ae8c379b84cc4080f8aad3ac2bc538701cbe0ac6416fb76ff) #0: 0%| | 0/5 [00:00<?, ?ba/s] #1: 0%| | 0/5 [00:00<?, ?ba/s] executed [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] executed [4272, 4273, 4274, 4275, 4276, 4277, 4278, 4279, 4280, 4281] executed [1000, 1001, 1002, 1003, 1004, 1005, 1006, 1007, 1008, 1009] executed [5272, 5273, 5274, 5275, 5276, 5277, 5278, 5279, 5280, 5281] executed [2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009] executed [6272, 6273, 6274, 6275, 6276, 6277, 6278, 6279, 6280, 6281] executed [3000, 3001, 3002, 3003, 3004, 3005, 3006, 3007, 3008, 3009] executed [7272, 7273, 7274, 7275, 7276, 7277, 7278, 7279, 7280, 7281] executed [4000, 4001, 4002, 4003, 4004, 4005, 4006, 4007, 4008, 4009] #0: 100%|██████████| 5/5 [00:00<00:00, 59.85ba/s] executed [8272, 8273, 8274, 8275, 8276, 8277, 8278, 8279, 8280, 8281] #1: 100%|██████████| 5/5 [00:00<00:00, 60.85ba/s] #0: 0%| | 0/1 [00:00<?, ?ba/s] #1: 0%| | 0/1 [00:00<?, ?ba/s]executed [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] #0: 100%|██████████| 1/1 [00:00<00:00, 69.32ba/s] executed [551, 552, 553, 554, 555, 556, 557, 558, 559, 560] #1: 100%|██████████| 1/1 [00:00<00:00, 70.93ba/s] #0: 0%| | 0/2 [00:00<?, ?ba/s] #1: 0%| | 0/2 [00:00<?, ?ba/s]executed [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] executed [1000, 1001, 1002, 1003, 1004, 1005, 1006, 1007, 1008, 1009] #0: 100%|██████████| 2/2 [00:00<00:00, 63.25ba/s] executed [1105, 1106, 1107, 1108, 1109, 1110, 1111, 1112, 1113, 1114] executed [2105, 2106, 2107, 2108, 2109, 2110, 2111, 2112, 2113, 2114] #1: 100%|██████████| 2/2 [00:00<00:00, 57.69ba/s] ############################## #0: 0%| | 0/5 [00:00<?, ?ba/s] #1: 0%| | 0/5 [00:00<?, ?ba/s] executed [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] executed [4272, 4273, 4274, 4275, 4276, 4277, 4278, 4279, 4280, 4281] executed [1000, 1001, 1002, 1003, 1004, 1005, 1006, 1007, 1008, 1009] executed [5272, 5273, 5274, 5275, 5276, 5277, 5278, 5279, 5280, 5281] executed [2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009] executed [6272, 6273, 6274, 6275, 6276, 6277, 6278, 6279, 6280, 6281] executed [3000, 3001, 3002, 3003, 3004, 3005, 3006, 3007, 3008, 3009] executed [4000, 4001, 4002, 4003, 4004, 4005, 4006, 4007, 4008, 4009] #0: 100%|██████████| 5/5 [00:00<00:00, 58.10ba/s] executed [7272, 7273, 7274, 7275, 7276, 7277, 7278, 7279, 7280, 7281] executed [8272, 8273, 8274, 8275, 8276, 8277, 8278, 8279, 8280, 8281] #1: 100%|██████████| 5/5 [00:00<00:00, 57.19ba/s] #0: 0%| | 0/1 [00:00<?, ?ba/s] #1: 0%| | 0/1 [00:00<?, ?ba/s] executed [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] #0: 100%|██████████| 1/1 [00:00<00:00, 60.10ba/s] executed [551, 552, 553, 554, 555, 556, 557, 558, 559, 560] #1: 100%|██████████| 1/1 [00:00<00:00, 53.82ba/s] #0: 0%| | 0/2 [00:00<?, ?ba/s] #1: 0%| | 0/2 [00:00<?, ?ba/s] executed [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] executed [1000, 1001, 1002, 1003, 1004, 1005, 1006, 1007, 1008, 1009] executed [1105, 1106, 1107, 1108, 1109, 1110, 1111, 1112, 1113, 1114] #0: 100%|██████████| 2/2 [00:00<00:00, 72.76ba/s] executed [2105, 2106, 2107, 2108, 2109, 2110, 2111, 2112, 2113, 2114] #1: 100%|██████████| 2/2 [00:00<00:00, 71.55ba/s] - Datasets: 1.6.1 - Python: 3.8.3 (default, May 19 2020, 18:47:26) [GCC 7.3.0] - Platform: Linux-5.4.0-72-generic-x86_64-with-glibc2.10 ``` ## Expected results Caching should work.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/2322/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/2322/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/4678
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/4678/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/4678/comments
https://api.github.com/repos/huggingface/datasets/issues/4678/events
https://github.com/huggingface/datasets/issues/4678
1,303,741,432
I_kwDODunzps5NtYP4
4,678
Cant pass streaming dataset to dataloader after take()
{ "avatar_url": "https://avatars.githubusercontent.com/u/39166683?v=4", "events_url": "https://api.github.com/users/zankner/events{/privacy}", "followers_url": "https://api.github.com/users/zankner/followers", "following_url": "https://api.github.com/users/zankner/following{/other_user}", "gists_url": "https://api.github.com/users/zankner/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/zankner", "id": 39166683, "login": "zankner", "node_id": "MDQ6VXNlcjM5MTY2Njgz", "organizations_url": "https://api.github.com/users/zankner/orgs", "received_events_url": "https://api.github.com/users/zankner/received_events", "repos_url": "https://api.github.com/users/zankner/repos", "site_admin": false, "starred_url": "https://api.github.com/users/zankner/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/zankner/subscriptions", "type": "User", "url": "https://api.github.com/users/zankner" }
[ { "color": "d73a4a", "default": true, "description": "Something isn't working", "id": 1935892857, "name": "bug", "node_id": "MDU6TGFiZWwxOTM1ODkyODU3", "url": "https://api.github.com/repos/huggingface/datasets/labels/bug" } ]
open
false
null
[]
null
[ "Hi! Calling `take` on an iterable/streamable dataset makes it not possible to shard the dataset, which in turn disables multi-process loading (attempts to split the workload over the shards), so to go past this limitation, you can either use single-process loading in `DataLoader` (`num_workers=None`) or fetch the first `50_000/batch_size` batches in the loop." ]
"2022-07-13T17:34:18Z"
"2022-07-14T13:07:21Z"
null
NONE
null
null
null
## Describe the bug I am trying to pass a streaming version of c4 to a dataloader, but it can't be passed after I call `dataset.take(n)`. Some functions such as `shuffle()` can be applied without breaking the dataloader but not take. ## Steps to reproduce the bug ```python import datasets import torch dset = datasets.load_dataset(path='c4', name='en', split="train", streaming=True) dset = dset.take(50_000) dset = dset.with_format("torch") num_workers = 8 batch_size = 512 loader = torch.utils.data.DataLoader(dataset=dset, batch_size=batch_size, num_workers=num_workers) for batch in loader: ... ``` ## Expected results No error thrown when iterating over the dataloader ## Actual results Original Traceback (most recent call last): File "/usr/local/lib/python3.9/dist-packages/torch/utils/data/_utils/worker.py", line 287, in _worker_loop data = fetcher.fetch(index) File "/usr/local/lib/python3.9/dist-packages/torch/utils/data/_utils/fetch.py", line 32, in fetch data.append(next(self.dataset_iter)) File "/root/.local/lib/python3.9/site-packages/datasets/formatting/dataset_wrappers/torch_iterable_dataset.py", line 48, in __iter__ for key, example in self._iter_shard(shard_idx): File "/root/.local/lib/python3.9/site-packages/datasets/iterable_dataset.py", line 586, in _iter_shard yield from ex_iterable.shard_data_sources(shard_idx) File "/root/.local/lib/python3.9/site-packages/datasets/iterable_dataset.py", line 60, in shard_data_sources raise NotImplementedError(f"{type(self)} doesn't implement shard_data_sources yet") NotImplementedError: <class 'datasets.iterable_dataset.TakeExamplesIterable'> doesn't implement shard_data_sources yet ## Environment info - `datasets` version: 2.3.2 - Platform: Linux-5.4.0-120-generic-x86_64-with-glibc2.31 - Python version: 3.9.13 - PyArrow version: 8.0.0 - Pandas version: 1.4.3
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 1, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 1, "url": "https://api.github.com/repos/huggingface/datasets/issues/4678/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/4678/timeline
null
null
false
https://api.github.com/repos/huggingface/datasets/issues/2687
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/2687/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/2687/comments
https://api.github.com/repos/huggingface/datasets/issues/2687/events
https://github.com/huggingface/datasets/pull/2687
948,890,481
MDExOlB1bGxSZXF1ZXN0NjkzNjY1NDI2
2,687
Minor documentation fix
{ "avatar_url": "https://avatars.githubusercontent.com/u/44175589?v=4", "events_url": "https://api.github.com/users/slowwavesleep/events{/privacy}", "followers_url": "https://api.github.com/users/slowwavesleep/followers", "following_url": "https://api.github.com/users/slowwavesleep/following{/other_user}", "gists_url": "https://api.github.com/users/slowwavesleep/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/slowwavesleep", "id": 44175589, "login": "slowwavesleep", "node_id": "MDQ6VXNlcjQ0MTc1NTg5", "organizations_url": "https://api.github.com/users/slowwavesleep/orgs", "received_events_url": "https://api.github.com/users/slowwavesleep/received_events", "repos_url": "https://api.github.com/users/slowwavesleep/repos", "site_admin": false, "starred_url": "https://api.github.com/users/slowwavesleep/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/slowwavesleep/subscriptions", "type": "User", "url": "https://api.github.com/users/slowwavesleep" }
[]
closed
false
null
[]
null
[]
"2021-07-20T17:43:23Z"
"2021-07-21T13:04:55Z"
"2021-07-21T13:04:55Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/2687.diff", "html_url": "https://github.com/huggingface/datasets/pull/2687", "merged_at": "2021-07-21T13:04:55Z", "patch_url": "https://github.com/huggingface/datasets/pull/2687.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/2687" }
Currently, [Writing a dataset loading script](https://huggingface.co/docs/datasets/add_dataset.html) page has a small error. A link to `matinf` dataset in [_Dataset scripts of reference_](https://huggingface.co/docs/datasets/add_dataset.html#dataset-scripts-of-reference) section actually leads to `xsquad`, instead. This PR fixes that.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/2687/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/2687/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/5842
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5842/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5842/comments
https://api.github.com/repos/huggingface/datasets/issues/5842/events
https://github.com/huggingface/datasets/issues/5842
1,705,510,602
I_kwDODunzps5lqAbK
5,842
Remove columns in interable dataset
{ "avatar_url": "https://avatars.githubusercontent.com/u/17240858?v=4", "events_url": "https://api.github.com/users/surya-narayanan/events{/privacy}", "followers_url": "https://api.github.com/users/surya-narayanan/followers", "following_url": "https://api.github.com/users/surya-narayanan/following{/other_user}", "gists_url": "https://api.github.com/users/surya-narayanan/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/surya-narayanan", "id": 17240858, "login": "surya-narayanan", "node_id": "MDQ6VXNlcjE3MjQwODU4", "organizations_url": "https://api.github.com/users/surya-narayanan/orgs", "received_events_url": "https://api.github.com/users/surya-narayanan/received_events", "repos_url": "https://api.github.com/users/surya-narayanan/repos", "site_admin": false, "starred_url": "https://api.github.com/users/surya-narayanan/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/surya-narayanan/subscriptions", "type": "User", "url": "https://api.github.com/users/surya-narayanan" }
[]
closed
false
null
[]
null
[ "Transferring this issue as it's related to the 🤗 Datasets library ", "Hi @surya-narayanan! Could you provide some code snippet?", "This method has been recently added to the `IterableDataset`, so you need to update the `datasets`' installation (`pip install -U datasets`) to use it." ]
"2023-05-11T03:48:46Z"
"2023-06-21T16:36:42Z"
"2023-06-21T16:36:41Z"
NONE
null
null
null
### Feature request Right now, remove_columns() produces a NotImplementedError for iterable style datasets ### Motivation It would be great to have the same functionality irrespective of whether one is using an iterable or a map-style dataset ### Your contribution hope and courage.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/5842/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5842/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/6125
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/6125/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/6125/comments
https://api.github.com/repos/huggingface/datasets/issues/6125/events
https://github.com/huggingface/datasets/issues/6125
1,837,980,986
I_kwDODunzps5tjV06
6,125
Reinforcement Learning and Robotics are not task categories in HF datasets metadata
{ "avatar_url": "https://avatars.githubusercontent.com/u/35373228?v=4", "events_url": "https://api.github.com/users/StoneT2000/events{/privacy}", "followers_url": "https://api.github.com/users/StoneT2000/followers", "following_url": "https://api.github.com/users/StoneT2000/following{/other_user}", "gists_url": "https://api.github.com/users/StoneT2000/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/StoneT2000", "id": 35373228, "login": "StoneT2000", "node_id": "MDQ6VXNlcjM1MzczMjI4", "organizations_url": "https://api.github.com/users/StoneT2000/orgs", "received_events_url": "https://api.github.com/users/StoneT2000/received_events", "repos_url": "https://api.github.com/users/StoneT2000/repos", "site_admin": false, "starred_url": "https://api.github.com/users/StoneT2000/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/StoneT2000/subscriptions", "type": "User", "url": "https://api.github.com/users/StoneT2000" }
[]
closed
false
null
[]
null
[]
"2023-08-05T23:59:42Z"
"2023-08-18T12:28:42Z"
"2023-08-18T12:28:42Z"
NONE
null
null
null
### Describe the bug In https://huggingface.co/models there are task categories for RL and robotics but none in https://huggingface.co/datasets Our lab is currently moving our datasets over to hugging face and would like to be able to add those 2 tags Moreover we see some older datasets that do have that tag, but we can't seem to add it ourselves. ### Steps to reproduce the bug 1. Create a new dataset on Hugging face 2. Try to type reinforcemement-learning or robotics into the tasks categories, it does not allow you to commit ### Expected behavior Expected to be able to add RL and robotics as task categories as some previous datasets have these tags ### Environment info N/A
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/6125/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/6125/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/3493
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/3493/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/3493/comments
https://api.github.com/repos/huggingface/datasets/issues/3493/events
https://github.com/huggingface/datasets/pull/3493
1,089,967,286
PR_kwDODunzps4wVxfr
3,493
Fix VCTK encoding
{ "avatar_url": "https://avatars.githubusercontent.com/u/42851186?v=4", "events_url": "https://api.github.com/users/lhoestq/events{/privacy}", "followers_url": "https://api.github.com/users/lhoestq/followers", "following_url": "https://api.github.com/users/lhoestq/following{/other_user}", "gists_url": "https://api.github.com/users/lhoestq/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/lhoestq", "id": 42851186, "login": "lhoestq", "node_id": "MDQ6VXNlcjQyODUxMTg2", "organizations_url": "https://api.github.com/users/lhoestq/orgs", "received_events_url": "https://api.github.com/users/lhoestq/received_events", "repos_url": "https://api.github.com/users/lhoestq/repos", "site_admin": false, "starred_url": "https://api.github.com/users/lhoestq/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/lhoestq/subscriptions", "type": "User", "url": "https://api.github.com/users/lhoestq" }
[]
closed
false
null
[]
null
[]
"2021-12-28T15:23:36Z"
"2021-12-28T15:48:18Z"
"2021-12-28T15:48:17Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/3493.diff", "html_url": "https://github.com/huggingface/datasets/pull/3493", "merged_at": "2021-12-28T15:48:17Z", "patch_url": "https://github.com/huggingface/datasets/pull/3493.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/3493" }
utf-8 encoding was missing in the VCTK dataset builder added in #3351
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/3493/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/3493/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/5855
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5855/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5855/comments
https://api.github.com/repos/huggingface/datasets/issues/5855/events
https://github.com/huggingface/datasets/issues/5855
1,708,784,943
I_kwDODunzps5l2f0v
5,855
`to_tf_dataset` consumes too much memory
{ "avatar_url": "https://avatars.githubusercontent.com/u/28751760?v=4", "events_url": "https://api.github.com/users/massquantity/events{/privacy}", "followers_url": "https://api.github.com/users/massquantity/followers", "following_url": "https://api.github.com/users/massquantity/following{/other_user}", "gists_url": "https://api.github.com/users/massquantity/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/massquantity", "id": 28751760, "login": "massquantity", "node_id": "MDQ6VXNlcjI4NzUxNzYw", "organizations_url": "https://api.github.com/users/massquantity/orgs", "received_events_url": "https://api.github.com/users/massquantity/received_events", "repos_url": "https://api.github.com/users/massquantity/repos", "site_admin": false, "starred_url": "https://api.github.com/users/massquantity/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/massquantity/subscriptions", "type": "User", "url": "https://api.github.com/users/massquantity" }
[]
closed
false
null
[]
null
[ "Cc @amyeroberts @Rocketknight1 \r\n\r\nIndded I think it's because it does something like this under the hood when there's no multiprocessing:\r\n\r\n```python\r\ntf_dataset = tf_dataset.shuffle(len(dataset))\r\n```\r\n\r\nPS: with multiprocessing it appears to be different:\r\n\r\n```python\r\nindices = np.arange(len(dataset))\r\nif shuffle:\r\n np.random.shuffle(indices)\r\n```", "Hi @massquantity, the dataset being shuffled there is not the full dataset. If you look at [the line above](https://github.com/huggingface/datasets/blob/main/src/datasets/utils/tf_utils.py#L182), the dataset is actually just a single indices array at that point, and that array is the only thing that gets fully loaded into memory and shuffled. We then load samples from the dataset by applying a transform function to the shuffled dataset, which fetches samples based on the indices it receives.\r\n\r\nIf your dataset is **really** gigantic, then this index tensor might be a memory issue, but since it's just an int64 tensor it will only use 1GB of memory per 125 million samples.\r\n\r\nStill, if you're encountering memory issues, there might be another cause here - can you share some code to reproduce the error, or does it depend on some internal/proprietary dataset?", "Hi @Rocketknight1, you're right and I also noticed that only indices are used in shuffling. My data has shape (50000000, 10), but really the problem doesn't relate to a specific dataset. Simply running the following code costs me 10GB of memory.\r\n\r\n```python\r\nfrom datasets import Dataset\r\n\r\ndef gen():\r\n for i in range(50000000):\r\n yield {\"data\": i}\r\n\r\nds = Dataset.from_generator(gen, cache_dir=\"./huggingface\")\r\n\r\ntf_ds = ds.to_tf_dataset(\r\n batch_size=1,\r\n shuffle=True,\r\n drop_remainder=False,\r\n prefetch=True,\r\n)\r\ntf_ds = iter(tf_ds)\r\nnext(tf_ds)\r\n# {'data': <tf.Tensor: shape=(1,), dtype=int64, numpy=array([0])>}\r\n```\r\n\r\nI just realized maybe it was an issue from tensorflow (I'm using tf 2.12). So I tried the following code, and it used 10GB of memory too.\r\n```python\r\nimport numpy as np\r\nimport tensorflow as tf\r\n\r\ndata_size = 50000000\r\ntf_dataset = tf.data.Dataset.from_tensor_slices(np.arange(data_size))\r\ntf_dataset = iter(tf_dataset.shuffle(data_size))\r\nnext(tf_dataset)\r\n# <tf.Tensor: shape=(), dtype=int64, numpy=24774043>\r\n```\r\n\r\nBy the way, as @lhoestq mentioned, multiprocessing uses numpy shuffling, and it uses less than 1 GB of memory:\r\n```python\r\ntf_ds_mp = ds.to_tf_dataset(\r\n batch_size=1,\r\n shuffle=True,\r\n drop_remainder=False,\r\n prefetch=True,\r\n num_workers=2,\r\n)\r\n```", "Thanks for that reproduction script - I've confirmed the same issue is occurring for me. Investigating it now!", "Update: The memory usage is occurring in creation of the index and shuffle buffer. You can reproduce it very simply with:\r\n\r\n```python\r\nimport tensorflow as tf\r\nindices = tf.range(50_000_000, dtype=tf.int64)\r\ndataset = tf.data.Dataset.from_tensor_slices(indices)\r\ndataset = dataset.shuffle(len(dataset))\r\nprint(next(iter(dataset))\r\n```\r\nWhen I wrote this code I thought `tf.data` had an optimization for shuffling an entire tensor that wouldn't create the entire shuffle buffer, but evidently it's just creating the enormous buffer in memory. I'll see if I can find a more efficient way to do this - we might end up moving everything to the `numpy` multiprocessing path to avoid it.", "I opened a PR to fix this - will continue the discussion there!" ]
"2023-05-14T01:22:29Z"
"2023-06-08T16:32:52Z"
"2023-06-08T16:32:52Z"
NONE
null
null
null
### Describe the bug Hi, I'm using `to_tf_dataset` to convert a _large_ dataset to `tf.data.Dataset`. I observed that the data loading *before* training took a lot of time and memory, even with `batch_size=1`. After some digging, i believe the reason lies in the shuffle behavior. The [source code](https://github.com/huggingface/datasets/blob/main/src/datasets/utils/tf_utils.py#L185) uses `len(dataset)` as the `buffer_size`, which may load all the data into the memory, and the [tf.data doc](https://www.tensorflow.org/guide/data#randomly_shuffling_input_data) also states that "While large buffer_sizes shuffle more thoroughly, they can take a lot of memory, and significant time to fill". ### Steps to reproduce the bug ```python from datasets import Dataset def gen(): # some large data for i in range(50000000): yield {"data": i} ds = Dataset.from_generator(gen, cache_dir="./huggingface") tf_ds = ds.to_tf_dataset( batch_size=64, shuffle=False, # no shuffle drop_remainder=False, prefetch=True, ) # fast and memory friendly 🤗 for batch in tf_ds: ... tf_ds_shuffle = ds.to_tf_dataset( batch_size=64, shuffle=True, drop_remainder=False, prefetch=True, ) # slow and memory hungry for simple iteration 😱 for batch in tf_ds_shuffle: ... ``` ### Expected behavior Shuffling should not load all the data into the memory. Would adding a `buffer_size` parameter in the `to_tf_dataset` API alleviate the problem? ### Environment info - `datasets` version: 2.11.0 - Platform: Linux-5.17.1-051701-generic-x86_64-with-glibc2.17 - Python version: 3.8.13 - Huggingface_hub version: 0.13.4 - PyArrow version: 11.0.0 - Pandas version: 1.4.3
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/5855/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5855/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/5883
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5883/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5883/comments
https://api.github.com/repos/huggingface/datasets/issues/5883/events
https://github.com/huggingface/datasets/pull/5883
1,719,527,597
PR_kwDODunzps5RAkYi
5,883
Fix string-encoding, make `batch_size` optional, and minor improvements in `Dataset.to_tf_dataset`
{ "avatar_url": "https://avatars.githubusercontent.com/u/36760800?v=4", "events_url": "https://api.github.com/users/alvarobartt/events{/privacy}", "followers_url": "https://api.github.com/users/alvarobartt/followers", "following_url": "https://api.github.com/users/alvarobartt/following{/other_user}", "gists_url": "https://api.github.com/users/alvarobartt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/alvarobartt", "id": 36760800, "login": "alvarobartt", "node_id": "MDQ6VXNlcjM2NzYwODAw", "organizations_url": "https://api.github.com/users/alvarobartt/orgs", "received_events_url": "https://api.github.com/users/alvarobartt/received_events", "repos_url": "https://api.github.com/users/alvarobartt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/alvarobartt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/alvarobartt/subscriptions", "type": "User", "url": "https://api.github.com/users/alvarobartt" }
[]
closed
false
null
[]
null
[ "_The documentation is not available anymore as the PR was closed or merged._", "To showcase the current issue, here's a Colab Gist, that shows that the `imdb` dataset cannot be read/iterated, since one or more samples contain a non-ascii character that is being converted to `numpy.bytes_`, and so on fails.\r\n\r\nColab Gist at https://gist.github.com/alvarobartt/1746959d1abb9a33e0c593f3bd82a2fb\r\n\r\nAlso, here's a quick sample of what's happening:\r\n\r\n```python\r\nfrom datasets import load_dataset\r\n\r\nds = load_dataset(\"imdb\", split=\"train\")\r\ntfds = ds.to_tf_dataset(batch_size=16)\r\nfor batch in tfds:\r\n print(batch)\r\n>>> UnicodeEncodeError: 'ascii' codec can't encode character '\\xe9' in position 0: ordinal not in range(128)\r\n```\r\n\r\nA more detailed version of it:\r\n\r\n```python\r\nfrom datasets import Dataset\r\n\r\nds = Dataset.from_dict(\r\n {\r\n \"a\": [1],\r\n \"b\": [\"é\"],\r\n }\r\n)\r\ntfds = ds.to_tf_dataset(batch_size=1)\r\nfor batch in tfds:\r\n print(batch)\r\n>>> UnicodeEncodeError: 'ascii' codec can't encode character '\\xe9' in position 0: ordinal not in range(128)\r\n```\r\n\r\nThe original issue comes from https://github.com/tensorflow/tensorflow/blob/388d952114e59a1aeda440ed4737b29f8b7c6e8a/tensorflow/python/ops/script_ops.py#LL234C4-L234C4, which could easily be solved by replacing that line with `return result.astype(np.unicode_)` but they are mentioning that it may lead to issues.\r\n\r\nEven the following fails in `numpy`:\r\n\r\n```python\r\nimport numpy as np\r\n\r\nx = np.array([\"é\"]).astype(np.bytes_)\r\n```", "cc. @lhoestq :hugs:", "cc @Rocketknight1 ", "> Nice ! Could you add some tests to make sure that batch_size=None works as expected ?\r\n\r\nSure, I'll add the tests for everything, including the string-encoding issue to make sure it's solved!", "Thanks for the review @lhoestq and @Rocketknight1! I do understand that processing it in batches is always more efficient than processing it one-by-one, it was just to make `batch_size` optional. What we can do is default it to a certain batch size e.g. 16 as before, and that's it, but I think it can still remain optional.", "@Rocketknight1 then I'll add the integration tests for the optional `batch_size` as well as for the encoding of non-ASCII compatible characters 😄 Do we set the default `batch_size` to 16 instead of `None`?", "@alvarobartt I think 16 is a reasonable default, yep!", "I think default should be None, not 16.\r\nUsers won't expect to have it batched by default.", "Then I'll leave it as is, and add the unit/integration tests, thanks @Rocketknight1 and @lhoestq ", "Hi @Rocketknight1 @lhoestq! So the string-encoding issue is already solved, but I've got one doubt about the `batch_size` being optional in the multiprocessing approach, since in that case I assume the `batch_size` should be mandatory, for the moment I'm assuming it is/should be mandatory, but let me know if you want me to add a check to disallow `batch_size=None` when `num_workers>1`. Thanks!", "> To showcase the current issue, here's a Colab Gist, that shows that the `imdb` dataset cannot be read/iterated, since one or more samples contain a non-ascii character that is being converted to `numpy.bytes_`, and so on fails.\r\n> \r\n> Colab Gist at https://gist.github.com/alvarobartt/1746959d1abb9a33e0c593f3bd82a2fb\r\n\r\nI've used the Colab shared above for testing purposes, and it works fine, plus the unit/integration tests are passing. I've also trained a `KerasNLP` model with incoming data from 🤗`datasets` with no issue at all!", "> in the multiprocessing approach, since in that case I assume the batch_size should be mandatory,\r\n\r\nNo I think they're quite orthogonal, no need to have it mandatory", "> No I think they're quite orthogonal, no need to have it mandatory\r\n\r\nBut it will break if `batch_size=None` as the multiprocessing approach will aim to prepare batches and distribute those to every worker, and assuming `batch_size=1` when `batch_size=None` I guess is not a good assumption, right?", "Ah I see. Multiprocessing should support batch_size=None indeed. If you have ideas you can do it in this PR, or raise a NotImplementedError and we can see later", "Sure @lhoestq, I can add a `NotImplementedError` for the moment, and prepare the next PR straight-away to tackle the multiprocessing approach with `batch_size=None`, but not sure if that may eventually collide with @Rocketknight1 PR at https://github.com/huggingface/datasets/pull/5863", "Yes, let me merge the PR at #5863 after this one, and then we can open another to improve the behaviour with multiprocessing and `batch_size=None`!", "Sure @Rocketknight1 makes complete sense to me! Do you want me to add the `raise NotImplementedError` and then we merge this PR? Or you prefer to directly merge the current?", "`raise NotImplementedError` for now with an error telling the user that multiprocessing needs them to specify a batch size, I think!", "Since you recently approved @Rocketknight1, are we ready to merge? Thanks 🤗", "Ah actually it looks like `minimal_tf_collate_fn` doesn't support batch_size=None", "Hi @lhoestq so I didn't include the call to `collate_fn`, as we won't need to collate the incoming data e.g. \"str\" should remain a \"str\" not a [\"str\"], and the `minimal_collate_fn` was indeed putting everything into a list, so the output was not un-batched, but batched with size 1", "What if the user passes a collate_fn ? The torch DataLoader still applies it if batch_size=None for example.\r\n\r\nDoes my last change look of to you ? If so I think we can merge", "> What if the user passes a collate_fn ? The torch DataLoader still applies it if batch_size=None for example.\r\n> \r\n> Does my last change look of to you ? If so I think we can merge\r\n\r\nI think we're good, since it won't batch it under the scenario of `str` being provided instead of `List[str]`, and the unit/integration tests are passing, so I'm OK to merge. Maybe we can double check with Matt? cc @Rocketknight1 ", "Yes, and sorry for the delay! I'm happy to merge.", "<details>\n<summary>Show benchmarks</summary>\n\nPyArrow==8.0.0\n\n<details>\n<summary>Show updated benchmarks!</summary>\n\n### Benchmark: benchmark_array_xd.json\n\n| metric | read_batch_formatted_as_numpy after write_array2d | read_batch_formatted_as_numpy after write_flattened_sequence | read_batch_formatted_as_numpy after write_nested_sequence | read_batch_unformated after write_array2d | read_batch_unformated after write_flattened_sequence | read_batch_unformated after write_nested_sequence | read_col_formatted_as_numpy after write_array2d | read_col_formatted_as_numpy after write_flattened_sequence | read_col_formatted_as_numpy after write_nested_sequence | read_col_unformated after write_array2d | read_col_unformated after write_flattened_sequence | read_col_unformated after write_nested_sequence | read_formatted_as_numpy after write_array2d | read_formatted_as_numpy after write_flattened_sequence | read_formatted_as_numpy after write_nested_sequence | read_unformated after write_array2d | read_unformated after write_flattened_sequence | read_unformated after write_nested_sequence | write_array2d | write_flattened_sequence | write_nested_sequence |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.006555 / 0.011353 (-0.004798) | 0.004521 / 0.011008 (-0.006487) | 0.096633 / 0.038508 (0.058125) | 0.032859 / 0.023109 (0.009750) | 0.294632 / 0.275898 (0.018734) | 0.325140 / 0.323480 (0.001660) | 0.005676 / 0.007986 (-0.002310) | 0.005252 / 0.004328 (0.000924) | 0.074349 / 0.004250 (0.070099) | 0.045836 / 0.037052 (0.008784) | 0.302919 / 0.258489 (0.044430) | 0.340686 / 0.293841 (0.046845) | 0.028398 / 0.128546 (-0.100148) | 0.008942 / 0.075646 (-0.066704) | 0.326994 / 0.419271 (-0.092278) | 0.049556 / 0.043533 (0.006023) | 0.293883 / 0.255139 (0.038744) | 0.316522 / 0.283200 (0.033322) | 0.097385 / 0.141683 (-0.044298) | 1.405334 / 1.452155 (-0.046821) | 1.521529 / 1.492716 (0.028812) |\n\n### Benchmark: benchmark_getitem\\_100B.json\n\n| metric | get_batch_of\\_1024\\_random_rows | get_batch_of\\_1024\\_rows | get_first_row | get_last_row |\n|--------|---|---|---|---|\n| new / old (diff) | 0.212269 / 0.018006 (0.194263) | 0.445692 / 0.000490 (0.445203) | 0.004930 / 0.000200 (0.004730) | 0.000093 / 0.000054 (0.000039) |\n\n### Benchmark: benchmark_indices_mapping.json\n\n| metric | select | shard | shuffle | sort | train_test_split |\n|--------|---|---|---|---|---|\n| new / old (diff) | 0.026907 / 0.037411 (-0.010504) | 0.108607 / 0.014526 (0.094081) | 0.116806 / 0.176557 (-0.059751) | 0.178428 / 0.737135 (-0.558707) | 0.122326 / 0.296338 (-0.174012) |\n\n### Benchmark: benchmark_iterating.json\n\n| metric | read 5000 | read 50000 | read_batch 50000 10 | read_batch 50000 100 | read_batch 50000 1000 | read_formatted numpy 5000 | read_formatted pandas 5000 | read_formatted tensorflow 5000 | read_formatted torch 5000 | read_formatted_batch numpy 5000 10 | read_formatted_batch numpy 5000 1000 | shuffled read 5000 | shuffled read 50000 | shuffled read_batch 50000 10 | shuffled read_batch 50000 100 | shuffled read_batch 50000 1000 | shuffled read_formatted numpy 5000 | shuffled read_formatted_batch numpy 5000 10 | shuffled read_formatted_batch numpy 5000 1000 |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.404211 / 0.215209 (0.189002) | 4.045374 / 2.077655 (1.967719) | 1.877237 / 1.504120 (0.373117) | 1.706276 / 1.541195 (0.165081) | 1.750610 / 1.468490 (0.282120) | 0.522331 / 4.584777 (-4.062446) | 3.742286 / 3.745712 (-0.003426) | 1.791285 / 5.269862 (-3.478577) | 1.043872 / 4.565676 (-3.521805) | 0.065176 / 0.424275 (-0.359099) | 0.011821 / 0.007607 (0.004214) | 0.507374 / 0.226044 (0.281329) | 5.088803 / 2.268929 (2.819875) | 2.282742 / 55.444624 (-53.161882) | 1.950737 / 6.876477 (-4.925740) | 2.042262 / 2.142072 (-0.099810) | 0.636525 / 4.805227 (-4.168702) | 0.140837 / 6.500664 (-6.359827) | 0.063223 / 0.075469 (-0.012246) |\n\n### Benchmark: benchmark_map_filter.json\n\n| metric | filter | map fast-tokenizer batched | map identity | map identity batched | map no-op batched | map no-op batched numpy | map no-op batched pandas | map no-op batched pytorch | map no-op batched tensorflow |\n|--------|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 1.188070 / 1.841788 (-0.653718) | 14.622681 / 8.074308 (6.548372) | 13.247988 / 10.191392 (3.056596) | 0.165858 / 0.680424 (-0.514566) | 0.017476 / 0.534201 (-0.516725) | 0.391973 / 0.579283 (-0.187310) | 0.433326 / 0.434364 (-0.001038) | 0.467163 / 0.540337 (-0.073175) | 0.568359 / 1.386936 (-0.818577) |\n\n</details>\nPyArrow==latest\n\n<details>\n<summary>Show updated benchmarks!</summary>\n\n### Benchmark: benchmark_array_xd.json\n\n| metric | read_batch_formatted_as_numpy after write_array2d | read_batch_formatted_as_numpy after write_flattened_sequence | read_batch_formatted_as_numpy after write_nested_sequence | read_batch_unformated after write_array2d | read_batch_unformated after write_flattened_sequence | read_batch_unformated after write_nested_sequence | read_col_formatted_as_numpy after write_array2d | read_col_formatted_as_numpy after write_flattened_sequence | read_col_formatted_as_numpy after write_nested_sequence | read_col_unformated after write_array2d | read_col_unformated after write_flattened_sequence | read_col_unformated after write_nested_sequence | read_formatted_as_numpy after write_array2d | read_formatted_as_numpy after write_flattened_sequence | read_formatted_as_numpy after write_nested_sequence | read_unformated after write_array2d | read_unformated after write_flattened_sequence | read_unformated after write_nested_sequence | write_array2d | write_flattened_sequence | write_nested_sequence |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.006076 / 0.011353 (-0.005276) | 0.004439 / 0.011008 (-0.006570) | 0.074496 / 0.038508 (0.035988) | 0.031396 / 0.023109 (0.008287) | 0.372237 / 0.275898 (0.096339) | 0.403412 / 0.323480 (0.079932) | 0.005430 / 0.007986 (-0.002555) | 0.003846 / 0.004328 (-0.000483) | 0.074403 / 0.004250 (0.070153) | 0.045398 / 0.037052 (0.008346) | 0.394133 / 0.258489 (0.135644) | 0.421769 / 0.293841 (0.127928) | 0.027936 / 0.128546 (-0.100610) | 0.008962 / 0.075646 (-0.066685) | 0.083158 / 0.419271 (-0.336113) | 0.044863 / 0.043533 (0.001331) | 0.393834 / 0.255139 (0.138695) | 0.391537 / 0.283200 (0.108337) | 0.097971 / 0.141683 (-0.043712) | 1.496632 / 1.452155 (0.044477) | 1.585511 / 1.492716 (0.092795) |\n\n### Benchmark: benchmark_getitem\\_100B.json\n\n| metric | get_batch_of\\_1024\\_random_rows | get_batch_of\\_1024\\_rows | get_first_row | get_last_row |\n|--------|---|---|---|---|\n| new / old (diff) | 0.010094 / 0.018006 (-0.007913) | 0.437811 / 0.000490 (0.437321) | 0.000963 / 0.000200 (0.000763) | 0.000084 / 0.000054 (0.000029) |\n\n### Benchmark: benchmark_indices_mapping.json\n\n| metric | select | shard | shuffle | sort | train_test_split |\n|--------|---|---|---|---|---|\n| new / old (diff) | 0.028864 / 0.037411 (-0.008547) | 0.112480 / 0.014526 (0.097954) | 0.120938 / 0.176557 (-0.055619) | 0.170888 / 0.737135 (-0.566247) | 0.125903 / 0.296338 (-0.170435) |\n\n### Benchmark: benchmark_iterating.json\n\n| metric | read 5000 | read 50000 | read_batch 50000 10 | read_batch 50000 100 | read_batch 50000 1000 | read_formatted numpy 5000 | read_formatted pandas 5000 | read_formatted tensorflow 5000 | read_formatted torch 5000 | read_formatted_batch numpy 5000 10 | read_formatted_batch numpy 5000 1000 | shuffled read 5000 | shuffled read 50000 | shuffled read_batch 50000 10 | shuffled read_batch 50000 100 | shuffled read_batch 50000 1000 | shuffled read_formatted numpy 5000 | shuffled read_formatted_batch numpy 5000 10 | shuffled read_formatted_batch numpy 5000 1000 |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.426716 / 0.215209 (0.211507) | 4.238380 / 2.077655 (2.160725) | 2.052889 / 1.504120 (0.548769) | 1.871043 / 1.541195 (0.329848) | 1.890405 / 1.468490 (0.421915) | 0.522059 / 4.584777 (-4.062718) | 3.813331 / 3.745712 (0.067619) | 2.891651 / 5.269862 (-2.378210) | 1.323836 / 4.565676 (-3.241841) | 0.065124 / 0.424275 (-0.359151) | 0.011498 / 0.007607 (0.003891) | 0.525102 / 0.226044 (0.299057) | 5.245190 / 2.268929 (2.976261) | 2.531149 / 55.444624 (-52.913476) | 2.197323 / 6.876477 (-4.679153) | 2.197314 / 2.142072 (0.055241) | 0.633423 / 4.805227 (-4.171804) | 0.140248 / 6.500664 (-6.360416) | 0.064432 / 0.075469 (-0.011037) |\n\n### Benchmark: benchmark_map_filter.json\n\n| metric | filter | map fast-tokenizer batched | map identity | map identity batched | map no-op batched | map no-op batched numpy | map no-op batched pandas | map no-op batched pytorch | map no-op batched tensorflow |\n|--------|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 1.270639 / 1.841788 (-0.571149) | 14.856678 / 8.074308 (6.782369) | 14.337631 / 10.191392 (4.146239) | 0.195319 / 0.680424 (-0.485105) | 0.017628 / 0.534201 (-0.516573) | 0.393984 / 0.579283 (-0.185299) | 0.421987 / 0.434364 (-0.012376) | 0.459245 / 0.540337 (-0.081092) | 0.557786 / 1.386936 (-0.829150) |\n\n</details>\n</details>\n\n![](https://cml.dev/watermark.png#a129219a48c1b07c06d4bc1db32c317bf513089d \"CML watermark\")\n", "Will you eventually need help with your PR @Rocketknight1? I'll be happy to help if needed 😄 ", "<details>\n<summary>Show benchmarks</summary>\n\nPyArrow==8.0.0\n\n<details>\n<summary>Show updated benchmarks!</summary>\n\n### Benchmark: benchmark_array_xd.json\n\n| metric | read_batch_formatted_as_numpy after write_array2d | read_batch_formatted_as_numpy after write_flattened_sequence | read_batch_formatted_as_numpy after write_nested_sequence | read_batch_unformated after write_array2d | read_batch_unformated after write_flattened_sequence | read_batch_unformated after write_nested_sequence | read_col_formatted_as_numpy after write_array2d | read_col_formatted_as_numpy after write_flattened_sequence | read_col_formatted_as_numpy after write_nested_sequence | read_col_unformated after write_array2d | read_col_unformated after write_flattened_sequence | read_col_unformated after write_nested_sequence | read_formatted_as_numpy after write_array2d | read_formatted_as_numpy after write_flattened_sequence | read_formatted_as_numpy after write_nested_sequence | read_unformated after write_array2d | read_unformated after write_flattened_sequence | read_unformated after write_nested_sequence | write_array2d | write_flattened_sequence | write_nested_sequence |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.007577 / 0.011353 (-0.003776) | 0.004960 / 0.011008 (-0.006048) | 0.113622 / 0.038508 (0.075114) | 0.037981 / 0.023109 (0.014872) | 0.355312 / 0.275898 (0.079414) | 0.393384 / 0.323480 (0.069904) | 0.006575 / 0.007986 (-0.001411) | 0.005941 / 0.004328 (0.001612) | 0.085976 / 0.004250 (0.081726) | 0.053784 / 0.037052 (0.016732) | 0.369358 / 0.258489 (0.110869) | 0.399402 / 0.293841 (0.105561) | 0.032155 / 0.128546 (-0.096391) | 0.010448 / 0.075646 (-0.065199) | 0.389009 / 0.419271 (-0.030263) | 0.057377 / 0.043533 (0.013844) | 0.354968 / 0.255139 (0.099829) | 0.382404 / 0.283200 (0.099204) | 0.111056 / 0.141683 (-0.030627) | 1.807986 / 1.452155 (0.355832) | 1.866070 / 1.492716 (0.373354) |\n\n### Benchmark: benchmark_getitem\\_100B.json\n\n| metric | get_batch_of\\_1024\\_random_rows | get_batch_of\\_1024\\_rows | get_first_row | get_last_row |\n|--------|---|---|---|---|\n| new / old (diff) | 0.244439 / 0.018006 (0.226432) | 0.491942 / 0.000490 (0.491452) | 0.001910 / 0.000200 (0.001710) | 0.000112 / 0.000054 (0.000058) |\n\n### Benchmark: benchmark_indices_mapping.json\n\n| metric | select | shard | shuffle | sort | train_test_split |\n|--------|---|---|---|---|---|\n| new / old (diff) | 0.031024 / 0.037411 (-0.006387) | 0.129674 / 0.014526 (0.115148) | 0.142974 / 0.176557 (-0.033583) | 0.213568 / 0.737135 (-0.523568) | 0.147794 / 0.296338 (-0.148545) |\n\n### Benchmark: benchmark_iterating.json\n\n| metric | read 5000 | read 50000 | read_batch 50000 10 | read_batch 50000 100 | read_batch 50000 1000 | read_formatted numpy 5000 | read_formatted pandas 5000 | read_formatted tensorflow 5000 | read_formatted torch 5000 | read_formatted_batch numpy 5000 10 | read_formatted_batch numpy 5000 1000 | shuffled read 5000 | shuffled read 50000 | shuffled read_batch 50000 10 | shuffled read_batch 50000 100 | shuffled read_batch 50000 1000 | shuffled read_formatted numpy 5000 | shuffled read_formatted_batch numpy 5000 10 | shuffled read_formatted_batch numpy 5000 1000 |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.480333 / 0.215209 (0.265124) | 4.792901 / 2.077655 (2.715246) | 2.233145 / 1.504120 (0.729025) | 2.036291 / 1.541195 (0.495096) | 2.109631 / 1.468490 (0.641140) | 0.624546 / 4.584777 (-3.960231) | 4.543511 / 3.745712 (0.797799) | 3.961345 / 5.269862 (-1.308517) | 1.903634 / 4.565676 (-2.662042) | 0.076584 / 0.424275 (-0.347691) | 0.014590 / 0.007607 (0.006983) | 0.593195 / 0.226044 (0.367151) | 5.928740 / 2.268929 (3.659811) | 2.781164 / 55.444624 (-52.663460) | 2.364303 / 6.876477 (-4.512173) | 2.510139 / 2.142072 (0.368067) | 0.770886 / 4.805227 (-4.034341) | 0.167995 / 6.500664 (-6.332669) | 0.076622 / 0.075469 (0.001153) |\n\n### Benchmark: benchmark_map_filter.json\n\n| metric | filter | map fast-tokenizer batched | map identity | map identity batched | map no-op batched | map no-op batched numpy | map no-op batched pandas | map no-op batched pytorch | map no-op batched tensorflow |\n|--------|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 1.402398 / 1.841788 (-0.439390) | 17.921233 / 8.074308 (9.846925) | 17.036738 / 10.191392 (6.845346) | 0.168997 / 0.680424 (-0.511427) | 0.020259 / 0.534201 (-0.513941) | 0.465322 / 0.579283 (-0.113962) | 0.500435 / 0.434364 (0.066071) | 0.546846 / 0.540337 (0.006509) | 0.658130 / 1.386936 (-0.728806) |\n\n</details>\nPyArrow==latest\n\n<details>\n<summary>Show updated benchmarks!</summary>\n\n### Benchmark: benchmark_array_xd.json\n\n| metric | read_batch_formatted_as_numpy after write_array2d | read_batch_formatted_as_numpy after write_flattened_sequence | read_batch_formatted_as_numpy after write_nested_sequence | read_batch_unformated after write_array2d | read_batch_unformated after write_flattened_sequence | read_batch_unformated after write_nested_sequence | read_col_formatted_as_numpy after write_array2d | read_col_formatted_as_numpy after write_flattened_sequence | read_col_formatted_as_numpy after write_nested_sequence | read_col_unformated after write_array2d | read_col_unformated after write_flattened_sequence | read_col_unformated after write_nested_sequence | read_formatted_as_numpy after write_array2d | read_formatted_as_numpy after write_flattened_sequence | read_formatted_as_numpy after write_nested_sequence | read_unformated after write_array2d | read_unformated after write_flattened_sequence | read_unformated after write_nested_sequence | write_array2d | write_flattened_sequence | write_nested_sequence |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.007624 / 0.011353 (-0.003729) | 0.005265 / 0.011008 (-0.005744) | 0.086886 / 0.038508 (0.048377) | 0.038235 / 0.023109 (0.015126) | 0.463969 / 0.275898 (0.188071) | 0.502451 / 0.323480 (0.178971) | 0.006285 / 0.007986 (-0.001701) | 0.004525 / 0.004328 (0.000197) | 0.086557 / 0.004250 (0.082307) | 0.052414 / 0.037052 (0.015362) | 0.482167 / 0.258489 (0.223678) | 0.513684 / 0.293841 (0.219843) | 0.032929 / 0.128546 (-0.095618) | 0.010249 / 0.075646 (-0.065397) | 0.093377 / 0.419271 (-0.325895) | 0.054114 / 0.043533 (0.010582) | 0.466116 / 0.255139 (0.210977) | 0.488977 / 0.283200 (0.205777) | 0.115446 / 0.141683 (-0.026237) | 1.762912 / 1.452155 (0.310757) | 1.874191 / 1.492716 (0.381475) |\n\n### Benchmark: benchmark_getitem\\_100B.json\n\n| metric | get_batch_of\\_1024\\_random_rows | get_batch_of\\_1024\\_rows | get_first_row | get_last_row |\n|--------|---|---|---|---|\n| new / old (diff) | 0.012666 / 0.018006 (-0.005341) | 0.485962 / 0.000490 (0.485473) | 0.002621 / 0.000200 (0.002421) | 0.000128 / 0.000054 (0.000074) |\n\n### Benchmark: benchmark_indices_mapping.json\n\n| metric | select | shard | shuffle | sort | train_test_split |\n|--------|---|---|---|---|---|\n| new / old (diff) | 0.033661 / 0.037411 (-0.003751) | 0.135395 / 0.014526 (0.120869) | 0.147230 / 0.176557 (-0.029326) | 0.205847 / 0.737135 (-0.531288) | 0.151496 / 0.296338 (-0.144842) |\n\n### Benchmark: benchmark_iterating.json\n\n| metric | read 5000 | read 50000 | read_batch 50000 10 | read_batch 50000 100 | read_batch 50000 1000 | read_formatted numpy 5000 | read_formatted pandas 5000 | read_formatted tensorflow 5000 | read_formatted torch 5000 | read_formatted_batch numpy 5000 10 | read_formatted_batch numpy 5000 1000 | shuffled read 5000 | shuffled read 50000 | shuffled read_batch 50000 10 | shuffled read_batch 50000 100 | shuffled read_batch 50000 1000 | shuffled read_formatted numpy 5000 | shuffled read_formatted_batch numpy 5000 10 | shuffled read_formatted_batch numpy 5000 1000 |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.514097 / 0.215209 (0.298887) | 5.134093 / 2.077655 (3.056438) | 2.496775 / 1.504120 (0.992655) | 2.268078 / 1.541195 (0.726883) | 2.342153 / 1.468490 (0.873663) | 0.623130 / 4.584777 (-3.961647) | 4.601787 / 3.745712 (0.856075) | 3.414249 / 5.269862 (-1.855613) | 1.849603 / 4.565676 (-2.716073) | 0.078350 / 0.424275 (-0.345925) | 0.013785 / 0.007607 (0.006178) | 0.638783 / 0.226044 (0.412739) | 6.378356 / 2.268929 (4.109427) | 3.072867 / 55.444624 (-52.371757) | 2.668123 / 6.876477 (-4.208354) | 2.693905 / 2.142072 (0.551833) | 0.764583 / 4.805227 (-4.040644) | 0.166854 / 6.500664 (-6.333810) | 0.076883 / 0.075469 (0.001414) |\n\n### Benchmark: benchmark_map_filter.json\n\n| metric | filter | map fast-tokenizer batched | map identity | map identity batched | map no-op batched | map no-op batched numpy | map no-op batched pandas | map no-op batched pytorch | map no-op batched tensorflow |\n|--------|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 1.502003 / 1.841788 (-0.339784) | 18.674205 / 8.074308 (10.599897) | 16.837759 / 10.191392 (6.646367) | 0.176995 / 0.680424 (-0.503428) | 0.020126 / 0.534201 (-0.514075) | 0.464480 / 0.579283 (-0.114803) | 0.516477 / 0.434364 (0.082113) | 0.549818 / 0.540337 (0.009481) | 0.659927 / 1.386936 (-0.727009) |\n\n</details>\n</details>\n\n![](https://cml.dev/watermark.png#a129219a48c1b07c06d4bc1db32c317bf513089d \"CML watermark\")\n", "@alvarobartt Yes, I'll ping you for a review once it's ready!" ]
"2023-05-22T11:51:07Z"
"2023-06-08T11:09:03Z"
"2023-06-06T16:49:15Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/5883.diff", "html_url": "https://github.com/huggingface/datasets/pull/5883", "merged_at": "2023-06-06T16:49:15Z", "patch_url": "https://github.com/huggingface/datasets/pull/5883.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/5883" }
## What's in this PR? This PR addresses some minor fixes and general improvements in the `to_tf_dataset` method of `datasets.Dataset`, to convert a 🤗HuggingFace Dataset as a TensorFlow Dataset. The main bug solved in this PR comes with the string-encoding, since for safety purposes the internal conversion of `numpy.arrays` when `dtype` is unicode/string, is to convert it into `numpy.bytes`, more information in the docstring of https://github.com/tensorflow/tensorflow/blob/388d952114e59a1aeda440ed4737b29f8b7c6e8a/tensorflow/python/ops/script_ops.py#L210. That's triggered when using `tensorflow.numpy_function` as it's applying another type cast besides the one that `datasets` does, so the casting is applied at least twice per entry/batch. So this means that the definition of the `numpy.unicode_` dtype when the data in the batch is a string, is ignored, and replaced by `numpy.bytes_`. Besides that, some other minor things have been fixed: * Made `batch_size` an optional parameter in `to_tf_dataset` * Map the `tensorflow` output dtypes just once, and not in every `tf.function` call during `map` * Keep `numpy` formatting in the `datasets.Dataset` if already formatted like it, no need to format it again as `numpy` * Docstring indentation in `dataset_to_tf` and `multiprocess_dataset_to_tf` ## What's missing in this PR? I can include some integration tests if needed, to validate that `batch_size` is optional, and that the tensors in the TF-Dataset can be looped over with no issues as before.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/5883/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5883/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/3793
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/3793/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/3793/comments
https://api.github.com/repos/huggingface/datasets/issues/3793/events
https://github.com/huggingface/datasets/pull/3793
1,150,974,950
PR_kwDODunzps4zfdL0
3,793
Docs new UI actions no self hosted
{ "avatar_url": "https://avatars.githubusercontent.com/u/30755778?v=4", "events_url": "https://api.github.com/users/LysandreJik/events{/privacy}", "followers_url": "https://api.github.com/users/LysandreJik/followers", "following_url": "https://api.github.com/users/LysandreJik/following{/other_user}", "gists_url": "https://api.github.com/users/LysandreJik/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/LysandreJik", "id": 30755778, "login": "LysandreJik", "node_id": "MDQ6VXNlcjMwNzU1Nzc4", "organizations_url": "https://api.github.com/users/LysandreJik/orgs", "received_events_url": "https://api.github.com/users/LysandreJik/received_events", "repos_url": "https://api.github.com/users/LysandreJik/repos", "site_admin": false, "starred_url": "https://api.github.com/users/LysandreJik/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/LysandreJik/subscriptions", "type": "User", "url": "https://api.github.com/users/LysandreJik" }
[]
closed
false
null
[]
null
[ "It seems like the doc can't be compiled right now because of the following:\r\n\r\n```\r\nTraceback (most recent call last):\r\n File \"/usr/local/bin/doc-builder\", line 33, in <module>\r\n sys.exit(load_entry_point('doc-builder', 'console_scripts', 'doc-builder')())\r\n File \"/__w/datasets/datasets/doc-builder/src/doc_builder/commands/doc_builder_cli.py\", line 39, in main\r\n args.func(args)\r\n File \"/__w/datasets/datasets/doc-builder/src/doc_builder/commands/build.py\", line 95, in build_command\r\n build_doc(\r\n File \"/__w/datasets/datasets/doc-builder/src/doc_builder/build_doc.py\", line 361, in build_doc\r\n anchors_mapping = build_mdx_files(package, doc_folder, output_dir, page_info)\r\n File \"/__w/datasets/datasets/doc-builder/src/doc_builder/build_doc.py\", line 200, in build_mdx_files\r\n raise type(e)(f\"There was an error when converting {file} to the MDX format.\\n\" + e.args[0]) from e\r\nTypeError: There was an error when converting datasets/docs/source/package_reference/table_classes.mdx to the MDX format.\r\nexpected string or bytes-like object\r\n```", "The docs for this PR live [here](https://moon-ci-docs.huggingface.co/docs/datasets/pr_3793). All of your documentation changes will be reflected on that endpoint.", "This is due to the injection of docstrings from PyArrow. I think I can fix that by moving all the docstrings and fix them manually.", "> It seems like the doc can't be compiled right now because of the following:\r\n\r\nit is expected since there is something I need to change on doc-builder side.\r\n\r\n> This is due to the injection of docstrings from PyArrow. I think I can fix that by moving all the docstrings and fix them manually.\r\n\r\n@lhoestq I will let you know if we need to change it manually.\r\n\r\n@LysandreJik thanks a lot for this PR! I only had one question [here](https://github.com/huggingface/datasets/pull/3793#discussion_r816100194)", "> @lhoestq I will let you know if we need to change it manually.\r\n\r\nIt would be simpler to change it manually anyway - I don't want our documentation to break if PyArrow has documentation issues", "For some reason it fails when `Installing node dependencies` when running `npm ci` from the `kit` directory, any idea why @mishig25 ?", "Checking it rn", "It's very likely linked to an OOM error: https://github.com/huggingface/transformers/pull/15710#issuecomment-1051737337" ]
"2022-02-25T23:48:55Z"
"2022-03-01T15:55:29Z"
"2022-03-01T15:55:28Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/3793.diff", "html_url": "https://github.com/huggingface/datasets/pull/3793", "merged_at": "2022-03-01T15:55:28Z", "patch_url": "https://github.com/huggingface/datasets/pull/3793.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/3793" }
Removes the need to have a self-hosted runner for the dev documentation
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/3793/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/3793/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/2318
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/2318/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/2318/comments
https://api.github.com/repos/huggingface/datasets/issues/2318/events
https://github.com/huggingface/datasets/issues/2318
876,212,460
MDU6SXNzdWU4NzYyMTI0NjA=
2,318
[api request] API to obtain "dataset_module" dynamic path?
{ "avatar_url": "https://avatars.githubusercontent.com/u/4529381?v=4", "events_url": "https://api.github.com/users/richardliaw/events{/privacy}", "followers_url": "https://api.github.com/users/richardliaw/followers", "following_url": "https://api.github.com/users/richardliaw/following{/other_user}", "gists_url": "https://api.github.com/users/richardliaw/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/richardliaw", "id": 4529381, "login": "richardliaw", "node_id": "MDQ6VXNlcjQ1MjkzODE=", "organizations_url": "https://api.github.com/users/richardliaw/orgs", "received_events_url": "https://api.github.com/users/richardliaw/received_events", "repos_url": "https://api.github.com/users/richardliaw/repos", "site_admin": false, "starred_url": "https://api.github.com/users/richardliaw/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/richardliaw/subscriptions", "type": "User", "url": "https://api.github.com/users/richardliaw" }
[ { "color": "a2eeef", "default": true, "description": "New feature or request", "id": 1935892871, "name": "enhancement", "node_id": "MDU6TGFiZWwxOTM1ODkyODcx", "url": "https://api.github.com/repos/huggingface/datasets/labels/enhancement" } ]
closed
false
{ "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" } ]
null
[ "Hi @richardliaw, \r\n\r\nFirst, thanks for the compliments.\r\n\r\nIn relation with your request, currently, the dynamic modules path is obtained this way:\r\n```python\r\nfrom datasets.load import init_dynamic_modules, MODULE_NAME_FOR_DYNAMIC_MODULES\r\n\r\ndynamic_modules_path = init_dynamic_modules(MODULE_NAME_FOR_DYNAMIC_MODULES)\r\n```\r\n\r\nLet me know if it is OK for you this way. \r\n\r\nI could set `MODULE_NAME_FOR_DYNAMIC_MODULES` as default value, so that you could instead obtain the path with:\r\n```\r\ndynamic_modules_path = datasets.load.init_dynamic_modules()\r\n```", "Hi @albertvillanova, the default value proposal seems great :) Looking forward to this!", "I like the idea as well ! thanks @albertvillanova ", "Hi @richardliaw, the feature is on the master branch and will be included in the next release in a couple of weeks.", "awesome work @albertvillanova !" ]
"2021-05-05T08:40:48Z"
"2021-05-06T08:45:45Z"
"2021-05-06T07:57:54Z"
NONE
null
null
null
**Is your feature request related to a problem? Please describe.** A clear and concise description of what the problem is. This is an awesome library. It seems like the dynamic module path in this library has broken some of hyperparameter tuning functionality: https://discuss.huggingface.co/t/using-hyperparameter-search-in-trainer/785/34 This is because Ray will spawn new processes, and each process will load modules by path. However, we need to explicitly inform Ray to load the right modules, or else it will error upon import. I'd like an API to obtain the dynamic paths. This will allow us to support this functionality in this awesome library while being future proof. **Describe the solution you'd like** A clear and concise description of what you want to happen. `datasets.get_dynamic_paths -> List[str]` will be sufficient for my use case. By offering this API, we will be able to address the following issues (by patching the ray integration sufficiently): https://github.com/huggingface/blog/issues/106 https://github.com/huggingface/transformers/issues/11565 https://discuss.huggingface.co/t/using-hyperparameter-search-in-trainer/785/34 https://discuss.huggingface.co/t/using-hyperparameter-search-in-trainer/785/35
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/2318/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/2318/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/3423
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/3423/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/3423/comments
https://api.github.com/repos/huggingface/datasets/issues/3423/events
https://github.com/huggingface/datasets/issues/3423
1,078,049,638
I_kwDODunzps5AQbtm
3,423
data duplicate when setting num_works > 1 with streaming data
{ "avatar_url": "https://avatars.githubusercontent.com/u/16486492?v=4", "events_url": "https://api.github.com/users/cloudyuyuyu/events{/privacy}", "followers_url": "https://api.github.com/users/cloudyuyuyu/followers", "following_url": "https://api.github.com/users/cloudyuyuyu/following{/other_user}", "gists_url": "https://api.github.com/users/cloudyuyuyu/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/cloudyuyuyu", "id": 16486492, "login": "cloudyuyuyu", "node_id": "MDQ6VXNlcjE2NDg2NDky", "organizations_url": "https://api.github.com/users/cloudyuyuyu/orgs", "received_events_url": "https://api.github.com/users/cloudyuyuyu/received_events", "repos_url": "https://api.github.com/users/cloudyuyuyu/repos", "site_admin": false, "starred_url": "https://api.github.com/users/cloudyuyuyu/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/cloudyuyuyu/subscriptions", "type": "User", "url": "https://api.github.com/users/cloudyuyuyu" }
[ { "color": "d73a4a", "default": true, "description": "Something isn't working", "id": 1935892857, "name": "bug", "node_id": "MDU6TGFiZWwxOTM1ODkyODU3", "url": "https://api.github.com/repos/huggingface/datasets/labels/bug" }, { "color": "fef2c0", "default": false, "description": "", "id": 3287858981, "name": "streaming", "node_id": "MDU6TGFiZWwzMjg3ODU4OTgx", "url": "https://api.github.com/repos/huggingface/datasets/labels/streaming" } ]
closed
false
null
[]
null
[ "Hi ! Thanks for reporting :)\r\n\r\nWhen using a PyTorch's data loader with `num_workers>1` and an iterable dataset, each worker streams the exact same data by default, resulting in duplicate data when iterating using the data loader.\r\n\r\nWe can probably fix this in `datasets` by checking `torch.utils.data.get_worker_info()` which gives the worker id if it happens.", "> Hi ! Thanks for reporting :)\r\n> \r\n> When using a PyTorch's data loader with `num_workers>1` and an iterable dataset, each worker streams the exact same data by default, resulting in duplicate data when iterating using the data loader.\r\n> \r\n> We can probably fix this in `datasets` by checking `torch.utils.data.get_worker_info()` which gives the worker id if it happens.\r\nHi ! Thanks for reply\r\n\r\nDo u have some plans to fix the problem?\r\n", "Isn’t that somehow a bug on PyTorch side? (Just asking because this behavior seems quite general and maybe not what would be intended)", "From PyTorch's documentation [here](https://pytorch.org/docs/stable/data.html#dataset-types):\r\n\r\n> When using an IterableDataset with multi-process data loading. The same dataset object is replicated on each worker process, and thus the replicas must be configured differently to avoid duplicated data. See [IterableDataset](https://pytorch.org/docs/stable/data.html#torch.utils.data.IterableDataset) documentations for how to achieve this.\r\n\r\nIt looks like an intended behavior from PyTorch\r\n\r\nAs suggested in the [docstring of the IterableDataset class](https://pytorch.org/docs/stable/data.html#torch.utils.data.IterableDataset), we could pass a `worker_init_fn` to the DataLoader to fix this. It could be called `streaming_worker_init_fn` for example.\r\n\r\nHowever, while this solution works, I'm worried that many users simply don't know about this parameter and just start their training with duplicate data without knowing it. That's why I'm more in favor of integrating the check on the worker id directly in `datasets` in our implementation of `IterableDataset.__iter__`.", "Fixed by https://github.com/huggingface/datasets/pull/4375", "> Fixed by #4375\r\n\r\nThanks!", "Hi there @lhoestq @cloudyuyuyu \r\nI met that problem recently, and #4375 is really useful because I finally found out I am training with duplicate data.\r\nHowever, in multi-GPU training, I'm using DDP mode and IterableDataset, which still yields duplicate data for each progress. And this is dangerous because users maybe not realize this behavior.", "If the worker_info.id is unique per process it should work fine, could you check that they're unique ?\r\n\r\nThe code to get the worker_info in each worker is `torch.utils.data.get_worker_info()`", "test.py\r\n```python\r\nimport json\r\nimport os\r\n\r\nimport torch\r\nfrom torch.utils.data import IterableDataset, DataLoader\r\nfrom transformers import PreTrainedTokenizer, TrainingArguments\r\n\r\nfrom common.arguments import DataTrainingArguments, ModelArguments\r\n\r\n\r\nclass MyIterableDataset(IterableDataset):\r\n def __iter__(self):\r\n worker_info = torch.utils.data.get_worker_info()\r\n print(worker_info)\r\n return iter(range(3))\r\n\r\n\r\nif __name__ == '__main__':\r\n dataset = MyIterableDataset()\r\n dataloader = DataLoader(dataset, num_workers=1)\r\n for i in dataloader:\r\n print(i)\r\n\r\n```\r\n\r\n\r\n```sh\r\n$ python3 -m torch.distributed.launch \\\r\n --nproc_per_node=2 test.py\r\nWorkerInfo(id=0, num_workers=1, seed=5545685212307804959, dataset=<__main__.MyIterableDataset object at 0x7f92648cf6a0>)\r\nWorkerInfo(id=0, num_workers=1, seed=3174108029709729025, dataset=<__main__.MyIterableDataset object at 0x7f19ab961670>)\r\ntensor([0])\r\ntensor([1])\r\ntensor([2])\r\ntensor([0])\r\ntensor([1])\r\ntensor([2])\r\n```\r\n\r\n@lhoestq they are not unique", "It looks like a bug from pytorch no ? How can we know which data should go in which process when using DDP ?\r\n\r\nI guess we need to check `torch.distributed.get_world_size()` and `torch.distributed.get_rank()` as well. Not fan of the design here tbh, but that's how it is", "> It looks like a bug from pytorch no ? How can we know which data should go in which process when using DDP ?\r\n> \r\n> I guess we need to check `torch.distributed.get_world_size()` and `torch.distributed.get_rank()` as well. Not fan of the design here tbh, but that's how it is\r\n\r\nMaybe we should document it?", "Never mind. After reading the code, `IterableDatasetShard` has solved this problem.", "I'm re-opening this one since I think it should be supported by `datasets` natively", "hmm actually let me open a new issue on DDP - original post was for single node" ]
"2021-12-13T03:43:17Z"
"2022-12-14T16:04:22Z"
"2022-12-14T16:04:22Z"
NONE
null
null
null
## Describe the bug The data is repeated num_works times when we load_dataset with streaming and set num_works > 1 when construct dataloader ## Steps to reproduce the bug ```python # Sample code to reproduce the bug import pandas as pd import numpy as np import os from datasets import load_dataset from torch.utils.data import DataLoader from tqdm import tqdm import shutil NUM_OF_USER = 1000000 NUM_OF_ACTION = 50000 NUM_OF_SEQUENCE = 10000 NUM_OF_FILES = 32 NUM_OF_WORKERS = 16 if __name__ == "__main__": shutil.rmtree("./dataset") for i in range(NUM_OF_FILES): sequence_data = pd.DataFrame( { "imei": np.random.randint(1, NUM_OF_USER, size=NUM_OF_SEQUENCE), "sequence": np.random.randint(1, NUM_OF_ACTION, size=NUM_OF_SEQUENCE) } ) if not os.path.exists("./dataset"): os.makedirs("./dataset") sequence_data.to_csv(f"./dataset/sequence_data_{i}.csv", index=False) dataset = load_dataset("csv", data_files=[os.path.join("./dataset",file) for file in os.listdir("./dataset") if file.endswith(".csv")], split="train", streaming=True).with_format("torch") data_loader = DataLoader(dataset, batch_size=1024, num_workers=NUM_OF_WORKERS) result = pd.DataFrame() for i, batch in tqdm(enumerate(data_loader)): result = pd.concat([result, pd.DataFrame(batch)], axis=0) result.to_csv(f"num_work_{NUM_OF_WORKERS}.csv", index=False) ``` ## Expected results data do not duplicate ## Actual results data duplicate NUM_OF_WORKERS = 16 ![image](https://user-images.githubusercontent.com/16486492/145748707-9d2df25b-2f4f-4d7b-a83e-242be4fc8934.png) ## Environment info <!-- You can run the command `datasets-cli env` and copy-and-paste its output below. --> - `datasets` version:datasets==1.14.0 - Platform:transformers==4.11.3 - Python version:3.8 - PyArrow version:
{ "+1": 2, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 2, "url": "https://api.github.com/repos/huggingface/datasets/issues/3423/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/3423/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/6233
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/6233/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/6233/comments
https://api.github.com/repos/huggingface/datasets/issues/6233/events
https://github.com/huggingface/datasets/pull/6233
1,891,804,286
PR_kwDODunzps5aF3kd
6,233
Update README.md
{ "avatar_url": "https://avatars.githubusercontent.com/u/95188570?v=4", "events_url": "https://api.github.com/users/NinoRisteski/events{/privacy}", "followers_url": "https://api.github.com/users/NinoRisteski/followers", "following_url": "https://api.github.com/users/NinoRisteski/following{/other_user}", "gists_url": "https://api.github.com/users/NinoRisteski/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/NinoRisteski", "id": 95188570, "login": "NinoRisteski", "node_id": "U_kgDOBax2Wg", "organizations_url": "https://api.github.com/users/NinoRisteski/orgs", "received_events_url": "https://api.github.com/users/NinoRisteski/received_events", "repos_url": "https://api.github.com/users/NinoRisteski/repos", "site_admin": false, "starred_url": "https://api.github.com/users/NinoRisteski/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/NinoRisteski/subscriptions", "type": "User", "url": "https://api.github.com/users/NinoRisteski" }
[]
closed
false
null
[]
null
[ "_The documentation is not available anymore as the PR was closed or merged._", "<details>\n<summary>Show benchmarks</summary>\n\nPyArrow==8.0.0\n\n<details>\n<summary>Show updated benchmarks!</summary>\n\n### Benchmark: benchmark_array_xd.json\n\n| metric | read_batch_formatted_as_numpy after write_array2d | read_batch_formatted_as_numpy after write_flattened_sequence | read_batch_formatted_as_numpy after write_nested_sequence | read_batch_unformated after write_array2d | read_batch_unformated after write_flattened_sequence | read_batch_unformated after write_nested_sequence | read_col_formatted_as_numpy after write_array2d | read_col_formatted_as_numpy after write_flattened_sequence | read_col_formatted_as_numpy after write_nested_sequence | read_col_unformated after write_array2d | read_col_unformated after write_flattened_sequence | read_col_unformated after write_nested_sequence | read_formatted_as_numpy after write_array2d | read_formatted_as_numpy after write_flattened_sequence | read_formatted_as_numpy after write_nested_sequence | read_unformated after write_array2d | read_unformated after write_flattened_sequence | read_unformated after write_nested_sequence | write_array2d | write_flattened_sequence | write_nested_sequence |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.008370 / 0.011353 (-0.002983) | 0.004674 / 0.011008 (-0.006334) | 0.103912 / 0.038508 (0.065404) | 0.101668 / 0.023109 (0.078559) | 0.417945 / 0.275898 (0.142047) | 0.454805 / 0.323480 (0.131325) | 0.004763 / 0.007986 (-0.003223) | 0.003934 / 0.004328 (-0.000394) | 0.078446 / 0.004250 (0.074196) | 0.068383 / 0.037052 (0.031331) | 0.415100 / 0.258489 (0.156611) | 0.475272 / 0.293841 (0.181431) | 0.036884 / 0.128546 (-0.091662) | 0.010097 / 0.075646 (-0.065549) | 0.354962 / 0.419271 (-0.064309) | 0.062688 / 0.043533 (0.019155) | 0.420643 / 0.255139 (0.165504) | 0.446504 / 0.283200 (0.163304) | 0.029075 / 0.141683 (-0.112608) | 1.791517 / 1.452155 (0.339363) | 1.859820 / 1.492716 (0.367104) |\n\n### Benchmark: benchmark_getitem\\_100B.json\n\n| metric | get_batch_of\\_1024\\_random_rows | get_batch_of\\_1024\\_rows | get_first_row | get_last_row |\n|--------|---|---|---|---|\n| new / old (diff) | 0.246929 / 0.018006 (0.228923) | 0.519593 / 0.000490 (0.519103) | 0.006848 / 0.000200 (0.006648) | 0.000168 / 0.000054 (0.000114) |\n\n### Benchmark: benchmark_indices_mapping.json\n\n| metric | select | shard | shuffle | sort | train_test_split |\n|--------|---|---|---|---|---|\n| new / old (diff) | 0.035179 / 0.037411 (-0.002232) | 0.115582 / 0.014526 (0.101057) | 0.128235 / 0.176557 (-0.048321) | 0.187123 / 0.737135 (-0.550012) | 0.120862 / 0.296338 (-0.175477) |\n\n### Benchmark: benchmark_iterating.json\n\n| metric | read 5000 | read 50000 | read_batch 50000 10 | read_batch 50000 100 | read_batch 50000 1000 | read_formatted numpy 5000 | read_formatted pandas 5000 | read_formatted tensorflow 5000 | read_formatted torch 5000 | read_formatted_batch numpy 5000 10 | read_formatted_batch numpy 5000 1000 | shuffled read 5000 | shuffled read 50000 | shuffled read_batch 50000 10 | shuffled read_batch 50000 100 | shuffled read_batch 50000 1000 | shuffled read_formatted numpy 5000 | shuffled read_formatted_batch numpy 5000 10 | shuffled read_formatted_batch numpy 5000 1000 |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.463406 / 0.215209 (0.248197) | 4.615517 / 2.077655 (2.537863) | 2.250513 / 1.504120 (0.746393) | 2.061226 / 1.541195 (0.520032) | 2.189938 / 1.468490 (0.721448) | 0.582984 / 4.584777 (-4.001793) | 4.299464 / 3.745712 (0.553751) | 4.037274 / 5.269862 (-1.232588) | 2.608967 / 4.565676 (-1.956710) | 0.068944 / 0.424275 (-0.355331) | 0.009501 / 0.007607 (0.001894) | 0.567436 / 0.226044 (0.341392) | 5.662738 / 2.268929 (3.393809) | 2.849094 / 55.444624 (-52.595530) | 2.461013 / 6.876477 (-4.415464) | 2.663245 / 2.142072 (0.521172) | 0.704528 / 4.805227 (-4.100699) | 0.163583 / 6.500664 (-6.337081) | 0.075719 / 0.075469 (0.000250) |\n\n### Benchmark: benchmark_map_filter.json\n\n| metric | filter | map fast-tokenizer batched | map identity | map identity batched | map no-op batched | map no-op batched numpy | map no-op batched pandas | map no-op batched pytorch | map no-op batched tensorflow |\n|--------|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 1.604743 / 1.841788 (-0.237044) | 24.512054 / 8.074308 (16.437746) | 17.870939 / 10.191392 (7.679547) | 0.199188 / 0.680424 (-0.481236) | 0.023820 / 0.534201 (-0.510381) | 0.487520 / 0.579283 (-0.091763) | 0.512543 / 0.434364 (0.078179) | 0.575138 / 0.540337 (0.034801) | 0.759863 / 1.386936 (-0.627073) |\n\n</details>\nPyArrow==latest\n\n<details>\n<summary>Show updated benchmarks!</summary>\n\n### Benchmark: benchmark_array_xd.json\n\n| metric | read_batch_formatted_as_numpy after write_array2d | read_batch_formatted_as_numpy after write_flattened_sequence | read_batch_formatted_as_numpy after write_nested_sequence | read_batch_unformated after write_array2d | read_batch_unformated after write_flattened_sequence | read_batch_unformated after write_nested_sequence | read_col_formatted_as_numpy after write_array2d | read_col_formatted_as_numpy after write_flattened_sequence | read_col_formatted_as_numpy after write_nested_sequence | read_col_unformated after write_array2d | read_col_unformated after write_flattened_sequence | read_col_unformated after write_nested_sequence | read_formatted_as_numpy after write_array2d | read_formatted_as_numpy after write_flattened_sequence | read_formatted_as_numpy after write_nested_sequence | read_unformated after write_array2d | read_unformated after write_flattened_sequence | read_unformated after write_nested_sequence | write_array2d | write_flattened_sequence | write_nested_sequence |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.010516 / 0.011353 (-0.000837) | 0.004779 / 0.011008 (-0.006229) | 0.078482 / 0.038508 (0.039974) | 0.108533 / 0.023109 (0.085424) | 0.498692 / 0.275898 (0.222794) | 0.534698 / 0.323480 (0.211218) | 0.007624 / 0.007986 (-0.000362) | 0.003938 / 0.004328 (-0.000391) | 0.077317 / 0.004250 (0.073067) | 0.078056 / 0.037052 (0.041004) | 0.493648 / 0.258489 (0.235159) | 0.540891 / 0.293841 (0.247050) | 0.040377 / 0.128546 (-0.088169) | 0.010155 / 0.075646 (-0.065491) | 0.084384 / 0.419271 (-0.334888) | 0.061419 / 0.043533 (0.017886) | 0.494474 / 0.255139 (0.239335) | 0.524656 / 0.283200 (0.241456) | 0.029052 / 0.141683 (-0.112631) | 1.794584 / 1.452155 (0.342429) | 1.939987 / 1.492716 (0.447270) |\n\n### Benchmark: benchmark_getitem\\_100B.json\n\n| metric | get_batch_of\\_1024\\_random_rows | get_batch_of\\_1024\\_rows | get_first_row | get_last_row |\n|--------|---|---|---|---|\n| new / old (diff) | 0.377404 / 0.018006 (0.359398) | 0.516562 / 0.000490 (0.516072) | 0.109555 / 0.000200 (0.109356) | 0.001126 / 0.000054 (0.001071) |\n\n### Benchmark: benchmark_indices_mapping.json\n\n| metric | select | shard | shuffle | sort | train_test_split |\n|--------|---|---|---|---|---|\n| new / old (diff) | 0.039793 / 0.037411 (0.002382) | 0.123001 / 0.014526 (0.108475) | 0.127536 / 0.176557 (-0.049021) | 0.191681 / 0.737135 (-0.545455) | 0.128590 / 0.296338 (-0.167748) |\n\n### Benchmark: benchmark_iterating.json\n\n| metric | read 5000 | read 50000 | read_batch 50000 10 | read_batch 50000 100 | read_batch 50000 1000 | read_formatted numpy 5000 | read_formatted pandas 5000 | read_formatted tensorflow 5000 | read_formatted torch 5000 | read_formatted_batch numpy 5000 10 | read_formatted_batch numpy 5000 1000 | shuffled read 5000 | shuffled read 50000 | shuffled read_batch 50000 10 | shuffled read_batch 50000 100 | shuffled read_batch 50000 1000 | shuffled read_formatted numpy 5000 | shuffled read_formatted_batch numpy 5000 10 | shuffled read_formatted_batch numpy 5000 1000 |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.513689 / 0.215209 (0.298480) | 5.135114 / 2.077655 (3.057459) | 2.797885 / 1.504120 (1.293765) | 2.715332 / 1.541195 (1.174137) | 2.746437 / 1.468490 (1.277947) | 0.596480 / 4.584777 (-3.988297) | 4.382013 / 3.745712 (0.636301) | 3.965956 / 5.269862 (-1.303906) | 2.545206 / 4.565676 (-2.020471) | 0.069620 / 0.424275 (-0.354655) | 0.009321 / 0.007607 (0.001714) | 0.612424 / 0.226044 (0.386379) | 6.107037 / 2.268929 (3.838109) | 3.447246 / 55.444624 (-51.997379) | 3.073262 / 6.876477 (-3.803215) | 3.280185 / 2.142072 (1.138113) | 0.704776 / 4.805227 (-4.100451) | 0.160488 / 6.500664 (-6.340176) | 0.075730 / 0.075469 (0.000261) |\n\n### Benchmark: benchmark_map_filter.json\n\n| metric | filter | map fast-tokenizer batched | map identity | map identity batched | map no-op batched | map no-op batched numpy | map no-op batched pandas | map no-op batched pytorch | map no-op batched tensorflow |\n|--------|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 1.697035 / 1.841788 (-0.144753) | 24.766118 / 8.074308 (16.691809) | 18.476699 / 10.191392 (8.285307) | 0.176594 / 0.680424 (-0.503830) | 0.024249 / 0.534201 (-0.509952) | 0.478743 / 0.579283 (-0.100541) | 0.518774 / 0.434364 (0.084410) | 0.581498 / 0.540337 (0.041161) | 0.797784 / 1.386936 (-0.589152) |\n\n</details>\n</details>\n\n![](https://cml.dev/watermark.png#722cea0f4929ff4ffcdbb7ca6b72cba229b9701a \"CML watermark\")\n" ]
"2023-09-12T06:53:06Z"
"2023-09-13T18:20:50Z"
"2023-09-13T18:10:04Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/6233.diff", "html_url": "https://github.com/huggingface/datasets/pull/6233", "merged_at": "2023-09-13T18:10:04Z", "patch_url": "https://github.com/huggingface/datasets/pull/6233.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/6233" }
fixed a typo
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/6233/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/6233/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/6221
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/6221/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/6221/comments
https://api.github.com/repos/huggingface/datasets/issues/6221/events
https://github.com/huggingface/datasets/issues/6221
1,884,324,631
I_kwDODunzps5wUIMX
6,221
Support saving datasets with custom formatting
{ "avatar_url": "https://avatars.githubusercontent.com/u/47462742?v=4", "events_url": "https://api.github.com/users/mariosasko/events{/privacy}", "followers_url": "https://api.github.com/users/mariosasko/followers", "following_url": "https://api.github.com/users/mariosasko/following{/other_user}", "gists_url": "https://api.github.com/users/mariosasko/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mariosasko", "id": 47462742, "login": "mariosasko", "node_id": "MDQ6VXNlcjQ3NDYyNzQy", "organizations_url": "https://api.github.com/users/mariosasko/orgs", "received_events_url": "https://api.github.com/users/mariosasko/received_events", "repos_url": "https://api.github.com/users/mariosasko/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mariosasko/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mariosasko/subscriptions", "type": "User", "url": "https://api.github.com/users/mariosasko" }
[]
open
false
null
[]
null
[ "Not a fan of pickling this sort of stuff either.\r\nNote that users can also share the code in their dataset documentation." ]
"2023-09-06T16:03:32Z"
"2023-09-06T18:32:07Z"
null
CONTRIBUTOR
null
null
null
Requested in https://discuss.huggingface.co/t/using-set-transform-on-a-dataset-leads-to-an-exception/53036. I am not sure if supporting this is the best idea for the following reasons: >For this to work, we would have to pickle a custom transform, which means the transform and the objects it references need to be serializable. Also, deserializing these bytes would make `load_from_disk` unsafe, so I'm not sure this is a good idea. @lhoestq WDYT?
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/6221/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/6221/timeline
null
null
false
https://api.github.com/repos/huggingface/datasets/issues/2718
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/2718/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/2718/comments
https://api.github.com/repos/huggingface/datasets/issues/2718/events
https://github.com/huggingface/datasets/pull/2718
953,360,663
MDExOlB1bGxSZXF1ZXN0Njk3NDE0NTQy
2,718
New documentation structure
{ "avatar_url": "https://avatars.githubusercontent.com/u/59462357?v=4", "events_url": "https://api.github.com/users/stevhliu/events{/privacy}", "followers_url": "https://api.github.com/users/stevhliu/followers", "following_url": "https://api.github.com/users/stevhliu/following{/other_user}", "gists_url": "https://api.github.com/users/stevhliu/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/stevhliu", "id": 59462357, "login": "stevhliu", "node_id": "MDQ6VXNlcjU5NDYyMzU3", "organizations_url": "https://api.github.com/users/stevhliu/orgs", "received_events_url": "https://api.github.com/users/stevhliu/received_events", "repos_url": "https://api.github.com/users/stevhliu/repos", "site_admin": false, "starred_url": "https://api.github.com/users/stevhliu/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/stevhliu/subscriptions", "type": "User", "url": "https://api.github.com/users/stevhliu" }
[]
closed
false
null
[]
null
[ "I just did some minor changes + added some content in these sections: share, about arrow, about cache\r\n\r\nFeel free to mark this PR as ready for review ! :)", "I just separated the `Share` How-to page into three pages: share, dataset_script and dataset_card.\r\n\r\nThis way in the share page we can explain in more details how to share a community or a canonical dataset - focus in their differences and the steps to upload them.\r\n\r\nAlso given that making a dataset script or a dataset card both require several steps, I feel like it's better to have dedicated pages for them.\r\n\r\nLet me know what you think @stevhliu and others. We can still revert this change if you feel like it was better with everything in the same place.", "I just added some minor changes to match the style, fix typos, etc. Great work on the conceptual guides, I learned a lot from them and I'm sure they will help a lot of other people too!\r\n\r\nI am fine with splitting `Share` into three separate pages. I think this probably makes it easier for users to navigate, instead of having to scroll up and down on a really long single page.", "Thanks a lot for all the suggestions ! I'm doing the final changes based on the remaining comments, then we can merge and release v1.12 of `datasets` and the new documentation ^^", "Alright I think I took all the suggestions and comments into account :)\r\nThanks everyone for the help !" ]
"2021-07-26T23:15:13Z"
"2021-09-13T17:20:53Z"
"2021-09-13T17:20:52Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/2718.diff", "html_url": "https://github.com/huggingface/datasets/pull/2718", "merged_at": "2021-09-13T17:20:52Z", "patch_url": "https://github.com/huggingface/datasets/pull/2718.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/2718" }
Organize Datasets documentation into four documentation types to improve clarity and discoverability of content. **Content to add in the very short term (feel free to add anything I'm missing):** - A discussion on why Datasets uses Arrow that includes some context and background about why we use Arrow. Would also be great to talk about Datasets speed and performance here, and if you can share any benchmarking/tests you did, that would be awesome! Finally, a discussion about how memory-mapping frees the user from RAM constraints would be very helpful. - Explain why you would want to disable or override verifications when loading a dataset. - If possible, include a code sample of when the number of elements in the field of an output dictionary aren’t the same as the other fields in the output dictionary (taken from the [note](https://huggingface.co/docs/datasets/processing.html#augmenting-the-dataset) here).
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/2718/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/2718/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/3850
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/3850/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/3850/comments
https://api.github.com/repos/huggingface/datasets/issues/3850/events
https://github.com/huggingface/datasets/pull/3850
1,162,126,030
PR_kwDODunzps40FBx9
3,850
[feat] Add tqdm arguments
{ "avatar_url": "https://avatars.githubusercontent.com/u/28087825?v=4", "events_url": "https://api.github.com/users/penguinwang96825/events{/privacy}", "followers_url": "https://api.github.com/users/penguinwang96825/followers", "following_url": "https://api.github.com/users/penguinwang96825/following{/other_user}", "gists_url": "https://api.github.com/users/penguinwang96825/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/penguinwang96825", "id": 28087825, "login": "penguinwang96825", "node_id": "MDQ6VXNlcjI4MDg3ODI1", "organizations_url": "https://api.github.com/users/penguinwang96825/orgs", "received_events_url": "https://api.github.com/users/penguinwang96825/received_events", "repos_url": "https://api.github.com/users/penguinwang96825/repos", "site_admin": false, "starred_url": "https://api.github.com/users/penguinwang96825/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/penguinwang96825/subscriptions", "type": "User", "url": "https://api.github.com/users/penguinwang96825" }
[]
closed
false
null
[]
null
[]
"2022-03-08T01:53:25Z"
"2022-12-16T05:34:07Z"
"2022-12-16T05:34:07Z"
NONE
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/3850.diff", "html_url": "https://github.com/huggingface/datasets/pull/3850", "merged_at": null, "patch_url": "https://github.com/huggingface/datasets/pull/3850.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/3850" }
In this PR, tqdm arguments can be passed to the map() function and such, in order to be more flexible.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/3850/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/3850/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/3523
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/3523/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/3523/comments
https://api.github.com/repos/huggingface/datasets/issues/3523/events
https://github.com/huggingface/datasets/pull/3523
1,093,819,227
PR_kwDODunzps4wiJc2
3,523
Added links to licensing and PII message in vctk dataset
{ "avatar_url": "https://avatars.githubusercontent.com/u/26722925?v=4", "events_url": "https://api.github.com/users/mcmillanmajora/events{/privacy}", "followers_url": "https://api.github.com/users/mcmillanmajora/followers", "following_url": "https://api.github.com/users/mcmillanmajora/following{/other_user}", "gists_url": "https://api.github.com/users/mcmillanmajora/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mcmillanmajora", "id": 26722925, "login": "mcmillanmajora", "node_id": "MDQ6VXNlcjI2NzIyOTI1", "organizations_url": "https://api.github.com/users/mcmillanmajora/orgs", "received_events_url": "https://api.github.com/users/mcmillanmajora/received_events", "repos_url": "https://api.github.com/users/mcmillanmajora/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mcmillanmajora/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mcmillanmajora/subscriptions", "type": "User", "url": "https://api.github.com/users/mcmillanmajora" }
[]
closed
false
null
[]
null
[]
"2022-01-04T22:56:58Z"
"2022-01-06T19:33:50Z"
"2022-01-06T19:33:50Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/3523.diff", "html_url": "https://github.com/huggingface/datasets/pull/3523", "merged_at": "2022-01-06T19:33:50Z", "patch_url": "https://github.com/huggingface/datasets/pull/3523.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/3523" }
null
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/3523/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/3523/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/4827
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/4827/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/4827/comments
https://api.github.com/repos/huggingface/datasets/issues/4827/events
https://github.com/huggingface/datasets/pull/4827
1,335,994,312
PR_kwDODunzps49B1zi
4,827
Add license metadata to pg19
{ "avatar_url": "https://avatars.githubusercontent.com/u/326577?v=4", "events_url": "https://api.github.com/users/julien-c/events{/privacy}", "followers_url": "https://api.github.com/users/julien-c/followers", "following_url": "https://api.github.com/users/julien-c/following{/other_user}", "gists_url": "https://api.github.com/users/julien-c/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/julien-c", "id": 326577, "login": "julien-c", "node_id": "MDQ6VXNlcjMyNjU3Nw==", "organizations_url": "https://api.github.com/users/julien-c/orgs", "received_events_url": "https://api.github.com/users/julien-c/received_events", "repos_url": "https://api.github.com/users/julien-c/repos", "site_admin": false, "starred_url": "https://api.github.com/users/julien-c/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/julien-c/subscriptions", "type": "User", "url": "https://api.github.com/users/julien-c" }
[]
closed
false
null
[]
null
[ "_The documentation is not available anymore as the PR was closed or merged._" ]
"2022-08-11T13:52:20Z"
"2022-08-11T15:01:03Z"
"2022-08-11T14:46:38Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/4827.diff", "html_url": "https://github.com/huggingface/datasets/pull/4827", "merged_at": "2022-08-11T14:46:38Z", "patch_url": "https://github.com/huggingface/datasets/pull/4827.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/4827" }
As reported over email by Roy Rijkers
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/4827/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/4827/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/4610
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/4610/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/4610/comments
https://api.github.com/repos/huggingface/datasets/issues/4610/events
https://github.com/huggingface/datasets/issues/4610
1,290,603,827
I_kwDODunzps5M7Q0z
4,610
codeparrot/github-code failing to load
{ "avatar_url": "https://avatars.githubusercontent.com/u/29863388?v=4", "events_url": "https://api.github.com/users/PyDataBlog/events{/privacy}", "followers_url": "https://api.github.com/users/PyDataBlog/followers", "following_url": "https://api.github.com/users/PyDataBlog/following{/other_user}", "gists_url": "https://api.github.com/users/PyDataBlog/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/PyDataBlog", "id": 29863388, "login": "PyDataBlog", "node_id": "MDQ6VXNlcjI5ODYzMzg4", "organizations_url": "https://api.github.com/users/PyDataBlog/orgs", "received_events_url": "https://api.github.com/users/PyDataBlog/received_events", "repos_url": "https://api.github.com/users/PyDataBlog/repos", "site_admin": false, "starred_url": "https://api.github.com/users/PyDataBlog/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/PyDataBlog/subscriptions", "type": "User", "url": "https://api.github.com/users/PyDataBlog" }
[ { "color": "d73a4a", "default": true, "description": "Something isn't working", "id": 1935892857, "name": "bug", "node_id": "MDU6TGFiZWwxOTM1ODkyODU3", "url": "https://api.github.com/repos/huggingface/datasets/labels/bug" } ]
closed
false
{ "avatar_url": "https://avatars.githubusercontent.com/u/42851186?v=4", "events_url": "https://api.github.com/users/lhoestq/events{/privacy}", "followers_url": "https://api.github.com/users/lhoestq/followers", "following_url": "https://api.github.com/users/lhoestq/following{/other_user}", "gists_url": "https://api.github.com/users/lhoestq/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/lhoestq", "id": 42851186, "login": "lhoestq", "node_id": "MDQ6VXNlcjQyODUxMTg2", "organizations_url": "https://api.github.com/users/lhoestq/orgs", "received_events_url": "https://api.github.com/users/lhoestq/received_events", "repos_url": "https://api.github.com/users/lhoestq/repos", "site_admin": false, "starred_url": "https://api.github.com/users/lhoestq/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/lhoestq/subscriptions", "type": "User", "url": "https://api.github.com/users/lhoestq" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/42851186?v=4", "events_url": "https://api.github.com/users/lhoestq/events{/privacy}", "followers_url": "https://api.github.com/users/lhoestq/followers", "following_url": "https://api.github.com/users/lhoestq/following{/other_user}", "gists_url": "https://api.github.com/users/lhoestq/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/lhoestq", "id": 42851186, "login": "lhoestq", "node_id": "MDQ6VXNlcjQyODUxMTg2", "organizations_url": "https://api.github.com/users/lhoestq/orgs", "received_events_url": "https://api.github.com/users/lhoestq/received_events", "repos_url": "https://api.github.com/users/lhoestq/repos", "site_admin": false, "starred_url": "https://api.github.com/users/lhoestq/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/lhoestq/subscriptions", "type": "User", "url": "https://api.github.com/users/lhoestq" } ]
null
[ "I believe the issue is in `codeparrot/github-code`. `base_path` param is missing - https://huggingface.co/datasets/codeparrot/github-code/blob/main/github-code.py#L169\r\n\r\nFunction definition has changed.\r\nhttps://github.com/huggingface/datasets/blob/0e1c629cfb9f9ba124537ba294a0ec451584da5f/src/datasets/data_files.py#L547\r\n\r\n@mariosasko could you please confirm my finding? And are there any changes that need to be done from my side?", "Good catch ! We recently did a breaking change in `get_patterns_in_dataset_repository`, I think we can revert it", "> Good catch ! We recently did a breaking change in `get_patterns_in_dataset_repository`, I think we can revert it\n\nI can't wait for that releasee. Broke my application", "This simple workaround should fix: https://huggingface.co/datasets/codeparrot/github-code/discussions/2\r\n\r\n`get_patterns_in_dataset_repository` can treat whether `base_path=None`, so we just need to make sure that codeparrot/github-code `_split_generators` calls with such an argument.", "I am afraid your suggested change @gugarosa will break compatibility with older datasets versions that don't have `base_path` argument in `get_patterns_in_dataset_repository`, as a workaround while the issue gets resolved in `datasets` can you downgrade your datasets version to `<=2.1.0` ? \r\n@lvwerra do you think we should adapt the script to check the datasets version before calling `get_patterns_in_dataset_repository`?", "Actually I think it's just simpler to fix it in the dataset itself, let me open a PR\r\n\r\nEDIT: PR opened here: https://huggingface.co/datasets/codeparrot/github-code/discussions/3", "PR is merged, it's working now ! Closing this one :)", "> I am afraid your suggested change @gugarosa will break compatibility with older datasets versions that don't have `base_path` argument in `get_patterns_in_dataset_repository`, as a workaround while the issue gets resolved in `datasets` can you downgrade your datasets version to `<=2.1.0` ?\r\n> @lvwerra do you think we should adapt the script to check the datasets version before calling `get_patterns_in_dataset_repository`?\r\n\r\nYou are definitely right, sorry about it. I always keep forgetting that we need to keep in mind users from past versions, my bad." ]
"2022-06-30T20:24:48Z"
"2022-07-05T14:24:13Z"
"2022-07-05T09:19:56Z"
NONE
null
null
null
## Describe the bug codeparrot/github-code fails to load with a `TypeError: get_patterns_in_dataset_repository() missing 1 required positional argument: 'base_path'` ## Steps to reproduce the bug ```python from datasets import load_dataset ``` ## Expected results loaded dataset object ## Actual results ```python [3]: dataset = load_dataset("codeparrot/github-code") No config specified, defaulting to: github-code/all-all Downloading and preparing dataset github-code/all-all to /home/bebr/.cache/huggingface/datasets/codeparrot___github-code/all-all/0.0.0/a55513bc0f81db773f9896c7aac225af0cff5b323bb9d2f68124f0a8cc3fb817... --------------------------------------------------------------------------- TypeError Traceback (most recent call last) Input In [3], in <cell line: 1>() ----> 1 dataset = load_dataset("codeparrot/github-code") File ~/miniconda3/envs/fastapi-kube/lib/python3.10/site-packages/datasets/load.py:1679, in load_dataset(path, name, data_dir, data_files, split, cache_dir, features, download_config, download_mode, ignore_verifications, keep_in_memory, save_infos, revision, use_auth_token, task, streaming, **config_kwargs) 1676 try_from_hf_gcs = path not in _PACKAGED_DATASETS_MODULES 1678 # Download and prepare data -> 1679 builder_instance.download_and_prepare( 1680 download_config=download_config, 1681 download_mode=download_mode, 1682 ignore_verifications=ignore_verifications, 1683 try_from_hf_gcs=try_from_hf_gcs, 1684 use_auth_token=use_auth_token, 1685 ) 1687 # Build dataset for splits 1688 keep_in_memory = ( 1689 keep_in_memory if keep_in_memory is not None else is_small_dataset(builder_instance.info.dataset_size) 1690 ) File ~/miniconda3/envs/fastapi-kube/lib/python3.10/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 706 ) 707 # Sync info 708 self.info.dataset_size = sum(split.num_bytes for split in self.info.splits.values()) File ~/miniconda3/envs/fastapi-kube/lib/python3.10/site-packages/datasets/builder.py:1221, in GeneratorBasedBuilder._download_and_prepare(self, dl_manager, verify_infos) 1220 def _download_and_prepare(self, dl_manager, verify_infos): -> 1221 super()._download_and_prepare(dl_manager, verify_infos, check_duplicate_keys=verify_infos) File ~/miniconda3/envs/fastapi-kube/lib/python3.10/site-packages/datasets/builder.py:771, in DatasetBuilder._download_and_prepare(self, dl_manager, verify_infos, **prepare_split_kwargs) 769 split_dict = SplitDict(dataset_name=self.name) 770 split_generators_kwargs = self._make_split_generators_kwargs(prepare_split_kwargs) --> 771 split_generators = self._split_generators(dl_manager, **split_generators_kwargs) 773 # Checksums verification 774 if verify_infos and dl_manager.record_checksums: File ~/.cache/huggingface/modules/datasets_modules/datasets/codeparrot--github-code/a55513bc0f81db773f9896c7aac225af0cff5b323bb9d2f68124f0a8cc3fb817/github-code.py:169, in GithubCode._split_generators(self, dl_manager) 162 def _split_generators(self, dl_manager): 164 hfh_dataset_info = HfApi(datasets.config.HF_ENDPOINT).dataset_info( 165 _REPO_NAME, 166 timeout=100.0, 167 ) --> 169 patterns = datasets.data_files.get_patterns_in_dataset_repository(hfh_dataset_info) 170 data_files = datasets.data_files.DataFilesDict.from_hf_repo( 171 patterns, 172 dataset_info=hfh_dataset_info, 173 ) 175 files = dl_manager.download_and_extract(data_files["train"]) TypeError: get_patterns_in_dataset_repository() missing 1 required positional argument: 'base_path' ``` ## Environment info - `datasets` version: 2.3.2 - Platform: Linux-5.18.7-arch1-1-x86_64-with-glibc2.35 - Python version: 3.10.5 - PyArrow version: 8.0.0 - Pandas version: 1.4.2
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/4610/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/4610/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/5251
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5251/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5251/comments
https://api.github.com/repos/huggingface/datasets/issues/5251/events
https://github.com/huggingface/datasets/issues/5251
1,451,761,321
I_kwDODunzps5WiB6p
5,251
Docs are not generated after latest release
{ "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" }
[ { "color": "d4c5f9", "default": false, "description": "Maintenance tasks", "id": 4296013012, "name": "maintenance", "node_id": "LA_kwDODunzps8AAAABAA_01A", "url": "https://api.github.com/repos/huggingface/datasets/labels/maintenance" } ]
closed
false
null
[]
null
[ "After a discussion with @mishig25:\r\n- He said that this action should be triggered if we call our release branch according to the regex `v*-release`, as transformers does\r\n- I said that our procedure is different: our release branch is *temporary* and it is deleted just after the release PR is merged to main\r\n - Indeed the release tag is not yet created when we make the release PR (not event when this is merged to main), but when we make the Release itself.\r\n\r\nI was thinking that maybe we could change the triggering event: use `release` instead of `push`.\r\n\r\nWhat do you think, @huggingface/datasets?", "Why is it an issue if our branch is temporary ?", "He says not; but the branch has no tag yet; does the doc building require the tag? Or just the version number in `__init__.py` or setup.py?", "It uses `module.__version__` (i.e. the one defined in `__init__.py`) - no need to have a tag\r\n\r\nhttps://github.com/huggingface/doc-builder/blob/81575cf081964c30ea5fd39450f4820db963f18e/src/doc_builder/commands/build.py#L69", "Thanks, @lhoestq.\r\n\r\n@mishig25 has manually forced the generation of the docs, that are live for 2.7.0 version: https://huggingface.co/docs/datasets/v2.7.0/en/index ", "Cool ! this can be closed then ?", "I was waiting for #5250 to be merged to close this.", "just to confirm, is there anything I need to do from my side ? Or is everything good here ?" ]
"2022-11-16T14:59:31Z"
"2022-11-22T16:27:50Z"
"2022-11-22T16:27:50Z"
MEMBER
null
null
null
After the latest `datasets` release version 0.7.0, the docs were not generated. As we have changed the release procedure (so that now we do not push directly to main branch), maybe we should also change the corresponding GitHub action: https://github.com/huggingface/datasets/blob/edf1902f954c5568daadebcd8754bdad44b02a85/.github/workflows/build_documentation.yml#L3-L8 Related to: - #5250 CC: @mishig25
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/5251/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5251/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/3908
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/3908/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/3908/comments
https://api.github.com/repos/huggingface/datasets/issues/3908/events
https://github.com/huggingface/datasets/pull/3908
1,168,576,963
PR_kwDODunzps40Z_9F
3,908
Update README.md for SQuAD v2 metric
{ "avatar_url": "https://avatars.githubusercontent.com/u/14205986?v=4", "events_url": "https://api.github.com/users/sashavor/events{/privacy}", "followers_url": "https://api.github.com/users/sashavor/followers", "following_url": "https://api.github.com/users/sashavor/following{/other_user}", "gists_url": "https://api.github.com/users/sashavor/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sashavor", "id": 14205986, "login": "sashavor", "node_id": "MDQ6VXNlcjE0MjA1OTg2", "organizations_url": "https://api.github.com/users/sashavor/orgs", "received_events_url": "https://api.github.com/users/sashavor/received_events", "repos_url": "https://api.github.com/users/sashavor/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sashavor/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sashavor/subscriptions", "type": "User", "url": "https://api.github.com/users/sashavor" }
[]
closed
false
null
[]
null
[ "The docs for this PR live [here](https://moon-ci-docs.huggingface.co/docs/datasets/pr_3908). All of your documentation changes will be reflected on that endpoint." ]
"2022-03-14T15:53:10Z"
"2022-03-15T17:04:11Z"
"2022-03-15T17:04:11Z"
NONE
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/3908.diff", "html_url": "https://github.com/huggingface/datasets/pull/3908", "merged_at": "2022-03-15T17:04:10Z", "patch_url": "https://github.com/huggingface/datasets/pull/3908.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/3908" }
Putting "Values from popular papers" as a subsection of "Output values"
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/3908/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/3908/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/1974
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/1974/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/1974/comments
https://api.github.com/repos/huggingface/datasets/issues/1974/events
https://github.com/huggingface/datasets/pull/1974
820,122,223
MDExOlB1bGxSZXF1ZXN0NTgzMTE5MDI0
1,974
feat(docs): navigate with left/right arrow keys
{ "avatar_url": "https://avatars.githubusercontent.com/u/32727188?v=4", "events_url": "https://api.github.com/users/ydcjeff/events{/privacy}", "followers_url": "https://api.github.com/users/ydcjeff/followers", "following_url": "https://api.github.com/users/ydcjeff/following{/other_user}", "gists_url": "https://api.github.com/users/ydcjeff/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ydcjeff", "id": 32727188, "login": "ydcjeff", "node_id": "MDQ6VXNlcjMyNzI3MTg4", "organizations_url": "https://api.github.com/users/ydcjeff/orgs", "received_events_url": "https://api.github.com/users/ydcjeff/received_events", "repos_url": "https://api.github.com/users/ydcjeff/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ydcjeff/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ydcjeff/subscriptions", "type": "User", "url": "https://api.github.com/users/ydcjeff" }
[]
closed
false
null
[]
null
[]
"2021-03-02T15:24:50Z"
"2021-03-04T10:44:12Z"
"2021-03-04T10:42:48Z"
NONE
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/1974.diff", "html_url": "https://github.com/huggingface/datasets/pull/1974", "merged_at": "2021-03-04T10:42:48Z", "patch_url": "https://github.com/huggingface/datasets/pull/1974.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/1974" }
Enables docs navigation with left/right arrow keys. It can be useful for the ones who navigate with keyboard a lot. More info : https://github.com/sphinx-doc/sphinx/pull/2064 You can try here : https://29353-250213286-gh.circle-artifacts.com/0/docs/_build/html/index.html
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/1974/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/1974/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/1409
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/1409/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/1409/comments
https://api.github.com/repos/huggingface/datasets/issues/1409/events
https://github.com/huggingface/datasets/pull/1409
760,593,932
MDExOlB1bGxSZXF1ZXN0NTM1Mzk5OTI1
1,409
Adding the ASSIN dataset
{ "avatar_url": "https://avatars.githubusercontent.com/u/5097052?v=4", "events_url": "https://api.github.com/users/jonatasgrosman/events{/privacy}", "followers_url": "https://api.github.com/users/jonatasgrosman/followers", "following_url": "https://api.github.com/users/jonatasgrosman/following{/other_user}", "gists_url": "https://api.github.com/users/jonatasgrosman/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jonatasgrosman", "id": 5097052, "login": "jonatasgrosman", "node_id": "MDQ6VXNlcjUwOTcwNTI=", "organizations_url": "https://api.github.com/users/jonatasgrosman/orgs", "received_events_url": "https://api.github.com/users/jonatasgrosman/received_events", "repos_url": "https://api.github.com/users/jonatasgrosman/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jonatasgrosman/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jonatasgrosman/subscriptions", "type": "User", "url": "https://api.github.com/users/jonatasgrosman" }
[]
closed
false
null
[]
null
[ "I wrongly commited data from another branch in this PR, I'll close this a reopen another PR with the fixed branch" ]
"2020-12-09T19:07:00Z"
"2020-12-09T19:18:12Z"
"2020-12-09T19:15:52Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/1409.diff", "html_url": "https://github.com/huggingface/datasets/pull/1409", "merged_at": null, "patch_url": "https://github.com/huggingface/datasets/pull/1409.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/1409" }
Adding the ASSIN dataset, a Portuguese language dataset for Natural Language Inference and Semantic Similarity Scoring
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/1409/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/1409/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/4972
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/4972/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/4972/comments
https://api.github.com/repos/huggingface/datasets/issues/4972/events
https://github.com/huggingface/datasets/pull/4972
1,371,443,306
PR_kwDODunzps4-3VVF
4,972
Fix map batched with torch output
{ "avatar_url": "https://avatars.githubusercontent.com/u/42851186?v=4", "events_url": "https://api.github.com/users/lhoestq/events{/privacy}", "followers_url": "https://api.github.com/users/lhoestq/followers", "following_url": "https://api.github.com/users/lhoestq/following{/other_user}", "gists_url": "https://api.github.com/users/lhoestq/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/lhoestq", "id": 42851186, "login": "lhoestq", "node_id": "MDQ6VXNlcjQyODUxMTg2", "organizations_url": "https://api.github.com/users/lhoestq/orgs", "received_events_url": "https://api.github.com/users/lhoestq/received_events", "repos_url": "https://api.github.com/users/lhoestq/repos", "site_admin": false, "starred_url": "https://api.github.com/users/lhoestq/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/lhoestq/subscriptions", "type": "User", "url": "https://api.github.com/users/lhoestq" }
[]
closed
false
null
[]
null
[ "_The documentation is not available anymore as the PR was closed or merged._" ]
"2022-09-13T13:16:34Z"
"2022-09-20T09:42:02Z"
"2022-09-20T09:39:33Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/4972.diff", "html_url": "https://github.com/huggingface/datasets/pull/4972", "merged_at": "2022-09-20T09:39:33Z", "patch_url": "https://github.com/huggingface/datasets/pull/4972.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/4972" }
Reported in https://discuss.huggingface.co/t/typeerror-when-applying-map-after-set-format-type-torch/23067/2 Currently it fails if one uses batched `map` and the map function returns a torch tensor. I fixed it for torch, tf, jax and pandas series.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/4972/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/4972/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/5450
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5450/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5450/comments
https://api.github.com/repos/huggingface/datasets/issues/5450/events
https://github.com/huggingface/datasets/issues/5450
1,551,109,365
I_kwDODunzps5cdAz1
5,450
to_tf_dataset with a TF collator causes bizarrely persistent slowdown
{ "avatar_url": "https://avatars.githubusercontent.com/u/12866554?v=4", "events_url": "https://api.github.com/users/Rocketknight1/events{/privacy}", "followers_url": "https://api.github.com/users/Rocketknight1/followers", "following_url": "https://api.github.com/users/Rocketknight1/following{/other_user}", "gists_url": "https://api.github.com/users/Rocketknight1/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Rocketknight1", "id": 12866554, "login": "Rocketknight1", "node_id": "MDQ6VXNlcjEyODY2NTU0", "organizations_url": "https://api.github.com/users/Rocketknight1/orgs", "received_events_url": "https://api.github.com/users/Rocketknight1/received_events", "repos_url": "https://api.github.com/users/Rocketknight1/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Rocketknight1/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Rocketknight1/subscriptions", "type": "User", "url": "https://api.github.com/users/Rocketknight1" }
[]
closed
false
null
[]
null
[ "wtf", "Couldn't find what's causing this, this will need more investigation", "A possible hint: The function it seems to be spending a lot of time in (when iterating over the original dataset) is `_get_mp` in the PIL JPEG decoder: \r\n![image](https://user-images.githubusercontent.com/12866554/214057267-c889f05e-efaf-4036-b805-c5381fa62f4a.png)\r\n", "If \"mp\" is multiprocessing, this might suggest some kind of negative interaction between the JPEG decoder and TF's handling of processes/threads. Note that we haven't merged the parallel `to_tf_dataset` PR yet, so it's not caused by that PR!", "Update: MP isn't multiprocessing at all, it's an internal PIL method for loading metadata from JPEG files. No idea why that would be a bottleneck, but I'll see if a Python profiler can't figure out where the time is actually being spent.", "After further profiling, the slowdown is in the C methods for JPEG decoding that are included as part of PIL. Because Python profilers can't inspect inside that, I don't have any further information on which lines exactly are responsible for the slowdown or why.\r\n\r\nIn the meantime, I'm going to suggest switching from `return_tensors=\"tf\"` to `return_tensors=\"np\"` in most of our `transformers` code - this generally works better for pre-processing. Two relevant PRs are [here](https://github.com/huggingface/transformers/pull/21266) and [here](https://github.com/huggingface/notebooks/pull/308).", "Closing this issue as we've done what we can with this one! " ]
"2023-01-20T16:08:37Z"
"2023-02-13T14:13:34Z"
"2023-02-13T14:13:34Z"
MEMBER
null
null
null
### Describe the bug This will make more sense if you take a look at [a Colab notebook that reproduces this issue.](https://colab.research.google.com/drive/1rxyeciQFWJTI0WrZ5aojp4Ls1ut18fNH?usp=sharing) Briefly, there are several datasets that, when you iterate over them with `to_tf_dataset` **and** a data collator that returns `tf` tensors, become very slow. We haven't been able to figure this one out - it can be intermittent, and we have no idea what could possibly cause it. The weirdest thing is that **the slowdown affects other attempts to access the underlying dataset**. If you try to iterate over the `tf.data.Dataset`, then interrupt execution, and then try to iterate over the original dataset, the original dataset is now also very slow! This is true even if the dataset format is not set to `tf` - the iteration is slow even though it's not calling TF at all! There is a simple workaround for this - we can simply get our data collators to return `np` tensors. When we do this, the bug is never triggered and everything is fine. In general, `np` is preferred for this kind of preprocessing work anyway, when the preprocessing is not going to be compiled into a pure `tf.data` pipeline! However, the issue is fascinating, and the TF team were wondering if anyone in datasets (cc @lhoestq @mariosasko) might have an idea of what could cause this. ### Steps to reproduce the bug Run the attached Colab. ### Expected behavior The slowdown should go away, or at least not persist after we stop iterating over the `tf.data.Dataset` ### Environment info The issue occurs on multiple versions of Python and TF, both on local machines and on Colab. All testing was done using the latest versions of `transformers` and `datasets` from `main`
{ "+1": 0, "-1": 0, "confused": 1, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 1, "url": "https://api.github.com/repos/huggingface/datasets/issues/5450/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5450/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/2268
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/2268/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/2268/comments
https://api.github.com/repos/huggingface/datasets/issues/2268/events
https://github.com/huggingface/datasets/pull/2268
868,773,380
MDExOlB1bGxSZXF1ZXN0NjI0MjQyODg1
2,268
Don't use pyarrow 4.0.0 since it segfaults when casting a sliced ListArray of integers
{ "avatar_url": "https://avatars.githubusercontent.com/u/42851186?v=4", "events_url": "https://api.github.com/users/lhoestq/events{/privacy}", "followers_url": "https://api.github.com/users/lhoestq/followers", "following_url": "https://api.github.com/users/lhoestq/following{/other_user}", "gists_url": "https://api.github.com/users/lhoestq/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/lhoestq", "id": 42851186, "login": "lhoestq", "node_id": "MDQ6VXNlcjQyODUxMTg2", "organizations_url": "https://api.github.com/users/lhoestq/orgs", "received_events_url": "https://api.github.com/users/lhoestq/received_events", "repos_url": "https://api.github.com/users/lhoestq/repos", "site_admin": false, "starred_url": "https://api.github.com/users/lhoestq/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/lhoestq/subscriptions", "type": "User", "url": "https://api.github.com/users/lhoestq" }
[]
closed
false
null
[]
null
[ "@lhoestq note that the segfault also occurs on Linux.", "Created the ticket at\r\nhttps://issues.apache.org/jira/browse/ARROW-12568", "@lhoestq the ticket you mentioned is now in state resolved. Pyarrow supports AArch64 after version 4.0.0. Because of this restriction `datasets` is not installing in AArch64 systems." ]
"2021-04-27T11:58:28Z"
"2021-06-12T12:44:49Z"
"2021-04-27T13:43:20Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/2268.diff", "html_url": "https://github.com/huggingface/datasets/pull/2268", "merged_at": "2021-04-27T13:43:20Z", "patch_url": "https://github.com/huggingface/datasets/pull/2268.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/2268" }
This test `tests/test_table.py::test_concatenation_table_cast` segfaults with the latest update of pyarrow 4.0.0. Setting `pyarrow<4.0.0` for now. I'll open an issue on JIRA once I know more about the origin of the issue
{ "+1": 1, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 1, "url": "https://api.github.com/repos/huggingface/datasets/issues/2268/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/2268/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/4598
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/4598/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/4598/comments
https://api.github.com/repos/huggingface/datasets/issues/4598/events
https://github.com/huggingface/datasets/pull/4598
1,288,774,514
PR_kwDODunzps46kfOS
4,598
Host financial_phrasebank data on the Hub
{ "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" }
[]
closed
false
null
[]
null
[ "_The documentation is not available anymore as the PR was closed or merged._" ]
"2022-06-29T13:59:31Z"
"2022-07-01T09:41:14Z"
"2022-07-01T09:29:36Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/4598.diff", "html_url": "https://github.com/huggingface/datasets/pull/4598", "merged_at": "2022-07-01T09:29:36Z", "patch_url": "https://github.com/huggingface/datasets/pull/4598.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/4598" }
Fix #4597.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/4598/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/4598/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/2982
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/2982/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/2982/comments
https://api.github.com/repos/huggingface/datasets/issues/2982/events
https://github.com/huggingface/datasets/pull/2982
1,010,118,418
PR_kwDODunzps4saVLh
2,982
Add the Math Aptitude Test of Heuristics dataset.
{ "avatar_url": "https://avatars.githubusercontent.com/u/91226467?v=4", "events_url": "https://api.github.com/users/hacobe/events{/privacy}", "followers_url": "https://api.github.com/users/hacobe/followers", "following_url": "https://api.github.com/users/hacobe/following{/other_user}", "gists_url": "https://api.github.com/users/hacobe/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/hacobe", "id": 91226467, "login": "hacobe", "node_id": "MDQ6VXNlcjkxMjI2NDY3", "organizations_url": "https://api.github.com/users/hacobe/orgs", "received_events_url": "https://api.github.com/users/hacobe/received_events", "repos_url": "https://api.github.com/users/hacobe/repos", "site_admin": false, "starred_url": "https://api.github.com/users/hacobe/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/hacobe/subscriptions", "type": "User", "url": "https://api.github.com/users/hacobe" }
[]
closed
false
null
[]
null
[]
"2021-09-28T19:18:37Z"
"2021-10-01T19:51:23Z"
"2021-10-01T12:21:00Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/2982.diff", "html_url": "https://github.com/huggingface/datasets/pull/2982", "merged_at": "2021-10-01T12:21:00Z", "patch_url": "https://github.com/huggingface/datasets/pull/2982.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/2982" }
null
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/2982/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/2982/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/4513
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/4513/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/4513/comments
https://api.github.com/repos/huggingface/datasets/issues/4513/events
https://github.com/huggingface/datasets/pull/4513
1,273,450,338
PR_kwDODunzps45xTqv
4,513
Update Google Cloud Storage documentation and add Azure Blob Storage example
{ "avatar_url": "https://avatars.githubusercontent.com/u/36760800?v=4", "events_url": "https://api.github.com/users/alvarobartt/events{/privacy}", "followers_url": "https://api.github.com/users/alvarobartt/followers", "following_url": "https://api.github.com/users/alvarobartt/following{/other_user}", "gists_url": "https://api.github.com/users/alvarobartt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/alvarobartt", "id": 36760800, "login": "alvarobartt", "node_id": "MDQ6VXNlcjM2NzYwODAw", "organizations_url": "https://api.github.com/users/alvarobartt/orgs", "received_events_url": "https://api.github.com/users/alvarobartt/received_events", "repos_url": "https://api.github.com/users/alvarobartt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/alvarobartt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/alvarobartt/subscriptions", "type": "User", "url": "https://api.github.com/users/alvarobartt" }
[ { "color": "0075ca", "default": true, "description": "Improvements or additions to documentation", "id": 1935892861, "name": "documentation", "node_id": "MDU6TGFiZWwxOTM1ODkyODYx", "url": "https://api.github.com/repos/huggingface/datasets/labels/documentation" } ]
closed
false
null
[]
null
[ "_The documentation is not available anymore as the PR was closed or merged._", "Hi @stevhliu, I've kept the `>>>` before all the in-line code comments as it was done like that in the default S3 example that was already there, I assume that it's done like that just for readiness, let me know whether we should remove the `>>>` in the Python blocks before the in-line code comments or keep them.\r\n\r\n![image](https://user-images.githubusercontent.com/36760800/174254663-b68d28d2-eae1-40f3-8695-dc4b0c3b479a.png)\r\n", "Comments are ignored by doctest, so I think we can remove the `>>>` :)", "Cool I'll remove those now 👍🏻", "Sure @lhoestq, I just kept that structure as that was the more similar one to the one that was already there, but we can go with that approach, just let me know whether I should change the headers so as to leave all those providers in the same level (`h2`). Thanks!" ]
"2022-06-16T11:46:09Z"
"2022-06-23T17:05:11Z"
"2022-06-23T16:54:59Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/4513.diff", "html_url": "https://github.com/huggingface/datasets/pull/4513", "merged_at": "2022-06-23T16:54:59Z", "patch_url": "https://github.com/huggingface/datasets/pull/4513.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/4513" }
While I was going through the 🤗 Datasets documentation of the Cloud storage filesystems at https://huggingface.co/docs/datasets/filesystems, I realized that the Google Cloud Storage documentation could be improved e.g. bullet point says "Load your dataset" when the actual call was to "Save your dataset", in-line code comment was mentioning "s3 bucket" instead of "gcs bucket", and some more in-line comments could be included. Also, I think that mixing Google Cloud Storage documentation with AWS S3's one was a little bit confusing, so I moved all those to the end of the document under an h2 tab named "Other filesystems", with an h3 for "Google Cloud Storage". Besides that, I was currently working with Azure Blob Storage and found out that the URL to [adlfs](https://github.com/fsspec/adlfs) was common for both filesystems Azure Blob Storage and Azure DataLake Storage, as well as the URL, which was updated even though the redirect was working fine, so I decided to group those under the same row in the column of supported filesystems. And took also the change to add a small documentation entry as for Google Cloud Storage but for Azure Blob Storage, as I assume that AWS S3, GCP Cloud Storage, and Azure Blob Storage, are the most used cloud storage providers. Let me know if you're OK with these changes, or whether you want me to roll back some of those! :hugs:
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/4513/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/4513/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/3765
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/3765/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/3765/comments
https://api.github.com/repos/huggingface/datasets/issues/3765/events
https://github.com/huggingface/datasets/pull/3765
1,145,126,881
PR_kwDODunzps4zMdIL
3,765
Update URL for tagging app
{ "avatar_url": "https://avatars.githubusercontent.com/u/26859204?v=4", "events_url": "https://api.github.com/users/lewtun/events{/privacy}", "followers_url": "https://api.github.com/users/lewtun/followers", "following_url": "https://api.github.com/users/lewtun/following{/other_user}", "gists_url": "https://api.github.com/users/lewtun/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/lewtun", "id": 26859204, "login": "lewtun", "node_id": "MDQ6VXNlcjI2ODU5MjA0", "organizations_url": "https://api.github.com/users/lewtun/orgs", "received_events_url": "https://api.github.com/users/lewtun/received_events", "repos_url": "https://api.github.com/users/lewtun/repos", "site_admin": false, "starred_url": "https://api.github.com/users/lewtun/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/lewtun/subscriptions", "type": "User", "url": "https://api.github.com/users/lewtun" }
[]
closed
false
null
[]
null
[ "Oh, this URL shouldn't be updated to the tagging app as it's actually used for creating the README - closing this." ]
"2022-02-20T20:34:31Z"
"2022-02-20T20:36:10Z"
"2022-02-20T20:36:06Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/3765.diff", "html_url": "https://github.com/huggingface/datasets/pull/3765", "merged_at": null, "patch_url": "https://github.com/huggingface/datasets/pull/3765.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/3765" }
This PR updates the URL for the tagging app to be the one on Spaces.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/3765/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/3765/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/5816
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/5816/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/5816/comments
https://api.github.com/repos/huggingface/datasets/issues/5816/events
https://github.com/huggingface/datasets/pull/5816
1,694,590,856
PR_kwDODunzps5Ps4t9
5,816
Preserve `stopping_strategy` of shuffled interleaved dataset (random cycling case)
{ "avatar_url": "https://avatars.githubusercontent.com/u/47462742?v=4", "events_url": "https://api.github.com/users/mariosasko/events{/privacy}", "followers_url": "https://api.github.com/users/mariosasko/followers", "following_url": "https://api.github.com/users/mariosasko/following{/other_user}", "gists_url": "https://api.github.com/users/mariosasko/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mariosasko", "id": 47462742, "login": "mariosasko", "node_id": "MDQ6VXNlcjQ3NDYyNzQy", "organizations_url": "https://api.github.com/users/mariosasko/orgs", "received_events_url": "https://api.github.com/users/mariosasko/received_events", "repos_url": "https://api.github.com/users/mariosasko/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mariosasko/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mariosasko/subscriptions", "type": "User", "url": "https://api.github.com/users/mariosasko" }
[]
closed
false
null
[]
null
[ "<details>\n<summary>Show benchmarks</summary>\n\nPyArrow==8.0.0\n\n<details>\n<summary>Show updated benchmarks!</summary>\n\n### Benchmark: benchmark_array_xd.json\n\n| metric | read_batch_formatted_as_numpy after write_array2d | read_batch_formatted_as_numpy after write_flattened_sequence | read_batch_formatted_as_numpy after write_nested_sequence | read_batch_unformated after write_array2d | read_batch_unformated after write_flattened_sequence | read_batch_unformated after write_nested_sequence | read_col_formatted_as_numpy after write_array2d | read_col_formatted_as_numpy after write_flattened_sequence | read_col_formatted_as_numpy after write_nested_sequence | read_col_unformated after write_array2d | read_col_unformated after write_flattened_sequence | read_col_unformated after write_nested_sequence | read_formatted_as_numpy after write_array2d | read_formatted_as_numpy after write_flattened_sequence | read_formatted_as_numpy after write_nested_sequence | read_unformated after write_array2d | read_unformated after write_flattened_sequence | read_unformated after write_nested_sequence | write_array2d | write_flattened_sequence | write_nested_sequence |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.007862 / 0.011353 (-0.003491) | 0.005747 / 0.011008 (-0.005261) | 0.106818 / 0.038508 (0.068310) | 0.036630 / 0.023109 (0.013521) | 0.344218 / 0.275898 (0.068320) | 0.398803 / 0.323480 (0.075324) | 0.006187 / 0.007986 (-0.001799) | 0.005686 / 0.004328 (0.001358) | 0.078568 / 0.004250 (0.074318) | 0.051786 / 0.037052 (0.014734) | 0.361736 / 0.258489 (0.103247) | 0.396323 / 0.293841 (0.102482) | 0.037943 / 0.128546 (-0.090603) | 0.013957 / 0.075646 (-0.061689) | 0.366782 / 0.419271 (-0.052490) | 0.054700 / 0.043533 (0.011167) | 0.349692 / 0.255139 (0.094553) | 0.366481 / 0.283200 (0.083281) | 0.117394 / 0.141683 (-0.024289) | 1.593156 / 1.452155 (0.141001) | 1.708864 / 1.492716 (0.216148) |\n\n### Benchmark: benchmark_getitem\\_100B.json\n\n| metric | get_batch_of\\_1024\\_random_rows | get_batch_of\\_1024\\_rows | get_first_row | get_last_row |\n|--------|---|---|---|---|\n| new / old (diff) | 0.229529 / 0.018006 (0.211523) | 0.490531 / 0.000490 (0.490042) | 0.002934 / 0.000200 (0.002734) | 0.000094 / 0.000054 (0.000040) |\n\n### Benchmark: benchmark_indices_mapping.json\n\n| metric | select | shard | shuffle | sort | train_test_split |\n|--------|---|---|---|---|---|\n| new / old (diff) | 0.028074 / 0.037411 (-0.009337) | 0.122321 / 0.014526 (0.107795) | 0.129120 / 0.176557 (-0.047436) | 0.188413 / 0.737135 (-0.548722) | 0.138983 / 0.296338 (-0.157355) |\n\n### Benchmark: benchmark_iterating.json\n\n| metric | read 5000 | read 50000 | read_batch 50000 10 | read_batch 50000 100 | read_batch 50000 1000 | read_formatted numpy 5000 | read_formatted pandas 5000 | read_formatted tensorflow 5000 | read_formatted torch 5000 | read_formatted_batch numpy 5000 10 | read_formatted_batch numpy 5000 1000 | shuffled read 5000 | shuffled read 50000 | shuffled read_batch 50000 10 | shuffled read_batch 50000 100 | shuffled read_batch 50000 1000 | shuffled read_formatted numpy 5000 | shuffled read_formatted_batch numpy 5000 10 | shuffled read_formatted_batch numpy 5000 1000 |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.479350 / 0.215209 (0.264141) | 4.926201 / 2.077655 (2.848546) | 2.265557 / 1.504120 (0.761437) | 2.014580 / 1.541195 (0.473386) | 2.120517 / 1.468490 (0.652027) | 0.795334 / 4.584777 (-3.789443) | 4.509754 / 3.745712 (0.764042) | 4.328313 / 5.269862 (-0.941548) | 2.153304 / 4.565676 (-2.412373) | 0.102942 / 0.424275 (-0.321333) | 0.053504 / 0.007607 (0.045896) | 0.609392 / 0.226044 (0.383347) | 6.114048 / 2.268929 (3.845119) | 2.773306 / 55.444624 (-52.671318) | 2.443434 / 6.876477 (-4.433042) | 2.612005 / 2.142072 (0.469932) | 0.950435 / 4.805227 (-3.854792) | 0.194081 / 6.500664 (-6.306583) | 0.074513 / 0.075469 (-0.000956) |\n\n### Benchmark: benchmark_map_filter.json\n\n| metric | filter | map fast-tokenizer batched | map identity | map identity batched | map no-op batched | map no-op batched numpy | map no-op batched pandas | map no-op batched pytorch | map no-op batched tensorflow |\n|--------|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 1.402897 / 1.841788 (-0.438891) | 18.263033 / 8.074308 (10.188724) | 16.579809 / 10.191392 (6.388417) | 0.212319 / 0.680424 (-0.468104) | 0.020468 / 0.534201 (-0.513733) | 0.494850 / 0.579283 (-0.084433) | 0.483790 / 0.434364 (0.049426) | 0.572073 / 0.540337 (0.031735) | 0.684353 / 1.386936 (-0.702583) |\n\n</details>\nPyArrow==latest\n\n<details>\n<summary>Show updated benchmarks!</summary>\n\n### Benchmark: benchmark_array_xd.json\n\n| metric | read_batch_formatted_as_numpy after write_array2d | read_batch_formatted_as_numpy after write_flattened_sequence | read_batch_formatted_as_numpy after write_nested_sequence | read_batch_unformated after write_array2d | read_batch_unformated after write_flattened_sequence | read_batch_unformated after write_nested_sequence | read_col_formatted_as_numpy after write_array2d | read_col_formatted_as_numpy after write_flattened_sequence | read_col_formatted_as_numpy after write_nested_sequence | read_col_unformated after write_array2d | read_col_unformated after write_flattened_sequence | read_col_unformated after write_nested_sequence | read_formatted_as_numpy after write_array2d | read_formatted_as_numpy after write_flattened_sequence | read_formatted_as_numpy after write_nested_sequence | read_unformated after write_array2d | read_unformated after write_flattened_sequence | read_unformated after write_nested_sequence | write_array2d | write_flattened_sequence | write_nested_sequence |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.009732 / 0.011353 (-0.001621) | 0.005901 / 0.011008 (-0.005107) | 0.084568 / 0.038508 (0.046060) | 0.038743 / 0.023109 (0.015634) | 0.431323 / 0.275898 (0.155425) | 0.472124 / 0.323480 (0.148644) | 0.006255 / 0.007986 (-0.001731) | 0.005892 / 0.004328 (0.001563) | 0.081913 / 0.004250 (0.077662) | 0.055560 / 0.037052 (0.018507) | 0.442857 / 0.258489 (0.184368) | 0.481887 / 0.293841 (0.188046) | 0.040730 / 0.128546 (-0.087816) | 0.014339 / 0.075646 (-0.061307) | 0.099258 / 0.419271 (-0.320013) | 0.054692 / 0.043533 (0.011159) | 0.436323 / 0.255139 (0.181184) | 0.461046 / 0.283200 (0.177846) | 0.125972 / 0.141683 (-0.015710) | 1.673173 / 1.452155 (0.221018) | 1.781364 / 1.492716 (0.288648) |\n\n### Benchmark: benchmark_getitem\\_100B.json\n\n| metric | get_batch_of\\_1024\\_random_rows | get_batch_of\\_1024\\_rows | get_first_row | get_last_row |\n|--------|---|---|---|---|\n| new / old (diff) | 0.271450 / 0.018006 (0.253444) | 0.514484 / 0.000490 (0.513994) | 0.000455 / 0.000200 (0.000255) | 0.000061 / 0.000054 (0.000006) |\n\n### Benchmark: benchmark_indices_mapping.json\n\n| metric | select | shard | shuffle | sort | train_test_split |\n|--------|---|---|---|---|---|\n| new / old (diff) | 0.036104 / 0.037411 (-0.001308) | 0.143306 / 0.014526 (0.128780) | 0.151105 / 0.176557 (-0.025451) | 0.210737 / 0.737135 (-0.526399) | 0.151404 / 0.296338 (-0.144934) |\n\n### Benchmark: benchmark_iterating.json\n\n| metric | read 5000 | read 50000 | read_batch 50000 10 | read_batch 50000 100 | read_batch 50000 1000 | read_formatted numpy 5000 | read_formatted pandas 5000 | read_formatted tensorflow 5000 | read_formatted torch 5000 | read_formatted_batch numpy 5000 10 | read_formatted_batch numpy 5000 1000 | shuffled read 5000 | shuffled read 50000 | shuffled read_batch 50000 10 | shuffled read_batch 50000 100 | shuffled read_batch 50000 1000 | shuffled read_formatted numpy 5000 | shuffled read_formatted_batch numpy 5000 10 | shuffled read_formatted_batch numpy 5000 1000 |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.573613 / 0.215209 (0.358404) | 5.828222 / 2.077655 (3.750567) | 2.993028 / 1.504120 (1.488908) | 2.617900 / 1.541195 (1.076706) | 2.754673 / 1.468490 (1.286183) | 1.010624 / 4.584777 (-3.574152) | 4.971261 / 3.745712 (1.225549) | 4.382017 / 5.269862 (-0.887845) | 1.971894 / 4.565676 (-2.593782) | 0.104404 / 0.424275 (-0.319871) | 0.014595 / 0.007607 (0.006988) | 0.657684 / 0.226044 (0.431639) | 6.566151 / 2.268929 (4.297222) | 3.221378 / 55.444624 (-52.223246) | 2.809402 / 6.876477 (-4.067075) | 2.882426 / 2.142072 (0.740354) | 1.006134 / 4.805227 (-3.799093) | 0.204469 / 6.500664 (-6.296196) | 0.078147 / 0.075469 (0.002678) |\n\n### Benchmark: benchmark_map_filter.json\n\n| metric | filter | map fast-tokenizer batched | map identity | map identity batched | map no-op batched | map no-op batched numpy | map no-op batched pandas | map no-op batched pytorch | map no-op batched tensorflow |\n|--------|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 1.574768 / 1.841788 (-0.267020) | 18.193335 / 8.074308 (10.119027) | 17.275353 / 10.191392 (7.083961) | 0.166890 / 0.680424 (-0.513534) | 0.020612 / 0.534201 (-0.513589) | 0.496179 / 0.579283 (-0.083104) | 0.507824 / 0.434364 (0.073460) | 0.620984 / 0.540337 (0.080647) | 0.749727 / 1.386936 (-0.637209) |\n\n</details>\n</details>\n\n![](https://cml.dev/watermark.png#06988d3e01820b93ebcdc76158339fd6f67329dc \"CML watermark\")\n", "_The documentation is not available anymore as the PR was closed or merged._", "<details>\n<summary>Show benchmarks</summary>\n\nPyArrow==8.0.0\n\n<details>\n<summary>Show updated benchmarks!</summary>\n\n### Benchmark: benchmark_array_xd.json\n\n| metric | read_batch_formatted_as_numpy after write_array2d | read_batch_formatted_as_numpy after write_flattened_sequence | read_batch_formatted_as_numpy after write_nested_sequence | read_batch_unformated after write_array2d | read_batch_unformated after write_flattened_sequence | read_batch_unformated after write_nested_sequence | read_col_formatted_as_numpy after write_array2d | read_col_formatted_as_numpy after write_flattened_sequence | read_col_formatted_as_numpy after write_nested_sequence | read_col_unformated after write_array2d | read_col_unformated after write_flattened_sequence | read_col_unformated after write_nested_sequence | read_formatted_as_numpy after write_array2d | read_formatted_as_numpy after write_flattened_sequence | read_formatted_as_numpy after write_nested_sequence | read_unformated after write_array2d | read_unformated after write_flattened_sequence | read_unformated after write_nested_sequence | write_array2d | write_flattened_sequence | write_nested_sequence |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.006534 / 0.011353 (-0.004819) | 0.004456 / 0.011008 (-0.006553) | 0.097978 / 0.038508 (0.059470) | 0.027614 / 0.023109 (0.004505) | 0.309833 / 0.275898 (0.033935) | 0.337006 / 0.323480 (0.013526) | 0.004986 / 0.007986 (-0.002999) | 0.004521 / 0.004328 (0.000193) | 0.075053 / 0.004250 (0.070803) | 0.037095 / 0.037052 (0.000043) | 0.305430 / 0.258489 (0.046941) | 0.345298 / 0.293841 (0.051457) | 0.029784 / 0.128546 (-0.098762) | 0.011449 / 0.075646 (-0.064197) | 0.323346 / 0.419271 (-0.095925) | 0.042188 / 0.043533 (-0.001345) | 0.318653 / 0.255139 (0.063514) | 0.333799 / 0.283200 (0.050599) | 0.088194 / 0.141683 (-0.053488) | 1.511012 / 1.452155 (0.058857) | 1.578205 / 1.492716 (0.085489) |\n\n### Benchmark: benchmark_getitem\\_100B.json\n\n| metric | get_batch_of\\_1024\\_random_rows | get_batch_of\\_1024\\_rows | get_first_row | get_last_row |\n|--------|---|---|---|---|\n| new / old (diff) | 0.229695 / 0.018006 (0.211689) | 0.413276 / 0.000490 (0.412786) | 0.009142 / 0.000200 (0.008942) | 0.000537 / 0.000054 (0.000482) |\n\n### Benchmark: benchmark_indices_mapping.json\n\n| metric | select | shard | shuffle | sort | train_test_split |\n|--------|---|---|---|---|---|\n| new / old (diff) | 0.024327 / 0.037411 (-0.013084) | 0.097953 / 0.014526 (0.083427) | 0.105551 / 0.176557 (-0.071005) | 0.169397 / 0.737135 (-0.567738) | 0.109784 / 0.296338 (-0.186554) |\n\n### Benchmark: benchmark_iterating.json\n\n| metric | read 5000 | read 50000 | read_batch 50000 10 | read_batch 50000 100 | read_batch 50000 1000 | read_formatted numpy 5000 | read_formatted pandas 5000 | read_formatted tensorflow 5000 | read_formatted torch 5000 | read_formatted_batch numpy 5000 10 | read_formatted_batch numpy 5000 1000 | shuffled read 5000 | shuffled read 50000 | shuffled read_batch 50000 10 | shuffled read_batch 50000 100 | shuffled read_batch 50000 1000 | shuffled read_formatted numpy 5000 | shuffled read_formatted_batch numpy 5000 10 | shuffled read_formatted_batch numpy 5000 1000 |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.417713 / 0.215209 (0.202504) | 4.190703 / 2.077655 (2.113048) | 1.873504 / 1.504120 (0.369384) | 1.664540 / 1.541195 (0.123346) | 1.704539 / 1.468490 (0.236049) | 0.699840 / 4.584777 (-3.884937) | 3.480605 / 3.745712 (-0.265107) | 1.844229 / 5.269862 (-3.425633) | 1.155793 / 4.565676 (-3.409883) | 0.083013 / 0.424275 (-0.341262) | 0.012414 / 0.007607 (0.004807) | 0.518357 / 0.226044 (0.292313) | 5.186136 / 2.268929 (2.917207) | 2.329263 / 55.444624 (-53.115361) | 1.991395 / 6.876477 (-4.885081) | 2.074563 / 2.142072 (-0.067509) | 0.801388 / 4.805227 (-4.003839) | 0.152236 / 6.500664 (-6.348428) | 0.067414 / 0.075469 (-0.008055) |\n\n### Benchmark: benchmark_map_filter.json\n\n| metric | filter | map fast-tokenizer batched | map identity | map identity batched | map no-op batched | map no-op batched numpy | map no-op batched pandas | map no-op batched pytorch | map no-op batched tensorflow |\n|--------|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 1.197290 / 1.841788 (-0.644497) | 13.666537 / 8.074308 (5.592229) | 13.017190 / 10.191392 (2.825798) | 0.142109 / 0.680424 (-0.538314) | 0.016321 / 0.534201 (-0.517880) | 0.378434 / 0.579283 (-0.200849) | 0.381101 / 0.434364 (-0.053263) | 0.444113 / 0.540337 (-0.096225) | 0.521448 / 1.386936 (-0.865488) |\n\n</details>\nPyArrow==latest\n\n<details>\n<summary>Show updated benchmarks!</summary>\n\n### Benchmark: benchmark_array_xd.json\n\n| metric | read_batch_formatted_as_numpy after write_array2d | read_batch_formatted_as_numpy after write_flattened_sequence | read_batch_formatted_as_numpy after write_nested_sequence | read_batch_unformated after write_array2d | read_batch_unformated after write_flattened_sequence | read_batch_unformated after write_nested_sequence | read_col_formatted_as_numpy after write_array2d | read_col_formatted_as_numpy after write_flattened_sequence | read_col_formatted_as_numpy after write_nested_sequence | read_col_unformated after write_array2d | read_col_unformated after write_flattened_sequence | read_col_unformated after write_nested_sequence | read_formatted_as_numpy after write_array2d | read_formatted_as_numpy after write_flattened_sequence | read_formatted_as_numpy after write_nested_sequence | read_unformated after write_array2d | read_unformated after write_flattened_sequence | read_unformated after write_nested_sequence | write_array2d | write_flattened_sequence | write_nested_sequence |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.006273 / 0.011353 (-0.005080) | 0.004408 / 0.011008 (-0.006600) | 0.077100 / 0.038508 (0.038592) | 0.027361 / 0.023109 (0.004251) | 0.358170 / 0.275898 (0.082272) | 0.390125 / 0.323480 (0.066646) | 0.004736 / 0.007986 (-0.003250) | 0.004663 / 0.004328 (0.000334) | 0.077626 / 0.004250 (0.073376) | 0.037103 / 0.037052 (0.000051) | 0.360044 / 0.258489 (0.101555) | 0.411539 / 0.293841 (0.117698) | 0.030173 / 0.128546 (-0.098373) | 0.011618 / 0.075646 (-0.064028) | 0.086036 / 0.419271 (-0.333235) | 0.039077 / 0.043533 (-0.004456) | 0.382223 / 0.255139 (0.127084) | 0.384817 / 0.283200 (0.101618) | 0.094591 / 0.141683 (-0.047092) | 1.494961 / 1.452155 (0.042807) | 1.583769 / 1.492716 (0.091053) |\n\n### Benchmark: benchmark_getitem\\_100B.json\n\n| metric | get_batch_of\\_1024\\_random_rows | get_batch_of\\_1024\\_rows | get_first_row | get_last_row |\n|--------|---|---|---|---|\n| new / old (diff) | 0.227467 / 0.018006 (0.209460) | 0.396648 / 0.000490 (0.396159) | 0.000382 / 0.000200 (0.000182) | 0.000057 / 0.000054 (0.000003) |\n\n### Benchmark: benchmark_indices_mapping.json\n\n| metric | select | shard | shuffle | sort | train_test_split |\n|--------|---|---|---|---|---|\n| new / old (diff) | 0.025346 / 0.037411 (-0.012065) | 0.102086 / 0.014526 (0.087560) | 0.108570 / 0.176557 (-0.067986) | 0.158777 / 0.737135 (-0.578359) | 0.112885 / 0.296338 (-0.183453) |\n\n### Benchmark: benchmark_iterating.json\n\n| metric | read 5000 | read 50000 | read_batch 50000 10 | read_batch 50000 100 | read_batch 50000 1000 | read_formatted numpy 5000 | read_formatted pandas 5000 | read_formatted tensorflow 5000 | read_formatted torch 5000 | read_formatted_batch numpy 5000 10 | read_formatted_batch numpy 5000 1000 | shuffled read 5000 | shuffled read 50000 | shuffled read_batch 50000 10 | shuffled read_batch 50000 100 | shuffled read_batch 50000 1000 | shuffled read_formatted numpy 5000 | shuffled read_formatted_batch numpy 5000 10 | shuffled read_formatted_batch numpy 5000 1000 |\n|--------|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 0.460731 / 0.215209 (0.245522) | 4.556450 / 2.077655 (2.478795) | 2.258185 / 1.504120 (0.754065) | 2.122584 / 1.541195 (0.581389) | 2.224638 / 1.468490 (0.756148) | 0.691909 / 4.584777 (-3.892868) | 3.482634 / 3.745712 (-0.263078) | 2.772837 / 5.269862 (-2.497024) | 1.533897 / 4.565676 (-3.031780) | 0.083025 / 0.424275 (-0.341250) | 0.012629 / 0.007607 (0.005022) | 0.548397 / 0.226044 (0.322352) | 5.492005 / 2.268929 (3.223077) | 2.669841 / 55.444624 (-52.774784) | 2.366947 / 6.876477 (-4.509529) | 2.496795 / 2.142072 (0.354722) | 0.804868 / 4.805227 (-4.000359) | 0.151686 / 6.500664 (-6.348978) | 0.068333 / 0.075469 (-0.007136) |\n\n### Benchmark: benchmark_map_filter.json\n\n| metric | filter | map fast-tokenizer batched | map identity | map identity batched | map no-op batched | map no-op batched numpy | map no-op batched pandas | map no-op batched pytorch | map no-op batched tensorflow |\n|--------|---|---|---|---|---|---|---|---|---|\n| new / old (diff) | 1.320414 / 1.841788 (-0.521374) | 14.367567 / 8.074308 (6.293258) | 14.047702 / 10.191392 (3.856310) | 0.129087 / 0.680424 (-0.551337) | 0.016658 / 0.534201 (-0.517543) | 0.381949 / 0.579283 (-0.197335) | 0.390105 / 0.434364 (-0.044258) | 0.445947 / 0.540337 (-0.094390) | 0.531074 / 1.386936 (-0.855862) |\n\n</details>\n</details>\n\n![](https://cml.dev/watermark.png#c67c9f3797ecc231b34d87ddef489c1238ec4046 \"CML watermark\")\n" ]
"2023-05-03T18:34:18Z"
"2023-05-04T14:31:55Z"
"2023-05-04T14:24:49Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/5816.diff", "html_url": "https://github.com/huggingface/datasets/pull/5816", "merged_at": "2023-05-04T14:24:49Z", "patch_url": "https://github.com/huggingface/datasets/pull/5816.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/5816" }
Preserve the `stopping_strategy` in the `RandomlyCyclingMultiSourcesExamplesIterable.shard_data_sources` to fix shuffling a dataset interleaved (from multiple sources) with probabilities. Fix #5812
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/5816/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/5816/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/1226
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/1226/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/1226/comments
https://api.github.com/repos/huggingface/datasets/issues/1226/events
https://github.com/huggingface/datasets/pull/1226
758,036,979
MDExOlB1bGxSZXF1ZXN0NTMzMjc2OTU3
1,226
Add menyo_20k_mt dataset
{ "avatar_url": "https://avatars.githubusercontent.com/u/7923902?v=4", "events_url": "https://api.github.com/users/yvonnegitau/events{/privacy}", "followers_url": "https://api.github.com/users/yvonnegitau/followers", "following_url": "https://api.github.com/users/yvonnegitau/following{/other_user}", "gists_url": "https://api.github.com/users/yvonnegitau/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/yvonnegitau", "id": 7923902, "login": "yvonnegitau", "node_id": "MDQ6VXNlcjc5MjM5MDI=", "organizations_url": "https://api.github.com/users/yvonnegitau/orgs", "received_events_url": "https://api.github.com/users/yvonnegitau/received_events", "repos_url": "https://api.github.com/users/yvonnegitau/repos", "site_admin": false, "starred_url": "https://api.github.com/users/yvonnegitau/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/yvonnegitau/subscriptions", "type": "User", "url": "https://api.github.com/users/yvonnegitau" }
[]
closed
false
null
[]
null
[ "looks like your PR includes changes about many other files than the ones for menyo 20k mt\r\nCan you create another branch and another PR please ?", "Yes, I will" ]
"2020-12-06T22:16:15Z"
"2020-12-10T19:22:14Z"
"2020-12-10T19:22:14Z"
CONTRIBUTOR
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/1226.diff", "html_url": "https://github.com/huggingface/datasets/pull/1226", "merged_at": null, "patch_url": "https://github.com/huggingface/datasets/pull/1226.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/1226" }
Add menyo_20k_mt dataset
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/1226/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/1226/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/6240
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/6240/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/6240/comments
https://api.github.com/repos/huggingface/datasets/issues/6240/events
https://github.com/huggingface/datasets/issues/6240
1,895,723,888
I_kwDODunzps5w_nNw
6,240
Dataloader stuck on multiple GPUs
{ "avatar_url": "https://avatars.githubusercontent.com/u/40049003?v=4", "events_url": "https://api.github.com/users/kuri54/events{/privacy}", "followers_url": "https://api.github.com/users/kuri54/followers", "following_url": "https://api.github.com/users/kuri54/following{/other_user}", "gists_url": "https://api.github.com/users/kuri54/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kuri54", "id": 40049003, "login": "kuri54", "node_id": "MDQ6VXNlcjQwMDQ5MDAz", "organizations_url": "https://api.github.com/users/kuri54/orgs", "received_events_url": "https://api.github.com/users/kuri54/received_events", "repos_url": "https://api.github.com/users/kuri54/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kuri54/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kuri54/subscriptions", "type": "User", "url": "https://api.github.com/users/kuri54" }
[]
closed
false
null
[]
null
[ "What type of dataset are you using in this script? `torch.utils.data.Dataset` or `datasets.Dataset`? Please share the `datasets` package version if it's the latter. Otherwise, it's better to move this issue to the `accelerate` repo.", "Very sorry, I thought I had a repo in `accelerate!`\r\nI will close this issue and repo the issue in the appropriate place." ]
"2023-09-14T05:30:30Z"
"2023-09-14T23:54:42Z"
"2023-09-14T23:54:42Z"
NONE
null
null
null
### Describe the bug I am trying to get CLIP to fine-tuning with my code. When I tried to run it on multiple GPUs using accelerate, I encountered the following phenomenon. - Validation dataloader stuck in 2nd epoch only on multi-GPU Specifically, when the "for inputs in valid_loader:" process is finished, it does not proceed to the next step. train_loader process is completed. Also, both train and valid are working correctly in the first epoch. The accelerate command at that time is as follows. `accelerate launch --multi_gpu --num_processes=2 {script_name.py} {--arg1} {--arg2} ...` - This will not happen when single GPU is used. `CUDA_VISIBLE_DEVICES="0" accelerate launch {script_name.py} --arg1 --arg2 ...` - Setting num_workers=0 in dataloader did not change the result. ### Steps to reproduce the bug 1. The codes for fine-tuning the regular CLIP were updated for accelerate. 2. Run the code with the accelerate command as `accelerate launch --multi_gpu --num_processes=2 {script_name.py} {--arg1} {--arg2} ...` and the above problem will occur. 3. CUDA_VISIBLE_DEVICES="0" accelerate launch {script_name.py} --arg1 --arg2 ...` , it works fine. ### Expected behavior It Should end normally as if it was run on a single GPU. ### Environment info Since `datasets-cli env` did not work, the environment is described below. - OS: Ubuntu 22.04 with Docker - Docker: 24.0.5, build ced0996 - Python: 3.10.12 - torch==2.0.1 - accelerate==0.21.0 - transformers==4.33.1
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/6240/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/6240/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/1475
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/1475/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/1475/comments
https://api.github.com/repos/huggingface/datasets/issues/1475/events
https://github.com/huggingface/datasets/pull/1475
762,187,000
MDExOlB1bGxSZXF1ZXN0NTM2NzYxMDQz
1,475
Fix XML iterparse in opus_dogc dataset
{ "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" }
[]
closed
false
null
[]
null
[]
"2020-12-11T10:08:18Z"
"2020-12-17T11:28:47Z"
"2020-12-17T11:28:46Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/1475.diff", "html_url": "https://github.com/huggingface/datasets/pull/1475", "merged_at": "2020-12-17T11:28:46Z", "patch_url": "https://github.com/huggingface/datasets/pull/1475.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/1475" }
I forgot to add `elem.clear()` to clear the element from memory.
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/1475/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/1475/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/3325
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/3325/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/3325/comments
https://api.github.com/repos/huggingface/datasets/issues/3325/events
https://github.com/huggingface/datasets/pull/3325
1,064,663,075
PR_kwDODunzps4vEaGO
3,325
Update conda dependencies
{ "avatar_url": "https://avatars.githubusercontent.com/u/42851186?v=4", "events_url": "https://api.github.com/users/lhoestq/events{/privacy}", "followers_url": "https://api.github.com/users/lhoestq/followers", "following_url": "https://api.github.com/users/lhoestq/following{/other_user}", "gists_url": "https://api.github.com/users/lhoestq/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/lhoestq", "id": 42851186, "login": "lhoestq", "node_id": "MDQ6VXNlcjQyODUxMTg2", "organizations_url": "https://api.github.com/users/lhoestq/orgs", "received_events_url": "https://api.github.com/users/lhoestq/received_events", "repos_url": "https://api.github.com/users/lhoestq/repos", "site_admin": false, "starred_url": "https://api.github.com/users/lhoestq/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/lhoestq/subscriptions", "type": "User", "url": "https://api.github.com/users/lhoestq" }
[]
closed
false
null
[]
null
[]
"2021-11-26T16:08:07Z"
"2021-11-26T16:20:37Z"
"2021-11-26T16:20:36Z"
MEMBER
null
0
{ "diff_url": "https://github.com/huggingface/datasets/pull/3325.diff", "html_url": "https://github.com/huggingface/datasets/pull/3325", "merged_at": "2021-11-26T16:20:36Z", "patch_url": "https://github.com/huggingface/datasets/pull/3325.patch", "url": "https://api.github.com/repos/huggingface/datasets/pulls/3325" }
Some dependencies minimum versions were outdated. For example `pyarrow` and `huggingface_hub`
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/3325/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/3325/timeline
null
null
true
https://api.github.com/repos/huggingface/datasets/issues/6256
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/6256/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/6256/comments
https://api.github.com/repos/huggingface/datasets/issues/6256/events
https://github.com/huggingface/datasets/issues/6256
1,910,275,199
I_kwDODunzps5x3Hx_
6,256
load_dataset() function's cache_dir does not seems to work
{ "avatar_url": "https://avatars.githubusercontent.com/u/171831?v=4", "events_url": "https://api.github.com/users/andyzhu/events{/privacy}", "followers_url": "https://api.github.com/users/andyzhu/followers", "following_url": "https://api.github.com/users/andyzhu/following{/other_user}", "gists_url": "https://api.github.com/users/andyzhu/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/andyzhu", "id": 171831, "login": "andyzhu", "node_id": "MDQ6VXNlcjE3MTgzMQ==", "organizations_url": "https://api.github.com/users/andyzhu/orgs", "received_events_url": "https://api.github.com/users/andyzhu/received_events", "repos_url": "https://api.github.com/users/andyzhu/repos", "site_admin": false, "starred_url": "https://api.github.com/users/andyzhu/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/andyzhu/subscriptions", "type": "User", "url": "https://api.github.com/users/andyzhu" }
[]
open
false
null
[]
null
[ "Can you share the error message?\r\n\r\nAlso, it would help if you could check whether `huggingface_hub`'s download behaves the same:\r\n```python\r\nfrom huggingface_hub import snapshot_download\r\nsnapshot_download(\"trec\", repo_type=\"dataset\", cache_dir='/path/to/my/dir)\r\n```\r\n\r\nIn the next major release, we aim to switch to `huggingface_hub` for file download/caching, but we could align the `cache_dir`'s `umask` behavior earlier than this if their solution works for your use case." ]
"2023-09-24T15:34:06Z"
"2023-09-27T13:40:45Z"
null
NONE
null
null
null
### Describe the bug datasets version: 2.14.5 when trying to run the following command trec = load_dataset('trec', split='train[:1000]', cache_dir='/path/to/my/dir') I keep getting error saying the command does not have permission to the default cache directory on my macbook pro machine. It seems the cache_dir parameter cannot change the dataset saving directory from the default what ever explained in the https://huggingface.co/docs/datasets/cache does not seem to work ### Steps to reproduce the bug datasets version: 2.14.5 when trying to run the following command trec = load_dataset('trec', split='train[:1000]', cache_dir='/path/to/my/dir') I keep getting error saying the command does not have permission to the default cache directory on my macbook pro machine. It seems the cache_dir parameter cannot change the dataset saving directory from the default what ever explained in the https://huggingface.co/docs/datasets/cache does not seem to work ### Expected behavior the dataset should be saved to the cache_dir points to ### Environment info datasets version: 2.14.5 macos X: Ventura 13.4.1 (c)
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/6256/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/6256/timeline
null
null
false
https://api.github.com/repos/huggingface/datasets/issues/2860
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/2860/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/2860/comments
https://api.github.com/repos/huggingface/datasets/issues/2860/events
https://github.com/huggingface/datasets/issues/2860
985,013,339
MDU6SXNzdWU5ODUwMTMzMzk=
2,860
Cannot download TOTTO dataset
{ "avatar_url": "https://avatars.githubusercontent.com/u/3653789?v=4", "events_url": "https://api.github.com/users/mrm8488/events{/privacy}", "followers_url": "https://api.github.com/users/mrm8488/followers", "following_url": "https://api.github.com/users/mrm8488/following{/other_user}", "gists_url": "https://api.github.com/users/mrm8488/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mrm8488", "id": 3653789, "login": "mrm8488", "node_id": "MDQ6VXNlcjM2NTM3ODk=", "organizations_url": "https://api.github.com/users/mrm8488/orgs", "received_events_url": "https://api.github.com/users/mrm8488/received_events", "repos_url": "https://api.github.com/users/mrm8488/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mrm8488/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mrm8488/subscriptions", "type": "User", "url": "https://api.github.com/users/mrm8488" }
[ { "color": "d73a4a", "default": true, "description": "Something isn't working", "id": 1935892857, "name": "bug", "node_id": "MDU6TGFiZWwxOTM1ODkyODU3", "url": "https://api.github.com/repos/huggingface/datasets/labels/bug" } ]
closed
false
{ "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/8515462?v=4", "events_url": "https://api.github.com/users/albertvillanova/events{/privacy}", "followers_url": "https://api.github.com/users/albertvillanova/followers", "following_url": "https://api.github.com/users/albertvillanova/following{/other_user}", "gists_url": "https://api.github.com/users/albertvillanova/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/albertvillanova", "id": 8515462, "login": "albertvillanova", "node_id": "MDQ6VXNlcjg1MTU0NjI=", "organizations_url": "https://api.github.com/users/albertvillanova/orgs", "received_events_url": "https://api.github.com/users/albertvillanova/received_events", "repos_url": "https://api.github.com/users/albertvillanova/repos", "site_admin": false, "starred_url": "https://api.github.com/users/albertvillanova/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/albertvillanova/subscriptions", "type": "User", "url": "https://api.github.com/users/albertvillanova" } ]
null
[ "Hola @mrm8488, thanks for reporting.\r\n\r\nApparently, the data source host changed their URL one week ago: https://github.com/google-research-datasets/ToTTo/commit/cebeb430ec2a97747e704d16a9354f7d9073ff8f\r\n\r\nI'm fixing it." ]
"2021-09-01T11:04:10Z"
"2021-09-02T06:47:40Z"
"2021-09-02T06:47:40Z"
CONTRIBUTOR
null
null
null
Error: Couldn't find file at https://storage.googleapis.com/totto/totto_data.zip `datasets version: 1.11.0` # How to reproduce: ```py from datasets import load_dataset dataset = load_dataset('totto') ```
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/huggingface/datasets/issues/2860/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/2860/timeline
null
completed
false
https://api.github.com/repos/huggingface/datasets/issues/4661
https://api.github.com/repos/huggingface/datasets
https://api.github.com/repos/huggingface/datasets/issues/4661/labels{/name}
https://api.github.com/repos/huggingface/datasets/issues/4661/comments
https://api.github.com/repos/huggingface/datasets/issues/4661/events
https://github.com/huggingface/datasets/issues/4661
1,298,374,944
I_kwDODunzps5NY6Eg
4,661
Concurrency bug when using same cache among several jobs
{ "avatar_url": "https://avatars.githubusercontent.com/u/17202292?v=4", "events_url": "https://api.github.com/users/ioana-blue/events{/privacy}", "followers_url": "https://api.github.com/users/ioana-blue/followers", "following_url": "https://api.github.com/users/ioana-blue/following{/other_user}", "gists_url": "https://api.github.com/users/ioana-blue/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ioana-blue", "id": 17202292, "login": "ioana-blue", "node_id": "MDQ6VXNlcjE3MjAyMjky", "organizations_url": "https://api.github.com/users/ioana-blue/orgs", "received_events_url": "https://api.github.com/users/ioana-blue/received_events", "repos_url": "https://api.github.com/users/ioana-blue/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ioana-blue/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ioana-blue/subscriptions", "type": "User", "url": "https://api.github.com/users/ioana-blue" }
[ { "color": "d73a4a", "default": true, "description": "Something isn't working", "id": 1935892857, "name": "bug", "node_id": "MDU6TGFiZWwxOTM1ODkyODU3", "url": "https://api.github.com/repos/huggingface/datasets/labels/bug" } ]
open
false
null
[]
null
[ "I can confirm that if I run one job first that processes the dataset, then I can run any jobs in parallel with no problem (no write-concurrency anymore...). ", "Hi! That's weird. It seems like the error points to the `mkstemp` function, but the official docs state the following:\r\n```\r\nThere are no race conditions in the file’s creation, assuming that the platform properly implements the [os.O_EXCL](https://docs.python.org/3/library/os.html#os.O_EXCL) flag for [os.open()](https://docs.python.org/3/library/os.html#os.open)\r\n```\r\nSo this could mean your platform doesn't support that flag.\r\n\r\n~~Can you please check if wrapping the temp file creation (the line `tmp_file = tempfile.NamedTemporaryFile(\"wb\", dir=os.path.dirname(cache_file_name), delete=False)` in `_map_single`) with the `multiprocess.Lock` fixes the issue?~~\r\nPerhaps wrapping the temp file creation in `_map_single` with `filelock` could work:\r\n```python\r\nwith FileLock(lock_path):\r\n tmp_file = tempfile.NamedTemporaryFile(\"wb\", dir=os.path.dirname(cache_file_name), delete=False)\r\n```\r\nCan you please check if that helps?" ]
"2022-07-08T01:58:11Z"
"2022-07-15T17:11:23Z"
null
NONE
null
null
null
## Describe the bug I used to see this bug with an older version of the datasets. It seems to persist. This is my concrete scenario: I launch several evaluation jobs on a cluster in which I share the file system and I share the cache directory used by huggingface libraries. The evaluation jobs read the same *.csv files. If my jobs get all scheduled pretty much at the same time, there are all kinds of weird concurrency errors. Sometime it crashes silently. This time I got lucky that it crashed with a stack trace that I can share and maybe you get to the bottom of this. If you don't have a similar setup available, it may be hard to reproduce as you really need two jobs accessing the same file at the same time to see this type of bug. ## Steps to reproduce the bug I'm running a modified version of `run_glue.py` script adapted to my use case. I've seen the same problem when running some glue datasets as well (so it's not specific to loading the datasets from csv files). ## Expected results No crash, concurrent access to the (intermediate) files just fine. ## Actual results Crashes due to races/concurrency bugs. ## 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.18.0-348.23.1.el8_5.x86_64-x86_64-with-glibc2.10 - Python version: 3.8.5 - PyArrow version: 8.0.0 - Pandas version: 1.1.0 Stack trace that I just got with the crash (I've obfuscated some names, it should still be quite informative): ``` Running tokenizer on dataset: 0%| | 0/3 [00:00<?, ?ba/s] Traceback (most recent call last): File "../../src/models//run_*******.py", line 600, in <module> main() File "../../src/models//run_*******.py", line 444, in main raw_datasets = raw_datasets.map( File "/*******//envs/tr-crt/lib/python3.8/site-packages/datasets/dataset_dict.py", line 770, in map { File "/*******//envs/tr-crt/lib/python3.8/site-packages/datasets/dataset_dict.py", line 771, in <dictcomp> k: dataset.map( File "/*******//envs/tr-crt/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 2376, in map return self._map_single( File "/*******/envs/tr-crt/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 551, in wrapper out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) File "/*******//envs/tr-crt/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 518, in wrapper out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) File "/*******/envs/tr-crt/lib/python3.8/site-packages/datasets/fingerprint.py", line 458, in wrapper out = func(self, *args, **kwargs) File "/*******//envs/tr-crt/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 2776, in _map_single buf_writer, writer, tmp_file = init_buffer_and_writer() File "/*******//envs/tr-crt/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 2696, in init_buffer_and_writer tmp_file = tempfile.NamedTemporaryFile("wb", dir=os.path.dirname(cache_file_name), delete=False) File "/*******//envs/tr-crt/lib/python3.8/tempfile.py", line 541, in NamedTemporaryFile (fd, name) = _mkstemp_inner(dir, prefix, suffix, flags, output_type) File "/*******//envs/tr-crt/lib/python3.8/tempfile.py", line 250, in _mkstemp_inner fd = _os.open(file, flags, 0o600) FileNotFoundError: [Errno 2] No such file or directory: '/*******/cache-transformers//transformers/csv/default-ef9cd184210742a7/0.0.0/51cce309a08df9c4d82ffd9363bbe090bf173197fc01a71b034e8594995a1a58/tmps8l6j5yc' ``` As I ran 100s of experiments last year for an empirical paper, I ran into this type of bugs several times. I found several bandaid/work-arounds, e.g., run one job first that caches the dataset => eliminate concurrency; OR use unique caches => eliminate concurrency (but increase storage space), etc. and it all works fine. I'd like to help you fixing this bug as it's really annoying to always apply the work arounds. Let me know what other info from my side could help you figure out the issue. Thanks for your help!
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 1, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 1, "url": "https://api.github.com/repos/huggingface/datasets/issues/4661/reactions" }
https://api.github.com/repos/huggingface/datasets/issues/4661/timeline
null
null
false