svenrdz / esg-pull

Home Page:https://svenrdz.github.io/esg-pull/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

pdm-managed

esgpull - ESGF data management utility

esgpull is a tool that simplifies usage of the ESGF Search API for data discovery, and manages procedures related to downloading and storing files from ESGF.

from esgpull import Esgpull, Query

query = Query()
query.selection.project = "CMIP6"
query.options.distrib = True  # default=False
esg = Esgpull()
nb_datasets = esg.context.hits(query, file=False)[0]
nb_files = esg.context.hits(query, file=True)[0]
datasets = esg.context.datasets(query, max_hits=5)
print(f"Number of CMIP6 datasets: {nb_datasets}")
print(f"Number of CMIP6 files: {nb_files}")
for dataset in datasets:
    print(dataset)

Features

  • Command-line interface
  • HTTP download (async multi-file)

Usage

Usage: esgpull [OPTIONS] COMMAND [ARGS]...

  esgpull is a management utility for files and datasets from ESGF.

Options:
  -V, --version  Show the version and exit.
  -h, --help     Show this message and exit.

Commands:
  add       Add one or more queries to the database.
  config
  convert   Convert synda selection files to esgpull queries.
  download
  facet
  login
  remove    Remove queries
  retry
  search    Search datasets and files on ESGF
  self
  show      Show recorded query data
  status
  track     Track queries
  untrack   Untrack queries
  update

About

https://svenrdz.github.io/esg-pull/


Languages

Language:Python 99.8%Language:Mako 0.2%