# Highway Traffic Flow Prediction Algorithm Based on Multiscale Transformation and Convolutional Networks

Authors: Yuzhu Luo; Jiarong Wang; Ming Wei
Journal: Journal of Control Science and Engineering
 (2022)

---

## Abstract

In order to solve the problem that the traditional long-term high-speed traffic forecasting algorithm is affected by the approximation ability of the function and easy to fall into the local mass value, we wrote a multivariate-based highway traffic forecasting algorithm scaling and convolutional networks. Because the feedforward wavelet neural network algorithm predicts the short-term traffic flow in different areas, it is necessary to examine the ability to predict the difference between different models. From the standard feedforward wavelet neural network algorithm using global optimization capabilities, we improve the wolf pack algorithm, improve the search accuracy of the algorithm, get the best solution of the estimated value of the work according to the search results when completing the research objectives, and get the ability to predict the work of the model. Feedforward neural network algorithm: we develop and obtain the best short-term high-speed traffic forecast values. The results are as follows: after using the author’s algorithm, the processing time increases by 1.5 seconds, but the average percentage of errors decreases by more than 50%, in fact the error and the root mean square error decreased by about 30%, and the smoothing coefficient increased by about 1%. The prediction of the author’s algorithm for short-term high-speed traffic is better than the wavelet neural network prediction algorithm, and the prediction accuracy and stability of the author’s algorithm are higher.


---

## Body

## 1. Introduction

With the rapid development of society, emerging concepts such as smart cities are gradually integrated into people’s lives [1, 2]. Intelligent transportation system (ITS) is an important part of a smart city [3–5]. Among them, traffic flow prediction is the key to ITS research. Road traffic data showed a similar trend at the same time on consecutive days. Accurate traffic flow prediction is of profound significance for ensuring public safety and solving traffic congestion.Due to the rapid increase in travel demand, severe traffic congestion, and its adverse impact on traffic safety and environmental conditions, it has attracted great attention from countries around the world [6]. Due to limited land resources and high construction costs, highway expansion projects cannot effectively solve this problem. In addition, potential traffic demand is also generated due to the increase in traffic vehicle capacity [7, 8]. In this context, the effective use of existing road facilities and transportation network resources, improving service levels, has become an important measure for transportation agencies to formulate management strategies [9, 10]. In recent years, the computing power of computers has been significantly improved, and many artificial intelligence models have been widely used in traffic flow prediction problems and achieved certain results. Among them, artificial neural networks are the most popular of these traffic flow prediction models. Unlike traditional statistics-based models, artificial neural networks can effectively analyze the nonlinear correlation between historical data and future data of traffic flow data. Therefore, it can establish a more accurate and excellent traffic flow prediction model [11].With the development of the economy, the problem of traffic in modern life has become an important problem affecting the development of society, and motor vehicle traffic has increased, which creates serious problems such as traffic accidents, traffic accidents, and the environment. Pollution utility [12]: the prediction results are important for the real-time detection of traffic flow, as the short-term prediction of traffic flow is performed [13]. The highway is a time-varying system with different components that show irregularity and uncertainty [8]. In the past, the feedforward wavelet neural network forecasting algorithms are mainly used to predict short-term high-speed traffic, but this algorithm is sensitive to the initial values of the weight and wavelet factors and easy access. Some negative results have negative predictive values. For this, some researchers have proposed some solutions. Figure 1 shows the process and method of traffic prediction based on the circuit diagram of the network.Figure 1
Prediction method and process of road traffic flow based on graph convolutional network.


## 2. Literature Review

