Multi satellite reader allowing you to load bands and index and stack them.
Project description
EOReader
EOReader is a multi-satellite reader allowing you to open optical and SAR data.
Optical | SAR | |
---|---|---|
Sensors | + Sentinel-2 & Theia + Sentinel-3 OLCI & SLSTR + Landsats 1 - 8 |
+ Sentinel-1 + COSMO-Skymed + TerraSAR-X + RADARSAT-2 |
It also implements additional sensor-agnostic features:
eoreader.products.product.Product.load
: Load many band types:- satellite bands (optical or SAR)
- index
- cloud bands
- DEM bands
eoreader.products.product.Product.stack
: Stack all these type of bands
EOReader works with xarrays.DataArray
and geopandas.GeoDataFrames
Python Quickstart
The main features of EOReader are gathered hereunder. For optical data:
>>> from eoreader.reader import Reader
>>> from eoreader.bands.alias import *
>>> # Your variables
>>> l5_path = "D:/eoreader/CI/DATA/LM05_L1TP_200029_19841014_20200902_02_T2.tar"
>>> # Create the reader object and open satellite data
>>> eoreader = Reader()
>>> l5_prod = eoreader.open(l5_path) # The Reader will recognize the satellite type from its name
>>> # Get the footprint of the product (usable data) and its extent (envelope of the tile)
>>> footprint = l5_prod.footprint
>>> extent = l5_prod.extent
>>> # Load some bands and index: they will all share the same metadata
>>> bands = l5_prod.load([NDVI, GREEN, HILLSHADE, CLOUDS]
>>> # Create a stack with some other bands
>>> stack = l5_prod.stack([NDWI, RED, SLOPE])
>>> # Read Metadata
>>> mtd, namespace = l5_prod.read_mtd()
For SAR data:
>>> from eoreader.reader import Reader
>>> from eoreader.bands.alias import *
>>> # Your variables
>>> s1_path = "D:/eoreader/S1B_EW_GRDM_1SDH_20200422T080459_20200422T080559_021254_028559_784D.zip" # Not in the package
>>> # Create the reader object and open satellite data
>>> eoreader = Reader()
>>> s1_prod = eoreader.open(s1_path) # The Reader will recognize the satellite type from its name
>>> # Get the footprint of the product (usable data) and its extent (envelope of the tile)
>>> footprint = s1_prod.footprint
>>> extent = s1_prod.extent
>>> # Load some bands and index: they will all share the same metadata
>>> bands = s1_prod.load([VV, VV_DSPK, DEM]
>>> # Create a stack with some other bands
>>> stack = s1_prod.stack([VV, VV_DSPK, SLOPE])
>>> # Read Metadata
>>> mtd, namespace = s1_prod.read_mtd()
Sentinel-3 and SAR products need SNAP gpt
to be geocoded.
Ensure that you have the folder containing your gpt.exe
in your PATH
.
Documentation
The API documentation can be found here.
Examples
Available notebooks provided as examples:
Installation
pip install eoreader
or conda install eoreader
EOReader mainly relies on geopandas
and rasterio
(through rioxarray
).
On Windows and with pip, you may face installation issues due to GDAL. The well known workaround of installing from Gohlke's wheels also applies here. Please look at the rasterio page to learn more about that.
License
EOReader is licensed under Apache License v2.0. See LICENSE file for details.
Authors
EOReader has been created by ICube-SERTIT.
Credits
EOReader is built on top of amazing libs, without which it couldn't have been coded:
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.