| Traffic flow forecasting tasks are not only closely related to the scheduling of vehicles by relevant management departments,but also enable drivers to avoid unnecessary traffic congestion.With the transformation of the industrial structure and the continuous increase in the number of residents’ vehicles,the insufficient carrying capacity of roads has led to a sharp rise in the contradiction between vehicles and roads.Traffic flow reflects the operational status of the road networks.If we know the trend of traffic flow in advance,it will help the traffic manager to unblock the traffic in advance,save time for residents,reduce pollution during road congestion,and beautify the urban environment.Traffic flow is a typical spatio-temporal data.It has the characteristics of a large scale,various types,low-value density,spatio-temporal dependence,and social relevance.Therefore,the task of traffic flow prediction is very complicated and challenging.Many existing traffic flow prediction models cannot take into account the spatio-temporal features of traffic flow.In this paper,two attention spatio-temporal networks are proposed to solve the problem of dynamic dependence of traffic flow data.The main research results are as follows:Firstly,after analyzing the multi-scale correlation of traffic flow data,we propose a multi-scale modeling scheme,which contains time interval,hour,day,and week levels to improve the accuracy of traffic flow forecast during peak hours.This multi-scale model not only is useful for traffic flow in un-peak periods,but also can make more accurate predictions for peak periods.Secondly,we propose a way to combine the multi-scale attention mechanism and the bidirectional long short-term memory networks.It resolves the problem in the simplification of traffic flow data features and the dependence of spatial-temporal dimensions.It extracts and utilizes the potential temporal dependence features of traffic flow.Finally,based on two public datasets,we construct the external factor features and integrate into the designed Attention Spatial-Temporal Network(ASTN),which reduces the effects of external factors such as weather,holidays and so on.The experiment results show that the ASTN can reduce the prediction error by 3-7% on NYC-Bike and NYC-Taxi datasets compared to the latest model STDN(2019).We propose a feature extraction method that employs a spatial multi-head selfattention mechanism and convolutional neural networks.It solves the problems of the road networks without direction and the diversity of spatial dependence.By modeling the inflow and outflow data separately,the model ignores the weak correlation data that is adjacent to the target area.Based on this method of feature extraction,we propose a Dual Attention Spatial-Temporal Network(DASTN)to solve the problem of traffic flow prediction when the data have weak neighborhood relations.The experiment results show that the DASTN can reduce the prediction error by 3-6% on NYC-Bike and NYC-Taxi datasets compared to the latest model STDN. |