Vehicle trajectory prediction method and model based on improved Transform model and target point guidance, and electronic equipment

Through the improved Transformer model and multi-modal motion decoder, the problems of high computational cost and trajectory prediction uncertainty in trajectory prediction of surrounding vehicles of autonomous vehicles are solved, achieving efficient and accurate prediction in complex scenes and improving prediction accuracy. performance and interpretability.

CN118823731AActive Publication Date: 2024-10-22JIANGSU UNIV

Patent Information

Application Number
CN202410801976.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-20
Publication Date
2024-10-22
Estimated Expiration
2044-06-20

AI Technical Summary

Technical Problem

Existing vehicle trajectory prediction methods around autonomous vehicles suffer from high computational costs, limited receptive fields, and trajectory prediction uncertainty in complex scenarios, and are unable to effectively capture fine-grained information, affecting prediction accuracy.

Method used

Using an improved Transformer model, combined with a scene context attention encoder and a multi-modal motion decoder, through vectorized representation and factorized attention mechanism, efficient feature fusion and multi-modal trajectory generation between scene elements are achieved, reducing redundancy. Target points to improve prediction accuracy and interpretability.

Benefits of technology

It achieves efficient and accurate multi-agent prediction in dynamic and complex scenes, reduces computational complexity and reasoning latency, improves the accuracy and reliability of trajectory prediction, and can capture multi-modal distribution and fine-grained information.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118823731A_ABST
    Figure CN118823731A_ABST
Patent Text Reader

Abstract

The invention discloses a vehicle trajectory prediction method and model based on an improved Transform model and target point guidance, and electronic equipment, and the method comprises the steps: processing all scene elements through a local space-time reference system, and enabling each scene element to generate a unique and unchanged representation; and secondly, in a scene context coding module based on factorization attention, a feature fusion method for querying cross attention along a target vehicle is provided, and information acquisition for guiding and enhancing the target vehicle is realized by injecting multiple key values, so that scene context global feature fusion is realized. Then, a multi-modal motion prediction module based on a target point as a condition is adopted, dense target candidate points and probabilities thereof are generated from scene contexts, a target point predictor is designed to select candidate targets on highly potential lane sections, and a multi-modal target decoder is introduced to further capture a high-quality target state; and finally, compact and diversified predictions are obtained by using a trajectory generation module, and multi-modal trajectory output with high reliability and interpretability is realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of autonomous driving, and specifically relates to a method, model and electronic equipment for predicting trajectories of vehicles around an autonomous driving vehicle based on an improved Transformer model and target point guidance. Background Art

[0002] In the field of autonomous driving, accurately predicting the future trajectory of surrounding vehicles is crucial, but this task is challenging. The movement of a vehicle is affected by many factors, including road geometry, traffic rules, and the behavior of other vehicles around it. In addition, the intentions and goals of surrounding vehicles are usually unknown, resulting in a high degree of uncertainty in the prediction of future states.

[0003] Motion prediction tasks traditionally rely on road map information with physical kinematic constraints and handcrafted rules. However, these methods fail to capture the rich behavioral strategies and interactions in complex scenarios. With the advancement of deep learning (DL), we are able to use data-driven methods to understand and capture the complexity of driving scenarios and achieve the most promising state-of-the-art results by learning these intrinsic rules. Early studies rasterized the scene into bird's-eye view images and applied CNNs for prediction. Although these methods are easier to implement using off-the-shelf image models, they are computationally expensive and have limited receptive fields. Given these limitations, vectorization methods have gradually gained attention due to their efficient sparse coding and ability to capture complex structural information. In addition, existing research methods model all relationships in spatial and temporal dimensions to capture fine-grained interactions between vectorized entities. It is worth noting that Transformer-based models have been widely used in trajectory prediction to model context in spatial and temporal domains and interactions between vehicles. Although these models improve the accuracy of prediction, their scalability is still limited by the high computational complexity of attention. When dealing with dense scenes and extreme conditions, it will lead to increased inference latency and inability to predict in time.

[0004] There is a huge uncertainty in the output results of trajectory prediction. In order to avoid missing any potential behaviors, the model must be able to capture the potential multimodal distribution. At present, a large number of studies use hand-crafted anchor points as a guide for multimodal prediction. However, when the number of anchor points cannot accurately cover the actual ground situation, it will lead to the inability to capture fine-grained information, thus affecting the accurate prediction of the trajectory. Summary of the invention

