Trajectory generation method and device of vehicle and processor

By introducing a vehicle kinematics model and the ILQR algorithm into the trajectory generation process, and combining penalty information to optimize the trajectory, the problem of low accuracy in vehicle trajectory generation is solved, and high-precision and smooth trajectory generation is achieved in complex environments.

CN121316907APending Publication Date: 2026-01-13GUANGZHOU AUTOMOBILE GROUP CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511865722.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-12-10
Publication Date
2026-01-13

AI Technical Summary

Technical Problem

Existing trajectory generation algorithms suffer from insufficient nonlinear modeling capabilities and weak constraint processing capabilities under complex road structures, dense dynamic obstacles, and multiple traffic rule constraints, making it difficult to guarantee real-time performance and resulting in low accuracy of vehicle trajectory generation.

Method used

By acquiring information on vehicle curvature and acceleration changes, a trajectory prediction model based on the vehicle's kinematics model is used for prediction. Combined with a trajectory optimization model based on the Iterative Linear Quadratic Regulator (ILQR) algorithm, different types of penalty information are introduced, such as kinematic continuity constraints, kinematic boundary constraints, and initial boundary constraints, to optimize the trajectory results and improve smoothness and safety.

Benefits of technology

It achieves high-precision generation of vehicle trajectories in complex environments, ensuring the smoothness and safety of the trajectory, and improving the vehicle's adaptability and driving experience in dynamic environments.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121316907A_ABST
    Figure CN121316907A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a vehicle track generation method and device and a processor, and the method comprises the steps: obtaining the driving information of a vehicle, the driving information comprises curvature change information and acceleration change information, the curvature change information is used for representing the change condition between the current curvature and the initial curvature of the vehicle, and the acceleration change information is used for representing the change condition between the current curvature and the initial curvature of the vehicle; the acceleration information is used for representing the change condition between the current acceleration and the initial acceleration of the vehicle; the driving information is input into a trajectory prediction model for trajectory prediction, a trajectory prediction result is obtained, the trajectory prediction model is constructed based on a kinematic model of the vehicle, and the trajectory prediction result is used for representing a prediction result of a trajectory of the vehicle at a future moment; and inputting the predicted trajectory result into a trajectory optimization model, and performing trajectory optimization on the predicted trajectory result by using different punishment information in the trajectory optimization model to obtain a trajectory optimization result. The technical problem of low generation precision of the track of the vehicle is solved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] Embodiments of the present application relate to the technical field of intelligent transportation, and in particular, to a trajectory generation method, device and processor of a vehicle. BACKGROUND

[0002] At present, with the rapid development of intelligent driving technology, as one of the cores of the vehicle automatic driving module, the trajectory planning system is gradually evolving towards higher precision, stronger robustness and higher real-time. Due to the complex road structure, dense dynamic obstacles and various traffic rule constraints faced by the automatic driving vehicle, the traditional trajectory generation algorithm (such as methods based on graph search, sampling, pure optimization, etc.) often has the limitations of insufficient non-linear modeling capability, weak constraint processing capability, poor adaptability to high dynamic environment, and difficulty in ensuring real-time. Therefore, there is still the technical problem of low generation precision of the trajectory of the vehicle.

[0003] In view of the above problems, no effective solution has been proposed so far. SUMMARY

[0004] Embodiments of the present application provide a trajectory generation method, device and processor of a vehicle, aiming to solve the technical problem of low generation precision of the trajectory of the vehicle.

[0005] According to an aspect of an embodiment of the present application, a trajectory generation method of a vehicle is provided, comprising: obtaining driving information of the vehicle, wherein the driving information comprises: curvature change information and acceleration change information, the curvature change information being used to represent the change between the current curvature and the initial curvature of the vehicle, and the acceleration information being used to represent the change between the current acceleration and the initial acceleration of the vehicle; inputting the driving information into a trajectory prediction model for trajectory prediction to obtain a trajectory prediction result, wherein the trajectory prediction model is constructed based on the kinematic model of the vehicle, and the trajectory prediction result is used to represent the prediction result of the trajectory of the vehicle at a future time; inputting the prediction trajectory result into a trajectory optimization model, and using different penalty information in the trajectory optimization model to perform trajectory optimization on the prediction trajectory result to obtain a trajectory optimization result, wherein the trajectory optimization model is constructed based on the ILQR algorithm, the different penalty information is used to represent the penalty term for different types of constraint conditions of the vehicle, the different types of constraint conditions include: kinematic continuity constraint condition, kinematic boundary constraint condition and initial boundary constraint condition, and the smoothness degree of the trajectory corresponding to the trajectory optimization result is higher than that of the trajectory corresponding to the trajectory prediction result.

[0006] The above optional embodiments of the present application can achieve the following technical effects: through the input of curvature change information and acceleration change information, the driving state of the vehicle can be finely controlled, and sudden turns or sudden acceleration / deceleration and other non-smooth driving behaviors can be avoided during prediction and optimization. In addition, the iterative characteristics of the Iterative Linear Quadratic Regulator (ILQR) algorithm gradually improve the smoothness of the trajectory prediction result while continuously optimizing the control input, making the optimized trajectory optimization result more in line with driving habits; the trajectory prediction model based on the kinematic model of the vehicle can more accurately predict the future driving trajectory of the vehicle, especially when considering curvature changes and acceleration changes, not only improving the accuracy of the prediction, but also ensuring the reliability of the trajectory prediction result, providing a solid foundation for the subsequent trajectory optimization result; by setting different types of penalty terms in the trajectory optimization model, the kinematic continuity constraint condition, the kinematic boundary constraint condition and the initial boundary constraint condition of the vehicle can be considered comprehensively, which can ensure that the trajectory optimization result is not only physically feasible, but also can safely drive under complex road conditions, meeting the strict requirements of the vehicle's autonomous driving system, thereby solving the technical problem of low accuracy of vehicle trajectory generation and achieving the technical effect of improving the accuracy of vehicle trajectory generation.

[0007] Optionally, the predicted trajectory result is input into the trajectory optimization model, and different penalty information in the trajectory optimization model is used to perform trajectory optimization on the predicted trajectory result to obtain a trajectory optimization result, including: in the trajectory optimization model, constraint information corresponding to different types of constraint conditions is obtained to obtain different constraint information; based on the barrier function, the different constraint information is converted to obtain different penalty information; the predicted trajectory result is input into the trajectory optimization model, and the different penalty information is used to perform trajectory adjustment on the predicted trajectory result to obtain the trajectory optimization result.

[0008] The optional embodiments of the present application can achieve the following technical effects: by inputting the predicted trajectory result as an initial point into the trajectory optimization model, the predicted trajectory result can be corrected and optimized based on real-time environmental information and vehicle state, not only improving the adaptability of trajectory planning to dynamic obstacles and road condition changes, but also ensuring that a safe and feasible driving trajectory can be generated under various complex working conditions. In the trajectory optimization model, different types of constraint conditions are obtained and converted into corresponding constraint information and penalty information, so that the predicted trajectory result can more carefully consider the vehicle kinematic constraints, physical limitations and safety distance requirements, avoiding trajectory distortion or collision risks caused by improper constraint processing. The constraint information is converted into penalty information using the barrier function, which helps to achieve trajectory smoothness and physical feasibility during trajectory optimization. Then, the predicted trajectory result is input into the trajectory optimization model, and different penalty information is used to adjust the predicted trajectory result to obtain the trajectory optimization result, so that static obstacles can be processed while effectively dealing with dynamic obstacles.

[0009] Optionally, based on the barrier function, different constraint information is converted to obtain different penalty information, including: constructing the barrier function as a penalty function; and converting different constraint information using the penalty function to obtain different penalty information.

[0010] The above optional embodiments of the present application can achieve the following technical effects: by converting constraint information based on the barrier function, multiple types of constraint information can be comprehensively processed, improving the real-time performance, computational efficiency and robustness of trajectory optimization, while ensuring that the generated trajectory is smooth and safe, thereby significantly improving the driving performance of the vehicle in complex environments and user experience.

[0011] Optionally, the barrier function is constructed as a penalty function, including: dividing the barrier function into intervals according to the kinematic continuity constraint condition, the kinematic boundary constraint condition and the starting boundary constraint condition to obtain the penalty function.

[0012] The above optional embodiments of the present application can achieve the following technical effects: by dividing the barrier function into intervals according to different types of constraint conditions to obtain the penalty function, various constraints can be correctly identified and processed, avoiding ambiguity or false triggering problems caused by related constraint processing methods.

[0013] Optionally, the different constraint information includes first constraint information corresponding to the kinematic continuity constraint condition, second constraint information corresponding to the kinematic boundary constraint condition, and third constraint information corresponding to the initial boundary constraint condition, wherein the different constraint information is converted into different penalty information by using a penalty function, including: the first constraint information is introduced into the penalty function to obtain the first penalty information, the second constraint information is introduced into the penalty function to obtain the second penalty information, and the third constraint information is introduced into the penalty function to obtain the third penalty information, wherein the first penalty information is used to represent a penalty term for the kinematic continuity constraint condition, the second penalty information is used to represent a penalty term for the kinematic boundary constraint condition, and the third penalty information is used to represent a penalty term for the initial boundary constraint condition.

