# Research on Segmentation Method of Greening Landscape of Urban Community Based on Improved U-Net Network

Authors: Jing Sui
Journal: Security and Communication Networks
 (2022)

---

## Abstract

Aiming at the problem of low segmentation accuracy of greening landscape of urban community, a segmentation method of greening landscape of urban community based on improved U-Net network is proposed by adding an encoder on U-Net network. In addition, simulation is carried out on the remote sensing image data collected by GPRS network, and the effectiveness of the method is verified. The simulation results show that the result of proposed method is close to that of manual annotation. Compared with the traditional segmentation algorithm SVM and SegNet method, as well as the U-Net network before improvement, the proposed method has higher segmentation accuracy. The segmentation accuracy can reach up to 91%, the intersection ratio can reach 76%, and the mean pixel accuracy and mean intersection ratio can reach 89% and 74%, which indicates that the proposed method has certain validity and practicability.


---

## Body

## 1. Related Work

As a community of people’s life, its environment affects people’s living conditions. In recent years, with the improvement of human living standard, the requirements for community environment have been more and more strict, and more and more attention has been paid to community landscape greening space. At the same time, with the advancement of urbanization, for the requirements of sustainable urban development planning, community landscape greening space should be reasonably distributed. Therefore, whether the landscape greening space distribution in a community is reasonable is an important indicator to judge sustainable urban development. At present, there are few researches on the landscape greening space distribution of community, and there is no effective segmentation method. Therefore, with the help of deep learning image processing method, the landscape greening space distribution of community is studied. For example, Qu et al. used the combined information of SVM network and HSI spatial spectrum to realize multiscale hyperspectral image classification [1]. Zhou et al. extracted image features through K-L transformation, mapped image features to quantum states through quantum coding, and used Hamming distance to represent image similarity. A new distance-weighted K-value classification method is proposed, which can achieve more accurate image classification [2]. Wang et al. used the symmetry theory and neural network to propose a symmetric neural network and proved the effectiveness of the algorithm by applying the classification algorithm to the classification of three-dimensional martial arts images [3]. Liu et al. introduced the idea of sparse representation into the architecture of deep learning network, thus a sparse representation classification method is proposed, which can replace the classifier of model and improve the effect of image classification [4]. Xiaoqing Zhang and Zhang adopted typical manifold learning method and local linear embedding (LLE) to construct graphs, and semisupervised classification was carried out on this basis. The classification of hyperspectral images is realized [5, 6]. On the basis of Weber’s law, Kong et al. adopted multiresolution Weber local descriptor to propose a digital image forgery detection technology, which can achieve multiresolution image classification [7]. Martines et al. used geographic processing and remote sensing technologies to explore the effect of three image classification algorithms, MLC, SVM and RT. It is found that the three algorithms can distinguish the target successfully [8]. Among them, MLC has higher efficiency, RT has the lowest efficiency, and SVM has the highest accuracy. As can be seen, the deep learning has a good effect in the classification of image recognition, and the landscape greening space distribution of community is actually the classification of remote sensing image recognition. Therefore, using the deep learning to study the landscape greening space distribution of community, based on the urban community landscape collected by GPRS network, taking U-Net network as the basic framework, a landscape classification model can be constructed.


## 2. Basic Methods

### 2.1. Overview of U-Net Network

U-Net network is a classical full convolutional network, and it is composed of encoder and decoder, which is shown in Figure1 [9]. The encoder is used to extract spatial features from the image, and its convolution block includes two 3∗3 convolution and maximum pooling operation. After downsampling, the filter in the convolution is doubled and connected to the decoder through convolution operation. According to the segmentation graph constructed by encoder, the decoder firstly uses 2∗2 convolution operation to upsample it, which reduces the feature channel to half of the original. Then, two 3∗3 convolution operations and one 1∗1 convolution operation are successively developed.Figure 1
U-Net network structure.When the context information is transmitted to the high level, U-Net network adopts four jump connections to reduce the loss of high-resolution feature information, thus edge accuracy and resolution of final segmentation results are improved [10]. In recent years, U-Net network has been widely used to segment image because of its good segmentation effect. However, since the images used in the landscape greening space distribution of community in this paper are remote sensing images, there is often the problem of unequal target distribution. Moreover, if the standard U-Net network is used to construct classification model, the classification accuracy may be low. Therefore, in order to improve the segmentation accuracy, U-Net network needs to be improved.


