Automatic driving track predicting and planning method based on scene category judgment
Through intelligent driver model scoring and importance sampling based on scene category judgment, combined with iterative interaction of autonomous driving prediction and planning models, the problem of insufficient performance of phased end-to-end autonomous driving models in complex scenarios is solved, and more accurate and efficient trajectory prediction and planning is achieved.
Patent Information
- Application Number
- CN202510481485.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-17
- Publication Date
- 2025-08-01
AI Technical Summary
The existing phased end-to-end autonomous driving model has problems with uneven data distribution and insufficient interactive game modeling, which has led to poor performance in complex scenarios, especially in strong interaction scenarios such as intersection car meetings and high-speed ramp confluence, which are difficult to effectively capture the strategic game relationship between multiple participants.
Using a method based on scene category judgment, the intelligent driver model scores the data complexity and performs importance sampling, combined with iterative interaction of autonomous driving prediction and planning models, including scene information vectorization, feature extraction, difficulty judgment and iteration count calculation, to achieve accurate prediction and planning of trajectories of bicycles and other vehicles.
The model's processing capability in complex scenarios is improved, more accurate prediction and planning results are achieved, computing efficiency and accuracy are balanced, and the characteristics of real-time scene complexity score and iteration calculation are achieved.
Smart Images

Figure CN120411906A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of trajectory prediction and planning, and specifically relates to an autonomous driving trajectory prediction and planning method based on scene category judgment. Background Technique
[0002] Under the background of the informatization and intelligence of the automotive industry, autonomous driving technology has attracted wide attention due to its potential to improve traffic efficiency and reduce traffic accidents. The current autonomous driving system architectures are mainly divided into two categories: modular architectures and end-to-end architectures. At present, the end-to-end method has shown certain advantages in engineering simplification and scene generalization, but the problem of non-explainable decision-making caused by its black-box characteristics restricts its commercial implementation. In recent years, the academic community has proposed a staged end-to-end architecture. By dividing the complete autonomous driving task into multiple interpretable and optimizable end-to-end sub-stages, while introducing an interpretable intermediate representation layer, it also maintains the end-to-end joint training and inference capabilities. However, the existing staged end-to-end architectures have problems such as uneven distribution of training data and insufficient interactive game modeling.
[0003] First, for the model training of existing staged end-to-end autonomous driving, it is usually assumed that the collected reference driving trajectory dataset is uniformly distributed, and a uniform sampling method is used when loading the data, which ignores the objective reality of the imbalance in the proportion of simple scenarios (such as straight following) and complex scenarios (such as unprotected left turns) in the dataset, resulting in most of the data learned by the model being simple scenarios such as straight driving; second, the existing staged end-to-end autonomous driving usually adopts a serial prediction-planning process, and decoupling the behavior of the ego vehicle and other vehicles will make it difficult for the model to effectively capture the strategic game relationship of multiple participants in the dynamic traffic scene, resulting in poor performance of the model in strong interaction scenarios such as meeting at intersections and merging on highway ramps. Summary of the Invention
[0004] To solve the above problems, the present invention provides an autonomous driving trajectory prediction and planning method based on scene category judgment, providing a more efficient and accurate solution for the interactive prediction and planning of autonomous driving.
[0005] The technical solution of the present invention is described in conjunction with the accompanying drawings as follows:
[0006] The present invention provides an autonomous driving trajectory prediction and planning method based on scene category judgment, including the following steps:
[0007] Step 1: Obtain a reference driving trajectory dataset along a preset route by a collection fleet, perform scene complexity scoring on the collected reference driving trajectory data based on the scene complexity model of the intelligent driver model, and perform data bucketing on the dataset according to the scoring results;
[0008] Step 2: During model training, data is loaded using importance sampling;
[0009] Step 3: Use the training data with importance sampling to train the autonomous driving prediction and planning model based on iterative interaction with scene complexity;
[0010] Step 4: The trained model performs real-time prediction of the trajectories of other vehicles and planning of the trajectory of the host vehicle.
[0011] Furthermore, the specific method of Step 1 is as follows:
[0012] 11) The acquisition fleet obtains a reference driving trajectory dataset along a preset route; the data structure in the reference driving trajectory dataset includes scene ID information, scene category information, time information, current moment information, static map information, dynamic map information, host vehicle and other traffic participant information;
[0013] 12) Use the intelligent driver model to plan the future trajectory of the host vehicle under different scene categories and determine the complexity scores corresponding to different category scenes by weighted synthesis of three evaluation indicators: collision risk, scene completion degree, and driving comfort; where the intelligent driver model formula is:
[0014]
[0015] In the formula, a is the calculated vehicle acceleration; a max is the maximum vehicle acceleration considering vehicle dynamics constraints and riding comfort; v is the current speed of the host vehicle; v0 is the expected speed set for the host vehicle; δ is the acceleration exponent, used to adjust the smoothness of the acceleration change when the vehicle approaches the expected speed to simulate different driving styles of human drivers, and δ = 4 is set; s is the actual vehicle distance between the host vehicle and the vehicle in front; s * is the expected vehicle distance, and the specific calculation formula is:
[0016]
[0017] In the formula, s0 is the minimum safety distance when the vehicle is stationary; T is the vehicle safety time interval, reflecting the driver's reaction time to the dynamics of the vehicle in front; Δv is the speed difference between the host vehicle and the vehicle in front; b is the comfortable deceleration, reflecting the comfort requirements of the driver during braking;
[0018] When the actual vehicle distance s is greater than 1.5 times the expected vehicle distance s * , the vehicle will accelerate to the expected vehicle speed v0; when the actual vehicle distance s is less than 0.8 times the expected vehicle distance s , the braking term * increases, reducing the vehicle acceleration to maintain the expected vehicle distance s , and *; when the speed v of the host vehicle and the relative speed Δv between the host vehicle and the preceding vehicle change dynamically, the set desired vehicle distance s * will also change dynamically to ensure driving safety and comfort;
[0019] According to the information at the current moment, the reference driving trajectory dataset can be divided into two major parts: historical information and future information; the reference driving trajectory data includes data of different scenario categories such as lane change, following the preceding vehicle, low-speed driving, left turn, and right turn. After using the above intelligent driver model to plan the future trajectory of the host vehicle based on the historical information of the host vehicle, the evaluation indexes of the intelligent driver model under different scenario categories can be obtained. Considering three indexes of collision risk, scenario completion degree, and driving comfort, the complexity of the scenario is judged and scored; the scoring interval of the scenario complexity scoring formula is S ∈ [0, 100], and the higher the score, the more complex the scenario. The scenario complexity scoring formula is as follows:
[0020]
[0021] In the formula, S is the scenario complexity score; N tota is the total number of samples in this scenario category; N coll is the number of samples with collisions; N comp is the number of samples that complete the scenario; N comf is the number of samples that meet the driving comfort; w1, w2, w3 are weight parameters reflecting the different importance degrees of the considered evaluation factors; αl, α2, α3 are non-linear scaling coefficients;
[0022] 13) Divide the dataset into five equal parts according to the scenario complexity score, that is, [0, 20], [20, 40], [40, 60], [60, 80], [80, 100], and classify the dataset according to the five equal-score intervals to form five data buckets of scenario difficulty levels.
[0023] Further, the specific method of the second step is as follows:
[0024] 21) Use the training data importance sampling method based on geometric series to load the data; the formula of the importance sampling method based on geometric series is as follows:
[0025]
[0026] In the formula, q k is the sampling weight of the kth data bucket, reflecting the proportion of the data bucket of different scenario difficulty levels in the overall data; is the initial weight of the kth data bucket. When loading the data initially, it is uniformly sampled and set to 1; is the final weight of the k-th data bin, which is determined by the scenario complexity corresponding to this data bin; α is a proportionality coefficient used to control the change rate of the weight with the training steps; t is the current training step.
[0027] Further, the specific method of step three is as follows:
[0028] 31) Establish an autonomous driving prediction and planning model; the autonomous driving prediction and planning model includes a scenario information vectorization module, a scenario feature vector extraction module, a scenario difficulty judgment and iteration number calculation module, a vehicle trajectory prediction module, and a self-vehicle trajectory planning module;
[0029] The scenario information vectorization module includes a scenario information module and a scenario vectorization module. The scenario information module is used to obtain the historical information of the agent, that is, the self-vehicle and other vehicles, and the scenario context, that is, the element information of the map, obtained from the self-vehicle sensors; the scenario vectorization module is used to process the agent historical state information and the scenario context information separately; for the agent historical state information, including 2D position coordinates, heading angle, speed, and bounding box size information, select to sample trajectory points at fixed time intervals, form a time-continuous polyline, and generate an agent vector sequence v_arr A ; for the scenario context information, considering two types of map elements, lanes and crosswalks, select to directly discretize the map elements into polylines, and sample key points according to the distance to generate a map vector sequence v_arr M ; for the agent vector sequence v_arr A and the map vector sequence v_arr M Each vector node in contains start and end point coordinates, semantic labels, and polyline ID attributes; for each agent, a local scenario context will be constructed, which includes the possible lanes and surrounding crosswalks adopted; the position attributes of all agents and scenario context elements will be converted to the local coordinate system of the self-vehicle AV; after the scenario information vectorization process, a vector sequence containing the agent historical state information and the scenario context information is obtained;
[0030] The scenario feature vector extraction module is used to convert the original vector sequence into a structured vector feature; for the agent historical information, use a long short-term memory (LSTM) network for encoding, and let each type of agent share an LSTM encoder to generate a self-vehicle feature vector v AV and an other-vehicle feature vector v AO ; for the two types of map elements, lanes and crosswalks, in the scenario context information, use a multi-layer perceptron (MLP) to encode digital features such as position and direction respectively, and use an embedding layer to encode discrete features such as lane type and number, and finally concatenate the encoded two map vectors to form a scenario context information feature tensor v CO; The ego-vehicle feature vector v AV and the other-vehicle feature vector v AO and the scene context information feature tensor v CO compose the scene feature vector v sc ;
[0031] The other-vehicle trajectory prediction module is used to input the scene feature vector v sc ; First, use the other-vehicle feature vector v AO as the query (q), and the other-vehicle feature vector v AO and the ego-vehicle feature vector v AV as the key-value pair (k, v) to perform attention interaction, obtaining the predicted intermediate feature vector v PRM ; Then, use the predicted intermediate feature vector v PRM as the query (q), and the scene context information feature tensor v CO as the key-value pair (k, v) to perform attention interaction, obtaining the predicted feature vector v PR ; Finally, decode the future trajectory of the other vehicle from the predicted feature vector v PR through the other-vehicle trajectory decoder based on MLP;
[0032] The ego-vehicle trajectory planning module is used to input the scene feature vector v sc ; First, use the ego-vehicle feature vector v AV as the query (q), and the other-vehicle feature vector v AO as the key-value pair (k, v) to perform attention interaction, obtaining the planning intermediate feature vector v PLM ; Then, use the planning intermediate feature vector v PLM as the query (q), and the scene context information feature tensor v CO as the key-value pair (k, v) to perform attention interaction, obtaining the planning feature vector v PL ; Finally, decode the future trajectory of the other vehicle from the planning feature vector v PM through the ego-vehicle trajectory decoder of MLP;
[0033] The scene difficulty judgment and iteration number calculation module is used to input the scene feature vector v sc into the scene difficulty decoder based on MLP, and the scene difficulty decoder will output the scene difficulty score of the scene; Then, use the scene iteration number formula to output the iteration number according to the scene difficulty score, and establish an exponential mapping relationship scene iteration calculation formula to ensure a high iteration number for complex scenes; The scene iteration number calculation formula is:
[0034]
[0035] In the formula, N iter is the scene iteration number; Nmin and N max are respectively the minimum and maximum number of iterations that can be set manually; C is the scene difficulty score; p = 1.5 controls the growth rate of the number of iterations; round() is a rounding function to ensure that the number of iterations is an integer;
[0036] 32) After calculating the scene iteration number N based on the scene difficulty judgment and iteration number calculation module iter the trajectory prediction module of other vehicles and the trajectory planning module of the host vehicle are iteratively interacted, where the iterative interaction is specifically realized by passing the predicted feature vector v PR obtained by the trajectory prediction module of other vehicles to the trajectory planning module of the host vehicle and passing the planned feature vector v PL obtained by the trajectory planning module of the host vehicle to the trajectory prediction module of other vehicles.
[0037] The beneficial effects of the present invention are as follows:
[0038] 1) The method adopted by the present invention for offline scene complexity scoring based on the intelligent driver model is simple and feasible. At the same time, when training the model, data loading is carried out by means of importance sampling, which breaks through the limitations of traditional uniform data sampling training and improves the model's ability to process complex scenes;
[0039] 2) The trajectory prediction module of other vehicles and the trajectory planning module of the host vehicle, which are iteratively interactive based on scene complexity, adopted by the present invention can effectively capture the interaction relationship between vehicles, and then obtain more accurate prediction and planning results. Among them, dynamically determining the number of iterations based on scene complexity can balance the computational efficiency and computational accuracy of the model;
[0040] 3) The present invention introduces a learnable scene difficulty judgment module into the model, which can realize real-time judgment of scene complexity and calculate the number of iterations corresponding to different scenes, and has the characteristics of high real-time of scene complexity scoring and reasonable calculation of the number of iterations. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following will briefly introduce the drawings required to be used in the embodiments. It should be understood that the following drawings only show some embodiments of the present invention, and therefore should not be regarded as limiting the scope. For those of ordinary skill in the art, other related drawings can be obtained based on these drawings without creative efforts.
[0042] Figure 1 is a schematic diagram of the overall process of autonomous driving joint trajectory prediction and planning based on driving scene category judgment;
[0043] Figure 2Schematic diagram of a trajectory prediction and planning model for iterative interaction based on driving scenario category judgment;
[0044] Figure 3 Schematic diagram of data distribution divided according to scenario complexity;
[0045] Figure 4 Effect diagram of simulation of partial scenario model operation. Specific implementation manner
[0046] The present invention will be further described in detail below with reference to the accompanying drawings and embodiments. It can be understood that the specific embodiments described herein are only used to explain the present invention, rather than limiting the present invention. In addition, it should be noted that for the sake of description, only parts related to the present invention are shown in the accompanying drawings rather than all structures.
[0047] Embodiment 1
[0048] Refer to Figure 1 This embodiment provides an autonomous driving trajectory prediction and planning method based on scenario category judgment, including the following steps:
[0049] Step 1: The acquisition fleet obtains a reference driving trajectory data set along a preset route, performs a scenario complexity score on the collected reference driving trajectory data based on the scenario complexity model of the intelligent driver model, and performs data bucketing on the data set according to the scoring result, specifically as follows:
[0050] 11) The acquisition fleet obtains a reference driving trajectory data set along a preset route; the reference driving trajectory data set usually does not have true value labels of complexity scores corresponding to different scenario categories; the data structure in the reference driving trajectory data set includes scenario ID information, scenario category information, time information, current moment information, static map information, dynamic map information, ego vehicle and other traffic participant information;
[0051] 12) In order to accurately label the complexity corresponding to different category scenarios, the present invention uses the intelligent driving modeler model to plan the future trajectory of the ego vehicle under different category scenarios and determines the complexity score corresponding to different category scenarios by weighted synthesis of three evaluation indicators of collision risk, scenario completion degree, and driving comfort; among them, the intelligent driver model formula is:
[0052]
[0053] In the formula, a is the calculated vehicle acceleration; a maxamax is the maximum acceleration of the vehicle considering vehicle dynamics constraints and riding comfort; v is the current speed of the host vehicle; v0 is the desired speed set for the host vehicle; δ is the acceleration exponent, which is used to adjust the smoothness of the acceleration change when the vehicle approaches the desired speed to simulate different driving styles of human drivers, and δ = 4 is set; s is the actual vehicle distance between the host vehicle and the leading vehicle; s * is the desired vehicle distance, and the specific calculation formula is:
[0054]
[0055] In the formula, s0 is the minimum safety distance when the vehicle is stationary; T is the vehicle safety time interval, which reflects the reaction time of the driver to the dynamics of the leading vehicle; Δv is the speed difference between the host vehicle and the leading vehicle; b is the comfortable deceleration, which reflects the comfort requirements of the driver during braking;
[0056] When the actual vehicle distance s is greater than 1.5 times the desired vehicle distance s * , the vehicle will accelerate to the desired vehicle speed v0 in accordance with ; when the actual vehicle distance s is less than 0.8 times the desired vehicle distance s * , the braking term of the vehicle increases, and the acceleration of the host vehicle is reduced to maintain the desired vehicle distance s * ; when the speed v of the host vehicle and the relative speed Δv between the host vehicle and the leading vehicle change dynamically, the set desired vehicle distance s * will also change dynamically to ensure driving safety and comfort;
[0057] According to the information at the current moment, the reference driving trajectory dataset can be divided into two major parts: historical information and future information; the reference driving trajectory data contains different scenario category data such as lane changing, following the leading vehicle, low-speed driving, turning left, and turning right; after using the above intelligent driver model to plan the future trajectory of the host vehicle based on the historical information of the host vehicle, the evaluation indexes of the intelligent driver model in different scenario categories can be obtained, and considering three indexes of collision risk, scenario completion degree, and driving comfort, the scenario complexity is judged and scored; the scoring interval of the scenario complexity scoring formula is S ∈ [0, 100], and the higher the score, the more complex the scenario. The scenario complexity scoring formula is:
[0058]
[0059] In the formula, S is the scenario complexity score; N tota is the total number of samples in this scenario category; N coll is the number of samples with collisions; N comp is the number of samples that complete the scenario; N comfThe number of samples to meet driving comfort; w1, w2, w3 are weight parameters reflecting the different importance degrees of the considered evaluation factors; α1, α2, α3 are non-linear scaling coefficients;
[0060] 13) Divide the scene complexity scores into five equal parts, i.e., [0, 20], [20, 40], [40, 60], [60, 80], [80, 100]. Classify the dataset according to the five equal parts of the scores to form five data buckets of different scene difficulty levels.
[0061] Step 2: When training the model, use the importance sampling method to load data, specifically as follows:
[0062] Existing models generally regard the collected reference driving trajectory dataset as uniformly distributed during training, and use uniform sampling when loading data, without considering the unequal data capacities of different scene complexities and the different abilities of the model to learn different complexity scenes.
[0063] 21) The present invention uses the importance sampling method of training data based on geometric series to load data; the core idea of this method is to gradually transition from uniform sampling to importance sampling based on difficulty weighting to pay more attention to data with higher scene complexity; the formula of the importance sampling method based on geometric series is:
[0064]
[0065] In the formula, q k is the sampling weight of the k-th data bucket, reflecting the proportion of data buckets of different scene difficulty levels in the overall data; is the initial weight of the k-th data bucket. When initially loading data, it is uniform sampling and is set to 1; is the final weight of the k-th data bucket, which is determined by the scene complexity corresponding to this data bucket; α is a proportionality coefficient used to control the change rate of the weight with the number of training steps; t is the current number of training steps;
[0066] The importance sampling method of training data based on geometric series performs equal-probability sampling on all data buckets at the initial stage of model training, that is, treats training data of different scene difficulties fairly; as the model training progresses, the model starts to pay more attention to data with higher difficulty. This adjustment is carried out gently, so that the model will not be overly biased towards difficult data at the initial stage of training, thereby preventing the model from falling into a data mode with higher difficulty prematurely; at the final stage of training, making the sampling probability of training data proportional to the difficulty score can make the model pay more attention to complex or critical data and improve the performance of the model on high-difficulty scene data.
[0067] Step 3: Train the autonomous driving prediction and planning model for iterative interaction based on scenario complexity using importance sampling training data, specifically as follows:
[0068] 31) Refer to Figure 2 , and establish an autonomous driving prediction and planning model;
[0069] The present invention proposes an autonomous driving prediction and planning model for iterative interaction based on scenario complexity. This model performs interactive iteration on the ego-vehicle trajectory planning and the other-vehicle trajectory prediction based on scenario complexity, can effectively capture vehicle-vehicle interaction features, and achieve a balance between the accuracy and efficiency of autonomous driving prediction and planning.
[0070] The autonomous driving prediction and planning model includes a scenario information vectorization module, a scenario feature vector extraction module, a scenario difficulty judgment and iteration number calculation module, an other-vehicle trajectory prediction module, and an ego-vehicle trajectory planning module;
[0071] The scenario information vectorization module includes a scenario information module and a scenario vectorization module. The scenario information module is used to obtain historical information of the agent, i.e., the ego-vehicle and other vehicles, and scenario context, i.e., element information of the map, obtained from the ego-vehicle sensors. The scenario vectorization module is used to separately process the agent historical state information and the scenario context information. For the agent historical state information, including 2D position coordinates, heading angle, speed, and bounding box size information, select to sample trajectory points at a fixed time interval, form a time-continuous polyline, and generate an agent vector sequence v_arr A ; for the scenario context information, considering two types of map elements, lanes and crosswalks, select to directly discretize the map elements into polylines, and sample key points according to distance to generate a map vector sequence v_arr M ; for each vector node in the agent vector sequence v_arr A and the map vector sequence v_arr M contains start and end point coordinates, semantic labels, and polyline ID attributes; for each agent, a local scenario context is constructed, which includes possible lanes and surrounding crosswalks adopted; the position attributes of all agents and scenario context elements are converted into the local coordinate system of the ego-vehicle AV; after the scenario information vectorization process, a vector sequence containing the agent historical state information and the scenario context information is obtained;
[0072] The scenario feature vector extraction module is used to convert the original vector sequence into a structured vector feature; for the agent historical information, use a long short-term memory (LSTM) network for encoding, and let each type of agent share an LSTM encoder to separately generate an ego-vehicle feature vector v AV and an other-vehicle feature vector v AO; For the two map elements of lanes and crosswalks in the scene context information, a multi-layer perceptron (MLP) is used to encode digital features such as position and direction, and an embedding layer is used to encode discrete features such as lane types and numbers. Finally, the two encoded map vectors are concatenated to form the scene context information feature tensor v CO ; The ego-vehicle feature vector v AV and the other-vehicle feature vector v AO and the scene context information feature tensor v CO form the scene feature vector v sc ;
[0073] The other-vehicle trajectory prediction module is used to input the scene feature vector v sc ; First, the other-vehicle feature vector v AO is used as the query (q), and the other-vehicle feature vector v AO and the ego-vehicle feature vector v AV are used as the key-value pair (k, v) for attention interaction to obtain the predicted intermediate feature vector v PRM ; Then, the predicted intermediate feature vector v PRM is used as the query (q), and the scene context information feature tensor v CO is used as the key-value pair (k, v) for attention interaction to obtain the predicted feature vector v PR ; Finally, the future trajectory of the other vehicle is decoded from the predicted feature vector v PR through the other-vehicle trajectory decoder based on MLP;
[0074] The ego-vehicle trajectory planning module is used to input the scene feature vector v sc ; First, the ego-vehicle feature vector v AV is used as the query (q), and the other-vehicle feature vector v AO is used as the key-value pair (k, v) for attention interaction to obtain the planning intermediate feature vector v PLM ; Then, the planning intermediate feature vector v PLM is used as the query (q), and the scene context information feature tensor v CO is used as the key-value pair (k, v) for attention interaction to obtain the planning feature vector v PL ; Finally, the future trajectory of the ego vehicle is decoded from the planning feature vector v PM through the ego-vehicle trajectory decoder of MLP;
[0075] The scene difficulty judgment and iteration number calculation module is used to use the scene feature vector v scInput to the MLP-based scene difficulty decoder, which outputs the scene difficulty score of the scene; then use the scene iteration times formula to output the iteration times according to the scene difficulty score, and establish an exponential mapping relationship for the scene iteration calculation formula to ensure a high iteration times for complex scenes; the scene iteration times calculation formula is:
[0076]
[0077] In the formula, N iter is the scene iteration times; N min and N max are respectively the minimum iteration times and the maximum iteration times that can be set manually; C is the scene difficulty score; p = 1.5 controls the growth rate of the iteration times; round() is the rounding function to ensure that the iteration times is an integer;
[0078] 32) After calculating the scene iteration times N iter based on the scene difficulty judgment and iteration times calculation module, the other vehicle trajectory prediction module and the ego vehicle trajectory planning module are iteratively interacted, where the iterative interaction is specifically realized by passing the predicted feature vector v PR obtained by the other vehicle trajectory prediction module to the ego vehicle trajectory planning module and passing the planned feature vector v PL obtained by the ego vehicle trajectory planning module to the other vehicle trajectory planning module.
[0079] Step Four: The trained model performs real-time other vehicle trajectory prediction and ego vehicle trajectory planning.
[0080] Embodiment Two
[0081] In this embodiment, the NuPlan autonomous driving dataset is used to preliminarily verify the proposed two-trajectory prediction and planning method for autonomous driving based on driving scene category judgment. In this embodiment, 1,138,526 pieces of data including 10 scene categories are selected from the NuPlan dataset for model training and verification. The data distribution divided according to the scene complexity is as Figure 3 shown. The model running effects under some driving scenes are as Figure 4 shown.
[0082] In summary, the present invention provides a more efficient and accurate solution for the interactive prediction and planning of autonomous driving.
[0083] Although the embodiments of the present invention have been shown and described, for those of ordinary skill in the art, it can be understood that various changes, modifications, substitutions, and variations can be made to these embodiments without departing from the principles and spirit of the present invention, and the scope of the present invention is defined by the appended claims and their equivalents.
Claims
1. A method for autonomous driving trajectory prediction and planning based on scene category judgment, characterized in that, It includes the following steps: Step 1: The acquisition fleet obtains a reference driving trajectory dataset along a preset route, performs a scene complexity score on the collected reference driving trajectory data based on the scene complexity model of the intelligent driver model, and performs data bucketing on the dataset according to the score results; Step 2: When training the model, use the method of importance sampling to load data; Step 3: Use the training data of importance sampling to train the autonomous driving prediction and planning model based on iterative interaction of scene complexity; Step 4: The trained model performs real-time prediction of the trajectories of other vehicles and planning of the trajectory of the host vehicle.
2. The method for predicting and planning an autonomous driving trajectory based on scenario category judgment according to claim 1, wherein, The specific method of the above Step 1 is as follows: 11) The acquisition fleet obtains a reference driving trajectory dataset along a preset route; the data structure in the reference driving trajectory dataset includes scene ID information, scene category information, time information, current moment information, static map information, dynamic map information, host vehicle and other traffic participant information; 12) Use the intelligent driver model to plan the future trajectory of the host vehicle under different scene categories and determine the complexity score corresponding to different category scenes by weighted synthesis of three evaluation indicators: collision risk, scene completion degree, and driving comfort; the intelligent driver model formula is: where a is the calculated vehicle acceleration; a max is the maximum vehicle acceleration considering vehicle dynamics constraints and riding comfort; v is the current speed of the host vehicle; v0 is the desired speed set for the host vehicle; δ is the acceleration exponent, which is used to adjust the smoothness of the acceleration change when the vehicle approaches the desired speed to simulate different driving styles of human drivers, and δ is set to 4; s is the actual vehicle distance between the host vehicle and the vehicle ahead; s * is the desired vehicle distance, and the specific calculation formula is: In the formula, s0 is the minimum safety distance when the vehicle is stationary; T is the vehicle safety time interval, which reflects the driver's reaction time to the dynamic of the vehicle ahead; Δv is the speed difference between the host vehicle and the vehicle ahead; b is the comfortable deceleration, which reflects the comfort requirement of the driver when braking; When the actual vehicle distance s is greater than 1.5 times the desired vehicle distance s * , the vehicle will accelerate to the desired vehicle speed v0 in accordance with ; when the actual vehicle distance s is less than 0.8 times the desired vehicle distance s * , the braking term of the vehicle increases to reduce the acceleration of the host vehicle to maintain the desired vehicle distance s * ; when the speed v of the host vehicle and the relative speed Δv between the host vehicle and the vehicle in front change dynamically, the set desired vehicle distance s * will also change dynamically to ensure driving safety and comfort; According to the current moment information, the reference driving trajectory dataset can be divided into two major parts: historical information and future information; the reference driving trajectory data includes data of different scene categories such as lane change, following the vehicle ahead, low-speed driving, left turn, and right turn; After using the intelligent driver model to plan the future trajectory of the host vehicle based on the historical information of the host vehicle, obtain the evaluation indicators of the intelligent driver model under different scene categories, and consider three indicators of collision risk, scene completion degree, and driving comfort to judge and score the scene complexity; the scoring interval of the scene complexity scoring formula is S∈[0,100], and the higher the score, the more complex the scene. The scene complexity scoring formula is: Where S is the scene complexity score; N tota is the total number of samples in this scene category; N coll is the number of samples with collisions; N comp is the number of samples that complete the scene; N comf is the number of samples that meet the driving comfort; w1, w2, w3 are weight parameters reflecting the different importance degrees of the considered evaluation factors; α1, α2, α3 are non-linear scaling coefficients; 13) Perform quintile division according to the scene complexity score, that is, [0,20], [20,40], [40,60], [60,80], [80,100], classify the dataset according to the score quintile interval, and form five data buckets of scene difficulty levels.
3. A method for predicting and planning an autonomous driving trajectory based on scene category judgment according to claim 1, characterized in that, The specific method of the above Step 2 is as follows: 21) Use the training data importance sampling method based on geometric series to load data; the formula of the importance sampling method based on geometric series is: where q k is the sampling weight of the k-th data bin, reflecting the proportion of data bins with different scene difficulty levels in the overall data; is the initial weight of the k-th data bin. When the data is initially loaded, it is uniformly sampled and set to 1; is the final weight of the k-th data bin, which is determined by the scene complexity corresponding to this data bin; α is a proportionality coefficient used to control the change rate of the weight with the number of training steps; t is the current training step.
4. A method for autonomous driving trajectory prediction and planning based on scenario category judgment according to claim 1, characterized in that, The specific method of the above Step 3 is as follows: 31) Establish an autonomous driving prediction and planning model; the autonomous driving prediction and planning model includes a scene information vectorization module, a scene feature vector extraction module, a scene difficulty judgment and iteration number calculation module, an other vehicle trajectory prediction module, and a host vehicle trajectory planning module; The scene information vectorization module includes a scene information module and a scene vectorization module. The scene information module is used to obtain historical information of the agent, i.e., the ego vehicle and other vehicles, and scene context, i.e., element information of the map, acquired from the ego vehicle sensors. The scene vectorization module is used to process the agent historical state information and the scene context information separately. For the agent historical state information, including 2D position coordinates, heading angle, speed, and bounding box size information, trajectory points are sampled at fixed time intervals to form a time-continuous polyline and generate an agent vector sequence v_arr A ; for the scene context information, considering two types of map elements, lanes and crosswalks, the map elements are directly discretized into polylines, and key points are sampled according to the distance to generate a map vector sequence v_aar M ; for the agent vector sequence v_arr A and the map vector sequence v_arr M each vector node in contains start and end coordinates, semantic labels, and polyline ID attributes; for each agent, a local scene context is constructed, which includes the possible lanes adopted and the surrounding crosswalks; the position attributes of all agents and scene context elements are converted to the local coordinate system of the ego vehicle AV After scene information vectorization processing, a vector sequence containing proxy historical state information and scene context information is obtained; The scene feature vector extraction module is used to convert the original vector sequence into structured vector features. For the proxy historical information, a long short-term memory (LSTM) network is used for encoding, and each type of agent shares an LSTM encoder to generate the ego-vehicle feature vector v AV and the other-vehicle feature vector v AO ; for the two map elements of lanes and crosswalks in the scene context information, a multi-layer perceptron (MLP) is used to encode digital features such as position and direction, and an embedding layer is used to encode discrete features such as lane types and numbers. Finally, the two encoded map vectors are concatenated to form the scene context information feature tensor v CO ; the ego-vehicle feature vector v AV and the other-vehicle feature vector v AO and the scene context information feature tensor v CO constitute the scene feature vector v sc ; The other vehicle trajectory prediction module is used to input the scene feature vector v sc ; First, use the other vehicle feature vector v AO as a query (q), and the other vehicle feature vector v AO and the ego vehicle feature vector v AV as key-value pairs (k, v) to perform attention interaction to obtain the predicted intermediate feature vector v PRM ; Then, use the predicted intermediate feature vector v PRM as a query (q), and the scene context information feature tensor v CO as key-value pairs (k, v) to perform attention interaction to obtain the predicted feature vector v PR ; Finally, decode the future trajectory of the other vehicle from the predicted feature vector v PR through the other vehicle trajectory decoder based on MLP; The ego-vehicle trajectory planning module is used to input the scene feature vector v sc ; First, use the ego-vehicle feature vector v AV as the query (q), and the other-vehicle feature vector v AO as the key-value pair (k, v) to perform attention interaction, obtaining the intermediate planning feature vector v PLM ; Then, use the intermediate planning feature vector v PLM as the query (q), and the scene context information feature tensor v CO as the key-value pair (k, v) to perform attention interaction, obtaining the planning feature vector v PL ; Finally, decode the future trajectory of the other vehicle from the planning feature vector v PM through the ego-vehicle trajectory decoder of the MLP; The scene difficulty judgment and iteration count calculation module is used to input the scene feature vector v sc into the MLP-based scene difficulty decoder, and the scene difficulty decoder outputs the scene difficulty score of the scene; After that, the number of scenario iteration times is output according to the scenario difficulty score using the scenario iteration times formula, and a scenario iteration calculation formula establishing an exponential mapping relationship is used to ensure a high number of iterations for complex scenarios; the scenario iteration times calculation formula is: where N iter is the number of scene iterations; N min and N max are respectively the minimum and maximum number of iterations that can be set manually; C is the scene difficulty score; p = 1.5 controls the growth rate of the number of iterations; round() is a rounding function to ensure that the number of iterations is an integer; 32) After calculating the scene iteration times N based on the scene difficulty judgment and iteration times calculation module, the other vehicle trajectory prediction module and the ego vehicle trajectory planning module are interactively iterated. Specifically, the interactive iteration is achieved by passing the predicted feature vector v obtained by the other vehicle trajectory prediction module to the ego vehicle trajectory planning module and passing the planned feature vector v obtained by the ego vehicle trajectory planning module to the other vehicle trajectory planning module. iter After that, the other vehicle trajectory prediction module and the ego vehicle trajectory planning module are interactively iterated. Specifically, the interactive iteration is achieved by passing the predicted feature vector v obtained by the other vehicle trajectory prediction module PR to the ego vehicle trajectory planning module and passing the planned feature vector v obtained by the ego vehicle trajectory planning module PL to the other vehicle trajectory planning module.
Citation Information
Cited By
Intelligent driving task configuration method and electronic equipment
CN121210076A