[0005] In order to overcome the limitations of previous solutions, the present invention provides a method, model and electronic device for predicting the trajectory of vehicles around an autonomous driving vehicle based on an improved Transformer model and target point guidance. The constructed model mainly consists of two modules: a scene context attention encoder and a multimodal motion decoder. The model processes multiple scene element inputs in a local spatiotemporal coordinate system to generate scene encodings. The scene encodings are used as contexts for the decoder to generate k possible multimodal trajectories covering the output space.

[0006] First, a vectorized scene representation is adopted. For each semantic element, such as vehicle and lane segment, a local reference frame is constructed to decouple the inherent features and relative information between elements to learn a traffic scene representation independent of the global spatiotemporal coordinate system to generate a unique and invariant representation. Secondly, a scene context encoding module based on a factorized attention transformer is constructed. A feature fusion method for querying cross-attention along the target vehicle axis is proposed. By injecting multiple key-value pairs to guide the enhanced information acquisition of the target vehicle, the goal of scene context global feature fusion is achieved, the computational efficiency and the accuracy of real-time prediction are improved, and the model is helpful to achieve efficient multi-agent prediction in dynamic and complex scenes. Then, a multimodal prediction decoding module based on target points is constructed. Dense target candidates and their probabilities are generated from the scene context, a target point predictor is designed to select only candidate targets on highly potential lane segments, and a multimodal target decoder is introduced to further capture a set of high-quality target states, thereby effectively filtering and suppressing redundant target points and reducing the representation requirements for subsequent target trajectory generation. Finally, the trajectory generation module is used to obtain a final set of compact and diverse predictions, achieving a multimodal trajectory output with high reliability and interpretability.

[0007] Based on the above prediction model, a method for predicting the trajectory of vehicles around an autonomous driving vehicle based on an improved Transformer model and target point guidance proposed by the present invention is implemented, and the following technical scheme is adopted, including the following steps:

[0008] Step 1: Trajectory prediction Problem description: In a certain driving environment, assume that there are A surrounding targets in the scene where the target vehicle is located. It is known that the target vehicle i has been h The time step history trajectory information is expressed as: Predict the target vehicle’s future t f Trajectory information for time step segments Each trajectory Refers to the location coordinate information at a future time. The specific representation is as follows:

[0009] Step 1.1: Vectorize all scene information: The motion state characteristics of target vehicle i at time step t include its spatial position Heading Angle Acceleration and speed Equal motion parameters, where (t∈t h ). Each trajectory motion vector is defined as in Respectively represent the starting and ending positions of the target vehicle i within the time step t. At the same time, obtain the M polygon shape on the high-definition map. For a lane segment C, Each lane vector Where N represents the total vector length, are the starting and ending coordinates of the lane segment respectively.

[0010] Step 1.2: From the target vehicle state and spatiotemporal position and reference direction Determine the establishment of a local space-time coordinate system. For lanes and crosswalks, select the location and direction of the centerline entry point as the reference.

[0011] Step 1.3: Embedding of multiple scene elements: For each spatiotemporal scene element, the polar coordinates are converted into Fourier features and embedded through a multi-layer perceptron (MLP) to obtain the embedding of the target vehicle i An attention-based pooling operation is applied to the sample point embedding m within each map polygon. i .

[0012] Step 1.4: In order to retain all the spatiotemporal position information of the scene element pairs, the relative spatiotemporal position is embedded. Specifically, taking the target vehicle i and the surrounding target j as examples, their absolute spatiotemporal positions are expressed as and Including its relative distance Relative Direction Relative position And the time interval ut. Then through the multi-layer perceptron (MLP) processing, the relative position embedding representation is generated as If either of the two scene elements is static (such as a lane segment), the embedding can be simplified to τ j:i .

[0013] Step 2: Encode scene elements into their local coordinate system, and with the help of relative spatiotemporal position embedding, propose an efficient feature fusion method for querying cross-attention along the target vehicle axis. By injecting multiple key-value pairs to guide the enhancement of the target vehicle scene context information feature acquisition capability, and iteratively update the target vehicle feature representation, the goal of obtaining the final target information embedding is achieved. The specific implementation process is as follows:

[0014] Step 2.1: First, use self-attention to capture the relationship between map elements, from the map embedding m i Extract a Query value from it and let it focus on its adjacent lanes and crosswalks Where N i is the map polygon m i The neighbor collection step is:

[0015]

