Datasets created with `push_to_hub` can't be accessed in offline mode
MEMBER
Thanks for reporting. I think this can be fixed by improving the `CachedDatasetModuleFactory` and making it look into the `parquet` cache directory (datasets from push_to_hub are loaded with the parquet dataset builder). I'll look into it
2022-01-10T10:44:44Z
https://github.com/huggingface/datasets/issues/3547#issuecomment-1008746336
https://api.github.com/repos/huggingface/datasets/issues/3547
IC_kwDODunzps48ID9g
https://api.github.com/repos/huggingface/datasets/issues/comments/1008746336/reactions
2022-01-10T10:44:44Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1008746336
https://avatars.githubusercontent.com/u/42851186?v=4
https://api.github.com/users/lhoestq/events{/privacy}
https://api.github.com/users/lhoestq/followers
https://api.github.com/users/lhoestq/following{/other_user}
https://api.github.com/users/lhoestq/gists{/gist_id}
https://github.com/lhoestq
lhoestq
MDQ6VXNlcjQyODUxMTg2
https://api.github.com/users/lhoestq/orgs
https://api.github.com/users/lhoestq/received_events
https://api.github.com/users/lhoestq/repos
https://api.github.com/users/lhoestq/starred{/owner}{/repo}
https://api.github.com/users/lhoestq/subscriptions
User
https://api.github.com/users/lhoestq
public
NONE
Hi, I'm having the same issue. Is there any update on this?
2022-08-17T08:30:15Z
https://github.com/huggingface/datasets/issues/3547#issuecomment-1217680697
https://api.github.com/repos/huggingface/datasets/issues/3547
IC_kwDODunzps5IlFU5
https://api.github.com/repos/huggingface/datasets/issues/comments/1217680697/reactions
2022-08-17T08:30:15Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1217680697
https://avatars.githubusercontent.com/u/36122564?v=4
https://api.github.com/users/dangne/events{/privacy}
https://api.github.com/users/dangne/followers
https://api.github.com/users/dangne/following{/other_user}
https://api.github.com/users/dangne/gists{/gist_id}
https://github.com/dangne
dangne
MDQ6VXNlcjM2MTIyNTY0
https://api.github.com/users/dangne/orgs
https://api.github.com/users/dangne/received_events
https://api.github.com/users/dangne/repos
https://api.github.com/users/dangne/starred{/owner}{/repo}
https://api.github.com/users/dangne/subscriptions
User
https://api.github.com/users/dangne
public
MEMBER
We haven't had a chance to fix this yet. If someone would like to give it a try I'd be happy to give some guidance
2022-08-19T10:43:17Z
https://github.com/huggingface/datasets/issues/3547#issuecomment-1220527313
https://api.github.com/repos/huggingface/datasets/issues/3547
IC_kwDODunzps5Iv8TR
https://api.github.com/repos/huggingface/datasets/issues/comments/1220527313/reactions
2022-08-19T10:43:17Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1220527313
https://avatars.githubusercontent.com/u/42851186?v=4
https://api.github.com/users/lhoestq/events{/privacy}
https://api.github.com/users/lhoestq/followers
https://api.github.com/users/lhoestq/following{/other_user}
https://api.github.com/users/lhoestq/gists{/gist_id}
https://github.com/lhoestq
lhoestq
MDQ6VXNlcjQyODUxMTg2
https://api.github.com/users/lhoestq/orgs
https://api.github.com/users/lhoestq/received_events
https://api.github.com/users/lhoestq/repos
https://api.github.com/users/lhoestq/starred{/owner}{/repo}
https://api.github.com/users/lhoestq/subscriptions
User
https://api.github.com/users/lhoestq
public
CONTRIBUTOR
@lhoestq Do you have an idea of what changes need to be made to `CachedDatasetModuleFactory`? I would be willing to take a crack at it. Currently unable to train with datasets I have `push_to_hub` on a cluster whose compute nodes are not connected to the internet.

It looks like it might be this line:

https://github.com/huggingface/datasets/blob/0c1d099f87a883e52c42d3fd1f1052ad3967e647/src/datasets/load.py#L994

