class pooch.Pooch(path, base_url, registry=None, urls=None)[source]

Manager for a local data storage that can fetch from a remote source.

path : str

The path to the local data storage folder. The path must exist in the file system.

base_url : str

Base URL for the remote data source. All requests will be made relative to this URL.

registry : dict or None

A record of the files that are managed by this good boy. Keys should be the file names and the values should be their SHA256 hashes. Only files in the registry can be fetched from the local storage. Files in subdirectories of path must use Unix-style separators ('/') even on Windows.

urls : dict or None

Custom URLs for downloading individual files in the registry. A dictionary with the file names as keys and the custom URLs as values. Not all files in registry need an entry in urls. If a file has an entry in urls, the base_url will be ignored when downloading it in favor of urls[fname].


Absolute path to the local storage


fetch(fname) Get the absolute path to a file in the local storage.
load_registry(fname) Load entries form a file and add them to the registry.