Attention U-Net — Glacier Extent Segmentation (Swiss Alps)

Trained model weights for binary glacier/non-glacier segmentation from Sentinel-2 multispectral imagery over the Jungfrau–Aletsch region, Switzerland.

Developed as part of a study transferring the deforestation detection architecture of John & Zhang (2022) to cryosphere monitoring.

Full code, notebooks, and documentation: https://github.com/camilletyriard-dev/glacier-segmentation-attention-unet


Model Files

File Description Input bands
glacier_segmentation_6band.keras Glacier segmentation — main model 6 (RGB + NIR + SWIR1 + SWIR2)
deforestation_amazon_4band.keras Replication — Amazon deforestation 4 (RGB + NIR)
deforestation_atlantic_4band.keras Replication — Atlantic Forest 4 (RGB + NIR)
deforestation_amazon_rgb_3band.keras Replication — Amazon RGB only 3 (RGB)

Performance

Glacier Segmentation (Swiss Alps — main contribution)

Metric Score
IoU 0.9839
Precision 0.9919
Recall 0.9915
F1 0.9917

Test set: 101 images, Jungfrau–Aletsch region, summer 2020–2025.


Usage

from keras.models import load_model
import numpy as np

# Load model
model = load_model("glacier_segmentation_6band.keras")

# Input shape: (batch, 512, 512, 6) — normalised to [0, 1]
# Output shape: (batch, 512, 512, 1) — binary mask
prediction = model.predict(image[np.newaxis, ...])

Architecture

Attention-gated U-Net (Oktay et al., 2018) adapted from John & Zhang (2022).

Key modifications for glacier segmentation:

  • 6-channel input (RGB + NIR + SWIR1 + SWIR2)
  • Bottleneck dropout (p = 0.5)
  • Dice loss (class imbalance: ice ≈ 12% of pixels)
  • Full fine-tuning of all 2.01M parameters

Citation

@misc{tyriard2025glacier,
  author = {Tyriard, Camille},
  title  = {Attention U-Net for Glacier Extent Segmentation in the Swiss Alps},
  year   = {2025},
  url    = {https://github.com/camilletyriard-dev/glacier-segmentation-attention-unet}
}

Based on:

@article{john2022attention,
  title   = {An attention-based U-Net for detecting deforestation within satellite sensor imagery},
  author  = {John, David A. and Zhang, Chuanxin},
  journal = {International Journal of Applied Earth Observation and Geoinformation},
  volume  = {107},
  year    = {2022},
  doi     = {10.1016/j.jag.2022.102685}
}
Downloads last month
138
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support