[0016] Where MHA(a, b, c) represents attention, a is the query, b is the key, and c is the value. The specific calculation of the attention function is as follows:

[0017]

[0018]

[0019] The spatial perception of the map encoding is combined with the cascade operation memory from adjacent polygon encoding and relative position embedding. Brief Notes To calculate the jth Key and Value. are query matrix, key matrix and value matrix respectively, W Q , W K , W V is a learnable linear projection matrix, d k is the dimension of the Q, K and V vectors. i Represented as a map encoding using the output of self-attention.

[0020] Step 2.2: Concatenate the key and value elements in the attention layer with the spatiotemporal position embedding relative to the query element. Derive the query vector Query value

[0021] The target vehicle information of the past time steps is mapped to the current state, so that the model can learn the previous motion information encoding. First, the historical time attention module is used to learn the temporal dependencies in its region. The formula is:

[0022]

[0023] By considering the target vehicle i from time step tu(0 <u<t h ) to the time step t-1 and the corresponding relative position embedding combination, denoted as Calculate the Key and Value values ​​to perform temporal attention operations.

[0024] Step 2.3: Then, in order to reflect the impact of map environment information on vehicle prediction, the updated map information after self-attention is integrated into the agent embedding. The formula is:

[0025]

[0026] The output map encoding is used Export Key and Value values ​​to complete the target - map attention.

[0027] Step 2.4: Aggregate spatial information through an interactive attention module to learn the environmental information and surrounding vehicle information that have a greater impact on the target vehicle's driving. The formula is:

[0028]

[0029] The state and relative spatiotemporal position of the surrounding vehicles are embedded in the combination Derive the Key and Value values ​​to complete the social attention between vehicles. Neighbor set N i Determined by a distance threshold of 50 meters.

[0030] Step 2.5: Repeat steps 2.2 to 2.4, stacking the historical time attention, target-map attention, and vehicle-to-vehicle interaction attention sequentially as a fusion block, and iteratively update L enc times to realize the update information flow between different scene elements and output the final tensor.

[0031] Step 3: Generate dense target candidates and their probabilities from the scene context, design a target point predictor to select only highly potential candidate targets on the lane segment, and introduce multimodal target decoding to further effectively capture a set of high-quality target states, thereby effectively filtering and suppressing redundant target points and reducing the representation requirements for subsequent target trajectory generation. The specific implementation process is as follows:

[0032] Step 3.1: First, lane scoring selection is used to predict the lane where the target vehicle will appear to reduce the number of target candidates. Select the first k lane segments {C1, C2, … C k}, then:

[0033] D(C,C gt )=min(||C1-C gt || 2 ,||C2-C gt || 2 ,…||C k -C gt || 2 )

[0034] L lane =L cls (C,C gt )

[0035] Where D(C,C gt ) represents lane C and ground truth lane segment C gt The distance between lane Estimate the damage for the driveway.

[0036] Step 3.2: Then, the target probability estimation is used to obtain the probability of the future target point on the candidate lane, and the attention mechanism is used to obtain the local information between the target vehicle and the lane. The specific calculation formula is:

[0037] q g =W q Z, k c =W k L, v c =W v L

[0038]

[0039] Where Z and L are the feature matrices of dense target candidates and all map elements obtained using MLP.

[0040] Then use the maximum entropy model to score all candidate target points, where the predicted score of the i-th target can be written as:

[0041]

[0042] The trainable function g(·) is also implemented using a 2-layer MLP.

[0043]

[0044] Where L goal is the target point loss. The predicted target score δ and the ground truth target score are calculated using the cross entropy loss function. The differences between.

[0045] Step 3.3: Then use the multimodal targeter and use k=6 heads with the same network structure to simultaneously predict multiple target points to achieve the goal of balancing decoding efficiency and performance. The specific formula is:

[0046]

[0047] where ψ k,x It is represented as a prediction head that passes through a linear layer and then uses a softmax function to obtain the distribution score. The output of the decoder g k is the candidate coordinate Si Get the corresponding prediction target.

[0048] Step 4: Finally, a two-layer MLP network structure is used to complete multimodal trajectory generation.

[0049]

[0050] Where L traj is the trajectory completion loss. t and are the future trajectory and predicted trajectory of the target vehicle, respectively.

[0051] L=L lane +L goal +L traj

[0052] Where L is the loss function of the entire model.

[0053] Step 5: Perform validation comparison on this model on the test set.

[0054] Beneficial effects of the present invention:

[0055] 1. For each semantic element, such as a vehicle and a lane segment, the present invention constructs a local reference frame to decouple the vectorized features between elements and their relative postures, so as to learn a traffic scene representation independent of the global spatiotemporal coordinate system, so that each scene element generates a unique and invariant representation to achieve faster online reasoning.

[0056] 2. The present invention constructs a scene context encoding module based on factorized attention Transformer. Under the local spatiotemporal coordinate system encoding, a feature fusion method for querying cross-attention along the axis of the target vehicle is proposed. By injecting multiple key-value pairs to guide and enhance the information acquisition of the target vehicle, the goal of scene context global feature fusion is achieved, and the computational efficiency and real-time prediction accuracy are improved. At the same time, when performing attention-based scene context fusion, the historical time attention, target-map attention, and vehicle-to-vehicle interaction attention are stacked in sequence as a fusion block. By iteratively learning the fusion block, the information update between the scene elements is realized, which helps the model to achieve accurate prediction in dynamic and complex scenes.

[0057] 3. The present invention constructs a multimodal motion prediction decoding module based on target points. Dense target candidate points and their probabilities are generated from the scene context, a target point predictor is designed to select candidate targets on highly potential lane segments, and a multimodal target decoder is introduced to further capture a set of high-quality target states, thereby effectively filtering and suppressing redundant target points, reducing the representation requirements for subsequent target trajectory generation. Finally, the trajectory generation module is used to obtain a final set of compact and diverse predictions, achieving highly reliable and interpretable multimodal trajectory output. BRIEF DESCRIPTION OF THE DRAWINGS

[0058] Figure 1 The present invention is a flowchart of the method.

[0059] Figure 2 Schematic diagram of attention encoding for scene context.

[0060] Figure 3 Schematic diagram of multimodal motion prediction decoding. DETAILED DESCRIPTION

[0061] The present invention will be further described below in conjunction with the accompanying drawings.

[0062] The present invention provides an accurate and efficient method for predicting the trajectory of vehicles around an autonomous driving vehicle. Figure 1 As shown in the figure. The model processes multimodal input to produce scene encoding. The scene encoding is used as the context of the decoder to generate highly reliable and interpretable multimodal trajectory output covering the output space. Specifically, it includes the following steps:

[0063] (1) First, the trajectory prediction problem is described as follows: In a certain driving environment, assume that there are A surrounding targets in the scene where the target vehicle is located. It is known that the target vehicle i has been h The time step history trajectory information is expressed as: Predict the target vehicle’s future t f Trajectory information for time step segments Each trajectory Refers to the position coordinate information at a future time, where the superscript t = 1, 2, ... t f The specific expressions are as follows:

[0064] 1) Vectorize all scene information: The motion state characteristics of target vehicle i at time step t include its spatial position Heading Angle Acceleration and speed Equal motion parameters, where t∈t h , are the horizontal and vertical coordinates of the vehicle in the coordinate system. Each trajectory motion vector is defined as in Respectively represent the starting and ending positions of the target vehicle i within the time step t. At the same time, obtain the M polygon shape on the high-definition map. For a lane segment C, Each lane vector Where N represents the total vector length, are the starting and ending coordinates of the lane segment respectively.

[0065] 2) A local spatiotemporal coordinate system is established for each scene element (including lanes, crosswalks, vehicles, pedestrians, etc.). The local spatiotemporal coordinate system is established by the spatiotemporal position of the target vehicle state and the reference direction. For lanes and crosswalks, the position and direction at the centerline entry point are selected as the reference.

[0066] 3) Embedding of multiple scene elements: Calculate the polar coordinates of all geometric attributes (such as the speed and motion vector of the target vehicle state, the position of all sampling points on the lane) based on the spatiotemporal position and direction referenced in the local coordinate system. Convert each polar coordinate into Fourier features and embed them through a multi-layer perceptron (MLP) to obtain the embedding A of the target vehicle i i t , an attention-based pooling operation is applied to the sample point embedding m within each map polygon i .

[0067] 4) At the same time, in order to retain all the spatiotemporal position information of the scene element pairs, the relative spatiotemporal position is embedded. Specifically: Take the target vehicle i at time step t and the surrounding target j at time step u as an example (0 <u<t h ), whose absolute space-time positions are expressed as and Including its relative distance Relative Direction Relative position And the time interval ut. Then through the multi-layer perceptron (MLP) processing, the relative position embedding representation is generated as If either of the two scene elements is static (such as a lane segment), the embedding can be simplified to τ j:i .

