# DMLU-Net: A Hybrid Neural Network for Water Body Extraction from Remote Sensing Images
## 2 Proposed Method
### Architecture of DMLU-Net  
As shown in Figure 1, the proposed DMLU-Net model adopts an encoder-bottleneck layer-decoder architecture, achieving accurate water body segmentation through the directional enhancement of feature maps. The encoder of the model consists of four levels of downsampling modules, each containing two 3 \(\times\) 3 convolution kernels and max pooling operations. While compressing the spatial dimension (512 \(\times\) 512 \(\rightarrow\) 32 \(\times\) 32), a spectral-spatial attention module (SSAM) is introduced in the skip connection path. This module strengthens the response of water-sensitive bands through the spectral branch (channel compression ratio of 16) and highlights boundary features with multi-scale spatial branches (3 \(\times\) 3 convolutions with dilation rates of 1, 2, and 3), effectively alleviating the problems of band redundancy and edge blurring in multispectral data. In the decoding process, a DySample module is utilized to restore both image resolution and detailed information. Ultimately, the encoder and decoder feature maps are integrated via skip connections to produce the final water body extraction outcome.  
The innovative design of DMLU-Net is mainly reflected in the three-level-deployed DMLKA modules, which balance the model's ability to mine global and local features through flexible multi-scale convolution layers and dynamic weight design. It realizes progressive feature optimization, from the global context to local details, through the differentiated feature weight design controlled by the temperature parameter T. The specific roles of DMLKA in the model are as follows:  
1. The DMLKA module is deployed in the encoder's terminal stage to pre-fuse 528-dimensional features (T = 0.3), uniformly considering water body features at multiple scales, maintaining the richness of feature information, and capturing the macroscopic water body morphology.  
Figure 1: Architecture of the DMLU-Net model.  
2. The pre-fused features are dimensionally upgraded using a convolution layer, and then the DMLKA module is used to perform shallow feature fusion (T = 0.2) of the 1056-dimensional high-dimensional features to extract key information.
3. After organizing the extracted feature information, the DMLKA module is used in the first layer of the decoder for deep feature enhancement (T = 0.1), emphasizing the focus on minor-scale features and enhancing the model's ability to extract the boundary detail features of various objects in remote sensing imagery.  
In the design of skip connections, to retain spatial details and enhance the representation ability of feature maps, a spectral-spatial attention module is designed. The SSAM combines spatial and channel attention mechanisms, suppressing irrelevant information and highlighting important features through attention expression. This module ensures that the network can focus on water body regions, ignoring noise and background interference, thereby improving the accuracy of segmentation results.  
The DySample module in the decoder realizes sub-pixel-level feature alignment by learning offset parameters. Combined with the skip connection features optimized by the SSAM, it significantly reduces upsampling artifacts during resolution restoration. By upsampling the feature map, the model gradually restores the data scale to the original image resolution (512 \(\times\) 512) and finally obtains the extraction result of the water body structure.