# Intelligent Design Model of Urban Landscape Space Based on Optimized BP Neural Network

Authors: Guoping Wu; Yihua Miao; Fang Wang
Journal: Journal of Sensors
 (2022)

---

## Abstract

Urban landscape space planning is an important application field of landscape ecology. With the continuous development of the field of architectural optimization, more and more optimization methods have sprung up, including various intelligent optimization algorithms. Such intelligent optimization algorithms usually rely on traditional building performance simulation methods to obtain building performance indicators for optimization in the optimization process. However, intelligent optimization algorithms generally require large-scale calculations. At the same time, the time required for building performance simulation is often limited by the complexity of the building model and the configuration of the computer, which leads to too long performance optimization time for designers in the project. With efficient and accurate feedback, building performance optimization methods based on intelligent optimization algorithms are mainly used in scientific research and are difficult to invest in actual projects. Because the traditional BP neural network has its own limitations and its insufficient sample size and weak generalization ability in complex prediction problems, this paper uses the learning algorithm of optimizing the BP neural network to propose an urban landscape space intelligent design model. This article introduces the artificial neural network, a new application technology with the assistance of a geographic information system, and establishes a BP neural network model for urban landscape ecological planning. Seven elements of distance and number of residential points are used as input variables, patch density, fractal dimension, the Shannon diversity index, and aggregation degree are selected as output changes, and 20 samples are carefully collected to train the network. The results show that the network convergence effect is ideal and the generalization ability is strong, which provides a new simulation analysis method for landscape ecological planning.


---

## Body

## 1. Introduction

