Skip to content

Repository files navigation

Paper Citation Code Reference

Spectral Use Case Validation - Flood 🌊 and Fire 🔥

This is the accompanying repository for the publication on spectral validation of Sentinel-2 super-resolution for flood-water detection and burn-scar mapping. It contains the reproducible workflows, generated metrics, and figure utilities used for the flood (MNDWI) and burn-scar (dNBR) use cases.

Project webpage and online maps

The companion webpage hosts the interactive online maps. The local workflow scripts in this repository reproduce the LR vs. SR spectral-index and binary-classification metrics reported in the paper.

Flood map example

Run the LR vs SR validations locally

Follow these steps once to enable both workflows.

  1. Install dependencies: create a virtual environment and install requirements.
    python -m venv sr-env
    source sr-env/bin/activate
    pip install -r requirements.txt
  2. Fetch data: download the prepared Sentinel-2 stacks (native, interpolated, and SR products) with the helper script. It populates data_fire/ and data_flood/ under each workflow directory.
    ./fetch_data.sh
    Update ZIP_URL in the script to point at your storage location if you host the archive elsewhere.

Running the workflows

The workflows are organized by hazard; each step is a numbered script. Run them from their directory after data download.

Flood (Valencia 2024)

cd flood_workflow
python 01_after_create_SR_flood.py       # visualize SR vs baseline inputs
python 02_create_flood_mask.py           # compute spectral mask
python 03_calc_mndwi.py                  # derive MNDWI index
python 04_create_thresh_mask.py          # apply thresholds
python 05_histograms_and_mndwi_thresh.py # explore histogram-based cuts
python 06_compute_metrics.py             # evaluate detection metrics
python 07_compute_spectral_metrics.py    # compute paper spectral-fidelity metrics
python 08_compute_edge_metrics.py        # compute paper edge-region metrics

Fire (Palisades 2025)

cd fire_workflow
python 01a_before_create_SR_fire.py      # visualize native inputs
python 01b_after_create_SR_fire.py       # visualize SR outputs
python 02_create_fire_mask.py            # compute spectral mask
python 03_calc_dnbr.py                   # derive dNBR index
python 04_create_thresh_mask.py          # apply thresholds
python 05_histograms_and_dnbr_thresh.py  # explore histogram-based cuts
python 06_compute_metrics.py             # evaluate detection metrics
python 07_compute_spectral_metrics.py    # compute paper spectral-fidelity metrics
python 08_compute_edge_metrics.py        # compute paper edge-region metrics

Notes

  • Both workflows assume GPU access for LDSR-S2 super-resolution (torch.cuda.is_available() must be true).
  • Replace paths or thresholds in the scripts as needed to test additional events or alternative SR baselines.

Citation

Please use the following citation:

@article{geomatics6050097,
  AUTHOR = {Donike, Simon and Portalés-Julià, Enrique and Aybar, Cesar and Gómez-Chova, Luis},
  TITLE = {Evaluating Sentinel-2 Super-Resolution for Geospatial Information Extraction: A Spectral and Thematic Assessment},
  JOURNAL = {Geomatics},
  VOLUME = {6},
  YEAR = {2026},
  NUMBER = {5},
  ARTICLE-NUMBER = {97},
  URL = {https://www.mdpi.com/2673-7418/6/5/97},
  ISSN = {2673-7418},
  DOI = {10.3390/geomatics6050097}
}


About

Spectral Use Case Valdiation for Super-Resolution

Resources

Stars

3 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages