CN111508230B - Time-interval traffic flow trend prediction method, system and device based on deep learning - Google Patents

Time-interval traffic flow trend prediction method, system and device based on deep learning Download PDF

Info

Publication number
CN111508230B
CN111508230B CN202010297850.8A CN202010297850A CN111508230B CN 111508230 B CN111508230 B CN 111508230B CN 202010297850 A CN202010297850 A CN 202010297850A CN 111508230 B CN111508230 B CN 111508230B
Authority
CN
China
Prior art keywords
traffic flow
data
model
time
traffic
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010297850.8A
Other languages
Chinese (zh)
Other versions
CN111508230A (en
Inventor
朱凤华
张伟
吕宜生
陈圆圆
董西松
王飞跃
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Institute of Automation of Chinese Academy of Science
Original Assignee
Institute of Automation of Chinese Academy of Science
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Institute of Automation of Chinese Academy of Science filed Critical Institute of Automation of Chinese Academy of Science
Priority to CN202010297850.8A priority Critical patent/CN111508230B/en
Publication of CN111508230A publication Critical patent/CN111508230A/en
Application granted granted Critical
Publication of CN111508230B publication Critical patent/CN111508230B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G08SIGNALLING
    • G08GTRAFFIC CONTROL SYSTEMS
    • G08G1/00Traffic control systems for road vehicles
    • G08G1/01Detecting movement of traffic to be counted or controlled
    • G08G1/0104Measuring and analyzing of parameters relative to traffic conditions
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/044Recurrent networks, e.g. Hopfield networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/04Forecasting or optimisation specially adapted for administrative or management purposes, e.g. linear programming or "cutting stock problem"
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q50/00Information and communication technology [ICT] specially adapted for implementation of business processes of specific business sectors, e.g. utilities or tourism
    • G06Q50/40Business processes related to the transportation industry
    • GPHYSICS
    • G08SIGNALLING
    • G08GTRAFFIC CONTROL SYSTEMS
    • G08G1/00Traffic control systems for road vehicles
    • G08G1/01Detecting movement of traffic to be counted or controlled
    • G08G1/0104Measuring and analyzing of parameters relative to traffic conditions
    • G08G1/0125Traffic data processing
    • GPHYSICS
    • G08SIGNALLING
    • G08GTRAFFIC CONTROL SYSTEMS
    • G08G1/00Traffic control systems for road vehicles
    • G08G1/01Detecting movement of traffic to be counted or controlled
    • G08G1/0104Measuring and analyzing of parameters relative to traffic conditions
    • G08G1/0125Traffic data processing
    • G08G1/0129Traffic data processing for creating historical data or processing based on historical data

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Business, Economics & Management (AREA)
  • General Health & Medical Sciences (AREA)
  • Health & Medical Sciences (AREA)
  • Software Systems (AREA)
  • Economics (AREA)
  • Evolutionary Computation (AREA)
  • Computational Linguistics (AREA)
  • Molecular Biology (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Biophysics (AREA)
  • Mathematical Physics (AREA)
  • Biomedical Technology (AREA)
  • Artificial Intelligence (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Analytical Chemistry (AREA)
  • Data Mining & Analysis (AREA)
  • Chemical & Material Sciences (AREA)
  • Human Resources & Organizations (AREA)
  • Strategic Management (AREA)
  • Marketing (AREA)
  • Tourism & Hospitality (AREA)
  • General Business, Economics & Management (AREA)
  • Entrepreneurship & Innovation (AREA)
  • Operations Research (AREA)
  • Quality & Reliability (AREA)
  • Game Theory and Decision Science (AREA)
  • Development Economics (AREA)
  • Primary Health Care (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The invention belongs to the field of intelligent traffic systems, and particularly relates to a time-interval traffic flow trend prediction method, a time-interval traffic flow trend prediction system and a time-interval traffic flow trend prediction device based on deep learning, aiming at solving the problems of low prediction precision and poor stability of the conventional traffic flow prediction method. The system method comprises the following steps: acquiring historical traffic flow data before a traffic observation point t moment to be predicted and corresponding sampling time; standardizing historical traffic flow data and carrying out first-order difference; extracting the characteristics of the data after the difference, coding the corresponding sampling time, and splicing the coded sampling time and the extracted characteristics; based on the spliced characteristics, obtaining the variable quantity of the traffic flow at the t moment relative to the t-1 moment through a second model, and obtaining the prediction result of the traffic flow data at the t moment of the traffic observation point to be predicted by combining the traffic flow data at the t-1 moment; and carrying out anti-standardization on the prediction result to obtain a prediction value of the traffic flow at the time t. The invention improves the stability and precision of prediction.

Description

Time-interval traffic flow trend prediction method, system and device based on deep learning
Technical Field
The invention belongs to the field of intelligent traffic systems, and particularly relates to a time-interval traffic flow trend prediction method, system and device based on deep learning.
Background
The rapid development of society brings great challenges to the planning and management of urban traffic, and an Intelligent Transportation System (ITS) is a key point for solving the problem. The accurate traffic flow prediction has very important significance for the management and control of an intelligent traffic system, and is a powerful basis for traffic decision.
Data-driven traffic flow prediction has received attention from many researchers, and a number of methods have been proposed in succession. From the initial ARIMA model (autoregistered Moving average) and a series of variants thereof, to the Kalman filter model (Kalman filtering model), the K-nearest neighbor (K-nearest neighbor), the Support Vector Regression (Support Vector Regression) and other machine learning algorithms, all are used to realize short-term traffic flow prediction. Since being proposed, Deep Learning models (Deep Learning) have been regarded as important and rapidly developed in the prediction field, and various Deep Network models, such as Long and Short Term Memory networks (LSTM), Convolutional Neural Networks (CNN), Graph Convolutional Networks (GCN), and the like, have been developed, which can effectively improve the accuracy of traffic flow prediction.
Different network models have advantages and disadvantages, and it is hard to say that the prediction performance of a certain model is superior to that of other networks in all scenes. Meanwhile, although the traffic network is a very complex nonlinear time-varying system, most of the existing researches do not consider the influence of time on traffic flow prediction. In addition, uncertain interferences in data, such as abnormal values and fluctuations, can seriously affect the learning of the model to the temporal spatial characteristics of the traffic network, and reduce the accuracy and stability of network prediction. Therefore, the invention provides a time-interval traffic flow trend prediction method based on deep learning.
Disclosure of Invention
In order to solve the above problems in the prior art, that is, to solve the problems of low prediction accuracy and poor stability caused by that the time factor is not considered and the uncertain interference of traffic flow data is not eliminated in the conventional method for predicting traffic flow, the first aspect of the present invention provides a method for predicting a time-segment traffic flow trend based on deep learning, which comprises:
step S100, obtaining historical traffic flow data before a traffic observation point t moment to be predicted and corresponding sampling time;
step S200, standardizing the historical traffic flow data, and performing first-order difference on the standardized data to obtain first data;
step S300, extracting the characteristics of the first data by adopting a first model, and coding the corresponding sampling time through One-Hot; splicing the coded sampling time and the extracted features;
s400, based on the spliced characteristics, obtaining the variable quantity of the traffic flow at the time t relative to the time t-1 through a second model, and obtaining the prediction result of the traffic flow data at the time t of the traffic observation point to be predicted by combining the traffic flow data at the time t-1;
step S500, carrying out anti-standardization on the prediction result of the traffic observation point to be predicted at the time t to obtain the predicted value of the traffic flow at the time t;
the first model and the second model are constructed on the basis of a deep learning network.
In some preferred embodiments, the traffic flow data includes traffic flow, vehicle travel speed, traffic flow density or average number of vehicles in a lane, average traffic occupancy.
In some preferred embodiments, in step S200, "standardizing the historical traffic flow data, and performing first-order difference on the standardized data" includes: and normalizing the historical traffic flow data by adopting a z-score normalization method, and performing first-order difference on the normalized data.
In some preferred embodiments, the training method of the first model and the second model is as follows:
a100, obtaining a training sample set, wherein the training sample set comprises a first data sample and a real traffic data flow data label at a moment to be predicted;
step A200, based on the first data sample of the training sample set, executing step S300 to splice the coded sampling time and the extracted features;
step A300, based on the spliced characteristics, executing the steps S400-S500 to obtain a predicted value of the traffic flow at the moment to be predicted; acquiring an average absolute prediction error through a preset prediction error calculation method based on the predicted value and the real traffic data flow data at the moment to be predicted;
step A400, fixing the network structure parameters of the first model, and selecting structure parameters from a preset second network structure parameter candidate set to modify the second model;
step A500, circularly executing the steps A300-A400 until all parameters in the second network structure parameter candidate set are traversed, selecting a second model corresponding to the minimum average absolute error as a trained second model, and skipping to the step A600;
step A600, fixing the structural parameters of the second model, and selecting the structural parameters from a preset first network structural parameter candidate set to modify the first model;
step A700, the steps A200, A300 and A600 are executed in a circulating mode until all the parameters in the first network structure parameter candidate set are traversed, and the first model corresponding to the minimum average absolute error is selected as the trained first model.
In some preferred embodiments, the prediction error method comprises:
Figure RE-GDA0002503065890000031
wherein m is the number of samples in the training sample set, MAE is the average absolute prediction error, y(p)For the real traffic data stream data at the time to be predicted,
Figure RE-GDA0002503065890000041
p is a natural number for predicting a predicted value of the traffic flow at the time,the superscript is denoted.
In some preferred embodiments, in step S300, "encode its corresponding sampling time by One-Hot", the method includes:
Figure BDA0002452894000000042
wherein the content of the first and second substances,
Figure BDA0002452894000000043
the code corresponding to the kth sampling time of the ith sample is shown, and i represents an index.
The invention provides a time-interval traffic flow trend prediction system based on deep learning, which comprises a data acquisition module, a difference module, a splicing module, a prediction result acquisition module and an anti-standardization output module;
the data acquisition module is configured to acquire historical traffic flow data before a traffic observation point t to be predicted and corresponding sampling time;
the difference module is configured to standardize the historical traffic flow data and perform first-order difference on the standardized data to serve as first data;
the splicing module is configured to extract the characteristics of the first data by adopting a first model and encode the corresponding sampling time through One-Hot; splicing the coded sampling time and the extracted features;
the prediction result acquisition module is configured to obtain the variation of the traffic flow at the t moment to the t-1 moment through the second model based on the spliced features, and obtain the prediction result of the traffic flow data at the t moment of the to-be-predicted traffic observation point by combining the traffic flow data at the t-1 moment;
the anti-standardization output module is configured to perform anti-standardization on the prediction result of the traffic observation point to be predicted at the time t to obtain a prediction value of the traffic flow at the time t;
the first model and the second model are constructed based on a deep learning model.
In a third aspect of the present invention, a storage device is provided, in which a plurality of programs are stored, the programs being loaded and executed by a processor to implement the above-mentioned time-share traffic flow tendency prediction method based on deep learning.
In a fourth aspect of the present invention, a processing apparatus is presented, comprising a processor, a storage device; a processor adapted to execute various programs; a storage device adapted to store a plurality of programs; the program is suitable for being loaded and executed by a processor to realize the time-share traffic flow trend prediction method based on deep learning.
The invention has the beneficial effects that:
the invention improves the stability and precision of prediction. According to the invention, through carrying out difference on the acquired historical traffic flow data, uncertain interferences such as abnormity and fluctuation in the data can be eliminated to a certain extent, and the learning of the model on the time-space characteristics of the traffic network is improved. By splicing the characteristics of the data after the difference and the corresponding sampling time and embedding the time information into a network model based on deep learning, different characteristics presented by traffic flow prediction along with time change can be mined, so that the prediction in different time periods is realized, and the prediction precision and the stability of the model are improved.
Meanwhile, the method is suitable for various network models, can be easily deployed at different prediction places, and has universality and robustness.
Drawings
Other features, objects, and advantages of the present application will become apparent from the following detailed description of non-limiting embodiments thereof, which proceeds with reference to the accompanying drawings.
FIG. 1 is a schematic flow chart of a time-segment traffic flow trend prediction method based on deep learning according to an embodiment of the present invention;
FIG. 2 is a block diagram of a deep learning based time-segmented traffic flow trend prediction system according to an embodiment of the present invention;
FIG. 3 is a schematic flow chart illustrating a method for predicting time-share traffic flow trend based on deep learning according to an embodiment of the present invention;
FIG. 4 is a detailed flowchart of the training process of the first and second models according to an embodiment of the present invention;
FIG. 5 is a schematic block diagram of a computer system suitable for use with the electronic device to implement an embodiment of the invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings, and it is apparent that the described embodiments are some, but not all embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The present application will be described in further detail with reference to the following drawings and examples. It is to be understood that the specific embodiments described herein are merely illustrative of the relevant invention and not restrictive of the invention. It should be noted that, for convenience of description, only the portions related to the present invention are shown in the drawings.
It should be noted that the embodiments and features of the embodiments in the present application may be combined with each other without conflict.
The time-interval traffic flow trend prediction method based on deep learning, disclosed by the invention, as shown in figure 1, comprises the following steps of:
step S100, obtaining historical traffic flow data before a traffic observation point t moment to be predicted and corresponding sampling time;
step S200, standardizing the historical traffic flow data, and performing first-order difference on the standardized data to obtain first data;
step S300, extracting the characteristics of the first data by adopting a first model, and coding the corresponding sampling time through One-Hot; splicing the coded sampling time and the extracted features;
s400, based on the spliced characteristics, obtaining the variable quantity of the traffic flow at the time t relative to the time t-1 through a second model, and obtaining the prediction result of the traffic flow data at the time t of the traffic observation point to be predicted by combining the traffic flow data at the time t-1;
step S500, carrying out anti-standardization on the prediction result of the traffic observation point to be predicted at the time t to obtain the predicted value of the traffic flow at the time t;
the first model and the second model are constructed on the basis of a deep learning network.
In order to more clearly describe the time-share traffic flow trend prediction method based on deep learning, the following describes in detail the steps of an embodiment of the method in conjunction with the accompanying drawings.
In the following preferred embodiment, the training method of the first and second models is described in detail, and the forecast value of the traffic flow is obtained by the time-segment traffic flow trend prediction method based on deep learning.
1. Training method
Step S100, acquiring a training sample set;
and collecting sample data, wherein the sample data comprises sampling time, vehicle running speed, traffic flow density or average number of vehicles in a lane and average traffic occupancy. The running speed and traffic flow of vehicles can be directly obtained by the loop coil detectors, and the traffic flow density or the average number of vehicles in the lane can be obtained by respectively arranging the loop coil detectors at the predicted starting and stopping points and then counting the difference between the numbers of vehicles passing through the two detectors (the number of lanes is a known constant). In addition to the toroid detector, more advanced detectors may be used to obtain the above data, such as video detectors, GPS devices, AVL devices, and the like.
Step A200, standardizing first data samples of the training sample set and carrying out first-order difference to obtain first data; extracting the characteristics of the first data by adopting a first model, and coding the sampling time corresponding to the first data by One-Hot; splicing the coded sampling time and the extracted characteristics;
after the sample data is collected, preprocessing by adopting standardization, wherein the specific processing process is as follows:
calculating standard difference sigma and mean value mu of traffic flow data to be standardized by adopting a z-score standardization method, namely calculating the standard difference sigma and the mean value mu of the traffic flow data to be standardized, namely the traffic flow x of each position at any timetNormalized data x'tAs shown in equation (1):
x′t=(xt-μ)/σ (1)
wherein the content of the first and second substances,
Figure BDA0002452894000000081
n is the total number of samples, and N is a natural number.
And performing the same standardization processing on other variables (including output variables) to obtain corresponding standardization parameters.
The traffic flow data after the normalization processing is subjected to a first order difference as shown in fig. 3, i.e., for the historical traffic flow data yt-N,yt-N+1,...,yt-1]The data after the first order difference is [ yt-N+1-yt-N,yt-N+2-yt-N+1,...,yt-1-yt-2,yt-1]Where t denotes a time (time) to be predicted, the differentiated data is used as the first data, and the rest of fig. 3 is described in the following process.
The differentiated first data is divided into a training set and a test set, wherein 80% of the data is preferably selected as the training set and 20% of the data is preferably selected as the test set, and in other embodiments, proper division can be adopted according to specific conditions. If the data volume is too small, the training set and the test set can be divided by adopting an N-fold cross validation method to fully utilize the data.
And the labels in the training set are real traffic data flow data at the moment to be predicted.
After the training sample set is obtained, a first model and a second model, i.e., a feature extraction model and a trend change prediction model, are constructed and trained, as shown in fig. 4.
Model of the first Model1Based on deep learning network construction, in other implementationsIn the example, a specific model, such as a full connection Network (FC), a Long Short-Term Memory (LSTM), a Convolutional Neural Network (CNN), or a hybrid Network model, such as CNN-LSTM or GCN-LSTM, may be selected according to actual needs. Model1For extracting time-independent spatio-temporal features of the data, a second Model2Is selected and Model1Similarly, Model2Using a Model1And the characteristics and the time information are extracted to complete the prediction of the traffic flow trend.
After the first model is built, determining network structure parameters of the first model, and extracting time-space characteristics of first data by using the first model (during training, input data simultaneously comprise time sequence data and data of different places, so that the obtained time-space characteristics are obtained).
When determining the parameters of the first model, if the first model is constructed based on the LSTM, the parameters to be set include the number of hidden nodes, the number of hidden layers, whether the two-way connection is adopted, and the like; if the CNN is constructed, the number of hidden layers, the number of output channels of each layer, the size of a convolution kernel, and the like need to be set.
After the characteristics of the first data are extracted, the sampling time corresponding to the first data is coded into a One-Hot form, namely if a day contains NdFor the ith sample of the same day, the code of the corresponding time is
Figure BDA0002452894000000093
The encoding process is shown in formula (2):
Figure BDA0002452894000000091
wherein the content of the first and second substances,
Figure BDA0002452894000000092
the code corresponding to the kth sampling time of the ith sample is shown, and i represents an index.
And splicing the coded time information and the extracted features.
Step A300, based on the spliced characteristics, obtaining the variable quantity of the traffic flow at the time t relative to the time t-1 by adopting a second model, and combining the traffic flow data at the time t-1 to obtain the prediction result of the traffic flow data at the time t of the to-be-predicted traffic observation point, and performing denormalization to obtain the predicted value of the traffic flow at the time to be predicted; and based on the predicted value and the real traffic data flow data at the moment to be predicted, obtaining an average absolute prediction error through a preset prediction error calculation method
Determining a Model2Based on the spliced characteristics, the parameters of the network structure are processed by a Model2Obtaining the variation quantity, namely the variation trend, of the traffic flow at the moment to be predicted relative to the previous moment and recording the variation quantity as the variation trend
Figure BDA0002452894000000101
Adding the obtained variable quantity with the traffic flow data of the previous moment to obtain the final predicted traffic flow
Figure BDA0002452894000000102
As shown in equation (3):
Figure BDA0002452894000000103
wherein, yt-1Representing traffic flow data at time t-1.
Figure BDA0002452894000000104
For the normalized data, the predicted value obtained after the denormalization is
Figure BDA0002452894000000105
Figure BDA0002452894000000106
Calculating average absolute prediction by a preset prediction error calculation method according to the real traffic data stream and the predicted value at the time tMeasuring errors, as shown in formula (4):
Figure BDA0002452894000000107
wherein MAE represents the average absolute prediction error, m' is the number of samples in the training sample set, y(p)For the real traffic data stream data at the time to be predicted,
Figure BDA0002452894000000108
p is a natural number representing a superscript for predicting the predicted value of the traffic flow at the time.
Step A400, fixing the network structure parameters of the first model, and selecting structure parameters from a preset second network structure parameter candidate set to modify the second model;
in the invention, because each model has more modifiable parameters, in order to avoid the problem of 'combinatorial explosion', the network structure is modified in the following two ways: modifying the structure of another network under the condition of not changing the structure parameters of one model; second, for Model1And a Model2It is not necessary to traverse every possible structure, but rather a number of alternative values are randomly generated and test verified on those structures. The specific process is as follows:
without changing the Model1In the case of (2), the Model is modified within a certain range2The second model is modified according to the structure parameters selected from the preset network structure parameter candidate set, and the corresponding average absolute prediction error is recorded.
Step A500, circularly executing the steps A300-A400 until all parameters in the second network structure parameter candidate set are traversed, selecting a second model corresponding to the minimum average absolute error as a trained second model, and skipping to the step A600;
traversing all parameters in the network structure parameter candidate set, and corresponding the minimum average absolute error to the network structure
Figure BDA0002452894000000111
As a second trained model.
Step A600, fixing the structural parameters of the second model, and selecting the structural parameters from a preset first network structural parameter candidate set to modify the first model;
step A700, the steps A200, A300 and A600 are executed in a circulating mode until all the parameters in the first network structure parameter candidate set are traversed, and the first model corresponding to the minimum average absolute error is selected as the trained first model.
That is, the Model is modified in the same manner as in the steps A400 and A5001Obtaining the network structure corresponding to the minimum error
Figure BDA0002452894000000112
As a trained first model.
And after the training of the first model and the second model is finished, outputting the optimal network structure and the corresponding parameters thereof.
2. Time-interval traffic flow trend prediction method based on deep learning
And S100, acquiring historical traffic flow data before the time t of a traffic observation point to be predicted and corresponding sampling time.
In this embodiment, the time to be predicted is t, and therefore, the acquired input data includes historical traffic flow data before the time t of the traffic observation point to be predicted and corresponding sampling time.
Step S200, the historical traffic flow data is standardized, and the standardized data is subjected to first-order difference to serve as first data.
In this embodiment, the acquired historical traffic flow data is normalized by a z-score method, and the normalized data is subjected to first order difference to serve as first data.
Step S300, extracting the characteristics of the first data by adopting a first model, and coding the corresponding sampling time through One-Hot; and splicing the coded sampling time and the extracted features.
In the embodiment, the characteristics of the first data are extracted through a first model, namely a characteristic extraction model, and the sampling time corresponding to the first data is coded through One-Hot; and splicing the coded sampling time and the extracted features.
And S400, obtaining the variable quantity of the traffic flow at the time t relative to the time t-1 through a second model based on the spliced characteristics, and obtaining the prediction result of the traffic flow data at the time t of the traffic observation point to be predicted by combining the traffic flow data at the time t-1.
In the embodiment, based on the characteristics after splicing, the variation trend, i.e. the variation, of the traffic flow at the time t relative to the time t-1 is obtained through a second model, i.e. a variation trend prediction model, and the prediction result of the traffic flow data at the time t of the traffic observation point to be predicted is obtained by combining the traffic flow data at the time t-1.
And S500, performing anti-standardization on the prediction result of the traffic observation point to be predicted at the time t to obtain a prediction value of the traffic flow at the time t.
In this embodiment, the normalized prediction result is denormalized to obtain a predicted value of the traffic flow at the time t of the traffic observation point to be predicted.
A time-share traffic flow trend prediction system based on deep learning according to a second embodiment of the present invention, as shown in fig. 2, includes: the device comprises a data acquisition module 100, a difference module 200, a splicing module 300, a prediction result acquisition module 400 and an anti-standardization output module 500;
the data acquisition module 100 is configured to acquire historical traffic flow data before a traffic observation point t to be predicted and corresponding sampling time;
the difference module 200 is configured to normalize the historical traffic flow data, and perform first-order difference on the normalized data to obtain first data;
the splicing module 300 is configured to extract the characteristics of the first data by using a first model, and encode the corresponding sampling time by One-Hot; splicing the coded sampling time and the extracted features;
the prediction result obtaining module 400 is configured to obtain, based on the spliced features, a variation of the traffic flow at the time t to the time t-1 through the second model, and obtain, in combination with traffic flow data at the time t-1, a prediction result of the traffic flow data at the time t of the traffic observation point to be predicted;
the anti-standardization output module 500 is configured to perform anti-standardization on the prediction result of the traffic observation point to be predicted at the time t to obtain a prediction value of the traffic flow at the time t;
the first model and the second model are constructed based on a deep learning model.
It can be clearly understood by those skilled in the art that, for convenience and brevity of description, the specific working process and related description of the system described above may refer to the corresponding process in the foregoing method embodiment, and details are not described herein again.
It should be noted that, the time-share traffic flow trend prediction system based on deep learning provided in the foregoing embodiment is only illustrated by the division of the above functional modules, and in practical applications, the above functions may be allocated to different functional modules according to needs, that is, the modules or steps in the embodiment of the present invention are further decomposed or combined, for example, the modules in the foregoing embodiment may be combined into one module, or may be further split into multiple sub-modules, so as to complete all or part of the above described functions. The names of the modules and steps involved in the embodiments of the present invention are only for distinguishing the modules or steps, and are not to be construed as limiting the present invention.
A storage device according to a third embodiment of the present invention stores therein a plurality of programs adapted to be loaded by a processor and to implement the above-described time-phased traffic flow tendency prediction method based on deep learning.
A processing apparatus according to a fourth embodiment of the present invention includes a processor, a storage device; a processor adapted to execute various programs; a storage device adapted to store a plurality of programs; the program is suitable for being loaded and executed by a processor to realize the deep learning-based time-share traffic flow trend prediction method.
It can be clearly understood by those skilled in the art that, for convenience and brevity of description, the specific working processes and related descriptions of the storage device and the processing device described above may refer to the corresponding processes in the foregoing method examples, and are not described herein again.
Referring now to FIG. 5, there is illustrated a block diagram of a computer system suitable for use as a server in implementing embodiments of the method, system, and apparatus of the present application. The server shown in fig. 5 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present application.
As shown in fig. 5, the computer system includes a Central Processing Unit (CPU)501 that can perform various appropriate actions and processes according to a program stored in a Read Only Memory (ROM) 502 or a program loaded from a storage section 508 into a Random Access Memory (RAM) 503. In the RAM 503, various programs and data necessary for system operation are also stored. The CPU 501, ROM 502, and RAM 503 are connected to each other via a bus 504. An Input/Output (I/O) interface 505 is also connected to bus 504.
The following components are connected to the I/O interface 505: an input portion 506 including a keyboard, a mouse, and the like; an output section 507 including a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and the like, a speaker, and the like; a storage section 508 including a hard disk and the like; and a communication section 509 including a Network interface card such as a LAN (Local Area Network) card, a modem, or the like. The communication section 509 performs communication processing via a network such as the internet. The driver 510 is also connected to the I/O interface 505 as necessary. A removable medium 511 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 510 as necessary, so that a computer program read out therefrom is mounted on the storage section 508 as necessary.
In particular, according to an embodiment of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program containing program code for performing the method illustrated by the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network through the communication section 509, and/or installed from the removable medium 511. The computer program performs the above-described functions defined in the method of the present application when executed by the Central Processing Unit (CPU) 501. It should be noted that the computer readable medium mentioned above in the present application may be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present application, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In this application, a computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, optical cable, RF, etc., or any suitable combination of the foregoing.
Computer program code for carrying out operations for aspects of the present application may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, Smalltalk, C + + or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or the connection may be made to an external computer (for example, through the Internet using an Internet service provider).
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present application. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The terms "first," "second," and the like are used for distinguishing between similar elements and not necessarily for describing or implying a particular order or sequence.
The terms "comprises," "comprising," or any other similar term are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus.
So far, the technical solutions of the present invention have been described in connection with the preferred embodiments shown in the accompanying drawings, but it is apparent that the scope of the present invention is not limited to these specific embodiments, as will be readily understood by those skilled in the art. Equivalent changes or substitutions of related technical features can be made by those skilled in the art without departing from the principle of the invention, and the technical scheme after the changes or substitutions can fall into the protection scope of the invention.

Claims (8)

1. A time-interval traffic flow trend prediction method based on deep learning is characterized by comprising the following steps:
step S100, obtaining historical traffic flow data before a traffic observation point t moment to be predicted and corresponding sampling time;
step S200, standardizing the historical traffic flow data, and performing first-order difference on the standardized data to obtain first data;
step S300, extracting the characteristics of the first data by adopting a first model, and coding the corresponding sampling time through One-Hot; splicing the coded sampling time and the extracted features;
s400, based on the spliced characteristics, obtaining the variable quantity of the traffic flow at the time t relative to the time t-1 through a second model, and obtaining the prediction result of the traffic flow data at the time t of the traffic observation point to be predicted by combining the traffic flow data at the time t-1;
step S500, carrying out anti-standardization on the prediction result of the traffic observation point to be predicted at the time t to obtain the prediction value of the traffic flow at the time t;
the first model and the second model are constructed on the basis of a deep learning network;
the training method of the first model and the second model is as follows:
a100, obtaining a training sample set, wherein the training sample set comprises a first data sample and a real traffic data flow data label at a moment to be predicted;
step A200, based on the first data sample of the training sample set, executing step S300 to splice the coded sampling time and the extracted features;
step A300, based on the spliced characteristics, executing the steps S400-S500 to obtain a predicted value of the traffic flow at the moment to be predicted; acquiring an average absolute prediction error through a preset prediction error calculation method based on the predicted value and the real traffic data flow data at the moment to be predicted;
step A400, fixing the network structure parameters of the first model, and selecting structure parameters from a preset second network structure parameter candidate set to modify the second model;
step A500, circularly executing the steps A300-A400 until all parameters in the second network structure parameter candidate set are traversed, selecting a second model corresponding to the minimum average absolute error as a trained second model, and skipping to the step A600;
step A600, fixing the structural parameters of the second model, and selecting the structural parameters from a preset first network structural parameter candidate set to modify the first model;
step A700, the steps A200, A300 and A600 are executed in a circulating mode until all the parameters in the first network structure parameter candidate set are traversed, and the first model corresponding to the minimum average absolute error is selected as the trained first model.
2. The deep learning-based time-share traffic flow tendency prediction method according to claim 1, wherein the traffic flow data includes a traffic flow, a vehicle traveling speed, a traffic flow density or an average number of vehicles in a lane, and an average traffic occupancy.
3. The method for predicting the traffic flow trend with time segments based on deep learning of claim 2, wherein in step S200, "the historical traffic flow data is normalized and the normalized data is first-order differenced", and the method comprises: and normalizing the historical traffic flow data by adopting a z-score normalization method, and performing first-order difference on the normalized data.
4. The deep learning-based time-segment traffic flow trend prediction method according to claim 1, wherein the prediction error method comprises:
Figure FDA0003141855900000021
wherein m' is the number of samples in the training sample set, MAE is the average absolute prediction error, y(p)For the real traffic data stream data at the time to be predicted,
Figure FDA0003141855900000022
p is a natural number representing a superscript for predicting the predicted value of the traffic flow at the time.
5. The method for predicting time-share traffic flow trend based on deep learning of claim 4, wherein in step S300, "the sampling time corresponding to the time-share traffic flow trend is encoded by One-Hot", and the method comprises:
Figure FDA0003141855900000031
wherein the content of the first and second substances,
Figure FDA0003141855900000032
the code corresponding to the kth sample time of the ith sample is indicated, i denotes the index.
6. A time-share traffic flow trend prediction system based on deep learning is characterized by comprising the following components: the device comprises a data acquisition module, a difference module, a splicing module, a prediction result acquisition module and an anti-standardization output module;
the data acquisition module is configured to acquire historical traffic flow data before a traffic observation point t to be predicted and corresponding sampling time;
the difference module is configured to standardize the historical traffic flow data and perform first-order difference on the standardized data to serve as first data;
the splicing module is configured to extract the characteristics of the first data by adopting a first model and encode the corresponding sampling time through One-Hot; splicing the coded sampling time and the extracted features;
the prediction result acquisition module is configured to obtain the variation of the traffic flow at the t moment to the t-1 moment through the second model based on the spliced features, and obtain the prediction result of the traffic flow data at the t moment of the to-be-predicted traffic observation point by combining the traffic flow data at the t-1 moment;
the anti-standardization output module is configured to perform anti-standardization on the prediction result of the traffic observation point to be predicted at the time t to obtain a prediction value of the traffic flow at the time t;
the first model and the second model are constructed based on a deep learning model;
the training method of the first model and the second model is as follows:
a100, obtaining a training sample set, wherein the training sample set comprises a first data sample and a real traffic data flow data label at a moment to be predicted;
step A200, based on the first data sample of the training sample set, executing step S300 to splice the coded sampling time and the extracted features;
step A300, based on the spliced characteristics, executing the steps S400-S500 to obtain a predicted value of the traffic flow at the moment to be predicted; acquiring an average absolute prediction error through a preset prediction error calculation method based on the predicted value and the real traffic data flow data at the moment to be predicted;
step A400, fixing the network structure parameters of the first model, and selecting structure parameters from a preset second network structure parameter candidate set to modify the second model;
step A500, circularly executing the steps A300-A400 until all parameters in the second network structure parameter candidate set are traversed, selecting a second model corresponding to the minimum average absolute error as a trained second model, and skipping to the step A600;
step A600, fixing the structural parameters of the second model, and selecting the structural parameters from a preset first network structural parameter candidate set to modify the first model;
step A700, the steps A200, A300 and A600 are executed in a circulating mode until all the parameters in the first network structure parameter candidate set are traversed, and the first model corresponding to the minimum average absolute error is selected as the trained first model.
7. A storage device having stored therein a plurality of programs, wherein the program applications are loaded and executed by a processor to implement the deep learning based time-share traffic flow tendency prediction method according to any one of claims 1 to 5.
8. A processing device comprising a processor, a storage device; a processor adapted to execute various programs; a storage device adapted to store a plurality of programs; wherein the program is adapted to be loaded and executed by a processor to implement the method for forecasting time-share traffic flow tendency based on deep learning according to any one of claims 1 to 5.
CN202010297850.8A 2020-04-16 2020-04-16 Time-interval traffic flow trend prediction method, system and device based on deep learning Active CN111508230B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010297850.8A CN111508230B (en) 2020-04-16 2020-04-16 Time-interval traffic flow trend prediction method, system and device based on deep learning

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010297850.8A CN111508230B (en) 2020-04-16 2020-04-16 Time-interval traffic flow trend prediction method, system and device based on deep learning

Publications (2)

Publication Number Publication Date
CN111508230A CN111508230A (en) 2020-08-07
CN111508230B true CN111508230B (en) 2021-08-20

Family

ID=71864735

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010297850.8A Active CN111508230B (en) 2020-04-16 2020-04-16 Time-interval traffic flow trend prediction method, system and device based on deep learning

Country Status (1)

Country Link
CN (1) CN111508230B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112257918B (en) * 2020-10-19 2021-06-22 中国科学院自动化研究所 Traffic flow prediction method based on circulating neural network with embedded attention mechanism
CN112489420B (en) * 2020-11-17 2022-06-21 中国科学院深圳先进技术研究院 Road traffic state prediction method, system, terminal and storage medium
CN115410386B (en) * 2022-09-05 2024-02-06 同盾科技有限公司 Short-time speed prediction method and device, computer storage medium and electronic equipment
CN116558541B (en) * 2023-07-11 2023-09-22 新石器慧通(北京)科技有限公司 Model training method and device, and track prediction method and device

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108062561A (en) * 2017-12-05 2018-05-22 华南理工大学 A kind of short time data stream Forecasting Methodology based on long memory network model in short-term
JP2018180907A (en) * 2017-04-12 2018-11-15 富士通株式会社 Traffic prediction program, traffic prediction apparatus, and traffic prediction method
CN110675623A (en) * 2019-09-06 2020-01-10 中国科学院自动化研究所 Short-term traffic flow prediction method, system and device based on hybrid deep learning

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2018180907A (en) * 2017-04-12 2018-11-15 富士通株式会社 Traffic prediction program, traffic prediction apparatus, and traffic prediction method
CN108062561A (en) * 2017-12-05 2018-05-22 华南理工大学 A kind of short time data stream Forecasting Methodology based on long memory network model in short-term
CN110675623A (en) * 2019-09-06 2020-01-10 中国科学院自动化研究所 Short-term traffic flow prediction method, system and device based on hybrid deep learning

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
"基于图卷积神经网络和注意力机制的短时交通流";李志帅等;《交通工程》;20190831;第19卷(第4期);第15-19、28页 *

Also Published As

Publication number Publication date
CN111508230A (en) 2020-08-07

Similar Documents

Publication Publication Date Title
CN111508230B (en) Time-interval traffic flow trend prediction method, system and device based on deep learning
CN110889546B (en) Attention mechanism-based traffic flow model training method
Dong et al. Characterizing driving styles with deep learning
Dou et al. A hybrid CEEMD-GMM scheme for enhancing the detection of traffic flow on highways
CN116504076A (en) Expressway traffic flow prediction method based on ETC portal data
CN114664091A (en) Early warning method and system based on holiday traffic prediction algorithm
Matarazzo et al. Crowdsourcing bridge dynamic monitoring with smartphone vehicle trips
CN111582559A (en) Method and device for estimating arrival time
CN111397625A (en) Vehicle navigation method and related device
CN110895879A (en) Method and device for detecting co-running vehicle, storage medium and electronic device
CN113903409A (en) Molecular data processing method, model construction and prediction method and related device
Yi et al. VDS data-based deep learning approach for traffic forecasting using LSTM network
Nguyen et al. Deep learning system for travel speed predictions on multiple arterial road segments
CN114872730A (en) Vehicle driving track prediction method and device, automobile and storage medium
CN111582589A (en) Car rental insurance prediction method, device, equipment and storage medium
Yu et al. A Hybrid Model for Short‐Term Traffic Flow Prediction Based on Variational Mode Decomposition, Wavelet Threshold Denoising, and Long Short‐Term Memory Neural Network
Kim et al. A hybrid approach based on variational mode decomposition for analyzing and predicting urban travel speed
Ciaburro Time series data analysis using deep learning methods for smart cities monitoring
CN117251722A (en) Intelligent traffic management system based on big data
Li et al. TSDCN: Traffic safety state deep clustering network for real‐time traffic crash‐prediction
Yang et al. Vehicular trajectory big data: Driving behavior recognition algorithm based on deep learning
CN114416686A (en) Vehicle equipment fingerprint CARID identification system and identification method
CN113284337A (en) OD matrix calculation method and device based on vehicle track multidimensional data
CN113077079A (en) Data-driven rail transit new line access passenger flow prediction method
CN111626508A (en) Rail transit vehicle-mounted data prediction method based on xgboost model

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant