Commit ·
e59bf55
1
Parent(s): cca18ed
fix download
Browse files116 unmodified lines117118119120121122123124125126127128129130131116 unmodified lines# dl_manager is a datasets.download.DownloadManager that can be used to download and extract URLS# It can accept any type or nested list/dict and will give back the same structure with the url replaced with path to local files.# By default the archives will be extracted and a path to a cached folder where they are extracted is returned instead of the archiveurls = _URLS[self.config.name]data_dir = dl_manager.download(urls)print(urls, data_dir)return [datasets.SplitGenerator(name=datasets.Split.TEST,# These kwargs will be passed to _generate_examplesgen_kwargs={"filepath": os.path.join(data_dir, f"{self.config.name}.json"),"split": "test"},),116 unmodified lines117118119120121122123124125126127128129116 unmodified lines# dl_manager is a datasets.download.DownloadManager that can be used to download and extract URLS# It can accept any type or nested list/dict and will give back the same structure with the url replaced with path to local files.# By default the archives will be extracted and a path to a cached folder where they are extracted is returned instead of the archivedownloaded_files = dl_manager.download(_URLS)return [datasets.SplitGenerator(name=datasets.Split.TEST,# These kwargs will be passed to _generate_examplesgen_kwargs={"filepath": downloaded_files[self.config.name],"split": "test"},),
ipquiz.py+2-4