FileNotFoundError: Couldn't find file at https://drive.google.com/uc?id=12Uz59TYg_NtxOy7SXraYeXPMRT7oaO7X

#5
by aladar - opened

Hello,

Background: datasets version 2.19.2 (latest) and I haven't downloaded this before. The issue remains with download_mode="force_redownload". It happens locally and in a remote instance.

The starter code—

from datasets import load_dataset

dataset = load_dataset("SemEvalWorkshop/emo")

—raises this error:

FileNotFoundError                         Traceback (most recent call last)
Cell In[2], line 1
----> 1 dataset = load_dataset("SemEvalWorkshop/emo")

File ~/Envs/pretrain/lib/python3.11/site-packages/datasets/load.py:2614, in load_dataset(path, name, data_dir, data_files, split, cache_dir, features, download_config, download_mode, verification_mode, ignore_verifications, keep_in_memory, save_infos, revision, token, use_auth_token, task, streaming, num_proc, storage_options, trust_remote_code, **config_kwargs)
   2611     return builder_instance.as_streaming_dataset(split=split)
   2613 # Download and prepare data
-> 2614 builder_instance.download_and_prepare(
   2615     download_config=download_config,
   2616     download_mode=download_mode,
   2617     verification_mode=verification_mode,
   2618     num_proc=num_proc,
   2619     storage_options=storage_options,
   2620 )
   2622 # Build dataset for splits
   2623 keep_in_memory = (
   2624     keep_in_memory if keep_in_memory is not None else is_small_dataset(builder_instance.info.dataset_size)
   2625 )

File ~/Envs/pretrain/lib/python3.11/site-packages/datasets/builder.py:1027, in DatasetBuilder.download_and_prepare(self, output_dir, download_config, download_mode, verification_mode, ignore_verifications, try_from_hf_gcs, dl_manager, base_path, use_auth_token, file_format, max_shard_size, num_proc, storage_options, **download_and_prepare_kwargs)
   1025     if num_proc is not None:
   1026         prepare_split_kwargs["num_proc"] = num_proc
-> 1027     self._download_and_prepare(
   1028         dl_manager=dl_manager,
   1029         verification_mode=verification_mode,
   1030         **prepare_split_kwargs,
   1031         **download_and_prepare_kwargs,
   1032     )
   1033 # Sync info
   1034 self.info.dataset_size = sum(split.num_bytes for split in self.info.splits.values())

File ~/Envs/pretrain/lib/python3.11/site-packages/datasets/builder.py:1789, in GeneratorBasedBuilder._download_and_prepare(self, dl_manager, verification_mode, **prepare_splits_kwargs)
   1788 def _download_and_prepare(self, dl_manager, verification_mode, **prepare_splits_kwargs):
-> 1789     super()._download_and_prepare(
   1790         dl_manager,
   1791         verification_mode,
   1792         check_duplicate_keys=verification_mode == VerificationMode.BASIC_CHECKS
   1793         or verification_mode == VerificationMode.ALL_CHECKS,
   1794         **prepare_splits_kwargs,
   1795     )

File ~/Envs/pretrain/lib/python3.11/site-packages/datasets/builder.py:1100, in DatasetBuilder._download_and_prepare(self, dl_manager, verification_mode, **prepare_split_kwargs)
   1098 split_dict = SplitDict(dataset_name=self.dataset_name)
   1099 split_generators_kwargs = self._make_split_generators_kwargs(prepare_split_kwargs)
-> 1100 split_generators = self._split_generators(dl_manager, **split_generators_kwargs)
   1102 # Checksums verification
   1103 if verification_mode == VerificationMode.ALL_CHECKS and dl_manager.record_checksums:

File ~/.cache/huggingface/modules/datasets_modules/datasets/SemEvalWorkshop--emo/3bb182a8ea21ffa4656a89f870d16a7b75abb79f07cf990436beb9320d1d6ddd/emo.py:94, in Emo._split_generators(self, dl_manager)
     92 def _split_generators(self, dl_manager):
     93     """Returns SplitGenerators."""
---> 94     dl_train = dl_manager.download_and_extract(self._get_drive_url(_TRAIN_URL))
     95     dl_test = dl_manager.download_and_extract(self._get_drive_url(_TEST_URL))
     96     return [
     97         datasets.SplitGenerator(
     98             name=datasets.Split.TRAIN,
   (...)
    107         ),
    108     ]

File ~/Envs/pretrain/lib/python3.11/site-packages/datasets/download/download_manager.py:434, in DownloadManager.download_and_extract(self, url_or_urls)
    418 def download_and_extract(self, url_or_urls):
    419     """Download and extract given `url_or_urls`.
    420
    421     Is roughly equivalent to:
   (...)
    432         extracted_path(s): `str`, extracted paths of given URL(s).
    433     """
