Skip to content

Latest commit

 

History

19 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Thünen Earth Observation (ThEO) STAC Demo

This project demonstrates how to work with STAC (SpatioTemporal Asset Catalog) data by retrieving crop type maps from the ThEO STAC API, processing the data, and generating an animated GIF. The project uses Python along with libraries such as pystac_client, stackstac, and geogif.

Table of Contents

Overview

This repository is aimed at demonstrating how to work with remote sensing data using the ThEO STAC API. The primary goal is to show how spatial data can be accessed, processed, and visualized effectively. In particular, the script located in src/stac_demo.py retrieves crop type maps from the ThEO STAC API for a defined geographic area and time range, stacks the data into a mosaic using stackstac, and generates an animated GIF using geogif. This visual representation helps illustrate temporal variations in crop types.

The script located in src/stac_demo.py connects to a STAC API, stacks and processes the resulting data, and eventually produces an animated GIF stored in the output directory.

Environment Setup

An environment.yml file is provided to help you create the necessary environment with all required dependencies. You can create the environment using either Conda or Micromamba.

Using Conda

  1. Make sure you have Conda installed.

  2. Create the environment by running:

    conda env create -f environment.yml
  3. Activate the environment:

    conda activate theo-stac-demo

Using Micromamba

  1. Ensure you have Micromamba installed.

  2. Create the environment by running:

    micromamba create --file environment.yml
  3. Activate the environment:

    micromamba activate theo-stac-demo

Running the Code

After activating the environment, you can run the source code using the following command:

python src/stac_demo.py

The script will connect to the STAC API, process the crop type data, and generate an animated GIF saved in the output folder.

Interactive Notebook

For interactive exploration, you can use the provided Jupyter notebook src/stac_demo_notebook.ipynb. This notebook allows you to step through the workflow, experiment with parameters, and visualize results interactively as an alternative to running the Python script.

License

This project is licensed under the terms specified in the LICENSE file.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages