pooch.os_cache

Contents

pooch.os_cache#

pooch.os_cache(project)[source]#

Default cache location based on the operating system.

The folder locations are defined by the platformdirs package using the user_cache_dir function. Usually, the locations will be following (see the platformdirs documentation):

  • Mac: ~/Library/Caches/<AppName>

  • Unix: ~/.cache/<AppName> or the value of the XDG_CACHE_HOME environment variable, if defined.

  • Windows: C:\Users\<user>\AppData\Local\<AppAuthor>\<AppName>\Cache

Parameters:

project (str) – The project name.

Returns:

cache_path (pathlib.Path) – The default location for the data cache. User directories ('~') are not expanded.