Debbarma and Choudhury’s short-term traffic prediction model combined with AF-SVR is proposed. The experimental results demonstrate the unique ability of parallel detection and support vector regression technology of the fish swarm algorithm combined with the AF-SVR method by simulating the data flow of the short term of the forecasting model. This method has high accuracy [14]. Zkoak et al. applied a kernel correlation vector combination machine for local estimation of short-term running time. First, the construction of the phase location is done by calculating the time delay of the connection time of the C-C road, determining the number of adjacent points according to Hannan-Quinn’s formula, and as a combination. Model of the kernel correlation vector machine developed a particle-by-particle optimization and overall estimation of short-term local traffic [15]. Forster-Heinzer et al. proposed a model for the development of short-distance transportation routes based on the spatiotemporal characteristics of traffic data. First, according to the BP neural network prediction model, time series, time similarity, and spatial series of traffic volumes are determined, and together with the estimation value of spatiotemporal characteristics of adaptive weighted data integration, traffic volumes are estimated [16]. In order to improve the accuracy of short-term traffic flow forecasting, Fu et al. presented a combined forecasting model based on nonparametric regression and support vector regression to provide accurate and reliable traffic information for traffic control centers and pedestrians. The K-nearest neighbor method using an ISM search engine is used to construct historical traffic flow time similar to current traffic flow, and support vector regression is used to estimate the short term [17]. Based on the real traffic data, the influence of the water flow and the flow of water on the planned road were determined and the prediction accuracy of the KNN-SVR model was analyzed. Meng and Zhang proposed a prediction method based on the multivariate GBDT model [18]. The traffic of the stations is collected at different times, the weather and seasonal changes are fully calculated, the analysis of the time of the collected data, and the new technology simulation technology learning algorithm is used to predict the traffic, and developed a short prediction method for GBDT models with multiple features. Ma et al. proposed short-term forecasting based on multiple autoregressive models [19]. The models discussed include autoregressive pooled moving average models (ARIMA and VARMA), error correction models (VECM and EC-VAR-MA), spatiotemporal ARMA (STARMA), and multiple autoregressive spatial state models (MASS). This model is based on various assumptions about the relationship between traffic data (temporal, spatial, or different traffic characteristics). The basic concepts of the model, such as traffic stability, freedom of information, and their importance in traffic are discussed. In addition, an empirical application of traffic estimation for small segments is added. But the above method has the problem of high definition uncertainty and root mean square error.To solve the above problem, a short-term high-speed traffic algorithm based on the wolf pack algorithm is proposed, and the global optimization ability of the wolf pack algorithm is used to determine the weight and wave quality. Structural feed-forward wavelet neural networks are for stable and accurate prediction of short-term high-speed traffic.


## 3. Methods

### 3.1. Prediction of Short-Term High-Speed Traffic Flow

#### 3.1.1. Analysis of Function Approximation Capability of Feedforward Wavelet Neural Network Algorithm

The combination of wavelet analysis with neural networks is the main feature of the feedforward neural network algorithm, which creates a network based on wavelet analysis and affects multiple transmission models, which prevents the network from local optimization and improved integration [20]. Algorithms, generalization, and learning for short-term high-speed traffic are strong. The nonlinear sigmoid function of the wavelet neural network is replaced by a nonlinear wavelet basis, and the signal is interpreted as a linear superimposed wavelet basis. The average number of neural networks and the number of interpolated samples in the feedforward wavelet neural network algorithm is n + 1; at the same time, the inner and outer weights of the feedforward wavelet neural network can be constructed according to the values of the interpolation samples, and the arbitrary uninterrupted functions in the closed interval can be approximated together based on arbitrary precision. Convergence conditions are more important for the approximation problem of multidimensional extended wavelet neural networks to unary functions; therefore, the requirements for it are relatively high, which leads to an increase in the difficulty of operation and decreases the stability of the radial basis neural network connection weights.fx describes the uninterrupted function in the interval a,bk, and Wax,An describes the wavelet radial basis neural network constructed by randomly selecting ξ>0, the neural network contains a function described by An and a natural number described by N, and the function approximation value of the feedforward wavelet neural network algorithm is fx−Wax,An A, under the condition of N<n, and all x∈a,bk include(1)fx−Wax,An<ξ.The wavelet neural networkWax,An and the positive real numbers An satisfying the size condition exist in the process of uniform grid division in the a,bk interval and in the data xifi∈Rk+1,i=0,1,…,n; under the conditions of An>An, there is(2)Wexi,An=fi=fxi.ForXex,An, a wavelet neural network Wax,An can be constructed, with a positive real number A′n satisfying the size; under the condition of An>A′n, there is(3)Wexi,An−Wax,An<ξ3.Again,(4)fx−Wax,An=fx−fxi+Wexi,An−Wax,An=fx−fxi+Wexi,An−Wex,An+Wex,An−Wax,An≤fx−fxi+Wexi,An−Wex,An+Wex,An−Wax,An.Sincefx is uninterrupted in the interval a,bk, therefore, for the above ξ>0, ∃δ>0, under the condition of x−xi<kxi−xi+1=kn1/2kb−a<δ, that is, under the condition of n>kb−a/δ2k=N1, there is(5)fx−fxi<ξ3.Sinceψx⊂L2R is an uninterrupted wavelet function,(6)Wex,An=∑j=0ndjφ0φAx−xj.From the above process, it is obtained that the intervalfxa,bk is consistent and uninterrupted. For ξ>0 and ∃δ1>0 above, under the condition of x−xi<kxi−xi+1=kn1/2kb−a<δ, that is, under the condition of n>kb−a/δ12k=N2, there is(7)Wexi,An−Wex,An<ξ3.Therefore, under the condition ofn>N=maxN1,N2, when n corresponds to the corresponding An, the function approximation value of the feedforward wavelet neural network algorithm is(8)fx−Wax,An=fx−fxi+Wexi,An−Wax,An=fx−fxi+Wexi,An−Wex,An+Wex,An−Wax,An≤fx−fxi+Wexi,An−Wex,An+Wex,An−Wax,An≤ξ3+ξ3+ξ3=ξ.From this, it can be seen that, when constructing the feedforward wavelet neural network algorithm, there is no need to use training methods, for short-term high-speed traffic flow prediction in multidimensional space, the random correlation of multidimensional samples can be approximated with a given accuracy, obtaining the best traffic flow prediction results [21].