[0014] The above-mentioned optional embodiments of the present application can achieve the following technical effects: the kinematic continuity constraint, the kinematic boundary constraint, and the initial boundary constraint are respectively converted into the first penalty information, the second penalty information, and the third penalty information, ensuring that these constraints are accurately reflected in the optimization process. Through the targeted penalty function, the driving state of the vehicle can be more finely controlled to avoid violating the constraint information, improving the accuracy and feasibility of trajectory planning.

[0015] Optionally, the predicted trajectory result is input into the trajectory optimization model, and the predicted trajectory result is trajectory adjusted by using the different penalty information to obtain a trajectory optimization result, including: the predicted trajectory result is input into the trajectory optimization model, and trajectory deviation information is obtained by calculating the trajectory deviation between the predicted trajectory result and the reference trajectory result; a plurality of weights are obtained by respectively determining the weights of the different penalty information, including: a first weight of the first penalty information, a second weight of the second penalty information, and a third weight of the third penalty information; the first penalty information is adjusted by using the first weight, the second penalty information is adjusted by using the second weight, and the third penalty information is adjusted by using the third weight; the adjusted first penalty information, the adjusted second penalty information, and the adjusted third penalty information are used as target constraint information of the trajectory optimization model to punish the trajectory deviation information, so as to perform trajectory adjustment on the predicted trajectory result to obtain the trajectory optimization result.

[0016] The above optional embodiments of the present application can achieve the following technical effects: by calculating the trajectory deviation information between the predicted trajectory result and the reference trajectory result, and punishing the trajectory deviation information, the predicted trajectory can be finely adjusted to ensure that the vehicle driving path is closer to the preset driving path. Such adjustment can not only improve the accuracy of the driving path, but also ensure that the path planning is more reasonable and meets the actual driving needs. By determining the weights of different penalty information (such as the first weight of the first penalty information, the second weight of the second penalty information, and the third weight of the third penalty information), multi-objective comprehensive optimization can be achieved. For example, the first penalty information can correspond to physical constraints, the second penalty information can focus on smoothness, and the third penalty information can focus on obstacle avoidance requirements. By adjusting the weights of each penalty information, the smoothness and safety of the driving path can be further optimized on the basis of ensuring physical feasibility, achieving better comprehensive performance.

[0017] Optionally, the method further comprises: obtaining a driving data set of the vehicle; extracting the current curvature, the initial curvature, the current acceleration, and the initial acceleration from the driving data set; determining the curvature change information based on the current curvature and the initial curvature, and determining the acceleration change information based on the current acceleration and the initial acceleration.

[0018] The above optional embodiments of the present application can achieve the following technical effects: by collecting and analyzing the driving data set of the vehicle in real time, determining the curvature change information and the acceleration change information, fine control of the vehicle driving trajectory can be achieved, adaptability to dynamic environment is enhanced, and at the same time, driving quality and efficiency of the vehicle under physical and safety constraints are ensured, thereby not only improving the driving experience, but also providing a solid foundation for the safety and intelligent decision-making of the vehicle.

[0019] Optionally, the method further comprises: constructing a trajectory prediction model based on a kinematic model of the vehicle, wherein the trajectory prediction model is used for trajectory prediction on the driving information to obtain a trajectory prediction result; and constructing a trajectory optimization model based on an ILQR algorithm, wherein the trajectory optimization model is used for trajectory optimization on the predicted trajectory result by using different penalty information to obtain a trajectory optimization result.

[0020] The above optional embodiments of the present application can achieve the following technical effects: by constructing the trajectory prediction model based on the kinematic model of the vehicle and the trajectory optimization model based on the ILQR algorithm, and combining the dynamic adjustment of different penalty information, the accuracy, real-time performance, robustness, and safety of trajectory prediction and optimization can be significantly improved, and the driving performance of the vehicle in complex environments is optimized, thereby providing strong support for the development of intelligent driving.

[0021] According to another aspect of the embodiments of this application, a vehicle trajectory generation device is also provided. The device may include: an acquisition unit for acquiring vehicle driving information, wherein the driving information includes curvature change information and acceleration change information, the curvature change information representing the change between the vehicle's current curvature and initial curvature, and the acceleration information representing the change between the vehicle's current acceleration and initial acceleration; a prediction unit for inputting the driving information into a trajectory prediction model to perform trajectory prediction and obtain a trajectory prediction result, wherein the trajectory prediction model is constructed based on the vehicle's kinematic model, and the trajectory prediction result represents the predicted trajectory of the vehicle at a future time; and an optimization unit for inputting the predicted trajectory result into a trajectory optimization model, and for optimizing the predicted trajectory result using different penalty information in the trajectory optimization model to obtain a trajectory optimization result, wherein the trajectory optimization model is constructed based on the ILQR algorithm, and the different penalty information represents penalty terms for different types of constraints on the vehicle, including: kinematic continuity constraints, kinematic boundary constraints, and initial boundary constraints, and the smoothness of the trajectory corresponding to the trajectory optimization result is higher than the smoothness of the trajectory corresponding to the trajectory prediction result.

[0022] According to another aspect of the embodiments of this application, an electronic device is also provided, including a processor and a memory. The memory is used to store computer programs. The processor is used to execute the programs stored in the memory to implement the above-described method.

[0023] According to another aspect of the embodiments of this application, a computer-readable storage medium is also provided. This computer-readable storage medium includes a stored program, wherein, when the program is executed, it controls the device where the computer-readable storage medium is located to perform the methods described in the embodiments of this application.

[0024] According to another aspect of the embodiments of this application, a processor is also provided. This processor is used to run a program, wherein the program executes the methods described in the embodiments of this application during runtime.

[0025] According to another aspect of the embodiments of this application, a vehicle is also provided. This vehicle is used to perform the methods described in the embodiments of this application.

[0026] It should be noted that the general descriptions above and the detailed descriptions below are merely illustrative and explanatory for this application and do not constitute a limitation thereof.

[0027] In this application, by collecting real-time information on vehicle curvature and acceleration changes, the current dynamic state of the vehicle can be more accurately grasped, such as the vehicle's steering trend and acceleration changes. The driving information is input into a trajectory prediction model for trajectory prediction, yielding a predicted trajectory result—that is, a predicted trajectory for the vehicle at a future time. This predicted trajectory result is then input into a trajectory optimization model, and different penalty information within the model is used to optimize the predicted trajectory, resulting in an optimized trajectory result. The trajectory optimization model based on the ILQR algorithm can further optimize the smoothness of the path based on the predicted trajectory result. By introducing different types of constraints (such as kinematic continuity constraints, kinematic boundary constraints, and initial boundary constraints) as penalty terms, abrupt changes in the path, such as unnecessary sharp turns or accelerations, can be avoided, thus generating a smoother, more comfortable, and physically feasible driving trajectory. This achieves the goal of cost-effective intelligent trajectory optimization, thereby solving the technical problem of low trajectory generation accuracy and improving the accuracy of vehicle trajectory generation. Attached Figure Description

[0028] Figure 1 This is a flowchart of a vehicle trajectory generation method provided in one embodiment of this application;

[0029] Figure 2 This is a flowchart of an intelligent vehicle trajectory optimization method based on an iterative linear quadratic regulator algorithm provided in an embodiment of this application;

[0030] Figure 3 This is a structural diagram of a vehicle trajectory generation device provided in one embodiment of this application;

[0031] Figure 4 This is a structural diagram of an electronic device provided in an embodiment of this application. Detailed Implementation

[0032] To make the technical problems, technical solutions, and beneficial effects solved by this application clearer, the following detailed description is provided in conjunction with embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0033] In related technologies, an augmented Lagrange iterative linear quadratic regulator path planning method based on an iterative linear quadratic regulator is proposed. The method includes: constructing a trajectory optimization model based on an iterative linear quadratic regulator algorithm, the input data of which includes driving state vectors and control vectors; constructing a kinematic model of the vehicle during driving; constructing an augmented Lagrange trajectory optimization model, which adds a Lagrange operator model to the trajectory optimization model; obtaining constraints on the driving state vectors; using the first constraint as the constraint of the trajectory optimization model and the second constraint as the constraint of the Lagrange operator model, and iteratively iterating the augmented Lagrange trajectory optimization model in conjunction with the vehicle's driving state vectors until the control vector in the trajectory optimization model reaches its optimum and the Lagrange penalty operator in the Lagrange operator model reaches its optimum, thus obtaining the final path planning model. However, the above methods tend to converge to local optima or even diverge when encountering strong nonlinearities (such as sharp turns or dynamic obstacles) or non-convex constraints (such as irregular obstacle regions). The solution speed is limited by the solver performance, and it cannot meet real-time requirements in large time domains or complex working conditions. It is also difficult to quickly adjust the output trajectory in highly dynamic interactive scenarios. Therefore, the technical problem of low accuracy in generating vehicle trajectories still exists.