Landscape ecological planning is a practical activity that uses the principles of landscape ecology to solve ecological problems at the landscape level. It embodies the application value of landscape ecology. It is particularly important to apply it to urban fringe areas with fragile ecology and complex landscape pattern changes. Landscape ecological planning can be understood as follows: based on regional, natural, social, economic, and other aspects of information, dynamic planning of the regional landscape pattern from a macro-, overall, and comprehensive perspective was developed, in order to optimize the structure, protect the ecological balance, and promote the sustainable development the goal of the region. The landscape pattern can be reflected by a set of landscape indices, so the landscape ecological planning process is essentially a nonlinear mapping process, that is, the nonlinear mapping relationship between various terrain factors and various interference effects (especially man-made effects) and a set of landscape indices. In recent years, the artificial neural network methods that have emerged at home and abroad can extract regular knowledge from the most primitive or statistical data, which is very suitable for quantitative landscape ecological planning. With the development of artificial neural network technology, researchers have designed a variety of neural network models, which describe and simulate the biological nervous system at different levels from different angles, and are used in various fields, of which 80%~90% of the artificial neural network models use BP network or its variation reflects the most elite part of the artificial neural network [1–9].From the application level, the time required for urban landscape performance optimization will directly determine the availability of optimization algorithms. Algorithm-based urban landscape performance optimization is mainly divided into two parts: urban landscape performance simulation and urban landscape performance optimization. The traditional urban landscape performance simulation process is usually completed by various simulation software such as EnergyPlus. The urban landscape performance optimization process is usually completed by intelligent algorithms such as a genetic algorithm through large-scale cluster search and other methods. Therefore, the calculation time of the entire urban landscape performance optimization process consists of two parts, which will directly determine the optimization efficiency. AgdasD. et al. believe that the computing time of the integrated feedback system EnergyPlus is several times that of other urban landscape energy consumption estimation methods, and the computing time of the energy consumption simulation algorithm is an important part of the overall computing time. Si B. et al. compared seven performances of three intelligent optimization algorithms, including optimization efficiency, and the results showed the optimization efficiency of the three algorithms. Although they are not all the same, there is no big difference, and the optimization efficiency is not high. Therefore, when designers use algorithms to optimize urban landscape performance, they often consider simplifying urban landscape models to save optimization time, especially thermal physical models. Therefore, it is a very important and urgent problem to take into account the complex urban landscape performance simulation and efficient urban landscape performance optimization. This is one of the reasons why this paper uses the optimized BP neural network algorithm to replace the dynamic simulation method of EnergyPlus [10–14].Because the BP (backpropagation) neural network has the characteristics of self-learning, self-adaptation, distributed storage, etc., it is widely used in nonlinear prediction. Some literature uses momentum gradient descent BP neural network algorithm to predict the settlement of deep foundation pits. However, the momentum gradient algorithm also has its own shortcomings, such as slow convergence and easy to fall into local minimums. Therefore, traditional BP algorithms also have certain limitations. Genetic algorithm (GA) has a strong global optimization capability, which is globally optimized through selection, crossover, and mutation operations. Therefore, the use of a genetic algorithm to optimize a BP neural network can effectively make up for the shortcomings of the traditional BP neural network [15–22].Since the relationship between building performance indicators and variables is mostly black box models (such as the EnergyPlus simulation software) rather than direct mathematical expressions, building performance optimization usually cannot use traditional optimization methods based on functional expressions and tends to choose smart algorithms. In view of the high robustness of intelligent algorithms to optimization problems, there is no lack of research on using intelligent algorithms to optimize building performance at home and abroad.Echenagucia et al. achieved the optimization of energy consumption including heating, cooling, and lighting based on the positional relationship of open spaces in the office building and the parameters of the transparent envelope structure in the initial stage of building design. The corresponding optimization suggestions are given in the form of the solution. Chen Tianchi uses Rhinoceros&Grasshopper as the platform, Octopus as the multiobjective optimization platform, and Ladybug+Honeybee as the simulation software platform. The multiobjective optimization is carried out with the sunlight index and natural ventilation index as the objective function, so as to integrate energy-saving optimization and other technologies into the early stage of building design. The final optimization results are presented with the Pareto boundary values. Chen Hang is based on the parameterized platform Rhinoceros&Grasshopper. The objective function selects the total energy consumption of the building throughout the year (optimization target is the smallest), daylight uniformity (optimization target is the largest), and glare occurrence probability (optimization target is the smallest), three optimization variables. It is the window parameter of the building’s transparent envelope structure; the standard model used for optimization is the standard model of the interior corridor slab space building in the office building in cold areas, and the extracted standard model is the final research object. Finally, a multiangle analysis is carried out on the optimized optimal solution set to provide a theoretical basis for the architectural window design in the early stage of architectural design. Ma Chong takes the exterior windows of office buildings in Guangzhou as the optimization object, takes low energy consumption and high comfort as the optimization goals, establishes a multiobjective optimization problem, and uses EnergyPlus and GenOpt to analyze and solve them in parallel. The author first compares the advantages and disadvantages of traditional algorithms and genetic algorithms, then determines the optimization decision variables as multiple shading forms, and sorts and screens them for their energy-saving potential; finally, the author chooses the total energy consumption of the room and the dissatisfaction PDD. In order to optimize the goal, multiobjective optimization is carried out, the optimization result is finally analyzed, and the most suitable sunshade form for office buildings in the Guangzhou area is given [23–28]. The combination of the artificial neural network and other traditional methods will promote the continuous development of artificial intelligence and information processing technology.Since this method contains many nonlinear elements (such as activation functions), its application scenarios have been greatly expanded, which can be summarized as the following three points: (1) regression problem: use BP neural network to establish the mapping relationship between the independent variable and the objective function; (2) classification problem: put the independent variable in a certain way; and (3) data compression: reduce data dimensions during data transmission or storage.


## 2. Optimize the BP Neural Network Model

In recent years, artificial neural networks are developing more deeply on the road of simulating human cognition. The artificial neural network is a new type of algorithm formed by simulating the biological organization of the human brain. In the initial stage of development, artificial neural networks were called perceptrons, and there was only one level. The unique nonlinear adaptive information processing capability of the artificial neural network overcomes the shortcomings of traditional artificial intelligence methods for intuition, such as pattern, speech recognition, and unstructured information processing, making it useful in neural expert systems, pattern recognition, intelligent control, combinatorial optimization, forecasting, and other fields that have been successfully applied. This perceptron model has many advantages, such as a simple model and low computational complexity. It can fit the internal relationship between the decision variable and the objective function by learning various training sets to solve the problem of the limited ability of explicit function fitting. However, since this model cannot fit nonlinear problems, its applicable scenarios are greatly restricted. Therefore, the artificial neural network based on the BP algorithm (BP neural network for short) came into being. This method introduces the backward propagation of errors into the learning process, so that the algorithm corrects the errors by itself to meet certain error requirements. Therefore, this paper uses the global search capabilities of genetic algorithms to optimize the BP neural network structure to obtain optimized initial weights and thresholds, so that the search space of the solution can be located near the global optimal solution, and then uses the BP neural network algorithm to find the global optimal solution, so that it finally converges to the global optimal solution.The BP algorithm is used in a multilayer feedforward network with a nonlinear transfer function, and it can theoretically approximate any nonlinear mapping relationship. This extraordinary advantage makes the multilayer feedforward network more and more widely used. The basic principle of the traditional BP algorithm is to use the gradient descent method to make the change of the connection weight and bias always move in the direction of error reduction and finally achieve the minimum error. The BP algorithm has the characteristics of simple structure, a small amount of calculation, strong parallelism, and high robustness. It is currently one of the most mature training algorithms used in neural network training. However, it also has many inherent flaws:(1)
Local convergence: from the principle point of view, the optimization purpose of the BP neural network is to find the minimum value of the error loss function. Due to the complex structure of the multilayer BP neural network, the optimal solution of its loss function is actually a nonlinear model optimization process. First of all, each update of the connection weight and bias of the neural network is updated by the gradient descent direction of some samples, which will make the algorithm very easy to fall into the local optimum. Furthermore, since the initial parameters (including connection weights and bias) of the neural network are initialized randomly each time, and the neural network can fit a multidimensional complex nonlinear model, the optimal value of each local convergence will have a certain difference(2)
Sample forgetting and slow convergence: because the traditional BP algorithm uses a sample-by-sample training algorithm, when the number of samples is large, the overall error of the neural network will be biased toward the gradient and error of the samples that are sorted later, which makes the neural network produce forgetting before. The trend of the sample will also cause the convergence speed to slow down or even fail to converge, which greatly limits the application of neural networks to multivariate complex problemsThe activation function in the neural network is one of the key factors that determine the performance of the neural network, and it is an important part of the nonlinear transformation of the neural network model. Since the mathematical models of many engineering problems are nonlinear, and linear models have many defects, it is extremely important to introduce activation functions (especially nonlinear activation functions). There are many types of activation functions in traditional BP neural networks, and the more widely used Sigmoid function (Figure1) expression is:
(1)fx=11+e−x.Figure 1
Different functions.It can be seen from the function expression that this function is a nonlinear function with a value range of (0, 1). With the increase of the independent variablex, the derivative of the function first increases and then decreases. Only when the value of x is near 0, the derivative value is the largest. Due to its nonlinearity and global derivability, the Sigmoid function is extended in the traditional BP neural network. However, as the application of the BP neural network has become more extensive, the actual problems have become more complicated, and the model complexity of the BP neural network has become higher and higher. This exposes the defects of the Sigmoid function, mainly for the following two points: (1) the problem of gradient disappearance: it can be seen from the function expression that when the input value is too small, the gradient almost approaches 0. This will make the update gradient too small and cause training stagnation and gradient disappearance. (2) Although the function is centrally symmetrical, the symmetrical point is not the origin, which will make the input variables of the hidden layer not centrally symmetrical at the origin, which will affect the gradient descent method.In response to these problems, in the development process of the activation function, many improved functions were used to replace the Sigmoid function, including thetanh function. The expression of this function (Figure 1) is
(2)fx=1−e−2x1+e−2x.However, when the value ofx is too large or too small, there will still be the problem of gradient disappearance, which essentially does not solve the defects left by the Sigmoid function.The emergence of the ReLU function has accelerated the final breakthrough in the direct supervision of deep network training. Its use effect in the network is significantly better than the previous Sigmoid andtanh functions, and it is the most widely used activation function. The ReLU activation function has the following advantages: it solves the problem of gradient disappearance and improves the training speed of the network. Its function expression is
(3)ReLUx=x,x>00,x≤0.The function image is shown in Figure1. The ReLU function can effectively solve the problem of gradient disappearance, and because the function is simple in operation and will not activate all neurons at the same time, the application effect of the ReLU function in the BP neural network is better than other functions.BP neural network includes two processes of signal forward propagation and error backpropagation and consists of an input layer, a hidden layer, and an output layer. When the actual output and expected output of the signal passing forward exceed the set threshold, it will enter the backpropagation phase. Due to the characteristic of gradient descent of the error function, the connection weight of the hidden layer can be continuously adjusted to optimize the learning network structure. BP neural network is suitable for nonlinear prediction due to its self-learning and self-adaptive characteristics, and it is widely used in the field of data prediction.Due to the large numerical difference between each input index and output index, the original data needs to be standardized before entering the system. The standardized expression is(4)xij′=xij−x¯jSj,Sj=1mi=1∑i=1mxij′−xj2,x¯j=1m∑i=1mxij,where x is the index and S is the standard deviation.Genetic algorithm is inspired by natural selection and genetic theories. It finds the global optimal solution through three genetic operators of selection, crossover, and mutation and has strong global optimization capabilities. It mainly includes the processes of genetic coding, fitness function design, selection, crossover, and mutation.(1)
Genetic coding: convert the solution space of the problem to a search space that can be processed by the genetic algorithm. It mainly includes real number encoding and binary encoding. This article encodes based on the characteristic of real number encoding that it is not easy to fall into the local extremum(2)
Fitness function design: the fitness function is the basis for selecting outstanding individuals based on the objective function and should be nonnegative and as simple as possible. This article uses the reciprocal of the sum of squares of errors, as shown in the following formula(5)f=1∑i=1NYi−Ti2,where N is the total number of input samples, Yi is the actual output of the i-th sample, and Ti is the expected output of the i-th sample
(3)
Selection operation: according to the “survival of the fittest” mechanism, individuals with greater fitness are selected to form a new population. The greater the fitness value of the individual, the greater the probability of being selected into the new population. The selection operation mainly includes the roulette method and tournament method. This article chooses the roulette method. Thus, it becomes(6)pk=Fk∑i=1NFi,where Fk is the fitness value of the individual
(4)
Crossover operation: the chromosomes of two individuals in the population are crossed and exchanged, and the excellent characteristics are inherited to the new individual. Since this article is a real number encoding method, it becomes(7)akj=akj1−b+aljb,alj=alj1−b+akjb,where b is a random number between 0 and 1
(5)
Mutation operation: its codes string to other alleles to produce excellent individuals. The individual gene mutation operation is shown in the following formula:(8)aij=aij+aij−amax×fg,r>0.5aij+amin−aij×fg,r≤0.5.In the formula:amax and amin are the upper and lower bounds of gene aij, respectively.
(9)fg=r21−gGmax2,where r2 is a random number, g is the current iteration number, Gmax is the maximum evolution number, and r is a random number between 0 and 1. BP neural network has strong local searchability and is very effective in data fitting, but it is very sensitive to the initial weight and threshold of the network. The slow convergence speed and the defects of easy to fall into the local minimum will lead to poor prediction results. However, genetic algorithms have strong global search capabilities due to their selection, crossover, and mutation operations. Combining the advantages of genetic algorithm and BP neural network, a high-precision prediction model is constructed, as shown in Figure 2.Figure 2
GA-BP neural network model prediction flow chart.


