A Highway Lane-Level Speed Prediction Method Based on Multi-Source Data Fusion
By introducing GRG and Attention mechanisms into lane-level speed prediction and combining them with the GRU_LSTM model, the problem of unconsidered inter-lane interactions is solved, resulting in more accurate speed prediction and supporting traffic management and intelligent driving.
Patent Information
- Application Number
- CN202311111518.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-08-31
- Publication Date
- 2025-10-31
- Estimated Expiration
- 2043-08-31
AI Technical Summary
Existing lane-level speed prediction methods fail to effectively consider the mutual influence between lanes, resulting in low predicted speeds and poor accuracy.
An improved model, GRGA, is established by using a multi-source data fusion method to calculate the inter-lane mutual influence degree through GRG and combining the Attention mechanism and the GRU_LSTM model to predict the lane-level speed of highways.
It improves the accuracy of lane-level speed prediction, providing a more practical solution for traffic management and intelligent driving.
Smart Images

Figure CN117012039B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of information prediction technology, specifically relating to a method for predicting highway lane-level speed based on multi-source data fusion. Background Technology
[0002] With economic development, people have increasingly higher demands for travel quality, leading more and more people to choose highways. The extensive use of highways has resulted in a huge traffic load, and existing transportation infrastructure can no longer meet the growing travel needs. The contradiction between traffic supply and demand is intensifying, leading to congestion. Furthermore, abnormal events such as traffic accidents, severe weather, and construction on highways make them more prone to congestion and queues.
[0003] Current traffic flow prediction methods can be broadly categorized into two types: those based on mathematical models and those based on data. Mathematical models primarily rely on statistical methods, such as mean, median, and moving average, with further improvements. Data-based methods mainly utilize machine learning and deep learning, such as decision trees, random forests, Long Short-Term Memory (LSTM) networks, and Gated Recurrent Units (GRUs). Patent CN202110124221.X, based on convolutional LSTM prediction, uses millimeter-wave radar as the data acquisition device. It considers average speed, headway, distance between vehicles, spatial occupancy, temporal occupancy, and the 85th percentile speed to predict the speed changes of each target lane. While it considers the influence of spatiotemporal factors, it directly uses data from different lanes as spatial input without considering the varying impacts of different lane positions on the target lanes being predicted. This reduces model complexity but increases time complexity, decreasing prediction speed and accuracy.
[0004] By comprehensively considering the overall characteristics of traffic flow, including the correlation between lanes, we can better understand the interactions between lanes and provide more representative and robust input data for prediction models. Therefore, future research in lane-level highway speed prediction should focus on the mutual influence between lanes. By considering traffic cooperation between lanes, we can conduct more comprehensive and accurate prediction model research, providing more practical solutions for applications in traffic management and intelligent driving. Summary of the Invention
[0005] In view of this, the purpose of this invention is to provide a highway lane-level speed prediction method based on multi-source data fusion. This invention aims to solve the problems of low predicted speed, poor accuracy, and failure to consider the mutual influence between lanes in existing lane-level speed prediction methods.
[0006] To achieve the above objectives, this invention provides a method for predicting lane-level speeds on highways based on multi-source data fusion, comprising the following steps:
[0007] S1. Divide the lanes according to the distribution of the detection equipment and extract the data collected by the detection equipment in each lane;
[0008] S2. Use GRG to calculate the mutual influence between different lanes;
[0009] S3. Use the Attention mechanism to calculate the attention weights of the target lane at different times;
[0010] S4. Based on the attention weights calculated by the attention mechanism and the mutual influence between different lanes calculated by GRG, an improved model GRGA is established;
[0011] S5. Based on the improved model GRGA, establish a GRU_LSTM fusion deep learning model;
[0012] S6. Based on the GRU_LSTM fusion deep learning model established in step S5, predict the average driving speed of any lane on the highway within a specific time period in real time.
[0013] Furthermore, step S2 includes defining the grey relational coefficient, and the calculation expression is as follows:
[0014]
[0015]
[0016] Δ min(t) =min a min c |v la (t)-v lc (t)|
[0017] In the formula, Δ min The minimum difference between the two poles; Δ max The maximum difference between the two poles; ρ is the resolution coefficient, which is generally taken as 0.5; Represents the target lane speed; This represents the average speed of the c-th candidate lane within the observed road segment.
[0018] Furthermore, step S3 includes the following sub-steps:
[0019] S3.1 uses lane speed as a feature for each time period;
[0020] S3.2 introduces an attention mechanism to calculate the data weights a within time t. i ;
[0021] a i =align(h i ,s0),i=1,2,...,t
[0022] In the formula, h i It is the hidden state sequence obtained by the Encoder encoding the velocity input at different time steps; s0 is the state of the decoder at the current time step;
[0023] S3.3 Based on the decoder's state s0 and the hidden state h at each time step in the input sequence i The correlation between them is used to adjust attention allocation and calculate attention weight b. i ;
[0024]
[0025] In the formula, w is the weight matrix; T is the total duration of the statistical data; v T For parameter matrices;
[0026] S3.4 The attention weight vectors b1, b2...b i The data is fed into the softmax function for normalization.
[0027] [a1,a2,...a i ] = softmax([b1,b2,...,b i ]).
[0028] Furthermore, step S4 includes the following sub-steps:
[0029] S4.1 Improved Grey Relational Equation: The influence between different time periods of the same lane calculated by the attention mechanism is imported into the grey relational equation;
[0030] The improved grey relational equation is:
[0031]
[0032] In the formula, c i Represents candidate lanes; t i Indicates a certain period of time;
[0033] The improved weights in S4.2 are multiplied by the average gray-level correlation to obtain the gray attention correlation (GRGA).
[0034]
[0035] S4.3 Normalizes the GRGA values;
[0036]
[0037] In the formula, GRGA(c) i The weighting coefficient represents the importance of each lane.
[0038] Furthermore, step S5 includes the following sub-steps:
[0039] S5.1 Introduce the importance weighting coefficients from step S4.3 into the input matrix V. i (t);
[0040]
[0041]
[0042] S5.2 Establish the GRU model and calculate the expression as follows:
[0043]
[0044] z t =σ(W z X t +U z H t-1 +b z )
[0045] r t =σ(W r X t +U r H t-1 +b r )
[0046]
[0047]
[0048] In the formula, z t It's an update gate; r t It's a door reset; This is a new candidate hidden state; X t It is the weighted velocity value that changes over time; W z W r W h W y U z U r U h b is the weight matrix; z ,b r ,b h It is the bias vector;
[0049] S5.3 Establishing an LSTM Model
[0050]
[0051] f t =σ(W f X t +U f h t-1 +b f )
[0052] i t =σ(W i X t +U i h t-1 +b i )
[0053] o t =σ(W o X t +U o h t-1 +b o )
[0054]
[0055]
[0056]
[0057] In the formula, i t It is an input gate; f t It is the Gate of Oblivion; t It is an output gate; This is the state of a new candidate cell; c t It refers to the cellular state; h t It is the hidden state at the current moment; W f W i W o and W c The weight matrix is used for calculating the hidden layer; U f U i U o and U c b is the weight matrix between the previous and subsequent time periods; f ,b i ,b c and b o σ is the bias vector; σ is the activation function that controls the data flow within the range [0,1]; tanh is the nonlinear activation function that controls the data flow within the range [-1,1].
[0058] S5.4 adds a fully connected layer to integrate the outputs of the GRU and LSTM models;
[0059] y = W yh h t +by
[0060] In the formula, W yh b is the weight matrix; y y is the bias vector; y is the output of the GRU_LSTM neural network;
[0061] S5.5 collects highway lane-level driving data and repeatedly iterates the training of the GRU_LSTM neural network model until the loss converges and the prediction accuracy meets the requirements, thus obtaining the GRU_LSTM fusion deep learning model.
[0062] Furthermore, in step S5, the calculation expression for the activation function σ is as follows:
[0063]
[0064] Furthermore, in step S5, the calculation expression for the nonlinear activation function tanh is as follows:
[0065]
[0066] Furthermore, all data collected by the detection equipment must be preprocessed.
[0067] The beneficial effects of this invention are as follows:
[0068] This invention proposes a novel model for calculating the speed relationship between lanes, incorporating an attention mechanism and utilizing machine learning methods to quantify the speed between lanes, thereby mitigating the drawbacks of external factors and the grey joint analysis algorithm itself. Furthermore, based on existing LSTM and GRU models, it considers actual traffic conditions by introducing a quantized coefficient matrix into the original model, thus characterizing speed changes during vehicle operation. This establishes a GRU_LSTM fusion deep learning speed prediction model based on the improved GRGA model. This invention can accurately predict the speed changes of a specific lane on a highway, providing a reference for traffic control personnel in traffic guidance.
[0069] Other advantages, objectives, and features of the invention will be set forth in part in the description which follows, and in part will be apparent to those skilled in the art from the following examination, or may be learned from practice of the invention. The objectives and other advantages of the invention can be realized and obtained through the following description. Attached Figure Description
[0070] Figure 1 This is a flowchart of a highway lane-level speed prediction method based on multi-source data fusion according to the present invention;
[0071] Figure 2 Lane division diagram;
[0072] Figure 3 A schematic diagram illustrating GRGA;
[0073] Figure 4 This is a schematic diagram of the structure of the GRU_LSTM fused deep learning model. Detailed Implementation
[0074] To make the technical solutions, advantages, and objectives of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of the present invention. All other embodiments obtained by those skilled in the art based on the described embodiments of the present invention without creative effort are within the protection scope of this application.
[0075] Highways are divided into three types: two-way four-lane, two-way six-lane, and two-way eight-lane. The highway surface includes several major parts such as main road, ramps, and auxiliary lanes. For highways, the average speed of a lane within a certain period of time will be affected by the front, rear, left, and right sides. Therefore, to make lane-level speed prediction, it is necessary to consider the mutual influence between lanes.
[0076] like Figure 1 As shown, this invention provides a method for predicting lane-level speeds on highways based on multi-source data fusion, comprising the following steps:
[0077] S1. Divide the lanes according to the distribution of the detection equipment, extract the data collected by the detection equipment in each lane, and preprocess the data collected by the detection equipment.
[0078] This embodiment studies the mutual influence between adjacent lanes in a two-way four-lane road system, thereby improving the accuracy of speed prediction for the target lane. For example... Figure 2 As shown, the lanes are first divided, assuming l a For the target lane, l c For each adjacent candidate lane, each detection device should be approximately 150m apart, taking the average speed of 10 lanes as an example.
[0079] S2. For each time step, use GRG to calculate the degree of mutual influence between different lanes;
[0080] The grey relational coefficient is defined and calculated as follows:
[0081]
[0082]
[0083] Δmin(t) =min a min c |v la (t)-v lc (t)|
[0084] In the formula, Δ min The minimum difference between the two poles; Δ max The maximum difference between the two poles; ρ is the resolution coefficient, which is generally taken as 0.5; Represents the target lane speed; This represents the average speed of the c-th candidate lane within the observed road segment.
[0085] S3. For each time step, use the Attention mechanism to calculate the attention weights of the target lane at different times;
[0086] To reduce the impact of abnormal vehicle behavior on inter-lane interactions, it is necessary to calculate the weights of the grey relational coefficients. Furthermore, since the speeds of the same lane at different times have influence relationships, the grey relational density equation should incorporate these influencing factors and introduce an attention mechanism. Taking the fast lane as an example, to reduce the impact of sudden situations on the overall data and considering the nonlinearity of lane relationships and the timeliness of congestion prediction, an improved GRG (grey relational analysis) model based on dynamic factors, GRGA (grey relational analysis based on attention mechanism), is established.
[0087] S3.1 uses lane speed as a feature for each time period. The feature for each time period is represented as a query (Q), key (K), and value (V). Here, the query and key can be the same feature, while the value is the vehicle speed information.
[0088] S3.2 introduces an attention mechanism to calculate the data weights a within time t. i ;
[0089] The input to the attention mechanism includes the decoder state of the current decoding step (usually denoted as "s0") and the sequence of hidden states of the encoder. This is done after the encoder has received the last state vector h. t At this time, the decoder and attention will start working simultaneously, calculating s0 and each state h1, h2, ..., h t The correlation is calculated using the following expression:
[0090] a i =align(h i ,s0),i=1,2,...,t
[0091] In the formula, h iIt is the hidden state sequence obtained by the Encoder encoding the velocity input at different time steps; s0 is the state of the decoder at the current time step;
[0092] S3.3 Based on the decoder's state s0 and the hidden state h at each time step in the input sequence i The correlation between them is used to adjust attention allocation and calculate attention weight b. i ;
[0093] This adjustment process involves h i The attention vector is inner-productted with s0 to obtain a higher-dimensional vector, which is then multiplied by matrix w. This resulting vector is fed into the tanh activation function, ensuring that each value of the new vector falls within the interval [-1, 1]. This attention vector is used to weighted summation of the hidden states at different time steps of the input sequence, providing information about different time periods of the input sequence for more accurate decision-making when generating elements of the target sequence. Attention weight b i The calculation expression is as follows:
[0094]
[0095] In the formula, h i The hidden state of velocity over a period of time is determined by input data. and The result is s0 = h m w is the weight matrix; T is the total duration of the statistical data; v T For parameter matrices;
[0096] S3.4 The attention weight vectors b1, b2...b i The samples are fed into the softmax function for normalization to ensure they satisfy the properties of a probability distribution, thus constructing reasonable velocity weights α. i ;
[0097] [a1,a2,...a i ] = softmax([b1,b2,...,b i ]).
[0098] S4. Based on the attention weights calculated using the attention mechanism and the mutual influence between different lanes calculated using GRG, an improved model GRGA is established, such as... Figure 3 As shown;
[0099] S4.1 Improved Grey Relational Equation: The influence between different time periods of the same lane calculated by the attention mechanism is imported into the grey relational equation;
[0100] The improved grey relational equation is:
[0101]
[0102] In the formula, c i Represents candidate lanes; t i Indicates a certain period of time;
[0103] The improved weights in S4.2 are multiplied by the average gray-level correlation to obtain the gray attention correlation (GRGA), which is the average gray-level correlation of all candidate lanes.
[0104] This value reflects the influence between different lanes at the same time and the mutual influence of the same lane at different times. Quantifying this influence provides the basis for the predictions mentioned later. The calculation expression for GRGA is as follows:
[0105]
[0106] S4.3 Normalizes the GRGA values;
[0107]
[0108] In the formula, GRGA(c) i The weighting coefficient represents the importance of each lane.
[0109] S5. Based on the improved GRGA model, establish a GRU_LSTM fusion deep learning model, such as... Figure 4 As shown;
[0110] To overcome the gradient vanishing problem of traditional RNNs, GRU-LSTM is introduced to predict the speed of this lane segment.
[0111] S5.1 Introduce the importance weighting coefficients from step S4.3 into the input matrix V. i (t);
[0112]
[0113]
[0114] S5.2 establishes the GRU model,
[0115] The GRU model is used to capture patterns and long-term dependencies in sequence data. The output of the GRU layer is gru_output, which has a shape of (batch_size, timesteps, gru_units), where gru_units is the number of neurons in the GRU layer.
[0116] Obtain the input matrix V from step S5.1 i(t), taking the matrix as input to the encoder layer, uses GRU neurons to capture patterns and long-term dependencies in the sequence data. The output calculation expression is as follows:
[0117]
[0118] z t =σ(W z X t +U z H t-1 +b z )
[0119] r t =σ(W r X t +U r H t-1 +b r )
[0120]
[0121]
[0122] In the formula, z t It's an update gate; r t It's a door reset; This is a new candidate hidden state; X t It is the weighted velocity value that changes over time; W z W r W h W y U z U r U h b is the weight matrix; z ,b r ,b h It is the bias vector;
[0123] S5.3 Establish an LSTM model to introduce the memory and forgetting mechanism of LSTM, aiming to capture the spatiotemporal characteristics of the input variables.
[0124] The output of the LSTM layer is lstm_output, with a shape of (batch_size, timesteps, lstm_units), where lstm_units is the number of neurons in the LSTM layer.
[0125] The LSTM layer primarily improves the prediction accuracy of sequence data by receiving the output from the GRU layer and capturing the spatiotemporal features in the sequence data. This is achieved by obtaining the output H in S5.2. t Then, using this as input, the computation expression output by the LSTM layer is as follows:
[0126]
[0127] f t =σ(W f X t +U f h t-1 +b f )
[0128] i t =σ(W i X t +U i h t-1 +b i )
[0129] o t =σ(W o X t +U o h t-1 +b o )
[0130]
[0131]
[0132]
[0133] In the formula, i t It is an input gate; f t It is the Gate of Oblivion; t It is an output gate; This is the state of a new candidate cell; c t It refers to the cellular state; h t It is the hidden state at the current moment; W f W i W o and W c The weight matrix is used for calculating the hidden layer; U f U i U o and U c b is the weight matrix between the previous and subsequent time periods; f ,b i ,b c and b o σ is the bias vector; σ is the activation function that controls the data flow within the range [0,1]; tanh is the nonlinear activation function that controls the data flow within the range [-1,1].
[0134] The expression for calculating the activation function σ is as follows:
[0135] The expression for calculating the nonlinear activation function tanh is as follows:
[0136] S5.4 adds a fully connected layer that integrates the outputs of the GRU and LSTM models, mapping the outputs of the GRU and LSTM layers to the desired output size;
[0137] After the GRU and LSTM layers, there are two outputs, gru_output and lstm_output. These outputs are concatenated with the features to form a matrix containing multiple time steps. This matrix can be flattened and converted into a matrix. Therefore, the output of the fully connected layer can be represented as:
[0138] y = W yh h t +b y
[0139] In the formula, W yh b is the weight matrix; y y is the bias vector; y is the output of the GRU_LSTM neural network;
[0140] S5.5 collects highway lane-level driving data and repeatedly iterates the training of the GRU_LSTM neural network model until the loss converges and the prediction accuracy meets the requirements, thus obtaining the GRU_LSTM fusion deep learning model.
[0141] S6. Based on the GRU_LSTM fusion deep learning model established in step S5, predict the average driving speed of any lane on the highway within a specific time period in real time.
[0142] S6.1 Based on data obtained from various detection devices on the highway, the average vehicle speed sequence data for a specific lane and a specific time period is extracted, and the raw data is preprocessed such as cleaning and smoothing to obtain clean and stable time series sample data.
[0143] S6.2 Input the preprocessed time series sample data into the constructed GRU_LSTM fusion deep learning model. Through the calculation of the neural network model, the predicted average driving speed of the target lane in time period t can be obtained.
[0144] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the present invention, and all such modifications or substitutions should be covered within the protection scope of the present invention.
Claims
1. A method for predicting lane-level speed on highways based on multi-source data fusion, characterized in that, Includes the following steps: S1. Divide the lanes according to the distribution of the detection equipment and extract the data collected by the detection equipment in each lane; S2. Use GRG to calculate the mutual influence between different lanes; Step S2 includes defining the grey relational coefficient, and the calculation expression is as follows: Δ min (t)=min a min c |v la (t)-v lc (t)| In the formula, Δ min The minimum difference between the two poles; Δ max The maximum difference between the two poles; ρ is the resolution coefficient, which is generally taken as 0.5; Represents the target lane speed; This represents the average vehicle speed of the c-th candidate lane within the observed road segment; S3. Use the Attention mechanism to calculate the attention weights of the target lane at different times; Step S3 includes the following sub-steps: S3.1 uses lane speed as a feature for each time period; S3.2 introduces an attention mechanism to calculate the data weights a within time t. i ; a i =align(h i ,s0),i=1,2,...,t In the formula, h i It is the hidden state sequence obtained by the Encoder encoding the velocity input at different time steps; s0 is the state of the decoder at the current time step; S3.3 Based on the decoder's state s0 and the hidden state h at each time step in the input sequence i The correlation between them is used to adjust attention allocation and calculate attention weight b. i ; In the formula, w is the weight matrix; T is the total duration of the statistical data; v T For parameter matrices; S3.4 The attention weight vectors b1, b2...b i The data is fed into the softmax function for normalization. [a1,a2,...a i ]=softmax([b1,b2,....,b i ]) S4. Based on the attention weights calculated by the attention mechanism and the mutual influence between different lanes calculated by GRG, an improved model GRGA is established; Step S4 includes the following sub-steps: S4.1 Improved Grey Relational Equation: The influence between different time periods of the same lane calculated by the attention mechanism is imported into the grey relational equation; The improved grey relational equation is: In the formula, c i Representing candidate lanes; t i Indicates a certain period of time; The improved weights in S4.2 are multiplied by the average gray-level correlation to obtain the gray attention correlation (GRGA). S4.3 Normalizes the GRGA values; In the formula, GRGA(c) i A weighting coefficient representing the importance of each lane; S5. Based on the improved model GRGA, establish a GRU_LSTM fusion deep learning model; Step S5 includes the following sub-steps: S5.1 Introduce the importance weighting coefficients from step S4.3 into the input matrix V. i (t); S5.2 Establish the GRU model and calculate the expression as follows: z t =σ(W z X t +U z H t-1 +b z ) r t =σ(W r X t +U r H t-1 +b r ) In the formula, z t It's an update gate; r t It's a door reset; This is a new candidate hidden state; X t It is the weighted velocity value that changes over time; W z W r W h U z U r U h b is the weight matrix; z ,b r ,b h It is the bias vector; S5.3 Establishing an LSTM Model f t =σ(W f X t +U f h t-1 +b f ) i t =σ(W i X t +U i h t-1 +b i ) the t =σ(W o X t +U o h t-1 +b o ) In the formula, i t It is an input gate; f t It is the Gate of Oblivion; t It is an output gate; This is the state of a new candidate cell; c t It refers to the cellular state; h t It is the hidden state at the current moment; W f W i W o and W c The weight matrix is used for calculating the hidden layer; U f U i U o and U c b is the weight matrix between the previous and subsequent time periods; f ,b i ,b c and b o σ is the bias vector; σ is the activation function that controls the data flow within the range [0,1]; tanh is the nonlinear activation function that controls the data flow within the range [-1,1]. S5.4 adds a fully connected layer to integrate the outputs of the GRU and LSTM models; y=W yh h t +b y In the formula, W yh b is the weight matrix; y y is the bias vector; y is the output of the GRU_LSTM neural network; S5.5 Collect highway lane-level driving data and repeatedly iterate the training of the GRU_LSTM neural network model until the loss converges and the prediction accuracy meets the requirements, thus obtaining the GRU_LSTM fusion deep learning model. S6. Based on the GRU_LSTM fusion deep learning model established in step S5, predict the average driving speed of any lane on the highway within a specific time period in real time.
2. The method for predicting highway lane-level speed based on multi-source data fusion according to claim 1, characterized in that: In step S5, the calculation expression for the activation function σ is as follows:
3. The method for predicting highway lane-level speed based on multi-source data fusion according to claim 1, characterized in that: In step S5, the expression for calculating the nonlinear activation function tanh is as follows:
4. The method for predicting highway lane-level speed based on multi-source data fusion according to claim 1, characterized in that: All data collected by the detection equipment must be preprocessed.
Citation Information
Patent Citations
Expressway lane-level running speed prediction method based on spatio-temporal information
CN112907956A
Urban traffic road section speed prediction method and system based on multi-road-section space-time correlation
CN111080029A
Ground road lane-level traffic flow prediction method based on space-time attention mechanism
CN112926768A