### 2.2. Improvement of U-Net Network

The improvement of U-Net network mainly includes the following aspects:(1)
To enhance the image minimum resolution receptive field, an encoder is added to original U-Net network to distinguish the input images with different levels of resolution;(2)
To enrich context information, Concat is used in each upsampling block to fuse different levels of features;(3)
To improve the speed of network training, all convolutional blocks are changed to deep convolutional blocks, and “one deep convolutional layer + one batch standardization layer + one convolutional layer” is adopted to replace the traditional convolutional layer;(4)
To ensure that downsampling can obtain more feature information, deep separable convolutional block is used to replace maximum pooling for downsampling;(5)
To increase the receptive field of feature map, deep separable convolution of dilated convolution is adopted as the last three convolutional blocks;(6)
To reduce the grid problem caused by dilated convolution, the dilation intervals of high and low resolution modules are set as 4 and 2, respectively.(7)
To reduce the computational complexity and improve the segmentation accuracy, there is 512 depth adopted in the last coding block and the first decoding block to replace 1024 depth.The structure of improved U-Net network is shown in Figure2, and its encoding block and decoding block structures are shown in Figure 3.Figure 2
The improved U-Net network structure.Figure 3
Encoding block and decoding block structure of improved U-Net network. (a) Encoding block structure (b) Decoding block structure. (c) SepConv structure.
(a)(b)(c)


## 2.1. Overview of U-Net Network

U-Net network is a classical full convolutional network, and it is composed of encoder and decoder, which is shown in Figure1 [9]. The encoder is used to extract spatial features from the image, and its convolution block includes two 3∗3 convolution and maximum pooling operation. After downsampling, the filter in the convolution is doubled and connected to the decoder through convolution operation. According to the segmentation graph constructed by encoder, the decoder firstly uses 2∗2 convolution operation to upsample it, which reduces the feature channel to half of the original. Then, two 3∗3 convolution operations and one 1∗1 convolution operation are successively developed.Figure 1
U-Net network structure.When the context information is transmitted to the high level, U-Net network adopts four jump connections to reduce the loss of high-resolution feature information, thus edge accuracy and resolution of final segmentation results are improved [10]. In recent years, U-Net network has been widely used to segment image because of its good segmentation effect. However, since the images used in the landscape greening space distribution of community in this paper are remote sensing images, there is often the problem of unequal target distribution. Moreover, if the standard U-Net network is used to construct classification model, the classification accuracy may be low. Therefore, in order to improve the segmentation accuracy, U-Net network needs to be improved.


## 2.2. Improvement of U-Net Network

The improvement of U-Net network mainly includes the following aspects:(1)
To enhance the image minimum resolution receptive field, an encoder is added to original U-Net network to distinguish the input images with different levels of resolution;(2)
To enrich context information, Concat is used in each upsampling block to fuse different levels of features;(3)
To improve the speed of network training, all convolutional blocks are changed to deep convolutional blocks, and “one deep convolutional layer + one batch standardization layer + one convolutional layer” is adopted to replace the traditional convolutional layer;(4)
To ensure that downsampling can obtain more feature information, deep separable convolutional block is used to replace maximum pooling for downsampling;(5)
To increase the receptive field of feature map, deep separable convolution of dilated convolution is adopted as the last three convolutional blocks;(6)
To reduce the grid problem caused by dilated convolution, the dilation intervals of high and low resolution modules are set as 4 and 2, respectively.(7)
To reduce the computational complexity and improve the segmentation accuracy, there is 512 depth adopted in the last coding block and the first decoding block to replace 1024 depth.The structure of improved U-Net network is shown in Figure2, and its encoding block and decoding block structures are shown in Figure 3.Figure 2
The improved U-Net network structure.Figure 3
Encoding block and decoding block structure of improved U-Net network. (a) Encoding block structure (b) Decoding block structure. (c) SepConv structure.
(a)(b)(c)


## 3. Space Segmentation Model of Community Landscape Greening Based on Improved U-Net

The above improved U-Net network is adopted to construct segmentation model of community landscape greening space distribution, and the optimization method and loss function are configured. In addition, the adaptive threshold method is used to determine the thresholds of different landscape categories.


### 3.1. Network Configuration

#### 3.1.1. Optimization Method

NAdam algorithm is a model optimization method proposed to improve the sensitivity of Adam optimization algorithm, in which Nesterov momentum term is added to correct the gradient in the updating process, which has better sensitivity [11]. Therefore, NAdam algorithm is adopted as model optimization method, and its formulas are as follows:(1)mt=μt∗mt−1+1−μt∗gt,m^t=mt1−∏i=1t+1μi,nt=v∗nt−1+1−v∗gt2,n^t=nt1−vtm¯t=1−μt∗g^t+μt+1∗m^t,Δθ=−η∗m¯tn^t+ε,wherein formulas (1)–(3) are first-order momentum and second-order momentum, respectively; formulas (2) and formula (4) are corrected momenta; −η is the step size and ε is the lattice constant. gt represents gradient descent value; µ is the exponential decay rate, and its value range is [0,1]. mt is the momentum vector.


#### 3.1.2. Loss Function

The loss function directly affects the training effect of model. In image segmentation, the cross entropy function, as shown in formula (2), is mostly used as the loss function [12]. However, when sample categories are unbalanced, this loss function tends to lead to inaccurate model training results. In order to solve this problem, reference [13] introduces weight parameter α to balance samples and dynamically adjust the loss function, which is defined as follows:(2)FLpt=−αt1−ptγlogpt.


### 3.2. Adaptive Threshold

Landscape greening space distribution of community is usually characterized by unbalanced landscape distribution and complex categories. If the same threshold judgment model is used to predict categories, it is easy to lead to large errors in the final segmentation results [14]. Therefore, adaptive threshold method is adopted to determine the optimal classification accuracy of different landscape categories. The threshold set of n classes is defined as T=t1,t2,…,tn, and jit is the pixel accuracy of class i, then the threshold of class i can be expressed as follows:(3)ti=argmaxjit.


## 3.1. Network Configuration

### 3.1.1. Optimization Method

NAdam algorithm is a model optimization method proposed to improve the sensitivity of Adam optimization algorithm, in which Nesterov momentum term is added to correct the gradient in the updating process, which has better sensitivity [11]. Therefore, NAdam algorithm is adopted as model optimization method, and its formulas are as follows:(1)mt=μt∗mt−1+1−μt∗gt,m^t=mt1−∏i=1t+1μi,nt=v∗nt−1+1−v∗gt2,n^t=nt1−vtm¯t=1−μt∗g^t+μt+1∗m^t,Δθ=−η∗m¯tn^t+ε,wherein formulas (1)–(3) are first-order momentum and second-order momentum, respectively; formulas (2) and formula (4) are corrected momenta; −η is the step size and ε is the lattice constant. gt represents gradient descent value; µ is the exponential decay rate, and its value range is [0,1]. mt is the momentum vector.


### 3.1.2. Loss Function

The loss function directly affects the training effect of model. In image segmentation, the cross entropy function, as shown in formula (2), is mostly used as the loss function [12]. However, when sample categories are unbalanced, this loss function tends to lead to inaccurate model training results. In order to solve this problem, reference [13] introduces weight parameter α to balance samples and dynamically adjust the loss function, which is defined as follows:(2)FLpt=−αt1−ptγlogpt.


## 3.1.1. Optimization Method

NAdam algorithm is a model optimization method proposed to improve the sensitivity of Adam optimization algorithm, in which Nesterov momentum term is added to correct the gradient in the updating process, which has better sensitivity [11]. Therefore, NAdam algorithm is adopted as model optimization method, and its formulas are as follows:(1)mt=μt∗mt−1+1−μt∗gt,m^t=mt1−∏i=1t+1μi,nt=v∗nt−1+1−v∗gt2,n^t=nt1−vtm¯t=1−μt∗g^t+μt+1∗m^t,Δθ=−η∗m¯tn^t+ε,wherein formulas (1)–(3) are first-order momentum and second-order momentum, respectively; formulas (2) and formula (4) are corrected momenta; −η is the step size and ε is the lattice constant. gt represents gradient descent value; µ is the exponential decay rate, and its value range is [0,1]. mt is the momentum vector.


## 3.1.2. Loss Function

The loss function directly affects the training effect of model. In image segmentation, the cross entropy function, as shown in formula (2), is mostly used as the loss function [12]. However, when sample categories are unbalanced, this loss function tends to lead to inaccurate model training results. In order to solve this problem, reference [13] introduces weight parameter α to balance samples and dynamically adjust the loss function, which is defined as follows:(2)FLpt=−αt1−ptγlogpt.