## 3. Design Model Analysis

Combining with fuzzy systems, genetic algorithms, and evolutionary mechanisms to form computational intelligence, it has become an important direction of artificial intelligence and will be developed in practical applications. The hidden layer neuron combination method and the learning rate are combined for training, and the mean square error of the training set and the mean square error of the test set obtained by each combination of learning rate training are averaged to obtain the mean square error of the training set (MSE) average value and test set mean square error (MSE) average value, as shown in Table1. Figure 3 shows the training set MSE average value, the test set MSE average value, and the trend of training times at convergence with the learning rate picture. It can be found that the average mean square error of the training set first rapidly decreases with the increase of the learning rate and then slowly increases; while the test set is slightly different, the average mean square error of the training set first decreases rapidly with the increase of the learning rate and then increases rapidly; training Algebra increases first and then decreases as the learning rate increases. Among them, when the learning rate is 0.001, the training algebra is the least, the convergence speed is the fastest, but the mean square error average of the training set, and the test set is the largest, that is, the model falls into the local optimum. When the learning rate is 0.007, the average mean square error of the training set and the mean square error of the test set both reach the lowest value. When the learning rate increases to 0.013, the average values are higher, the number of training is less, and the situation of nonconvergence or local optimality begins to appear. In order to ensure that the model fully converges while preventing the occurrence of overfitting, this model chooses 0.007 as the optimal learning rate.Table 1
Neural network performance indicators vs. different learning rates.
Learning rate0.0010.0030.0050.0070.0090.0110.013Train MSE0.36460.12980.092510.082150.18060.19250.1845Test MSE0.76230.41770.18760.13960.58940.69630.5397Number of iterations605589440112902512675512685093139101829Figure 3
The trend of neural network performance indicators changing with learning rate.Based on the optimal learning rate of 0.007, the first set of training is performed on the hidden layer combination, each combination is calculated five times, and the mean square error of the training set and the mean square error of the test set are calculated. The results are shown in Table1. In order to observe the impact of these 64 combinations on the performance of the neural network more intuitively, the data in the table will be presented in the three-dimensional scatter plots (Figure 3). As shown in this figure, the blue cross is the mean square error of the training set, and the orange circle is the mean square error of the test set. Among them, the size of the cross and the circle represents the relative size of the mean square error, and the larger the shape, the larger the value. It can be seen that when the number of neurons in hidden layer 1 and hidden layer 2 is both at a small level, the average mean square error of the training set and the average mean square error of the test set are both at a higher level. The data set has almost no fitting and generalization capabilities. As the number increases, the mean square error of the training set and the mean square error of the test set rapidly decrease, and the fitting effect begins to increase. Figure 3 is a partial three-dimensional scatter plot after filtering out part of the excessively high mean square error, in order to more clearly observe the mean square error at the optimal solution. The mean square error of the training set and the mean square error of the test set also decrease until the maximum number of neurons is reached. A [45,45] combination scheme was used.Therefore, based on the combination scheme of [45,45], a second set of hidden layer combination schemes is set for training. The combination scheme and training results are shown in Figure4. Each group of schemes is calculated five times, and the average square error of the training set and the average square error of the test set are averaged. The average square error of the training set and the average square error of the test set are calculated. The data in the table is the same. It is presented in a three-dimensional scatter chart, as shown in Figure 4.Figure 4
3D data.From Figure4, it can be found that as the number of hidden layer 1 and hidden layer 2 neurons increases, the average mean square error of the training set generally shows a trend of decreasing, while the average mean square error of the test set tends to decrease first and then increase. Obviously, at a certain combination of neurons, the neural network has reached the maximum generalization ability. Before that, the neural network fitting ability and generalization ability continued to increase. After that, the neural network fitting ability continued to increase, but the generalization ability began to decrease, and the model began to appear overfitting.Combining Figure5, it can be found that when the structure of the hidden layer is [54,54], the average mean square error of the training set of the neural network is the lowest among all neuron combination schemes, which is 0.001461, but the corresponding the average mean square error of the test set is as high as 0.008668. This shows that the BP neural network under this combination has a strong fitting ability, but with low generalization ability, serious overfitting phenomenon, and poor predictive ability for the objective function of the unknown scheme. When the structure of the hidden layer is [45,43], the average mean square error of the training set is 0.003414, and the fitting ability ranks 9th among all combinations, but the average mean square error of the test set is 0.003809, and the generalization ability is the most strong, that is, the model has good generalization ability while fully converging and belongs to the most superior model in all groups.Figure 5
Mean square error.For the final selected BP neural network model, the group with the strongest generalization ability among the five training results is selected as the optimal model, and its accuracy and stability are analyzed in detail. Figure6 is the distribution diagram of the true value (or actual value) obtained by simulation in the training set. The abscissa is the number of sample sequences. Figure 6 is a comparison diagram of the true value obtained by the simulation in the test set and the predicted value of the optimal neural network model. The abscissa is the number of sample sequences, a total of 997 groups, and the ordinate is also -0.4-0.4. The average daily cooling energy consumption in summer during the four days can be seen qualitatively from Figure 6 in which the predicted value of the average daily cooling energy consumption in summer is in good agreement with the true value, and the prediction model has a strong ability to fit and generalize.Figure 6
Comparison of test and prediction.In fact, the convergence process of the solution set in the evolutionary algorithm consists of two parts: one is the closeness between the Pareto optimal solution set and the full solution set, and the other is the closeness between the Pareto optimal solution set and the real Pareto optimal solution set. It can reflect the convergence process from the local optimal solution to the global optimal solution. But the Pareto frontier in actual engineering is often unpredictable (this is the core problem that the optimization method needs to solve), so the second part of the convergence process often cannot give a quantitative or qualitative judgment. Therefore, this section mainly focuses on the analysis of the convergence process mentioned in the first part and analyzes the convergence process with the changing trend of the maximum and minimum values of the two solutions.As shown in Figure7. The Pareto optimal solution and the minimum value of the full solution set in the two objective function dimensions have little change. This is mainly because the optimization objective of this paper is the minimum value of the function. The maximum changes in the two dimensions are more obvious, and the maximum value of the Pareto optimal solution is often smaller than the full solution set. As the evolution progresses, the maximum values of the two gradually approach and eventually tend to coincide. This is mainly because, first, the proportion of the Pareto optimal solution set in the full solution set has increased and the distance between the second optimal solution and the dominant solution is getting closer. It can also be seen in the figure that the maximum values of energy consumption and thermal comfort both increase with the growth of evolutionary algebra and eventually stabilize, while the minimum values remain basically unchanged. This shows that the two objective functions seek to find the minimum value of the understanding set and remain stable in the early stage of evolution, while the maximum value develops toward the direction of increasing the universality of the solution set. It should be noted that the maximum value of APMV’s total solution set and the Pareto solution set has a slight upward trend in the 55th generation, which means that the solution set is still evolving in the direction of increasing generality, rather than not converging. The MSE variation is shown in Figure 8.Figure 7
Convergence.Figure 8
MSE variation.It can also be known from the figure that the fluctuation range of the maximum value is relatively large; especially, the energy consumption is more obvious. There may be two reasons for this phenomenon. One is that most of the decision variables in this case are discrete variables, and the other is that the previous multigeneration solutions hover in multiple local optimal points, and finally, they are near the stable place due to variation. This phenomenon can be explained by the outliers in the box chart. This is very normal, and it is also the meaning of the mutation rate setting in the algorithm.


## 4. Conclusion

The research in this article still has some shortcomings. As far as the scope of application is concerned, although the two algorithms used in this article are theoretically suitable for most building performance prediction and optimization problems, the building performance prediction and optimization platform built in this article are only suitable for spatial parameter optimization of small- and medium-sized urban landscapes in cold regions. On the one hand, the spatial generation method in this paper is derived from the architectural features of small- and medium-sized urban landscapes; on the other hand, the data set used for algorithm model training in this paper is also derived from the performance simulation results of small- and medium-sized urban landscapes in cold areas. In terms of algorithm theory, with the continuous development of deep learning and intelligent algorithms, many new algorithms continue to emerge, and it is very likely that there will be algorithms with better performance than the algorithms in this article in the future. Therefore, how to build a building performance prediction and optimization platform with wider applicability and better algorithm performance requires further research.



---

*Source: 9704287-2022-03-25.xml*