Installation

Installing from PyPI

Minimal installation

Install earthkit-data with python3 (>= 3.8) and pip as follows:

python3 -m pip install earthkit-data

The package installed like this is minimal supporting only GRIB and NetCDF data and cannot access remote services other than URLs. If you want to use more data types or remote services you need to install the optional Python packages.

Installing all the optional packages

You can install earthkit-data with all the optional packages in one go by using:

python3 -m pip install earthkit-data[all]

Please note in zsh you need to use quotes around the square brackets:

python3 -m pip install "earthkit-data[all]"

Installing individual optional packages

Alternatively, you can install the following components:

  • mars: provides access to the mars source

  • cds: provides access to the cds and ads sources

  • ecmwf-opendata: provides access to the ecmwf-open-data

  • wekeo: provides access to the wekeo and wekeocds sources

  • fdb: provides access to the fdb source

  • polytope: provides access to the polytope source

  • odb: provides full support for the ODB data type

  • geopandas: adds geojson/geopandas support

  • projection: adds projection support

  • eccovjson: provides access to coverage json data served by the polytope source

E.g. to add mars support you can use:

python3 -m pip install earthkit-data[mars]

List of optional dependencies can also be specified :

python3 -m pip install earthkit-data[cds,mars]

Installing with conda

Install earthkit-data via conda with:

conda install earthkit-data -c conda-forge

This will bring in some necessary binary dependencies for you.

Installing the binary dependencies

ecCodes

earthkit-data depends on the ECMWF ecCodes library that must be installed on the system and accessible as a shared library.

When earthkit-data is installed from conda ecCodes will also be installed for you. Otherwise, you need to install it using one of the following methods:

  • The easiest way to install it is to use conda:

    conda install eccodes -c conda-forge
    
  • On a MacOS it is also available from HomeBrew:

    brew install eccodes
    
  • As an alternative you may install the official source distribution by following the instructions here.

FDB

For FDB (Fields DataBase) access FDB5 must be installed on the system. See the FDB documentation for details.