The Earth Library¶

A spectral library for continuous satellite land cover mapping.
Documentation: earth-chris.github.io/earthlib
Source code: earth-chris/earthlib
Introduction¶
earthlib is a python package featuring a global spectral library. It was developed to support satellite-based land cover mapping.
The library contains a diverse catalog of unique spectral endmembers representing green vegetation, bare soil, non-photosynthetic vegetation, urban materials, and burned materials.
The reflectance data cover the visible to the shortwave infrared wavelengths (400-2450 nm) at 10 nm band widths.
earthlib provides tools to resample these spectra to match the wavelengths of popular satellite and airborne earth observing sensors. The purpose is to support running spectral mixture analysis in a sensor-agnostic fashion.
Running spectral mixture analysis across sensors with a consistent spectral library presents a new approach to creating consistent, analysis-ready data.
The goal of earthlib is to help users quantify spatial and temporal patterns of global land cover change in a sensor-generic fashion.
Installation¶
This library can be installed via pip.
pip install earthlib
You can also clone the source repository and install it locally.
git clone https://github.com/earth-chris/earthlib.git
cd earthlib
pip install -e .
The Earth Engine routines (earthlib.geelib) are not currently available. They are out of date with the v1.1 API and are being reworked. The spectral library is unaffected.
Development¶
earthlib uses pixi to manage environments.
git clone https://github.com/earth-chris/earthlib.git
cd earthlib
pixi install
Common tasks:
pixi run test # run tests with coverage
pixi run -e lint lint # format and lint (installs pre-commit hooks)
pixi run -e typecheck typecheck # run mypy
pixi run -e docs docs-serve # serve docs locally
Please commit using the development environment to ensure code is well-formatted.
Developed by¶
This package was primarily developed at the Stanford Center for Conservation Biology and Salo Sciences.