[0034] To address the aforementioned problems, this application provides a method for generating vehicle trajectories. This method may include: acquiring vehicle driving information, wherein the driving information includes curvature change information and acceleration change information, the curvature change information representing the change between the vehicle's current curvature and initial curvature, and the acceleration information representing the change between the vehicle's current acceleration and initial acceleration; inputting the driving information into a trajectory prediction model for trajectory prediction, obtaining a trajectory prediction result, wherein the trajectory prediction model is constructed based on the vehicle's kinematic model, and the trajectory prediction result represents the predicted trajectory of the vehicle at a future time; inputting the predicted trajectory result into a trajectory optimization model, and using different penalty information in the trajectory optimization model to optimize the predicted trajectory result, obtaining a trajectory optimization result, wherein the trajectory optimization model is constructed based on the ILQR algorithm, and the different penalty information represents penalty terms for different types of constraints on the vehicle, including: kinematic continuity constraints, kinematic boundary constraints, and initial boundary constraints; the smoothness of the trajectory corresponding to the trajectory optimization result is higher than the smoothness of the trajectory corresponding to the trajectory prediction result.

[0035] The vehicle control method provided in this application achieves the following technical effects: By collecting real-time information on vehicle curvature and acceleration changes, this application can more accurately grasp the current dynamic state of the vehicle, such as its steering trend and acceleration changes. Driving information is input into a trajectory prediction model for trajectory prediction, yielding a predicted trajectory result—that is, a predicted trajectory of the vehicle at a future time. This predicted trajectory result is then input into a trajectory optimization model, and different penalty information within the model is used to optimize the predicted trajectory result, resulting in an optimized trajectory. The trajectory optimization model based on the ILQR algorithm can further optimize the smoothness of the path based on the predicted trajectory result. By introducing different types of constraints (such as kinematic continuity constraints, kinematic boundary constraints, and initial boundary constraints) as penalty terms, abrupt changes in the path, such as unnecessary sharp turns or accelerations, can be avoided, thereby generating a smoother, more comfortable, and physically feasible driving trajectory. This achieves the goal of cost-effective intelligent trajectory optimization, thus solving the technical problem of low trajectory generation accuracy and improving the accuracy of vehicle trajectory generation.

[0036] This application provides a method for generating vehicle trajectories. Please refer to [the relevant documentation]. Figure 1 , Figure 1 This is a flowchart of a vehicle trajectory generation method provided in an embodiment of this application, including the following steps S102 to S106.

[0037] Step S102: Obtain vehicle driving information.

[0038] In step S102, during the vehicle trajectory planning process, in order to provide comprehensive and detailed information on the current vehicle status and environmental data as the basis for subsequent path planning and optimization, the vehicle's driving information can be obtained.

[0039] In this embodiment, vehicle driving information is acquired. This driving information may include curvature change information and acceleration change information. The curvature change information indicates the change between the vehicle's current curvature and its initial curvature, while the acceleration information indicates the change between the vehicle's current acceleration and its initial acceleration. Furthermore, the vehicle driving information may also include: position coordinate information, heading angle information, velocity information, curvature information, acceleration information, and rate of change of acceleration information, etc.

[0040] In this embodiment, the aforementioned location coordinate information can be used to determine the vehicle's current location. For example, the location coordinate information can be the vehicle's coordinates on a map.

[0041] In this embodiment, the heading angle information can be used to represent the vehicle's direction of travel, expressed in angular form, which is crucial for path tracking.

[0042] In this embodiment, the speed information can be used to represent the current driving speed of the vehicle and can affect the real-time performance and safety of path planning.

[0043] In this embodiment, the curvature information can be used as a parameter to describe the degree of curvature of the vehicle path, which helps to optimize the driving smoothness when turning.

[0044] In this embodiment, the acceleration information may include lateral acceleration and longitudinal acceleration, and may affect the acceleration and deceleration process of the vehicle.

[0045] In this embodiment, the aforementioned acceleration change rate information can be used to represent the changes in acceleration, and can affect driving comfort during vehicle operation, for example, when the vehicle changes lanes or turns.

[0046] Optionally, various sensors deployed in the vehicle (such as GPS, gyroscopes, accelerometers, cameras, radar, lidar, etc.) can be used to collect vehicle driving information such as position, attitude, speed, and surrounding environment information. Through Vehicle-to-Everything (V2X) communication technology, vehicle driving information can be received from surrounding vehicles, infrastructure (such as traffic lights), or other traffic participants, as well as real-time traffic information obtained through the network.

[0047] It should be noted that the specific content and acquisition method of the above vehicle driving information are for illustrative purposes only, and no specific restrictions are imposed here.

[0048] The above-mentioned optional embodiments of this application can achieve the following technical effects: by obtaining the vehicle's driving information, the real-time position, speed, acceleration, heading angle and curvature of the vehicle can be understood, ensuring that subsequent path planning is based on the current driving state, thereby ensuring the accuracy of path planning.

[0049] Step S104: Input the driving information into the trajectory prediction model to perform trajectory prediction and obtain the trajectory prediction result.

[0050] In step S104, the trajectory prediction model can be constructed based on the vehicle's kinematic model, and the trajectory prediction result can be used to represent the predicted trajectory of the vehicle at future times.

[0051] Optionally, after acquiring the vehicle's driving information, the driving information can be input into a trajectory prediction model for trajectory prediction to obtain the trajectory prediction result. Alternatively, the curvature change information, acceleration change information, and other driving information from the driving information can be input into the trajectory prediction model for prediction to obtain the trajectory prediction result. The trajectory prediction model can be based on machine learning techniques, such as neural network models in deep learning, or regression models in statistical learning, etc., by learning from a large number of driving information samples and corresponding trajectory samples, thereby establishing a mapping relationship from driving information to the predicted trajectory.

[0052] Optionally, during the trajectory prediction model training phase, driving information samples can be used as input, and the corresponding trajectory prediction results can be used as output labels to train the trajectory prediction model to predict the vehicle's driving trajectory under specific driving conditions. In practical applications, real-time acquired driving information can be input into the trained trajectory prediction model, which can then output a predicted driving trajectory.

[0053] Optionally, the first driving data can describe the vehicle's real-time driving status at the current moment. The first driving data may include position coordinates, speed, acceleration, heading angle, curvature, etc. The aforementioned first driving data can be used to provide basic information about the vehicle's current environment and status, which is the basis for predicting costs.

[0054] Optionally, the second driving data can reflect the differences and trends between the vehicle's driving state and its initial state. The second driving data may include the rate of change of speed, the rate of change of acceleration, etc., which helps to understand the dynamic behavior of the vehicle, predict how the vehicle's state will evolve in the next period of time, and the corresponding cost changes.

[0055] The above optional embodiments of this application can achieve the following technical effects: by using a trajectory prediction model to predict the trajectory of a vehicle at a future time, the smoothness of the trajectory prediction results can be improved.

[0056] Step S106: Input the predicted trajectory result into the trajectory optimization model, and use different penalty information in the trajectory optimization model to optimize the predicted trajectory result to obtain the trajectory optimization result.

[0057] In step S106, the trajectory optimization model is constructed based on the Iterative Linear Quadratic Regulator (ILQR) algorithm. Different penalty information is used to represent penalty terms for different types of constraints on the vehicle. Different types of constraints may include: kinematic continuity constraints, kinematic boundary constraints, and initial boundary constraints. The smoothness of the trajectory corresponding to the trajectory optimization result is higher than that of the trajectory corresponding to the trajectory prediction result.

[0058] In this embodiment, after inputting driving information into the trajectory prediction model to predict the trajectory and obtaining the trajectory prediction result, the predicted trajectory result can be input into the trajectory optimization model, and the predicted trajectory result can be optimized using different penalty information in the trajectory optimization model to obtain the trajectory optimization result.

[0059] Optionally, the trajectory corresponding to the predicted trajectory result is input into the ILQR model as the initial trajectory. Penalty information for each constraint can be set, including but not limited to kinematic continuity constraints, kinematic boundary constraints, and initial boundary constraints. This penalty information is an additional cost term used during the optimization process to guide the trajectory towards satisfying specific constraints. By utilizing different penalty information in the trajectory optimization model, the initial trajectory is optimized to obtain the optimized initial trajectory, which is then determined as the trajectory optimization result.

[0060] Optionally, kinematic continuity constraints can ensure smooth transitions between trajectory points and avoid discontinuous jumps. This can be achieved by penalizing abrupt changes in velocity, acceleration, or higher-order derivatives between trajectory points. Kinematic boundary constraints can limit the kinematic parameters of trajectory points, such as velocity, acceleration, and curvature, to a reasonable range to conform to the actual motion capabilities and safety standards of the vehicle. Initial boundary constraints can ensure that the trajectory optimization results begin with the current actual state of the vehicle, including position, velocity, and steering angle.

[0061] Optionally, the characteristics of the ILQR algorithm can be utilized, namely, iterating backward from the end of the trajectory, adjusting the control input (such as the rate of change of acceleration and the rate of change of curvature) in each iteration to minimize the total cost function, which includes different penalty terms. Through repeated iterations, the ILQR algorithm gradually improves the trajectory until all constraints are met and the predetermined smoothness and control quality standards are achieved.

[0062] Optionally, the ILQR algorithm can pay special attention to the smoothness of the trajectory during the optimization process, reduce unnecessary acceleration and deceleration, as well as abrupt changes in direction. The final trajectory optimization result maintains the safety and feasibility of the vehicle path, while its smoothness is significantly higher than the original predicted trajectory, and it can better adapt to dynamic environments and driver comfort requirements.

