Intelligent driving prediction model construction method, prediction method, device and medium

Through the vectorization representation and Transformer algorithm, the problem of multi-source heterogeneous data alignment in autonomous driving technology is solved, the accuracy and efficiency of agent driving data prediction are improved, and efficient model construction and prediction performance improvement are achieved.

CN118306428BActive Publication Date: 2024-10-01LIANYI YUNKE (BEIJING) TECH CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202410725180.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-06-06
Publication Date
2024-10-01
Estimated Expiration
2044-06-06

AI Technical Summary

Technical Problem

Existing deep learning-based agent driving data prediction methods in autonomous driving technology are difficult to align the time and space dimensions when processing multi-source heterogeneous data, resulting in a waste of computing resources and increased learning difficulty, affecting prediction accuracy and credibility.

Method used

The vectorization representation method is used to uniformly represent the agent's historical trajectory and scene data, and a prediction model based on the Transformer algorithm is constructed to capture trajectory characteristics and ignore redundant data, efficiently model road topological relationships, and reduce the difficulty of model learning.

Benefits of technology

It improves the accuracy and efficiency of agent driving data prediction, avoids the problem of difficulty in aligning multi-agent data in time and space dimensions, reduces the waste of computing resources, and improves the performance of trajectory and behavior prediction.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118306428B_ABST
    Figure CN118306428B_ABST
Patent Text Reader

Abstract

The present invention discloses a method for constructing an intelligent driving prediction model, a prediction method, a device and a medium, including: obtaining historical trajectory data and historical scene data of each intelligent agent in an intelligent agent set; vectorizing the historical trajectory data and historical scene data to obtain a trajectory vector feature matrix, a lane vector feature matrix and a lane vector adjacency matrix; based on a setting algorithm, using the trajectory vector feature matrix, the lane vector feature matrix and the lane vector adjacency matrix, constructing a target prediction model, the target prediction model is used to predict the driving data of the intelligent agent to be predicted at the next moment. The present invention performs vector unified representation processing on the acquired multi-source heterogeneous data, so that when constructing a prediction model, it is possible to capture the characteristics of the historical trajectory, ignore useless redundant data, describe useful topological data, efficiently model the topological relationship between roads, provide accurate input for the construction of the prediction model, and realize efficient and rapid construction of the target prediction model.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of autonomous driving, and in particular to a method for constructing an intelligent body driving prediction model, a prediction method, a device and a medium. Background Art

[0002] Autonomous driving technology is one of the important transformative technologies for the future of automobiles. As a link between the upper and lower parts of the autonomous driving algorithm process, the prediction module represents and understands low-level environmental perception data in a high-level abstract manner and outputs the future state of the surrounding intelligent bodies.

[0003] At present, with the help of deep neural networks, self-driving cars can infer and predict the movement trajectory, behavioral intentions and risk levels of surrounding intelligent bodies with high accuracy, thereby improving the accuracy and solution speed of self-driving car decision-making and planning modules. The prediction method based on deep learning has surpassed the rule-based and machine learning methods in terms of accuracy and generalization, and is also a research hotspot in the field of autonomous driving.

[0004] However, in related technologies, when making predictions based on deep learning, a serialized trajectory input format is used for the collected multi-source data. Since the duration of the perceived agent trajectory data may vary, it is difficult for the serialized input to represent input and output of varying lengths, which in turn makes it difficult to align the time and space dimensions of multiple agents. Moreover, the redundant input of rasterized input not only wastes computing resources, but is also likely to affect the performance of trajectory and behavior prediction. The spatial topological relationship between roads and agents is not explicitly modeled, which may increase the difficulty of network learning. Ultimately, in the face of complex and changing traffic scenarios, the accuracy and high credibility of its predictions are still insufficient. Summary of the invention

[0005] The problem solved by the present invention is how to improve the prediction accuracy of intelligent body driving data.

[0006] In order to solve the above problems, in a first aspect, the present invention provides a method for constructing an intelligent body driving data prediction model, the method comprising:

[0007] Acquire historical sequence data of the agent, the historical sequence data including historical trajectory data and historical scene data of each agent in the agent set, the historical scene data being environmental data in the scene where the agent is located that affects the trajectory of the agent;

[0008] Performing vector representation on the historical trajectory data and the historical scene data to obtain a trajectory vector feature matrix corresponding to the historical trajectory data, a lane vector feature matrix corresponding to the historical scene data, and a lane vector adjacency matrix;

[0009] Based on the transformer algorithm, a target prediction model is constructed using the trajectory vector feature matrix, the lane vector feature matrix and the lane vector adjacency matrix. The target prediction model is used to predict the driving data of the intelligent body to be predicted at the next moment according to the historical sequence data of the intelligent body to be predicted. The driving data includes the target trajectory data and target behavior data of the intelligent body to be predicted. The target trajectory data includes at least one driving trajectory of the intelligent body to be predicted at the next moment, and its corresponding probability. The target behavior data includes the operation behavior label and lane line intention label of the intelligent body to be predicted at the next moment.

[0010] In a second aspect, the present invention provides a method for predicting driving data of an intelligent agent, the method comprising:

[0011] Obtaining historical sequence data of the intelligent agent to be predicted, the historical sequence data including trajectory data and scene data of each intelligent agent to be predicted in the set of intelligent agents to be predicted, the scene data being environmental data affecting the trajectory of the intelligent agent in the scene where the intelligent agent to be tested is located;

[0012] The historical sequence data is input into the target prediction model constructed in the method for constructing the intelligent agent driving prediction model as in the first aspect above, and the driving data of each intelligent agent to be predicted at the next moment is output, wherein the driving data includes the target trajectory data and target behavior data of the intelligent agent to be predicted, wherein the target trajectory data includes at least one driving trajectory of the intelligent agent to be predicted at the next moment, and its corresponding probability, and the target behavior data includes the operation behavior label and lane line intention label of the intelligent agent to be predicted at the next moment.

[0013] In a third aspect, the present invention provides a computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the method described in the first or second aspect above when executing the program.

[0014] In a fourth aspect, the present invention provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program is used to implement the method described in the first aspect or the second aspect.

[0015] The intelligent agent driving prediction model construction method, prediction method, device and medium provided by the present invention perform vector unified representation processing on the multi-source heterogeneous data of each intelligent agent obtained, so that under the vectorized input of the sequence data, each trajectory and lane line of the intelligent agent is represented by a vector with attributes, so that when the prediction model is constructed, the characteristics of the historical trajectory of each intelligent agent can be captured, useless redundant data can be ignored, useful topological data can be described, and the topological relationship between roads can be efficiently modeled, so as to provide accurate input for the construction of the prediction model, reduce the learning difficulty of the model, and finally realize the efficient and rapid construction of the target prediction model for intelligent agent driving prediction, avoiding the defects of multi-agent data being difficult to align in time and space dimensions under the input method based on trajectory time series, and avoiding the input format based on raster map, which contains many non-interesting scenes, resulting in waste of computing resources, and thus affecting the performance of trajectory and behavior prediction. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] Figure 1 A schematic diagram of a process for constructing a driving data prediction model for an intelligent agent according to some embodiments of the present invention;

[0017] Figure 2 A schematic diagram of vectorized lane lines in some embodiments of the present invention;

[0018] Figure 3 A schematic diagram of the principle of vectorized feature extraction in some embodiments of the present invention;

[0019] Figure 4 A schematic diagram of a process for constructing an intelligent agent driving prediction model in some embodiments of the present invention;