## 3.2. Adaptive Threshold

Landscape greening space distribution of community is usually characterized by unbalanced landscape distribution and complex categories. If the same threshold judgment model is used to predict categories, it is easy to lead to large errors in the final segmentation results [14]. Therefore, adaptive threshold method is adopted to determine the optimal classification accuracy of different landscape categories. The threshold set of n classes is defined as T=t1,t2,…,tn, and jit is the pixel accuracy of class i, then the threshold of class i can be expressed as follows:(3)ti=argmaxjit.


## 4. Simulation Experiment

### 4.1. Construction of Experimental Environment

This experiment is conducted on Ubuntu 16.04 LTS operating system. The deep learning model is constructed based on Tensorflow 1.14 and Keras 2.4 frameworks. The CPU is configured as Intel (R) Core (TM) i7-6700CPU@3.40 GHz, and the memory is 16 GB. The CPU is NVIDIA GTX 1080Ti, which is implemented based on software, such as Arc GIS10.3 and MATLAB.


### 4.2. Data Sources and Preprocessing

The data in this study come from the remote sensing image data collected by a system through GPRS, which mainly contain 5 labeled large-size RGB remote sensing images [15, 16] of vegetation (No. 1), building (No. 2), water body (No. 3), road (No. 4), and others (No. 0). The image size is 4608∗4608, and the level is 17. Furthermore, the pixel resolution is 1.3 m, and the scale is 1 : 727.Due to the influence of weather, geographical location, and other external factors in the process of experimental data collection, the image may have geometric distortion and atomization problems, so the image needs to be preprocessed before experiment. According to the actual problems of remote sensing images, ENVI tool is used for geometric calibration of images, and image defogging algorithm based on channel priority is adopted for defogging treatment [17, 18]. The specific operation of defogging is as follows:The dark channel is defined as the following formula:(4)Jdarkx=minc∈r,q,bminy∈ΩxJcy,where x is the pixel point, and Ω is the window in channel.Then, the established atmospheric physical model is(5)Ix=Jxtx+A1−tx,where I is the input image; J is the output image; A is the global atmospheric illumination intensity; and t is the transmittance, which can be calculated by the following formula:(6)t˜x=1−ωmincminy∈ΩxIcyAc,where Ic is the input image and Ac is the global atmospheric illumination, as shown in the following formula:(7)Ac=AR,AG,AB,AR=sumRN,AG=sumGN,AB=sumBN,where sumR, sumG, and sumB represent the sum of coordinates of the brightest pixel point at 1/1000 of the total pixel point of the image found in Jdarkx in the three channels of the original image. Combined with the atmospheric physical model, the defogging image can be obtained:(8)Jx=Ix−Amaxtx,t0+A.In addition, in order to avoid over-fitting, data enhancements such as rotation, mirror image, and adding noise are performed for the data sets processed by geometric calibration and defogging.Finally, the data sets are divided into training set and test set according to the ratio of 7 : 3.


### 4.3. Evaluation Indicators

There are pixel accuracy (PA), mean pixel accuracy (MPA), and mean intersection over union (MIoU) selected as indicators to evaluate performance of method, and the calculation methods are as follows [19–22]:(9)PA=∑i=0kpii∑i=0k∑j=0kpij,MeanPA=1k+1∑i=0kpii∑j=0ipij,MIoU=1k+1∑i=0kpii∑j=0kpij+∑j=0kpij−pii,where pii, pij, and pji represent the true positive cases, false positive cases, and false negative cases, respectively.


### 4.4. Experimental Results

#### 4.4.1. Model Verification