[0068] (2) This paper constructs a Transformer scene attention context encoding module based on factored attention. The scene elements are encoded into their local coordinate system, and with the help of relative spatiotemporal position embedding, an efficient feature fusion method for querying cross-attention along the target vehicle axis is proposed, such as Figure 2As shown. By injecting multiple key-value pairs to guide, the target vehicle scene context information feature acquisition capability is enhanced, and the target vehicle feature representation is iteratively updated to achieve the goal of obtaining the final target information embedding. The specific implementation process is as follows:

[0069] 1) First, self-attention is used to capture the relationship between map elements, from the map embedding m i Extract a Query value from it and let it focus on its adjacent lanes and crosswalks Where N i is the map polygon m i The neighbor collection step is:

[0070]

[0071] Where MHA(a, b, c) represents attention, a is the query, b is the key, and c is the value. The specific calculation of the attention function is as follows:

[0072]

[0073] In which, the spatial perception of the map encoding is combined, and the adjacent polygon encoding and relative position embedding cascade operation is recorded as Brief Notes To calculate the jth Key and Value. are query matrix, key matrix and value matrix respectively, W Q , W K , W V is a learnable linear projection matrix, d k are the dimensions of the Q, K, and V vectors.

[0074]

[0075] Among them, M i is a map encoding output using self-attention that can be shared across all vehicles and all time steps.

[0076] 2) Before performing attention, the key and value elements in the attention layer are concatenated with the spatiotemporal position embeddings relative to the query element.

[0077] First, the target vehicle information fused with the past time steps is mapped to the current state, so that the model can learn the previous motion information encoding. The historical time attention is used to learn the temporal dependencies within its region. The formula is the same as above:

[0078]

[0079] Among them, from the target vehicle state embedding Derive the query vector Query value By considering the target vehicle i from time step tx(0 <x<t h ) to the time step t-1 and the corresponding relative position embedding combination, denoted as Calculate the Key and Value values ​​to perform historical time attention operations and obtain the updated target features

[0080] 3) Then, in order to reflect the impact of map environment information on vehicle prediction, the map information updated by self-attention is integrated into the intelligent agent embedding. The formula is:

[0081]

[0082] Among them, using the output map encoding Export Key and Value values ​​to complete the target - map attention, and get the target features of the map information

[0083] 4) Then, an interactive attention module is used to aggregate spatial information, thereby learning the environmental information and surrounding vehicle information that have a greater impact on the target vehicle's driving. The formula is:

[0084]

[0085] The state and relative spatiotemporal position of the surrounding intelligent agents are embedded in the combination Export the Key and Value values ​​to complete the interaction between vehicles and obtain the final fusion target features The neighbor set N i Determined by a distance threshold of 50 meters.

[0086] 5) Repeat the first three steps 1)-3) and use the unchanged key and value to continuously update the initial unchanged query. Stack the historical time attention, target-map attention, and vehicle-to-vehicle interaction attention in sequence as a fusion block, and update it multiple times through iterations, denoted by the number L enc , to realize the update information flow between different scene elements and output the final tensor.

[0087] (3) The present invention constructs a multi-modal motion prediction decoding module based on the target point, such as Figure 3 As shown. Dense target candidates and their probabilities are generated from the scene context, a target point predictor is designed to select only candidate targets on highly potential lane segments, and a multimodal target decoder is introduced to further effectively capture a set of high-quality target states, thereby effectively filtering and suppressing redundant target points and reducing the representation requirements for subsequent target trajectory generation. The specific implementation process is as follows:

[0088] 1) The number of sampled target candidates depends on the lanes around the target vehicle. Since multiple hypothetical targets are freely output based on map elements, a lane scoring selection strategy is used to predict the lane where the target vehicle will appear, which can effectively avoid some unreasonable target points and obtain a reasonable driving lane for the target vehicle. In order to reduce the number of target candidates, the first k lane segments {C1, C2, … C k}, then:

[0089] D(C,C gt )=min(||C1-C gt || 2 ,||C2-C gt || 2 ,…||C k -C gt || 2 )

[0090]

[0091] in Estimate the loss for the lane, To choose to use the binary cross entropy loss function, D(C,C gt ) represents lane C and ground truth lane segment C gt The distance between.