#### 3.1.2. Improved Wolf Pack Algorithm

The process of detecting wolves in the wolf pack algorithm can be considered as the process of approximating the performance of the feedforward neural network algorithm in the traditional wolf pack algorithm, but in the process of catching wolves to find different animals, the number of directions Y is different, and the value is randomly selected according to the actual situation when taking the value, and the value range is represented byymin,ymax [22]. However, the number of directions that wolves look for is not affected by changes in the number of walks or the number of algorithm iterations. At the same time, during the experiment, the wolf detection direction is usually fixed at 10, rather than random, as described above. As a result, the search direction of the wolf detection in the wolf pack algorithm remains unchanged, and the error of the search result is large. The detailed description is as follows: if the number of directions y for the wolf to search for prey is 8, then the optimal direction is determined after one move.In the process of searching for the secondary movement, each direction forms a parallel relationship with the optimal direction, and in the subsequent search process, the search is carried out in this parallel direction, which seriously affects the search efficiency. In order to solve this problem, the walking direction of the wolf detection algorithm is improved, and W is used to represent the number of wolf detection. According to the parity of W, the search direction is selected betweeny,y+1 to enhance the accuracy of the search result. After the algorithm is improved, there is no parallel relationship between the directions of the W-th walk and the W + 1-th walk. It can be seen from this that the improved way of arbitrarily selecting the search direction of wolf detection in a given range can expand the search range.The improved wolf pack algorithm is described as follows:(1)
Value initialization:Xi, N, and Kmax are used to describe the wolf position, the number of wolves, and the maximum number of iterations in the wolf pack, respectively, and α, Wmax, ω, and β are used to describe the wolf detection scale factor, the maximum number of walks, the distance judgment factor, and the update scale factor, respectively, to initialize the above parameters [23].(2)
Xlead and Zlead are used to describe the position of the head wolf and the value of the objective function, which is the optimal objective function value. We use S−num to represent the number of wolves with the optimal objective function value, except for the first wolf, and when the number of walks is an odd number, the walk is performed according to the following formula:(9)xidp=xid+sin2π×py×step=xid+sin2π×py×rand⋅normxi,:−Xlead.When the number of walks is an even number, the walk is performed according to the following formula:(10)xidp=xid+sin2π×py+1×step=xid+sin2π×py+1×rand⋅normxi,:−Xlead.When the number of walks of each wolf detection meets the maximum number of walksWmax, we proceed to process (3).(3)
In the wolf pack, we randomly selectM_num wolves, except the alpha wolf, to search for prey according to the following formula:(11)xid=xid+step×xleadd−xidxleadd−xid=xid+rand×xi−xlead2×xleadd−xidxleadd−xid,d=1,2,…,D.During the search process, when the objective function value of a certain wolf isZi>Zlead, Zlead=Zi, the wolf replaces the alpha wolf to summon; under the condition of Zi<Zlead, the distance between the hunting behavior and the position of the same wolf is lower than dnear, and process (4) is performed.(4)
After updating the position of the selected wolf using the following formula, we continue to maintain the search behavior(12)xid=xidk+λ×step×Gd−xid=xid+λ×rand×xi−G2×Gd−xid,d=1,2,…,D.(5)
The positions of the alpha wolf and the wolf group are updated with the “winner is king” and “the strong survive” as the selection criteria of the alpha wolf and the wolf group update mechanism, respectively [24].(6)
determine whether the updated result satisfies the optimization accuracy or the maximum number of iterations and output the position of the head wolf under the satisfied conditions; this position is the optimal solution of the function approximation value of the feedforward wavelet neural network algorithm; on the contrary, if the condition is not satisfied, return to process (2).The improved wolf pack algorithm can improve the function approximation ability of the wavelet neural network algorithm, greatly improve the traffic flow forecasting performance, and obtain the best traffic flow forecasting results.


