Home

Awesome

stactools-esa-cci-lc

PyPI

Background

A stactools package for ESA's Climate Change Initiative (CCI) Land Cover (LC) product. The ESA CCI LC dataset provides global maps describing the land surface classes, which have been defined using the United Nations Food and Agriculture Organization's (UN FAO) Land Cover Classification System (LCCS). In addition to the land cover (LC) maps, four quality flags are produced to document the reliability of the classification and change detection.

Two STAC Collections, and corresponding Items, can be generated with this package:

  1. esa-cci-lc: A Collection of COG tiles generated from the source NetCDF data files.
  2. esa-cci-lc-netcdf: A Collection describing the source NetCDF data files.

If you are interested in creating single STAC Items for each source NetCDF file along with worldwide COGs (not tiled), see release v0.1.0.

STAC Examples

The example Collections and Items in the examples directory can be created by running ./scripts/create_examples.py.

Installation

pip install stactools-esa-cci-lc

Command-line Usage

To create the NetCDF Collection:

stac esa-cci-lc netcdf create-collection collection.json

To convert a NetCDF to tiled COGs and create an Item for each tile:

stac esa-cci-lc cog create-items /path/to/source/file.nc /path/to/output/directory

Use stac esa-cci-lc --help to see all subcommands and options.

Contributing

We use pre-commit to check any changes. To set up your development environment:

pip install -e .
pip install -r requirements-dev.txt
pre-commit install

To check all files:

pre-commit run --all-files

To run the tests:

pytest -vv