
==== Front
Heliyon
Heliyon
Heliyon
2405-8440
Elsevier

S2405-8440(24)13501-3
10.1016/j.heliyon.2024.e37470
e37470
Research Article
Remote sensing image road network detection based on channel attention mechanism
Shan Chuanhui chuanhshan@163.com
⁎
Geng Xinlong gengxinlong@stu.ahpu.edu.cn

Han Chao hanchao@ahpu.edu.cn

College of Electrical Engineering, Anhui Polytechnic University, Middle Beijing Road, Wuhu, 241004, Anhui Province, China
⁎ Corresponding author. chuanhshan@163.com
06 9 2024
30 9 2024
06 9 2024
10 18 e3747028 8 2023
4 9 2024
4 9 2024
© 2024 The Author(s)
2024
https://creativecommons.org/licenses/by-nc/4.0/ This is an open access article under the CC BY-NC license (http://creativecommons.org/licenses/by-nc/4.0/).
Extracting and detecting road network consistency from high-resolution remote sensing images has been a hot and difficult problem in the computer vision. Although it has made significant progress, there is still a phenomenon of high training accuracy but unsatisfactory actual extraction and detection results. The attention mechanism is one of the efficient and practical mechanisms in deep learning. It improves the performance of deep learning by selectively focusing on a portion of all information while ignoring other visible information, while effectively utilizing computing resources. Numerous experiments have also confirmed that the attention mechanism is resource-saving and effective. Its plug and play feature brings great convenience to programmers. In order to provide better road network detection results and solve the above problem, this paper combines the channel attention mechanism with ResNet and proposes SE-ResNet and ECA-ResNet for remote sensing image road network detection, making networks extract and learn road network features and ignore some non-road network features. The experimental results show that on the Massachusetts roads (MR) and CHN6-CUG roads datasets, ECA-ResNet and SE-ResNet based on channel attention mechanism perform similar to LeNet7 and ResNet in terms of accuracy, loss, accuracy convergence, and loss convergence, and even increase a certain computational burden. However, their final road network detection results (including road network detection pixel count, precision, recall, accuracy, IOU, F1 score, and actual road network detection result) of the former are significantly better than those of the latter. The channel attention mechanism makes the deep neural network pay more attention to the extraction and learning of road network features, while ignoring the extraction and learning of some non-road network features, which improves the accuracy of containing road network samples and reduces the accuracy of not containing road network samples. Therefore, the performance of ECA-ResNet and SE-ResNet is similar to that of LeNet7 and ResNet in the accuracy, loss, accuracy convergence and loss convergence, but the final road network detection results of ECA-ResNet and SE-ResNet are significantly better than those of LeNet7 and ResNet. Therefore, the proposed ECA-ResNet and SE-ResNet have broad application prospects in road network detection, especially ECA-ResNet.

MSC

00-01
99-00
Keywords

Road network detection
Attention mechanism
SE-ResNet
ECA-ResNet
Road network detection performance
==== Body
pmc1 Introduction

Road networks are a type of road system made up of different roads that connect to one another and are distributed within a certain area. Among them, the road network composed of all levels of highways is called the highway network. The road network of various roads within the city limits is called the urban road network. Road network extraction or detection is the process of identifying a road network from high-resolution remote sensing images by entering them into a computer and having it identify them in accordance with certain rules [1]. For the extraction or detection of road networks, high-resolution remote sensing images include a wealth of information. The fundamental theory is to analyze the spatial geometric and spectral features of different targets in the image. The traditional road network detection methods extract roads through the texture, color, edge, and geometric features of images, which are limited in application scenarios and have low efficiency. Road network detection based on deep learning can utilize massive high-resolution images and extract independently and quickly traffic information such as submeter precision road networks and centerlines in complex backgrounds, which has become an important means of high-precision map production [2]. The road network extraction methods based on deep learning rely on the edge detection and the semantic segmentation to extract road network, and transform the road network extraction task into a binary classification image semantic segmentation task [3]. Mnih et al. [4] used the constrained Boltzmann machine to detect road networks from high-resolution remote sensing images. For detecting road network, Zhang et al. [5] incorporated residual learning [6] into U-Net to construct a semantic segmentation convolutional neural network. Xu et al. [7] introduced DenseNet [8] into U-Net for road network detection, which achieved higher recall rates. Shan et al. [9] proposed an E-Road with encoding-decoding structure for road network detection. Ren et al. [10] incorporated the U-Net results into the capsule network and put forward a dual attention capsule network (DA-CapsU-Net), which extracts and integrates multi-scale capsule features, has good universality and compatibility, but there are errors in detection. To present a high-resolution road segmentation map, Abdollahi et al. [11] developed the VNet model, a novel deep learning-based neural network. They also defined the cross-entropy-dice-loss (CEDL), a new dual loss function. The suggested VNet+CEDL approach outperforms other deep learning techniques in road extraction. The first publicly available dataset LRSNY for road extraction from optical remote sensing images with manually labeled labels was published by Chen et al. [12], then they developed a reconstruction bias U-Net for road extraction from remote sensing images. Comparing the reconstruction bias U-Net to the other six cutting-edge segmentation models on the LRSNY dataset, it performs better. With a complement UNet (C-UNet), Hou et al. [13] presented a road extraction method for remote sensing images. The Massachusetts Road dataset's results show that C-UNet performs better than state-of-the-art approaches, proving its efficacy. A novel network for road extraction termed SDUNet was presented by Yang et al. [14] based on spatially enhanced and densely connected UNet. In comparison to earlier methods for road extraction, SDUNet delivers state-of-the-art performance on two benchmark datasets. When roads of different sizes coexist in an HRSI, Wang et al. [15] introduced an improved deep neural network model called dual-decoder-U-Net (DDU-Net) to increase the accuracy and reliability of small-sized road extraction. Although these researchers have made significant progress, there is still a phenomenon of high training accuracy but unsatisfactory actual extraction and detection results.

