A comprehensive preprocessing pipeline for Sentinel-1 and Sentinel-2 satellite data, designed for agricultural remote sensing applications.
SCOUT-sentinel-processor automates the acquisition, processing, and statistical extraction of relevant metrics of SAR (eg. radar backscatter, entropy, alpha angles) and optical (NDVI) satellite data for crop monitoring.
- Sentinel-1 Processing: Automated SAR data acquisition, SNAP preprocessing, and statistical extraction
- Sentinel-2 Processing: NDVI computation and export using Google Earth Engine
- Multi-field Support: Process individual agricultural fields or regions of interest
- Configurable Workflows: Modular design allowing selective execution of processing steps
- Automated scene discovery via Copernicus Data Space
- Configurable satellite selection (S1A, S1B, or both), acquisition modes (IW, EW, SM) and polarizations (VV, VH, HH, HV)
- SNAP-based preprocessing with custom graphs
- Field subsetting and statistical extraction
- Google Earth Engine integration for scalable processing
- Cloud probability filtering
- Daily-averaged NDVI computation
- Multi-field processing support
- Automated statistics extraction
- YAML-based configuration management
- Support for multiple vector formats (KML, GeoJSON, Shapefile)
SCOUT-sentinel-processor/
├── config/
│ └── config.yml # Main configuration
├── sentinel1/
│ ├── s1_find_ids.py # Scene discovery
│ ├── s1_download_from_csv.py # Data download
│ ├── subset_raster.py # Field subsetting
│ ├── extract_stats.py # Statistical extraction
│ └── snap_graphs/ # SNAP processing graphs
├── sentinel2/
│ ├── cli.py # Command-line interface
│ ├── ndvi_exporter.py # NDVI computation
│ └── extract_ndvi_stats.py # Statistics extraction
├── scripts/ # Execution scripts
│ ├── run_sentinel1.sh # bash script for running workflow of Sentinel-1 (backscatter and polarimetry examples)
│ └── run_sentinel2.sh # bash script for running workflow of Sentinel-2 (NDVI)
├── data/ # Output data directory
├── kml/ # Area of interest files
└── logs/ # Processing logs
- Python 3.7+
- Google Earth Engine account and authentication
- Copernicus Data Space account
- SNAP (Sentinel Application Platform)
# Install dependencies
pip install -r requirements.txt
# Authenticate Google Earth Engine
earthengine authenticate
# Configure Copernicus credentials in config/config.ymlThe system uses config/config.yml to manage all processing parameters:
workflow:
find_ids: 1 # Enable scene discovery
download: 1 # Enable data download
pre_process: 1 # Enable preprocessing
subset: 1 # Enable field subsetting
extract_metric: 1 # Enable statistics extraction
input:
aoi_path: "../kml/Eitelsried_Fields_kml" # Individual field KMLs
aoi_path_total: "../kml/Eitelsried_Fields_total.kml" # Combined AOI
start_date: "2025-04-01"
end_date: "2025-05-31"
output:
base_dir: "../data"
sentinel1:
satellite: "BOTH" # S1A, S1B, or BOTH
mode: "IW" # IW, EW, SM
level: "SLC" # SLC, GRD
polarisation: "VV+VH" # VV, VH, HH, HV, VV+VH, HH+HV
snap:
gpt_path: "/path/to/snap/bin/gpt"
dem_path: "/path/to/dem.tif"
sentinel2:
cloud_threshold: 15Sentinel-1 and Sentinel-2 preprocessing are done independently and do not rely on one another aside from sharing the same area of interest and timespan inputted in the config file.
cd scripts
./run_sentinel1.shEither toggle 1 and 0 where wanted in the config file. All steps can work independently (ie only one step can be 1 whilst all the others are 0). Another way to run individual steps could be through their python script directly:
# Find available scenes
python sentinel1/s1_find_ids.py --config config/config.yml
# Download scenes
python sentinel1/s1_download_from_csv.py --config config/config.yml
# Subset to fields
python sentinel1/subset_raster.py --config config/config.yml
# Extract statistics
python sentinel1/extract_stats.py --config config/config.ymlcd scripts
./run_sentinel2.sh# NDVI export with statistics
python cli.py --config ../config/config.yml --extract_stats
# Extract statistics from existing files
python cli.py --config ../config/config.yml --extract-existing-only- Scene Discovery: Query Copernicus Data Space for available scenes
- Data Download: Download selected scenes to local storage
- Preprocessing: Apply SNAP processing graphs
- Field Subsetting: Extract data for individual fields
- Statistics Extraction: Compute statistical metrics
- Area Processing: Process each field/area of interest
- Cloud Filtering: Filter scenes by cloud probability
- NDVI Computation: Calculate daily-averaged NDVI
- Data Export: Export GeoTIFF files
- Statistics Extraction: Compute field-level statistics
Input KML → Scene Discovery → Download → Preprocessing → Subsetting → Statistics
↓
Field Boundaries → Cloud Filtering → NDVI Computation → Export → Analysis