oggm.utils.base_dir_to_tar

On this page

oggm.utils.base_dir_to_tar#

oggm.utils.base_dir_to_tar(base_dir: Path | str | None = None, delete: bool = True, bundle_size: int = 100) None[source]#

Merge the directories into tar bundle files.

The tar file is located at the same location of the original directory.

Parameters:
base_dirPath | str | None

Path to the basedir to parse (defaults to the working directory)

deletebool

Delete the original directory tars afterwards (default)

bundle_sizeint, default 100

Size of the glacier bundles to create. Must be either 100 (the new default, which makes for faster downloads) or 1000 (the legacy layout). With 100, the individual glacier .tar.gz files (from gdir_to_tar) are grouped into bundles named from each glacier’s RGI ID, e.g. RGI60-07.000 contains glaciers 00000-00099. Both RGI6 and RGI7 IDs are supported.