### 3.2. Simulation Test

In order to test the feasibility and effectiveness of the short-term high-speed traffic flow prediction algorithm based on the wolf pack algorithm, the measured data of a highway toll station in my country in 2017 were used as the experimental data, and the simulation was carried out in the MATLAB 2012a environment and the measured data in April, June, and September. November in 2017 was used as 4 data sets, with a total of 1418 groups of data; the relevant parameters are set as follows: according to the normal distribution, the weights and scaling factors of the wavelet neural network are randomly assigned, divided into the 1418 sets of data into training samples and test samples, 947 and 471, respectively, and we set the maximum training times and momentum factor to be 90 and 0.3, respectively; the minimum error value, weight learning rate, translation factor learning rate, and scaling factor learning rate are 0.0001, 0.01, 0.001, and 0.001, respectively.MAPE: mean percentage error, which can intuitively represent the strength and weakness of forecasting effects; MAE: mean error, small value, small error; RMSE: the root mean square error, the smaller the value, the smaller the error; EC: equal coefficient, the higher the value, the higher the ratio; RT: running time, reflecting the complexity of the algorithm. The calculation formula for the above indicators is as follows:(13)MAPE=1V∑tCpt−CrtCrt×100%,(14)MAE=1V∑tCpt−Crt,(15)RMSE=∑tCpt−Crt2V,(16)EC=1−∑tCpt−Crt2∑tCpt2+∑tCrt2.In the above formula,Cpt, Crt, and V are the predicted output value, the measured value of high-speed traffic flow at time t, and the number of predicted samples, respectively.


## 3.1. Prediction of Short-Term High-Speed Traffic Flow

### 3.1.1. Analysis of Function Approximation Capability of Feedforward Wavelet Neural Network Algorithm

The combination of wavelet analysis with neural networks is the main feature of the feedforward neural network algorithm, which creates a network based on wavelet analysis and affects multiple transmission models, which prevents the network from local optimization and improved integration [20]. Algorithms, generalization, and learning for short-term high-speed traffic are strong. The nonlinear sigmoid function of the wavelet neural network is replaced by a nonlinear wavelet basis, and the signal is interpreted as a linear superimposed wavelet basis. The average number of neural networks and the number of interpolated samples in the feedforward wavelet neural network algorithm is n + 1; at the same time, the inner and outer weights of the feedforward wavelet neural network can be constructed according to the values of the interpolation samples, and the arbitrary uninterrupted functions in the closed interval can be approximated together based on arbitrary precision. Convergence conditions are more important for the approximation problem of multidimensional extended wavelet neural networks to unary functions; therefore, the requirements for it are relatively high, which leads to an increase in the difficulty of operation and decreases the stability of the radial basis neural network connection weights.fx describes the uninterrupted function in the interval a,bk, and Wax,An describes the wavelet radial basis neural network constructed by randomly selecting ξ>0, the neural network contains a function described by An and a natural number described by N, and the function approximation value of the feedforward wavelet neural network algorithm is fx−Wax,An A, under the condition of N<n, and all x∈a,bk include(1)fx−Wax,An<ξ.The wavelet neural networkWax,An and the positive real numbers An satisfying the size condition exist in the process of uniform grid division in the a,bk interval and in the data xifi∈Rk+1,i=0,1,…,n; under the conditions of An>An, there is(2)Wexi,An=fi=fxi.ForXex,An, a wavelet neural network Wax,An can be constructed, with a positive real number A′n satisfying the size; under the condition of An>A′n, there is(3)Wexi,An−Wax,An<ξ3.Again,(4)fx−Wax,An=fx−fxi+Wexi,An−Wax,An=fx−fxi+Wexi,An−Wex,An+Wex,An−Wax,An≤fx−fxi+Wexi,An−Wex,An+Wex,An−Wax,An.Sincefx is uninterrupted in the interval a,bk, therefore, for the above ξ>0, ∃δ>0, under the condition of x−xi<kxi−xi+1=kn1/2kb−a<δ, that is, under the condition of n>kb−a/δ2k=N1, there is(5)fx−fxi<ξ3.Sinceψx⊂L2R is an uninterrupted wavelet function,(6)Wex,An=∑j=0ndjφ0φAx−xj.From the above process, it is obtained that the intervalfxa,bk is consistent and uninterrupted. For ξ>0 and ∃δ1>0 above, under the condition of x−xi<kxi−xi+1=kn1/2kb−a<δ, that is, under the condition of n>kb−a/δ12k=N2, there is(7)Wexi,An−Wex,An<ξ3.Therefore, under the condition ofn>N=maxN1,N2, when n corresponds to the corresponding An, the function approximation value of the feedforward wavelet neural network algorithm is(8)fx−Wax,An=fx−fxi+Wexi,An−Wax,An=fx−fxi+Wexi,An−Wex,An+Wex,An−Wax,An≤fx−fxi+Wexi,An−Wex,An+Wex,An−Wax,An≤ξ3+ξ3+ξ3=ξ.From this, it can be seen that, when constructing the feedforward wavelet neural network algorithm, there is no need to use training methods, for short-term high-speed traffic flow prediction in multidimensional space, the random correlation of multidimensional samples can be approximated with a given accuracy, obtaining the best traffic flow prediction results [21].