[0092] 2) Since the sampling of dense target points is random, no probability value is provided. Then, the target probability estimation is used to obtain the probability of future target points on the candidate lanes, and the attention mechanism is used to obtain the local information between the target vehicle and the lane. The specific calculation formula is:

[0093] q g =W q Z, k c =W k L, v c =W v L

[0094]

[0095] Among them, W q , W k , W v is the matrix of linear projection, d k is the dimension of Q, K and V vectors, q g is the query vector, k c is the key vector, v c is a value vector, Z and L represent the feature matrices of dense target candidates and all map elements obtained using MLP, and Attn(·) represents the attention mechanism operation.

[0096] Then use the maximum entropy model to score all candidate target points, and then use the softmax function to normalize the scores, taking into account various environmental factors and trajectory characteristics, so as to more accurately evaluate the possibility of each target point. The prediction score of the i-th target can be written as:

[0097]

[0098] Among them, the trainable function g(·) is implemented using a two-layer MLP, Z i The information obtained on the lane for target point i based on the attention mechanism.

[0099]

[0100] in, is the target point loss, is the cross entropy loss function, δ is the predicted target score, The predicted target score δ and the ground truth target score are calculated using the cross entropy loss function. The differences between.

[0101] 3) After the target point predictor above, a heat map describing the probability distribution of potential targets is obtained. The top X candidate targets with the highest scores are selected and their corresponding features, prediction scores and coordinates are obtained. These vectors are first concatenated and MLP is used to obtain the new embedding of the selected nodes, while the self-attention mechanism is used to fuse the global heat map information.

[0102] Then a multimodal target decoder is used with k=6 heads having the same network structure to simultaneously predict X=100 target points, achieving the goal of balancing decoding efficiency and performance.

[0103]

[0104] Among them, ψ k,x It is represented as a prediction head that passes through a linear layer and then uses a softmax function to obtain the distribution score. The output of the decoder g k is the candidate coordinate S i Obtain the corresponding predicted target, including the 6 most likely target points.

[0105] (4) Finally, each trajectory is completed according to the predicted target set. The features of each target point are passed to the decoder, and a two-layer MLP network structure is used to complete the multimodal trajectory generation.

[0106]

[0107] in is the trajectory completion loss. is the Huber loss function, Y t and are the future trajectory and predicted trajectory of the target vehicle, respectively.

[0108]

[0109] in is the loss function of the entire model. The loss is estimated by the lane Target point loss and trajectory completion loss composition.

[0110] (5) Verify and compare this model on the test set.

[0111] An embodiment of the present invention also proposes an electronic device for an autonomous driving vehicle, or a control device for executing a program of the above-mentioned prediction method, or a storage device for storing the program of the above-mentioned prediction method.

[0112] In summary, the present invention is a method, model and electronic device for predicting the trajectory of vehicles around an autonomous driving vehicle based on an improved Transformer model and target point guidance. The model architecture is mainly composed of a scene context attention encoding module and a multimodal target decoding module. The encoder is used to learn the vector representation of dynamic scenes and their components, so that the target vehicle can efficiently and accurately capture long-term behaviors in complex scenes and interactions with map structures and other surrounding traffic entities. The decoder predicts conditionally based on the target point and uses a trajectory generation module to generate a multimodal future trajectory of the vehicle. By using the trajectory prediction model for vehicles around an autonomous driving vehicle provided by the present invention to predict multimodal trajectories, reliable and accurate prediction results can be obtained.

[0113] The series of detailed descriptions listed above are only specific descriptions of feasible implementation methods of the present invention. They are not intended to limit the scope of protection of the present invention. All equivalent methods or changes that do not deviate from the technical creation of the present invention should be included in the scope of protection of the present invention.

Claims

1. A method for predicting trajectory of an autonomous driving vehicle based on an improved Transformer model and target point guidance, characterized in that: The steps include: Step 1: Trajectory prediction problem description: In a certain driving environment, assume that there are A surrounding targets in the scene where the target vehicle is located, and it is known that the target vehicle i has been in the past t h The time step history trajectory information is expressed as: Predict the target vehicle’s future t f Trajectory information for time step segments Each trajectory Refers to the location coordinate information at a future time; Step 2: Encode scene elements into their local coordinate system, and with the help of relative spatiotemporal position embedding, adopt an efficient feature fusion method of querying cross-attention along the target vehicle axis, inject multiple key-value pairs to guide the enhancement of the target vehicle scene context information feature acquisition capability, and iteratively update the target vehicle feature representation to achieve the goal of obtaining the final target information embedding; Step 3: Generate dense target candidates and their probabilities from the scene context, design a target point predictor to select only candidate targets on highly potential lane segments, and introduce multimodal target decoding to further capture a set of high-quality target states, effectively filter and suppress redundant target points, and reduce the representation requirements for subsequent target trajectory generation; Step 4: Finally, use the two-layer MLP network structure to complete multimodal trajectory generation.

2. The method for predicting trajectory of an autonomous driving vehicle based on an improved Transformer model and target point guidance according to claim 1, characterized in that: The specific implementation of step 1 includes the following: Step 1.1: Vectorize all scene information: The motion state characteristics of target vehicle i at time step t include its spatial position Heading Angle Acceleration and speed Equal motion parameters, where (t∈t h ). Each trajectory motion vector is defined as in Respectively represent the starting and ending positions of the target vehicle i within the time step t; at the same time, obtain the M polygon shape on the high-definition map. For a lane segment C, Each lane vector Where N represents the total vector length, are the starting and ending coordinates of the lane segment respectively; Step 1.2: From the target vehicle state and spatiotemporal position and reference direction Determine and establish a local space-time coordinate system. For lanes and crosswalks, select the location and direction of the centerline entry point as a reference; Step 1.3: Embedding of multiple scene elements: For each spatiotemporal scene element, the polar coordinates are converted into Fourier features and embedded through a multi-layer perceptron (MLP) to obtain the embedding of the target vehicle i Embed m for each sample point in the map polygon i Adopt attention-based pooling operation; Step 1.4: In order to retain all the spatiotemporal position information of the scene element pairs, the relative spatiotemporal positions are embedded. Specifically, for the target vehicle i and the surrounding target j, their absolute spatiotemporal positions are expressed as and Specifically including relative distance Relative direction Relative position and time interval ut; then processed by a multi-layer perceptron (MLP), a relative position embedding is generated, expressed as If either of the two scene elements is static, the embedding can be simplified to τ j:i .

3. The method for predicting trajectory of an autonomous driving vehicle based on an improved Transformer model and target point guidance according to claim 1, characterized in that: The specific implementation of step 2 includes the following: Step 2.1: First, use self-attention to capture the relationship between map elements, from the map embedding m i Extract a Query value from it and let it focus on its adjacent lanes and crosswalks Where N i is the map polygon m i The neighbor collection step is: Where MHA(a, b, c) represents attention, a is the query, b is the key, and c is the value. The specific calculation of the attention function is as follows: The spatial perception of the map encoding is combined with the cascade operation memory from adjacent polygon encoding and relative position embedding. Brief Notes To calculate the jth Key and Value, and are query matrix, key matrix and value matrix respectively, W Q , W K , W V is a learnable linear projection matrix, d k is the dimension of the Q, K and V vectors, M i Represented as a map encoding using self-attention output; Step 2.2: Concatenate the key and value elements in the attention layer with the spatiotemporal position embedding relative to the query element, where the key and value elements are embedded from the target vehicle state embedding Derive the query vector Query value The target vehicle information fused with the past time steps is mapped to the current state to learn the previous motion information encoding. First, the historical time attention is used to learn the temporal dependencies within its region. The formula is: Among them, by considering the target vehicle i from time step tu(0 <u<t h ) to the time step t-1 and the corresponding relative position embedding combination, denoted as Calculate the Key and Value values ​​to perform time attention operations; Step 2.3: Then, in order to reflect the impact of map environment information on vehicle prediction, the map information updated by self-attention is fused into the agent embedding. The formula is: Among them, using the output map encoding Export Key and Value to complete the goal - map attention; Step 2.4: Aggregate spatial information through interactive attention and learn the environmental information and surrounding vehicle information that have a great impact on the target vehicle's driving. The formula is: Among them, the state and relative spatiotemporal position of surrounding vehicles are embedded in the combination Export Key and Value to complete the social attention between vehicles, neighbor set N i Determined by a distance threshold of 50 meters; Step 2.5: Repeat steps 2.2 to 2.4, stacking the historical time attention, target-map attention, and vehicle-to-vehicle interaction attention sequentially as a fusion block, and iteratively update L enc times to realize the update information flow between different scene elements and output the final tensor.