Which wouldn't pick up the stuff saved under `"datasets/allenai___parquet/*"`. Additionally, the datasets saved under `"datasets/allenai___parquet/*"` appear to have hashes in their name, e.g.  `"datasets/allenai___parquet/my_dataset-def9ee5552a1043e"`. This would not be detected by `CachedDatasetModuleFactory`, which currently looks for subdirectories

https://github.com/huggingface/datasets/blob/0c1d099f87a883e52c42d3fd1f1052ad3967e647/src/datasets/load.py#L995-L999
2022-08-19T16:08:16Z
https://github.com/huggingface/datasets/issues/3547#issuecomment-1220847532
https://api.github.com/repos/huggingface/datasets/issues/3547
IC_kwDODunzps5IxKes
https://api.github.com/repos/huggingface/datasets/issues/comments/1220847532/reactions
2022-08-19T16:33:24Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1220847532
https://avatars.githubusercontent.com/u/8917831?v=4
https://api.github.com/users/JohnGiorgi/events{/privacy}
https://api.github.com/users/JohnGiorgi/followers
https://api.github.com/users/JohnGiorgi/following{/other_user}
https://api.github.com/users/JohnGiorgi/gists{/gist_id}
https://github.com/JohnGiorgi
JohnGiorgi
MDQ6VXNlcjg5MTc4MzE=
https://api.github.com/users/JohnGiorgi/orgs
https://api.github.com/users/JohnGiorgi/received_events
https://api.github.com/users/JohnGiorgi/repos
https://api.github.com/users/JohnGiorgi/starred{/owner}{/repo}
https://api.github.com/users/JohnGiorgi/subscriptions
User
https://api.github.com/users/JohnGiorgi
public
MEMBER
`importable_directory_path` is used to find a **dataset script** that was previously downloaded and cached from the Hub

However in your case there's no dataset script on the Hub, only parquet files. So the logic must be extended for this case.