### 3.1.2. Improved Wolf Pack Algorithm

The process of detecting wolves in the wolf pack algorithm can be considered as the process of approximating the performance of the feedforward neural network algorithm in the traditional wolf pack algorithm, but in the process of catching wolves to find different animals, the number of directions Y is different, and the value is randomly selected according to the actual situation when taking the value, and the value range is represented byymin,ymax [22]. However, the number of directions that wolves look for is not affected by changes in the number of walks or the number of algorithm iterations. At the same time, during the experiment, the wolf detection direction is usually fixed at 10, rather than random, as described above. As a result, the search direction of the wolf detection in the wolf pack algorithm remains unchanged, and the error of the search result is large. The detailed description is as follows: if the number of directions y for the wolf to search for prey is 8, then the optimal direction is determined after one move.In the process of searching for the secondary movement, each direction forms a parallel relationship with the optimal direction, and in the subsequent search process, the search is carried out in this parallel direction, which seriously affects the search efficiency. In order to solve this problem, the walking direction of the wolf detection algorithm is improved, and W is used to represent the number of wolf detection. According to the parity of W, the search direction is selected betweeny,y+1 to enhance the accuracy of the search result. After the algorithm is improved, there is no parallel relationship between the directions of the W-th walk and the W + 1-th walk. It can be seen from this that the improved way of arbitrarily selecting the search direction of wolf detection in a given range can expand the search range.The improved wolf pack algorithm is described as follows:(1)
Value initialization:Xi, N, and Kmax are used to describe the wolf position, the number of wolves, and the maximum number of iterations in the wolf pack, respectively, and α, Wmax, ω, and β are used to describe the wolf detection scale factor, the maximum number of walks, the distance judgment factor, and the update scale factor, respectively, to initialize the above parameters [23].(2)
Xlead and Zlead are used to describe the position of the head wolf and the value of the objective function, which is the optimal objective function value. We use S−num to represent the number of wolves with the optimal objective function value, except for the first wolf, and when the number of walks is an odd number, the walk is performed according to the following formula:(9)xidp=xid+sin2π×py×step=xid+sin2π×py×rand⋅normxi,:−Xlead.When the number of walks is an even number, the walk is performed according to the following formula:(10)xidp=xid+sin2π×py+1×step=xid+sin2π×py+1×rand⋅normxi,:−Xlead.When the number of walks of each wolf detection meets the maximum number of walksWmax, we proceed to process (3).(3)
In the wolf pack, we randomly selectM_num wolves, except the alpha wolf, to search for prey according to the following formula:(11)xid=xid+step×xleadd−xidxleadd−xid=xid+rand×xi−xlead2×xleadd−xidxleadd−xid,d=1,2,…,D.During the search process, when the objective function value of a certain wolf isZi>Zlead, Zlead=Zi, the wolf replaces the alpha wolf to summon; under the condition of Zi<Zlead, the distance between the hunting behavior and the position of the same wolf is lower than dnear, and process (4) is performed.(4)
After updating the position of the selected wolf using the following formula, we continue to maintain the search behavior(12)xid=xidk+λ×step×Gd−xid=xid+λ×rand×xi−G2×Gd−xid,d=1,2,…,D.(5)
The positions of the alpha wolf and the wolf group are updated with the “winner is king” and “the strong survive” as the selection criteria of the alpha wolf and the wolf group update mechanism, respectively [24].(6)
determine whether the updated result satisfies the optimization accuracy or the maximum number of iterations and output the position of the head wolf under the satisfied conditions; this position is the optimal solution of the function approximation value of the feedforward wavelet neural network algorithm; on the contrary, if the condition is not satisfied, return to process (2).The improved wolf pack algorithm can improve the function approximation ability of the wavelet neural network algorithm, greatly improve the traffic flow forecasting performance, and obtain the best traffic flow forecasting results.


