downloader#
Implements download and post-processing based on pooch.
- irdl.downloader._fetch(pup: Pooch, fname: str) str#
Fetch a file from a pooch registry, displaying a Rich progress bar.
- Parameters:
- pup
pooch.Pooch The Pooch instance managing the registry.
- fname
str The file name to fetch (must be registered in pup).
- pup
- Returns:
- full_path
str The absolute path to the fetched file on disk.
- full_path
- irdl.downloader._pooch_from_doi(doi: str, path: str = PosixPath('/home/runner/.cache/irdl')) Pooch#
Create a Pooch instance from a DOI.
- Parameters:
- Returns:
- pup
pooch.Pooch The Pooch instance.
- pup
- irdl.downloader._pooch_from_static_registry(path: str | Path, registry: Mapping[str, str | None], urls: Mapping[str, str]) Pooch#
Create a Pooch instance for direct static-file downloads.
- Parameters:
- path
strorpathlib.Path Directory where downloaded files should be stored.
- registry
mapping Mapping of file names to known hashes.
- urls
mapping Mapping of file names to direct download URLs.
- path
- Returns:
- pup
pooch.Pooch The Pooch instance.
- pup