To verify the effectiveness of proposed method, the performance of model under different network configurations and adaptive thresholds is analyzed experimentally. Figure4 shows the changes of model evaluation indicators with the epoch when different optimization methods are adopted. Compared with SGD method, loss of Adam and Nadam method decreases faster and accuracy increases faster. The SGD method reaches saturation in 10 epochs, and the Adam and Nadam methods reach saturation in 30 epochs. The test loss of Nadam method is closest to the verification loss, and the test accuracy is closest to the verification accuracy, indicating that using the Nadam method as a model training and optimization method has certain advantages.Figure 4
Changes of evaluation indicators of different optimization methods with epoch. (a) SGD. (b) Adam. (c) Nadam.
(a)(b)(c)Under the condition that other parameter conditions remain fixed, adaptive threshold method is adopted to train all types of data sets, and the changes of accuracy of different landscape pixels with probability thresholds are obtained as shown in Figure5. As can be seen, the probability threshold of different categories is different. By comparing the best probability threshold of each classification, the best threshold of vegetation landscape classification can be obtained, and it is 0.6; the best threshold of road landscape classification is 0.4; the best threshold of building classification is 0.4; the best threshold of the water body classification is 0.6; and the best threshold of other classification is 0.3.Figure 5
Changes of different landscapes pixel accuracy with probability threshold.Taking roads as an example, the comparison of segmentation effects adding adaptive threshold and not adding adaptive threshold (0.5) is shown in Figure6. As can been seen, the segmentation effect achieved by adding adaptive threshold is better.Figure 6
Comparison of segmentation effects. (a) Image without adaptive threshold. (b) Image with adaptive threshold.
(a)(b)


#### 4.4.2. Model Comparison

To verify the superiority of the proposed model, the segmentation results of different methods on CCF data set and BDS data set are compared. Figure7 compares the segmentation results of proposed method with traditional classification methods SVM, SegNet, and U-Net on CCF data sets and provides manual annotation results as a reference. The SVM classification method is prone to misclassify buildings and roads, and there are many noise points in the segmentation results. Compared with SVM classification methods, SegNet and U-Net segmentation methods reduce the misclassification and noise points, but there are still problems of misclassification and missing classification of buildings and roads. The proposed method can segment all categories well, and the segmentation effect of buildings and roads is better than that of the contrast method. The reason is that when the target is segmented, the proposed method can fuse multiscale cross features and expand the receptive field, thus the global feature during target segmentation is better extracted. On the whole, compared with the contrast method, the image segmentation result of proposed method is closer to manual annotation result, and the visual effect is the best.Figure 7
Segmentation results of different methods on CCF data set. (a) Original image. (b) SVM. (c) U-Net. (d) the proposed network.
(a)(b)(c)(d)Figure8 shows the segmentation result evaluation of different methods on CCF data set. The pixel segmentation accuracy and mean intersection over union of proposed method are higher than those of contrast method for all categories on CCF data set. Compared with SVM and U-Net methods, the mean pixel accuracy reaches 91%, which increases by 19%, 7%, and 2%, respectively. The mean intersection over union increases by 11%, 3%, and 1%, respectively, which reaches 76%. Therefore, the proposed method has good image segmentation performance and certain advantages.Figure 8
Segmentation result evaluation of different methods on CCF data set.


## 4.1. Construction of Experimental Environment

This experiment is conducted on Ubuntu 16.04 LTS operating system. The deep learning model is constructed based on Tensorflow 1.14 and Keras 2.4 frameworks. The CPU is configured as Intel (R) Core (TM) i7-6700CPU@3.40 GHz, and the memory is 16 GB. The CPU is NVIDIA GTX 1080Ti, which is implemented based on software, such as Arc GIS10.3 and MATLAB.


## 4.2. Data Sources and Preprocessing

The data in this study come from the remote sensing image data collected by a system through GPRS, which mainly contain 5 labeled large-size RGB remote sensing images [15, 16] of vegetation (No. 1), building (No. 2), water body (No. 3), road (No. 4), and others (No. 0). The image size is 4608∗4608, and the level is 17. Furthermore, the pixel resolution is 1.3 m, and the scale is 1 : 727.Due to the influence of weather, geographical location, and other external factors in the process of experimental data collection, the image may have geometric distortion and atomization problems, so the image needs to be preprocessed before experiment. According to the actual problems of remote sensing images, ENVI tool is used for geometric calibration of images, and image defogging algorithm based on channel priority is adopted for defogging treatment [17, 18]. The specific operation of defogging is as follows:The dark channel is defined as the following formula:(4)Jdarkx=minc∈r,q,bminy∈ΩxJcy,where x is the pixel point, and Ω is the window in channel.Then, the established atmospheric physical model is(5)Ix=Jxtx+A1−tx,where I is the input image; J is the output image; A is the global atmospheric illumination intensity; and t is the transmittance, which can be calculated by the following formula:(6)t˜x=1−ωmincminy∈ΩxIcyAc,where Ic is the input image and Ac is the global atmospheric illumination, as shown in the following formula:(7)Ac=AR,AG,AB,AR=sumRN,AG=sumGN,AB=sumBN,where sumR, sumG, and sumB represent the sum of coordinates of the brightest pixel point at 1/1000 of the total pixel point of the image found in Jdarkx in the three channels of the original image. Combined with the atmospheric physical model, the defogging image can be obtained:(8)Jx=Ix−Amaxtx,t0+A.In addition, in order to avoid over-fitting, data enhancements such as rotation, mirror image, and adding noise are performed for the data sets processed by geometric calibration and defogging.Finally, the data sets are divided into training set and test set according to the ratio of 7 : 3.


