Cannot load TREC dataset: ConnectionError
See original GitHub issueProblem
I cannot load “trec” dataset, it results with ConnectionError as shown below. I’ve tried on both Google Colab and locally.
requests.head('http://cogcomp.org/Data/QA/QC/train_5500.label')
returns <Response [302]>.requests.head('http://cogcomp.org/Data/QA/QC/train_5500.label', allow_redirects=True)
raisesrequests.exceptions.TooManyRedirects: Exceeded 30 redirects.
- Opening `http://cogcomp.org/Data/QA/QC/train_5500.label’ in a browser works, but opens a different address
- Increasing max_redirects to 100 doesn’t help
Also, while debugging I’ve seen that requesting ‘https://storage.googleapis.com/huggingface-nlp/cache/datasets/trec/default/1.1.0/dataset_info.json’ returns <Response [404]> before, but it doesn’t raise any errors. Not sure if that’s relevant.
- datasets.version == ‘1.1.2’
- requests.version == ‘2.24.0’
Error trace
>>> import datasets
>>> datasets.__version__
'1.1.2'
>>> dataset = load_dataset("trec", split="train")
Using custom data configuration default
Downloading and preparing dataset trec/default (download: 350.79 KiB, generated: 403.39 KiB, post-processed: Unknown size, total: 754.18 KiB) to /home/przemyslaw/.cache/huggingface/datasets/trec/default/1.1.0/ca4248481ad244f235f4cf277186cad2ee8769f975119a2bbfc41b8932b88bd7...
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/przemyslaw/.local/lib/python3.6/site-packages/datasets/load.py", line 611, in load_dataset
ignore_verifications=ignore_verifications,
File "/home/przemyslaw/.local/lib/python3.6/site-packages/datasets/builder.py", line 476, in download_and_prepare
dl_manager=dl_manager, verify_infos=verify_infos, **download_and_prepare_kwargs
File "/home/przemyslaw/.local/lib/python3.6/site-packages/datasets/builder.py", line 531, in _download_and_prepare
split_generators = self._split_generators(dl_manager, **split_generators_kwargs)
File "/home/przemyslaw/.cache/huggingface/modules/datasets_modules/datasets/trec/ca4248481ad244f235f4cf277186cad2ee8769f975119a2bbfc41b8932b88bd7/trec.py", line 140, in _split_generators
dl_files = dl_manager.download_and_extract(_URLs)
File "/home/przemyslaw/.local/lib/python3.6/site-packages/datasets/utils/download_manager.py", line 254, in download_and_extract
return self.extract(self.download(url_or_urls))
File "/home/przemyslaw/.local/lib/python3.6/site-packages/datasets/utils/download_manager.py", line 179, in download
num_proc=download_config.num_proc,
File "/home/przemyslaw/.local/lib/python3.6/site-packages/datasets/utils/py_utils.py", line 225, in map_nested
_single_map_nested((function, obj, types, None, True)) for obj in tqdm(iterable, disable=disable_tqdm)
File "/home/przemyslaw/.local/lib/python3.6/site-packages/datasets/utils/py_utils.py", line 225, in <listcomp>
_single_map_nested((function, obj, types, None, True)) for obj in tqdm(iterable, disable=disable_tqdm)
File "/home/przemyslaw/.local/lib/python3.6/site-packages/datasets/utils/py_utils.py", line 163, in _single_map_nested
return function(data_struct)
File "/home/przemyslaw/.local/lib/python3.6/site-packages/datasets/utils/file_utils.py", line 308, in cached_path
use_etag=download_config.use_etag,
File "/home/przemyslaw/.local/lib/python3.6/site-packages/datasets/utils/file_utils.py", line 475, in get_from_cache
raise ConnectionError("Couldn't reach {}".format(url))
ConnectionError: Couldn't reach http://cogcomp.org/Data/QA/QC/train_5500.label
I would appreciate some suggestions here.
Issue Analytics
- State:
- Created 3 years ago
- Reactions:1
- Comments:9 (6 by maintainers)
Top Results From Across the Web
frahman/github-issues · Datasets at Hugging Face
Describe the bug I get `ConnectionError` when I am trying to load the SciELO dataset. When I try the URL with `requests` I...
Read more >Cannot Load File. It Is Either an Unsupported Media Type or ...
TREC: If this error occurs after recording, the TREC file may be corrupt and unrecoverable. Make sure media is imported from a local...
Read more >tensorflow keras datasets doesn't load ConnectionError?
Here is my code Everytime I run I get connectionError [WinError 10054] An existing connection was forcibly closed by the remote host: import ......
Read more >Untitled
Syf motif design competition, Pawn shops open sunday, Logit stata help, ... Nbi clearance database, Turbo c not showing output, Pirate arena!
Read more >HuggingFace datasets library - Overview - Colaboratory
This call to datasets.load_dataset() does the following steps under the hood: Download and import in the library the SQuAD python processing script from ......
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Forgot to update, i wrote an email to the webmaster of seas.upenn.edu because i couldnt reach the url on any machine. This was the answer:
Guess all back to normal now 🙂
Hi ! The URL seems to work fine on my side, can you try again ?