[0063] The above-described optional embodiments of this application achieve the following technical effects: The ILQR algorithm, through iterative adjustment of the control input, can effectively improve the smoothness of the predicted trajectory. Compared to the original predicted trajectory, the optimized trajectory significantly reduces unnecessary curvature changes and acceleration fluctuations, improves driving comfort, reduces wear and tear on vehicle components caused by frequent and drastic changes, and also reduces energy consumption and improves driving efficiency.

[0064] Based on steps S102 to S106 above, this application, by collecting real-time information on vehicle curvature and acceleration changes, can more accurately grasp the vehicle's current dynamic state, such as its steering trend and acceleration changes. The driving information is input into a trajectory prediction model for trajectory prediction, yielding a predicted trajectory result—that is, a predicted trajectory for the vehicle at a future time. This predicted trajectory result is then input into a trajectory optimization model, and different penalty information within the model is used to optimize the predicted trajectory, resulting in an optimized trajectory result. The trajectory optimization model based on the ILQR algorithm can further optimize the smoothness of the path based on the predicted trajectory result. By introducing different types of constraints (such as kinematic continuity constraints, kinematic boundary constraints, and initial boundary constraints) as penalty terms, abrupt changes in the path, such as unnecessary sharp turns or accelerations, can be avoided, thus generating a smoother, more comfortable, and physically feasible driving trajectory. This achieves the goal of cost-effective intelligent trajectory optimization, thereby solving the technical problem of low trajectory generation accuracy and improving the accuracy of vehicle trajectory generation.

[0065] The method described in this embodiment will now be further explained.

[0066] As an optional embodiment, step S106 involves inputting the predicted trajectory result into the trajectory optimization model and optimizing the predicted trajectory result using different penalty information in the trajectory optimization model to obtain the trajectory optimization result. This includes: obtaining constraint information corresponding to different types of constraints in the trajectory optimization model to obtain different constraint information; transforming the different constraint information based on the obstacle function to obtain different penalty information; inputting the predicted trajectory result into the trajectory optimization model and adjusting the predicted trajectory result using different penalty information to obtain the trajectory optimization result.

[0067] In this embodiment, during the process of inputting the predicted trajectory results into the trajectory optimization model and optimizing the predicted trajectory results using different penalty information in the trajectory optimization model to obtain the trajectory optimization result, different types of constraints can be extracted from the vehicle's current operating state and environmental information, such as speed limits, acceleration limits, curvature limits, and safe distances to static and dynamic obstacles. These constraints constitute hard constraints during vehicle operation and must be strictly adhered to during trajectory optimization.

[0068] Optionally, after obtaining the constraint information corresponding to different types of constraints, the obstacle function method can be used to transform each type of constraint information. An obstacle function is a mathematical tool that transforms constraints into penalty terms of a cost function. It ensures that when a vehicle approaches or violates constraints, the optimization objective increases significantly, thereby driving the algorithm to avoid these situations. For example, for obstacle avoidance, the obstacle function can dynamically adjust the penalty intensity based on the distance between the vehicle and the obstacle. When the distance is close to or less than a safety threshold, the penalty term will increase significantly, prompting the trajectory to move away from the obstacle.

[0069] Optionally, after obtaining different penalty information, the predicted initial trajectory result can be used as input to the trajectory optimization model. The trajectory optimization model iteratively optimizes the control input, gradually adjusting the trajectory to ensure that the adjusted trajectory not only follows the reference path but also satisfies different constraint information, until an optimized trajectory that minimizes the total cost and satisfies all constraint information is found. Finally, the trajectory optimization model outputs an optimized trajectory sequence that considers not only the vehicle's physical limitations and obstacle safety but also maintains the smoothness and comfort of the path as much as possible. This optimization result can be directly used for vehicle path tracking control, ensuring that autonomous vehicles can drive safely, efficiently, and comfortably in complex environments such as urban roads, intersections, and narrow sections.

[0070] The above-mentioned optional embodiments of this application can achieve the following technical effects: by inputting the predicted trajectory result into the trajectory optimization model and using different constraint information to adjust the predicted trajectory result, the trajectory optimization result can be obtained. This can effectively solve the shortcomings of related trajectory planning methods in handling nonlinear constraints and obstacle avoidance, as well as the technical problems of poor robustness and real-time performance of the algorithm. This makes the generated trajectory more in line with actual driving needs and enhances the vehicle's adaptability and safety in dynamic environments.

[0071] As an optional implementation method, different constraint information is transformed based on the obstacle function to obtain different penalty information, including: constructing the obstacle function as a penalty function; and using the penalty function to transform different constraint information to obtain different penalty information.

[0072] In this embodiment, the obstacle function method can be used to convert various constraint information (including kinematic continuity constraints, kinematic boundary constraints, and initial boundary constraints) in vehicle trajectory planning into penalty information (e.g., penalty terms) in the optimization problem, and then use the ILQR algorithm for efficient and accurate trajectory optimization.

[0073] Optionally, a barrier function is a function used to describe the "barrier" or "cost" incurred when constraints deviate from the normal range. By defining a barrier function and transforming it into part of a penalty function, it can be used to quantify the degree to which the trajectory deviates from the constraints. The barrier function has the following characteristics: when the constraints are strictly satisfied, the value of the barrier function is 0, indicating no additional "barrier" cost; when the trajectory begins to violate the constraints, the value of the barrier function increases rapidly, acting as a "barrier wall" to prevent the trajectory from deviating further.

[0074] Optionally, the penalty function is a specific implementation of the barrier function, which can be applied under different constraints to form a series of penalty terms. These penalty terms are added to the total cost function, thereby guiding the ILQR algorithm to find the optimal trajectory while satisfying the constraints.

[0075] The optional embodiments described above in this application can achieve the following technical effects: Through the above series of transformations, an optimization framework can be constructed that can both pursue the original trajectory optimization objective and strictly adhere to various constraints. During the iterative optimization process of the ILQR algorithm, these penalty terms can guide the ILQR algorithm to gradually adjust the vehicle trajectory until a better path is found that is both smooth and meets all physical constraints and safety standards.

[0076] As an optional implementation method, the obstacle function is constructed as a penalty function, including: dividing the obstacle function into intervals according to kinematic continuity constraints, kinematic boundary constraints, and initial boundary constraints to obtain the penalty function.

[0077] In this embodiment, the kinematic continuity constraint requires that the vehicle's state changes smoothly between adjacent time points, avoiding sudden changes in speed or direction. The kinematic boundary constraints define acceptable ranges for the vehicle's speed, acceleration, and curvature to ensure physical feasibility and safety. The initial boundary constraints ensure that the optimized trajectory begins with the vehicle's actual state, including position, speed, and orientation.

[0078] Optionally, the construction of the penalty function needs to consider the continuity of the vehicle state. Therefore, the obstacle function can be divided into intervals according to the kinematic continuity constraints. For example, a set of time intervals can be defined. In each time interval, the rate of change of the vehicle's speed, heading angle, and curvature can be examined to see if they exceed the preset thresholds. For each state variable, a penalty function can be defined. When the rate of change exceeds the corresponding threshold, the penalty function value increases, and the ILQR algorithm is controlled to adjust the control input to meet the continuity requirements.

[0079] Optionally, the obstacle function can be divided into intervals according to kinematic boundary constraints. For example, allowable ranges for velocity, acceleration, and curvature can be defined, and a penalty interval can be created for each range. A penalty cost can be added for values ​​that exceed the allowable range, and a penalty function can be determined.

[0080] Optionally, the obstacle function can be divided into intervals according to the initial boundary constraints. For example, the deviation between the initial state and the actual vehicle state can be intervalized, and a deviation range can be defined. If the initial state deviation is greater than the maximum allowable value, the penalty function will be increased.

[0081] The above-described optional embodiments of this application achieve the following technical effects: by transforming the obstacle function into a specific penalty function and dividing different constraints into intervals, this embodiment provides a systematic and quantifiable processing method to ensure that the trajectory optimization process based on the ILQR algorithm strictly adheres to the vehicle's physical constraints and safety standards. This penalty function construction strategy improves optimization efficiency while also enhancing the robustness and applicability of the trajectory optimization results.

[0082] As an optional embodiment, the different constraint information includes: first constraint information corresponding to kinematic continuity constraints, second constraint information corresponding to kinematic boundary constraints, and third constraint information corresponding to initial boundary constraints. The different constraint information is transformed using a penalty function to obtain different penalty information, including: importing the first constraint information into the penalty function to obtain first penalty information; importing the second constraint information into the penalty function to obtain second penalty information; and importing the third constraint information into the penalty function to obtain third penalty information. The first penalty information represents the penalty term for kinematic continuity constraints, the second penalty information represents the penalty term for kinematic boundary constraints, and the third penalty information represents the penalty term for initial boundary constraints.

[0083] In this embodiment, the first constraint information is used to represent the conditions for applying kinematic constraints to multiple first driving data and multiple second driving data. It can be a vehicle kinematic continuity constraint, which can be determined by the following formula:

[0084] (1)