## 4.3. Evaluation Indicators

There are pixel accuracy (PA), mean pixel accuracy (MPA), and mean intersection over union (MIoU) selected as indicators to evaluate performance of method, and the calculation methods are as follows [19–22]:(9)PA=∑i=0kpii∑i=0k∑j=0kpij,MeanPA=1k+1∑i=0kpii∑j=0ipij,MIoU=1k+1∑i=0kpii∑j=0kpij+∑j=0kpij−pii,where pii, pij, and pji represent the true positive cases, false positive cases, and false negative cases, respectively.


## 4.4. Experimental Results

### 4.4.1. Model Verification

To verify the effectiveness of proposed method, the performance of model under different network configurations and adaptive thresholds is analyzed experimentally. Figure4 shows the changes of model evaluation indicators with the epoch when different optimization methods are adopted. Compared with SGD method, loss of Adam and Nadam method decreases faster and accuracy increases faster. The SGD method reaches saturation in 10 epochs, and the Adam and Nadam methods reach saturation in 30 epochs. The test loss of Nadam method is closest to the verification loss, and the test accuracy is closest to the verification accuracy, indicating that using the Nadam method as a model training and optimization method has certain advantages.Figure 4
Changes of evaluation indicators of different optimization methods with epoch. (a) SGD. (b) Adam. (c) Nadam.
(a)(b)(c)Under the condition that other parameter conditions remain fixed, adaptive threshold method is adopted to train all types of data sets, and the changes of accuracy of different landscape pixels with probability thresholds are obtained as shown in Figure5. As can be seen, the probability threshold of different categories is different. By comparing the best probability threshold of each classification, the best threshold of vegetation landscape classification can be obtained, and it is 0.6; the best threshold of road landscape classification is 0.4; the best threshold of building classification is 0.4; the best threshold of the water body classification is 0.6; and the best threshold of other classification is 0.3.Figure 5
Changes of different landscapes pixel accuracy with probability threshold.Taking roads as an example, the comparison of segmentation effects adding adaptive threshold and not adding adaptive threshold (0.5) is shown in Figure6. As can been seen, the segmentation effect achieved by adding adaptive threshold is better.Figure 6
Comparison of segmentation effects. (a) Image without adaptive threshold. (b) Image with adaptive threshold.
(a)(b)


### 4.4.2. Model Comparison

To verify the superiority of the proposed model, the segmentation results of different methods on CCF data set and BDS data set are compared. Figure7 compares the segmentation results of proposed method with traditional classification methods SVM, SegNet, and U-Net on CCF data sets and provides manual annotation results as a reference. The SVM classification method is prone to misclassify buildings and roads, and there are many noise points in the segmentation results. Compared with SVM classification methods, SegNet and U-Net segmentation methods reduce the misclassification and noise points, but there are still problems of misclassification and missing classification of buildings and roads. The proposed method can segment all categories well, and the segmentation effect of buildings and roads is better than that of the contrast method. The reason is that when the target is segmented, the proposed method can fuse multiscale cross features and expand the receptive field, thus the global feature during target segmentation is better extracted. On the whole, compared with the contrast method, the image segmentation result of proposed method is closer to manual annotation result, and the visual effect is the best.Figure 7
Segmentation results of different methods on CCF data set. (a) Original image. (b) SVM. (c) U-Net. (d) the proposed network.
(a)(b)(c)(d)Figure8 shows the segmentation result evaluation of different methods on CCF data set. The pixel segmentation accuracy and mean intersection over union of proposed method are higher than those of contrast method for all categories on CCF data set. Compared with SVM and U-Net methods, the mean pixel accuracy reaches 91%, which increases by 19%, 7%, and 2%, respectively. The mean intersection over union increases by 11%, 3%, and 1%, respectively, which reaches 76%. Therefore, the proposed method has good image segmentation performance and certain advantages.Figure 8
Segmentation result evaluation of different methods on CCF data set.