In particular I think you can add a new logic in the case where `hashes is None` (i.e. if there's no dataset script associated to the dataset in the cache).

In this case you can check directly in the in the datasets cache for a directory named `<namespace>__parquet` and a subdirectory named `<config_id>`. The config_id must match `{self.name.replace("/", "--")}-*`. 

In your case those two directories correspond to `allenai___parquet` and then `allenai--my_dataset-def9ee5552a1043e`

Then you can find the most recent version of the dataset in subdirectories (e.g. sorting using the last modified time of the `dataset_info.json` file).

Finally, we will need  return the module that is used to load the dataset from the cache. It is the same module than the one that would have been normally used if you had an internet connection.

At that point you can ping me, because we will need to pass all this:
- `module_path = _PACKAGED_DATASETS_MODULES["parquet"][0]`
- `hash` it corresponds the name of the directory that contains the .arrow file, inside `<namespace>__parquet/<config_id>`
- ` builder_kwargs = {"hash": hash, "repo_id": self.name, "config_id": config_id}`
and currently `config_id` is not a valid argument for a `DatasetBuilder`

I think in the future we want to change this caching logic completely, since I don't find it super easy to play with.
2022-08-24T16:39:45Z
https://github.com/huggingface/datasets/issues/3547#issuecomment-1225971588
https://api.github.com/repos/huggingface/datasets/issues/3547
IC_kwDODunzps5JEteE
https://api.github.com/repos/huggingface/datasets/issues/comments/1225971588/reactions
2022-08-24T16:39:45Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1225971588
https://avatars.githubusercontent.com/u/42851186?v=4
https://api.github.com/users/lhoestq/events{/privacy}
https://api.github.com/users/lhoestq/followers
https://api.github.com/users/lhoestq/following{/other_user}
https://api.github.com/users/lhoestq/gists{/gist_id}
https://github.com/lhoestq
lhoestq
MDQ6VXNlcjQyODUxMTg2
https://api.github.com/users/lhoestq/orgs
https://api.github.com/users/lhoestq/received_events
https://api.github.com/users/lhoestq/repos
https://api.github.com/users/lhoestq/starred{/owner}{/repo}
https://api.github.com/users/lhoestq/subscriptions
User
https://api.github.com/users/lhoestq
public
NONE
Hi! Is there a workaround for the time being?
Like passing `data_dir` or something like that?

I would like to use [this diffuser example](https://github.com/huggingface/diffusers/tree/main/examples/unconditional_image_generation) on my cluster whose nodes are not connected to the internet. I have downloaded the dataset online form the login node.
2022-09-20T14:47:58Z
https://github.com/huggingface/datasets/issues/3547#issuecomment-1252468374
https://api.github.com/repos/huggingface/datasets/issues/3547
IC_kwDODunzps5KpyaW
https://api.github.com/repos/huggingface/datasets/issues/comments/1252468374/reactions
2022-09-20T14:47:58Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1252468374
https://avatars.githubusercontent.com/u/6387497?v=4
https://api.github.com/users/zaccharieramzi/events{/privacy}
https://api.github.com/users/zaccharieramzi/followers
https://api.github.com/users/zaccharieramzi/following{/other_user}
https://api.github.com/users/zaccharieramzi/gists{/gist_id}
https://github.com/zaccharieramzi
zaccharieramzi
MDQ6VXNlcjYzODc0OTc=
https://api.github.com/users/zaccharieramzi/orgs
https://api.github.com/users/zaccharieramzi/received_events
https://api.github.com/users/zaccharieramzi/repos
https://api.github.com/users/zaccharieramzi/starred{/owner}{/repo}
https://api.github.com/users/zaccharieramzi/subscriptions
User
https://api.github.com/users/zaccharieramzi
public
MEMBER
Hi ! Yes you can save your dataset locally with `my_dataset.save_to_disk("path/to/local")` and reload it later with `load_from_disk("path/to/local")`

(removing myself from assignees since I'm currently not working on this right now)
2022-09-20T15:10:33Z
https://github.com/huggingface/datasets/issues/3547#issuecomment-1252503988
https://api.github.com/repos/huggingface/datasets/issues/3547
IC_kwDODunzps5Kp7G0
https://api.github.com/repos/huggingface/datasets/issues/comments/1252503988/reactions
2022-09-20T15:11:04Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1252503988
https://avatars.githubusercontent.com/u/42851186?v=4
https://api.github.com/users/lhoestq/events{/privacy}
https://api.github.com/users/lhoestq/followers
https://api.github.com/users/lhoestq/following{/other_user}
https://api.github.com/users/lhoestq/gists{/gist_id}
https://github.com/lhoestq
lhoestq
MDQ6VXNlcjQyODUxMTg2
https://api.github.com/users/lhoestq/orgs
https://api.github.com/users/lhoestq/received_events
https://api.github.com/users/lhoestq/repos
https://api.github.com/users/lhoestq/starred{/owner}{/repo}
https://api.github.com/users/lhoestq/subscriptions
User
https://api.github.com/users/lhoestq
public
NONE
Still not fixed? ......
2023-05-10T13:09:57Z
https://github.com/huggingface/datasets/issues/3547#issuecomment-1542188366
https://api.github.com/repos/huggingface/datasets/issues/3547
IC_kwDODunzps5b6-1O
https://api.github.com/repos/huggingface/datasets/issues/comments/1542188366/reactions
2023-05-10T13:09:57Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1542188366
https://avatars.githubusercontent.com/u/8064242?v=4
https://api.github.com/users/thuzhf/events{/privacy}
https://api.github.com/users/thuzhf/followers
https://api.github.com/users/thuzhf/following{/other_user}
https://api.github.com/users/thuzhf/gists{/gist_id}
https://github.com/thuzhf
thuzhf
MDQ6VXNlcjgwNjQyNDI=
https://api.github.com/users/thuzhf/orgs
https://api.github.com/users/thuzhf/received_events
https://api.github.com/users/thuzhf/repos
https://api.github.com/users/thuzhf/starred{/owner}{/repo}
https://api.github.com/users/thuzhf/subscriptions
User
https://api.github.com/users/thuzhf
public
CONTRIBUTOR
Any idea @lhoestq who to tag to fix this ? This is a very annoying bug, which is becoming more and more present since the push_to_hub API is getting used more ?
2023-10-26T13:13:19Z
https://github.com/huggingface/datasets/issues/3547#issuecomment-1781099259
https://api.github.com/repos/huggingface/datasets/issues/3547
IC_kwDODunzps5qKWr7
https://api.github.com/repos/huggingface/datasets/issues/comments/1781099259/reactions
2023-10-26T13:13:19Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1781099259
https://avatars.githubusercontent.com/u/43467008?v=4
https://api.github.com/users/ManuelFay/events{/privacy}
https://api.github.com/users/ManuelFay/followers
https://api.github.com/users/ManuelFay/following{/other_user}
https://api.github.com/users/ManuelFay/gists{/gist_id}
https://github.com/ManuelFay
ManuelFay
MDQ6VXNlcjQzNDY3MDA4
https://api.github.com/users/ManuelFay/orgs
https://api.github.com/users/ManuelFay/received_events
https://api.github.com/users/ManuelFay/repos
https://api.github.com/users/ManuelFay/starred{/owner}{/repo}
https://api.github.com/users/ManuelFay/subscriptions
User
https://api.github.com/users/ManuelFay
public
CONTRIBUTOR
Perhaps @mariosasko ? Thanks a lot for the great work on the lib !
2023-10-26T13:16:02Z
https://github.com/huggingface/datasets/issues/3547#issuecomment-1781104188
https://api.github.com/repos/huggingface/datasets/issues/3547
IC_kwDODunzps5qKX48
https://api.github.com/repos/huggingface/datasets/issues/comments/1781104188/reactions
2023-10-26T13:16:02Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1781104188
https://avatars.githubusercontent.com/u/43467008?v=4
https://api.github.com/users/ManuelFay/events{/privacy}
https://api.github.com/users/ManuelFay/followers
https://api.github.com/users/ManuelFay/following{/other_user}
https://api.github.com/users/ManuelFay/gists{/gist_id}
https://github.com/ManuelFay
ManuelFay
MDQ6VXNlcjQzNDY3MDA4
https://api.github.com/users/ManuelFay/orgs
https://api.github.com/users/ManuelFay/received_events
https://api.github.com/users/ManuelFay/repos
https://api.github.com/users/ManuelFay/starred{/owner}{/repo}
https://api.github.com/users/ManuelFay/subscriptions
User
https://api.github.com/users/ManuelFay
public
MEMBER
It should be easier to implement now that we improved the caching of datasets from `push_to_hub`: each dataset has its own directory in the cache.

The cache structure has been improved in https://github.com/huggingface/datasets/pull/5331. Now the cache structure is `"{namespace__}<dataset_name>/<config_name>/<version>/<hash>/"` which contains the arrow files `"<dataset_name>-<split>.arrow"` and `"dataset_info.json"`. 

The idea is to extend `CachedDatasetModuleFactory` to also check if this directory exists in the cache (in addition to the already existing cache check) and return the requested dataset module. The module name can be found in the JSON file in the `builder_name` field.
2023-10-26T13:44:58Z
https://github.com/huggingface/datasets/issues/3547#issuecomment-1781159455
https://api.github.com/repos/huggingface/datasets/issues/3547
IC_kwDODunzps5qKlYf
https://api.github.com/repos/huggingface/datasets/issues/comments/1781159455/reactions
2023-10-26T13:44:58Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1781159455
https://avatars.githubusercontent.com/u/42851186?v=4
https://api.github.com/users/lhoestq/events{/privacy}
https://api.github.com/users/lhoestq/followers
https://api.github.com/users/lhoestq/following{/other_user}
https://api.github.com/users/lhoestq/gists{/gist_id}
https://github.com/lhoestq
lhoestq
MDQ6VXNlcjQyODUxMTg2
https://api.github.com/users/lhoestq/orgs
https://api.github.com/users/lhoestq/received_events
https://api.github.com/users/lhoestq/repos
https://api.github.com/users/lhoestq/starred{/owner}{/repo}
https://api.github.com/users/lhoestq/subscriptions
User
https://api.github.com/users/lhoestq
public
NONE
Any progress?
2023-11-29T15:14:52Z
https://github.com/huggingface/datasets/issues/3547#issuecomment-1832091438
https://api.github.com/repos/huggingface/datasets/issues/3547
IC_kwDODunzps5tM38u
https://api.github.com/repos/huggingface/datasets/issues/comments/1832091438/reactions
2023-11-29T15:14:52Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1832091438
https://avatars.githubusercontent.com/u/30099658?v=4
https://api.github.com/users/Nugine/events{/privacy}
https://api.github.com/users/Nugine/followers
https://api.github.com/users/Nugine/following{/other_user}
https://api.github.com/users/Nugine/gists{/gist_id}
https://github.com/Nugine
Nugine
MDQ6VXNlcjMwMDk5NjU4
https://api.github.com/users/Nugine/orgs
https://api.github.com/users/Nugine/received_events
https://api.github.com/users/Nugine/repos
https://api.github.com/users/Nugine/starred{/owner}{/repo}
https://api.github.com/users/Nugine/subscriptions
User
https://api.github.com/users/Nugine
public
MEMBER
I started a PR to draft the logic to reload datasets from the cache fi they were created with push_to_hub: https://github.com/huggingface/datasets/pull/6459

Feel free to try it out
2023-11-29T16:57:08Z
https://github.com/huggingface/datasets/issues/3547#issuecomment-1832334480
https://api.github.com/repos/huggingface/datasets/issues/3547
IC_kwDODunzps5tNzSQ
https://api.github.com/repos/huggingface/datasets/issues/comments/1832334480/reactions
2023-11-29T16:57:27Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1832334480
https://avatars.githubusercontent.com/u/42851186?v=4
https://api.github.com/users/lhoestq/events{/privacy}
https://api.github.com/users/lhoestq/followers
https://api.github.com/users/lhoestq/following{/other_user}
https://api.github.com/users/lhoestq/gists{/gist_id}
https://github.com/lhoestq
lhoestq
MDQ6VXNlcjQyODUxMTg2
https://api.github.com/users/lhoestq/orgs
https://api.github.com/users/lhoestq/received_events
https://api.github.com/users/lhoestq/repos
https://api.github.com/users/lhoestq/starred{/owner}{/repo}
https://api.github.com/users/lhoestq/subscriptions
User
https://api.github.com/users/lhoestq
public
NONE
It seems that this does not support dataset with uppercase name 
2024-01-28T04:15:31Z
https://github.com/huggingface/datasets/issues/3547#issuecomment-1913442749
https://api.github.com/repos/huggingface/datasets/issues/3547
IC_kwDODunzps5yDNG9
https://api.github.com/repos/huggingface/datasets/issues/comments/1913442749/reactions
2024-01-28T04:15:31Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1913442749
https://avatars.githubusercontent.com/u/41792945?v=4
https://api.github.com/users/fecet/events{/privacy}
https://api.github.com/users/fecet/followers
https://api.github.com/users/fecet/following{/other_user}
https://api.github.com/users/fecet/gists{/gist_id}
https://github.com/fecet
fecet
MDQ6VXNlcjQxNzkyOTQ1
https://api.github.com/users/fecet/orgs
https://api.github.com/users/fecet/received_events
https://api.github.com/users/fecet/repos
https://api.github.com/users/fecet/starred{/owner}{/repo}
https://api.github.com/users/fecet/subscriptions
User
https://api.github.com/users/fecet
public
MEMBER
Which version of `datasets` are you using ? This issue has been fixed with `datasets` 2.16
2024-01-29T16:36:15Z
https://github.com/huggingface/datasets/issues/3547#issuecomment-1915093407
https://api.github.com/repos/huggingface/datasets/issues/3547
IC_kwDODunzps5yJgGf
https://api.github.com/repos/huggingface/datasets/issues/comments/1915093407/reactions
2024-01-29T16:36:15Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1915093407
https://avatars.githubusercontent.com/u/42851186?v=4
https://api.github.com/users/lhoestq/events{/privacy}
https://api.github.com/users/lhoestq/followers
https://api.github.com/users/lhoestq/following{/other_user}
https://api.github.com/users/lhoestq/gists{/gist_id}
https://github.com/lhoestq
lhoestq
MDQ6VXNlcjQyODUxMTg2
https://api.github.com/users/lhoestq/orgs
https://api.github.com/users/lhoestq/received_events
https://api.github.com/users/lhoestq/repos
https://api.github.com/users/lhoestq/starred{/owner}{/repo}
https://api.github.com/users/lhoestq/subscriptions
User
https://api.github.com/users/lhoestq
public
NONE
I can confirm that this problem is still happening with `datasets` 2.17.0, installed from pip
2024-02-15T17:32:55Z
https://github.com/huggingface/datasets/issues/3547#issuecomment-1946699599
https://api.github.com/repos/huggingface/datasets/issues/3547
IC_kwDODunzps50CEdP
https://api.github.com/repos/huggingface/datasets/issues/comments/1946699599/reactions
2024-02-15T17:32:55Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1946699599
https://avatars.githubusercontent.com/u/10492604?v=4
https://api.github.com/users/jaded0/events{/privacy}
https://api.github.com/users/jaded0/followers
https://api.github.com/users/jaded0/following{/other_user}
https://api.github.com/users/jaded0/gists{/gist_id}
https://github.com/jaded0
jaded0
MDQ6VXNlcjEwNDkyNjA0
https://api.github.com/users/jaded0/orgs
https://api.github.com/users/jaded0/received_events
https://api.github.com/users/jaded0/repos
https://api.github.com/users/jaded0/starred{/owner}{/repo}
https://api.github.com/users/jaded0/subscriptions
User
https://api.github.com/users/jaded0
public
MEMBER
Can you share a code or a dataset that reproduces the issue ? It seems to work fine on my side.
2024-02-15T17:35:56Z
https://github.com/huggingface/datasets/issues/3547#issuecomment-1946709388
https://api.github.com/repos/huggingface/datasets/issues/3547
IC_kwDODunzps50CG2M
https://api.github.com/repos/huggingface/datasets/issues/comments/1946709388/reactions
2024-02-15T17:35:56Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1946709388
https://avatars.githubusercontent.com/u/42851186?v=4
https://api.github.com/users/lhoestq/events{/privacy}
https://api.github.com/users/lhoestq/followers
https://api.github.com/users/lhoestq/following{/other_user}
https://api.github.com/users/lhoestq/gists{/gist_id}
https://github.com/lhoestq
lhoestq
MDQ6VXNlcjQyODUxMTg2
https://api.github.com/users/lhoestq/orgs
https://api.github.com/users/lhoestq/received_events
https://api.github.com/users/lhoestq/repos
https://api.github.com/users/lhoestq/starred{/owner}{/repo}
https://api.github.com/users/lhoestq/subscriptions
User
https://api.github.com/users/lhoestq
public
NONE
Yeah, 
```python
dataset = load_dataset("roneneldan/TinyStories")
```
I tried it with:
```python
dataset = load_dataset("roneneldan/tinystories")
```
and it worked.

> It seems that this does not support dataset with uppercase name

@fecet was right, but if you just put the name lowercase, it works. 
2024-02-15T17:41:23Z
https://github.com/huggingface/datasets/issues/3547#issuecomment-1946727335
https://api.github.com/repos/huggingface/datasets/issues/3547
IC_kwDODunzps50CLOn
https://api.github.com/repos/huggingface/datasets/issues/comments/1946727335/reactions
2024-02-15T17:41:23Z
https://api.github.com/repos/huggingface/datasets/issues/comments/1946727335
https://avatars.githubusercontent.com/u/10492604?v=4
https://api.github.com/users/jaded0/events{/privacy}
https://api.github.com/users/jaded0/followers
https://api.github.com/users/jaded0/following{/other_user}
https://api.github.com/users/jaded0/gists{/gist_id}
https://github.com/jaded0
jaded0
MDQ6VXNlcjEwNDkyNjA0
https://api.github.com/users/jaded0/orgs
https://api.github.com/users/jaded0/received_events
https://api.github.com/users/jaded0/repos
https://api.github.com/users/jaded0/starred{/owner}{/repo}
https://api.github.com/users/jaded0/subscriptions
User
https://api.github.com/users/jaded0
public
## Describe the bug
In offline mode, one can still access previously-cached datasets. This fails with datasets created with `push_to_hub`.

## Steps to reproduce the bug
in Python:
```
import datasets
mpwiki = datasets.load_dataset("teven/matched_passages_wikidata")
```
in bash:
```
export HF_DATASETS_OFFLINE=1
```
in Python:
```
import datasets
mpwiki = datasets.load_dataset("teven/matched_passages_wikidata")
```

## Expected results
`datasets` should find the previously-cached dataset.

## Actual results
ConnectionError: Couln't reach the Hugging Face Hub for dataset 'teven/matched_passages_wikidata': Offline mode is enabled

## Environment info
- `datasets` version: 1.16.2.dev0
- Platform: Linux-4.18.0-193.70.1.el8_2.x86_64-x86_64-with-glibc2.17
- Python version: 3.8.10
- PyArrow version: 3.0.0