--> 434     return self.extract(self.download(url_or_urls))

File ~/Envs/pretrain/lib/python3.11/site-packages/datasets/download/download_manager.py:257, in DownloadManager.download(self, url_or_urls)
    255 start_time = datetime.now()
    256 with stack_multiprocessing_download_progress_bars():
--> 257     downloaded_path_or_paths = map_nested(
    258         download_func,
    259         url_or_urls,
    260         map_tuple=True,
    261         num_proc=download_config.num_proc,
    262         desc="Downloading data files",
    263         batched=True,
    264         batch_size=-1,
    265     )
    266 duration = datetime.now() - start_time
    267 logger.info(f"Downloading took {duration.total_seconds() // 60} min")

File ~/Envs/pretrain/lib/python3.11/site-packages/datasets/utils/py_utils.py:484, in map_nested(function, data_struct, dict_only, map_list, map_tuple, map_numpy, num_proc, parallel_min_length, batched, batch_size, types, disable_tqdm, desc)
    482 if batched:
    483     data_struct = [data_struct]
--> 484 mapped = function(data_struct)
    485 if batched:
    486     mapped = mapped[0]

File ~/Envs/pretrain/lib/python3.11/site-packages/datasets/download/download_manager.py:313, in DownloadManager._download_batched(self, url_or_filenames, download_config)
    300     return thread_map(
    301         download_func,
    302         url_or_filenames,
   (...)
    310         tqdm_class=tqdm,
    311     )
    312 else:
--> 313     return [
    314         self._download_single(url_or_filename, download_config=download_config)
    315         for url_or_filename in url_or_filenames
    316     ]

File ~/Envs/pretrain/lib/python3.11/site-packages/datasets/download/download_manager.py:314, in <listcomp>(.0)
    300     return thread_map(
    301         download_func,
    302         url_or_filenames,
   (...)
    310         tqdm_class=tqdm,
    311     )
    312 else:
    313     return [
--> 314         self._download_single(url_or_filename, download_config=download_config)
    315         for url_or_filename in url_or_filenames
    316     ]

File ~/Envs/pretrain/lib/python3.11/site-packages/datasets/download/download_manager.py:323, in DownloadManager._download_single(self, url_or_filename, download_config)
    320 if is_relative_path(url_or_filename):
    321     # append the relative path to the base_path
    322     url_or_filename = url_or_path_join(self._base_path, url_or_filename)
--> 323 out = cached_path(url_or_filename, download_config=download_config)
    324 out = tracked_str(out)
    325 out.set_origin(url_or_filename)

File ~/Envs/pretrain/lib/python3.11/site-packages/datasets/utils/file_utils.py:201, in cached_path(url_or_filename, download_config, **download_kwargs)
    197     url_or_filename = strip_protocol(url_or_filename)
    199 if is_remote_url(url_or_filename):
    200     # URL, so get it from the cache (downloading if necessary)
--> 201     output_path = get_from_cache(
    202         url_or_filename,
    203         cache_dir=cache_dir,
    204         force_download=download_config.force_download,
    205         proxies=download_config.proxies,
    206         resume_download=download_config.resume_download,
    207         user_agent=download_config.user_agent,
    208         local_files_only=download_config.local_files_only,
    209         use_etag=download_config.use_etag,
    210         max_retries=download_config.max_retries,
    211         token=download_config.token,
    212         ignore_url_params=download_config.ignore_url_params,
    213         storage_options=download_config.storage_options,
    214         download_desc=download_config.download_desc,
    215         disable_tqdm=download_config.disable_tqdm,
    216     )
    217 elif os.path.exists(url_or_filename):
    218     # File, and it exists.
    219     output_path = url_or_filename

File ~/Envs/pretrain/lib/python3.11/site-packages/datasets/utils/file_utils.py:630, in get_from_cache(url, cache_dir, force_download, proxies, etag_timeout, resume_download, user_agent, local_files_only, use_etag, max_retries, token, use_auth_token, ignore_url_params, storage_options, download_desc, disable_tqdm)
    625     raise FileNotFoundError(
    626         f"Cannot find the requested files in the cached path at {cache_path} and outgoing traffic has been"
    627         " disabled. To enable file online look-ups, set 'local_files_only' to False."
    628     )
    629 elif response is not None and response.status_code == 404:
--> 630     raise FileNotFoundError(f"Couldn't find file at {url}")
    631 _raise_if_offline_mode_is_enabled(f"Tried to reach {url}")
    632 if head_error is not None:

FileNotFoundError: Couldn't find file at https://drive.google.com/uc?id=12Uz59TYg_NtxOy7SXraYeXPMRT7oaO7X
aladar changed discussion status to closed
aladar changed discussion status to open

This issue was blocking me so I found the cached arrow files locally and uploaded them to https://huggingface.co/datasets/aladar/emo

Sign up or log in to comment