## 3.1.1. Analysis of Function Approximation Capability of Feedforward Wavelet Neural Network Algorithm

The combination of wavelet analysis with neural networks is the main feature of the feedforward neural network algorithm, which creates a network based on wavelet analysis and affects multiple transmission models, which prevents the network from local optimization and improved integration [20]. Algorithms, generalization, and learning for short-term high-speed traffic are strong. The nonlinear sigmoid function of the wavelet neural network is replaced by a nonlinear wavelet basis, and the signal is interpreted as a linear superimposed wavelet basis. The average number of neural networks and the number of interpolated samples in the feedforward wavelet neural network algorithm is n + 1; at the same time, the inner and outer weights of the feedforward wavelet neural network can be constructed according to the values of the interpolation samples, and the arbitrary uninterrupted functions in the closed interval can be approximated together based on arbitrary precision. Convergence conditions are more important for the approximation problem of multidimensional extended wavelet neural networks to unary functions; therefore, the requirements for it are relatively high, which leads to an increase in the difficulty of operation and decreases the stability of the radial basis neural network connection weights.fx describes the uninterrupted function in the interval a,bk, and Wax,An describes the wavelet radial basis neural network constructed by randomly selecting ξ>0, the neural network contains a function described by An and a natural number described by N, and the function approximation value of the feedforward wavelet neural network algorithm is fx−Wax,An A, under the condition of N<n, and all x∈a,bk include(1)fx−Wax,An<ξ.The wavelet neural networkWax,An and the positive real numbers An satisfying the size condition exist in the process of uniform grid division in the a,bk interval and in the data xifi∈Rk+1,i=0,1,…,n; under the conditions of An>An, there is(2)Wexi,An=fi=fxi.ForXex,An, a wavelet neural network Wax,An can be constructed, with a positive real number A′n satisfying the size; under the condition of An>A′n, there is(3)Wexi,An−Wax,An<ξ3.Again,(4)fx−Wax,An=fx−fxi+Wexi,An−Wax,An=fx−fxi+Wexi,An−Wex,An+Wex,An−Wax,An≤fx−fxi+Wexi,An−Wex,An+Wex,An−Wax,An.Sincefx is uninterrupted in the interval a,bk, therefore, for the above ξ>0, ∃δ>0, under the condition of x−xi<kxi−xi+1=kn1/2kb−a<δ, that is, under the condition of n>kb−a/δ2k=N1, there is(5)fx−fxi<ξ3.Sinceψx⊂L2R is an uninterrupted wavelet function,(6)Wex,An=∑j=0ndjφ0φAx−xj.From the above process, it is obtained that the intervalfxa,bk is consistent and uninterrupted. For ξ>0 and ∃δ1>0 above, under the condition of x−xi<kxi−xi+1=kn1/2kb−a<δ, that is, under the condition of n>kb−a/δ12k=N2, there is(7)Wexi,An−Wex,An<ξ3.Therefore, under the condition ofn>N=maxN1,N2, when n corresponds to the corresponding An, the function approximation value of the feedforward wavelet neural network algorithm is(8)fx−Wax,An=fx−fxi+Wexi,An−Wax,An=fx−fxi+Wexi,An−Wex,An+Wex,An−Wax,An≤fx−fxi+Wexi,An−Wex,An+Wex,An−Wax,An≤ξ3+ξ3+ξ3=ξ.From this, it can be seen that, when constructing the feedforward wavelet neural network algorithm, there is no need to use training methods, for short-term high-speed traffic flow prediction in multidimensional space, the random correlation of multidimensional samples can be approximated with a given accuracy, obtaining the best traffic flow prediction results [21].


## 3.1.2. Improved Wolf Pack Algorithm

