A Python-based automated dInSAR processing toolkit for surface deformation analysis using Sentinel-1 and ISCE2
Still work in progress!!
Automated, modular, and robust wrapper around the ISCE2 topsApp.py workflow for Sentinel-1 InSAR processing.
Designed for reproducible end-to-end processing: search β download β preprocess β run ISCE β visualize displacement.
This document combines the project overview and example notebook guide into a single, structured README.
-
Modular Architecture
-
Separate managers for SLC search/download, orbit retrieval, DEM preparation, and ISCE execution.
-
Robust DEM Strategy
-
Automatically builds a DEM covering the full SLC intersection + internal safety buffer.
-
Prevents
runTopoedge errors in mountainous or high-relief terrain. -
ROI-Focused Processing
-
Processing window is limited to the user ROI for stability and speed.
-
Automated Auxiliary Data
-
Precise orbits (POEORB) with RESORB fallback.
-
DEM download via
dem_stitcher(GLO-30 / SRTM). -
Modern Python Environment
-
Python 3.10 + Conda compatible.
-
Notebook-friendly workflow.
graph TD
User[User Configuration] -->|ROI & Dates| SLC[SLC Manager]
SLC -->|Scene Metadata| Orbit[Orbit Manager]
SLC -->|Geometry Bounds| DEM[DEM Manager]
SLC -->|Inputs| Proc[ISCE Processor]
Orbit -->|Orbit Files| Proc
DEM -->|Buffered DEM| Proc
Proc -->|Generate topsApp.xml<br>&<br> Run ISCE topsApp.py| Outputs[InSAR Products]
./
βββ main.py
βββ environment.yml
βββ README.md
βββ modules/
β βββ __init__.py
β βββ SLC_manager.py
β βββ orbit_manager.py
β βββ DEM_manager.py
β βββ isce_processor.py
β βββ auth_base.py
βββ examples/
βββ ISCE_processor(INSAR_main).ipynb
βββ S1SLCManager.ipynb
βββ OrbitManager.ipynb
βββ DEMManager.ipynb
βββ README.md
git clone https://github.com/YONGHUNI/dInSAR-Toolkit.git
cd dInSAR-Toolkit
conda env create -f environment.yml
conda activate insar_envmain.py is configured via command-line arguments (not by editing constants inside the file).
Required arguments:
- ROI bounding box (min_lon min_lat max_lon max_lat)
- Start / end date
Example:
python main.py \
--roi 129.2 42.2 129.3 42.3 \
--start 2025-12-20 \
--end 2026-01-10 \
--work_dir work \
--download_dir data/slc \
--orbit_dir data/orbits \
--dem_dir data/dem \
--project insar_projectNotes:
- ROI must be provided as a bounding box (not WKT)
- Dates must follow YYYY-MM-DD
Example run:
python main.py \
--roi 129.2 42.2 129.3 42.3 \
--start 2025-12-20 \
--end 2026-01-10At least two Sentinel-1 SLC scenes must be found in the date range, otherwise the run stops.
A NASA Earthdata account is required.
The pipeline will use:
.netrcif present, or- interactive login on first run.
Generated under the configured --work_dir directory.
Example:
work/
βββ insar_project/
βββ topsApp.xml
βββ merged/
βββ products ...
Exact files depend on ISCE2 processing results returned by ISCEProcessor.get_results().
Key products:
| File | Meaning |
|---|---|
filt_topophase.unw.geo |
Geocoded unwrapped phase (displacement signal) |
topophase.cor.geo |
Coherence map |
phsig.cor.geo |
Phase sigma (uncertainty proxy) |
The examples/ directory contains interactive notebooks demonstrating each module and the full pipeline.
| Notebook | Purpose |
|---|---|
S1SLCManager.ipynb |
ASF search & Sentinel-1 download tests |
OrbitManager.ipynb |
Orbit retrieval tests |
DEMManager.ipynb |
DEM buffering and stitching demo |
ISCE_processor(INSAR_main).ipynb |
Interactive version of main.py |
conda activate insar_envcd examples
jupyter labISCE_processor(INSAR_main).ipynb
- Define ROI bounding box (min_lon, min_lat, max_lon, max_lat)
- Set date range
- DEM buffer is handled inside the pipeline
- SLC search and download
- Orbit files auto-retrieved
Large Buffer Strategy
- DEM covers full SLC intersection
- Adds internal buffer (default 0.2Β° in code)
- Prevents edge artifacts
- Generate
topsApp.xml - Run
topsApp.py
Typical runtime: tens of minutes to several hours depending on ROI size and scene count.
File: topophase.cor.geo
| Coherence | Interpretation |
|---|---|
| > 0.5 | Reliable phase (urban, bare soil) |
| < 0.3 | Noisy (vegetation, water) |
Unwrapped phase β displacement:
displacement = phase * (Ξ» / 4Ο)
To convert in meters.
Increase DEM buffer by editing the value in main.py:
dem.prepare_dem(..., buffer_deg=0.3)Check:
- Earthdata credentials
.netrcpermissions- ASF / Earthdata login status
Approximate disk usage:
| Component | Size |
|---|---|
| Sentinel-1 SLC | 4β8 GB per scene |
| ISCE intermediates | 50β100 GB |
| DEM tiles | 1β3 GB |
Ensure sufficient free space before processing.
See LICENSE file for terms.