BiEHFFNet: A Water Body Detection Network for SAR Images Based on Bi-Encoder and Hybrid Feature Fusion

Bin Han, Xin Huang, Feng XueMathematics 2025 · DOI

TL;DR

This paper introduces BiEHFFNet, a novel deep learning architecture for detecting water bodies in Synthetic Aperture Radar (SAR) images, which are notoriously challenging due to complex backgrounds and noise. BiEHFFNet leverages a dual-encoder approach combining ResNet and Swin Transformer for rich feature extraction, a cross-attention fusion module for integrating these features, and a specialized decoder for accurate boundary reconstruction, outperforming existing methods.

What Problem Does This Paper Address?

Detecting water bodies in SAR imagery is crucial for applications like disaster management and environmental monitoring. However, SAR images present significant challenges:

  • Complex Backgrounds: Variations in grayscale values and diverse surface targets (like wetlands, marshes, and shadowed areas) can mimic water signatures, leading to misclassifications.
  • Topographic Variations & Noise: These can cause blurry boundaries, fragmented predictions, and disconnected river structures.
  • Limited Contextual Understanding: Traditional methods often struggle to effectively combine local details with global context, hindering accurate segmentation.

The paper aims to address these issues by developing a robust deep learning model capable of accurately identifying water bodies even in challenging, noisy, and complex SAR scenes.

Methods

BiEHFFNet is built upon an encoder-decoder architecture with several key innovations:

  • Bi-Encoder Structure:
    • ResNet Branch: Extracts local texture and edge details using residual learning. Convolutional Block Attention Module (CBAM) is applied to suppress irrelevant information.
  • Swin Transformer Branch: Captures long-range dependencies and global contextual information using self-attention mechanisms.
  • Cross-Attention-Based Hybrid Feature Fusion (CABHFF): This module interactively fuses features from the ResNet and Swin Transformer branches. It uses bidirectional cross-attention to allow features from one branch to guide the other, followed by channel attention to learn feature weights for a more effective integration of local and global information.
  • Multi-Scale Content-Aware Upsampling (MSCAU): This decoder module integrates Atrous Spatial Pyramid Pooling (ASPP) for multi-scale context extraction and Content-Aware ReAssembly of FEatures (CARAFE) for adaptive kernel generation. This combination aims to enhance multi-scale feature representation and restore fine spatial details while mitigating upsampling-induced distortion.
  • Composite Loss Function: A combination of Dice Loss (for foreground recognition and handling class imbalance) and Active Contour (AC) Loss (for enforcing boundary smoothness and structural consistency) is used to provide stronger supervision for both region detection and boundary delineation.

Datasets

The paper uses two publicly available SAR datasets:

  • ALOS PALSAR Dataset: Contains 1000 SAR image samples, used for training, validation, and testing (6:2:2 split).
  • Sen1-SAR Dataset: Derived from the Sentinel-1 satellite and the Sen1Floods11 dataset. 1000 SAR image samples (originally 512x512) were selected, preprocessed, and uniformly resized to 256x256 for training and evaluation (6:2:2 split).

Key Insights and Ideas

  • Synergy of CNNs and Transformers: Combining the local feature extraction power of CNNs (ResNet) with the global context modeling of Transformers (Swin Transformer) in a bi-encoder setup is highly effective for complex SAR imagery.
  • Cross-Attention for Fusion: Using cross-attention in the feature fusion stage allows for a more dynamic and interactive integration of features from different modalities (local vs. global), leading to richer representations.
  • Content-Aware Upsampling: Employing CARAFE alongside ASPP in the decoder is crucial for accurately reconstructing fine water body boundaries without introducing significant distortion, a common problem in SAR image segmentation.
  • Dual-Purpose Loss Function: The combination of Dice Loss and Active Contour Loss effectively addresses both the challenge of class imbalance (small water bodies) and the need for precise boundary definition.

Key Results

  • Superior Performance: BiEHFFNet consistently outperformed six other state-of-the-art deep learning models (UNet, ResUNet, UNet++, DeepLabV3+, SwinUNet, TransUNet) across both ALOS PALSAR and Sen1-SAR datasets.
  • Quantitative Gains: On the ALOS PALSAR dataset, BiEHFFNet achieved the highest IoU (96.36%), mIoU (84.37%), OA (96.30%), Re (97.38%), and F1 Score (97.30%). Similar advantages were observed on the Sen1-SAR dataset.
  • Qualitative Improvements: Visualizations showed that BiEHFFNet effectively suppressed background interference, avoided false detections in shadowed regions, and accurately delineated complex water body structures, including slender and fragmented streams.

Limitations and Future Work

  • Computational Complexity: The paper acknowledges that BiEHFFNet's complex architecture (bi-encoder, multiple attention modules, fusion) leads to high computational complexity, limiting its deployment on resource-constrained devices.
  • Future Work: The authors suggest investigating model compression and acceleration methodologies, such as model pruning, quantization, and knowledge distillation, to make the model more efficient. They also aim to explore integrating multi-source data fusion and adaptive noise modeling techniques for improved performance on high-resolution SAR images and better handling of diverse environments.

Summary updated

Abstract

Water body detection in synthetic aperture radar (SAR) imagery plays a critical role in applications such as disaster response, water resource management, and environmental monitoring. However, it remains challenging due to complex background interference in SAR images. To address this issue, a bi-encoder and hybrid feature fuse network (BiEHFFNet) is proposed for achieving accurate water body detection. First, a bi-encoder structure based on ResNet and Swin Transformer is used to jointly extract local spatial details and global contextual information, enhancing feature representation in complex scenarios. Additionally, the convolutional block attention module (CBAM) is employed to suppress irrelevant information of the output features of each ResNet stage. Second, a cross-attention-based hybrid feature fusion (CABHFF) module is designed to interactively integrate local and global features through cross-attention, followed by channel attention to achieve effective hybrid feature fusion, thus improving the model’s ability to capture water structures. Third, a multi-scale content-aware upsampling (MSCAU) module is designed by integrating atrous spatial pyramid pooling (ASPP) with the Content-Aware ReAssembly of FEatures (CARAFE), aiming to enhance multi-scale contextual learning while alleviating feature distortion caused by upsampling. Finally, a composite loss function combining Dice loss and Active Contour loss is used to provide stronger boundary supervision. Experiments conducted on the ALOS PALSAR dataset demonstrate that the proposed BiEHFFNet outperforms existing methods across multiple evaluation metrics, achieving more accurate water body detection.
BibTeX
@inproceedings{han2025biehffnet,
  author = {Bin Han and Xin Huang and Feng Xue},
  title = {{BiEHFFNet: A Water Body Detection Network for SAR Images Based on Bi-Encoder and Hybrid Feature Fusion}},
  booktitle = {Mathematics},
  year = {2025},
  doi = {10.3390/math13152347},
}
Figure