4. The method for predicting trajectory of an autonomous driving vehicle based on an improved Transformer model and target point guidance according to claim 1, characterized in that: The specific implementation of step 3 includes the following: Step 3.1: First, a lane scoring selection strategy is used to predict the lane where the target vehicle will appear, so as to reduce the number of target candidates and select the first k lane segments {C1, C2, … C k }, then: D(C,C gt )=min(||C1-C gt || 2 ,||C2-C gt || 2 ,…||C k -C gt || 2 ) L lane =L cls (C,C gt ) Where D(C,C gt ) represents lane C and ground truth lane segment C gt The distance between lane Estimate damages for driveways; Step 3.2: Then, the target probability estimation is used to obtain the probability of the future target point on the candidate lane, and the attention mechanism is used to obtain the local information between the target vehicle and the lane. The specific calculation formula is: q g =W q Z,k c =W k L,v c =W v L Where Z and L are feature matrices of dense target candidates and all map elements obtained using MLP; Then use the maximum entropy model to score all candidate target points, where the prediction score of the i-th target can be expressed as: The trainable function g(·) is implemented using a two-layer MLP; Where L goal is the target point loss, using the cross entropy loss function to calculate the predicted target score δ and the ground truth target score The differences between Step 3.3: After the above target point predictor, a heat map describing the probability distribution of potential targets is obtained. The top X candidate targets with the highest scores are selected, and their corresponding features, prediction scores and coordinates are obtained. Then these vectors are connected and MLP is used to obtain the new embedding of the selected nodes. At the same time, the self-attention mechanism is used to fuse the global heat map information. Then, the multimodal target decoder is used, and k=6 heads with the same network structure are used to simultaneously predict multiple target points to achieve the goal of balancing decoding efficiency and performance. The specific formula is: where ψ k,x It is represented as a prediction head that passes through a linear layer and then uses a softmax function to obtain the distribution score. The output of the decoder g k is the candidate coordinate S i Get the corresponding prediction target.

5. The method for predicting trajectory of an autonomous driving vehicle based on an improved Transformer model and target point guidance according to claim 1, characterized in that: In step 4, the loss function of the two-layer MLP network is designed as follows: Where L traj is the trajectory completion loss, Y t and are the future trajectory and predicted trajectory of the target vehicle, respectively.

6. An autonomous driving vehicle trajectory prediction model based on an improved Transformer model and target point guidance, characterized in that: include: scene context attention encoder and multimodal motion decoder; The scene context attention encoder is used to process multiple scene element inputs in a local spatiotemporal coordinate system to generate a scene encoding, which is used as a context for a multimodal motion decoder to capture a set of high-quality target states, and a trajectory generation module generates k possible multimodal trajectories covering the output space; The scene context attention encoder implements the content of step 2 described in any one of claims 1-5; The multimodal motion decoder implements the content of step 3 described in any one of claims 1-5.

7. The prediction model according to claim 6, characterized in that The prediction model also includes: a vectorized scene representation module, which can implement the content of step 1 described in any one of claims 1-5.

8. The prediction model according to claim 6, characterized in that The trajectory generation module adopts the two-layer MLP network described in any one of claims 1-5.

9. The prediction model according to claim 6, characterized in that The total loss function L of the prediction model is composed of the lane estimation loss L of claim 4 lane 、Target point loss L goal and the trajectory completion loss L of claim 5 traj composition: L=L lane +L goal +L traj .

10. An electronic device for an autonomous driving vehicle, characterized in that: The device is capable of executing the program of the prediction method of claims 1-5, or storing the program of the prediction method of claims 1-5.

Citation Information

Patent Citations

  • Urban scene-oriented vehicle trajectory prediction method and system, and storage medium

    CN115009275A

  • Multi-modal vehicle trajectory prediction method based on hierarchical order network

    CN116513240A

  • Automatic driving vehicle driving track planning method, device and equipment and storage medium

    CN117492447A

  • Trajectory prediction using efficient attention neural networks

    US20230406360A1

Cited By

  • Multi-feature fusion target trajectory prediction method based on Transform model

    CN119600055A

  • Unmanned ship automatic control method based on multi-modal feature fusion

    CN119717801A

  • Method for predicting tracks of various traffic participants in autonomous driving system based on flexible anchor points

    CN119940118A

  • Method for trajectory prediction of diverse traffic participants in autonomous driving system based on flexible anchor point

    CN119940118B

  • Transform and end point induction-based multi-modal trajectory prediction method for automatic driving vehicle

    CN119975390A