[0085] in, , can be used to represent state variables, x k and y k It can be used to represent position coordinates, θ k It can be used to represent heading angle, v k It can be used to represent speed, k k It can be used to represent curvature. a k It can be used to represent acceleration; , can be used to represent control variables, It can be used to represent the rate of change of curvature. It can be used to represent the rate of change of acceleration.

[0086] The third constraint information is used to represent the conditions for boundary constraints on the current driving trajectory. It can be the boundary constraint of the starting point and can be determined by the following formula:

[0087] (2)

[0088] in, It can be used to indicate the starting position of the current driving trajectory.

[0089] The second constraint information is used to represent at least the conditions for obstacle avoidance constraints on the vehicle, and can be kinematic boundary constraints and obstacle avoidance constraints, which can be determined by the following formula:

[0090] (3)

[0091] Optionally, in the process of transforming different constraint information using the penalty function to obtain different penalty information, the first constraint information can be imported into the penalty function to obtain the first penalty information, the second constraint information can be imported into the penalty function to obtain the second penalty information, and the third constraint information can be imported into the penalty function to obtain the third penalty information. Optimization algorithms, such as the ILQR algorithm, can be used to further optimize the cost data to minimize the target cost data. The final target cost data reflects the lowest cost or optimal performance index when the vehicle executes the planned driving trajectory while complying with all constraints.

[0092] Optionally, to solve using ILQR, constraints need to be addressed. Barrier functions can be used to convert constraint information into penalty terms in the cost function. When constraints are strictly satisfied, the penalty term is zero; when constraints are not satisfied, the penalty term is greater than zero. Therefore, by finding the minimum value of the cost function and bringing the penalty term closer to zero, the optimization quantity that satisfies the constraints can be obtained.

[0093] Ideal obstacle function It can be determined using the following formula:

[0094] (4)

[0095] in, It can be used to represent the input parameters of an ideal obstacle function.

[0096] Construct the barrier function as a differentially continuous function:

[0097] (5)

[0098] The constraint terms using the penalty function can be expressed as:

[0099]

[0100] (6)

[0101] (7)

[0102] (8)

[0103] (9)

[0104] in, Constraint terms that can be used to represent vehicle kinematic continuity constraints, i.e., the first penalty information, It can be used to represent the constraint terms of obstacle avoidance constraints established based on the vehicle's potential energy field, that is, the second penalty information. Constraint terms that can be used to represent starting point boundary constraints, also known as third-party penalty information, It can be used to represent the total constraint term. , , , , , , It can be used to represent the weight of each penalty item.

[0105] The above-mentioned optional embodiments of this application can achieve the following technical effects: by integrating kinematics, obstacle avoidance constraints and boundary-corresponding first constraint information, second constraint information and third constraint information, a more rigorous and safer vehicle trajectory generation method is provided, which not only improves the efficiency and economy of vehicle driving, but also significantly enhances the safety and controllability of driving.

[0106] As an optional embodiment, step S106, which involves inputting the predicted trajectory result into the trajectory optimization model and adjusting the predicted trajectory result using different penalty information to obtain the trajectory optimization result, includes: inputting the predicted trajectory result into the trajectory optimization model; calculating the trajectory deviation between the predicted trajectory result and the reference trajectory result to obtain trajectory deviation information; determining the weights of different penalty information to obtain multiple weights, including: determining the first weight of the first penalty information, the second weight of the second penalty information, and the third weight of the third penalty information; adjusting the first penalty information using the first weight, adjusting the second penalty information using the second weight, and adjusting the third penalty information using the third weight; using the adjusted first penalty information, the adjusted second penalty information, and the adjusted third penalty information as the target constraint information of the trajectory optimization model to penalize the trajectory deviation information, thereby adjusting the predicted trajectory result to obtain the trajectory optimization result.

[0107] In this embodiment, the predicted trajectory result is input into the trajectory optimization model. The trajectory optimization model compares the predicted trajectory result with a preset reference trajectory result and calculates the trajectory deviation information between the two. This trajectory deviation information may include position deviation, velocity deviation, heading angle deviation, and curvature deviation, etc. Based on the trajectory deviation information calculated above, the weights of the penalty information for kinematic continuity constraints, kinematic boundary constraints, and initial boundary constraints can be determined respectively.

[0108] Optionally, the setting of weights is crucial to the optimization results, determining the priority and importance of different constraints during the optimization process. By adjusting the various penalty information using the weights determined above, it can be ensured that the trajectory optimization model can effectively penalize the parts of the predicted trajectory that violate the constraints.

[0109] For example, the adjustment of the first penalty information can be achieved using the first weight. If the predicted trajectory result deviates from the kinematic continuity, the penalty function will increase, causing the optimization algorithm to adjust the rate of change between trajectory points until the continuity requirement is met. The adjustment of the second penalty information can be achieved using the second weight. If the predicted trajectory result exceeds the allowable range of kinematic parameters, the penalty function will increase, adjusting the control input to meet boundary constraints. The adjustment of the third penalty information can be achieved using the third weight. If the starting point of the optimized trajectory does not match the current state of the vehicle, the penalty function will increase, adjusting the initial state of the trajectory to ensure consistency with the actual state of the vehicle. Then, the adjusted penalty information is integrated into the trajectory optimization model as target constraint information. The trajectory optimization model can then penalize trajectory deviations based on this information to adjust the predicted trajectory result, making it as close as possible to the reference trajectory while satisfying all constraints.

[0110] Optionally, in the above formula (9) , , , , , , The weights of each penalty term can be used to represent the trajectory optimization problem, which can then be transformed into:

[0111] (10)

[0112] (11)

[0113] (12)

[0114] in, It can be used to represent the cost of the last node. It can be used to represent the first The cost of each node.

[0115] Optionally, according to the solution process of the ILQR algorithm, it is necessary to calculate right The partial derivatives, and right The first and second partial derivatives, i.e., the objective function. After several iterations, the ILQR algorithm obtains a sequence of control inputs, thereby generating a trajectory optimization result (e.g., a target driving trajectory). This target driving trajectory not only smoothly and accurately tracks the reference trajectory, but also avoids obstacles and satisfies physical constraints such as speed, acceleration, and turning angle.

[0116] The above-mentioned optional embodiments of this application can achieve the following technical effects: through penalty information and weight adjustment and trajectory optimization process, the predicted trajectory results can be effectively adjusted to ensure that the trajectory optimization results can not only smoothly track the reference trajectory, but also comply with the first constraint information corresponding to the kinematic continuity constraint conditions, the second constraint information corresponding to the kinematic boundary constraint conditions, and the third constraint information corresponding to the initial boundary constraint conditions, thereby realizing the efficient and safe driving of intelligent vehicles in complex urban road environments.

[0117] As an optional embodiment, the method further includes: acquiring a vehicle driving dataset; extracting current curvature, initial curvature, current acceleration, and initial acceleration from the driving dataset; determining curvature change information based on the current curvature and initial curvature, and determining acceleration change information based on the current acceleration and initial acceleration.

[0118] In this embodiment, the vehicle's driving dataset may include first driving data and second driving data. The first driving data mainly includes the vehicle's current actual physical state, which may include position coordinates, heading angle, speed, curvature, and acceleration. The second driving data focuses more on changes in the vehicle's future driving state, used to predict and plan the vehicle's dynamic behavior, and may include curvature change information (e.g., rate of curvature change) and acceleration change information (rate of acceleration change).

[0119] Optionally, the first driving data is monitored and collected in real time by the vehicle's sensor system, forming a comprehensive description of the current driving state. The second driving data aims to predict how the vehicle will respond to different control commands in the future, such as acceleration, deceleration, or steering. Integrating the first and second driving data together forms a complete driving dataset, that is, a series of discrete trajectory points that change over time. The time step is ,in, For state variables, x k and y k It can be used to represent position coordinates, θ k It can be used to represent heading angle, v k It can be used to represent speed, k k It can be used to represent curvature. a k It can be used to represent acceleration; , can be used to represent control variables, It can be used to represent the rate of change of curvature. It can be used to represent the rate of change of acceleration.

[0120] The optional embodiments described above in this application achieve the following technical effects: the construction and combination of the driving dataset provides accurate input data for optimization models such as the ILQR algorithm, ensuring that the trajectory prediction model can make appropriate trajectory planning based on the vehicle's current and expected state. Constructing and combining the driving dataset is a key step in the intelligent vehicle trajectory planning process, integrating the vehicle's real-time state and predictions of future state changes, providing a solid foundation for achieving safe, efficient, and comfortable autonomous driving. Through this process, the vehicle can better understand itself and its surrounding environment, making more intelligent driving decisions.

[0121] As an optional embodiment, the method further includes: constructing a trajectory prediction model based on the vehicle's kinematic model, wherein the trajectory prediction model is used to predict the trajectory of driving information to obtain a trajectory prediction result; and constructing a trajectory optimization model based on the ILQR algorithm, wherein the trajectory optimization model is used to optimize the predicted trajectory result using different penalty information to obtain a trajectory optimization result.

[0122] In this embodiment, multiple first target driving data sets and multiple second target driving data sets can be passed as input to the trajectory prediction model, i.e., the ILQR algorithm. The first target driving data sets contain the target driving state of the vehicle at future moments; the second target driving data sets describe how the target driving state changes over time. Based on the input target driving data, the ILQR algorithm can first generate an initial driving trajectory, i.e., the trajectory prediction result. This initial driving trajectory is obtained through iterative calculation using the vehicle kinematics model based on the current driving state and the expected control input sequence.