The process of detecting wolves in the wolf pack algorithm can be considered as the process of approximating the performance of the feedforward neural network algorithm in the traditional wolf pack algorithm, but in the process of catching wolves to find different animals, the number of directions Y is different, and the value is randomly selected according to the actual situation when taking the value, and the value range is represented byymin,ymax [22]. However, the number of directions that wolves look for is not affected by changes in the number of walks or the number of algorithm iterations. At the same time, during the experiment, the wolf detection direction is usually fixed at 10, rather than random, as described above. As a result, the search direction of the wolf detection in the wolf pack algorithm remains unchanged, and the error of the search result is large. The detailed description is as follows: if the number of directions y for the wolf to search for prey is 8, then the optimal direction is determined after one move.In the process of searching for the secondary movement, each direction forms a parallel relationship with the optimal direction, and in the subsequent search process, the search is carried out in this parallel direction, which seriously affects the search efficiency. In order to solve this problem, the walking direction of the wolf detection algorithm is improved, and W is used to represent the number of wolf detection. According to the parity of W, the search direction is selected betweeny,y+1 to enhance the accuracy of the search result. After the algorithm is improved, there is no parallel relationship between the directions of the W-th walk and the W + 1-th walk. It can be seen from this that the improved way of arbitrarily selecting the search direction of wolf detection in a given range can expand the search range.The improved wolf pack algorithm is described as follows:(1)
Value initialization:Xi, N, and Kmax are used to describe the wolf position, the number of wolves, and the maximum number of iterations in the wolf pack, respectively, and α, Wmax, ω, and β are used to describe the wolf detection scale factor, the maximum number of walks, the distance judgment factor, and the update scale factor, respectively, to initialize the above parameters [23].(2)
Xlead and Zlead are used to describe the position of the head wolf and the value of the objective function, which is the optimal objective function value. We use S−num to represent the number of wolves with the optimal objective function value, except for the first wolf, and when the number of walks is an odd number, the walk is performed according to the following formula:(9)xidp=xid+sin2π×py×step=xid+sin2π×py×rand⋅normxi,:−Xlead.When the number of walks is an even number, the walk is performed according to the following formula:(10)xidp=xid+sin2π×py+1×step=xid+sin2π×py+1×rand⋅normxi,:−Xlead.When the number of walks of each wolf detection meets the maximum number of walksWmax, we proceed to process (3).(3)
In the wolf pack, we randomly selectM_num wolves, except the alpha wolf, to search for prey according to the following formula:(11)xid=xid+step×xleadd−xidxleadd−xid=xid+rand×xi−xlead2×xleadd−xidxleadd−xid,d=1,2,…,D.During the search process, when the objective function value of a certain wolf isZi>Zlead, Zlead=Zi, the wolf replaces the alpha wolf to summon; under the condition of Zi<Zlead, the distance between the hunting behavior and the position of the same wolf is lower than dnear, and process (4) is performed.(4)
After updating the position of the selected wolf using the following formula, we continue to maintain the search behavior(12)xid=xidk+λ×step×Gd−xid=xid+λ×rand×xi−G2×Gd−xid,d=1,2,…,D.(5)
The positions of the alpha wolf and the wolf group are updated with the “winner is king” and “the strong survive” as the selection criteria of the alpha wolf and the wolf group update mechanism, respectively [24].(6)
determine whether the updated result satisfies the optimization accuracy or the maximum number of iterations and output the position of the head wolf under the satisfied conditions; this position is the optimal solution of the function approximation value of the feedforward wavelet neural network algorithm; on the contrary, if the condition is not satisfied, return to process (2).The improved wolf pack algorithm can improve the function approximation ability of the wavelet neural network algorithm, greatly improve the traffic flow forecasting performance, and obtain the best traffic flow forecasting results.


## 3.2. Simulation Test

In order to test the feasibility and effectiveness of the short-term high-speed traffic flow prediction algorithm based on the wolf pack algorithm, the measured data of a highway toll station in my country in 2017 were used as the experimental data, and the simulation was carried out in the MATLAB 2012a environment and the measured data in April, June, and September. November in 2017 was used as 4 data sets, with a total of 1418 groups of data; the relevant parameters are set as follows: according to the normal distribution, the weights and scaling factors of the wavelet neural network are randomly assigned, divided into the 1418 sets of data into training samples and test samples, 947 and 471, respectively, and we set the maximum training times and momentum factor to be 90 and 0.3, respectively; the minimum error value, weight learning rate, translation factor learning rate, and scaling factor learning rate are 0.0001, 0.01, 0.001, and 0.001, respectively.MAPE: mean percentage error, which can intuitively represent the strength and weakness of forecasting effects; MAE: mean error, small value, small error; RMSE: the root mean square error, the smaller the value, the smaller the error; EC: equal coefficient, the higher the value, the higher the ratio; RT: running time, reflecting the complexity of the algorithm. The calculation formula for the above indicators is as follows:(13)MAPE=1V∑tCpt−CrtCrt×100%,(14)MAE=1V∑tCpt−Crt,(15)RMSE=∑tCpt−Crt2V,(16)EC=1−∑tCpt−Crt2∑tCpt2+∑tCrt2.In the above formula,Cpt, Crt, and V are the predicted output value, the measured value of high-speed traffic flow at time t, and the number of predicted samples, respectively.


## 4. Results and Discussion

The above measurements are shown in the simulation, and the estimation of the estimation algorithm based on the author’s algorithm and wavelet neural network is compared with the maximum. Figures2 and 3 show short-term high-speed traffic prediction results of the author’s algorithm and a wavelet neural network-based prediction algorithm.Figure 2
The author’s algorithm predicts the effect.Figure 3
Prediction effect based on wavelet neural network.The simulation results in Figures2 and 3 show that the mean absolute percentage error value, mean absolute error value, and root mean square error value of the author’s algorithm are 0.054, 1.134, and 1.812, respectively; compared with the wavelet neural network prediction algorithm, it is reduced by 0.130, 1.585, and 1.749, respectively, while the equal coefficient and running time are respectively improved by 0.016 and 1.489  compared with the wavelet neural network prediction algorithm. The simulation results show that the short-term high-speed traffic forecasting effect of the author’s algorithm is better than that of the comparison algorithm in the situation where the operation time is different.Figure4 compares the error of the two algorithms in predicting the short-term traffic flow.Figure 4
Prediction errors of different algorithms.Analysis of the simulation results shown in Figure4 shows that the short-term high-speed traffic error of the author’s algorithm is less than the comparison algorithm, and at the same time, the sequence of errors is very similar. The probability of occurrence is higher. The data error is controlled between 0.8% and 2.7%. The simulation results show that the author’s algorithm has high accuracy and stability.Table1 shows the results of 10 short periods of high-speed traffic using the author’s algorithm.Table 1
The author’s algorithm for short-term high-speed traffic flow prediction results.
Number of experimentsMAPEMAERMSEECRT (s)10.0671.3772.0680.96933.42020.0701.2512.0670.97032.54730.0721.4132.0280.97032.5440.0351.0161.7650.97132.70050.0611.2101.9000.97030.08760.0601.1671.9280.97028.45170.0501.1301.8050.97131.00680.0471.1621.8880.97032.49390.0791.2502.0770.96929.087100.0531.2301.8300.97131.024Average value0.0591.2211.9360.97031.236The average value of each index obtained by the author’s algorithm in Table1 is compared with the average value of each index obtained by the wavelet neural network algorithm, and the results are shown in Table 2.Table 2
The comparison results of the prediction performance of the two algorithms.
Prediction algorithmMAPEMAERMSEECRT/sAuthor’s algorithm0.0591.2211.9360.97031.236Wavelet neural network prediction algorithm0.1211.822.6780.96129.891Analysis of Table2 shows that after using the author’s algorithm, although the running time is increased by about 1.5 s, the average absolute percentage error is reduced by more than 50%, the mean absolute error and root mean square error are reduced by about 30%, and the equalization coefficient is increased by about 1%; it shows that the prediction effect of the author’s algorithm is significantly improved compared with the prediction algorithm based on wavelet neural network.


## 5. Conclusion

Using short-term high-speed traffic forecasting, the author introduces a multiscale modified highway traffic forecasting algorithm based on convolutional networks, which is useful for extracting and improving short-term traffic highway running in the future. High-speed traffic laws: the author proposed a short-term high-speed traffic algorithm based on the wolf pack algorithm and derived the function approximation of the standard feedforward wavelet neural network algorithm from the derivation of the function; based on this, the walking-enhanced wolf pack algorithm is adopted to expand the walking path of the wolf detection, improve the prediction performance of the wavelet neural network algorithm, and improve the accuracy of the estimated short-run speed.



---

*Source: 8427237-2022-09-22.xml*