Vehicle lane changing behavior prediction method under lane changing maneuver constraint
By screening key features in vehicle lane change behavior prediction and building an improved Transformer module, combining Bagging algorithm and Softmax layer, the shortcomings in feature selection and prior knowledge utilization of existing models are solved, and more efficient and accurate lane change behavior prediction is achieved.
Patent Information
- Application Number
- CN202411968015.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-30
- Publication Date
- 2025-04-25
AI Technical Summary
The existing Transformer model lacks an effective feature selection mechanism in the prediction of vehicle lane change behavior, resulting in increased information redundancy and computational complexity, while there is room for improvement in utilizing prior knowledge related to lane change behavior.
A lane change behavior prediction method combining feature selection mechanism and scene-specific prior knowledge is proposed. By screening key features in the historical data of vehicle lane change behavior, an improved Transformer module is constructed, and a lane change behavior prediction model is constructed by combining Bagging algorithm and Softmax layer.
It effectively improves the accuracy and computing efficiency of the prediction of lane-changing behavior, reduces data redundancy, enhances the model's adaptability to complex scenarios, and improves the timeliness and accuracy of predictions.
Smart Images

Figure CN119884951A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of intelligent transportation technology, and more specifically, relates to a method for predicting vehicle lane-changing behavior under lane-changing maneuver constraints. Background Art
[0002] Lane changing behavior is a key factor affecting road traffic safety, especially in the application scenario of autonomous driving technology. Statistics from the National Highway Traffic Safety Administration (NHTSA) show that traffic accidents involving autonomous vehicles account for 57% of the total number of accidents, of which up to 35% are caused by improper lane changing behavior. In order to significantly improve the safety of autonomous vehicles, the autonomous driving system needs to be able to accurately perceive the dynamic information of surrounding vehicles in real time and make adjustments in a very short time. Developing an accurate and efficient vehicle lane changing behavior prediction model is crucial to improving the safety and reliability of the autonomous driving system, and has become an important research direction in the current intelligent transportation field.
[0003] Existing vehicle lane-changing behavior prediction models are mainly divided into traditional models and deep learning-based models. Traditional models such as hidden Markov models (HMM), support vector machines (SVM) and dynamic Bayesian networks (DBN) can model the temporal dynamic characteristics of lane-changing behavior and are suitable for capturing driving state transitions or temporal dependencies. However, these methods rely heavily on expert knowledge, making it difficult to dynamically model complex long-term dependencies, and have limited generalization capabilities when faced with highly nonlinear and dynamic traffic scenarios. Deep learning-based models such as convolutional neural networks (CNN), long short-term memory networks (LSTM) and graph neural networks (GNN) have advantages in capturing local spatial features, temporal dependencies and multi-vehicle interactions, but they still have bottlenecks in global dependency modeling, computational efficiency and training speed. In recent years, the Transformer model has become a research hotspot for lane-changing behavior prediction due to its parallel computing capabilities and excellent global dependency modeling capabilities. Related studies such as LCAM-Transformer and Residual-Transformer have improved prediction accuracy by combining vehicle dynamics and interaction features. However, the existing Transformer model lacks an effective feature selection mechanism, which easily leads to information redundancy and increases computational complexity. At the same time, there is still much room for improvement in utilizing prior knowledge related to lane-changing behavior. Therefore, in order to solve the above problems, it is urgent to develop a lane-changing behavior prediction model that can combine feature selection mechanism with scene-specific prior knowledge, so as to improve prediction accuracy and optimize computational efficiency. Summary of the invention
[0004] The purpose of the present invention is to overcome the shortcomings of the prior art and provide a method for predicting vehicle lane changing behavior under lane changing maneuver constraints. A lane changing behavior prediction model is constructed based on an improved Transformer module, combining the target vehicle's own characteristics and its interaction characteristics with surrounding vehicles, so as to effectively improve the accuracy and computational efficiency of lane changing behavior prediction.
[0005] In order to achieve the above-mentioned object of the invention, the vehicle lane changing behavior prediction method under lane changing maneuver constraints of the present invention comprises the following steps:
[0006] S1: K lane-changing behavior history data of vehicles are collected according to actual needs to form a historical data set. Each lane-changing behavior history data contains lane-changing behavior feature data of T consecutive moments and the lane-changing behavior type adopted at each moment. The lane-changing behavior feature data includes the self-features of the target vehicle at the corresponding moment and the interactive features of the surrounding vehicles. The self-features of the target vehicle include speed, acceleration, position coordinates, lane width, height, and lane ID. The interactive features of the target vehicle and the surrounding vehicles include the distance difference and speed difference between the target vehicle and the surrounding vehicles. The lane-changing behavior types include left lane change, right lane change, and lane keeping.
[0007] S2: Filter out key features from the lane-changing behavior characteristics based on the historical data of the vehicle's lane-changing behavior. The number of the target vehicle's own features in the key features is N, and the number of the target vehicle's interaction features with surrounding vehicles is M.
[0008] S3: Extract N self-features of the target vehicle from each lane-changing behavior history data of the historical data set to form its own features Extract M interactive features between the target vehicle and surrounding vehicles to form interactive features Determine the corresponding T-dimensional maneuver judgment result vector according to the lane-changing behavior type If the target vehicle in the lane-changing behavior history data adopts a lane-changing operation, then the maneuver judgment result g corresponding to the t-th moment is t = 1, if lane keeping operation is adopted, then the maneuver judgment result g corresponding to the tth moment t =0, t=1,2,…,T;
[0009] Each interactive feature S and maneuver judgment result vector G is taken as a lane-changing maneuver sample, thereby constructing a lane-changing maneuver sample set;
[0010] Concatenate each vehicle H with the maneuver judgment result vector G to obtain the target vehicle feature The target vehicle feature C and the interaction feature S are used as input, and a lane-changing behavior type vector A is constructed according to the lane-changing behavior type at each moment as the expected output, forming a lane-changing behavior training sample, thereby constructing a lane-changing behavior training sample set;
[0011] S4: Based on the lane-changing maneuver sample set, a Bagging algorithm is used to train D lane-changing maneuver decision trees, where D is set according to actual needs, thereby constructing a lane-changing maneuver judgment model;
[0012] S5: Construct a lane-changing behavior prediction model, including a Transformer module, a fully connected layer, and a Softmax layer, where:
[0013] The Transformer module is used to extract the target vehicle feature C and the interaction feature S, obtain the lane-changing behavior feature R and send it to the fully connected layer; the Transformer module includes a first multi-head attention module, a first feedforward network, a first normalization layer, a second multi-head attention module, a third multi-head attention module, a second feedforward network and a second normalization layer, wherein:
[0014] The first multi-head attention module is used to process the target vehicle feature C using a multi-head attention mechanism to obtain the target vehicle attention feature C′ and output it to the first feedforward network and the first normalization layer;
[0015] The first feedforward network is used to process the target vehicle attention feature C′, obtain the feature F and output it to the first normalization layer;
[0016] The first normalization layer is used to normalize the target vehicle attention feature C′ and feature F after superposition to obtain the target vehicle optimization feature And output to the third multi-head attention module;
[0017] The second multi-head attention module is used to process the interactive feature S using the multi-head attention mechanism to obtain the interactive attention feature And output to the third multi-head attention module;
[0018] The third multi-head attention module is used to optimize the features of the target vehicle As keys and values, the interactive attention features As a query, a multi-head attention mechanism is used to process the global feature G and send it to the second feedforward network;
[0019] The second feed-forward network is used to process the global feature G and output the obtained feature to the second normalization layer;
[0020] The second normalization layer is used to normalize the received features to obtain the lane-changing behavior feature R;
[0021] The fully connected layer is used to map the lane-changing behavior feature R and output the obtained features to the Softmax layer;
[0022] The Softmax layer is used to predict the received features and obtain the probability of belonging to each lane-changing behavior type;
[0023] S6: using the lane-changing behavior training sample set obtained in step S3 to train the lane-changing behavior prediction model constructed in step S105 to obtain a trained lane-changing behavior prediction model;
[0024] S7: When it is necessary to predict the lane-changing behavior of a target vehicle, obtain the key features of the current moment and the previous T-1 moments, extract the N self-features of the target vehicle from them to form the N-dimensional self-feature H′, and extract the M interactive features between the target vehicle and the surrounding vehicles to form the M-dimensional interactive feature S′. First, input the interactive feature S′ into the lane-changing maneuver judgment model, and obtain D judgment results from D lane-changing maneuver decision trees. Then, the Bagging set strategy is used to aggregate the D judgment results to obtain the maneuver judgment result G′. The specific method is as follows: for each moment, count the number of lane-changing operations and vehicle-keeping operations in the D judgment results, and select the operations with the majority number as the maneuver judgment result vector g t ′; concatenate its own feature H′ and the maneuver judgment result vector G′ to obtain the target vehicle feature C′; then input the target vehicle feature C′ and the interaction feature S′ into the trained lane-changing behavior prediction model to obtain the predicted lane-changing behavior type vector, and then obtain the lane-changing behavior type at the last moment as the prediction result at the current moment.
[0025] The method for predicting vehicle lane changing behavior under lane changing maneuver constraints of the present invention first selects key features from lane changing behavior characteristics according to vehicle lane changing behavior historical data, and divides the features into the target vehicle's own features and the interaction features between the target vehicle and surrounding vehicles, constructs a lane changing maneuver sample set and a lane changing behavior training sample set according to the historical data set, constructs a lane changing maneuver judgment model based on the lane changing maneuver sample set, constructs a lane changing behavior prediction model based on the improved Transformer module and uses the lane changing behavior training sample set for training, and when it is necessary to predict the lane changing behavior of a certain target vehicle, collects its key features, determines the maneuver judgment result through the lane changing maneuver judgment model, and then inputs the feature data and the maneuver judgment result into the lane changing behavior prediction model to obtain the predicted lane changing behavior type.
[0026] The present invention combines feature selection, lane-changing maneuver judgment and the global modeling capabilities of deep learning, which can effectively reduce data redundancy, enhance the model's adaptability to complex scenarios, and at the same time improve the timeliness and accuracy of lane-changing behavior prediction, providing reliable technical support for vehicle trajectory planning and collision risk assessment. BRIEF DESCRIPTION OF THE DRAWINGS
[0027] Figure 1is a flowchart of a specific implementation method of the vehicle lane-changing behavior prediction method under lane-changing maneuver constraints of the present invention;
[0028] Figure 2 is a flowchart of key feature selection based on the autoencoder in this embodiment;
[0029] Figure 3 is a structural diagram of the lane-changing behavior prediction model in the present invention;
[0030] Figure 4 is a performance comparison diagram of three lane change maneuver judgment models in this embodiment;
[0031] Figure 5 is a visual diagram of the lane changing situation of the target vehicle in this embodiment;
[0032] Figure 6 Graph showing the performance of the vehicle lane changing behavior prediction in the present invention in this embodiment. DETAILED DESCRIPTION
[0033] The specific implementation of the present invention is described below in conjunction with the accompanying drawings so that those skilled in the art can better understand the present invention. It should be noted that in the following description, when the detailed description of known functions and designs may dilute the main content of the present invention, these descriptions will be omitted here.
[0034] Example
[0035] Figure 1 FIG. 1 is a flow chart of a specific implementation method of the vehicle lane changing behavior prediction method under lane changing maneuver constraints of the present invention. Figure 1 As shown, the specific steps of the vehicle lane changing behavior prediction method under lane changing maneuver constraints of the present invention include:
[0036] S101: Collect lane-changing behavior history data:
[0037] According to actual needs, K lane-changing behavior historical data are collected to form a historical data set. Each lane-changing behavior historical data contains lane-changing behavior feature data for T consecutive moments and the lane-changing behavior type adopted at each moment. The lane-changing behavior feature data includes the target vehicle's own characteristics at the corresponding moment and the interactive characteristics of its surrounding vehicles. The target vehicle's own characteristics include speed, acceleration, position coordinates, lane width, height, and lane ID. The interactive characteristics of the target vehicle and surrounding vehicles include the relative position and relative speed of the target vehicle and surrounding vehicles. The lane-changing behavior types include left lane change, right lane change, and lane keeping.
[0038] In order to facilitate the subsequent model to better learn the relationship between features, the encoding method of relative position is improved in this embodiment, instead of using only one-dimensional features such as distance. The specific method is: the relative distance between the target vehicle i and the surrounding vehicle j at time t in the k-th vehicle lane change behavior history data is calculated using the following formula: and relative azimuth
[0039]
[0040] in, They respectively represent the position coordinates of the target vehicle i and the surrounding vehicle j at time t in the k-th vehicle lane changing behavior history data, k = 1, 2, ..., K, t = 1, 2, ..., T.
[0041] Since the surroundings may exist in all directions of the target vehicle, the relative azimuth Quantize 360 degrees and encode by buckets, then connect the relative distances Thus, the relative position code P is obtained t i,j :
[0042]
[0043] in, Relative azimuth The bucket encoding representation of Represents a join operation.
[0044] S102: Select key features:
[0045] According to the historical data of vehicle lane-changing behavior, key features are selected from the lane-changing behavior characteristics. The number of the target vehicle's own features in the key features is N, and the number of the interaction features between the target vehicle and the surrounding vehicles is M.
[0046] In order to more accurately select the most representative and predictive key features, this embodiment proposes a key feature selection method based on an autoencoder. Figure 2 This is a flowchart of the key feature selection based on the autoencoder in this embodiment. Figure 2 As shown, the specific steps of key feature selection based on the autoencoder in this embodiment include:
[0047] S201: Constructing time series feature matrix:
[0048] For each lane-changing behavior history data of a vehicle, the lane-changing behavior feature data is converted into a feature vector, and then all feature vectors are sorted in time series. Then each feature vector is used as a row vector to construct a time series feature matrix x k :
[0049]
[0050] Among them, f k,t,b represents the value of the b-th feature at time t in the k-th lane-changing behavior historical data of the vehicle, b=1, 2, …, B, and B represents the number of features in the lane-changing behavior historical data of the vehicle.
[0051] S202: Noise processing:
[0052] The time series feature matrix x k Add Gaussian noise to get the time series feature matrix X after adding noise k In this embodiment, the mean μ of the Gaussian noise is 0, and the variance σ is 0.01.
[0053] S203: Build and train an autoencoder:
[0054] Construct an autoencoder according to actual needs, and then use all the time series feature matrices of the historical data set to train the autoencoder. Use the trained autoencoder to train the time series feature matrix X k Reconstruct the time series feature matrix
[0055] An autoencoder is a commonly used neural network, including an encoder and a decoder. It is an unsupervised method for data dimension compression and data feature expression. In this embodiment, the autoencoder adopts an autoencoder based on a gated recurrent unit (GRU), including a three-layer GRU encoder and a three-layer GRU decoder, wherein the encoding process can be expressed as follows:
[0056] z k,t =GRU 3 (GRU 2 (GRU 1 (f k,t,1 ,…f k,t,B )))
[0057] Among them, z k,t represents the latent space representation.
[0058] Then, we can represent the latent space z k,t Reconstructed through a three-layer GRU decoder, and then the reconstructed time series feature matrix is constructed
[0059] S204: Calculate feature importance:
[0060] The importance of each feature is calculated using a one-by-one removal strategy. The specific method is:
[0061] For the bth feature, from the time series feature matrix X k And reconstruct the time series feature matrix Remove the column vector of the feature and obtain the time series feature matrix X after removal k,b And reconstruct the time series feature matrix Then the importance of the bth feature is calculated using the following formula I b :
[0062]
[0063] Among them, MSE() means to obtain the mean square error.
[0064] Importance I b The larger the value of , the greater the increment of reconstruction error caused by removing the feature, that is, the greater the impact of removing the feature on the quality of the reconstructed feature. Therefore, the more important the feature is, and feature screening can be performed based on the importance.
[0065] S205: Screening features:
[0066] Set the importance threshold according to actual needs, and select features whose importance is greater than the preset threshold as key features.
[0067] Through the above method, features that are highly correlated with lane-changing behavior are screened out and redundant information is removed, which can effectively reduce the dimension of input data, optimize computational efficiency, and enhance the generalization ability of the model in complex scenarios.
[0068] S103: Constructing a training sample set:
[0069] Extract N self-features of the target vehicle from each lane-changing behavior history data of the historical data set to form its own features Extract M interactive features between the target vehicle and surrounding vehicles to form interactive features Determine the corresponding T-dimensional maneuver judgment result vector according to the lane-changing behavior type If the target vehicle in the lane-changing behavior history data adopts a lane-changing operation, then the maneuver judgment result g corresponding to the tth moment is t = 1, if lane keeping operation is adopted, then the maneuver judgment result g corresponding to the tth moment t =0, t=1,2,…,T.
[0070] Each interactive feature S and maneuver judgment result vector G is taken as a lane changing maneuver sample, thereby constructing a lane changing maneuver sample set.
[0071] Concatenate each self-feature H with the maneuver judgment result vector G to obtain the target vehicle feature The target vehicle feature C and the interaction feature S are taken as input, and a lane changing behavior type vector A is constructed as the expected output according to the lane changing behavior type at each moment to form a lane changing behavior training sample, thereby constructing a lane changing behavior training sample set.
[0072] S104: Constructing a lane-changing maneuver judgment model:
[0073] Based on the lane-changing maneuver sample set, the Bagging algorithm is used to train D lane-changing maneuver decision trees. D is set according to actual needs, thereby constructing a lane-changing maneuver judgment model.
[0074] Bagging (bootstrap aggregating) algorithm is a parallel integration algorithm. The idea of this algorithm is to construct multiple base learners (weak learners) respectively, and the multiple base learners are in parallel with each other, and are trained by bootstrap sampling (each training data of each base classifier is randomly extracted from the initial training set with replacement), and finally multiple base learners are combined. In the present invention, the base learner is a lane change maneuver decision tree.
[0075] Since the lane-changing maneuver judgment model in the present invention is a binary classification task, the lane-changing maneuver decision tree in this embodiment adopts a Cart decision tree suitable for binary classification tasks, and uses Gini Impurity as a feature selection criterion. The Cart decision tree is a commonly used decision tree, and its construction process is not repeated here.
[0076] S105: Constructing a lane-changing behavior prediction model:
[0077] In order to realize the prediction of vehicle lane-changing behavior, the present invention proposes a lane-changing behavior prediction model. Figure 3 : is a structural diagram of the lane-changing behavior prediction model in the present invention. Figure 3 As shown, the lane-changing behavior prediction model in the present invention includes a Transformer module, a fully connected layer and a Softmax layer, wherein:
[0078] The Transformer module is used to extract the target vehicle feature C and the interaction feature S, obtain the lane-changing behavior feature R and send it to the fully connected layer. In order to better learn the correlation between the target vehicle's historical trajectory information and the interaction trajectory features, and thus achieve accurate lane-changing behavior prediction, the present invention makes adaptive improvements to the Transformer module. Figure 3 As shown, the Transformer module in the present invention includes a first multi-head attention module, a first feedforward network, a first normalization layer, a second multi-head attention module, a third multi-head attention module, a second feedforward network and a second normalization layer, wherein:
[0079] The first multi-head attention module is used to process the target vehicle feature C using the multi-head attention mechanism to obtain the target vehicle attention feature C′ and output it to the first feedforward network and the first normalization layer. The multi-head attention mechanism is a commonly used mechanism in deep learning, and its specific process will not be repeated here.
[0080] The first feedforward network is used to process the target vehicle attention feature C′, obtain the feature F and output it to the first normalization layer.
[0081] The first normalization layer is used to normalize the target vehicle attention feature C′ and feature F after superposition to obtain the target vehicle optimization feature And output to the third multi-head attention module.
[0082] The second multi-head attention module is used to process the interactive feature S using the multi-head attention mechanism to obtain the interactive attention feature And output to the third multi-head attention module.
[0083] The third multi-head attention module is used to optimize the features of the target vehicle As keys and values, the interactive attention features As a query, a multi-head attention mechanism is used to process it to obtain the global feature G and send it to the second feed-forward network.
[0084] The second feed-forward network is used to process the global feature G and output the obtained feature to the second normalization layer.
[0085] The second normalization layer is used to normalize the received features to obtain the lane-changing behavior feature R.
[0086] The fully connected layer is used to map the lane-changing behavior feature R and output the obtained features to the Softmax layer.
[0087] The Softmax layer is used to predict the received features and obtain the probability of belonging to each lane-changing behavior type.
[0088] S105: Training lane-changing behavior prediction model:
[0089] The lane-changing behavior training sample set obtained in step S103 is used to train the lane-changing behavior prediction model constructed in step S105. In this embodiment, the loss function of the lane-changing behavior prediction model adopts a cross entropy loss function.
[0090] S106: Lane change behavior prediction:
[0091] When it is necessary to predict the lane-changing behavior of a target vehicle, the key features of the current moment and the previous T-1 moments are obtained, and the N self-features of the target vehicle are extracted from them to form the N-dimensional self-feature H′, and the M interactive features between the target vehicle and the surrounding vehicles are extracted to form the M-dimensional interactive feature S′. First, the interactive feature S′ is input into the lane-changing maneuver judgment model, and D judgment results are obtained from D lane-changing maneuver decision trees. Then, the Bagging set strategy is used to aggregate the D judgment results to obtain the maneuver judgment result vector G′. The specific method is as follows: for each moment, the number of lane-changing operations and vehicle-keeping operations in the D judgment results is counted, and the operation with the majority number is selected as the maneuver judgment result g t ′, can be expressed by the formula as follows:
[0092]
[0093] Among them, count t,1 Indicates the number of judgment results of lane change operation at time t, count t,0 Indicates the number of judgment results of vehicle holding operation at time t.
[0094] The target vehicle feature C' is obtained by concatenating the self feature H' and the maneuver judgment result vector G'. Then the target vehicle feature C' and the interactive feature S' are input into the trained lane-changing behavior prediction model to obtain the predicted lane-changing behavior type vector, and then the lane-changing behavior type at the last moment is obtained as the prediction result at the current moment.
[0095] In order to better illustrate the technical effect of the present invention, a specific example is used to experimentally verify the present invention.
[0096] In this embodiment, a High D dataset is used, which contains 110,000 vehicles, a total of 45,000 km of travel, and 5,600 complete lane changes are recorded.
[0097] First, key features are selected. Among the key features selected in this embodiment, the target vehicle's own features include its position and speed, that is, the target vehicle's own features include {x, y, V x ,V y}, where (x, y) represents the position coordinates of the target vehicle, V x ,V y Respectively represent the components of the target vehicle's speed; the interaction features between the target vehicle and the surrounding vehicles include the relative position and speed difference between the target vehicle and the front vehicle, left front, right front, left rear and right rear vehicles, so the interaction features include {V a ,V al ,V ar ,V bl ,V br ,Da ,D al ,D ar ,D bl ,D br}, where V a ,V al ,V ar ,V bl ,V br Denote the speed difference between the target vehicle and the vehicle in front, the left front, the right front, the left rear, and the right rear, respectively. a ,D al ,D ar ,D bl ,D br They respectively represent the relative positions of the target vehicle to the vehicle in front, the left front, the right front, the left rear and the right rear.
[0098] First, the performance of the lane-changing maneuver judgment model is compared. In this embodiment, a lane-changing maneuver judgment model based on a Cart decision tree is constructed, and the use of a single Cart decision tree, a combination of a Cart decision tree and an Adaboost algorithm (referred to as a CA algorithm), and a Cart decision tree and a Bagging algorithm (referred to as a CB algorithm) are compared. Figure 4 : is a performance comparison chart of the three lane change maneuver judgment models in this embodiment. Figure 4 As shown, the lane-changing maneuver judgment results obtained using only the Cart algorithm have low accuracy and recall. The CA algorithm can improve the model performance to a certain extent, but due to the characteristics of the input data and the algorithm, its generalization ability will be greatly affected. In the CB algorithm proposed in this embodiment, its accuracy, recall and F1-score are better than the other two algorithms. After analysis, the reason may be that the Bagging method reduces the bias and variance of a single decision tree by constructing multiple decision trees and voting, thereby improving the stability and generalization ability of the model. In contrast, the simple Cart decision tree is easily affected by the noise of the training data, and although the CA algorithm improves the performance of a single tree through weighted adjustment, it is more sensitive to data and has relatively limited generalization ability. Therefore, the CB algorithm performs better in the lane-changing maneuver judgment task.
[0099] In order to observe the lane-changing maneuver judgment results more intuitively, all lane-changing situations of the CB algorithm are visualized. Figure 5 is a visual graph of the lane change of the target vehicle in this embodiment. In order to make the result clearer, the visual graph has been processed by data point display control. Figure 5As shown in the figure, the first row from left to right shows the situation where vehicles No. 117, No. 394, No. 615, and No. 847 change lanes to the left, and the second row from left to right shows the situation where vehicles No. 83, No. 206, No. 560, and No. 1024 change lanes to the right. The black continuous points are vehicle trajectories, and the red ones are the maneuver judgment results. It can be clearly observed that the CB algorithm is fully capable of giving the correct lane change maneuver judgment before the vehicle starts to change lanes.
[0100] Figure 6 : is a performance statistics diagram of the vehicle lane changing behavior prediction of the present invention in this embodiment. Figure 6 As shown, the present invention performs best in predicting LK (vehicle hold), with 392 samples correctly predicted, and only a few misclassified as LLC (left lane change) (8) and RLC (right lane change) (2). For the LLC category, 375 samples were correctly predicted, but 7 were misclassified as LK and 7 were misclassified as RLC. In the RLC category, the model correctly predicted 201 samples, and 2 and 4 samples were misclassified as LK and LLC, respectively.
[0101] Although the above describes the illustrative specific embodiments of the present invention to facilitate those skilled in the art to understand the present invention, it should be clear that the present invention is not limited to the scope of the specific embodiments. For those of ordinary skill in the art, as long as various changes are within the spirit and scope of the present invention as defined and determined by the attached claims, these changes are obvious, and all inventions and creations using the concept of the present invention are protected.
Claims
1. A method for predicting vehicle lane-changing behavior under lane-changing maneuver constraints, characterized in that: The following steps are involved: S1: K lane-changing behavior history data of vehicles are collected according to actual needs to form a historical data set. Each lane-changing behavior history data contains lane-changing behavior feature data of T consecutive moments and the lane-changing behavior type adopted at each moment. The lane-changing behavior feature data includes the self-features of the target vehicle at the corresponding moment and the interactive features of the surrounding vehicles. The self-features of the target vehicle include speed, acceleration, position coordinates, lane width, height, and lane ID. The interactive features of the target vehicle and the surrounding vehicles include the distance difference and speed difference between the target vehicle and the surrounding vehicles. The lane-changing behavior types include left lane change, right lane change, and lane keeping. S2: Filter out key features from the lane-changing behavior characteristics based on the historical data of the vehicle's lane-changing behavior. The number of the target vehicle's own features in the key features is N, and the number of the target vehicle's interaction features with surrounding vehicles is M. S3: Extract N self-features of the target vehicle from each lane-changing behavior history data of the historical data set to form its own features Extract M interactive features between the target vehicle and surrounding vehicles to form interactive features Determine the corresponding T-dimensional maneuver judgment result vector according to the lane-changing behavior type If the target vehicle in the lane-changing behavior history data adopts a lane-changing operation, then the maneuver judgment result g corresponding to the tth moment is t = 1, if lane keeping operation is adopted, then the maneuver judgment result g corresponding to the tth moment t =0, t=1,2,…,T; Each interactive feature S and maneuver judgment result vector G is taken as a lane-changing maneuver sample, thereby constructing a lane-changing maneuver sample set; Concatenate each self-feature H with the maneuver judgment result vector G to obtain the target vehicle feature The target vehicle feature C and the interaction feature S are used as input, and a lane-changing behavior type vector A is constructed according to the lane-changing behavior type at each moment as the expected output, forming a lane-changing behavior training sample, thereby constructing a lane-changing behavior training sample set; S4: Based on the lane-changing maneuver sample set, a Bagging algorithm is used to train D lane-changing maneuver decision trees, where D is set according to actual needs, thereby constructing a lane-changing maneuver judgment model; S5: Construct a lane-changing behavior prediction model, including a Transformer module, a fully connected layer, and a Softmax layer, where: The Transformer module is used to extract the target vehicle feature C and the interaction feature S, obtain the lane-changing behavior feature R and send it to the fully connected layer; the Transformer module includes a first multi-head attention module, a first feedforward network, a first normalization layer, a second multi-head attention module, a third multi-head attention module, a second feedforward network and a second normalization layer, wherein: The first multi-head attention module is used to process the target vehicle feature C using a multi-head attention mechanism to obtain the target vehicle attention feature C′ and output it to the first feedforward network and the first normalization layer; The first feedforward network is used to process the target vehicle attention feature C′, obtain the feature F and output it to the first normalization layer; The first normalization layer is used to normalize the target vehicle attention feature C′ and feature F after superposition to obtain the target vehicle optimization feature And output to the third multi-head attention module; The second multi-head attention module is used to process the interactive feature S using the multi-head attention mechanism to obtain the interactive attention feature And output to the third multi-head attention module; The third multi-head attention module is used to optimize the features of the target vehicle As keys and values, the interactive attention features As a query, a multi-head attention mechanism is used to process the global feature G and send it to the second feedforward network; The second feed-forward network is used to process the global feature G and output the obtained feature to the second normalization layer; The second normalization layer is used to normalize the received features to obtain the lane-changing behavior feature R; The fully connected layer is used to map the lane-changing behavior feature R and output the obtained features to the Softmax layer; The Softmax layer is used to predict the received features and obtain the probability of belonging to each lane-changing behavior type; S6: using the lane-changing behavior training sample set obtained in step S3 to train the lane-changing behavior prediction model constructed in step S5 to obtain a trained lane-changing behavior prediction model; S7: When it is necessary to predict the lane-changing behavior of a target vehicle, the key features of the current moment and the previous T-1 moments are obtained, and the N self-features of the target vehicle are extracted from them to form the N-dimensional self-feature H′, and the M interactive features between the target vehicle and the surrounding vehicles are extracted to form the M-dimensional interactive feature S′; first, the interactive feature S′ is input into the lane-changing maneuver judgment model, and D judgment results are obtained from D lane-changing maneuver decision trees. Then, the Bagging set strategy is used to aggregate the D judgment results to obtain the maneuver judgment result G′. The specific method is as follows: for each moment, the number of lane-changing operations and vehicle-keeping operations in the D judgment results is counted, and the operations with the majority number are selected as the maneuver judgment result vector g t ′; concatenate its own feature matrix H′ and the maneuver judgment result vector G′ to obtain the target vehicle feature C′; then input the target vehicle feature C′ and the interaction feature S′ into the trained lane-changing behavior prediction model to obtain the predicted lane-changing behavior type vector, and then obtain the lane-changing behavior type at the last moment as the prediction result at the current moment.
2. The vehicle lane-changing behavior prediction method according to claim 1, characterized in that: The relative position in step S1 is obtained by the following method: The following formula is used to calculate the relative distance between the target vehicle i and the surrounding vehicle j at time t in the kth vehicle lane change behavior history data: and relative azimuth in, They represent the position coordinates of the target vehicle i and the surrounding vehicle j at time t in the k-th vehicle lane change behavior history data, k = 1, 2, ..., K, t = 1, 2, ..., T; Relative azimuth Quantize 360 degrees and encode by buckets, then connect the relative distances Thus, the relative position code P is obtained t i,j : in, Relative azimuth The bucket encoding representation of Represents a join operation.
3. The vehicle lane-changing behavior prediction method according to claim 1, characterized in that: The specific method for selecting key features in step S2 is: S2.1: For each lane-changing behavior history data of a vehicle, convert the lane-changing behavior feature data into feature vectors, then sort all feature vectors in time series, and then use each feature vector as a row vector to construct a time series feature matrix x k : Among them, f k,t,b represents the value of the b-th feature at time t in the k-th lane-changing behavior history data of the vehicle, b = 1, 2, ..., B, and B represents the number of features in the lane-changing behavior history data of the vehicle; S2.2: To the time series feature matrix x k Add Gaussian noise to get the time series feature matrix X after adding noise k ; S2.3: Construct an autoencoder according to actual needs, and then use all the time series feature matrices of the historical data set to train the autoencoder. Use the trained autoencoder to train the time series feature matrix X k Reconstruct the time series feature matrix S2.4: The importance of each feature is calculated using the one-by-one removal strategy. The specific method is: For the bth feature, from the time series feature matrix X k And reconstruct the time series feature matrix Remove the column vector of the feature and obtain the time series feature matrix X after removal k,b And reconstruct the time series feature matrix Then the importance of the bth feature is calculated using the following formula I b : Among them, MSE() means to obtain the mean square error; S2.5: Set the importance threshold according to actual needs, and select features whose importance is greater than the preset threshold as key features.
4. The vehicle lane-changing behavior prediction method according to claim 1, characterized in that: The lane-changing maneuver decision tree in step S4 adopts a Cart decision tree.