Abstract
The high-speed growth of big data and various cloud computing technologies has accelerated the process of various intelligent transportations. How to more comprehensively alleviate traffic congestion has become a key issue in urban construction. In view of this, this study proposes a traffic speed prediction and travel plan optimization method built on improved long short-term memory. In the process, an improved memory network model is established to predict the driving speed at the future end of the road section, and the improved ant colony optimization algorithms is integrated to optimize and re-plan the route of the traffic congestion travel plan. The results showed that when testing different datasets, the research method had a maximum fitness value of 97.21 when the number of training sessions was 82. When the number of iterations of the system is 85, the average absolute percentage error of the research method on the test set begins to approach 0. At this time, the error values of the three algorithms in the literature, the improved graph convolutional neural network, and the improved long short-term memory model are 0.018%, 0.034%, and 0.035%, respectively, which are significantly greater than the research methods. From the perspective of overall traffic speed prediction, the research method can achieve a fit of 95.42% when predicting the next 10 minutes speed time. All the above results show that the research method has a high adaptability to traffic speed prediction, can achieve dynamic programming of travel plan congestion paths, and provides reliable technical support for urban congestion mitigation methods.
Keywords
Introduction
In recent years, various countries around the world have faced various transportation problems, and China is no exception. With the rapid growth of people’s travel demand, the traffic congestion problem caused by it is becoming increasingly serious. The various economic losses caused by this problem are countless, and it is evident that solving traffic congestion has become an important issue.1,2 At this point, the rise and development of smart transportation have brought new opportunities to solve the problem of traffic congestion. At present, artificial intelligence algorithms are developing rapidly. Taking various deep learning algorithms as an example, long short-term memory (LSTM) has received extensive attention from all walks of life. 3 Scholars have pointed out that in today’s era of penetration of the Internet and intelligent devices, traditional traffic monitoring methods need to be improved. The fusion of multiple data traffic represented by mobile data, replacing existing cameras and maps, will inevitably achieve more accurate traffic detection and control, thereby promoting human travel. 4 On the ground of the resources of traffic data, the solution to traffic congestion is easily solved, which also proves that the development of intelligent transportation is imperative. 5 To better predict traffic speed and facilitate human travel planning, this study proposes an improved LSTM-based optimization method for traffic speed prediction (TSP) and travel planning. The entire paper has four parts. Part 1 is an analysis of the current domestic and international status of LSTM algorithm and TSP models. In the second part, LATM is utilized to predict the short-term traffic speed, and the improved ant colony optimization algorithm is integrated to re-plan the travel plan. The third part is to analyze the performance of the constructed prediction model and apply it to solve travel plans in practice. The fourth part is a summary statement of the entire article.
Related works
With the rapid advancement of modern society and the rapid construction of transportation, how to better alleviate traffic congestion is a key issue in construction, and neural network technology is also becoming increasingly mature. LSTM technology can handle and predict important events in time series, and through LSTM, traffic speed can be predicted, enabling analysis and optimization of travel paths. In the study of LSTM technology, Wang’s team proposed a multi-step prediction method grounded on LSTM and GM (1, 1) model for crude oil price prediction. This method uses empirical mode decomposition method to decompose crude oil prices and then classify and synthesize them to obtain components for fitting. This model has high prediction accuracy, especially for sequences representing long-term impacts of lower frequencies, which also has a great fitting effect on the trend of crude oil prices. 6 Li et al. proposed a vehicle speed prediction method based on backpropagation short-term memory to predict the speed of individual vehicles on traffic roads. During the process, the method used Pearson coefficient to analyze the correlation between different parameters, and the results showed that the method had high accuracy in predicting vehicle data. 7 Peng et al. believe that existing software crowdsourcing recommendation mechanisms do not take into account the contextual information of crowdsourcing tasks and therefore propose a new LSTM recommendation framework for worker capability correction. It adds LSTM to its historical tasks to extract long run and short run feature layers, and integrates the attention mechanism. The framework can accurately assess the changes in the interests and preferences of crowdsourcing workers and effectively improve the quality and efficiency of crowdsourcing recommendations. 8 Li’s team proposes a short-term and short-term memory model based on improved spatiotemporal correlation to predict tourists’ short-term vacation travel needs. Using tourist flow data from suburban tourist attractions in Beijing as the training dataset, it was found that the research method can effectively improve prediction accuracy and capture the temporal and spatial correlation of tourist flow more comprehensively. 9 Mao et al. believed that the quality of road network traffic operation occupies a crucial position in urban planning and sustainable development, so they established an overall and dynamic time series prediction model for road traffic speed based on PSO-LSTM. They discussed the appearance of peak hours from two aspects of local heat map and static heat map, and investigated the traffic states of main roads in Kunming. The model can analyze the road speed and visualize the results, which can provide reference for transportation planning and road design of plateau mountain cities. 10
At the same time, in the study of travel paths, Acarman’s team proposed a sequence-based prediction method to predict regional travel time, travel speed, and optimize travel paths. This method uses recurrent neural network to learn its spatiotemporal nonlinear relationship to predict the sequence and uses LSTN units to learn the travel time and final speed of the sub journey. Its root-mean-square error (RMSE) and mean absolute error (MAE) metrics are superior to function mapping and methods based on nonparametric linear velocity change. 11 Mai et al. proposed a recursive Logit (STDrl) model for route strategy selection in stochastic time-dependent networks to study the adaptation of travel route selection to traffic conditions. The routing strategy is a mapping from the state to the next link action to be taken, and the state is defined by nodes, time, and information. This model can meet the requirements and is superior to conventional models. 12 To alleviate traffic problems and save travel time, Zhai et al. came up with a dynamic layered spatiotemporal network on the basis of gray correlation analysis, CNN, and door control cycle unit. This model uses EGRA analysis to select candidate road segments that have a significant impact on the target road segment, constructs a multi-layer structure based on attention mechanism, and predicts the speed change in the next time interval. This model has good performance, with an MAE of around 2.6%, meeting practical requirements. 13 Shabarek’s team introduces deep learning models and data analysis to improve the performance of TSP and optimize travel paths. They proposed a framework has 2 DL models for predicting traffic speed while considering various external effects of traffic. The proposed framework model outperforms other models in terms of minimum RMSE and MAE. 14 Lee’s team proposed a spatiotemporal algorithm based on gate GRU to predict road travel time in order to solve the problem of reducing the time delay between experiential travel time and predicted travel time on travel routes. Through comparison with individual detector data and analysis of travel time, the forecasting travel time of each model and its applicability in travel were verified. Therefore, the spatiotemporal GRU prediction of road sections and route travel times is the most precise. 15
From the above, it can be seen that many scholars have designed a large number of improvement methods in optimizing travel distance and studying traffic speed, but combining LSTM’s TSP and optimizing travel paths is still relatively rare. Therefore, this manuscript raises a TSP method combined with improved LSTM to achieve optimization of travel paths.
Design and application of LSTM prediction algorithm in traffic speed under the background of travel plan optimization
With the rapid development of big data, cloud computing, 5G, BeiDou technology, etc., smart transportation is also being constructed rapidly. How to better alleviate traffic congestion is still the key to the construction. In the context of smart transportation, the experiment proposes a traffic speed prediction model based on an improved LSTM to achieve re-planning of travel routes in view of the problems existing in urban road traffic such as unknown arrival road conditions and delayed push of real-time traffic condition messages. At the same time, the idea of travel planning is introduced and the entire research process is built on this basis, in order to achieve transparency of the road ahead in the future, so as to conduct more accurate and time-efficient traffic prediction and path guidance.
Improved LSTM future short-term travel speed prediction method based on travel plan
At the beginning of its development, the travel plan was defined as a simulated navigation website, which refers to the user’s established travel information, including travel start and end points, travel time, and navigation routes. Collecting travel plan data from all travelers will effectively form a massive spatiotemporal database. By processing, analyzing, and calculating data, more accurate road traffic information can be obtained. In order to effectively evacuate congestion and provide travelers with the best travel experience, while helping traffic management departments optimize traffic light control systems, a TSP method based on improved LSTM is proposed.
16
Firstly, it built a simulated navigation website using programming language and the Gaode Map API. The system collects the planned travel data of travelers and calculates the resulting data to obtain the average speed of vehicles on a certain section of the road during a certain period of time. Set the time when the vehicle arrives at its destination to
In formula (1), Schematic diagram of travel time superposition.
In the later stage, in order to make this system better, other humanized functions can also be added. Considering that there may be changes in the starting and ending points of travelers, which can lead to changes in travel plans, research can set up a development change function in the system function bar. The entire system and its related functions are deployed on a cloud server at a certain Jiao Tong University, making it easy for research members to use and develop. In the construction of the primary travel planning system, the speed factor is crucial for achieving future road condition calculations. In order to grasp and predict future short-term driving speeds in real time, an improved LSTM method for predicting future short-term driving speeds based on travel plans is proposed in the experiment. The network traffic changes of vehicles during driving will be interfered by geographical factors and other factors, and there is a strong correlation between the two.
17
Congestion at transportation nodes can seriously affect other nodes, and there is a dynamic spatial dependence between traffic flow (Tf) and geographical location. For the LSTM model, this model has many limitations. First, the model is limited to traffic flow prediction in a single area. Predictions in different areas also need to use the traffic flow data of this collection point for training. Second, time series training is limited to single-day traffic flow and cannot capture periodic information. Third, the period of traffic data is not fixed and does not meet strict periodicity. Considering the above reasons, the experiment introduces the CNN model and combines it with the LSTM model to predict the traffic flow in the overall area. The CNN-LSTM model combines the powerful feature extraction capabilities of CNN and the ability of LSTM to process sequence data, making this model outstanding in processing pixel and temporal data. The Tf matrix is actually composed of the sorting of sampling points and the temporal order of Tf. When the total number of all sampling points is
In formula (2),
In formula (3),
In formula (4), Time series input expansion diagram of the LSTM model at time t.
Observing and analyzing the LSTM model, it can be seen that it is very powerful in processing time series, but the implementation of its three gate structure is relatively complex. This study introduces Gated Recurrent Unit (GRU) as its evolutionary model for short-term Tf prediction. Consider the GRU model directly as a structure in which the forgetting gate and output gate are combined in the LSTM model, while the memory unit state and the hidden layer state Structure diagram of the GRU model.
As shown in Figure 3, the output
In formula (5),
When outputting hidden layer unit information, the GRU model must control the proportion of information saved in the previous moment of the hidden layer. Add the information output of
Based on the above formula, it can be seen that the output of the update gate will directly affect the current hidden layer to affect how much previous information needs to be retained in the hidden layer output.
Design of improved ant colony traffic congestion seeking path re-planning method based on travel planning
The experiment first designed an improved LSTM deep learning model to analyze short-term TSP and then achieved speed prediction for multiple road sections at multiple times in the future. The entire process achieved feature extraction of global information, but the re-planning of the current travel path is not clear. The idea of ant colony optimization (ACO) comes from the foraging behavior of ants. Through the role of distributed search and positive feedback mechanism, it can respond quickly during path search, providing great feasibility and effectiveness for optimizing urban road traffic conditions. Therefore, the experiment uses the traffic flow prediction model as the basis, introduces the ant colony algorithm, and plans to re-plan an efficient and safe travel route for travelers to avoid congestion. Compared with ants that actually exist in nature, the ants in the algorithm have a certain degree of memory ability.
19
The experiment aims to add a taboo table to the algorithm to record the nodes traveled by different ants. The expression of the state transition probability function of the node that the
In formula (8),
In addition, in order to effectively avoid that the cumulant of the positive and negative features of the ant colony is large and weakened so that the influence of the heuristic function is eliminated, it is necessary to update the pheromone after the ant colony completes an iteration. The specific update calculation is formula (10).
In formula (10), ACO process.
The basic ant colony algorithm sets the pheromone distribution on each path to be uniform in the initial state. In this way, forward routes can be selected with equal probability in the early stage of pathfinding and the search range can be expanded. However, pheromone without concentration difference cannot induce well and will cause a search situation that cannot converge quickly and is inefficient in the early stage of the algorithm. And conventional path planning targeting the shortest distance can no longer satisfy today’s increasingly complex road network. Avoiding congestion means that the high speed is smooth and the travel plan can be completed efficiently in a short time. Under the guidance of this core idea, the experiment combines the speed prediction of different road sections in the future realized by the CNN-LSTM deep learning model in the previous chapter, and ACO and grid Methods (A* Algorithm) are combined with each other to re-plan travel routes to avoid congestion. The representative meanings of the parameters obtained using ACO have different influence ranges. Different parameter values will form different parameter combinations, which will affect the rate of convergence and operation efficiency. To better plan the ideal range of parameters, the A* algorithm was selected for research, and a single independent variable approach was adopted to narrow down and select a more optimal range of parameter values. The A* algorithm is usually used for path optimization and graph traversal problems; therefore, it has better performance and accuracy. Figure 5 shows the heuristic function of the A* algorithm idea. Schematic diagram of heuristic function for A*.
The experiment assumes that the starting point of the abstract transportation network is a and the ending point is d, and searches for the shortest path between the two. The heuristic function variation in A* is formula (11).
In formula (11), Initial road network structure of ants foraging.
The global and local pheromone update methods are different. The experiment introduces speed factor here to realize the dynamic re-planning of local pheromone. If the pheromone of the congested road can be volatilized in time when facing the congestion of some roads, the probability of ants choosing other non-congested paths will begin to increase. The traffic information changes of local roads are accurately reflected in the pheromone distribution of roads to lift the search efficiency. The expression of information trajectory update is formula (12).
In formula (12),
In formula (13),
In formula (14), the lower threshold of
Analysis of the optimization effect of improving LSTM's TSP on travel paths
Performance analysis of traffic speed prediction model based on improved LSTM
Basic environmental parameters.
The experimental variable studied is the speed prediction model, and the remaining experimental environments, simulation techniques, and traffic application datasets are consistent to ensure the comparability of the obtained experimental results. Set the population size as 200. Select 2200 traffic data from a certain road network in the United States, remove 100 erroneous data information after processing, and use 40% of the remaining 2100 as the test set and 60% as the validation set. Perform different performance metrics tests on different algorithms. The convergence changes of the four models are shown in Figure 7. Comparison of convergence changes of four models. (a) Test set and (b) verification set.
Figure 7(a) shows the convergence changes of different algorithms on the test set. Under changes in the number of system runs, all four algorithms show a relatively rapid increase, and the fitness values of literature,
21
IGCN, and ILSTM algorithms have been in a tortuous state of change. In addition, when the training frequency is 82, the research method has a maximum fitness value of 97.21. This also indicates that the convergence of the research method is more stable. Figure 7(b) shows the convergence test on the validation set dataset. The fitness values of all algorithms vary relatively smoothly. When the iteration reached the 18th time, the research method had a maximum fitness value of 99.74 and began to move infinitely towards 99.99. However, the other three algorithms did not show stable fitness values throughout the entire operation process, and the fitness values of all algorithms were lower than those of the research method. The above data show that the research method has the highest fitness value and can have a faster rate of convergence. Compare the changes in accuracy and recall using the test set as the main experimental dataset. The PR curve is shown in Figure 8. Comparison of PR values of four algorithms on the test set.
Observing the changes in PR values in Figure 8, it can be observed that when the accuracy of the research method reaches 80% and 90%, the corresponding recall rates are 89.79% and 81.77%, respectively. At this time, the recall rates in Reference 21 were 81.78% and 68.74%, respectively. Meanwhile, when the accuracy rate is 90%, the corresponding recall rates for ILSTM and IGCN are 58.87% and 63.21%, respectively. Based on the above results, in the same experimental environment, the accuracy and recall of the three comparative algorithms were significantly lower than those of the research methods. The results obtained in Reference 21 are slightly better than ILSTM and IGCN. This further indicates that the research method is more accurate in predicting the TSP system in the context of travel planning, which can effectively cope with the probability of traffic accidents and ensure the safety of vehicles and individuals. On this basis, the mean absolute percentage error (MAPE) changes of the four algorithms were compared, and Figure 9 shows the specific results. Change curve of MAPE. (a) Test set and (b) verification set.
Figure 9(a) shows the variation of the average absolute percentage error on the test set. When the system was trained for the 85th time, the MAPE values of the research method began to approach 0, while the MAPE values of the literature, 21 IGCN, and ILSTM algorithms were 0.018%, 0.034%, and 0.035%, respectively, which were significantly higher than those of the research method. When the MAPE value in Figure 9(b) approaches 0, the system is trained for the 73rd time. When iterating to 88 times, Reference 21 has the minimum MAPE value. Until the system iterates 100 times, there is no minimum MAPE value for IGCN and ILSTM. Based on the analysis of significance results, there is a significant difference in error between the research method and other methods. The deviation between the TSP values obtained using research methods and the true values is smaller.
Impact of traffic speed prediction model on travel route planning
Then, the improved algorithm is used and combined with the short-term driving speed prediction value of the corresponding road section in the previous chapter to re-plan travel sections that will be congested in the future. The selected travel plan is based on the traffic induction example road network, and the research method and the research method in the literature
21
are used to predict the traffic speed of a certain road section in the United States. The traffic speed predictions of different algorithms on the target road section are shown in Figure 10. TSP 10 min of different algorithms on the target road segment. (a) Research method for predicting the next 10 min speed at the current moment (b) Reference 21 predicting the next 10 min speed at the current time.
Path optimization results of distinctive methods.
Table 2 shows that the optimal path for this section is 52.12 km. When the iteration reaches 72 times, the optimization path of the research method is 36.04 km, which only takes 2.16 s. Among the other three algorithms, Reference 21 performed the best in terms of application performance, with optimal paths, iterations, and time consumption of 45.29 km, 85, and 3.56 s, respectively. By comparison, the travel planning path of the research method is the shortest and the most time-consuming, which can be applied in actual road sections and achieve good results.
Conclusion
To effectively alleviate road traffic congestion, the LSTM is put forward to predict short-term traffic speeds in the future, and the improved ACO algorithm is integrated to optimize the travel path planning. The final method for optimizing TSP and travel plans based on improved LSTM has been constructed. The data shows that during the convergence test on the validation set, when the iteration reaches the 18th time, the research method has a maximum fitness value of 99.74 and begins to approach infinitely towards 99.99. When the accuracy of the research method reaches 80% and 90%, the corresponding recall rates are 89.79% and 81.77%, respectively. At this time, the recall rates in Reference 21 were 81.78% and 68.74%, respectively. On the validation set, when the system iterates 73 times, the MAPE value of the research method begins to approach 0. Using research methods to predict the next 10 min speed, the fitting degree between the true and predicted value is as high as 95.42%. When optimizing the actual travel plan, when the time consumption is 2.16 s, the optimization path of the research method is only 36.04 km. The above results indicate that the research method has fast operational efficiency and can effectively predict traffic speed, thereby solving the problem of travel planning paths. However, the travel plans and TSP system involved in the research are still in the early stages of simulation and cannot be applied on a large scale. Therefore, further expansion of experimental venues is needed in the future to verify the actual application effects in multiple locations.
Statements and declarations
Footnotes
Conflicting interests
The author(s) declared no potential conflicts of interest with respect to the research, authorship, and/or publication of this article.
Funding
The author(s) received no financial support for the research, authorship, and/or publication of this article.
