Vehicle track prediction method based on spatial motion relation and long-short time memory network
By constructing a spatial interaction graph and utilizing graph attention network, combined with the LSTM network, the problem of ignoring the relative position and dynamic relationship between vehicles in the existing vehicle trajectory prediction method is solved, and more accurate vehicle trajectory prediction is achieved, improving prediction accuracy is improved and computing efficiency, suitable for intelligent transportation systems and other trajectory prediction fields.
Patent Information
- Application Number
- CN202411189217.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-28
- Publication Date
- 2024-12-06
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The existing LSTM-based vehicle trajectory prediction method ignores the relative position and dynamic relationship between vehicles and cannot fully capture the allocation of spatial influence between vehicles, resulting in insufficient prediction accuracy.
By constructing a spatial interaction diagram between vehicles and using graph attention network to learn the spatial influence allocation between vehicles, combining LSTM to capture the timing characteristics and spatial relationships of vehicle movement, a more accurate vehicle trajectory prediction model is built.
It improves prediction accuracy and generalization capabilities of models, enhances adaptability to different road environments and traffic conditions, significantly improves computing efficiency, and has broad application prospects.
Smart Images

Figure CN119091623A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of vehicle prediction, and in particular relates to a vehicle trajectory prediction method based on spatial motion relationship and long-short time memory network. Background Art
[0002] With the rapid development of intelligent transportation systems, vehicle trajectory prediction has become an important research field. Accurate vehicle trajectory prediction is of great significance for improving traffic efficiency, reducing traffic congestion, and improving driving safety. However, vehicle trajectory prediction faces many challenges, such as the interaction between vehicles, the complexity of the road environment, and the timing of vehicle movement.
[0003] Traditional vehicle trajectory prediction methods are mainly based on physical models and statistical models. Physical models predict future trajectories by considering the kinematic characteristics of vehicles, but ignore the interaction between vehicles and the impact of road environments. Statistical models use historical data to establish the probability distribution of vehicle trajectories, but have difficulty handling complex nonlinear relationships and time-series dependencies.
[0004] In recent years, deep learning has made significant progress in the field of vehicle trajectory prediction. In particular, the Long Short-Term Memory (LSTM) network has been widely used in vehicle trajectory prediction due to its powerful time series modeling capabilities. LSTM can capture the time dependency of vehicle motion and output time series features, thereby improving the accuracy of prediction.
[0005] However, existing LSTM-based vehicle trajectory prediction methods still have some limitations. On the one hand, they tend to only consider the absolute position and motion state of the vehicle, while ignoring the relative position and dynamic relationship between vehicles. On the other hand, they usually use simple pooling operations or attention mechanisms when dealing with the interaction between vehicles, which cannot fully capture the spatial influence distribution between vehicles.
[0006] Therefore, in order to further improve the accuracy of vehicle trajectory prediction, this paper proposes a vehicle trajectory prediction method based on spatial motion relationship and long short-term memory network. This method constructs a spatial interaction graph between vehicles and uses a graph attention network to learn the spatial influence distribution between vehicles. At the same time, LSTM is used to capture the temporal characteristics and spatial relationship of vehicle motion, thereby achieving more accurate vehicle trajectory prediction. Summary of the invention
[0007] The present invention (object of the invention).
[0008] The technical solution of the present invention is as follows:
[0009] A vehicle trajectory prediction method based on spatial motion relationship and long short-term memory network includes the following steps:
[0010] Collect and preprocess the real-time data of the vehicle, and extract the absolute and relative features of the vehicle as input features;
[0011] Based on the relative characteristics of the vehicles, a spatial interaction diagram is constructed;
[0012] Build an LSTM prediction model, take the spatial interaction graph and the absolute features of the vehicle as input, and train the LSTM prediction model;
[0013] The trained LSTM prediction model outputs the vehicle trajectory prediction results at future moments.
[0014] Furthermore, the real-time data of the vehicle is obtained through vehicle-mounted sensors, traffic monitoring systems or mobile positioning devices.
[0015] Furthermore, the preprocessing is specifically as follows:
[0016] The collected vehicle data is smoothed to reduce noise interference by removing outliers and missing values.
[0017] Furthermore, the absolute characteristics of the vehicles are the lateral and longitudinal coordinates, the absolute speed, and the absolute acceleration of each vehicle;
[0018] The relative characteristics of the vehicle are the relative position, relative speed, and relative acceleration between the target vehicle and surrounding vehicles.
[0019] Furthermore, the nodes in the spatial interaction graph represent vehicles, the edges represent interactions between vehicles, and the weights of the edges are dynamically adjusted according to relative distance, speed difference, and acceleration difference.
[0020] Furthermore, the LSTM prediction model consists of an input layer, a multi-layer LSTM structure, a fully connected layer, and an output layer;
[0021] The input layer is responsible for receiving preprocessed data, including the absolute position features of the vehicle and the features extracted from the spatial interaction graph;
[0022] The multi-layer LSTM structure is responsible for capturing long-term dependencies in time series data;
[0023] The fully connected layer is located after the LSTM layer and is used to further integrate and extract features;
[0024] The output layer is used to generate the final prediction result.
[0025] Furthermore, each layer of LSTM includes multiple LSTM units, each of which has a forget gate, an input gate, an output gate, and a memory cell for storing and updating information.
[0026] Furthermore, the method uses mean square error and mean absolute error as loss functions to train the LSTM prediction model.
[0027] Compared with the prior art, the present invention has the following advantages:
[0028] Improved prediction accuracy: This paper constructs a spatial interaction graph between vehicles and uses a graph attention network to learn the spatial influence distribution between vehicles, so that the model can more accurately capture the interaction and dynamic relationship between vehicles. At the same time, the LSTM network is used to capture the temporal characteristics of vehicle movement, further improving the accuracy of prediction.
[0029] Enhanced generalization ability of the model: The present invention not only considers the absolute position and motion state of the vehicle, but also fully considers the relative position and dynamic relationship between vehicles, so that the model can better adapt to different road environments and traffic conditions, thereby enhancing the generalization ability of the model.
[0030] Improved computational efficiency: The present invention uses LSTM as the encoder-decoder structure and captures the temporal characteristics and spatial relationships of vehicle motion through multi-layer LSTM units. Compared with traditional physical models and statistical models, the method of the present invention has significantly improved computational efficiency and can output prediction results faster.
[0031] Easy to implement and optimize: The method of the present invention is based on a deep learning framework and is easy to implement and deploy. At the same time, by using loss functions and optimization algorithms to train and optimize the model, the performance and prediction accuracy of the model can be further improved.
[0032] It has broad application prospects: The method of the present invention is not only suitable for urban traffic trajectory prediction, but can also be extended to trajectory prediction problems in other fields, such as trajectory prediction of moving objects in aviation, ocean and other fields, and has broad application prospects. BRIEF DESCRIPTION OF THE DRAWINGS
[0033] The accompanying drawings generally illustrate various embodiments by way of example and not limitation, and together with the description and claims, serve to illustrate the embodiments of the invention. Where appropriate, the same reference numerals are used throughout the drawings to refer to the same or similar parts. Such embodiments are illustrative and are not intended to be exhaustive or exclusive embodiments of the present apparatus or method.
[0034] Figure 1 A schematic diagram of the process of the present invention is shown. DETAILED DESCRIPTION
[0035] It should be noted that, in the absence of conflict, the embodiments and features in the embodiments of the present application can be combined with each other. The present application will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.
[0036] The embodiment of the present invention proposes a vehicle trajectory prediction method based on spatial motion relationship and long short-term memory (LSTM) network, and the specific implementation method is as follows:
[0037] Data collection and preprocessing
[0038] Using on-board sensors, traffic monitoring systems, and mobile positioning devices, the present invention collects a large amount of real-time data from vehicles. These data cover a time span of up to one year, including vehicle behavior in various traffic scenarios and weather conditions. Specifically, the present invention collects information such as the lateral and longitudinal coordinates, speed, acceleration, etc. of each vehicle, and records the driving data of about 1 million vehicles in different traffic scenarios.
[0039] In the data preprocessing stage, the present invention first removes outliers and missing values. For example, for records where the speed suddenly changes and exceeds the threshold of 10 meters per second, the present invention regards it as an outlier and removes it. This step helps the present invention remove about 5% of the data noise. Then, the present invention uses a sliding average filter algorithm to smooth the raw data, and the window size is set to 5 to reduce noise interference and improve the accuracy and reliability of the data.
[0040] The following is a comparison table before and after data preprocessing:
[0041] Data indicators Before pretreatment After preprocessing Total amount of data 1 million vehicles 1 million vehicles Outlier ratio 5% <1% Data Noise high Low Data smoothness Low high
[0042] Feature extraction
[0043] In the preprocessed data, the present invention extracts the absolute features and relative features of the vehicle. The absolute features include the lateral and longitudinal coordinates, absolute speed, and absolute acceleration of each vehicle, which describe the motion state of the vehicle itself. The relative features include the relative position, relative speed, and relative acceleration between the target vehicle and the surrounding vehicles, which reflect the interaction between the vehicles.
[0044] In order to describe the interaction between vehicles more specifically, the present invention calculates the relative distance, speed difference and acceleration difference between the target vehicle and the surrounding vehicles, and uses these values as the weights of the edges to construct a spatial interaction graph. In this graph, nodes represent vehicles and edges represent the interaction between vehicles. In this way, the present invention can more accurately capture the mutual influence between vehicles and use it as an important input feature of the prediction model.
[0045] Building an LSTM prediction model
[0046] The present invention constructs an LSTM prediction model, which consists of an input layer, a three-layer LSTM structure, a fully connected layer, and an output layer. The input layer is responsible for receiving preprocessed data, including the absolute position features of the vehicle and the features extracted from the spatial interaction graph. The three-layer LSTM structure is responsible for capturing the long-term dependencies in the time series data to more accurately predict the vehicle trajectory. Each LSTM layer contains 128 LSTM units, each of which has a forget gate, an input gate, an output gate, and a memory cell for storing and updating information. The fully connected layer is located after the LSTM layer and is used to further integrate and extract features. The output layer is used to generate the final prediction result, that is, the vehicle trajectory at the future moment.
[0047] Training LSTM prediction model
[0048] The present invention uses the collected vehicle data to train the LSTM prediction model. During the training process, the present invention uses the mean square error (MSE) and the mean absolute error (MAE) as loss functions to evaluate the prediction performance of the model. Through the optimization algorithm, the present invention continuously adjusts the parameters of the model to minimize the loss function and improve the prediction accuracy. After multiple iterative training, the present invention obtains an LSTM prediction model with stable performance. During the training process, the present invention uses about 80% of the data as a training set and 20% of the data as a validation set to ensure the generalization ability of the model.
[0049] The following is a table of performance indicators during model training:
[0050] Training phase MSE MAE Prediction accuracy Initial stage 0.1 0.05 70% Intermediate Stage 0.05 0.025 80% Final Stage 0.02 0.015 90%
[0051] Actual case application and prediction result verification
[0052] In order to verify the practical application effect of the present invention, the present invention selected a busy urban traffic intersection as a test scene. The intersection has a large traffic flow and frequent vehicle interactions, which is a typical complex traffic environment. The present invention uses the traffic monitoring system deployed at the intersection to collect the trajectory data of passing vehicles in real time, and inputs it into the trained LSTM prediction model as input. The model predicts the vehicle trajectory within the next 5 seconds based on the input vehicle trajectory data.
[0053] In order to evaluate the accuracy of the prediction results, the present invention compares the predicted trajectory with the actual trajectory. The comparison results show that the model of the present invention has high accuracy in predicting vehicle trajectories. Specifically, in the test data set, the MSE of the model is 0.02 and the MAE is 0.015, which indicates that the error between the prediction results of the model and the actual trajectory is small. Further analyzing the prediction results, the present invention found that the model can accurately capture the interaction between vehicles and reasonably predict the future trajectory of the vehicle based on the vehicle's motion state and changes in the surrounding environment. Even in the case of heavy traffic and frequent vehicle interactions, the model can maintain a high prediction accuracy, with a prediction accuracy of more than 90%.
[0054] The following is a table of performance indicators in actual case applications:
[0055] Test scenario MSE MAE Prediction accuracy Urban traffic intersection 0.02 0.015 90%
[0056] In summary, the present invention achieves accurate prediction of vehicle trajectories by combining the advantages of spatial motion relationship and LSTM network. Field test results show that this method has high prediction accuracy and can provide strong technical support for the development of intelligent transportation systems.
[0057] The above description is only a preferred specific implementation manner of the present invention, but the protection scope of the present invention is not limited thereto. Any technician familiar with the technical field can make equivalent replacements or changes according to the technical scheme and inventive concept of the present invention within the technical scope disclosed by the present invention, which should be covered by the protection scope of the present invention.
Claims
1. A vehicle trajectory prediction method based on spatial motion relationship and long-short time memory network, characterized in that: The following steps are involved: Collect and preprocess the real-time data of the vehicle, and extract the absolute and relative features of the vehicle as input features; Based on the relative characteristics of the vehicles, a spatial interaction diagram is constructed; Build an LSTM prediction model, take the spatial interaction graph and the absolute features of the vehicle as input, and train the LSTM prediction model; The trained LSTM prediction model outputs the vehicle trajectory prediction results at future moments.
2. The vehicle trajectory prediction method based on spatial motion relationship and long short-term memory network according to claim 1 is characterized in that: The real-time data of the vehicle is obtained through vehicle-mounted sensors, traffic monitoring systems or mobile positioning devices.
3. The vehicle trajectory prediction method based on spatial motion relationship and long short-term memory network according to claim 1 is characterized in that: The pre-processing is specifically as follows: The collected vehicle data is smoothed to reduce noise interference by removing outliers and missing values.
4. The vehicle trajectory prediction method based on spatial motion relationship and long-short time memory network according to claim 1 is characterized in that: The absolute characteristics of the vehicles are the lateral and longitudinal coordinates, absolute speed, and absolute acceleration of each vehicle; The relative characteristics of the vehicle are the relative position, relative speed, and relative acceleration between the target vehicle and surrounding vehicles.
5. The vehicle trajectory prediction method based on spatial motion relationship and long short-term memory network according to claim 1 is characterized in that: The nodes in the spatial interaction graph represent vehicles, the edges represent the interactions between vehicles, and the weights of the edges are dynamically adjusted according to the relative distance, speed difference, and acceleration difference.
6. The vehicle trajectory prediction method based on spatial motion relationship and long short-term memory network according to claim 1 is characterized in that: The LSTM prediction model consists of an input layer, a multi-layer LSTM structure, a fully connected layer, and an output layer; The input layer is responsible for receiving preprocessed data, including the absolute position features of the vehicle and the features extracted from the spatial interaction graph; The multi-layer LSTM structure is responsible for capturing long-term dependencies in time series data; The fully connected layer is located after the LSTM layer and is used to further integrate and extract features; The output layer is used to generate the final prediction result.
7. The vehicle trajectory prediction method based on spatial motion relationship and long-short time memory network according to claim 5 is characterized in that: Each layer of LSTM includes multiple LSTM units, each of which has a forget gate, an input gate, an output gate, and a memory cell for storing and updating information.
8. The vehicle trajectory prediction method based on spatial motion relationship and long-short time memory network according to claim 1 is characterized in that: The method uses mean square error and mean absolute error as loss functions to train the LSTM prediction model.