The attention mechanism was originally developed in 2014 as a part of the encoder-decoder framework in recurrent neural network (RNN) to encode long input statements, and has subsequently been widely used in RNN [16]. Hu et al. applied the attention mechanism to the feature map and attempted to obtain the available attention information in the feature map for achieving better task effects. They proposed the squeeze and extraction network (SE-Net) [17] and won the champion of the classification task in ImageNet 2017 competition. Since then, attention mechanism models have been widely concerned, and various attention mechanism models have been proposed successively, such as structure-aware network (SANet) [18] and visual-spatial-graph network (VSV-NET) [19], etc. It is frequently utilized in a variety of deep learning applications, including speech recognition, image recognition, and natural language processing. Woo et al. [20] believed that for feature maps, not only do the feature map channels contain rich attention information, but also there is a great deal of attention information between pixel points of feature maps. Thus, they presented the convolutional block attention module (CBAM) and verified its widespread applicability on VOC 2007, MS Coco, and ImageNet-1k detection datasets. Based on the attention mechanism of convolutional kernel, namely the importance of convolutional kernel, Li et al. [21] proposed the selective kernel network (SK-Net), and achieved better results than existing state-of-the-art architectures on ImageNet and CIFAR datasets. By combining spatial and channel attention mechanisms, Fu et al. [22] suggested the dual attention Network (DA-Net). In fact, CBAM is also proposed by integrating channel and spatial attention mechanisms. The difference is that the acquisition of CBAM's channel and spatial attention mechanism is serial, while the acquisition of DA-Net's channel and spatial attention mechanism is parallel, and the methods of obtaining attention mechanisms also vary greatly. DA-Net achieves the most advanced segmentation performance on Cityscapes, PASCAL Context, and COCO Stuff scene segmentation datasets. Zhao et al. [23] presented a pyramid feature attention network (PFA-Net) to address the low effectiveness of multi-scale convolutional feature extraction for saliency detection. PFA-NET achieved good saliency detection results by focusing on effective low-level spatial structural features and high-level contextual features. Wang et al. [24] proposed the efficient channel attention network (ECA-Net), which offers a local cross-channel interaction strategy that reduces non-dimensionality and an adaptive way to choose the size of one-dimensional convolutional kernels. By summarizing cross-channel information through one-dimensional convolutional layers, more accurate attention information can be obtained. Transformer [25] is an end-to-end natural language processing (NLP) model proposed by the Google team in 2017. This model abandons the traditional RNN sequential structure and adopts a self-attention mechanism to enable parallel training and grasp global information. Usually, Transformer is trained in large text corpora and then is fine-tuned in smaller specific tasks to achieve better computational efficiency and accuracy. In order to apply the Transformer to images, Dosovitskiy et al. [26] proposed the Vision Transformer (ViT). ViT can be seen as a graphical version of the Transformer, which directly migrates the standard Transformer model to the image domain with minimal modifications to become ViT. ViT divides the image into many sub blocks and forms a linear embedding sequence, and then these linear embedding sequences are used as inputs to the Transformer to simulate the input of phrase sequences in the NLP domain. Zhang et al. [27] proposed a modular split-attention block, which enables the use of attention mechanisms feature groups of feature maps in a network. An entirely new ResNet version known as ResNeSt is created by stacking split-attention blocks in the ResNet fashion, which can be directly plug and play in downstream applications without introducing additional computational costs. A cascaded attention-enhanced architecture was suggested by Li et al. [28] to extract boundary-refined roads from remote sensing images. Experiments demonstrate that the suggested method outperforms current methods and produces state-of-the-art results on the Massachusetts dataset. To deal with road segmentation tasks in high spatial resolution satellite images, Khan et al. [29] introduced an encoder-decoder network called DSMSA-Net combined with attention units. In comparison to reference approaches, DSMSA-Net performs better on the Massachusetts and DeepGlobe road datasets.

Numerous deep learning tasks have made extensive use of the attention mechanism. The attention mechanism improves the performance of deep learning by selectively focusing on a portion of all information while ignoring other visible information, while effectively utilizing computing resources. Numerous experiments have also confirmed that attention mechanism is resource-saving and effective. As a lightweight module, attention mechanism has the characteristics of plug and play. Although road extraction has made significant progress, there is still a phenomenon of high training accuracy but unsatisfactory actual extraction and detection results. Therefore, based on the superior performance of attention mechanism, the paper combines channel attention mechanism with ResNet to deal with the road network detection of remote sensing image, SE-ResNet and ECA-ResNet are proposed for road network detection of remote sensing image, thereby improving the road network detection performance.

The paper is organized as follows. Section 2 introduces the channel attention mechanism and its residual network. Section 3 introduces experimental results and analysis, including experimental environment, datasets, evaluating indicator, and result analysis. Section 4 summarizes the full text.

2 Channel attention mechanism neural network

2.1 Channel attention mechanism

The key structure in SE-Net is the squeeze and extraction (SE) module, as shown in Fig. 1. The SE module makes explicit use of the attention mechanism to create the interdependence between feature maps. It then adaptively determines the relevance of each feature map through learning and modifies the original data in accordance with this importance level. The SE module mainly consists of three operations, namely Fsq, Fex, and Fscale. Fsq employs the global average pooling (GAP) operation to transform each channel's two-dimensional feature (H×W) into a real number, resulting in a weight of size 1×1×C. Suppose that the size of the input feature map X is H×W×C, namely X=(x1,x2,⋯,xC), the size of the output weight z is 1×1×C, namely z=(z1,z2,⋯,zC). Taking the C-th feature map xC of the input feature map X as an example, the Fsq operation result is(1) zC=Fsq(xC)=1H×W∑i=1H∑j=1WxC(i,j)

xC(i,j) represents the element in the position of row i and column j of the C-th feature map xC of the input feature map X in Formula (1). Since the weight is get through GAP operation, the SE module has global receptive field to some extent. Fex models the correlation between channels using a two-layer multi-layer perceptron network (i.e. FC-ReLU-FC-Sigmoid), where the output weight has the same amount of weights as the input weight. The input of Fex is the output z=(z1,z2,⋯,zC) of Fsq. Fex first compresses the weight z of size 1×1×C into a weight of 1×1×C/r, and then expands the weight of 1×1×C/r into a weight of 1×1×C, that is(2) s=Fex(z,W)=σ(g(z,W))=σ(W2δ(W1z))

σ refers to the sigmoid activate function, and δ refers to the activation function, generally taken as rectified linear unit (ReLU) in Formula (2). W1∈RCr×C and W2∈RC×Cr are the weights in Formula (2). s represent the output weight with a size of 1×1×C, namely s=(s1,s2,⋯,sC). Fscale weights the normalized weights obtained above onto the feature maps of each channel in Formula (2), i.e. multiplies the weight coefficients channel-by-channel to introduce attention mechanisms in the channel dimension. Suppose that the output feature map of Fscale is X¯, after the Fscale operation, the size of the output feature map X¯ changes to H×W×C again, namely X¯=(x¯1,x¯2,⋯,x¯C). Taking the C-th feature map x¯C of the output feature map X¯ as an example, the Fscale operation result is(3) x¯C=Fscale(xC,sC)=sCxC

xC refers to the C-th feature map of input feature map X of Fsq operation, and sC represents the C-th value of the weight s in Formula (3). The specific process of SE module is shown in Fig. 2. From a mathematical point of view, SE module is obtained by weighted feature map channels, so SE module is also called channel attention mechanism. SE module is a plug and play lightweight module. By incorporating this module into the network, the neural network's processing resources can be distributed more equitably at the cost of slightly increasing the number of parameters and the performance of the network can be greatly improved. For example, by embedding the SE module into the residual module, an SE-residual module can be constructed, as shown in Fig. 3. Fig. 3 (a) represents the traditional residual module, and Fig. 3 (b) represents the SE-residual module formed by embedding the SE module into the residual module. The residual module is an important skill of ResNet [30] and a crucial technique for enhancing network performance and preventing deep neural network overfitting. The common residual modules are divided into two types, as shown in Fig. 4 (a) and Fig. 4 (b), where Fig. 4 (a) shows the residual module connected across two layers and Fig. 4 (b) indicates the residual module connected across three layers. To improve the performance of road network detection, this paper adopts the residual module shown in Fig. 4 (a).Figure 1 The squeeze-and-excitation module.

Figure 1

Figure 2 The SE module.

Figure 2

Figure 3 Fig. 3 (a) The residual module, (b) The SE-residual module.

Figure 3

Figure 4 The residual module:(a)The residual module connected across two layers, (b)The residual module connected across three layers.

Figure 4

