get_path#

photutils.datasets.get_path(filename, location='local', cache=True, show_progress=False)[source]#

Get the local path for a given file.

Parameters:
filenamestr

File name in the local or remote data folder.

location{‘local’, ‘remote’, ‘photutils-datasets’}

File location. 'local' means bundled with photutils. 'remote' means the astropy data server (or the photutils-datasets repo as a backup) or the Astropy cache on your machine. 'photutils-datasets' means the photutils-datasets repo or the Astropy cache on your machine.

cachebool, optional

Whether to cache the contents of remote URLs. Default is True.

show_progressbool, optional

Whether to display a progress bar during the download (default is False). The progress bar is displayed only when outputting to a terminal.

Returns:
pathstr

The local path of the file.