[0123] Optionally, the kinematic model includes higher-order control variables such as the rate of change of curvature and the rate of change of acceleration, resulting in greater comfort and better trajectory continuity. The vehicle's kinematic model can be determined using the following formula:

[0124] (13)

[0125] (14)

[0126] (15)

[0127] (16)

[0128] (17)

[0129] (18)

[0130] Among them, the Gaussler-Gandhi integral is used instead of the Euler integral to ensure the integration accuracy.

[0131] A discretized continuous model is established, and the system state is recursively updated through control inputs to generate the target driving trajectory, i.e., the trajectory optimization result:

[0132] (19)

[0133] (20)

[0134] (twenty one)

[0135] (twenty two)

[0136] (twenty three)

[0137] (twenty four)

[0138] (25)

[0139] Where N can be used to represent the order of Gauss-Legend integral, which determines the approximate accuracy. It can be used to represent the precision adjustment factor and corresponding weight of the control step size.

[0140] (26)

[0141] (27)

[0142] (28)

[0143] in, Can be used to represent Deformation parameters. Can be used to represent Deformation parameters.

[0144] Optionally, the deviation between the initial driving trajectory and the target driving state can be compared to evaluate whether the initial trajectory meets the pre-set performance indicators and constraints. If it is found that the initial driving trajectory fails to fully meet certain requirements (such as insufficient obstacle avoidance or insufficient trajectory smoothness), the optimization objective needs to be adjusted. For example, the weights of certain constraints can be increased in the cost function, or the penalty term can be adjusted to encourage the algorithm to pay more attention to the optimization of specific aspects.

[0145] Optionally, leveraging the iterative nature of the ILQR algorithm, the control input sequence can be fine-tuned to progressively optimize the initial driving trajectory. For example, differentiating the cost function determines the update direction of the control input sequence until the initial driving trajectory reaches its optimal state across all evaluation metrics. Throughout the optimization process, it is crucial to ensure that all constraints, including vehicle kinematic continuity constraints, boundary constraints, and obstacle avoidance constraints, are satisfied. This can be achieved by embedding appropriate penalty terms in the cost function, ensuring that any control input sequence that violates the constraints is automatically eliminated by the algorithm. After multiple rounds of iterative optimization, the ILQR algorithm outputs a final target driving trajectory that, while satisfying all constraints, achieves accurate tracking of the target driving state and reaches its optimal performance metrics.

[0146] The above-mentioned optional embodiments of this application can achieve the following technical effects: by using the ILQR algorithm to predict and subsequently adjust the input driving information to generate trajectory optimization results (e.g., target driving trajectory), it can not only ensure driving safety and comfort, but also greatly improve driving efficiency and the adaptability of intelligent vehicles to dynamic environments, providing strong technical support for vehicle trajectory planning in intelligent transportation systems, and helping to promote the maturity and widespread application of autonomous driving technology.

[0147] In this embodiment, by collecting real-time information on vehicle curvature and acceleration changes, the current dynamic state of the vehicle can be more accurately grasped, such as the vehicle's steering trend and acceleration changes. The driving information is input into a trajectory prediction model for trajectory prediction, yielding a predicted trajectory result—that is, a predicted trajectory for the vehicle at a future time. This predicted trajectory result is then input into a trajectory optimization model, and different penalty information within the model is used to optimize the predicted trajectory, resulting in an optimized trajectory result. The trajectory optimization model based on the ILQR algorithm can further optimize the smoothness of the path based on the predicted trajectory result. By introducing different types of constraints (such as kinematic continuity constraints, kinematic boundary constraints, and initial boundary constraints) as penalty terms, abrupt changes in the path, such as unnecessary sharp turns or accelerations, can be avoided, thereby generating a smoother, more comfortable, and physically feasible driving trajectory. This achieves the goal of cost-effective intelligent trajectory optimization, thus solving the technical problem of low trajectory generation accuracy and improving the accuracy of vehicle trajectory generation.

[0148] Figure 2 This is a flowchart illustrating an intelligent vehicle trajectory optimization method based on an iterative linear quadratic regulator algorithm, as provided in an embodiment of this application. Figure 2 As shown, the method includes the following steps.

[0149] Step S201: Define the trajectory optimization problem and construct a high-order vehicle kinematics model.

[0150] In this embodiment, a vehicle trajectory optimization problem is constructed based on the vehicle's kinematic model. The goal is to minimize the deviation between the vehicle state and the reference trajectory, while avoiding obstacles and ensuring the smoothness of acceleration, velocity, and turning angle.

[0151] Optionally, a trajectory optimization mathematical model is constructed. The trajectory is mathematically represented as a series of discrete trajectory points that change over time. The time step is ,in, , can be used to represent state variables, x k and y k It can be used to represent position coordinates, θ k It can be used to represent heading angle, v k It can be used to represent speed, k k It can be used to represent curvature. a k It can be used to represent acceleration; , can be used to represent control variables, It can be used to represent the rate of change of curvature. It can be used to represent the rate of change of acceleration. Compared to the traditional approach that uses front wheel steering angle and acceleration as direct control variables, the new trajectory optimization mathematical model can directly constrain the rate of change of acceleration. Physical variables such as the rate of change of curvature are used to avoid unreasonable rapid acceleration / deceleration or sharp turns in the trajectory. The trajectory generation method describes the changes in the vehicle's state by integrating over time.

[0152] Optionally, the kinematic model includes higher-order control variables such as the rate of change of curvature and the rate of change of acceleration, which provides higher comfort and better trajectory continuity. The vehicle kinematic model can be determined by the above formulas (13)-(18). Then, a discretized continuous model is established by the above formulas (19)-(28), and the system state is recursively updated by the control input to generate the target driving trajectory, which will not be elaborated here.

[0153] Step S202: Construct the cost function.

[0154] In this embodiment, Deviation terms from reference path and reference speed curve The cost function, including the bias term, smoothing term, and tail point objective term, can be expressed by the following formula:

[0155] (29)

[0156] in, Can be used to represent Projection point to the reference path, Can be used to represent At the projection point of the reference velocity curve, It can be used to represent relevant weights. It calculates the deviation between the vehicle and the reference trajectory, including differences in position, direction, and speed. The trajectory is optimized by penalizing these deviations.

[0157] Alternatively, the smoothing term can be determined using the following formula:

[0158] (30)

[0159] (31)

[0160] in, , This represents cost items related to the smoothness of vehicle acceleration and steering angle. This can be used to represent relevant weights. A lateral acceleration term should ideally be added to the smoothing term. However, since lateral acceleration is coupled with lateral and longitudinal factors, it may cause a decrease in speed during lane change scenarios, which is not in line with driving habits. Therefore, lateral acceleration is added as a constraint condition to the model.

[0161] Alternatively, the tail point constraint term can be determined by the following formula to ensure that the vehicle matches the target position when it reaches the destination:

[0162] (32)

[0163] in, It can be used to represent relevant weights. Tail point states are generally included as soft constraints in the cost function, used in parking scenarios. It can be used to represent the position and orientation of parking points. It can be used to represent speed and acceleration at a stopping point.

[0164] Alternatively, the total cost function is a weighted average of all cost items, which can be expressed by the following formula:

[0165] (33)

[0166] By minimizing the total cost function, we can obtain a trajectory that conforms to the reference trajectory, is smooth, and reaches the target state; that is, the target driving trajectory.

[0167] Step S203: Set constraints.

[0168] In this embodiment, the constraints include vehicle kinematic continuity constraints, starting point boundary constraints, and obstacle avoidance constraints. The vehicle kinematic continuity constraints can be determined by the above formula (1), which will not be repeated here.

[0169] Optionally, the starting point boundary constraints can be determined using the following formula:

[0170] (34)

[0171] Kinematic boundary constraints can be determined using the following formula:

[0172] (35)

[0173] in, It can be used to represent the difference between speed and the maximum speed. It can be used to represent the inversion of speed.

[0174] Alternatively, the acceleration term can be expressed by the following formula:

[0175] (36)

[0176] in, It can be used to represent the difference between acceleration and its maximum value. It can be used to represent the sum between the inverse of acceleration and the minimum value of acceleration.

[0177] Alternatively, the rate of change of acceleration can be expressed by the following formula:

[0178] (37)

[0179] in, It can be used to represent the difference between the rate of change of acceleration and the maximum rate of change of acceleration. It can be used to represent the sum between the inverse of the rate of change of acceleration and the minimum rate of change of acceleration.

[0180] Alternatively, the curvature term can be expressed by the following formula:

[0181] (38)

[0182] in, It can be used to represent the difference between curvature and the maximum curvature. It can be used to represent the sum between the inverse of curvature and the minimum curvature.

[0183] Alternatively, the rate of change of curvature can be expressed by the following formula:

[0184] (39)

[0185] in, It can be used to represent the difference between the rate of change of curvature and the maximum rate of change of curvature. It can be used to represent the sum between the inverse of the rate of change of curvature and the minimum rate of change of curvature.

[0186] Alternatively, the lateral acceleration can be expressed by the following formula:

[0187] (40)

[0188] in, It can be used to represent the difference between the product of the square of the lateral acceleration and the curvature, and the maximum value of the lateral acceleration. It can be used to represent the sum between the inverse of the product of the square of the lateral acceleration and the curvature, and the minimum value of the lateral acceleration.

[0189] Optionally, the five terms—acceleration, rate of change of acceleration, curvature, rate of change of curvature, and lateral acceleration—are ensured not to exceed the vehicle's physical limitations. Since lateral acceleration is coupled with both longitudinal and lateral factors, it may cause a decrease in speed during lane changes, which is inconsistent with driving habits. Therefore, lateral acceleration is added as a constraint to the model rather than to the objective function.

[0190] Step S204: Transform optimization constraints using obstacle functions.

[0191] In this embodiment, obstacle avoidance constraints can be established by creating obstacle avoidance conditions for both static and dynamic obstacles. The vehicle's position is... The field value of the potential energy field established by the vehicle at a point on the obstacle (discrete the vehicle rectangle into grid points). and The field value is relevant, and its value at the vehicle's boundary points is 0. The distance field value is calculated as follows: the global coordinates of the obstacle rigid body are transformed into a vehicle coordinate system with the rear axle center as the origin and the vehicle's front direction as the positive direction; it is then determined whether the obstacle rigid body is within the vehicle's rigid body range. If the minimum distance between the vehicle and the obstacle or road boundary is required... Then it needs to satisfy: The obstacle avoidance constraint based on the vehicle's potential energy field can be expressed as: in, It can be used to represent the extended width of a vehicle. It can be used to represent the pose of the vehicle at the k-th point. The distance between the current object and the i-th obstacle is calculated by the obstacle avoidance module.

[0192] In summary, the established trajectory optimization problem can be expressed as:

[0193] (41)

[0194] (42)

[0195] (43)

[0196] (44)

[0197] in, It can be used to represent the objective function. It can be used to represent kinematic continuity constraints. It can be used to represent kinematic boundary constraints and obstacle avoidance constraints. It can be used to represent the starting point boundary constraint.

[0198] Step S205: Use the ILQR algorithm to optimize the trajectory.

[0199] In this embodiment, based on the concept of dynamic programming, we return to the last step to obtain a subproblem. We solve the optimal solution to the subproblem; according to the state transition equation, we obtain a new subproblem that includes the subproblems that have already been solved; we jump to solving the optimal solution to the subproblem, and continue the recursion until we reach the end of the first step.

[0200] Optionally, the established trajectory optimization model is a nonlinear optimization problem with constraints. To solve it using ILQR, the constraints need to be processed. The obstacle function method can be used to convert the constraints into a penalty term of the cost function. When the constraints are strictly satisfied, the penalty term is equal to zero; when the constraints are not satisfied, the penalty term is greater than zero. Therefore, by solving for the minimum value of the cost function and making the penalty term approach zero, the optimal quantity that satisfies the constraints can be obtained.

[0201] Optionally, the obstacle function and the constraint terms using the penalty function can be described by the above formulas (4)-(12), which will not be repeated here.

[0202] in, This represents the cost of the final node.

[0203] For the first The cost of each node. According to the ILQR algorithm's solution process, it is necessary to calculate... right partial derivatives and right The first and second partial derivatives, i.e., the objective function. After several iterations, the ILQR algorithm obtains an optimal control input sequence, thereby generating the target driving trajectory. This target driving trajectory not only smoothly and accurately tracks the reference trajectory, but also avoids obstacles and satisfies physical constraints such as speed, acceleration, and turning angle.

[0204] Optionally, by inputting the vehicle's current position coordinates, current heading angle, current speed, current curvature, and current acceleration into the J model constructed in this scheme, outputting the model solution from the J model, and then inputting the above results into the ILQR algorithm for trajectory generation, a more optimized trajectory can be obtained.

[0205] In this embodiment, by collecting real-time information on vehicle curvature and acceleration changes, the current dynamic state of the vehicle can be more accurately grasped, such as the vehicle's steering trend and acceleration changes. The driving information is input into a trajectory prediction model for trajectory prediction, yielding a predicted trajectory result—that is, a predicted trajectory for the vehicle at a future time. This predicted trajectory result is then input into a trajectory optimization model, and different penalty information within the model is used to optimize the predicted trajectory, resulting in an optimized trajectory result. The trajectory optimization model based on the ILQR algorithm can further optimize the smoothness of the path based on the predicted trajectory result. By introducing different types of constraints (such as kinematic continuity constraints, kinematic boundary constraints, and initial boundary constraints) as penalty terms, abrupt changes in the path, such as unnecessary sharp turns or accelerations, can be avoided, thereby generating a smoother, more comfortable, and physically feasible driving trajectory. This achieves the goal of cost-effective intelligent trajectory optimization, thus solving the technical problem of low trajectory generation accuracy and improving the accuracy of vehicle trajectory generation.

[0206] This application also provides a vehicle trajectory generation device 30, please refer to... Figure 3 , Figure 3 This is a structural diagram of a vehicle trajectory generation device according to an embodiment of this application, as shown below. Figure 3 As shown, the trajectory generation device 30 for the vehicle includes: an acquisition unit 302, a prediction unit 304, and an optimization unit 306.

[0207] The acquisition unit 302 is used to acquire the vehicle's driving information, which includes curvature change information and acceleration change information. The curvature change information is used to indicate the change between the vehicle's current curvature and the initial curvature, and the acceleration information is used to indicate the change between the vehicle's current acceleration and the initial acceleration.

[0208] The prediction unit 304 is used to input driving information into the trajectory prediction model to perform trajectory prediction and obtain trajectory prediction results. The trajectory prediction model is constructed based on the vehicle's kinematic model, and the trajectory prediction results are used to represent the predicted trajectory of the vehicle at future times.

[0209] The optimization unit 306 is used to input the predicted trajectory result into the trajectory optimization model, and to optimize the predicted trajectory result using different penalty information in the trajectory optimization model to obtain the trajectory optimization result. The trajectory optimization model is constructed based on the ILQR algorithm. Different penalty information is used to represent penalty terms for different types of constraints on the vehicle. The different types of constraints include: kinematic continuity constraints, kinematic boundary constraints, and initial boundary constraints. The smoothness of the trajectory corresponding to the trajectory optimization result is higher than that of the trajectory corresponding to the trajectory prediction result.

[0210] Optionally, the predicted trajectory result is input into the trajectory optimization model, and the predicted trajectory result is optimized using different penalty information in the trajectory optimization model to obtain the trajectory optimization result. The optimization unit 306 includes: a first acquisition subunit, used to acquire constraint information corresponding to different types of constraint conditions in the trajectory optimization model to obtain different constraint information; a first transformation subunit, used to transform the different constraint information based on the obstacle function to obtain different penalty information; and an input subunit, used to input the predicted trajectory result into the trajectory optimization model, and to adjust the predicted trajectory result using different penalty information to obtain the trajectory optimization result.

[0211] Optionally, the first transformation subunit includes: a construction subunit for constructing the obstacle function into a penalty function; and a second transformation subunit for using the penalty function to transform different constraint information to obtain different penalty information.

[0212] Optionally, constructing sub-units includes: dividing sub-units to divide the obstacle function into intervals according to kinematic continuity constraints, kinematic boundary constraints, and initial boundary constraints, thereby obtaining a penalty function.

[0213] Optionally, the different constraint information includes: first constraint information corresponding to kinematic continuity constraints, second constraint information corresponding to kinematic boundary constraints, and third constraint information corresponding to initial boundary constraints. The second transformation subunit includes: an import subunit, used to import the first constraint information into a penalty function to obtain first penalty information, import the second constraint information into a penalty function to obtain second penalty information, and import the third constraint information into a penalty function to obtain third penalty information. The first penalty information represents the penalty term for kinematic continuity constraints, the second penalty information represents the penalty term for kinematic boundary constraints, and the third penalty information represents the penalty term for initial boundary constraints.

[0214] Optionally, the input subunit includes: a calculation subunit, used to input the predicted trajectory result into the trajectory optimization model, calculate the trajectory deviation between the predicted trajectory result and the reference trajectory result, and obtain trajectory deviation information; a first determination subunit, used to determine the weights of different penalty information respectively, and obtain multiple weights, including: determining the first weight of the first penalty information, the second weight of the second penalty information, and the third weight of the third penalty information; an adjustment subunit, used to adjust the first penalty information using the first weight, the second penalty information using the second weight, and the third penalty information using the third weight; and a penalty subunit, used to use the adjusted first penalty information, the adjusted second penalty information, and the adjusted third penalty information as target constraint information of the trajectory optimization model to penalize the trajectory deviation information, so as to adjust the predicted trajectory result and obtain the trajectory optimization result.

[0215] Optionally, the vehicle trajectory generation device 30 further includes: a second acquisition subunit for acquiring a vehicle driving dataset; an extraction subunit for extracting the current curvature, initial curvature, current acceleration, and initial acceleration from the driving dataset; and a second determination subunit for determining curvature change information based on the current curvature and initial curvature, and determining acceleration change information based on the current acceleration and initial acceleration.