The ECA-Net offers an adaptive technique for choosing the size of one-dimensional convolutional kernels as well as a local cross-channel interaction strategy (i.e., the efficient channel attention (ECA) module) that reduces non-dimensionality. By summarizing cross-channel information through one-dimensional convolutional layers, more accurate attention information is obtained. The ECA module is an improvement based on the SE module, as shown in Fig. 5. In fact, the ECA module is an improvement on the feature transformation part of the SE module. The channel information interaction mode of SE module is realized through fully connected layer, which will damage some feature expression in the process of decreasing and increasing dimension. The ECA module further uses one-dimensional convolution to realize information interaction between channels. Compared to the computational cost of global channel information interaction achieved through fully connection, the ECA module proposes a method based on adaptive selection of convolution kernel size to achieve local interaction, significantly reducing model complexity and maintaining performance. Fig. 5 shows the structure diagram of ECA module, in which the adaptive selection of kernel size k refers to the coverage of local cross-channel interaction, that is, how many fields participate in the attention prediction of a channel. To avoid manually adjusting k through cross-verification, an adaptive method is developed to determine k, where the coverage range of cross-channel interactions (i.e. kernel size k) is proportional to the channel dimension, namely(4) k=Ψ(C)

Ψ represents an adaptive function for determining k in terms of C in Formula (4), which satisfies that k is proportional to C. Like the SE module, the ECA module is also a channel attention mechanism. Similarly, the ECA module is also a plug and play lightweight module. For example, embedding the ECA module into the residual module can construct the ECA-residual module, as shown in Fig. 6. Fig. 6 (a) displays the traditional residual module, and Fig. 6 (b) displays the ECA-residual module formed by embedding the ECA module into the residual module.Figure 5 The ECA module.

Figure 5

Figure 6 (a) The residual module, (b) The ECA-residual module.

Figure 6

2.2 Channel attention mechanism residual network

SE-ResNet can be constructed by embedding the SE-residual module in Fig. 3 (b) into the common convolutional neural network, and the structure diagram of SE-ResNet is displayed in Fig. 7 (c). ECA-ResNet can be constructed by embedding the ECA-residual module in Fig. 6 (b) into the common convolutional neural network (LeNet7). The structure diagram of ECA-ResNet is displayed in Fig. 7 (d). The residual network (ResNet) and LeNet7 corresponding to SE-ResNet or ECA-ResNet are displayed in Fig. 7 (b) and Fig. 7 (a), respectively. Se-ResNet is obtained by embedding SE module on the basis of ResNet, ECA-ResNet is obtained by embedding ECA module on the basis of ResNet, and ResNet is obtained by adding residual learning on the basis of LeNet7. The difference between SE-ResNet, ECA-ResNet, ResNet, and LeNet7 can be seen in the green and red dashed areas shown in Fig. 7. Table 1 provides the specific parameters of the four networks (LeNet7, ResNet, SE-ResNet, and ECA-ResNet) shown in Fig. 7. In Table 1, “Input 25 × 25 × 3” indicates that the size of the input layer is 25 × 25 × 3. “Conv1 (3 × 3/1/1) 25 × 25 × 64” indicates that the size, padding, and stride of the convolutional kernel are 3 × 3, 1, and 1 respectively in the first convolutional layer, and the size of the convolutional layer is 25 × 25 × 64. “Conv2 (3 × 3/1/1) 25 × 25 × 64” indicates that the size, padding, and stride of convolutional kernel are 3 × 3, 1, and 1 respectively in the second convolutional layer, and the size of the convolutional layer is 25 × 25 × 64. “BN1 25 × 25 × 64” indicates that the size of the first batch normalization (BN) layer is 25 × 25 × 64. “ReLU1 25 × 25 × 64” indicates that the size after the ReLU activation function mapping is 25 × 25 × 64. “GAP 25 × 25/25 1 × 1 × 64” indicates that the size and stride of global average pooling are 25 × 25 and 25 respectively. “GMP 25 × 25/25 1 × 1 × 64” indicates that the size and stride of global max pooling are 25 × 25 and 25 respectively, and the size of the pooling layer is 1 × 1 × 64. “SE-Fc1 (16 × 64) 16 ×1” indicates that the size of the weight matrix is 16 × 64 in the first fully connected layer and the size of the fully connected or output layer is 16 × 1 in the SE-residual module. “SE-ReLU 16 × 1” indicates that the size after the ReLU activation function mapping is 16 × 1 in the SE-residual module. “SE-Sigmoid 64 × 1” indicates that the size after sigmoid activation function mapping is 64 × 1 in the SE-residual module. “ECA-Conv (1 × 1/0/1) 1 × 1 × 64” indicates that the size, padding, and stride of the convolutional kernel are 1 × 1, 0, and 1 respectively in the convolutional layer, and the size of the convolutional layer is 1 × 1 × 64 in the ECA-residual module. “ECA-Sigmoid 64 × 1” indicates that the size after the sigmoid activation function mapping is 64 × 1 in the ECA-residual module. “Scale 25 × 25 × 64” indicates the size after the scale operation of Formula (3) is 25 × 25 × 64. “Eltwise 25 × 25 × 64” indicates the size after adding the residual layer is 25 × 25 × 64. “Fc (64 × 64) 64 ×1” indicates that the size of the weight matrix is 64 × 64 in the fully connected layer and the size of the fully connected layer is 64 × 1. “Output (2 × 64) 2 ×1” indicates that the size of the weight matrix is 2 × 64 in the fully connected layer and the size of the fully connected layer is 2 × 1. The other representations are similar and will not be repeated here. Table 1 provides detailed auxiliary information for Fig. 7, which helps to understand the specific structural information of LeNet7, ResNet, SE-ResNet, and ECA-ResNet. The road network detection performance of these networks is respectively tested through comparative experiments.Figure 7 The schematic diagrams of four neural networks for remote sensing image road network extraction: (a) Convolutional neural network or LeNet7, (b) ResNet, (c) SE-ResNet, (d) ECA-ResNet.

Figure 7

Table 1 The detailed parameters of LeNet7, ResNet, SE-ResNet, and ECA-ResNet.

Table 1Networks	LeNet7	ResNet	SE-ResNet	ECA-ResNet	
Layers	Input 25 × 25 × 3	
Conv1 (3 × 3/1/1) 25 × 25 × 64	
BN1 25 × 25 × 64	
ReLU1 25 × 25 × 64	
Conv2 (3 × 3/1/1) 25 × 25 × 64	
BN2 25 × 25 × 64	
ReLU2 25 × 25 × 64	
Conv3 (3 × 3/1/1) 25 × 25 × 64	
BN3 25 × 25 × 64	
/	/	GAP 25 × 25/25 1 × 1 × 64	
/	/	SE-Fc1 (16 × 64)	
16 × 1	

	ECA-Conv (1 × 1/0/1)	
1 × 1 × 64	

	
/	/	SE-ReLU 16 × 1	ECA-Sigmoid 1 × 1 × 64	
/	/	SE-Fc2 (64 × 16)	
64 × 1	

	/	
/	/	SE-Sigmoid 64 × 1	/	
/	/	Scale 25 × 25 × 64	
/	Eltwise 25 × 25 × 64	
GMP (25 × 25/25) 1 × 1 × 64	
Fc (64 × 64) 64 × 1	
	ReLU3 64 × 1	
	Output (2 × 64) 2 × 1	

3 Experimental results and analysis

3.1 Experimental environment

SE-ResNet and ECA-ResNet, as shown in Fig. 7 (c) and Fig. 7 (d) respectively, have a total of 9 layers, including 1 input layer, 3 convolutional layers, 1 SE module/ECA module, 2 fully connected layers,1 maximum pooling layer, and 1 output layer. It can also be seen from Fig. 7 (c) and Fig. 7 (d) that in addition to the above 9 layers, the network also uses batch normalization (BN), ReLU activation functions, and the residual connected across two layers. The ResNet corresponding to SE-ResNet and ECA-ResNet is shown in Fig. 7 (b). The settings of the three networks are the same except for adding an additional SE module/ECA module. Similarly, the LeNet7 shown in Fig. 7 (a) is obtained by removing the residual connected across 2 layers on the basis of the ResNet shown in Fig. 7 (b), and the remaining settings of the network are exactly the same as the ResNet shown in Fig. 7 (b). All experiments were performed on 2 × NVIDIA GeForce RTX 3080, and convergence training for four networks was performed using the Caffe platform.

