RiWiX: Toward Automatic River Water Width Extraction From High-Resolution Satellite Imagery Using Swin Transformers
Open Access
- 10 February 2026
- journal article
- Published by Institute of Electrical and Electronics Engineers (IEEE) in IEEE Access
- Vol. 14, 24139-24157
Abstract
Accurate extraction of water surface and width of river systems is essential for hydrological modeling, flood monitoring, and water resource management. Traditional field-based measurements are often labor-intensive, time-consuming, and error-prone. With advances in satellite imaging and geospatial data processing, automated methods are increasingly replacing manual approaches. Yet, remote sensing-based river width extraction remains challenging due to dynamic water levels, vegetation interference, variable discharge, spectral reflections, and heterogeneous surface appearance. Existing convolutional neural network (CNN)–based encoder-decoder models have performed well for large rivers but struggle with narrow ones due to limited high-level semantic representation. Recent transformer-based models capture long-range dependencies through self-attention but are computationally heavy and underexplored in remote sensing. This paper presents RiWiX (River Water Width Extraction), a lightweight six-level segmentation model with an integrated width extraction module. Built upon the Swin Transformer architecture, RiWiX employs an efficient encoder-only design with a simple up-sampling module to restore the output mask, thereby improving computational efficiency. A graph-based algorithm further derives continuous water widths by generating a centerline and computing perpendicular distances along the flow direction, effectively generalizing complex river geometries. Experiments on a public water dataset demonstrate that RiWiX achieves competitive accuracy with reduced complexity compared to baseline methods. Tests on geo-referenced imagery yield a mean absolute error of 0.02%for wide rivers (width>500m), 0.06% for moderate rivers (50m < width < 70m), and 0.11% for narrow rivers (width < 20m), underscoring the robustness and scalability of the proposed framework for river-water-width extraction. The implementation process and code has been made publicly available for researchers to use and extend this work. The full repository is accessible at: https://github.com/FahimaHasanAthina/RiWIX.Keywords
This publication has 40 references indexed in Scilit:
- Mechanically and accurately calculate river width in vegetation areas by coupling Sentinel-1 and -2 imageries within land-water-mixed pixelsJournal of Hydrology, 2024
- Semantic segmentation using Vision Transformers: A surveyEngineering Applications of Artificial Intelligence, 2023
- Automatic extraction of surface water based on lightweight convolutional neural networkEcotoxicology and Environmental Safety, 2023
- Swin-Unet: Unet-Like Pure Transformer for Medical Image Segmentation2023
- Pixel Level Feature Extraction and Machine Learning Classification for Water Body ExtractionArabian Journal for Science and Engineering, 2022
- DeepRivWidth : Deep learning based semantic segmentation approach for river identification and width measurement in SAR images of Coastal KarnatakaComputers & Geosciences, 2021
- RivaMap: An automated river analysis and mapping engineRemote Sensing of Environment, 2017
- Patterns of river width and surface area revealed by the satellite‐derived North American River Width data setGeophysical Research Letters, 2015
- Using width-based rating curves from spatially discontinuous satellite imagery to monitor river dischargeHydrological Processes, 2014
- Depth-First and Breadth-First Search1992