[0216] Optionally, the trajectory generation device 30 of the vehicle further includes: a first construction subunit for constructing a trajectory prediction model based on the vehicle's kinematic model, wherein the trajectory prediction model is used to predict the trajectory of driving information and obtain a trajectory prediction result; and a second construction subunit for constructing a trajectory optimization model based on the ILQR algorithm, wherein the trajectory optimization model is used to optimize the predicted trajectory result using different penalty information and obtain a trajectory optimization result.

[0217] In this embodiment, the vehicle's driving information is acquired by the acquisition unit 302. This driving information includes curvature change information and acceleration change information. The curvature change information represents the change between the vehicle's current curvature and its initial curvature, and the acceleration information represents the change between the vehicle's current acceleration and its initial acceleration. The driving information is input into a trajectory prediction model by the prediction unit 304 for trajectory prediction, resulting in a trajectory prediction result. The trajectory prediction model is constructed based on the vehicle's kinematic model, and the trajectory prediction result represents the predicted trajectory of the vehicle at a future time. The predicted trajectory result is then input into the optimization unit 306. The trajectory optimization model is used to optimize the predicted trajectory by utilizing different penalty information within the model. The trajectory optimization model is constructed based on the ILQR algorithm. Different penalty information represents penalty terms for different types of constraints on the vehicle. These different types of constraints include kinematic continuity constraints, kinematic boundary constraints, and initial boundary constraints. The smoothness of the trajectory corresponding to the optimized trajectory is higher than that of the trajectory corresponding to the predicted trajectory, thus solving the technical problem of low trajectory generation accuracy and achieving the technical effect of improving the trajectory generation accuracy of the vehicle.

[0218] This application also provides an electronic device 40, please refer to... Figure 4 It includes a processor 410 and a memory 420, wherein the memory 410 is used to store computer programs; the processor 420 is used to execute the programs stored in the memory 410 to implement the vehicle trajectory generation method described in any embodiment of this application.

[0219] This application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the vehicle trajectory generation method described in any embodiment of this application.

[0220] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application, such as the data used for testing, are all information and data authorized by the user or fully authorized by all parties. Furthermore, the collection, use and processing of the relevant data must comply with the relevant laws, regulations and standards of the relevant countries and regions, and corresponding operation entry points are provided for users to choose to authorize or refuse.

[0221] In this application, "multiple" refers to two or more.

[0222] In this application, unless otherwise expressly defined, the terms "installation," "connection," and "linking" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; and they can refer to the internal connection between two components. Those skilled in the art can understand the specific meaning of the above terms in this application based on the specific circumstances.

[0223] The terms “first,” “second,” “third,” “fourth,” etc., in this application (if present) are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence.

[0224] In this application, the term "and / or" is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, or B existing alone. Additionally, in this application, the character " / " generally indicates that the preceding and following related objects have an "or" relationship.

[0225] Unless otherwise specified, all steps in this application may be performed sequentially or randomly. For example, the method includes steps S102 and S104, indicating that the method may include steps S102 and S104 performed sequentially, or it may include steps S104 and S102 performed sequentially. For example, the method may also include step S106, indicating that step S106 may be added to the method in any order. For example, the method may include steps S102, S104, and S106, or it may include steps S102, S106, and S104, or it may include steps S106, S102, and S104, etc.

[0226] The above description is merely a preferred embodiment of this application and is not intended to limit this application. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this application should be included within the protection scope of this application.

Claims

1. A method for generating the trajectory of a vehicle, characterized in that, include: Acquire vehicle driving information, wherein the driving information includes curvature change information and acceleration change information, the curvature change information is used to indicate the change between the current curvature and the initial curvature of the vehicle, and the acceleration information is used to indicate the change between the current acceleration and the initial acceleration of the vehicle; The driving information is input into the trajectory prediction model to perform trajectory prediction, and the trajectory prediction result is obtained. The trajectory prediction model is constructed based on the kinematic model of the vehicle, and the trajectory prediction result is used to represent the predicted trajectory of the vehicle at a future time. The predicted trajectory result is input into the trajectory optimization model, and the predicted trajectory result is optimized using different penalty information in the trajectory optimization model to obtain the trajectory optimization result. The trajectory optimization model is constructed based on the ILQR algorithm. The different penalty information is used to represent penalty terms for different types of constraints on the vehicle. The different types of constraints include: kinematic continuity constraints, kinematic boundary constraints, and initial boundary constraints. The smoothness of the trajectory corresponding to the trajectory optimization result is higher than that of the trajectory corresponding to the trajectory prediction result.

2. The method according to claim 1, characterized in that, The predicted trajectory result is input into the trajectory optimization model, and different penalty information in the trajectory optimization model is used to optimize the predicted trajectory result to obtain the trajectory optimization result, including: In the trajectory optimization model, the constraint information corresponding to the different types of constraint conditions is obtained to obtain different constraint information; Based on the obstacle function, the different constraint information is transformed to obtain the different penalty information; The predicted trajectory result is input into the trajectory optimization model, and the different penalty information is used to adjust the predicted trajectory result to obtain the trajectory optimization result.

3. The method according to claim 2, characterized in that, Based on the obstacle function, the different constraint information is transformed to obtain the different penalty information, including: The obstacle function is then constructed as a penalty function; The different constraint information is transformed using the penalty function to obtain the different penalty information.

4. The method according to claim 3, characterized in that, The barrier function is constructed as a penalty function, including: The obstacle function is divided into intervals according to the kinematic continuity constraint, the kinematic boundary constraint, and the initial boundary constraint to obtain the penalty function.

5. The method according to claim 2, characterized in that, The different constraint information includes: first constraint information corresponding to the kinematic continuity constraint condition, second constraint information corresponding to the kinematic boundary constraint condition, and third constraint information corresponding to the initial boundary constraint condition. The different constraint information is obtained by transforming the different constraint information using the penalty function, including: The first constraint information is imported into the penalty function to obtain the first penalty information; The second constraint information is imported into the penalty function to obtain the second penalty information; and... The third constraint information is imported into the penalty function to obtain the third penalty information, wherein the first penalty information is used to represent the penalty term for the kinematic continuity constraint, the second penalty information is used to represent the penalty term for the kinematic boundary constraint, and the third penalty information is used to represent the penalty term for the initial boundary constraint.

6. The method according to claim 5, characterized in that, The predicted trajectory result is input into the trajectory optimization model, and the predicted trajectory result is adjusted using the different penalty information to obtain the trajectory optimization result, including: The predicted trajectory result is input into the trajectory optimization model, and the trajectory deviation between the predicted trajectory result and the reference trajectory result is calculated to obtain the trajectory deviation information. The weights of the different penalty information are determined to obtain multiple weights, including: determining the first weight of the first penalty information, the second weight of the second penalty information, and the third weight of the third penalty information; The first penalty information is adjusted using the first weight, the second penalty information is adjusted using the second weight, and the third penalty information is adjusted using the third weight. The adjusted first penalty information, the adjusted second penalty information, and the adjusted third penalty information are used as the target constraint information of the trajectory optimization model to penalize the trajectory deviation information, thereby adjusting the predicted trajectory result and obtaining the trajectory optimization result.

7. The method according to claim 1, characterized in that, The method further includes: Obtain the vehicle's driving data set; Extract the current curvature, the initial curvature, the current acceleration, and the initial acceleration from the driving dataset; Based on the current curvature and the initial curvature, the curvature change information is determined, and based on the current acceleration and the initial acceleration, the acceleration change information is determined.

8. The method according to any one of claims 1 to 7, characterized in that, The method further includes: Based on the vehicle's kinematic model, the trajectory prediction model is constructed, wherein the trajectory prediction model is used to predict the trajectory of driving information to obtain the trajectory prediction result; Based on the ILQR algorithm, a trajectory optimization model is constructed, wherein the trajectory optimization model is used to optimize the predicted trajectory result using the different penalty information to obtain the trajectory optimization result.

9. A vehicle trajectory generation device, characterized in that, include: An acquisition unit is used to acquire vehicle driving information, wherein the driving information includes curvature change information and acceleration change information, the curvature change information is used to indicate the change between the current curvature and the initial curvature of the vehicle, and the acceleration information is used to indicate the change between the current acceleration and the initial acceleration of the vehicle. The prediction unit is used to input the driving information into the trajectory prediction model to perform trajectory prediction and obtain the trajectory prediction result. The trajectory prediction model is constructed based on the kinematic model of the vehicle, and the trajectory prediction result is used to represent the predicted trajectory of the vehicle at a future time. An optimization unit is used to input the predicted trajectory result into a trajectory optimization model, and to optimize the predicted trajectory result using different penalty information in the trajectory optimization model to obtain a trajectory optimization result. The trajectory optimization model is constructed based on the ILQR algorithm. The different penalty information is used to represent penalty terms for different types of constraints on the vehicle. The different types of constraints include: kinematic continuity constraints, kinematic boundary constraints, and initial boundary constraints. The smoothness of the trajectory corresponding to the trajectory optimization result is higher than the smoothness of the trajectory corresponding to the trajectory prediction result.

10. A processor, characterized in that, The processor is used to run a program, wherein the program, when run by the processor, executes the trajectory generation method for the vehicle according to any one of claims 1 to 8.