3.2 Datasets

In the experiment, the datasets used consist of the Massachusetts roads (MR) dataset [31] and the CHN6-CUG roads dataset [32] which are public remote sensing images of traffic networks. The MR dataset contains 1,171 aerial images of Massachusetts. Each image measures 1500 × 1500 pixels and covers a 2.25 square kilometers' area. There are 49 test images, 14 validation images, and 1,108 training images on the MR dataset. Some remote sensing images and road network annotations of the MR dataset are shown in Fig. 8. In this paper, there are 17 images selected as the dataset from MR dataset, including 6 test images and 11 training images. The CHN6-CUG roads dataset is a new dataset of large-scale satellite remote sensing images of representative cities in China, including 4,511 labeled images of size 512 × 512, i.e. 3,608 training images and 903 test images. Some remote sensing images and road network annotations of the CHN6-CUG roads dataset are displayed in Fig. 9. In this paper, 18 images are chosen as the dataset, 6 images are used as the test images and 12 images are used as the training images.Figure 8 Examples of MR dataset and their corresponding road network annotation.

Figure 8

Figure 9 Examples of CHN6-CUG roads dataset and their corresponding road network annotation.

Figure 9

3.3 Evaluating indicator

In order to evaluate the effectiveness of LeNet7, ResNet, SE-ResNet, and ECA-ResNet in remote sensing image road network detection, two evaluation indicators are used. The first method is to evaluate the performance of network training and learning by comparing the training speed, final accuracy and loss, as well as the convergence rate of accuracy and loss. The second method is to evaluate the final detection performance of the network by comparing the actual results of road network detection. The final results of road network detection include the road network detection pixel count, precision, recall, accuracy, IOU, F1 score, and actual road network detection result. Finally, the advantages and disadvantages of four networks for remote sensing image road network detection are presented.

3.4 Result analysis

3.4.1 Result analysis on MR dataset

The comparative experimental results of LeNet7, ResNet, SE-ResNet and ECA-ResNet on the MR Dataset are illustrated in Table 2, which is the training result of 100,000 iterations. Observed from Table 2, the accuracies of LeNet7, ResNet, SE-ResNet and ECA-ResNet are 97.44%, 97.94%, 97.73% and 97.64% respectively on the MR Dataset. The accuracies of SE-ResNet and ECA-ResNet are 0.29% and 0.20% higher than that of LeNet7 respectively, and the accuracy of ResNet is the highest. It can also be seen that the losses of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 0.0759, 0.0679, 0.0579, and 0.0724, respectively. The loss of SE-ResNet and ECA-ResNet is 0.0180 and 0.0034 lower than that of LeNet7 respectively. The loss of SE-ResNet is the least and is reduced by 0.0180, 0.0100, and 0.0145 compared to LeNet7, ResNet, and ECA-ResNet, respectively. It is also observed that the average training speed of LeNet7, ResNet, SE-ResNet, and ECA-ResNet is 0.6145 iterations/s (iters/s), 0.6027 iters/s, 0.5748 iters/s, and 0.5983 iters/s, respectively. The training speed of LeNet7 is the fastest, that of ResNet is faster, that of ECA-ResNet is slow, and that of SE-ResNet is the slowest, but the overall difference in training speeds among the four networks is not significant. It is also observed that the parameter numbers of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 79,680, 79,680, 81,728, and 83,776 respectively. ECA-ResNet has the most parameters, SE-ResNet has more parameters, and LeNet7 and ResNet have the least parameters. The overall difference in parameter number among the four networks is not significant, which also confirms the training speed of the four networks. Fig. 10 and Fig. 11 show the relationship between loss and iterations of LeNet7, ResNet, SE-ResNet, and ECA-ResNet on the MR training and test dataset. Observed from Fig. 10, LeNet7, ResNet, SE-ResNet, and ECA-ResNet have little difference in loss convergence on MR training dataset, and LeNet7 has the most stable loss convergence. As can be seen from Fig. 11, LeNet7, ResNet, SE-ResNet, and ECA-ResNet have basically the same loss convergence on MR test dataset, and SE-ResNet has the most stable loss convergence, especially in the later stage of training. Fig. 12 shows the relationship between accuracies and iterations of LeNet7, ResNet, SE-ResNet, and ECA-ResNet on the MR dataset. It is observed that the accuracy convergence of LeNet7, ResNet, SE-ResNet, and ECA-ResNet is basically consistent.Table 2 Comparative experiment of LeNet7, ResNet, SE-ResNet, and ECA-ResNet on MR and CHN6-CUG roads datasets.

Table 2Network	MR	CHN6-CUG	Parameter number	
Accuracy	Loss	Average training	
speed (iters/s)	

	Accuracy	Loss	Average training	
speed (iters/s)	

	
LeNet7	97.44%	0.0759	0.6145	99.96%	0.0023	1.2643	79,680	
ResNet	97.94%	0.0679	0.6027	99.92%	0.0025	1.2584	79,680	
SE-ResNet	97.73%	0.0579	0.5748	99.94%	0.0025	0.5957	81,728	
ECA-ResNet	97.64%	0.0724	0.5983	99.94%	0.0025	0.5957	83,776	

Figure 10 The relationship between loss and iterations on the MR training dataset.

Figure 10

Figure 11 The relationship between loss and iterations on the MR test dataset.

Figure 11

Figure 12 The relationship between accuracies and iterations on the MR dataset.

Figure 12