[0020] Figure 5 A schematic diagram of a process for constructing an intelligent agent driving prediction model according to some embodiments of the present invention;

[0021] Figure 6 A schematic diagram of a process for constructing an intelligent driving prediction model for some embodiments of the invention;

[0022] Figure 7 Schematic diagram of feature fusion in some embodiments of the present invention;

[0023] Figure 8 Schematic diagram of prediction results of some embodiments of the present invention;

[0024] Fig. 9 Schematic diagram of prediction results of some embodiments of the present invention;

[0025] Fig.10 Schematic diagram of prediction results of some embodiments of the present invention;

[0026] Fig.11Schematic diagram of prediction results of some embodiments of the present invention;

[0027] Fig.12 Schematic diagram of prediction results of some embodiments of the present invention;

[0028] Fig.13 Schematic diagram of the structure of computer equipment according to some embodiments of the present invention. DETAILED DESCRIPTION

[0029] The present invention will be further described in detail below in conjunction with the accompanying drawings and embodiments. It is to be understood that the specific embodiments described herein are only used to explain the relevant invention, rather than to limit the invention. It is also necessary to explain that, for ease of description, only the parts related to the invention are shown in the accompanying drawings.

[0030] It should be noted that, in the absence of conflict, the embodiments of the present invention and the features in the embodiments can be combined with each other. The present invention will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.

[0031] It can be understood that the prediction and estimation of the driving data of surrounding intelligent bodies, that is, the behavior and trajectory, of autonomous vehicles is the key to determining the next behavior decision and path planning of the vehicle.

[0032] The agent can communicate with intelligent physical obstacles around the autonomous driving vehicle, such as motor vehicles, non-motor vehicles, pedestrians, etc., which may change their positions in the future, as well as itself.

[0033] The role of the prediction model is to model the interactions among the intelligent agent set, including the self-vehicle (i.e., the target intelligent agent), surrounding intelligent agents, and the road environment, and output the driving data of the target intelligent agent and surrounding intelligent agents in the future, including movement trajectories and behavioral intentions. The prediction of intelligent agent driving data with high accuracy can improve the safety, stability, and comfort of the self-vehicle behavior decision-making and path planning, and is the basis for autonomous vehicles to move from automation to intelligence.

[0034] In order to solve the problem that the time and space dimensions of multiple agents are difficult to align due to conventional serialized trajectory input in multi-source heterogeneous input scenarios in complex scenarios, and the problem that the gridded input leads to a waste of computing resources, which leads to an increase in the difficulty of network learning and can affect the performance of trajectory and behavior prediction, the present invention provides a prediction model construction method and prediction method for the multimodal behavior and trajectory of agents under multi-source data fusion. By introducing an input method based on vectorized representation, each trajectory and lane line of the agent is represented by a vector with attributes under vectorized input of the training data. And the spatial topological relationship between each vector is continuously, meticulously and semantically linked, thereby reducing the learning difficulty of the model. In addition, since the vectorized representation is not limited by the fixed size of the input image, the vector of interest can be selected at will through the flag bit, thereby improving the input utilization rate. Finally, the vectorized map describes useful topological data for description, and useless redundant data can be ignored. For example, whether it is a scene with a close aspect ratio such as a roundabout and an intersection, or a scene with a larger aspect ratio such as a straight road, the vectorized input representation can efficiently model the topological relationship between roads.

[0035] In order to better understand the intelligent body driving data prediction model construction method and prediction method provided by the present invention, it is described in detail below with reference to the accompanying drawings.

[0036] Figure 1 FIG. 1 is a flow chart of a method for constructing a driving data prediction model of an intelligent agent according to an embodiment of the present invention. Figure 1 As shown, the method specifically includes:

[0037] S110, obtaining historical sequence data of the agent, wherein the historical sequence data includes historical trajectory data and historical scene data of each agent in the agent set, wherein the scene data is environmental data in the scene where the agent is located that affects the trajectory of the agent.

[0038] S120, performing vector representation on the historical trajectory data and the historical scene data to obtain a historical trajectory vector feature matrix corresponding to the dynamic data, a historical lane vector feature matrix corresponding to the historical scene data, and a historical lane vector adjacency matrix.

[0039] S130, based on the transformer algorithm, using the historical trajectory vector feature matrix, the historical lane vector feature matrix and the historical lane vector adjacency matrix, construct a target prediction model, the target prediction model is used to predict the driving data of the intelligent body to be predicted at the next moment according to the historical sequence data of the intelligent body to be predicted, the driving data includes the target trajectory data and target behavior data of the intelligent body to be predicted, the target trajectory data includes at least one driving trajectory of the intelligent body to be predicted at the next moment, and its corresponding probability, the target behavior data includes the operation behavior label and lane line intention label of the intelligent body to be predicted at the next moment.

[0040] Specifically, in an embodiment of the present invention, the historical sequence data of each agent in the agent set used to construct the prediction model can be first obtained, that is, the historical trajectory data of multiple agents in the agent set under the data collection scenario, as well as the historical scene data that affects the trajectory of each agent in the scenario where the agent is located.

[0041] Among them, the historical trajectory data may specifically include the position data and speed data of each intelligent agent at each historical time point, and the historical scene data may specifically include the environmental data such as lane lines, traffic lights, traffic signs, static obstacles, etc. at each historical time point in the scene where each intelligent agent is located.

[0042] For example, you can get the agent collection {A 1 , A 2 , …A NS}, where NS is the number of sensed agents.

[0043] but .

[0044] where f a is the feature dimension of the agent, t hst is the length of the historical sequence data.

[0045] It can be understood that the historical data of each agent in the above-collected agent set can be collected from high-definition maps, positioning systems and other data sources, including complete scene data. The agent can include all agents in the collection scene, such as vehicles, non-motor vehicles and pedestrians.

[0046] For example, the present invention can use data collected from Argoverse agents. The Argoverse collected data can include data of agents such as cars, bicycles, and pedestrians. All data is collected by vehicles equipped with lidar and cameras at a frequency of 10 Hz.

[0047] It can also be understood that in order to accurately construct the target prediction model, the collected data can be divided into a training data set, a validation data set, and a test data set according to the proportion, such as 205942, 39472, and 78143 data sets. There is no geographical overlap between the data sets to verify the generalization of the model.

[0048] It can be understood that when constructing a prediction model, the above data set can be divided according to time, that is, it can be divided into historical data and data to be predicted according to the collection time.

[0049] For example, the collected data set may contain a 5-second trajectory, with the first 2 seconds as historical input and the last 3 seconds as data to be predicted. The true value of the lane line intention can represent the lane line followed by the agent's trajectory point in the next 1 to 3 seconds.

[0050] Furthermore, after obtaining the above-mentioned historical sequence data, in order to achieve unified representation of multi-source heterogeneous data, the above-mentioned historical trajectory data and historical scene data can be vectorized and uniformly represented to obtain the trajectory vector feature matrix corresponding to the historical trajectory data, and the lane vector feature matrix and lane vector adjacency matrix corresponding to the scene data.

[0051] Finally, after the acquired multi-source heterogeneous data are uniformly represented by vectors, the obtained trajectory vector feature matrix, lane vector feature matrix and lane vector adjacency matrix can be extracted and fused based on the transformer algorithm to construct the final target prediction model. The constructed target prediction model can accurately predict the driving data of each intelligent agent at the next moment in the future according to the historical sequence data of each intelligent agent, that is, output the target trajectory data and target behavior data of each intelligent agent at the next moment.

[0052] Among them, the target trajectory data includes at least one trajectory of each agent in the agent set at the next moment and its corresponding probability, and the target behavior data includes the operation behavior label and lane line intention label of each agent at the next moment.

[0053] That is, the output target trajectory data can be K trajectories of each agent in the set of agents in the prediction scene:

[0054] And the probability p corresponding to each trajectory k .

[0055] Where K is the number of trajectory modes, k=1,2,…,K,t=1,2,…,t fut ; The first and second items in the brackets are the coordinate values ​​corresponding to the trajectory.

[0056] Correspondingly, the output target behavior data can be the operation behavior labels of all agents in the predicted scene at the next moment (such as ), and the lane line intention labels of all agents (such as ), as shown in Table 1 below:

[0057] Table 1

[0058]

[0059] That is, the behavior label of the next moment is labeled according to the future trajectory of the intelligent agent and certain rules.

[0060] Table 1 shows the meaning and labeling rules of agent behavior labels, where the priority indicates that when the current agent meets multiple behavior conditions, the behavior of the current agent is defined according to the priority. Among them, "1" has the highest priority and "6" has the lowest priority.

[0061] For example, when a vehicle changes lanes, it may be accompanied by acceleration or deceleration. According to the priority, the present invention marks the behavior as "Yield+Nudge / Lane change" instead of "Yield+Decrease speed" or "Ignore". Agent behaviors belonging to the Yield class have a higher priority to ensure that the output behavior is more robust. In addition, if the future behavior of an agent is difficult to label, or the perception duration is too short to be labeled, it will be marked as "Unknown" and ignored when calculating the loss.

[0062] Lane intention refers to the lane that the agent depends on for future movement. The lane intention labeling rule is: all lane vectors whose distance to the agent's coordinates is less than half the lane width, and whose angle with the agent's future trajectory direction is no greater than 15°, will be considered.

[0063] It can be understood that in the embodiment of the present invention, by performing vector unified representation processing on the acquired multi-source heterogeneous data, it is possible to capture the characteristics of historical trajectories, ignore useless redundant data, describe useful topological data, and efficiently model the topological relationship between roads when constructing the prediction model, thereby providing accurate input for the construction of the prediction model, and ultimately achieving efficient and rapid construction of the target prediction model, avoiding the defects of multi-agent data being difficult to align in time and space dimensions under the input method based on trajectory time series, and avoiding the input format based on raster graphs, where the input contains many non-interesting scenes, resulting in a waste of computing resources, which can affect the performance of trajectory and behavior prediction.

[0064] That is, the present invention introduces an input method based on vectorized representation. Under vectorized input, each trajectory and lane line is represented by a vector with attributes. The spatial topological relationship between each vector is continuously, meticulously and semantically linked, which reduces the learning difficulty of the model. Since the vectorized representation is not limited by the fixed size of the input image, the vector of interest can be selected at will through the flag bit, thereby improving the input utilization rate. The vectorized map describes the useful topological data and ignores useless redundant data. Whether it is a scene with a close aspect ratio such as a roundabout or an intersection, or a scene with a larger aspect ratio such as a straight road, the vectorized input representation can efficiently model the topological relationship between roads.

[0065] Optionally, in some embodiments of the present invention, in S120, as Figure 2 and Figure 3 As shown in the figure, after the input is uniformly represented by vectorization, each track and lane line is represented by a vector with attributes. That is, all input vectors are constructed into a graph, and the relationship between vectors is represented by the adjacency matrix.

[0066] Specifically, two lane line vectors may be predecessors or successors of each other, or left and right neighbors. In this way, the spatial topological relationship between the vectors can be connected continuously, carefully and semantically, thereby reducing the difficulty of learning the model. In addition, since the vectorized representation is not limited by the fixed size of the input image, the flag bit can be used to arbitrarily select the vector of interest, thereby improving the input utilization rate.

[0067] For example, under vectorized unified input, the above historical sequence data is uniformly represented by vectorization, so that the input data can be expressed as:

[0068] ;

[0069] Among them, B is the size of the mini-batch in deep learning, S is the length of the vector sequence, P is the number of elements in the scene, and F is the feature size, so that all scene elements can be represented in this way.

[0070] In practice, in order to realize the construction of the prediction model, when the training data is uniformly represented, the origin position of the vector representation coordinate system can be determined, that is, any agent in the agent set can be used as the target agent, and its corresponding position can be used as the origin position of the coordinate system.

[0071] After the vector representation processing of the training data, the trajectory vector feature matrix can specifically include the coordinate value, type and indication data of each agent in the local coordinate system with the coordinate position of the target agent as the origin at the first moment, such as the current moment. The indication data indicates whether the agent is perceived at the second moment, such as the next moment, and the first moment is earlier than the second moment.

[0072] For example, for all the above agent sets {A 1 , A 2 , …A NS}, taking the position of the target agent at time t=0, i.e. the first time, as the origin, establish a local coordinate system. The positive direction of the x-axis is defined as the direction of movement (heading) of the target agent, and the y-axis is the direction of the x-axis rotated 90° counterclockwise. The characteristics of the agent at time t, i.e. the second time, are recorded as:

[0073]

[0074] in, is the difference between the x and y coordinates of the agent from time t to time t-1, class is the agent type, flag is a t It is the first indicator data of the agent, indicating whether it is perceived at time t to ensure that all inputs are aligned.

[0075] It can be understood that, through the above vectorized representation, the position coordinates of each agent at time t=0, i.e., the first time, can be used as input to filter the agents of interest of the target agent based on partial prior knowledge.

[0076] Further, if Figure 2 and Figure 3 As shown, in some embodiments of the present invention, the lane vector feature matrix may include basic data, turning data, restriction data, and second indication data, wherein the second indication data indicates whether it is a fork in the road; the lane vector adjacency matrix may include a preceding lane vector, a succeeding lane vector, a right lane vector, a left lane vector, and an incoming or outgoing vector.

[0077] For example, the scene data set S is divided into a lane vector feature matrix M f , and a lane vector adjacency matrix set S a .

[0078] M f =(Δx l , Δy l , heading l , turn l , traf l , intersect l ).

[0079] in, is the basic data of the lane vector, indicating the location information of the agent, turn l Indicates whether the current lane vector is a lane turning left or right, traf lIndicates whether the lane vector is restricted in motion due to traffic lights or lane markings, interest l The second indication data indicates whether the lane vector is within an intersection.

[0080] S a ={M 1:6 p , M 1:6 s , M r , M l , M m , M o}.

[0081] in, , f l is the lane vector feature dimension, N l is the number of lane vectors.

[0082] The adjacency matrix S of lane vectors a The meaning of each matrix in the set is shown in Table 2 below.

[0083] Table 2

[0084]

[0085] Understandably, for simplicity, Figure 3 Only the adjacency relationship between vector 2 and vector 8 is shown in Figure 1. Pairedness indicates that the relationship appears in pairs with the same attributes, and uniqueness indicates whether the relationship appears multiple times for the lane vector. In addition, the position coordinates of the lane vector are used as input to filter the lane lines of interest based on some prior knowledge.

[0086] It can be understood that in the embodiments of the present invention, after the historical sequence data is vectorized and uniformly represented by the methods described in the above embodiments, the data after the representation processing can be further used to construct a prediction model. The construction of the prediction model can specifically include the following steps:

[0087] S131, input the agent trajectory vector feature matrix, lane vector feature matrix and lane vector adjacency matrix into the initial prediction model constructed based on the improved transformer algorithm, and output the initial prediction result and the corresponding loss function.

[0088] S132, performing iterative training of the initial model according to the loss function and the set loss function threshold to obtain the target prediction model, so that when the target prediction model outputs the target prediction result, the corresponding loss function reaches the set loss function threshold.

[0089] Specifically, when training the prediction model, we can first build an initial prediction model based on the transformer algorithm, and then input the feature data after vectorization representation processing into the built initial prediction model, perform up-convolution feature extraction and fusion on the feature data, and then perform down-convolution decoding operation on the fused features to output the prediction results of this training, that is, the initial prediction results of the trajectory data and behavior data of the intelligent agent, and the corresponding loss function.

[0090] Furthermore, based on the output initial prediction results, loss function, set loss function threshold and verification data set, the initial prediction model is iteratively trained and parameters are updated to finally obtain the target prediction model so that the corresponding loss function meets the pre-set loss function threshold requirement.

[0091] Optionally, in some embodiments of the present invention, in S130, the construction of the prediction model may be implemented by using an improved transformer algorithm.

[0092] Combination Figure 4 and Figure 6 As shown, in S131, the initial prediction model constructed by the improved transformer algorithm may include an encoder, a feature extraction module and a decoder.

[0093] That is, in some embodiments of the present invention, in order to improve the training efficiency and prediction accuracy of the model, a feature extraction module is embedded in the basic transformer algorithm to organically integrate multi-source data by utilizing feature selection sparse attention.

[0094] When the training data is processed once, the above improved transformer algorithm is used for processing. Figure 5 As shown, S131 may specifically include the following steps:

[0095] S01, encoding the trajectory vector feature matrix, the lane vector feature matrix and the lane vector adjacency matrix to obtain kinematic features corresponding to the trajectory vector feature matrix, and static lane vector features and dynamic lane vector features corresponding to the lane vector feature matrix and the lane vector adjacency matrix.

[0096] S02: Using a feature extraction module, extract the kinematic feature, the static lane vector feature, and the dynamic lane vector feature to obtain a feature of interest corresponding to the historical sequence data.

[0097] S03, inputting the extracted feature data of interest into the decoder, and outputting the initial prediction result and the corresponding loss function.

[0098] Specifically, in order to improve the training efficiency and prediction accuracy of the model, the improved transformer algorithm can first encode the feature data after vectorized unified representation processing. Then, the encoded data is subjected to feature fusion using the feature selection sparse attention mechanism in the feature extraction module, and finally, the selected feature data of interest is input into the decoder for processing to output the prediction result.

[0099] Further, combined with Figure 4 and Figure 6 In some embodiments of the present invention, in order to improve the efficiency of building a prediction model and the accuracy of the output of the constructed prediction model, three attention mechanisms can be used to improve the performance of the model, namely, using a sparse multi-head attention mechanism to suppress the perceptual uncertainty in the agent input; using feature selection sparse attention to organically integrate multi-source data; and finally using lane line scale dot product attention to guide multimodal prediction, thereby improving the interpretability of the model.

[0100] That is, by constructing an improved Transformer algorithm, we can solve the problems of unified representation of multi-source heterogeneous inputs and organic fusion of multi-source data in complex scenarios. This model improves the performance of multimodal behavior and trajectory prediction through three different attention mechanisms. Taking intelligent behaviors such as lane changing and turning as an example, as the behavior proceeds, the attention of the intelligent agent to the lane line gradually changes from the current lane to the target lane. The above conclusion is similar to human intuition, which shows that the lane line intention attention has a high degree of credibility.

[0101] In detail, combined Figure 4 As shown, in the embodiment of the present invention, the agent trajectory vector feature matrix, lane vector feature matrix and lane vector adjacency matrix are obtained respectively through vector representation processing. Then, sparse multi-head attention encoding can be used for the agent trajectory vector feature matrix to obtain the corresponding kinematic features, reducing the influence of noise; the lane vector feature matrix and the lane vector adjacency matrix are encoded by lane line convolution to obtain the corresponding static lane vector features and dynamic lane vector features, thereby improving the topological extraction capability of the lane line. Subsequently, the feature selection network, i.e., the feature extraction module, organically integrates the agent features and the lane line features, and uses the attention weight as the output of the behavior and lane line intention, and uses the regularization term during error back propagation to improve the accuracy of trajectory prediction.

[0102] It can be understood that since the original Transformer uses scaled dot product attention, a global position representation is required, so a positional embedding (PE) layer is used, and the feature dimension after the input representation is d model :

[0103]

[0104]

[0105] Where i=1,2,…,[d model / 2 ], the standard scaled dot-product self-attention mechanism includes query sequence Query, key sequence Key, , value sequence Value, Where L is the sequence length, which is equal to the input sequence size t in the first sparse attention. hst , d is the characteristic size of h heads, where d model =h d The input of the attention module is denoted as X A , Q, K, V are obtained through linear layer transformation. Then, the self-attention mechanism is described by the following formula:

[0106] .

[0107] It can also be understood that in the embodiment of the present invention, the largest Nd time steps are selected according to the KL divergence to replace the original self-attention. However, due to the existence of an exponential function in the equation, the calculation of the KL divergence may cause an unstable numerical overflow problem. Therefore, the present invention uses an approximate value instead:

[0108]

[0109] The replaced M value can be understood as the difference between the dominant term and the average value of the attention weight. If the difference between the two is smaller, it means that the importance of this time step is smaller. In sparse attention, all q i M value, i = 1, 2, ..., L, select the largest Nd time steps, and the remaining unselected LN d The time steps are directly replaced by uniform distribution, and the new query matrix dN ds×Q directly replaces the original Q. Therefore, the original attention in the above formula becomes:

[0110]

[0111] After sparse self-attention, in order to further increase the impact of useful features, the present invention uses the convolutional pooling unit shown in the model framework diagram. After Nx sparse attention / one-dimensional convolution blocks, the encoder encodes the dynamic and kinematic features of the agent. x-1The first 1D convolution block consists of two 1D convolution normalization layers and a nonlinear activation layer, and then the more significant convolution features are selected by max pooling to better suppress the influence of noise. The sequence length is reduced by max pooling (dividing the length of the sequence by 2), and the last 1D convolution block uses average pooling to compress the sequence length to 1, because when the receptive field is large, all features may affect the prediction.

[0112] Furthermore, for lane vector features, the lane vector is encoded using LaneGCN. Since the agent moves long distances at a faster speed on the lane vector, it is not enough to convolve only one preceding lane vector or a succeeding lane vector. In order to capture long-term dependencies, LaneGCN extends the lane line convolution to focus on more preceding and succeeding lanes at multi-scale levels, i.e., the agent lane line vector :

[0113]

[0114] Among them, M f and M i Referring to the above embodiment, W is the weight of LaneConv, k C is the cth dilation size. Normalization and ReLU activation function are used after each lane line convolution layer and linear layer. After Ng LaneGCN blocks, the static lane vector X out SL Feature completion encoding.

[0115] Static lane vector feature, i.e. X out SL , describes the topological structure of the lane of interest, but lacks the dynamic scene data of the agent. Dynamic scene data refers to the additional attributes generated when the agent uses the scene. The behavior of the agent in dealing with road congestion, non-lane right owner invasion and ordinary scenes is also different. Therefore, the dynamic lane vector feature is very important for the trajectory prediction and behavior prediction of the agent. In order to extract the dynamic lane vector feature, the present invention uses the static lane line feature X out SL Based on Ng LaneGCN blocks, the data of each agent is integrated into the lane vector through the feature selection sparse attention mechanism. Then, the data of each lane line is transmitted again through Lane GCN, so that the lane line has traffic flow and agent lane occupancy data. After Ng LaneGCN blocks, the dynamic lane vector encoding feature X is obtained. out SL .

[0116] As you can understand, the encoder above outputs three features: the kinematic features of the agent, and the static and dynamic lane vector features. When these features are fused, irrelevant features make it more difficult for the neural network to learn. A common approach is to calculate the distance between the target agent and all surrounding scene elements; this distance is then used as an additional feature to allow the network model to understand the importance of surrounding agents and scene elements at different distances. When the target agent learns from the surrounding lane lines, there may be hundreds of lane vectors.

[0117] In practice, only a small number of lane lines are more important to the target agent. Therefore, it is necessary to remove redundant features in the lane vector to avoid transmitting too much redundant invalid data and increase the difficulty of learning. Unlike the original input that lacks prior knowledge, the agent usually only pays attention to the lane and other agents within a certain range.

[0118] That is, in some embodiments of the present invention, in S03, the present application can purposefully select scene elements that need to be paid attention to, and proposes a feature extraction module that organically integrates multi-cue features, which is mainly implemented by feature selection sparse attention.

[0119] In detail, the input of the feature selection sparse attention is the base feature (Base) and the context feature (Context), that is, under the premise of partial prior knowledge, the base feature focuses on useful context features. First, the interesting tensor selector is used to select the feature set of interest based on the Euclidean distance between the base and the context:

[0120]

[0121] where d i d j x i 、x j , coordinates in the local coordinate system, ε th is the threshold of the region of interest. Then, the first, second, and third items of the tuple in the set are sent to the linear layer respectively and are recorded as , and .

[0122] The present invention combines context features with distance data Concatenate them and combine them with the base features through a linear layer, using Exponential Linear Units (ELU) as the activation function after normalization:

[0123]

[0124] Among them, W b , W cis the weight of the fully connected layer, b b For bias.

[0125] when When , ELU activation is equivalent to an identity function;

[0126] when Therefore, the present invention adopts a gate selection mechanism to select useful features in context features:

[0127]

[0128]

[0129]

[0130] Among them, W γ , W σ , W g is the weight of the fully connected layer, b γ 、b σ 、b g is the bias, σ(.) is the Sigmoid function, ⊙ is the Hadamard product, and φ is the normalization function; , g is a parameter in the gating mechanism; It is the result after weighted integration of context features; This is the result after filtering the context features.

[0131] Furthermore, the present invention adds the selected features to the original input and normalizes them:

[0132]

[0133] Among them, ⊕ is the index plus, X att b,c The output of sparse attention is selected for the feature. Then it passes through the feedforward layer and the fusion output is X att b,c It is to integrate the context features into the basic features.

[0134] Through the above operations, the basic feature selects features from the interesting context features for feature fusion, which reduces the learning difficulty and realizes the organic fusion of multiple clues.

[0135] That is Figure 6 Shown and Figure 7As shown in Figure 1, in the lane-to-agent feature selection network, the basic feature is the agent and the context feature is the lane vector. The attention module is used to establish the interaction between the agent and the surrounding environment, that is, to build the interaction relationship between the agent and the lane. In the agent-to-agent feature selection network, the basic feature is the target agent and the context feature is other agents. The attention module is used to establish the interaction between different agents, that is, to establish the interaction relationship between each agent. In addition, the above two interactive feature selection sparse attention weights, X att b,c It will be used in subsequent agent behavior prediction.

[0136] After the interaction is established, in order to make full use of the posterior knowledge of lane line intention, lane-scale dot product attention is used. It is worth noting that since there may be multiple lane lines as positive classes in the lane line intention, or there may be no lane lines as positive classes, the Sigmoid function is used instead of the equation for activation.

[0137] Among them, the attention output X att lane is used for the subsequent lane line intention output. After passing through the attention module, the agent feature X att false Combining with multiple clues for decoding.

[0138] That is, through the above feature extraction, the first feature of interest and the second feature of interest are obtained, which represent the features of the effective intelligent agent related to the target intelligent agent in the scene, that is, the effective features after screening.

[0139] That is, further, the data after the above-mentioned feature selection processing is input into the decoder to predict the driving data of the intelligent body and output the corresponding loss function.

[0140] The decoder consists of two parts: behavior prediction and trajectory prediction. For behavior classification tasks, a common practice is to share prediction features during decoding, output the probability distribution prediction of the behavior through SoftMax, and calculate the classification loss. Due to the difference in task similarity between the prediction task and the behavior task, sharing prediction features increases the burden on the decoder.

[0141] Therefore, the present invention uses the attention weight matrix in the attention mechanism as the output of the behavior data, making the semantic data fusion more interpretable, and as a regular term, it links the behavior with the trajectory prediction, reducing the difficulty of network learning. In the behavior prediction branch, the lane line attention weight is the lane behavior probability, and the agent behavior is composed of multiple X att b,c Connect them in series and output them through the linear layer to get the agent behavior probability.

[0142] The trajectory prediction module converts X att false As the input of the linear ResNet block, and decoded. In order to improve the performance of trajectory classification, the present invention also uses a feature selection sparse attention that does not include the tensor of interest selector. Among them, the basic feature is X att false , the context feature is the predicted value, where: is the predicted endpoint. Finally, the probability of each predicted trajectory is output through the SoftMax layer .

[0143] Optionally, in some embodiments of the present invention, through the above processing, the output loss function may include two parts, namely, a trajectory loss function and a behavior loss function.

[0144] That is, the loss function consists of trajectory prediction loss and behavior classification loss. The trajectory prediction task predicts K trajectories and their corresponding probabilities. For any agent, let k*=argmax( ), and obtain the trajectory with the highest probability. In order to improve the model's ability to explore the multi-modality of the agent, Max-margin loss is used:

[0145]

[0146] in, For nth s The probability of the kth mode of an agent, ε M is the boundary parameter.

[0147] In order to improve the confidence of the k*th trajectory, a pseudo label is set That is, when the k*th class is assigned to the positive class, the k≠k∗th class is assigned to the negative class. The cross entropy loss function is used:

[0148]

[0149] In addition, the error between the predicted trajectory and the actual trajectory is calculated using the Smooth L1 loss:

[0150]

[0151] in, is the Nth s The true value of an agent.

[0152] The behavior prediction task is a classification task, using cross entropy loss:

[0153]

[0154] The final loss function is the sum of the above losses:

[0155] .

[0156] It can be understood that in the above-described embodiment of the present invention, by performing vector unified representation processing on the acquired multi-source heterogeneous data, it is possible to capture the characteristics of historical trajectories, ignore useless redundant data, describe useful topological data, and efficiently model the topological relationship between roads when constructing a prediction model, thereby providing accurate input for the construction of the prediction model, and ultimately achieving efficient and rapid construction of the target prediction model, avoiding the defects of multi-agent data being difficult to align in time and space dimensions under the input method based on trajectory time series, and avoiding the input format based on raster graphs, where the input contains many non-interesting scenes, resulting in a waste of computing resources, which in turn can affect the performance of trajectory and behavior prediction.

[0157] That is, the present invention introduces an input method based on vectorized representation. Under vectorized input, each trajectory and lane line is represented by a vector with attributes. The spatial topological relationship between each vector is continuously, meticulously and semantically linked, which reduces the learning difficulty of the model. Since the vectorized representation is not limited by the fixed size of the input image, the vector of interest can be selected at will through the flag bit, thereby improving the input utilization rate. The vectorized map describes the useful topological data and ignores useless redundant data. Whether it is a scene with a close aspect ratio such as a roundabout or an intersection, or a scene with a larger aspect ratio such as a straight road, the vectorized input representation can efficiently model the topological relationship between roads.

[0158] Furthermore, in the embodiment of the present invention, the prediction model may be verified using a verification data set in the acquired data set.

[0159] Specifically, according to the collected agent trajectory data, the length of the agent's input feature sequence is set to t hst = 20. The model predicts the future time step t fut =30 and modality K=6 for a total of 180 trajectory points, as well as the agent's lane line intention and behavior probability distribution. The feature dimension of the model is set to 128. For sparse multi-head attention, h=4 heads are selected. According to the KL divergence, the largest N d =0.75L sequence time steps to replace the original self-attention mechanism. The sparse multi-head attention block, LaneGCN block and feature selection sparse attention block are set to 3, 4 and 2 respectively. Set to 0.2. The feature selection sparse attention, lane feature selection sparse attention, and agent feature selection sparse attention The values ​​are 6, 6, and 100 respectively. The mini-batch size used by the Adam optimizer is 32. A total of 50 epochs are trained. The first 30 epochs use a learning rate of 10-3, the next 15 epochs use a learning rate of 10-4, and the last 5 epochs use a learning rate of 10-5. The trajectory prediction indicators of the model are from the test set, and the other results are from the validation set.

[0160] like Figures 8 to 12 As shown in the figure, the prediction examples in the bird's-eye view of the Argoverse validation dataset. For simplicity, only the k*th trajectory is shown. In the figure, the trajectory points are agents, the long dashed lines are the historical trajectories of the agents, the solid lines are the predicted trajectories, and the shorter dashed lines are the actual trajectories. The characters next to the trajectory points represent the behavior classification results of the agents. It can be seen that the proposed model outputs accurate prediction results for all agents in scenes such as intersections and straight roads.

[0161] Figure 8 In the example, the scene is a T-shaped intersection, where the traffic light is red for straight ahead and green for the T-shaped intersection. It can be seen that on the straight road, there are many agents waiting for the traffic light, so their behavior prediction result is "S", which means stop and wait. Fig. 9 In the figure, pedestrians cross the road and non-motor vehicles cross the zebra crossing. It can be seen that although these agents are close to perpendicular to the lane line vector direction, the model can still give good prediction results. Fig.10 In the example, all agents are moving straight ahead, and there are other agents moving in front of the moving agents. Fig.11 In this case, multiple agents enter the intersection and choose to turn left. In this case, an accurate prediction can be inferred, with "N" indicating that the agent's behavior is to change lanes. In the leftmost lane, the agent behind the lane-changing agent has not yet entered the intersection, so the behavior prediction output "F" indicates that it follows the agent in front. The behavior prediction output of the second agent on the left is "I", indicating that the agent prefers not to change lanes. Fig.12 The T-junction scene is shown. Although the agent in the upper left corner of the figure has not entered the intersection, the behavior data output by the model is "N", indicating that it is about to change lanes. This shows that the model captures the interaction between the agent and the surrounding environment and outputs accurate and reasonable trajectory prediction and behavior prediction results.

[0162] Table 3 below shows the classification performance of each behavior prediction corresponding to the validation set.

[0163] Table 3

[0164]

[0165] The above table shows the results of behavior prediction classification on the Argoverse validation set. As can be seen from the table, behaviors S and F have the best classification performance, while behaviors N, D, and I have average classification performance. It is worth noting that behaviors "S", "N", and "D" all belong to the Yield class and are prone to misclassification. When calculating the total Yield category metric, the model has good classification performance (F1-score: 87.99%), which shows that when the agent is affected by the outside world, multiple Yield behaviors often occur simultaneously. Due to the imbalance between the positive lane line intention and the negative lane line intention (about 1:100), the lane line intention accuracy performance can only reflect the model performance, and cannot explain the accuracy of the model for a specific event. Therefore, by calculating the recall rate of the event-level lane line intention, it can be seen that the lane line intention result output by the model is more accurate (event-level lane line intention recall rate: 89.98%).

[0166] On the other hand, the present invention also provides an intelligent agent driving data prediction method, which specifically comprises the following steps:

[0167] S210, obtaining sequence data of the intelligent agent to be predicted, wherein the sequence data includes trajectory data and scene data of each intelligent agent to be predicted in the set of intelligent agents to be predicted, wherein the scene data is environmental data affecting the trajectory of the intelligent agent in the scene where the intelligent agent to be tested is located;

[0168] S220, input the sequence data into a pre-built target prediction model, and output the driving data of each intelligent agent to be predicted at the next moment, the driving data includes the target trajectory data and target behavior data of the intelligent agent, the target trajectory data includes at least one trajectory of each intelligent agent to be predicted in the set of intelligent agents to be predicted at the next moment, and its corresponding probability, the target behavior data includes the operation behavior label and lane line intention label of each intelligent agent to be predicted at the next moment.

[0169] Specifically, in some embodiments, after the target prediction model is constructed through the above embodiments, for the intelligent agent whose future behavior and trajectory need to be predicted in practice, its sequence data can be first obtained, and then the obtained sequence data can be input into the pre-constructed target prediction model to output the prediction result, that is, output at least one trajectory of each intelligent agent to be predicted at the next moment, and its corresponding probability, as well as the operation behavior label and lane line intention label of each intelligent agent to be predicted at the next moment.

[0170] It can be understood that since the embodiments of the present invention utilize the target prediction model constructed by the above embodiments, the model input includes scene data and agent data, and the output is the corresponding trajectory and behavior data, that is, the agent behavior is multimodal. When the agent moves on public roads, it will inevitably be constrained by other obstacles, traffic lights, traffic rules and other data, thereby affecting the agent's intention change pattern. The model input not only includes the characteristics of the agent's dynamics and kinematics, but also includes environmental data such as lane lines and traffic lights. The scene data includes static, dynamic, and semi-dynamic data. The feature meanings, feature quantities, and feature topologies corresponding to different scene elements are different. At the same time, the topological relationship between roads is comprehensively considered, which can cope with more complex scenes, improve the model's computational reasoning efficiency, and thus improve the accuracy of the prediction.

[0171] The constructed target prediction model has good practicality and can output multiple modal trajectories and their behavior probabilities at the same time, providing a more accurate solution space for subsequent motion planning and reducing the burden of computing resources. Due to the improved Transformer neural network model, the model combines multiple clues for trajectory prediction and behavior prediction. The improved Transformer consists of an encoder, a feature selection network, and a decoder. Three attention mechanisms are used to improve the performance of the model: the sparse multi-head attention mechanism suppresses the perceptual uncertainty in the agent input; the feature selection sparse attention organically integrates multi-source data; the lane line scale dot product attention guides multi-modal prediction and improves the interpretability of the model. Through experimental analysis of agent trajectory data, the comprehensive performance of the proposed model is better than other trajectory prediction models that have performed well recently. In addition, the improved Transformer can simultaneously output behavior prediction results and lane line intention results: lane line intention helps to explore the multi-modality of the agent, and agent behavior prediction helps single-modal prediction.

[0172] On the other hand, an embodiment of the present invention provides a device for constructing an intelligent agent driving data prediction model, comprising:

[0173] An acquisition module is used to acquire the historical sequence data of the agent, wherein the historical sequence data includes the historical trajectory data and historical scene data of each agent in the agent set, and the historical scene data is the environmental data in the scene where the agent is located that affects the trajectory of the agent;

[0174] A representation module is used to perform vector representation on the historical trajectory data and the historical scene data to obtain the trajectory vector feature matrix corresponding to the historical trajectory data, the lane vector feature matrix and the lane vector adjacency matrix corresponding to the scene data;

[0175] A construction module is used to construct a target prediction model based on the transformer algorithm using the trajectory vector feature matrix, the lane vector feature matrix and the lane vector adjacency matrix. The target prediction model is used to predict the driving data of the intelligent agent to be predicted at the next moment according to the historical sequence data of the intelligent agent to be predicted. The driving data includes the target trajectory data and target behavior data of the intelligent agent. The target trajectory data includes at least one trajectory of each intelligent agent in the intelligent agent set at the next moment, and its corresponding probability. The target behavior data includes the operation behavior label and lane line intention label of each intelligent agent at the next moment.

[0176] Optionally, in the intelligent agent driving data prediction model construction device provided by the present invention, the trajectory vector feature matrix includes the coordinate value, type and first indication data of each intelligent agent in a coordinate system with the coordinate position of the target intelligent agent as the origin, the first indication data indicates whether the intelligent agent perceives it at the next moment; the lane vector feature matrix includes basic data, turning data, restriction data and second indication data of each intelligent agent, the basic data indicates the position information of the intelligent agent, and the second indication data indicates whether the lane is a fork in the road; the lane vector adjacency matrix includes the leading lane vector, the succeeding lane vector, the right lane vector, the left lane vector and the merging or exporting vector, the leading lane vector, the succeeding lane vector, the right lane vector, the left lane vector and the merging or exporting vector indicate the spatial relationship between two adjacent lane line vectors; the target intelligent agent is any intelligent agent in the intelligent agent set.

[0177] Optionally, in the intelligent agent driving data prediction model construction device provided by the present invention, the construction module is specifically used for:

[0178] The trajectory vector feature matrix, lane vector feature matrix and lane vector adjacency matrix of the intelligent agent are input into the initial prediction model constructed based on the transformer algorithm, and the initial prediction result and the corresponding loss function are output. The loss function is the sum of the trajectory prediction loss function and the behavior prediction loss function. According to the loss function, the initial model is iteratively trained to obtain the target prediction model, so that when the target prediction model outputs the target prediction result, the corresponding loss function reaches the set loss function threshold.

[0179] Optionally, in the intelligent agent driving data prediction model construction device provided by the present invention, the construction module is specifically used for:

[0180] The trajectory vector feature matrix, lane vector feature matrix and lane vector adjacency matrix are encoded and processed to obtain kinematic features, static lane vector features and dynamic lane vector features. The kinematic features, static lane vector features and dynamic lane vector features are extracted using the feature extraction module to obtain the features of interest corresponding to the historical sequence data. The extracted feature data of interest is input into the decoder, and the initial prediction results and the corresponding loss function are output.

[0181] Optionally, the intelligent body driving data prediction model construction device provided by the present invention has a construction module specifically used to: encode the trajectory vector feature matrix based on sparse multi-head attention to obtain kinematic features.

[0182] Optionally, the intelligent body driving data prediction model construction device provided by the present invention, the construction module is specifically used to: encode the lane vector feature matrix and the lane vector adjacency matrix based on lane line convolution to obtain static lane vector features and dynamic lane vector features.

[0183] Optionally, in the agent driving data prediction model construction device provided by the present invention, the selection module includes a lane line to agent feature selection module and an agent to agent feature selection module, and the construction module is specifically used to: based on the lane line to agent feature selection module, take the agent as the basic feature, take the static lane vector feature and the dynamic lane vector feature as the context feature, establish a first interactive relationship between the agent and the lane, and obtain a first feature of interest;

[0184] Based on the agent-to-agent feature selection module, the target agent is used as the basic feature and other agents are used as the context features to establish an interactive relationship between the agents and obtain the second feature of interest. The first feature of interest and the second feature of interest represent the features of the effective agents related to the target agent in the scene.

[0185] In a second aspect, the present invention provides an intelligent body driving data prediction device, comprising:

[0186] An acquisition module is used to acquire sequence data of the intelligent agent to be predicted, wherein the sequence data includes trajectory data and scene data of each intelligent agent to be predicted in the set of intelligent agents to be predicted, and the scene data is the environmental data that affects the trajectory of the intelligent agent in the scene where the intelligent agent to be tested is located;

[0187] The prediction module is used to input the sequence data into the target prediction model constructed in the above-mentioned intelligent agent driving prediction model construction method, and output the driving data of each intelligent agent to be predicted at the next moment. The driving data includes the target trajectory data and target behavior data of the intelligent agent. The target trajectory data includes at least one trajectory of each intelligent agent to be predicted in the set of intelligent agents to be predicted at the next moment, and its corresponding probability. The target behavior data includes the operation behavior label and lane line intention label of each intelligent agent to be predicted at the next moment.

[0188] On the other hand, an embodiment of the present invention provides a computer device, which also includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, it implements the intelligent agent driving prediction model construction method or the intelligent agent driving prediction method as described above.

[0189] Reference below Fig.13 , Fig.13 Schematic diagram of the structure of a computer device according to an embodiment of the present invention.

[0190] like Fig.13 As shown, the computer device includes a central processing unit (CPU) 301, which can perform various appropriate actions and processes according to the program stored in the read-only memory (ROM) 302 or the program loaded from the storage part 308 to the random access memory (RAM) 303. In the RAM 303, various programs and data required for the operation of the electronic device 300 are also stored. The CPU 301, the ROM 302, and the RAM 303 are connected to each other through the bus 304. The input / output (I / O) interface 305 is also connected to the bus 304. In some embodiments, the following components are connected to the I / O interface 305: an input part 306 including a keyboard, a mouse, etc.; an output part 307 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage part 308 including a hard disk, etc.; and a communication part 309 including a network interface card such as a LAN card, a modem, etc. The communication part 309 performs communication processing via a network such as the Internet. The drive 310 is also connected to the I / O interface 305 as needed. Removable media 311, such as magnetic disks, optical disks, magneto-optical disks, semiconductor memories, etc., are installed on drive 310 as needed, so that the computer program read therefrom is installed into storage section 308 as needed. In particular, according to an embodiment of the present invention, the process described with reference to the flowchart above can be implemented as a computer software program. For example, an embodiment of the present invention includes a computer program product, which includes a computer program carried on a machine-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through communication section 309, and / or installed from removable media 311. When the computer program is executed by central processing unit (CPU) 301, the above-mentioned functions defined in the electronic device of the present invention are executed.

[0191] It should be noted that the computer-readable medium shown in the present invention may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electronic device, device or device of electrical, magnetic, optical, electromagnetic, infrared, or semiconductor, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present invention, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction-executing electronic device, device or device. In the present invention, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, which carries a computer-readable program code. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. The computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium, which may send, propagate or transmit a program for use by or in conjunction with an instruction-executing electronic device, apparatus or device. The program code contained on the computer-readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, optical cable, RF, etc., or any suitable combination of the above.

[0192] The flowcharts and block diagrams in the accompanying drawings illustrate the possible architecture, functions and operations of the computer devices, methods and computer program products according to various embodiments of the present invention. In this regard, each box in the flowchart or block diagram can represent a module, a program segment, or a part of the code, and the aforementioned module, program segment, or a part of the code contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flowchart, and the combination of boxes in the block diagram and / or flowchart can be implemented with a dedicated hardware-based electronic device that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0193] The units or modules involved in the embodiments of the present invention may be implemented in software or hardware. The units or modules described may also be provided in a processor, for example, may be described as: a processor comprising: an acquisition module, a characterization module and a construction module. Among them, the names of these units or modules do not constitute limitations on the units or modules themselves in certain circumstances. For example, the characterization module may also be described as "used to perform vector characterization on the historical trajectory data and the historical scene data, and obtain the trajectory vector feature matrix corresponding to the historical trajectory data, the lane vector feature matrix corresponding to the scene data and the lane vector adjacency matrix".

[0194] As another aspect, the present invention further provides a computer-readable storage medium, which may be included in the electronic device described in the above embodiment; or may exist independently and not be installed in the electronic device. The above computer-readable storage medium stores one or more computer programs, and when the above computer programs are used by one or more processors to execute the intelligent agent driving data prediction model construction method described in the present invention.

[0195] The above description is only a preferred embodiment of the present invention and an explanation of the technical principles used. Those skilled in the art should understand that the scope of disclosure involved in the present invention is not limited to the technical solution formed by a specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the aforementioned disclosed concept. For example, the above features are replaced with the technical features with similar functions disclosed in the present invention (but not limited to) to form a technical solution.

Claims

1. A method for constructing an intelligent agent driving prediction model, characterized in that: The method comprises: Acquire historical sequence data of the agent, wherein the historical sequence data includes historical trajectory data and historical scene data of each agent in the agent set, wherein the historical scene data is environmental data affecting the trajectory of the agent in the scene where each agent is located; Performing vector representation on the historical trajectory data and the historical scene data to obtain a trajectory vector feature matrix corresponding to the historical trajectory data, a lane vector feature matrix and a lane vector adjacency matrix corresponding to the historical scene data; Based on the transformer algorithm, a target prediction model is constructed by using the trajectory vector feature matrix, the lane vector feature matrix and the lane vector adjacency matrix. The target prediction model is used to predict the driving data of the intelligent body to be predicted at the next moment according to the historical sequence data of the intelligent body to be predicted. The driving data includes the target trajectory data and target behavior data of the intelligent body to be predicted. The target trajectory data includes at least one driving trajectory of the intelligent body to be predicted at the next moment and its corresponding probability. The target behavior data includes the operation behavior label and lane line intention label of the intelligent body to be predicted at the next moment. The trajectory vector feature matrix includes the coordinate value, type and first indication data of each agent in a coordinate system with the coordinate position of the target agent as the origin, and the first indication data indicates whether the agent is sensed at the next moment; The lane vector feature matrix includes basic data, turning data, restriction data and second indication data of each agent, wherein the basic data represents the location information of the agent, and the second indication data represents whether the lane is a fork in the road; The lane vector adjacency matrix includes a preceding lane vector, a succeeding lane vector, a right lane vector, a left lane vector, and an inbound or outbound vector, wherein the preceding lane vector, the succeeding lane vector, the right lane vector, the left lane vector, and the inbound or outbound vector represent a spatial relationship between two adjacent lane line vectors; The target agent is any agent in the agent set.

2. The method for constructing an intelligent agent driving prediction model according to claim 1, characterized in that: The transformer-based algorithm, using the trajectory vector feature matrix, the lane vector feature matrix and the lane vector adjacency matrix, constructing a target prediction model includes: Inputting the trajectory vector feature matrix of the agent, the lane vector feature matrix and the lane vector adjacency matrix into an initial prediction model constructed based on the transformer algorithm, outputting an initial prediction result and a corresponding loss function, wherein the loss function is the sum of a trajectory prediction loss function and a behavior prediction loss function; According to the loss function and the set loss function threshold, the initial model is iteratively trained to obtain the target prediction model, so that when the target prediction model outputs the target prediction result, the corresponding loss function reaches the set loss function threshold.

3. The method for constructing an intelligent driving prediction model according to claim 2, characterized in that: The step of inputting the trajectory vector feature matrix of the agent, the lane vector feature matrix and the lane vector adjacency matrix into the initial prediction model constructed based on the transformer algorithm, and outputting the initial prediction result and the corresponding loss function includes: Encoding the trajectory vector feature matrix, the lane vector feature matrix and the lane vector adjacency matrix to obtain kinematic features corresponding to the trajectory vector feature matrix, and static lane vector features and dynamic lane vector features corresponding to the lane vector feature matrix and the lane vector adjacency matrix; Using a feature extraction module, extracting the kinematic features, the static lane vector features, and the dynamic lane vector features to obtain features of interest corresponding to the historical sequence data; The extracted feature data of interest is input into a decoder, and the initial prediction result and the corresponding loss function are output.

4. The method for constructing an intelligent agent driving prediction model according to claim 3, characterized in that: The encoding process of the trajectory vector feature matrix comprises: The trajectory vector feature matrix is ​​encoded based on sparse multi-head attention to obtain the kinematic features.

5. The method for constructing an intelligent agent driving prediction model according to claim 3, characterized in that: The encoding process of the lane vector feature matrix and the lane vector adjacency matrix includes: The lane vector feature matrix and the lane vector adjacency matrix are encoded based on lane line convolution to obtain the static lane vector feature and the dynamic lane vector feature.

6. The method for constructing an intelligent agent driving prediction model according to claim 3, characterized in that: The feature extraction module includes a lane-to-agent feature selection module and an agent-to-agent feature selection module. The feature extraction of the kinematic features, static lane vector features, and dynamic lane vector features to obtain the interesting features of the historical sequence data includes: Based on the lane-to-agent feature selection module, a first interactive relationship between the agent and the lane is established with the agent as the basic feature and the static lane vector feature and the dynamic lane vector feature as the context feature to obtain a first feature of interest; Based on the agent-to-agent feature selection module, taking the target agent as the basic feature and other agents as the context features, an interactive relationship between the agents is established to obtain a second feature of interest. The first feature of interest and the second feature of interest represent the features of the valid agents related to the target agent in the scene.

7. An intelligent agent driving prediction method, characterized in that: The method comprises: Acquire historical sequence data of the intelligent agent to be predicted, wherein the historical sequence data includes trajectory data and scene data of each intelligent agent to be predicted in the set of intelligent agents to be predicted, wherein the scene data is environmental data affecting the trajectory of the intelligent agent in the scene where the intelligent agent to be predicted is located; The historical sequence data is input into the target prediction model constructed in the intelligent agent driving prediction model construction method as described in any one of claims 1 to 6, and the driving data of each intelligent agent to be predicted at the next moment is output, wherein the driving data includes the target trajectory data and target behavior data of the intelligent agent to be predicted, wherein the target trajectory data includes at least one driving trajectory of the intelligent agent to be predicted at the next moment, and its corresponding probability, and the target behavior data includes the operation behavior label and lane line intention icon of the intelligent agent to be predicted at the next moment.

8. A computer device, characterized in that: The computer device includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, the method for constructing an intelligent body driving prediction model as described in any one of claims 1 to 6 or the method for constructing an intelligent body driving prediction as described in claim 7 is implemented.

9. A computer-readable storage medium, characterized in that: A computer program is stored thereon, and the computer program is used to implement the intelligent body driving prediction model construction method as described in any one of claims 1-6, or the intelligent body driving prediction method as described in claim 7.

Citation Information

Patent Citations

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

    CN115009275A

  • Vehicle track prediction model training method and device, equipment and storage medium

    CN116401549A

  • Vehicle driving track data determination method and device, equipment and medium

    CN116834771A

  • Method and computer program for characterizing future trajectories of road users

    DE102022201127A1

  • Lane-attention: predicting vehicles' moving trajectories by learning their attention over lanes

    US20210179097A1