## 4.4.1. Model Verification

To verify the effectiveness of proposed method, the performance of model under different network configurations and adaptive thresholds is analyzed experimentally. Figure4 shows the changes of model evaluation indicators with the epoch when different optimization methods are adopted. Compared with SGD method, loss of Adam and Nadam method decreases faster and accuracy increases faster. The SGD method reaches saturation in 10 epochs, and the Adam and Nadam methods reach saturation in 30 epochs. The test loss of Nadam method is closest to the verification loss, and the test accuracy is closest to the verification accuracy, indicating that using the Nadam method as a model training and optimization method has certain advantages.Figure 4
Changes of evaluation indicators of different optimization methods with epoch. (a) SGD. (b) Adam. (c) Nadam.
(a)(b)(c)Under the condition that other parameter conditions remain fixed, adaptive threshold method is adopted to train all types of data sets, and the changes of accuracy of different landscape pixels with probability thresholds are obtained as shown in Figure5. As can be seen, the probability threshold of different categories is different. By comparing the best probability threshold of each classification, the best threshold of vegetation landscape classification can be obtained, and it is 0.6; the best threshold of road landscape classification is 0.4; the best threshold of building classification is 0.4; the best threshold of the water body classification is 0.6; and the best threshold of other classification is 0.3.Figure 5
Changes of different landscapes pixel accuracy with probability threshold.Taking roads as an example, the comparison of segmentation effects adding adaptive threshold and not adding adaptive threshold (0.5) is shown in Figure6. As can been seen, the segmentation effect achieved by adding adaptive threshold is better.Figure 6
Comparison of segmentation effects. (a) Image without adaptive threshold. (b) Image with adaptive threshold.
(a)(b)


## 4.4.2. Model Comparison

To verify the superiority of the proposed model, the segmentation results of different methods on CCF data set and BDS data set are compared. Figure7 compares the segmentation results of proposed method with traditional classification methods SVM, SegNet, and U-Net on CCF data sets and provides manual annotation results as a reference. The SVM classification method is prone to misclassify buildings and roads, and there are many noise points in the segmentation results. Compared with SVM classification methods, SegNet and U-Net segmentation methods reduce the misclassification and noise points, but there are still problems of misclassification and missing classification of buildings and roads. The proposed method can segment all categories well, and the segmentation effect of buildings and roads is better than that of the contrast method. The reason is that when the target is segmented, the proposed method can fuse multiscale cross features and expand the receptive field, thus the global feature during target segmentation is better extracted. On the whole, compared with the contrast method, the image segmentation result of proposed method is closer to manual annotation result, and the visual effect is the best.Figure 7
Segmentation results of different methods on CCF data set. (a) Original image. (b) SVM. (c) U-Net. (d) the proposed network.
(a)(b)(c)(d)Figure8 shows the segmentation result evaluation of different methods on CCF data set. The pixel segmentation accuracy and mean intersection over union of proposed method are higher than those of contrast method for all categories on CCF data set. Compared with SVM and U-Net methods, the mean pixel accuracy reaches 91%, which increases by 19%, 7%, and 2%, respectively. The mean intersection over union increases by 11%, 3%, and 1%, respectively, which reaches 76%. Therefore, the proposed method has good image segmentation performance and certain advantages.Figure 8
Segmentation result evaluation of different methods on CCF data set.


## 5. Conclusion

In conclusion, the proposed landscape greening space distribution model of community based on image recognition can achieve more accurate landscape space classification of community by using improved U-Net network to segment community landscape greening. Compared with the traditional SVM and SegNet methods, as well as the improved U-Net method, the proposed method has better classification effect, and the results are closer to the manual annotation results. On data set, the mean pixel accuracy of proposed method is 19%, 7% and 2% higher than that of SVM, SegNet and U-Net methods, respectively, reaching 91%. In addition, the mean intersection over union reaches 76%. In practical application, the proposed method can also obtain good segmentation results, where the mean pixel accuracy and the mean intersection over union reach 89% and 74%, which means that the proposed method has certain validity and practicability. However, there are still some deficiencies. The improvement method used by U-Net model is supervised learning, and images need to be annotated in the early stage. Although the classification accuracy is improved to a certain extent, the overall efficiency is reduced. Therefore, the next step is to try to improve the model by using unsupervised learning method while ensuring high precision segmentation effect. [23–25].



---

*Source: 4834952-2022-09-14.xml*