Fig. 13 shows the partial road network detection results of LeNet7, ResNet, SE-ResNet, and ECA-ResNet on the MR dataset with a connectivity size of 10. From Fig. 13, It is observed that the road network detection width of ECA-ResNet is closest to the actual road network width, and better than the road network detection width of LeNet7, ResNet, and SE-ResNet. Table 3 presents the road network detection pixel count of LeNet7, ResNet, SE-ResNet, and ECA-ResNet in Fig. 13. Observed from Table 3, the road network detection pixel counts of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 26,992, 31,931, 32,755, and 60,947 respectively on the left column images in Fig. 13, the road network detection pixel counts of LeNet7, ResNet, SE-ResNet and ECA-ResNet are 20,345, 24,904, 21,086, and 54,569 respectively on the middle column images in Fig. 13, and the road network detection pixel counts of LeNet7, ResNet, SE-ResNet and ECA-ResNet are 16,366, 16,923, 17,356, and 40,718 respectively on the right column images in Fig. 13. It can be seen that the road network detection pixel count of ECA-ResNet is the most, the road network detection pixel count of SE-ResNet is more, and the road network detection pixel counts of LeNet7 and ResNet is the least. Table 4 presents the precision, recall, accuracy, IOU, and F1 score of LeNet7, ResNet, SE-ResNet, and ECA-ResNet on MR roads dataset. Observed from Table 4, the precision of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 14.70%, 17.19%, 16.68%, and 13.84% respectively on the left column images in Fig. 13, the recall of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 25.65%, 40.62%, 37.02%, and 57.93% respectively on the left column images in Fig. 13, the accuracy of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 98.01%, 97.72%, 97.79%, and 96.41% respectively on the left column images in Fig. 13, the intersection over union (IOU) of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 10.31%, 13.74%, 12.99%, and 12.58% respectively on the left column images in Fig. 13, and the F1 score of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 18.69%, 24.16%, 23.00%, and 22.35% respectively on the left column images in Fig. 13. The precision of ResNet is the largest, which is 2.49%, 0.15%, and 3.35% more than those of LeNet7, SE-ResNet, and ECA-ResNet, respectively. The recall of ECA-ResNet is the largest, which is 32.28%, 17.31%, and 20.90% more than those of LeNet7, ResNet, and SE-ResNet, respectively. The accuracy of LeNet7 is the largest, which is 0.29%, 0.22%, and 1.60% more than those of ResNet, SE-ResNet, and ECA-ResNet, respectively. The IOU of ResNet is the largest, which is 3.43%, 0.75%, and 1.16% more than those of LeNet7, SE-ResNet, and ECA-ResNet, respectively. The F1 score of ResNet is the largest, which is 5.47%, 1.16%, and 1.81% more than those of LeNet7, SE-ResNet, and ECA-ResNet, respectively. The precision of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 14.44%, 12.61%, 14.71%, and 12.77% respectively on the middle column images in Fig. 13, the recall of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 34.05%, 46.37%, 48.57%, and 66.63% respectively on the middle column images in Fig. 13, the accuracy of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 98.56%, 97.46%, 97.75%, and 96.69% respectively on the middle column images in Fig. 13, the IOU of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 11.28%, 11.00%, 12.73%, and 12.00% respectively on the middle column images in Fig. 13, and the F1 score of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 20.28%, 19.83%, 22.58%, and 21.43% respectively on the middle column images in Fig. 13. The precision of SE-ResNet is the largest, which is 0.27%, 2.10%, and 1.94% more than those of LeNet7, ResNet, and ECA-ResNet, respectively. The recall of ECA-ResNet is the largest, which is 32.58%, 20.26%, and 18.06% more than those of LeNet7, ResNet, and SE-ResNet, respectively. The accuracy of LeNet7 is the largest, which is 1.10%, 0.81%, and 1.87% more than those of ResNet, SE-ResNet, and ECA-ResNet respectively. The IOU of SE-ResNet is the largest, which is 1.45%, 1.73%, and 0.73% more than those of LeNet7, ResNet, and ECA-ResNet, respectively. The F1 score of SE-ResNet is the largest, which is 2.30%, 2.75%, and 1.15% more than those of LeNet7, ResNet, and ECA-ResNet, respectively. The precision of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 11.81%, 10.17%, 12.02%, and 10.13% respectively on the right column images in Fig. 13, the recall of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 56.35%, 60.48%, 73.10%, and 82.47% respectively on the right column images in Fig. 13, the accuracy of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 96.37%, 95.52%, 95.61%, and 94.15% respectively on the right column images in Fig. 13, the IOU of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 10.82%, 9.54%, 11.51%, and 9.92% respectively on the right column images in Fig. 13, and the F1 score of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 19.52%, 17.41%, 20.64%, and 18.05% respectively on the right column images in Fig. 13. The precision of SE-ResNet is the largest, which is 0.21%, 1.85%, and 1.89% more than those of LeNet7, ResNet, and ECA-ResNet, respectively. The recall of ECA-ResNet is the largest, which is 26.12%, 21.99%, and 9.37% more than those of LeNet7, ResNet, and SE-ResNet, respectively. The accuracy of LeNet7 is the largest, which is 0.85%, 0.76%, and 2.22% more than those of ResNet, SE-ResNet, and ECA-ResNet respectively. The IOU of SE-ResNet is the largest, which is 0.69%, 1.97%, and 1.59% more than those of LeNet7, ResNet, and ECA-ResNet, respectively. The F1 score of SE-ResNet is the largest, which is 1.12%, 3.23%, and 2.59% more than those of LeNet7, ResNet, and ECA-ResNet, respectively. Based on Table 4, it can be concluded that the comprehensive indicators (including precision, recall, accuracy, IOU, and F1 score) of ResNet are the best on the left column images in Fig. 13, the comprehensive indicators (including precision, recall, accuracy, IOU, and F1 score) of SE-ResNet are the best on the middle and right column images in Fig. 13. However, it should be noted that the recall of ECA-ResNet is the largest, far greater than those of the other three networks. It also indicates that ECA-ResNet can recognize the most positive examples of the road network, SE-ResNet can recognize more positive examples of the road network, and LeNet7 and ResNet can recognize fewer positive examples of the road network, which is also consistent with the actual road network detection results of the four networks. Therefore, the road network detection results of ECA-ResNet are generally better than those of LeNet7, ResNet, and SE-ResNet. The road network detection effect of SE-ResNet takes second place, the road network detection effect of ResNet takes third place, and the road network detection effect of LeNet7 was the worst. In summary, it can be seen that although ECA-ResNet has slightly lower accuracy in road network recognition than ResNet and SE-ResNet on the MR dataset, its final road network detection effect is the best. Therefore, the road network detection results of ECA-ResNet are better than those of LeNet7, ResNet, and SE-ResNet.Figure 13 Road network detection results of LeNet7, ResNet, SE-ResNet, and ECA-ResNet on the MR dataset when the connectivity is 10.

Figure 13

Table 3 Road network detection pixel count of LeNet7, ResNet, SE-ResNet, and ECA-ResNet on MR and CHN6-CUG roads datasets.

Table 3Network	Pixel count	
MR	CHN6-CUG	
LeNet7	26,992	20,345	16,366	7,455	11,789	8,050	
ResNet	31,931	24,904	16,923	6,500	10,179	6,499	
SE-ResNet	32,755	21,086	17,356	10,708	12,186	8,025	
ECA-ResNet	60,947	54,569	40,718	13,135	17,839	12,900	

Table 4 Precision, recall, accuracy, IOU, and F1 score of LeNet7, ResNet, SE-ResNet, and ECA-ResNet on MR roads dataset.

Table 4Image	Network	Precision	Recall	Accuracy	IOU	F1 score	
Left	LeNet7	14.70%	25.65%	98.01%	10.31%	18.69%	
ResNet	17.19%	40.62%	97.72%	13.74%	24.16%	
SE-ResNet	16.68%	37.02%	97.79%	12.99%	23.00%	
ECA-ResNet	13.84%	57.93%	96.41%	12.58%	22.35%	
	
Middle	LeNet7	14.44%	34.05%	98.56%	11.28%	20.28%	
ResNet	12.61%	46.37%	97.46%	11.00%	19.83%	
SE-ResNet	14.71%	48.57%	97.75%	12.73%	22.58%	
ECA-ResNet	12.77%	66.63%	96.69%	12.00%	21.43%	
	
Right	LeNet7	11.81%	56.35%	96.37%	10.82%	19.52%	
ResNet	10.17%	60.48%	95.52%	9.54%	17.41%	
SE-ResNet	12.02%	73.10%	95.61%	11.51%	20.64%	
ECA-ResNet	10.13%	82.47%	94.15%	9.92%	18.05%	

