A Trajectory Planning Method and Device for an Autonomous Driving Vehicle
By generating and screening spiral curve driving trajectories in autonomous driving vehicles, safe avoidance is achieved when encountering obstacles, solving the problem of the inability to avoid collisions and poor body feeling of sudden brakes in the EPB system, and improving the safety of the vehicle and the comfort of the ride.
Patent Information
- Application Number
- CN202210900018.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-07-28
- Publication Date
- 2025-07-22
- Estimated Expiration
- 2042-07-28
AI Technical Summary
When an autonomous vehicle encounters a sudden obstacle, the longitudinal brake of the EPB system in the prior art cannot avoid collisions and lead to poor body feeling of sudden braking.
By obtaining vehicle parameters and environmental information, we judge whether the lateral avoidance conditions are met, several spiral curved driving trajectories are generated, and the target driving trajectory that can avoid collision is selected, and the vehicle is traveling according to this trajectory to bypass obstacles.
It reduces the probability of vehicle collision, improves the comfort of passengers, solves the discomfort caused by sudden brakes, and improves the safety and smoothness of vehicle driving.
Smart Images

Figure CN115214647B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of autonomous driving, and particularly to a trajectory planning method and device for an autonomous driving vehicle. Background Art
[0002] In autonomous driving, vehicles will inevitably encounter dangerous situations where obstacles such as pedestrians and bicycles suddenly appear. In such cases, it is usually necessary for autonomous driving vehicles to accurately identify the positions of obstacles and avoid them in time to prevent collisions.
[0003] In the prior art, an autonomous driving vehicle is equipped with an EPB (Electrical Park Brake) system. After detecting an obstacle, it immediately brakes to avoid a collision. The EPB system avoids collisions by longitudinal braking. If the vehicle is running at a high speed and the braking distance is greater than the distance between the obstacle and the vehicle, there will be problems that braking cannot avoid the collision and there is a poor sense of sudden braking.
[0004] In view of this, there is an urgent need for a trajectory planning method for an autonomous driving vehicle to solve the problems that sudden braking by the EPB system cannot avoid collisions and brings a poor sense of sudden braking. Summary of the Invention
[0005] In view of the above situation, the present invention provides a trajectory planning method and device for an autonomous driving vehicle, which can reduce the probability of vehicle collisions and improve the comfort of passengers during braking.
[0006] In a first aspect, an embodiment of the present invention provides a trajectory planning method for an autonomous driving vehicle, including:
[0007] Obtain the parameter information and driving environment information of the vehicle;
[0008] According to the driving environment information and the parameter information, determine whether the vehicle meets a preset lateral avoidance condition. If it meets, generate a plurality of driving trajectories according to the parameter information and the parameter equation of a preset spiral curve;
[0009] Determine whether there are a plurality of available driving trajectories among the plurality of driving trajectories. If there are, select a target driving trajectory from the plurality of available driving trajectories, and control the vehicle to drive according to the target driving trajectory;
[0010] Wherein, when the vehicle drives according to the available driving trajectory, the distance between the vehicle and the obstacle is within a preset safe distance range.
[0011] In a second aspect, an embodiment of the present invention provides a trajectory planning device for an autonomous driving vehicle, including:
[0012] An acquisition module, configured to acquire parameter information and driving environment information of a vehicle;
[0013] A determination module, configured to determine whether the vehicle meets a preset lateral avoidance condition according to the driving environment information and the parameter information, and if so, generate a plurality of driving trajectories according to the parameter information and the parameter equation of a preset spiral curve;
[0014] A screening module, configured to determine whether there are a plurality of available driving trajectories among the plurality of driving trajectories, and if so, screen out a target driving trajectory from the plurality of available driving trajectories, and control the vehicle to drive according to the target driving trajectory;
[0015] Wherein, when the vehicle drives according to the available driving trajectory, the distance between the vehicle and the obstacle is within a preset safe distance range.
[0016] In a third aspect, an embodiment of the present invention provides an electronic device, including a memory, a processor, and a program stored on the memory and executable on the processor, and when the processor executes the program, the method described in any of the above embodiments is implemented.
[0017] In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, on which a program is stored, and when the program is executed by a processor, the method described in any of the above embodiments is implemented.
[0018] The beneficial effects of the technical solution provided by the present invention: When an obstacle invades the driving trajectory of the vehicle, if the vehicle meets the preset lateral avoidance condition, driving trajectories for lateral avoidance are generated according to the vehicle parameter information and the parameter equation of the preset spiral curve. In order to further reduce the collision risk, the embodiment of the present invention screens out available driving trajectories that can avoid collisions from the plurality of driving trajectories through the safe distance range, and determines the target driving trajectory therefrom. Especially when longitudinal braking cannot avoid a collision, the vehicle drives according to the target driving trajectory, can bypass the obstacle through lateral avoidance, improves the driving safety of the vehicle, and solves the problem of poor riding experience caused by emergency braking. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following will briefly introduce the drawings required for the description of the embodiments. These drawings form a part of the present invention, and the schematic embodiments of the present invention and their descriptions are used to explain the present invention, and do not constitute an improper limitation of the present invention. In the drawings:
[0020] Figure 1 is a flowchart of a trajectory planning method for an autonomous vehicle provided by an embodiment of the present invention;
[0021] Figure 2Schematic diagram of an autonomous vehicle provided by an embodiment of the present invention on a driving trajectory;
[0022] Figure 3 Schematic diagram of the curvature changing with the moving distance provided by an embodiment of the present invention;
[0023] Figure 4 Schematic diagram of the orientation changing with the moving distance provided by an embodiment of the present invention;
[0024] Figure 5 Schematic diagram of a vehicle driving trajectory provided by an embodiment of the present invention;
[0025] Figure 6 Schematic diagram of the curvature changing with the moving distance corresponding to different curvature thresholds provided by an embodiment of the present invention;
[0026] Figure 7 Schematic diagram of the orientation changing with the moving distance corresponding to different curvature thresholds provided by an embodiment of the present invention;
[0027] Figure 8 Schematic diagram of the driving trajectory corresponding to different curvature thresholds provided by an embodiment of the present invention;
[0028] Figure 9 Schematic diagram of vehicle-obstacle collision detection provided by an embodiment of the present invention;
[0029] Figure 10 Flowchart of a trajectory planning device for an autonomous vehicle provided by an embodiment of the present invention;
[0030] Figure 11 Schematic diagram of the structure of a computer system of a terminal device or a server suitable for implementing the embodiments of the present invention. Detailed implementation manners
[0031] In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings required for use in the description of the embodiments or the prior art. Obviously, the drawings in the following description are some embodiments of this specification. For those of ordinary skill in the art, without creative efforts, other drawings can also be obtained based on these drawings.
[0032] During the driving process of a vehicle, it is inevitable to encounter dangerous situations such as suddenly appearing pedestrians, bicycles and other obstacles. In such situations, it is usually necessary for an autonomous vehicle to accurately identify the position of the obstacle and avoid it in time to prevent collisions.
[0033] In the prior art, vehicles are equipped with an EPB system which, when detecting an obstacle, brakes with maximum force. However, the EPB system can only avoid collisions through longitudinal braking. If the vehicle speed is relatively high, longitudinal braking may not be able to avoid a collision. Additionally, sudden longitudinal braking can result in a poor riding experience for passengers.
[0034] In view of this, according to Figure 1 , an embodiment of the present invention provides a trajectory planning method for an autonomous vehicle, including:
[0035] Step 101, obtain the parameter information and driving environment information of the vehicle.
[0036] The parameter information of the vehicle includes any one or more of the current driving trajectory, longitudinal speed, position, orientation, dimension information, braking distance, and vehicle wheelbase of the vehicle.
[0037] The driving environment information is the environmental information around the vehicle, including any one or more of road information, traffic signal information, and obstacle information.
[0038] Step 102, determine whether the vehicle meets a preset lateral avoidance condition according to the driving environment information and parameter information. If the lateral avoidance condition is met, execute Step 103; otherwise, execute Step 106.
[0039] Step 103: Generate a number of driving trajectories according to the parameter information and the parameter equation of a preset spiral curve.
[0040] When an autonomous vehicle encounters an obstacle, it determines whether to perform lateral avoidance through the lateral avoidance condition. When the vehicle meets the lateral avoidance condition, a number of driving trajectories for lateral avoidance are generated.
[0041] Step 104, determine whether there are a number of available driving trajectories among the number of driving trajectories. If there are, execute Step 105; otherwise, execute Step 106.
[0042] When the vehicle travels along the available driving trajectory, the distance between the vehicle and the obstacle is within a preset safe distance range. When the distance between the vehicle and the obstacle results in no collision risk between the vehicle and the obstacle, the distance between the vehicle and the obstacle is within the safe distance range.
[0043] Step 105: Screen out a target driving trajectory from the number of available driving trajectories, and control the vehicle to travel according to the target driving trajectory.
[0044] Specifically, the target driving trajectory can be screened based on the moving distance of the driving trajectory and the maximum lateral distance of the driving trajectory. For example, select the available driving trajectory with the shortest moving distance as the target driving trajectory, or select the driving trajectory with the smallest maximum lateral distance as the target driving trajectory.
[0045] Step 106: Control the vehicle to brake.
[0046] When an obstacle intrudes into the driving trajectory of the vehicle, if the vehicle meets the preset lateral avoidance condition, a driving trajectory for lateral avoidance is generated according to the vehicle parameter information and the preset spiral curve parameter equation. To further reduce the collision risk, in the embodiment of the present invention, available driving trajectories that can avoid collisions are screened from several driving trajectories through the safety distance range, and the target driving trajectory is determined therefrom. Especially in the case where longitudinal braking cannot avoid collisions, when the vehicle travels according to the target driving trajectory, it can bypass the obstacle through lateral avoidance, improving the driving safety of the vehicle and solving the problem of poor riding experience caused by sudden braking.
[0047] In an embodiment of the present invention, the lateral avoidance condition includes: there is an intersection between the obstacle and the current driving trajectory, and the braking distance is greater than the distance between the vehicle and the obstacle.
[0048] Specifically, according to the position of the obstacle in the driving environment information and the current driving trajectory of the vehicle in the parameter information, it is judged whether there is an intersection between the obstacle and the current driving trajectory; according to the position of the obstacle and the position of the vehicle in the parameter information, the distance between the obstacle and the vehicle is calculated, and it is judged whether the braking distance is greater than the distance between the obstacle and the vehicle. If there is an intersection between the obstacle and the current driving trajectory of the vehicle and the braking distance is greater than the distance between the obstacle and the vehicle, the lateral avoidance condition is met.
[0049] In an embodiment of the present invention, the lateral avoidance condition may further include: any one or more of the lateral distance between the obstacle and the vehicle not exceeding a set threshold and the vehicle speed not being greater than a set threshold. For example, the lateral distance between the obstacle and the vehicle does not exceed 0.5 meters, and the vehicle speed is not greater than 10 m / s.
[0050] Through the lateral avoidance condition, it can be accurately judged whether the vehicle can laterally avoid the obstacle when encountering an obstacle during driving, triggering the generation of the lateral avoidance driving trajectory.
[0051] In an embodiment of the present invention, several driving trajectories are generated according to the parameter information and the preset parameter equation of the spiral curve, including:
[0052] For each of the driving trajectories:
[0053] According to the parameter information, determine the moving distance of the vehicle at any moment;
[0054] Determine the orientation of the vehicle according to the moving distance of the vehicle;
[0055] Generate the driving trajectory according to the parametric equation of the spiral curve, the moving distance and the orientation of the vehicle.
[0056] The parametric equation of the spiral curve satisfies equations (1) and (2):
[0057] x(s) = ∫cosθds (1)
[0058] y(s) = ∫sinθds (2)
[0059] Wherein, x is the abscissa in the Cartesian coordinate system, y is the ordinate in the Cartesian coordinate system, s is the moving distance of the vehicle, and θ is the orientation of the vehicle.
[0060] The parametric equation of the spiral curve is determined by the orientation and the moving distance of the vehicle, but its specific form is not limited to equations (1) and (2), and can also be equations (3) and (4):
[0061] x(s) = ∫rcosθds (3)
[0062] y(s) = ∫rsinθds (4)
[0063] Wherein, r is a constant.
[0064] The parametric equation of the spiral curve is obtained by deforming the parametric equation of the Euler spiral (ram's horn spiral). Among them, θ is calculated based on vehicle kinematics. Specifically, θ is calculated based on equation (7).
[0065] Calculate θ based on vehicle kinematics to obtain an improved Euler spiral, so that the curvature of each point on the curve changes continuously and smoothly along the length direction, and then obtain the driving trajectory. When the vehicle travels according to this driving trajectory, the controller of the vehicle can better execute, and the vehicle can travel smoothly.
[0066] The moving distance s of the vehicle is determined by the longitudinal speed of the vehicle, the time and the first rotation speed of the front wheels. The front wheel rotation angle can be determined by the first rotation speed and the time of the front wheels, and the moving distance of the vehicle can be determined by the front wheel rotation angle, the longitudinal speed and the time.
[0067] In an embodiment of the present invention, the preset value of the first rotation speed of the front wheels is equal to the maximum rotation speed of the front wheels. Using the maximum rotation speed of the front wheels for steering can open the lateral distance between the vehicle and the obstacle at the fastest speed and avoid the obstacle at the fastest speed.
[0068] In the embodiment of the present invention, the value of the first rotational speed may also be a value close to the maximum rotational speed, such as 0.8 times the maximum rotational speed, 0.9 times the maximum rotational speed, etc.
[0069] In an embodiment of the present invention, considering that the curvature changes with the moving distance s, therefore, the curvature and the moving distance satisfy Equation (5):
[0070] k = f(s) (5)
[0071] where k is the curvature.
[0072] The orientation θ changes with the moving distance s, and the relationship between θ, k, and s satisfies Equation (6):
[0073] θ = ∫kds = F(s) + C (6)
[0074] Reference Figure 2 , based on vehicle kinematics, Equation (7) can be obtained:
[0075]
[0076] where is the front wheel steering angle, and l is the wheelbase of the vehicle.
[0077] As Figure 2 shown, L is the vehicle length, v is the longitudinal speed of the vehicle, P r is the center of the rear axle of the vehicle, P f is the center of the front axle of the vehicle, P c is the center of the vehicle.
[0078] Differentiating Equation (5) can obtain Equation (8):
[0079]
[0080] where v is the longitudinal speed of the vehicle, which remains constant at a uniform speed.
[0081] Differentiating Equation (7) can obtain Equation (9):
[0082]
[0083] where w max is the maximum rotational speed of the front wheel, and its value is determined by the vehicle performance.
[0084] According to Equation (8) and Equation (9), the mapping relationship between k and s can be obtained, which satisfies Equation (10):
[0085]
[0086] According to Equation (7), Equation (11) can be obtained:
[0087]
[0088] According to Equation (10) and Equation (11), Equation (12) can be obtained as follows:
[0089]
[0090] According to Equation (12), the mapping relationship between k and s can be obtained, satisfying Equation (13),
[0091]
[0092] where c = arctan(lk0), k0 is the curvature of the driving trajectory when s = 0, that is, the curvature of the position of the vehicle on the driving trajectory at the moment when the obstacle is detected.
[0093] According to the relationship between k and θ in Equation (6), the orientation of the vehicle can be obtained, satisfying Equation (14):
[0094]
[0095] where θ0 is the orientation of the vehicle when s = 0, that is, the orientation of the vehicle at the moment when the obstacle is detected.
[0096] According to Equation (14), Equation (1) and Equation (2), several driving trajectories can be generated.
[0097] w in Equation (9) max can be replaced by the first rotational speed w of the front wheel, and the obtained θ is Equation (15):
[0098]
[0099] That is to say, w in Equation (9) max is only a preferred method, and other values of the first rotational speed can also be used for replacement. For example, 0.9w max .
[0100] In an embodiment of the present invention, the driving trajectory can be generated according to the moving distance, the orientation and the parametric equation of the above spiral curve. Based on the first rotational speed of the front wheel and the set threshold of the curvature, the vehicle is segmented and controlled, and three spiral curves are simulated. The three spiral curves can be spliced to obtain a driving trajectory.
[0101] The specific control method is as follows:
[0102] Determine the first moving distance of the vehicle at any moment when driving according to the first condition. The first condition includes: the longitudinal speed of the vehicle, the current position of the vehicle as the starting point, and the rotational speed of the front wheels is the first rotational speed. The value of the first rotational speed is preset, and the maximum rotational speed of the vehicle's front wheels can be selected. The maximum rotational speed of the vehicle's front wheels is equal to the maximum rotational speed of the vehicle's steering wheel, and this maximum rotational speed is determined by the vehicle's performance. The direction of the first rotational speed is to drive the vehicle away from the obstacle, that is, turn the steering wheel in the direction away from the obstacle.
[0103] Calculate the first spiral curve according to the first moving distance of the vehicle and the parametric equation of the spiral curve. The curvature of the starting point of the first spiral curve is obtained from the vehicle parameter information, and the curvature of the ending point of the first spiral curve is the set threshold.
[0104] Determine the second moving distance of the vehicle at any moment when driving according to the second condition. The second condition includes the longitudinal speed of the vehicle, the ending point of the first spiral curve as the starting point, and the rotational speed of the front wheels is the second rotational speed. The value of the second rotational speed is equal to the value of the first rotational speed, and the direction of the second rotational speed is opposite to the direction of the first rotational speed.
[0105] Calculate the second spiral curve according to the second moving distance of the vehicle and the parametric equation of the spiral curve. The curvature of the ending point of the second spiral curve is the set threshold.
[0106] Determine the third moving distance of the vehicle at any moment when driving according to the third condition. The third condition includes: the longitudinal speed of the vehicle, the ending point of the second spiral curve as the starting point, and the rotational speed of the front wheels is the first rotational speed.
[0107] Calculate the third spiral curve according to the third moving distance of the vehicle and the parametric equation of the spiral curve. The curvature of the ending point of the third spiral curve is 0, and the orientations of the vehicle at the starting point of the first spiral curve and the ending point of the third spiral curve are the same.
[0108] The first spiral curve, the second spiral curve, and the third spiral curve constitute the driving trajectory.
[0109] For example, the first condition is a longitudinal speed of 5 m / s, the current position coordinates of the vehicle are (0, 0), this position is the starting point of the first spiral curve, and the first rotational speed is the maximum rotational speed w max . At any moment t, the front wheel steering angle can be determined through the time t and w max . Then, the first moving distance s at time t can be calculated through the front wheel steering angle and the longitudinal speed. After obtaining the first moving distance s at time t, through Equation (14), the vehicle orientation θ at time t can be obtained. Substituting θ into Equation (1) and Equation (2), the horizontal and vertical coordinates (x, y) of the point on the first spiral curve at time t in the Cartesian coordinate system can be obtained. Similarly, the points on the second spiral curve and the third spiral curve at any moment can be obtained.
[0110] The driving trajectory consists of three spiral line segments, each of which satisfies the limitations of the first rotational speed and the set curvature threshold, conforms to the constraints of vehicle kinematics, the curvature of the curve is smooth in the first order along the length direction, and the vehicle executes according to this driving trajectory, and the execution process is smoother and the physical feeling is better.
[0111] In an embodiment of the present invention, the orientations of the vehicle at the starting point of the first spiral curve and the ending point of the third spiral curve may be the same or different. The orientation of the ending point of the third spiral curve may also be 0, or other orientations convenient for vehicle driving.
[0112] Figure 3 is a schematic diagram of the change of curvature k with the moving distance s. The positive and negative values of the data on this diagram represent the bending direction of the curve at this point. a1b1 is the curvature of the first spiral curve, the curvature k changes from 0 to the set threshold, the b1c1 segment is the curvature of the second spiral curve, and the curvature changes from the set threshold to the negative value of the set threshold. The c1d1 segment is the curvature of the third spiral curve, and the curvature of the ending point of the third spiral curve is 0. According to Equation (5), from the mapping relationship between k and s, the mapping relationship between the orientation θ and s can be obtained, as Figure 4 shown, is a schematic diagram of the change of the orientation θ with the moving distance s. The a2b2 segment is the orientation of the first spiral curve, the starting point orientation of the first spiral curve is 0, the b2c2 segment is the orientation of the second spiral curve, and the c2d2 segment is the orientation of the third spiral curve. According to the parametric equation of the spiral curve, from the mapping relationship between the orientation θ and s, a driving trajectory can be further obtained, as Figure 5 shown, is a schematic diagram of the driving trajectory in the Cartesian coordinate system. The a3b3 segment is the first spiral curve, the b3c3 segment is the second spiral curve, and the c3d3 segment is the third spiral curve. Figure 3 The a1b1 segment in Figure 4 corresponds to the a2b2 segment in Figure 5 and the a3b3 segment in Figure 3 The b1c1 segment in Figure 4 corresponds to the b2c2 segment in Figure 5 and the b3c3 segment in Figure 3 The c1d1 segment in Figure 4 corresponds to the c2d2 segment in Figure 5 and the c3d3 segment in
[0113] Each driving trajectory corresponds to a set threshold, and different driving trajectories have different set thresholds.
[0114] The set threshold is selected from the threshold interval, and the upper limit of the threshold interval satisfies Equation (16):
[0115] v 2 k max <<a lat,max≤ μg (16)
[0116] where k max is the upper limit of the threshold interval, a lat,max is used to represent the maximum preset lateral acceleration, μ is used to represent the friction between the tire and the ground, and g is the acceleration due to gravity.
[0117] The lower limit of the threshold interval is not less than 0.
[0118] The set thresholds of the curvature are sampled from the threshold interval, and several set thresholds can be obtained. Each set threshold corresponds to generating a driving trajectory, and thus n driving trajectories can be obtained.
[0119] In one embodiment of the present invention, the threshold interval is selected as [0.05, 0.2], and the curvature at the moment when the moving distance s = 0 is 0. As Figure 6 shown, sampling the set thresholds of the curvature on the threshold interval [0.05, 0.2], n mapping curves of the curvature and the moving distance can be obtained; from the mapping relationship between the curvature and the moving distance, the mapping relationship between the orientation and the moving distance is obtained. Therefore, n relationship curves between the orientation and the moving distance can be obtained. As Figure 7 shown, further, n driving trajectories can be obtained. As Figure 8 shown, it is a schematic diagram of the n driving trajectories in the Cartesian coordinate system.
[0120] In one embodiment of the present invention, determining whether there are several available driving trajectories among several driving trajectories includes:
[0121] For each driving trajectory:
[0122] Obtain the target box of the vehicle according to the position of the vehicle at any moment on the driving trajectory and the size information of the vehicle;
[0123] Obtain the target box of the obstacle according to the position and size information of the obstacle;
[0124] Calculate the distance between the target box of the vehicle and the target box of the obstacle;
[0125] If the distance between the target box of the vehicle and the target box of the obstacle is within the safe distance range, then the driving trajectory is the available driving trajectory.
[0126] If the distance between the vehicle target box and the obstacle target box is within the safe distance range, there is no collision risk between the vehicle and the obstacle; otherwise, there is a collision risk. For example, the safe distance range is greater than 100 m. The vehicle moves on the driving trajectory. If the distance between the vehicle and the obstacle at each position on the driving trajectory is greater than 100 m, there is no collision risk between the vehicle and the obstacle at each position on the driving trajectory, and this driving trajectory is an available driving trajectory; otherwise, it is an unavailable driving trajectory.
[0127] As Figure 9 shown, it is a schematic diagram of collision detection between a vehicle and an obstacle on a driving trajectory. In the figure, P r is the center of the rear axle of the vehicle, located on the driving trajectory curve, P f is the center of the front axle of the vehicle, P c is the center of the vehicle. The rectangle formed by the center of the front axle and the center of the rear axle of the vehicle is the target box of the vehicle, obs represents the target box of the obstacle, D is used to represent the distance between the vehicle target box and the obstacle target box. If this distance is within the preset safe distance range, this driving trajectory is an available driving trajectory.
[0128] Performing collision detection between the vehicle and the obstacle on the driving trajectory can effectively perform collision pruning on several generated driving trajectories. The available driving trajectories obtained by pruning ensure that when the vehicle travels according to this available driving trajectory, it can effectively avoid obstacles.
[0129] In an embodiment of the present invention, screening out the target driving trajectory from the several available driving trajectories includes:
[0130] Calculating the maximum lateral distance of each of the available driving trajectories;
[0131] Determining the target driving trajectory according to the maximum lateral distance of each of the available driving trajectories; the maximum lateral distance of the target driving trajectory is not greater than the maximum lateral distances of other driving trajectories.
[0132] Calculating the distance between the abscissa of each point on the available driving trajectory and the abscissa of the starting point of the vehicle. Among them, the point on the available driving trajectory with the largest distance from the abscissa of the starting point of the vehicle is the maximum lateral distance of the available driving trajectory.
[0133] Selecting the available driving trajectory with the smallest maximum lateral distance as the target driving trajectory according to the above method can avoid obstacles with the smallest lateral steering angle. The vehicle can avoid obstacles more quickly and has the smallest loss cost to the vehicle.
[0134] In an embodiment of the present invention, if there is no available driving trajectory among the several driving trajectories, the method further includes: controlling the vehicle to brake.
[0135] If the lateral avoidance condition is not met or there is no available driving trajectory, the vehicle should brake with maximum force to reduce the degree of collision.
[0136] According to Figure 10 , an embodiment of the present invention provides a trajectory planning device for an autonomous vehicle, including:
[0137] An acquisition module 1001, configured to acquire parameter information and driving environment information of the vehicle;
[0138] A determination module 1002, configured to determine whether the vehicle meets a preset lateral avoidance condition according to the driving environment information and parameter information. If it meets, several driving trajectories are generated according to the parameter information and the parameter equation of a preset spiral curve;
[0139] A screening module 1003, configured to determine whether there are several available driving trajectories among several driving trajectories. If there are, a target driving trajectory is screened out from the several available driving trajectories, and the vehicle is controlled to drive according to the target driving trajectory;
[0140] Wherein, when the vehicle drives along the available driving trajectory, the distance between the vehicle and the obstacle is within a preset safe distance range.
[0141] In an embodiment of the present invention, the parameter information includes: position, current driving trajectory, and braking distance;
[0142] The driving environment information includes: the position of the obstacle;
[0143] The lateral avoidance condition includes: there is an intersection between the obstacle and the current driving trajectory, and the braking distance is greater than the distance between the vehicle and the obstacle.
[0144] In an embodiment of the present invention, the parameter information includes: position, orientation, and longitudinal speed;
[0145] The determination module 1002 is configured to, for each of the driving trajectories:
[0146] Determine the first moving distance of the vehicle at any moment when driving according to the first condition; the first condition includes: the longitudinal speed, the starting point being the current position of the vehicle, and the rotational speed of the front wheels being the first rotational speed; the value of the first rotational speed is preset, and the first rotational speed causes the vehicle to drive in a direction away from the obstacle;
[0147] Calculate the first section of the spiral curve according to the first moving distance of the vehicle and the parameter equation of the spiral curve; the curvature of the end point of the first section of the spiral curve is a set threshold;
[0148] Determine the second moving distance of the vehicle at any moment when driving according to the second condition; the second condition includes: the longitudinal speed, starting from the end point of the first spiral curve, and the rotational speed of the front wheels being the second rotational speed; the value of the second rotational speed is equal to the value of the first rotational speed, and the direction of the second rotational speed is opposite to the direction of the first rotational speed;
[0149] Calculate the second spiral curve according to the second moving distance of the vehicle and the parametric equation of the spiral curve; the curvature of the end point of the second spiral curve is the set threshold;
[0150] Determine the third moving distance of the vehicle at any moment when driving according to the third condition; the third condition includes: the longitudinal speed, starting from the end point of the second spiral curve, and the rotational speed of the front wheels being the first rotational speed;
[0151] Calculate the third spiral curve according to the third moving distance of the vehicle and the parametric equation of the spiral curve; the curvature of the end point of the third spiral curve is 0, and the orientations of the vehicle at the starting point of the first spiral curve and the end point of the third spiral curve are the same;
[0152] The first spiral curve, the second spiral curve, and the third spiral curve constitute the driving trajectory.
[0153] In an embodiment of the present invention, the set threshold is selected from a threshold range, and the upper limit of the threshold range satisfies formula 1;
[0154] Formula 1:
[0155] v 2 k max <<a lat,max ≤μg
[0156] Wherein, v is the longitudinal speed of the vehicle, k max is the upper limit of the threshold range, the a lat,max is used to represent the maximum preset lateral acceleration, μ is used to represent the friction between the tire and the ground, and g is used to represent the acceleration due to gravity;
[0157] Different driving trajectories have different set thresholds.
[0158] In an embodiment of the present invention, the determination module 1002 is configured for each of the driving trajectories:
[0159] Determine the moving distance of the vehicle at any moment according to the parameter information;
[0160] Determine the orientation of the vehicle according to the moving distance of the vehicle;
[0161] Generate the driving trajectory according to the parametric equation of the spiral curve, the moving distance of the vehicle, and the orientation thereof.
[0162] The parametric equation of the spiral curve includes:
[0163] x(s) = ∫cosθds
[0164] y(s) = ∫sinθds
[0165] where x is the abscissa in the Cartesian coordinate system, y is the ordinate in the Cartesian coordinate system, s is the moving distance of the vehicle, and θ is the orientation of the vehicle.
[0166] In an embodiment of the present invention, the parameter information includes: longitudinal speed and time;
[0167] The determination module 1002 is configured to determine the moving distance of the vehicle according to the longitudinal speed, time, and a preset first rotation speed of the front wheels.
[0168] In an embodiment of the present invention, the parameter information further includes: vehicle wheelbase, the orientation of the vehicle when s = 0, and the curvature of the driving trajectory when s = 0;
[0169] In an embodiment of the present invention, the orientation of the vehicle is calculated according to Formula 2;
[0170] Formula 2:
[0171]
[0172] v is the longitudinal speed, w is the first rotation speed of the front wheels, l is the vehicle wheelbase, s is the moving distance, and θ0 is the orientation of the vehicle when s = 0;
[0173] where c = arctan(lk0), and k0 is the curvature of the driving trajectory when s = 0.
[0174] In an embodiment of the present invention, the parameter information further includes: dimension information;
[0175] The driving environment information includes: the position and dimension information of the obstacle;
[0176] The screening module 1003 is configured to, for each of the driving trajectories: obtain the target box of the vehicle according to the position of the vehicle at any moment on the driving trajectory and the size information of the vehicle; obtain the target box of the obstacle according to the position and size information of the obstacle; calculate the distance between the target box of the vehicle and the target box of the obstacle; if the distance between the target box of the vehicle and the target box of the obstacle is within the safe distance range, then the driving trajectory is the available driving trajectory.
[0177] In an embodiment of the present invention, the screening module 1003 is configured to calculate the maximum lateral distance of each of the available driving trajectories; determine the target driving trajectory according to the maximum lateral distance of each of the available driving trajectories; the maximum lateral distance of the target driving trajectory is not greater than the maximum lateral distances of other driving trajectories.
[0178] In an embodiment of the present invention, the screening module 1003 is configured to control the vehicle to brake if there is no available driving trajectory among the several driving trajectories.
[0179] An embodiment of the present invention provides an electronic device, including a memory, a processor, and a program stored on the memory and executable on the processor. When the processor executes the program, the method described in any of the above embodiments is implemented.
[0180] An embodiment of the present invention provides a computer-readable storage medium, on which a program is stored. When the program is executed by a processor, the method described in any of the above embodiments is implemented.
[0181] Reference is made below Figure 11 , which shows a schematic structural diagram of a computer system 1100 of a terminal device suitable for implementing the embodiments of the present invention. Figure 11 The terminal device shown is only an example and should not impose any limitations on the functions and usage scope of the embodiments of the present invention.
[0182] As Figure 11 shown, the computer system 1100 includes a central processing unit (CPU) 1101, which can perform various appropriate actions and processes according to the program stored in the read-only memory (ROM) 1102 or the program loaded from the storage section 1108 into the random access memory (RAM) 1103. In the RAM 1103, various programs and data required for the operation of the system 1100 are also stored. The CPU 1101, ROM 1102, and RAM 1103 are connected to each other through a bus 1105. The input / output (I / O) interface 1105 is also connected to the bus 1105.
[0183] The following components are connected to the I / O interface 1105: an input section 1106 including a keyboard, a mouse, etc.; an output section 1107 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc. and a speaker, etc.; a storage section 1108 including a hard disk, etc.; and a communication section 1109 including a network interface card such as a LAN card, a modem, etc. The communication section 1109 performs communication processing via a network such as the Internet. A drive 1110 is also connected to the I / O interface 1105 as required. A removable medium 1111 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc. is installed on the drive 1110 as required so that a computer program read therefrom is installed into the storage section 1108 as required.
[0184] Specifically, according to the embodiments disclosed by the present invention, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, the embodiments disclosed by the present invention include a computer program product which includes a computer program carried on a computer-readable medium, and the computer program includes program codes for performing the methods shown in the flowcharts. In such an embodiment, the computer program can be downloaded and installed from a network via the communication section 1109, and / or installed from the removable medium 1111. When the computer program is executed by a central processing unit (CPU) 1101, the above-described functions defined in the system of the present invention are executed.
[0185] It should be noted that the computer-readable medium shown in the present invention can be a computer-readable signal medium, a computer-readable storage medium, or any combination of the two. A computer-readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the above. More specific examples of a computer-readable storage medium can include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present invention, a computer-readable storage medium can be any tangible medium that contains or stores a program, and this program can be used by or in conjunction with an instruction execution system, apparatus, or device. In the present invention, a computer-readable signal medium can include a data signal propagated in a baseband or as part of a carrier wave, in which the computer-readable program code is carried. Such a propagated data signal can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. A computer-readable signal medium can also be any computer-readable medium other than a computer-readable storage medium, and this computer-readable medium can send, propagate, or transmit a program for use by or in conjunction with an instruction execution system, apparatus, or device. The program code contained on a computer-readable medium can be transmitted using any appropriate medium, including but not limited to: wireless, wire, optical cable, RF, etc., or any suitable combination of the above.
[0186] The flowcharts and block diagrams in the accompanying drawings illustrate the possible architectures, functions, and operations of systems, methods, and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagram can represent a module, a program segment, or a part of code, and the above-mentioned module, program segment, or part of code contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the blocks can occur in a different order than marked in the accompanying drawings. For example, two consecutive blocks shown can actually be executed substantially in parallel, and they can sometimes be executed in the reverse order, depending on the functions involved. It should also be noted that each block in the block diagram or flowchart, and the combination of blocks in the block diagram or flowchart, can be implemented by a dedicated hardware-based system for performing the specified functions or operations, or can be implemented by a combination of dedicated hardware and computer instructions.
[0187] The modules involved in the embodiments of the present invention can be implemented in software or in hardware. The described modules can also be provided in a processor. For example, it can be described as: a processor includes a sending module, an obtaining module, a determining module, and a first processing module. Among them, the names of these modules do not constitute a limitation to the module itself in some cases. For example, the sending module can also be described as "a module that sends a picture acquisition request to the connected server".
[0188] As another aspect, an embodiment of the present invention further provides a computer-readable storage medium, on which a program is stored, and when the program is executed by a processor, the method described in any of the above embodiments is implemented.
[0189] The above specific implementation manners do not constitute a limitation to the protection scope of the present invention. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can occur depending on design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principle of the present invention shall be included within the protection scope of the present invention.
Claims
1. A trajectory planning method for an autonomous vehicle, characterized in that, Including: Obtaining parameter information and driving environment information of the vehicle; The parameter information includes: the position, orientation, and longitudinal speed of the vehicle; According to the driving environment information and the parameter information, determining whether the vehicle meets a preset lateral avoidance condition. If it meets, generating a plurality of driving trajectories according to the parameter information and the parameter equation of a preset spiral curve; Determining whether there are a plurality of available driving trajectories among the plurality of driving trajectories. If there are, screening out a target driving trajectory from the plurality of available driving trajectories, and controlling the vehicle to drive according to the target driving trajectory; Wherein, when the vehicle drives according to the available driving trajectory, the distance between the vehicle and the obstacle is within a preset safe distance range; wherein, Generating a plurality of driving trajectories according to the parameter information and the parameter equation of a preset spiral curve, including: For each of the driving trajectories: Determining the first moving distance of the vehicle at any moment when driving according to the first condition; the first condition includes: the longitudinal speed, the starting point being the current position of the vehicle, and the rotational speed of the front wheels being a first rotational speed; the value of the first rotational speed is preset, and the first rotational speed causes the vehicle to drive away from the obstacle; Calculating a first segment of spiral curve according to the first moving distance of the vehicle and the parameter equation of the spiral curve; the curvature of the end point of the first segment of spiral curve is a set threshold; Determining the second moving distance of the vehicle at any moment when driving according to the second condition; the second condition includes: the longitudinal speed, the starting point being the end point of the first segment of spiral curve, and the rotational speed of the front wheels being a second rotational speed; the value of the second rotational speed is equal to the value of the first rotational speed, and the direction of the second rotational speed is opposite to the direction of the first rotational speed; Calculating a second segment of spiral curve according to the second moving distance of the vehicle and the parameter equation of the spiral curve; the curvature of the end point of the second segment of spiral curve is the set threshold; Determining the third moving distance of the vehicle at any moment when driving according to the third condition; the third condition includes: the longitudinal speed, the starting point being the end point of the second segment of spiral curve, and the rotational speed of the front wheels being the first rotational speed; Calculating a third segment of spiral curve according to the third moving distance of the vehicle and the parameter equation of the spiral curve; the curvature of the end point of the third segment of spiral curve is 0, and the orientation of the vehicle at the starting point of the first segment of spiral curve and the end point of the third segment of spiral curve is the same; The first segment of spiral curve, the second segment of spiral curve, and the third segment of spiral curve constitute the driving trajectory.
2. The method according to claim 1, wherein The parameter information includes: the current driving trajectory and the braking distance; The driving environment information includes: the position of the obstacle; The lateral avoidance condition includes: there is an intersection between the obstacle and the current driving trajectory, and the braking distance is greater than the distance between the vehicle and the obstacle.
3. The method according to claim 1, wherein The set threshold is selected from a threshold range, and the upper limit of the threshold range satisfies formula 1; Formula 1: v 2 k max <<a lt,max ≤ μg wherein, v is the longitudinal speed of the vehicle, and k max is the upper limit of the threshold range, and the a lat,max is used to represent the maximum value of the preset lateral acceleration, μ is used to represent the friction between the tire and the ground, and g is used to represent the acceleration due to gravity; Different driving trajectories have different set thresholds.
4. The method according to any one of claims 1-3, characterized in that According to the parameter information and the parametric equation of the preset spiral curve, a plurality of driving trajectories are generated, including: For each of the driving trajectories: According to the parameter information, determine the moving distance of the vehicle at any moment; According to the moving distance of the vehicle, determine the orientation of the vehicle; According to the parametric equation of the spiral curve, the moving distance and orientation of the vehicle, generate the driving trajectory; The parametric equation of the spiral curve includes: x(s) = ∫cosθds y(s) = ∫sinθds Where, x is the abscissa in the Cartesian coordinate system, y is the ordinate in the Cartesian coordinate system, s is the moving distance of the vehicle, and θ is the orientation of the vehicle.
5. The method according to claim 4, characterized in that The parameter information includes: longitudinal speed and time; According to the parameter information, determining the moving distance of the vehicle at any moment includes: According to the longitudinal speed, time and the preset first rotation speed of the front wheel, determine the moving distance of the vehicle.
6. The method according to claim 4, characterized in that The parameter information further includes: vehicle wheelbase, the orientation of the vehicle when s = 0, and the curvature of the driving trajectory when s = 0; According to the moving distance of the vehicle, determining the orientation of the vehicle includes: Calculate the orientation of the vehicle according to formula 2; Formula 2: v is the longitudinal speed, w is the first rotation speed of the front wheel, l is the vehicle wheelbase, s is the moving distance, and θ0 is the orientation of the vehicle when s = 0; Where, c = arctan(lk0), and k0 is the curvature of the driving trajectory when s = 0.
7. The method according to claim 1, characterized in that The parameter information further includes: dimension information; The driving environment information includes: the position and dimension information of the obstacle; Determining whether there are several available driving trajectories among the several driving trajectories includes: For each of the driving trajectories: According to the position of the vehicle at any moment on the driving trajectory and the dimension information of the vehicle, obtain the target frame of the vehicle; According to the position and dimension information of the obstacle, obtain the target frame of the obstacle; Calculate the distance between the target frame of the vehicle and the target frame of the obstacle; If the distance between the target frame of the vehicle and the target frame of the obstacle is within the safe distance range, the driving trajectory is the available driving trajectory.
8. The method according to claim 1, characterized in that Selecting a target driving trajectory from the several available driving trajectories includes: Calculate the maximum lateral distance of each available driving trajectory; According to the maximum lateral distance of each available driving trajectory, determine the target driving trajectory; the maximum lateral distance of the target driving trajectory is not greater than the maximum lateral distances of other driving trajectories.
9. The method according to claim 1, characterized in that If there are no available driving trajectories among the several driving trajectories, the method further includes: Control the vehicle to brake.
10. A trajectory planning device for an autonomous vehicle, characterized in that, Including: An acquisition module, configured to acquire parameter information and driving environment information of a vehicle; The parameter information includes: the position, orientation and longitudinal speed of the vehicle; A determination module, configured to determine whether the vehicle meets a preset lateral avoidance condition according to the driving environment information and the parameter information, and if so, generate a plurality of driving trajectories according to the parameter information and the parameter equation of a preset spiral curve; A screening module, configured to determine whether there are a plurality of available driving trajectories among the plurality of driving trajectories, and if so, screen out a target driving trajectory from the plurality of available driving trajectories, and control the vehicle to travel according to the target driving trajectory; Wherein, when the vehicle travels along the available driving trajectory, the distance between the vehicle and the obstacle is within a preset safe distance range; The determination module is further configured to, for each of the driving trajectories: determine the first moving distance of the vehicle at any moment when driving according to a first condition; the first condition includes: the longitudinal speed, the current position of the vehicle as the starting point, and the rotational speed of the front wheels being a first rotational speed; the value of the first rotational speed is preset, and the first rotational speed causes the vehicle to travel in a direction away from the obstacle; calculate a first spiral curve according to the first moving distance of the vehicle and the parameter equation of the spiral curve; the curvature of the end point of the first spiral curve is a set threshold; determine the second moving distance of the vehicle at any moment when driving according to a second condition; the second condition includes: the longitudinal speed, the end point of the first spiral curve as the starting point, and the rotational speed of the front wheels being a second rotational speed; the value of the second rotational speed is equal to the value of the first rotational speed, and the direction of the second rotational speed is opposite to the direction of the first rotational speed; calculate a second spiral curve according to the second moving distance of the vehicle and the parameter equation of the spiral curve; the curvature of the end point of the second spiral curve is the set threshold; determine the third moving distance of the vehicle at any moment when driving according to a third condition; the third condition includes: the longitudinal speed, the end point of the second spiral curve as the starting point, and the rotational speed of the front wheels being the first rotational speed; calculate a third spiral curve according to the third moving distance of the vehicle and the parameter equation of the spiral curve; the curvature of the end point of the third spiral curve is 0, and the orientations of the vehicle at the starting point of the first spiral curve and the end point of the third spiral curve are the same; the first spiral curve, the second spiral curve and the third spiral curve constitute the driving trajectory.
11. An electronic device, comprising a memory, a processor, and a program stored on the memory and executable on the processor, characterized in that, When the processor executes the program, the method according to any one of claims 1-9 is implemented.
12. A computer-readable storage medium having a program stored thereon, characterized in that, When the program is executed by a processor, the method according to any one of claims 1-9 is implemented.
Citation Information
Patent Citations
Vehicle low-speed automatic driving collision avoidance method and system
CN107145147A
Route planning method and device for vehicle, vehicle-mounted equipment and storage medium
CN110861650A