Observed from Table 2, although the performance of ECA-ResNet and SE-ResNet is similar to that of LeNet7 and ResNet in terms of accuracy, loss, accuracy convergence and loss convergence on MR dataset, their final road network detection results of the former are significantly better than those of the latter. Fig. 13, Table 3, and Table 4 are sufficient to support the conclusion. The road network detection pixel counts of SE-ResNet and ECA-ResNet are much larger than those of LeNet7 and ResNet, especially ECA-ResNet, and the comprehensive indicators (including precision, recall, accuracy, IOU, and F1 score) of SE-ResNet and ECA-ResNet are also much larger than those of LeNet7 and ResNet, especially SE-ResNet. ECA-ResNet not only has the largest road network detection pixel count and the largest recall, but also has the best actual road network detection results. These indicate that the channel attention mechanism makes the network pay more attention to the extraction and learning of road network features, while ignoring the extraction and learning of some non-road network features, which improves the accuracy of having road network samples and reduces the accuracy of not having road network samples. Therefore, the performance of ECA-ResNet and SE-ResNet is similar to that of LeNet7 and ResNet in the accuracy, loss, accuracy convergence and loss convergence, but the final road network detection results of ECA-ResNet and SE-ResNet are significantly better than those of LeNet7 and ResNet. This further indicates that ECA-ResNet and SE-ResNet with channel attention mechanism have better ability to extract and learn road network features.

3.4.2 Result analysis on CHN6-CUG roads dataset

The comparative experimental results of LeNet7, ResNet, SE-ResNet, and ECA-ResNet on the CHN6-CUG roads dataset are illustrated in Table 2, which is the training result of 50,000 iterations. Observed from Table 2, the accuracies of LeNet7, ResNet, SE-ResNet, and ECA-ResNet on the CHN6-CUG roads dataset are 99.96%, 99.92%, 99.94%, and 99.94%, respectively. Although LeNet7 has the highest accuracy, the difference in accuracy between the other three networks and LeNet7 can be almost negligible. Therefore, the accuracies of the four networks are basically the same. It is also observed that the losses of LeNet7, ResNet, SE ResNet, and ECA ResNet are 0.0023, 0.0025, 0.0025, and 0.0025, respectively. Although the loss of LeNet7 are the smallest, the difference in loss between the other three networks and LeNet7 is almost negligible. Therefore, the losses of the four networks are also basically the same. It is also observed the average training speed of LeNet7, ResNet, SE-ResNet, and ECA-ResNet is 1.2643iters/s, 1.2584iters/s, 0.5957iters/s, and 0.5957iters/s, respectively. LeNet7 has the fastest average training speed, followed by ResNet. The average training speeds of SE-ResNet and ECA-ResNet are the slowest, and LeNet7 and ResNet have much higher average training speeds than SE-ResNet and ECA-ResNet. It is also observed that the parameter numbers of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 79,680, 79,680, 81,728, and 83,776 respectively. ECA-ResNet has the most parameters, SE-ResNet has more parameters, and LeNet7 and ResNet have the least parameters. The overall difference in parameter number among the four networks is not significant, which also confirms the training speed of the four networks. Fig. 14 and Fig. 15 respectively show the relationship between loss and iterations of LeNet7, ResNet, SE-ResNet, and ECA-ResNet on the CHN6-CUG training and test dataset. Observed from Fig. 14, LeNet7, ResNet, SE-ResNet, and ECA-ResNet have basically the same loss convergence on the CHN6-CUG training dataset. As can be seen from Fig. 15, LeNet7, ResNet, SE-ResNet, and ECA-ResNet have basically the same loss convergence on the CHN6-CUG test dataset. Fig. 16 shows the relationship between accuracies and iterations of LeNet7, ResNet, SE-ResNet, and ECA-ResNet on the CHN6-CUG roads dataset. It is observed the accuracy convergence of LeNet7, ResNet, SE-ResNet, and ECA-ResNet is basically consistent, and the accuracy convergence of SE-ResNet and ECA-ResNet is faster at the early stage of training.Figure 14 The relationship between loss and iterations on the CHN6-CUG training dataset.

Figure 14

Figure 15 The relationship between loss and iterations on the CHN6-CUG test dataset.

Figure 15

Figure 16 The relationship between accuracies and iterations on the CHN6-CUG roads dataset.

Figure 16

Fig. 17 shows the partial road network detection results of LeNet7, ResNet, SE-ResNet, and ECA-ResNet on the CHN6-CUG roads dataset with a connectivity size of 10. From Fig. 17, it is observed that the road network detection widths of SE-ResNet and ECA-ResNet are closest to the actual road network width, and better than the road network detection width of LeNet7 and ResNet. Compared with the road network detection widths of SE-ResNet and ECA-ResNet, the road network detection width of ECA-ResNet is better than that of SE-ResNet. The proportion of missing road network detection in ECA-ResNet is significantly lower than that in LeNet7, ResNet, and SE-ResNet. The proportion of road network detection errors in ECA-ResNet is significantly lower than that in LeNet7, ResNet, and SE-ResNet. Table 3 presents the road network detection pixel count of LeNet7, ResNet, SE-ResNet, and ECA-ResNet in Fig. 17. Observed from Table 3, the road network detection pixel counts of LeNet7, ResNet, SE-ResNet and ECA-ResNet are 7,455, 6,500, 10,708, and 13,135 respectively on the left column images in Fig. 13, the road network detection pixel counts of LeNet7, ResNet, SE-ResNet and ECA-ResNet are 11,789, 10,179, 12,186, and 17,839 respectively on the middle column images in Fig. 17, and the road network detection pixel counts of LeNet7, ResNet, SE-ResNet and ECA-ResNet are 8,050, 6,499, 8,025, and 12,900 respectively on the right column images in Fig. 17. It can be seen that the road network detection pixel count of ECA-ResNet is the most, the road network detection pixel count of SE-ResNet is more, and the road network detection pixel counts of LeNet7 and ResNet is the least. Table 5 presents the precision, recall, accuracy, IOU, and F1 score of LeNet7, ResNet, SE-ResNet, and ECA-ResNet on CHN6-CUG roads dataset. Observed from Table 5, the precision of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 29.25%, 28.09%, 32.59%, and 31.62% respectively on the left column images in Fig. 17, the recall of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 30.05%, 24.92%, 34.61%, and 49.15% respectively on the left column images in Fig. 17, the accuracy of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 93.76%, 93.92%, 94.00%, and 93.12% respectively on the left column images in Fig. 17, the IOU of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 17.40%, 15.21%, 20.17%, and 23.82% respectively on the left column images in Fig. 17, and the F1 score of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 29.64%, 26.41%, 33.57%, and 38.48% respectively on the left column images in Fig. 17. The precision of SE-ResNet is the largest, which is 3.34%, 4.50%, and 0.97% more than those of LeNet7, ResNet, and ECA-ResNet, respectively. The recall of ECA-ResNet is the largest, which is 19.10%, 24.23%, and 14.54% more than those of LeNet7, ResNet, and SE-ResNet, respectively. The accuracy of SE-ResNet is the largest, which is 0.24%, 0.08%, and 0.88% more than those of LeNet7, ResNet, and ECA-ResNet, respectively. The IOU of ECA-ResNet is the largest, which is 6.42%, 8.61%, and 3.65% more than those of LeNet7, ResNet, and SE-ResNet, respectively. The F1 score of ECA-ResNet is the largest, which is 8.84%, 12.07%, and 4.91% more than those of LeNet7, ResNet, and SE-ResNet, respectively. The precision of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 28.97%, 31.66%, 30.84%, and 29.70% respectively on the middle column images in Fig. 17, the recall of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 23.28%, 19.73%, 24.70%, and 38.25% respectively on the middle column images in Fig. 17, the accuracy of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 94.89%, 95.30%, 95.01%, and 94.18% respectively on the middle column images in Fig. 17, the IOU of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 14.82%, 13.84%, 15.90%, and 20.08% respectively on the middle column images in Fig. 17, and the F1 score of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 25.81%, 24.31%, 27.43%, and 33.44% respectively on the middle column images in Fig. 17. The precision of ResNet is the largest, which is 2.69%, 0.82%, and 1.96% more than those of LeNet7, SE-ResNet, and ECA-ResNet, respectively. The recall of ECA-ResNet is the largest, which is 14.97%, 18.52%, and 13.55% more than those of LeNet7, ResNet, and SE-ResNet, respectively. The accuracy of ResNet is the largest, which is 0.41%, 0.29%, and 1.12% more than those of LeNet7, SE-ResNet, and ECA-ResNet respectively. The IOU of ECA-ResNet is the largest, which is 5.26%, 6.24%, and 4.18% more than those of LeNet7, ResNet, and SE-ResNet, respectively. The F1 score of ECA-ResNet is the largest, which is 7.63%, 9.13%, and 6.01% more than those of LeNet7, ResNet, and SE-ResNet, respectively. The precision of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 26.99%, 28.14%, 37.82%, and 35.35% respectively on the right column images in Fig. 17, the recall of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 16.84%, 15.31%, 33.90%, and 38.86% respectively on the right column images in Fig. 17, the accuracy of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 94.13%, 94.36%, 94.45%, and 93.39% respectively on the right column images in Fig. 17, the IOU of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 11.57%, 11.01%, 21.77%, and 22.71% respectively on the right column images in Fig. 17, and the F1 score of LeNet7, ResNet, SE-ResNet, and ECA-ResNet are 20.74%, 19.83%, 35.75%, and 37.02% respectively on the right column images in Fig. 17. The precision of SE-ResNet is the largest, which is 10.83%, 9.68%, and 2.47% more than those of LeNet7, ResNet, and ECA-ResNet, respectively. The recall of ECA-ResNet is the largest, which is 22.02%, 23.55%, and 4.96% more than those of LeNet7, ResNet, and SE-ResNet, respectively. The accuracy of SE-ResNet is the largest, which is 0.32%, 0.09%, and 0.48% more than those of LeNet7, ResNet, and ECA-ResNet, respectively. The IOU of ECA-ResNet is the largest, which is 11.14%, 11.70%, and 0.94% more than those of LeNet7, ResNet, and SE-ResNet, respectively. The F1 score of ECA-ResNet is the largest, which is 16.28%, 17.19%, and 1.27% more than those of LeNet7, ResNet, and SE-ResNet, respectively. Based on Table 5, it can be concluded that the comprehensive indicators (including precision, recall, accuracy, IOU, and F1 score) of ECA-ResNet are the best on the left, middle and right column images in Fig. 17 and the recall of ECA-ResNet is the largest, far greater than those of the other three networks. It also indicates that ECA-ResNet can recognize the most positive examples of the road network, SE-ResNet can recognize more positive examples of the road network, and LeNet7 and ResNet can recognize fewer positive examples of the road network, which is also consistent with the actual road network detection results of the four networks. Moreover, the proportion of true road networks predicted by SE-ResNet and ECA-ResNet in the positive samples is generally higher than that of true road networks predicted by LeNet7 and ResNet in the positive samples. Therefore, the road network detection results of ECA-ResNet are generally better than those of LeNet7, ResNet, and SE-ResNet. The road network detection effect of SE-ResNet takes second place, and the road network detection effects of LeNet7 and ResNet are the worst. In summary, it can be seen that although ECA-ResNet has slightly lower accuracy in road network recognition than ResNet and SE-ResNet on the CHN6-CUG roads dataset, its final road network detection effect is the best. Therefore, the road network detection results of ECA-ResNet are better than those of LeNet7, ResNet, and SE-ResNet.Figure 17 Road network detection results of LeNet7, ResNet, SE-ResNet, and ECA-ResNet on the CHN6-CUG roads dataset when the connectivity is 10.

Figure 17

Table 5 Precision, recall, accuracy, IOU, and F1 score of LeNet7, ResNet, SE-ResNet, and ECA-ResNet on CHN6-CUG roads dataset.

Table 5Image	Network	Precision	Recall	Accuracy	IOU	F1 score	
Left	LeNet7	29.25%	30.05%	93.76%	17.40%	29.64%	
ResNet	28.09%	24.92%	93.92%	15.21%	26.41%	
SE-ResNet	32.59%	34.61%	94.00%	20.17%	33.57%	
ECA-ResNet	31.62%	49.15%	93.12%	23.82%	38.48%	
	
Middle	LeNet7	28.97%	23.28%	94.89%	14.82%	25.81%	
ResNet	31.66%	19.73%	95.30%	13.84%	24.31%	
SE-ResNet	30.84%	24.70%	95.01%	15.90%	27.43%	
ECA-ResNet	29.70%	38.25%	94.18%	20.08%	33.44%	
	
Right	LeNet7	26.99%	16.84%	94.13%	11.57%	20.74%	
ResNet	28.14%	15.31%	94.36%	11.01%	19.83%	
SE-ResNet	37.82%	33.90%	94.45%	21.77%	35.75%	
ECA-ResNet	35.35%	38.86%	93.97%	22.71%	37.02%	

Observed from Table 2, although the performance of ECA-ResNet and SE-ResNet is basically consistent with that of LeNet7 and ResNet in terms of accuracy, loss, accuracy convergence and loss convergence on CHN6-CUG roads dataset, their final road network detection results of the former are significantly better than those of the latter. Fig. 17, Table 3, and Table 5 are sufficient to support the conclusion. The road network detection pixel counts of SE-ResNet and ECA-ResNet are much larger than those of LeNet7 and ResNet, especially ECA-ResNet, and the comprehensive indicators (including precision, recall, accuracy, IOU, and F1 score) of SE-ResNet and ECA-ResNet are also much larger than those of LeNet7 and ResNet, especially ECA-ResNet. ECA-ResNet not only has the largest road network detection pixel count, the largest recall, the largest IOU, and the largest F1 score, but also has the best actual road network detection results. These indicate that the channel attention mechanism makes the network pay more attention to the extraction and learning of road network features, while ignoring the extraction and learning of some non-road network features, which improves the accuracy of having road network samples and reduces the accuracy of not having road network samples. Therefore, the performance of ECA-ResNet and SE-ResNet is similar to that of LeNet7 and ResNet in the accuracy, loss, accuracy convergence and loss convergence, but the final road network detection results of ECA-ResNet and SE-ResNet are significantly better than those of LeNet7 and ResNet. This further indicates that ECA-ResNet and SE-ResNet with channel attention mechanism have better ability to extract and learn road network features.

4 Conclusion

The attention mechanism greatly improves the task performance of the network under the condition of minimal burden, and its plug and play feature brings great convenience to programmers. It is one of the efficient and practical mechanisms in deep learning. Therefore, in response to the problem of remote sensing image road network detection, the paper combines the channel attention mechanism with ResNet and proposes SE-ResNet and ECA-ResNet for remote sensing image road network detection. The experimental results show that although ECA-ResNet and SE-ResNet based on channel attention mechanism perform similar to LeNet7 and ResNet in terms of accuracy, loss, accuracy convergence, and loss convergence, and even increase a certain computational burden, their final road network detection results (including road network detection pixel count, precision, recall, accuracy, IOU, F1 score, and actual road network detection result) of the former are significantly better than those of the latter. The channel attention mechanism can make the network pay more attention to the extraction and learning of road network features, while ignoring the extraction and learning of some non-road network features, which improves the accuracy of having road network samples and reduces the accuracy of not having road network samples, thus enabling more scientific and reasonable utilization and allocation of computing resources. Therefore, the proposed ECA-ResNet and SE-ResNet have broad application prospects in road network detection, especially ECA-ResNet. However, ECA-ResNet and SE-ResNet still have lower precision and accuracy. Further improving the precision and accuracy is the next research direction of the paper.

Ethics approval

This article does not contain any studies with human participants or animals performed by any of the authors.

Consent to participate

Yes.

Consent for publication

Yes.

Funding

Funding for this research has been provided by grants from the Key projects of Natural Science Research of Universities in Anhui Province, China (No. 2023AH050929 ), the Pre-research Project of National Natural Science Foundation of Anhui Polytechnic University (No. Xjky2022046 ), and the Regional Innovation and Development Joint Funds of the National Natural Science Foundation of China (No. U22A2079 ).

CRediT authorship contribution statement

Chuanhui Shan: Writing – review & editing, Writing – original draft, Methodology, Investigation, Data curation. Xinlong Geng: Writing – review & editing, Visualization, Data curation. Chao Han: Visualization, Validation, Funding acquisition.

Declaration of Competing Interest

The authors declare that they have no known competing financial interests or personal relationships that could have appeared to influence the work reported in this paper.

Data availability

The code is not available in a public repository. The data is available in a public repository. Massachusetts roads (MR) dataset that supports the findings of this study is openly available at [https://www.kaggle.com/datasets/balraj98/massachusetts-roads-dataset] or [https://paperswithcode.com/dataset/massachusetts-roads-dataset], reference number [31]. CHN6-CUG roads dataset that supports the findings of this study is openly available at [https://github.com/CUG-URS/CHN6-CUG-Roads-Dataset], reference number [32].

Acknowledgements

The support of the Key projects of Natural Science Research of Universities in Anhui Province, China (No. 2023AH050929 ), Pre-research Project of National Natural Science Foundation of Anhui Polytechnic University (No. Xjky2022046 ), and the Regional Innovation and Development Joint Funds of the National Natural Science Foundation of China (No. U22A2079 ) are gratefully acknowledged.
==== Refs
References

1 Unsalan C. Sirmacek B. Road network detection using probabilistic and graph theoretical methods IEEE Trans. Geosci. Remote Sens. 50 11 2012 4441 4453 10.1109/TGRS.2012.2190078
2 Abdollahi A. Pradhan B. Shukla N. Deep learning approaches applied to remote sensing datasets for road extraction: a state-of-the-art review Remote Sens. 12 9 2020 1444 10.3390/rs12091444
3 Abdollahi A. Pradhan B. Shukla N. Road extraction from high-resolution orthophoto images using convolutional neural network J. Ind. Soc. Remote Sens. 49 3 2021 569 583 10.1007/s12524-020-01228-y
4 Mnih V. Hinton G.E. Learning to detect roads in high-resolution aerial images European Conference on Computer Vision 2010 Springer Berlin, Heidelberg 210 223
5 Zhang Z. Liu Q. Wang Y. Road extraction by deep residual u-net IEEE Geosci. Remote Sens. Lett. 15 5 2018 749 753 10.1109/LGRS.2018.2802944
6 Zhang K. Zuo W. Chen Y. Beyond a gaussian denoiser: residual learning of deep cnn for image denoising IEEE Trans. Image Process. 26 7 2017 3142 3155 10.1109/TIP.2017.2662206 28166495
7 Xu Y. Xie Z. Feng Y. Road extraction from high-resolution remote sensing imagery using deep learning Remote Sens. 10 9 2018 1461 10.3390/rs10091461
8 Huang G. Liu Z. V.D.M L. Densely connected convolutional networks Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition 2017 4700 4708
9 Shan B. Fang Y. A cross entropy based deep neural network model for road extraction from satellite images Entropy 22 5 2020 535 10.3390/e22050535 33286307
10 Ren Y. Yu Y. Guan H. Da-capsunet: a dual-attention capsule u-net for road extraction from remote sensing imagery Remote Sens. 12 18 2020 2866 10.3390/rs12182866
11 Abdollahi A. Pradhan B. Alamri A. Vnet: an end-to-end fully convolutional neural network for road extraction from high-resolution remote sensing data IEEE Access 8 2020 179424 179436 10.1109/ACCESS.2020.3026658
12 Chen Z. Wang C. Li J. Reconstruction bias u-net for road extraction from optical remote sensing images IEEE J. Sel. Top. Appl. Earth Obs. Remote Sens. 14 2021 2284 2294 10.1109/JSTARS.2021.3053603
13 Hou Y. Liu Z. Zhang T. C-unet: complement unet for remote sensing road extraction Sensors 21 6 2021 2153 10.3390/s21062153 33808588
14 Yang M. Yuan Y. Liu G. Sdunet: road extraction via spatial enhanced and densely connected unet Pattern Recognit. 126 2022 108549 10.1016/j.patcog.2022.108549
15 Wang Y. Peng Y. Li W. Ddu-net: dual-decoder-u-net for road extraction using high-resolution remote sensing images IEEE Trans. Geosci. Remote Sens. 60 2022 1 20 10.1109/TGRS.2022.3197546
16 Mnih V. Heess N. Graves A. Recurrent models of visual attention Proc of Advances in Neural Information Processing Systems 27 (NIPS 2014) 2014 MIT Press Cambridge, MA 2204 2212
17 Hu J. Shen L. Sun G. Squeeze-and-excitation networks Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition 2018 7132 7141
18 Zhong Z. Lin Z.Q. Bidart R. Squeeze-and-attention networks for semantic segmentation Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition 2020 13065 13074
19 Ulutan O. Iftekhar A.S.M. Manjunath B.S. Vsgnet: spatial attention network for detecting human object interactions using graph convolutions Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition 2020 13617 13626
20 Woo S. Park J. Lee J.Y. Cbam: convolutional block attention module Proceedings of the European Conference on Computer Vision (ECCV) 2018 3 19
21 Li X. Wang W. Hu X. Selective kernel networks Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition 2019 510 519
22 Fu J. Liu J. Tian H. Dual attention network for scene segmentation Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition 2019 3146 3154
23 Zhao T. Wu X. Pyramid feature attention network for saliency detection Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition 2019 3085 3094
24 Wang Q. Wu B. Zhu P. Eca-net: efficient channel attention for deep convolutional neural networks Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition 2020 11534 11542
25 Vaswani A. Shazeer N. Parmar N. Attention is all you need Advances in Neural Information Processing Systems 2017 6000 6010
26 Dosovitskiy A. Beyer L. Kolesnikov A. An image is worth 16×16 words: Transformers for image recognition at scale Proceedings of the 9th International Conference on Learning Representations 2021 1 22
27 Zhang H. Wu C. Zhang Z. Resnest: split-attention networks Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition 2022 2736 2746
28 Li S. Liao C. Ding Y. Cascaded residual attention enhanced road extraction from remote sensing images ISPRS Int.l J. Geo-Inf. 11 1 2022 9 10.3390/ijgi11010009
29 Khan S.D. Alarabi L. Basalamah S. Dsmsa-net: deep spatial and multi-scale attention network for road extraction in high spatial resolution satellite images Arab. J. Sci. Eng. 48 2 2023 1907 1920 10.1007/s13369-022-07082-z
30 He K. Zhang X. Ren S. Deep residual learning for image recognition Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition 2016 770 778
31 Mnih V. Machine Learning for Aerial Image Labeling 2013 University of Toronto Canada
32 Zhu Q. Zhang Y. Wang L. A global context-aware and batch-independent network for road extraction from vhr satellite imagery ISPRS J. Photogramm. Remote Sens. 175 12 2021 353 365 10.1016/j.isprsjprs.2021.03.016
