Driving track determination method and device, electronic equipment and readable storage medium
By obtaining historical driving trajectories from the vehicles in front of the bicycle and matching and determining the target trajectory, the problem of inaccurate vehicle path planning in complex road environments is solved, and safer and more efficient autonomous driving is achieved.
Patent Information
- Application Number
- CN202410115537.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-01-26
- Publication Date
- 2025-07-29
AI Technical Summary
In the prior art, vehicle path planning has low accuracy in complex road environments, resulting in inaccurate driving trajectory of autonomous driving or assisted driving functions.
A plurality of second vehicles are selected from the first vehicles located in front of the bicycle and the same driving direction, and their historical driving trajectories are obtained, and the target driving trajectory is determined by the matching degree, so as to correct the predicted driving trajectory of the bicycle.
It improves the accuracy and safety of the vehicle's driving trajectory, and improves the stability and driving efficiency of autonomous driving.
Smart Images

Figure CN120382915A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of vehicles, and particularly to a method, device, electronic device and readable storage medium for determining a driving trajectory. Background Art
[0002] With the development of technology, more and more vehicles are beginning to be equipped with autonomous driving functions or assisted driving functions. When implementing autonomous driving or assisted driving functions, a vehicle needs to plan a driving trajectory to achieve the autonomous driving or assisted driving functions.
[0003] In the related art, usually, environmental information including traffic guidance such as road lines and traffic lights around the vehicle is obtained, and a local high-precision map is obtained according to the position information of the vehicle. The environmental information and the high-precision map are input into a path planning model trained based on a neural network, and the path planning model outputs a driving trajectory that the vehicle needs to refer to.
[0004] However, the real road environment is relatively complex. Due to the limitations of training materials and model performance, path planning based on neural networks often cannot plan an accurate path in a complex road environment, resulting in a low accuracy of current vehicle path planning. Summary of the Invention
[0005] In view of this, the present invention aims to propose a method, device, electronic device and readable storage medium for determining a driving trajectory to solve the problem of low accuracy of current vehicle path planning.
[0006] To achieve the above object, the technical solution of the present invention is realized as follows:
[0007] In a first aspect, the present invention provides a method for determining a driving trajectory, the method including:
[0008] Selecting a plurality of second vehicles from a first vehicle located in front of the own vehicle and having the same driving direction as the own vehicle;
[0009] Obtaining the historical driving trajectories respectively corresponding to each of the second vehicles;
[0010] Matching the predicted driving trajectory of the own vehicle with the historical driving trajectories to obtain the matching degrees corresponding to each of the historical driving trajectories;
[0011] Determining a target driving trajectory from the historical driving trajectories based on the matching degrees.
[0012] Optionally, the step of selecting a plurality of second vehicles from a first vehicle located in front of the own vehicle and having the same driving direction as the own vehicle includes:
[0013] Determining a first vehicle located in front of the own vehicle and having the same driving direction as the own vehicle;
[0014] Select at least two vehicles closest to the host vehicle from the first vehicles as the second vehicles.
[0015] Optionally, the step of selecting at least two vehicles closest to the host vehicle from the first vehicles as the second vehicles includes:
[0016] Select at least one vehicle closest to the host vehicle from the first vehicles traveling in the host vehicle's lane as the second vehicles;
[0017] Select at least one vehicle closest to the host vehicle from the first vehicles traveling in the adjacent lane as the second vehicles.
[0018] Optionally, the existence probability of the first vehicles is greater than or equal to a preset probability, and the number of existence cycles of the first vehicles is greater than or equal to a preset number of cycles.
[0019] Optionally, the step of obtaining the historical driving trajectories respectively corresponding to the second vehicles includes:
[0020] Obtain the storage positions of the starting point and the ending point corresponding to the second vehicle; wherein, the storage position of the starting point represents the storage position of the trajectory point collected farthest from the current moment in the target storage space with a fixed size, the storage position of the ending point represents the storage position of the trajectory point collected closest to the current moment in the target storage space, and the target storage space is used for circularly storing the trajectory points of the second vehicle collected;
[0021] Based on the storage position of the starting point and the storage position of the ending point, obtain the set of trajectory points corresponding to the second vehicle from the target storage space;
[0022] Fit the historical driving trajectory of the second vehicle based on the set of trajectory points corresponding to the second vehicle.
[0023] Optionally, the method further includes:
[0024] Collect the vehicle position information of the second vehicle;
[0025] Perform coordinate transformation on the vehicle position information based on the vehicle coordinate system of the host vehicle to obtain the trajectory points.
[0026] Optionally, the method further includes:
[0027] Obtain the road information in front of the host vehicle;
[0028] When the forward road information indicates that there is a target road area meeting the preset road conditions in front of the host vehicle, perform the step of selecting multiple second vehicles from the first vehicles located in front of the host vehicle and moving in the same direction as the host vehicle;
[0029] After determining the target driving trajectory from the historical driving trajectories based on the matching degree, the method further includes:
[0030] Control the host vehicle to drive through the target road area based on the target driving trajectory.
[0031] In a second aspect, the present invention provides a driving trajectory determination device, and the device includes:
[0032] A selection module, configured to select multiple second vehicles from the first vehicles located in front of the host vehicle and moving in the same direction as the host vehicle;
[0033] An acquisition module, configured to acquire the historical driving trajectories respectively corresponding to each of the second vehicles;
[0034] A matching degree module, configured to match the predicted driving trajectory of the host vehicle with the historical driving trajectories to obtain the matching degree corresponding to each of the historical driving trajectories;
[0035] A driving trajectory module, configured to determine a target driving trajectory from the historical driving trajectories based on the matching degree.
[0036] Optionally, the selection module includes:
[0037] A first vehicle sub-module, configured to determine the first vehicles located in front of the host vehicle and moving in the same direction as the host vehicle;
[0038] A second vehicle sub-module, configured to select at least two vehicles closest to the host vehicle from the first vehicles as the second vehicles.
[0039] Optionally, the second vehicle sub-module includes:
[0040] A first selection sub-module, configured to select at least one vehicle closest to the host vehicle from the first vehicles driving in the host vehicle lane as the second vehicle;
[0041] A second selection sub-module, configured to select at least one vehicle closest to the host vehicle from the first vehicles driving in the adjacent lanes as the second vehicle.
[0042] Optionally, the existence probability of the first vehicle is greater than or equal to a preset probability, and the number of existence cycles of the first vehicle is greater than or equal to a preset number of cycles.
[0043] Optionally, the acquisition module includes:
[0044] A storage location acquisition sub-module, configured to acquire the starting point storage location and the ending point storage location corresponding to the second vehicle; wherein, the starting point storage location represents the storage location of the trajectory point collected farthest from the current moment in the target storage space with a fixed size, and the ending point storage location represents the storage location of the trajectory point collected closest to the current moment in the target storage space, and the target storage space is used for circularly storing the trajectory points of the second vehicle collected;
[0045] A trajectory point set sub-module, configured to acquire the trajectory point set corresponding to the second vehicle from the target storage space based on the starting point storage location and the ending point storage location;
[0046] A historical driving trajectory sub-module, configured to fit the historical driving trajectory of the second vehicle based on the trajectory point set corresponding to the second vehicle.
[0047] Optionally, the device further includes:
[0048] A vehicle position information acquisition module, configured to acquire the vehicle position information of the second vehicle;
[0049] A trajectory point module, configured to perform coordinate transformation on the vehicle position information based on the vehicle coordinate system of the own vehicle to obtain the trajectory point.
[0050] Optionally, the device further includes:
[0051] A front road information module, configured to acquire the front road information in front of the own vehicle;
[0052] A selection execution module, configured to perform the step of selecting a plurality of second vehicles from the first vehicles located in front of the own vehicle and having the same driving direction as the own vehicle when the front road information indicates that there is a target road area meeting the preset road conditions in front of the own vehicle;
[0053] The device further includes a driving module, configured to control the own vehicle to drive through the target road area based on the target driving trajectory.
[0054] In a third aspect, the present invention provides a readable storage medium, when the instructions in the readable storage medium are executed by a processor of an electronic device, enabling the electronic device to execute the above-mentioned driving trajectory determination method.
[0055] In a fourth aspect, an embodiment of the present invention provides an electronic device, which includes a processor and a memory, and the memory stores a program or instructions that can run on the processor, and when the program or instructions are executed by the processor, the steps of the method as described in the first aspect are implemented.
[0056] In a fifth aspect, the present invention provides a vehicle controller, which includes a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the computer program, the above-mentioned driving trajectory determination method is implemented.
[0057] In a sixth aspect, the present invention provides a vehicle, which includes the above-mentioned vehicle controller.
[0058] Compared with the prior art, the driving trajectory determination method, device, electronic device, and readable storage medium of the present invention have the following advantages:
[0059] In summary, the embodiments of the present invention provide a driving trajectory determination method, including: selecting a plurality of second vehicles from the first vehicles located in front of the host vehicle and having the same driving direction as the host vehicle; obtaining the historical driving trajectories corresponding to each of the second vehicles; matching the predicted driving trajectory of the host vehicle with the historical driving trajectories to obtain the matching degree corresponding to each historical driving trajectory; and determining the target driving trajectory from the historical driving trajectories based on the matching degree. It is possible to determine a plurality of second vehicles that meet the following vehicle requirements from other vehicles, and determine a target driving trajectory that matches the predicted driving trajectory of the host vehicle according to the historical driving trajectories of the plurality of second vehicles, which helps to improve the accuracy of the driving trajectory generated by the vehicle, make the driving trajectory of the vehicle safer and more reasonable, and thus help to improve the driving safety and driving efficiency based on the target driving trajectory for vehicle automatic driving. BRIEF DESCRIPTION OF THE DRAWINGS
[0060] The accompanying drawings that form a part of the present invention are used to provide a further understanding of the present invention. The schematic embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation to the present invention. In the drawings:
[0061] Figure 1 is a flowchart of the steps of a driving trajectory determination method provided by an embodiment of the present invention;
[0062] Figure 2 is a flowchart of the steps of another driving trajectory determination method provided by an embodiment of the present invention;
[0063] Figure 3 A schematic diagram of trajectory point storage provided by an embodiment of the present invention;
[0064] Figure 4 is a structural block diagram of a driving trajectory determination device provided by an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0065] It should be noted that, without conflict, the embodiments in the present invention and the features in the embodiments may be combined with each other.
[0066] The present invention will be described in detail below with reference to the accompanying drawings and in conjunction with embodiments.
[0067] Referring to Figure 1 , a flowchart showing the steps of a driving trajectory determination method provided by an embodiment of the present invention is shown.
[0068] Step 101: Select a plurality of second vehicles from the first vehicles located in front of the host vehicle and having the same driving direction as the host vehicle.
[0069] In the embodiments of the present application, the host vehicle refers to the vehicle that determines the target driving trajectory using this solution, and the first vehicle refers to the vehicle located in front of the host vehicle and having the same driving direction as the host vehicle. A plurality of second vehicles can be selected from the first vehicles, and the target driving trajectory applicable to the host vehicle can be determined through the historical driving trajectories of the second vehicles.
[0070] Specifically, in one implementation, the host vehicle can collect the environmental information in front of the vehicle through sensors such as lidar and cameras carried on the vehicle, perform target detection on the environmental information to determine the vehicles in front of the host vehicle, and then determine the driving directions of the vehicles in front of the host vehicle based on the position differences of the same vehicle in multiple frames of environmental information. The vehicles in front of the host vehicle with the same driving direction as the host vehicle are determined as the first vehicles. In another implementation, road detection can also be performed on the environmental information to determine the lane area with the same driving direction as the host vehicle, and then the vehicles in front of the vehicle in this lane area are directly determined as the first vehicles, so that the first vehicles can be directly determined through one frame of environmental information, improving the processing efficiency.
[0071] After determining the first vehicles, a plurality of second vehicles can be selected from all the first vehicles for subsequent acquisition of the target driving trajectory. In the embodiments of the present application, all the first vehicles can be directly used as the second vehicles, that is, all the first vehicles are selected as the second vehicles, or a preset number (such as 6 vehicles) of vehicles can be selected from the first vehicles as the second vehicles, or a preset proportion (such as 30%) of vehicles can be selected from the first vehicles as the second vehicles. The embodiments of the present application do not make specific limitations. The above selection process can be random selection or selection based on the attributes of the first vehicles. The above attributes can include but are not limited to vehicle speed, vehicle type, etc. For example, a preset number of vehicles with the closest vehicle speed to the host vehicle can be selected from the first vehicles as the second vehicles. The selection strategy of the second vehicles can be flexibly selected according to actual needs, and the embodiments of the present application do not make specific limitations.
[0072] It should be noted that the selection of the second vehicle can be carried out dynamically. The selected second vehicle can be continuously monitored. If the second vehicle no longer meets the selection criteria of the second vehicle, it will be excluded, and a new second vehicle will be selected from the latest determined first vehicles for supplementation. For example, if a second vehicle starts to decelerate and gradually moves out of the front area of the host vehicle and comes to the rear of the host vehicle, the second vehicle can be excluded from the set of second vehicles, and a new second vehicle will be determined from the first vehicles in front of the host vehicle to supplement the set of second vehicles.
[0073] Step 102: Obtain the historical driving trajectories respectively corresponding to each of the second vehicles.
[0074] After determining the second vehicle, it can be continuously monitored for a period of time to obtain the historical driving trajectory of the vehicle during this period. Specifically, the environmental information including the second vehicle can be continuously collected at a preset frequency, the second vehicle can be identified from the environmental information including the second vehicle and the vehicle position information of the second vehicle in the environmental information can be obtained, and the vehicle position information corresponding to the environmental information obtained at different times can be fitted to obtain the historical driving trajectory of the second vehicle.
[0075] It should be noted that the acquisition of the historical driving trajectory of the second vehicle can also be carried out dynamically. The historical driving trajectory of the second vehicle can be obtained once at preset time intervals to maintain the real-time nature of the historical trajectory.
[0076] Step 103: Match the predicted driving trajectory of the host vehicle with the historical driving trajectory to obtain the matching degree corresponding to each historical driving trajectory.
[0077] In the embodiment of the present application, the predicted driving trajectory of the host vehicle can be matched with the historical driving trajectory of the second vehicle to determine the matching degree between the historical driving trajectory of each second vehicle and the predicted driving trajectory. Among them, the predicted driving trajectory of the host vehicle can be determined by the automatic driving system based on the destination and the high-precision map. For example, the driver can set the destination and start the automatic driving system. The automatic driving system predicts the trajectory that the host vehicle needs to travel to reach the destination based on the destination set by the driver and the high-precision map to obtain the predicted driving trajectory; the predicted driving trajectory can also be determined by the assisted driving system based on the assisted driving state. For example, when the driver turns on the lane keeping function of the host vehicle, the assisted driving system of the host vehicle automatically generates a predicted driving trajectory that needs to keep driving in the current lane. The predicted driving trajectory can also be generated in other ways, which is not specifically limited in the embodiment of the present application.
[0078] It should be noted that the predicted driving trajectory is a relatively rough driving trajectory, which can provide a guiding trajectory for the host vehicle. For example, it can guide the vehicle to the shortest driving route, the most ideal driving route, the fastest driving route, etc. to the destination. During the actual driving process of the vehicle, various special situations usually occur on the road, and the vehicle needs to correct the predicted driving trajectory based on the actual road conditions to obtain the target driving trajectory that actually needs to be driven. For example, when an obstacle suddenly appears in front of the vehicle, the vehicle can calculate the target driving trajectory that can avoid the obstacle based on the predicted driving trajectory, and make the vehicle actually drive along the target driving trajectory to avoid the obstacle in front.
[0079] In the embodiments of the present application, the predicted driving trajectory of the host vehicle can be respectively matched with the historical driving trajectories of each second vehicle, so as to determine the matching degree corresponding to the historical driving trajectory. The matching degree can be determined based on one or more of, but not limited to, distance difference, shape difference, and angle difference.
[0080] Exemplarily, the predicted driving trajectory and the historical driving trajectory can be projected into the host vehicle coordinate system, and the distance deviation value between the predicted driving trajectory and the historical driving trajectory can be calculated. Among them, the distance deviation value can be described by the average value of the shortest distances between multiple trajectory points on the predicted driving trajectory and the historical driving trajectory. Specifically, multiple first points can be selected from the predicted driving trajectory. The first points can be selected by an equal-spacing method or a random method. The embodiments of the present invention do not make specific limitations. Then, the first distance between each first point and the historical driving trajectory is calculated, and the average value of all the first distances is taken to obtain the distance deviation value. The reciprocal of the distance deviation value can be directly used as the above-mentioned matching degree, that is, the larger the distance deviation value, the lower the matching degree.
[0081] The predicted driving trajectory and the historical driving trajectory can also be input into a shape similarity model, and the shape similarity model can output the shape similarity between the two, and the shape similarity can be directly used as the above-mentioned matching degree. Among them, the shape similarity model can be a mathematical model or can be trained based on a neural network model. The embodiments of the present application do not make specific limitations.
[0082] In addition, different methods can also be used to determine multiple sub-matching degrees between the predicted driving trajectory and the historical driving trajectory, and then the multiple sub-matching degrees are averaged or weighted averaged to obtain the above-mentioned similarity. For example, a first sub-matching degree can be determined according to the above-mentioned distance deviation value, and the above-mentioned shape similarity is used as the second sub-matching degree, and then the average value of the first sub-matching degree and the second sub-matching degree is used as the matching degree between the predicted driving trajectory and the historical driving trajectory. Those skilled in the art can select a suitable method to determine the above-mentioned matching degree according to actual needs. The embodiments of the present application do not make specific limitations.
[0083] Step 104: Determine a target driving trajectory from the historical driving trajectories based on the matching degree.
[0084] After determining the matching degrees corresponding to the historical driving trajectories of each second vehicle, the historical driving trajectory with the highest matching degree can be determined as the target driving trajectory, and the self-vehicle can be controlled to drive based on the target driving trajectory, so as to achieve the effect of following the second vehicle corresponding to the target driving trajectory, improve the safety and stability of the self-vehicle driving, and help reduce driving problems caused by imperfect automatic driving.
[0085] Optionally, multiple historical driving trajectories with the highest matching degrees can also be selected from the historical driving trajectories based on the matching degree, and then these multiple historical driving trajectories can be synthesized to obtain the target driving trajectory. For example, if 6 matching degrees corresponding to the historical driving trajectories of 6 second vehicles are determined, the historical driving trajectories corresponding to the top two highest matching degrees can be selected and synthesized after arranging these matching degrees from high to low to obtain the target driving trajectory. The above synthesis can include but is not limited to averaging, weighted averaging, etc., and the embodiments of the present application do not make specific limitations.
[0086] After determining the target driving trajectory, the predicted driving trajectory can be corrected with reference to the target driving trajectory to obtain a corrected driving trajectory, and the vehicle can be controlled to drive based on the corrected driving trajectory, or the vehicle can be directly controlled to drive based on the target driving trajectory, or other processing can be performed based on the target driving trajectory to obtain the final driving trajectory for controlling the vehicle to drive. Those skilled in the art can perform subsequent processing or driving operations based on the target driving trajectory according to actual needs, and the embodiments of the present application do not make specific limitations.
[0087] It should be noted that since the second vehicle does not necessarily drive in the same lane as the self-vehicle, when following the second vehicle by referring to its historical driving trajectory, the self-vehicle can be kept driving in the lane indicated by the predicted driving trajectory. Therefore, the target driving trajectory determined based on the matching degree can also be translated to the lane where the self-vehicle is located and then the vehicle can be controlled to drive based on the target driving trajectory, thereby improving the driving smoothness and safety of the vehicle to a certain extent.
[0088] In summary, the embodiment of the present invention provides a method for determining a driving trajectory, including: selecting a plurality of second vehicles from the first vehicles located in front of the host vehicle and having the same driving direction as the host vehicle; obtaining the historical driving trajectories corresponding to the respective second vehicles; matching the predicted driving trajectory of the host vehicle with the historical driving trajectories to obtain the matching degree corresponding to each historical driving trajectory; and determining a target driving trajectory from the historical driving trajectories based on the matching degree. It is possible to determine a plurality of second vehicles that meet the following-following requirements from other vehicles, and determine a target driving trajectory that matches the predicted driving trajectory of the host vehicle according to the historical driving trajectories of the plurality of second vehicles, which helps to improve the accuracy of the driving trajectory generated by the vehicle, make the driving trajectory of the vehicle safer and more reasonable, and thus helps to improve the driving safety and driving efficiency based on the target driving trajectory for autonomous driving of the vehicle.
[0089] Referring to Figure 2 , Figure 2 FIG. shows a flowchart of steps of another method for determining a driving trajectory provided by an embodiment of the present invention.
[0090] Step 201, obtain the front road information in front of the host vehicle.
[0091] In the embodiment of the present application, second vehicles can be selected to obtain the target driving trajectory for following driving in some scenarios that cannot be well handled by certain autonomous driving systems. For example, roads without lane lines, road intersection areas, crossroads areas, etc.
[0092] Specifically, during the driving of the host vehicle, the front road information in front of the host vehicle can be obtained. The front road information may include a front road image and / or front road point cloud, which is not specifically limited in the embodiment of the present application. In addition, the front road information can also be obtained based on a road information database containing road information such as a high-precision map. The front road information can be obtained from the road information database according to the current position information and driving direction of the host vehicle. In this case, the front road information may include road attributes, road shapes, lane division conditions, etc., which is not specifically limited in the embodiment of the present application.
[0093] Step 202, in the case where the front road information indicates that there is a target road area that meets the preset road conditions in front of the host vehicle, execute the step of selecting a plurality of second vehicles from the first vehicles located in front of the host vehicle and having the same driving direction as the host vehicle.
[0094] In the embodiments of the present application, it is possible to determine whether there is a target road area in front of the host vehicle according to the road information ahead, and the target road area can be determined by determining whether the road information ahead meets the preset road conditions. Among them, the preset road conditions may include crossroads road conditions, lane-less road conditions, high-precision map-less road conditions, etc. Those skilled in the art can flexibly set the preset road conditions according to actual business needs, and the embodiments of the present application do not make specific limitations. For example, the passing rate of the autonomous driving system under different road conditions can be tested, and the road conditions with a lower passing rate can be set as the preset road conditions.
[0095] If the road information ahead means that there is a target road area in front of the host vehicle that meets the preset road conditions, then the step of selecting multiple second vehicles from the first vehicles located in front of the host vehicle and having the same driving direction as the host vehicle can be executed, and the target driving trajectory is selected from the second vehicles to start following the vehicle.
[0096] Through the above steps 201 to 202, the second vehicle can be determined when the road ahead meets the preset road conditions, and it can travel based on the driving trajectory planned by the autonomous driving system in the non-target road area, and follow the vehicle based on the target driving trajectory selected from the second vehicles in the target road area. By integrating multiple driving trajectory determination strategies during the vehicle driving process, it helps to improve the stability and accuracy of vehicle autonomous driving.
[0097] Step 203, determine the first vehicle located in front of the host vehicle and having the same driving direction as the host vehicle.
[0098] This step can refer to the above step 101, and the embodiments of the present application will not elaborate.
[0099] Optionally, the existence probability of the first vehicle is greater than or equal to a preset probability, and the existence cycle number of the first vehicle is greater than or equal to a preset cycle number; wherein, the existence probability is determined by the target detection unit.
[0100] In order to improve the accuracy of determining the second vehicle, it is also possible to screen the vehicles in front of the host vehicle and having the same driving direction as the host vehicle based on the existence probability and existence cycle determined by the target detection unit to obtain the first vehicle. Among them, the existence probability is the confidence level of the vehicle detected by the target detection unit. The existence cycle number being greater than or equal to the preset cycle number can represent the number of cycles in which the existence probability of the vehicle detected by the target detection unit is greater than the preset probability. If the existence probability of the vehicle in a single target detection result is greater than or equal to the second preset probability, it means that the vehicle exists in a detection cycle, and then the vehicle has one existence cycle. It should be noted that the above existence cycle number can be the number of continuously existing cycles in time, or the number of existence cycles within a period of time, and the embodiments of the present application do not make specific limitations.
[0101] Exemplarily, if the target detection unit performs target detection around the host vehicle once every 0.1 second, a total of 50 target detections are performed in 5 seconds. Among the results of these 50 target detections, a certain vehicle A appears 40 times. Among these 40 detection results, the maximum presence probability of the vehicle A is greater than a preset probability (for example, 0.7), and in 30 consecutive target detection results, the presence probability of the vehicle A is greater than a second preset probability (for example, 0.6). When the preset number of periods is 20, it can be determined that the presence probability of the vehicle A is greater than the preset probability and the number of presence periods is greater than the preset number of periods, and the vehicle A can be determined as the first vehicle. It should be noted that the above-mentioned preset number of periods and preset probability can be flexibly set by those skilled in the art. The above-mentioned second preset probability can be equal to the preset probability or less than the preset probability, which is not specifically limited in the embodiments of the present application.
[0102] Through the presence probability and the presence period, the first vehicles that stably exist can be screened out, so that the determined second vehicles are more accurate, which helps to improve the stability and accuracy of the subsequent determination of the target driving trajectory.
[0103] Step 204: Select at least two vehicles closest to the host vehicle from the first vehicles as the second vehicles.
[0104] Since the first vehicles closer to the host vehicle can perform more accurate target detection, thereby determining a more accurate historical driving trajectory, and the historical driving trajectories of the first vehicles closer to the host vehicle have stronger reference significance. Therefore, in the embodiments of the present application, at least two vehicles closest to the host vehicle can be selected from the first vehicles as the second vehicles, that is, the second vehicles can be determined by the distance between the first vehicles and the host vehicle.
[0105] Through the above steps 203 to 204, multiple second vehicles closer to the host vehicle can be determined. The historical driving trajectories of these second vehicles closer in distance have strong reference significance for the driving of the host vehicle, and the accuracy of target detection for these second vehicles closer in distance is higher, and more accurate historical driving trajectories can be obtained, which helps to improve the accuracy and reference value of the finally determined target driving trajectory.
[0106] Optionally, step 204 may include:
[0107] Sub-step 2041: Select at least one vehicle closest to the host vehicle from the first vehicles driving in the lane of the host vehicle as the second vehicle.
[0108] In the embodiments of the present application, the second vehicle can be selected from different lanes respectively, and at least one vehicle can be selected as the second vehicle from the first vehicles traveling in the vehicle's own lane. Specifically, the positions of the first vehicles can be matched with the high-precision map to determine the lanes in which the first vehicles are traveling, and the distances between the first vehicles and the vehicle itself can be determined. Then, at least one vehicle closest to the vehicle itself among the first vehicles traveling in the vehicle's own lane is determined as the second vehicle.
[0109] It should be noted that the specific number of the above at least one vehicle can be a preset selection number, such as 1 or 2, etc., and the embodiments of the present application do not make specific limitations.
[0110] Sub-step 2042: Select at least one vehicle closest to the vehicle itself from the first vehicles traveling in the adjacent lane as the second vehicle.
[0111] In the embodiments of the present application, at least one vehicle can also be selected as the second vehicle from the first vehicles traveling in the adjacent lanes of the vehicle's own lane. Further, the adjacent lanes can include the left adjacent lane and the right adjacent lane. Thus, at least one vehicle closest to the vehicle itself can be selected from the first vehicles traveling in the left adjacent lane as the second vehicle, and at least one vehicle closest to the vehicle itself can be selected from the first vehicles traveling in the right adjacent lane as the second vehicle.
[0112] Exemplarily, if two second vehicles closest to the vehicle itself can be selected from the vehicle's own lane, two second vehicles closest to the vehicle itself can be selected from the left adjacent lane, and two second vehicles closest to the vehicle itself can be selected from the right adjacent lane, a total of 6 second vehicles are obtained.
[0113] It should be noted that the same number of second vehicles can be selected for each of the above lanes, or different numbers of second vehicles can be selected, and the embodiments of the present application do not make specific limitations.
[0114] Through the above sub-step 2041 to sub-step 2042, the first vehicles closest to the vehicle itself can be selected from multiple lanes respectively to obtain multiple second vehicles, so that the second vehicles come from multiple lanes, which helps to avoid the influence on the subsequent acquisition of the historical driving trajectories of the second vehicles due to unexpected situations (such as congestion, lane occupation, etc.) occurring in a single lane, and improves the stability of determining the target driving trajectory of this solution.
[0115] Step 205: Obtain the starting point storage location and the ending point storage location corresponding to the second vehicle. Herein, the starting point storage location represents the storage location of the trajectory point collected farthest from the current moment in the target storage space of a fixed size, and the ending point storage location represents the storage location of the trajectory point collected closest to the current moment in the target storage space. The target storage space is used for circularly storing the trajectory points of the second vehicle collected.
[0116] In the embodiments of the present application, the positions of multiple second vehicles can be obtained to get a large number of trajectory points of the second vehicles. To avoid these trajectory points occupying too much storage space and improve the storage efficiency, a target storage space of a fixed size can be used to circularly store these trajectory points. Each second vehicle corresponds to a target storage space, and the number of target storage spaces can be matched with the number of second vehicles that need to be obtained in this solution. For example, if 6 second vehicles need to be obtained, 6 target storage spaces are correspondingly set.
[0117] Refer to Figure 3 , Figure 3 which shows a schematic diagram of trajectory point storage provided by the embodiments of the present application. As Figure 3 shown, each target storage space contains a fixed number (e.g., 80) of storage units, and each storage unit can store a trajectory point. For the new trajectory point of each second vehicle, first, the trajectory points stored in the other storage units except the last storage unit in the target storage space (the storage units i0 to in-1 shown in Figure 3 ) are shifted backward by one storage unit, and the trajectory point in the last storage unit (the storage unit in shown in Figure 3 ) is discarded. Then, the new trajectory point is stored in the first storage unit (the storage unit i1 shown in Figure 3 ) of the target storage space to achieve circular storage of the trajectory points.
[0118] In the embodiments of the present application, for the trajectory points stored by the second vehicle in the target storage space, the starting point position and the ending point position therein can be recorded. The starting point position represents the storage position of the trajectory point collected farthest from the current moment currently stored in the target storage space, that is, the earliest trajectory point position retained by the second vehicle in the corresponding target storage space. The ending point position represents the storage position of the trajectory point collected closest to the current moment currently stored in the target storage space, that is, the latest trajectory point position retained by the second vehicle in the corresponding target storage space.
[0119] Optionally, the above-mentioned trajectory points can be obtained in the following manner:
[0120] Step A1: Collect the vehicle position information of the second vehicle.
[0121] In the embodiments of the present application, the host vehicle can obtain the surrounding environment information, perform target recognition through the environment information, and thus obtain the vehicle position information of the second vehicle. The above-mentioned environment information may include, but is not limited to, the environmental images captured by the host vehicle, the environmental point clouds captured by the host vehicle, etc. The vehicle position information may include the two-dimensional coordinates of the second vehicle in the two-dimensional plane, or may include the three-dimensional coordinates of the second vehicle in the three-dimensional space. The embodiments of the present application do not make specific limitations.
[0122] Step A2: Perform coordinate transformation on the vehicle position information based on the vehicle coordinate system of the host vehicle to obtain the trajectory point.
[0123] After obtaining the vehicle position information of the second vehicle, the vehicle position information can be coordinate-transformed based on the vehicle coordinate system of the host vehicle to obtain the trajectory point of the second vehicle in the vehicle coordinate system of the host vehicle.
[0124] Through the above steps A1 to A2, it is possible to align the positions of the host vehicle and the second vehicle when storing the trajectory points of the second vehicle, so that the historical driving trajectory of the second vehicle generated according to the trajectory points can be directly applied to the driving of the host vehicle, which can improve the execution efficiency of the present solution to a certain extent.
[0125] Step 206: Based on the start point storage position and the end point storage position, obtain the set of trajectory points corresponding to the second vehicle from the target storage space.
[0126] In the embodiments of the present application, the set of trajectory points corresponding to the second vehicle can be obtained from the target storage space based on the start point storage position and the end point storage position. There may be two situations for the trajectory points stored in the target storage space. One is that the start point storage position of the second vehicle is behind the end point storage position, that is, the start point storage position is greater than the end point storage position. Then, the trajectory points from the start point storage position to the last storage unit of the target storage space, and the trajectory points from the first storage unit of the target storage space to the end point storage position can be read to obtain the set of trajectory points of the second vehicle. The other is that the start point storage position of the second vehicle is in front of the end point storage position, that is, the start point storage position is less than the end point storage position. This means that all storage units in the target storage space have been occupied by the trajectory points of the second vehicle. Then, all trajectory points can be sequentially read from the target storage space to obtain the set of trajectory points of the second vehicle.
[0127] Optionally, if the number of trajectory points in the obtained trajectory point set of the second vehicle is less than the number of storage units in the target storage space, the trajectory points in the trajectory point set can also be supplemented to be the same as the number of storage units, so as to improve the stability of generating the historical driving trajectory based on the trajectory point set. Specifically, the above-mentioned supplementation method can be: supplementing through the last trajectory point of the second vehicle, or supplementing through preset trajectory points, or supplementing through the predicted trajectory points of the second vehicle. The embodiments of the present application do not make specific limitations.
[0128] Optionally, due to reasons such as the complexity of the actual environment and sensor performance, there may be jump points in the collected trajectory points of the second vehicle, that is, trajectory points that deviate greatly from the actual trajectory of the second vehicle. These jump points will directly affect the accuracy of subsequent trajectory fitting. In order to ensure that the historical trajectory points obtained by fitting based on the trajectory points are more consistent with the actual trajectory of the second vehicle, in the embodiments of the present application, outlier determination and removal can be performed on the trajectory points in the trajectory point set. Specifically, the average value and standard deviation of the trajectory points in the trajectory point set can be calculated, and then the 3δ criterion can be used to determine the outliers in the trajectory point set based on the above average value and standard deviation. Those skilled in the art can also use other methods to determine outliers, such as the Z-score method, the interquartile range method, etc. The embodiments of the present application do not make specific limitations.
[0129] Step 207: Fit the historical driving trajectory of the second vehicle based on the trajectory point set corresponding to the second vehicle.
[0130] In the embodiments of the present application, the historical driving trajectory of the second vehicle can be described by a polynomial. The historical driving trajectory of the second vehicle can be obtained by constructing a polynomial and using the trajectory point set to solve the polynomial. Generally, the following cubic polynomial equation can be used to describe the historical driving trajectory of the second vehicle:
[0131] y = a3x 3 + a2x 2 + a1x + a0
[0132] Specifically, in matlab, the polynomial regression method can be used to fit the historical driving trajectory of the second vehicle. The polynomial can be defined and solved in the following way to obtain the historical driving trajectory of the second vehicle:
[0133] First, define the quadratic term of the polynomial: X(:,1) = dx 2 ; define the linear term of the polynomial: X(:,2) = dx; define the constant term of the polynomial: X(:,3) = ones(80,1); then define the target variable Y: Y = dy; and then apply the least squares method to calculate the regression coefficient B, that is, find the best coefficient (B) to minimize the sum of the squared errors between the predicted value and the actual value: B = (XT X) -1 X T Y.
[0134] Among them, dx and dy represent the coordinates of the trajectory points, ones(80,1) represents a matrix with 80 rows and 1 column, and X T represents the transpose of X, and B is a matrix. By solving B in the above manner, each parameter in the polynomial equation for describing the historical driving trajectory of the second vehicle can be obtained, so that the trajectory equation for describing the historical driving trajectory of the second vehicle can be constructed, and the historical driving trajectory of the second vehicle can be obtained.
[0135] In addition, other methods can be used to fit the historical driving trajectory of the second vehicle, which may include but are not limited to B-spline curves, trajectory fitting models based on neural networks, etc., and the embodiments of the present application do not make specific limitations.
[0136] Step 208: Match the predicted driving trajectory of the host vehicle with the historical driving trajectory to obtain the matching degree corresponding to each historical driving trajectory.
[0137] This step can refer to step 103, and the embodiments of the present application will not be elaborated herein.
[0138] Step 209: Determine the target driving trajectory from the historical driving trajectories based on the matching degree.
[0139] This step can refer to step 104, and the embodiments of the present application will not be elaborated herein.
[0140] Step 210: Control the host vehicle to drive through the target road area based on the target driving trajectory.
[0141] In the embodiments of the present application, the host vehicle can be controlled to drive based on the determined target driving trajectory and pass through the target road area. It should be noted that the determination of the above target driving trajectory can be continuously and dynamically performed. For example, the target driving trajectory is determined every 2 seconds. Within 2 seconds after determining a target driving trajectory, the vehicle is controlled to drive along the target driving trajectory. After 2 seconds, a new target driving trajectory is determined. The target driving trajectory can be continuously determined and the vehicle can continuously drive along the newly determined target driving trajectory until it passes through the target road area, that is, it is detected that there is no longer a target road area that meets the preset road conditions in front of the host vehicle.
[0142] Furthermore, after the vehicle passes through the target road area according to the target driving trajectory, the strategy for determining the driving trajectory of the host vehicle on the normal road can be restored, such as driving along the predicted driving trajectory, etc., and the embodiments of the present application do not make specific limitations.
[0143] Through the above step 210, multiple second vehicles that meet the following - vehicle conditions can be selected from the environment, and the target driving trajectory can be determined based on the multiple second vehicles for following driving, thereby passing through the target road area, which helps to improve the stability and safety of the self - vehicle's autonomous driving.
[0144] Optionally, in the embodiments of the present application, in order to further improve the accuracy and safety of the target driving trajectory and enhance the safety of the self - vehicle when driving based on the target driving trajectory, the target driving trajectory can also be corrected by the road curvature, that is, the road curvature is introduced into the quadratic - term coefficient of the above polynomial. For example, a2 of the above polynomial can be set to where kap represents the road curvature. For example, the parameter terms of the target driving trajectory after being corrected by the road curvature can be taken as follows: a0 = 0; a1 = 0; a3 = 0, and the finally obtained corrected target driving trajectory can be:
[0145]
[0146] In summary, the embodiments of the present invention provide another method for determining a driving trajectory, including: selecting multiple second vehicles from the first vehicles located in front of the self - vehicle and having the same driving direction as the self - vehicle; obtaining the historical driving trajectories corresponding to each of the second vehicles; matching the predicted driving trajectory of the self - vehicle with the historical driving trajectories to obtain the matching degree corresponding to each historical driving trajectory; and determining the target driving trajectory from the historical driving trajectories based on the matching degree. Multiple second vehicles that meet the following - vehicle requirements can be determined from other vehicles, and the target driving trajectory that matches the predicted driving trajectory of the self - vehicle can be determined based on the historical driving trajectories of the multiple second vehicles, which helps to improve the accuracy of the driving trajectory generated by the vehicle, make the driving trajectory of the vehicle safer and more reasonable, and thus the autonomous driving of the vehicle based on the target driving trajectory helps to improve the driving safety and driving efficiency.
[0147] Based on the above - mentioned embodiments, the embodiments of the present invention also provide a device for determining a driving trajectory.
[0148] Referring to Figure 4 , Figure 4 shows the structural block diagram of a device for determining a driving trajectory provided by the embodiments of the present invention:
[0149] A selection module 401, configured to select multiple second vehicles from the first vehicles located in front of the self - vehicle and having the same driving direction as the self - vehicle;
[0150] An acquisition module 402, configured to acquire the historical driving trajectories corresponding to each of the second vehicles;
[0151] A matching degree module 403, configured to match the predicted driving trajectory of the host vehicle with the historical driving trajectory to obtain the matching degree corresponding to each historical driving trajectory;
[0152] A driving trajectory module 404, configured to determine a target driving trajectory from the historical driving trajectories based on the matching degree.
[0153] Optionally, the selection module includes:
[0154] A first vehicle sub-module, configured to determine a first vehicle located in front of the host vehicle and having the same driving direction as the host vehicle;
[0155] A second vehicle sub-module, configured to select at least two vehicles closest to the host vehicle from the first vehicles as the second vehicles.
[0156] Optionally, the second vehicle sub-module includes:
[0157] A first selection sub-module, configured to select at least one vehicle closest to the host vehicle from the first vehicles driving in the host vehicle's lane as the second vehicles;
[0158] A second selection sub-module, configured to select at least one vehicle closest to the host vehicle from the first vehicles driving in adjacent lanes as the second vehicles.
[0159] Optionally, the existence probability of the first vehicle is greater than or equal to a preset probability, and the number of existence cycles of the first vehicle is greater than or equal to a preset number of cycles.
[0160] Optionally, the acquisition module includes:
[0161] A storage location acquisition sub-module, configured to acquire the starting point storage location and the ending point storage location corresponding to the second vehicle; wherein, the starting point storage location represents the storage location of the trajectory point collected farthest from the current moment in a target storage space of a fixed size, and the ending point storage location represents the storage location of the trajectory point collected closest to the current moment in the target storage space, and the target storage space is used for circularly storing the trajectory points of the second vehicle collected;
[0162] A trajectory point set sub-module, configured to acquire the trajectory point set corresponding to the second vehicle from the target storage space based on the starting point storage location and the ending point storage location;
[0163] A historical driving trajectory sub-module, configured to fit the historical driving trajectory of the second vehicle based on the trajectory point set corresponding to the second vehicle.
[0164] Optionally, the device further includes:
[0165] A vehicle position information acquisition module, configured to acquire the vehicle position information of the second vehicle;
[0166] A trajectory point module, configured to perform coordinate transformation on the vehicle position information based on the vehicle coordinate system of the host vehicle to obtain the trajectory point.
[0167] Optionally, the device further includes:
[0168] A front road information module, configured to acquire the front road information in front of the host vehicle;
[0169] A selection execution module, configured to perform the step of selecting a plurality of second vehicles from a first vehicle located in front of the host vehicle and having the same driving direction as the host vehicle when the front road information indicates that there is a target road area that meets the preset road conditions in front of the host vehicle;
[0170] The device further includes a driving module, configured to control the host vehicle to drive through the target road area based on the target driving trajectory.
[0171] In summary, the embodiment of the present invention provides a driving trajectory determination device, including: selecting a plurality of second vehicles from a first vehicle located in front of the host vehicle and having the same driving direction as the host vehicle; acquiring the historical driving trajectories corresponding to each of the second vehicles; matching the predicted driving trajectory of the host vehicle with the historical driving trajectories to obtain the matching degree corresponding to each historical driving trajectory; and determining a target driving trajectory from the historical driving trajectories based on the matching degree. It is possible to determine a plurality of second vehicles that meet the following vehicle requirements from other vehicles, and determine a target driving trajectory that matches the predicted driving trajectory of the host vehicle according to the historical driving trajectories of the plurality of second vehicles, which helps to improve the accuracy of the driving trajectory generated by the vehicle, make the driving trajectory of the vehicle safer and more reasonable, and thus the automatic driving of the vehicle based on the target driving trajectory helps to improve the driving safety and driving efficiency.
[0172] The embodiment of the present invention further provides a readable storage medium, when the instructions in the readable storage medium are executed by the processor of the electronic device, enabling the electronic device to execute the above-mentioned driving trajectory determination method.
[0173] The embodiment of the present invention further provides an electronic device, the electronic device includes a processor and a memory, the memory stores a program or instructions running on the processor, and when the program or the instructions are executed by the processor, the above-mentioned driving trajectory determination method is implemented.
[0174] The embodiment of the present invention further provides a vehicle controller, the vehicle controller includes a memory, a processor, and a computer program stored on the memory and executable on the processor, and the processor executes the above-mentioned driving trajectory determination method.
[0175] An embodiment of the present invention further provides a vehicle, including the above-mentioned vehicle controller.
[0176] Those skilled in the art can clearly understand that for the convenience and brevity of description, the specific working processes of the above-described systems, devices, and units can refer to the corresponding processes in the foregoing device embodiments, and will not be elaborated herein.
[0177] The above are only the preferred embodiments of the present invention, and are not intended to limit the present invention. Any modifications, equivalent replacements, and improvements made within the spirit and principles of the present invention shall be included in the protection scope of the present invention.
[0178] The above is only the specific implementation manner of the present invention, but the protection scope of the present invention is not limited thereto. Any person skilled in the art can easily think of changes or replacements within the technical scope disclosed by the present invention, and all should be covered by the protection scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.
Claims
1. A method for determining a driving trajectory, characterized in that, The method includes: Selecting a plurality of second vehicles from a first vehicle in front of the host vehicle and traveling in the same direction as the host vehicle; Obtaining the historical driving trajectories respectively corresponding to each of the second vehicles; Matching the predicted driving trajectory of the host vehicle with the historical driving trajectories to obtain the matching degree corresponding to each of the historical driving trajectories; Determining a target driving trajectory from the historical driving trajectories based on the matching degree.
2. The method according to claim 1, characterized in that The step of selecting a plurality of second vehicles from a first vehicle in front of the host vehicle and traveling in the same direction as the host vehicle includes: Determining a first vehicle in front of the host vehicle and traveling in the same direction as the host vehicle; Selecting at least two vehicles closest to the host vehicle from the first vehicle as the second vehicles.
3. The method according to claim 2, wherein The step of selecting at least two vehicles closest to the host vehicle from the first vehicle as the second vehicles includes: Selecting at least one vehicle closest to the host vehicle from the first vehicles traveling in the host vehicle's lane as the second vehicles; Selecting at least one vehicle closest to the host vehicle from the first vehicles traveling in the adjacent lane as the second vehicles.
4. The method according to claim 2, wherein The existence probability of the first vehicle is greater than or equal to a preset probability, and the number of existence cycles of the first vehicle is greater than or equal to a preset number of cycles.
5. The method according to claim 1, characterized in that The step of obtaining the historical driving trajectories respectively corresponding to each of the second vehicles includes: Obtaining the starting point storage position and the ending point storage position corresponding to the second vehicle; wherein, the starting point storage position represents the storage position of the trajectory point collected farthest from the current moment in a target storage space of a fixed size, the ending point storage position represents the storage position of the trajectory point collected closest to the current moment in the target storage space, and the target storage space is used for circularly storing the trajectory points of the second vehicle collected; Based on the starting point storage position and the ending point storage position, obtaining the set of trajectory points corresponding to the second vehicle from the target storage space; Fitting the historical driving trajectory of the second vehicle based on the set of trajectory points corresponding to the second vehicle.
6. The method according to claim 5, characterized in that, The method further includes: Collecting the vehicle position information of the second vehicle; Performing coordinate transformation on the vehicle position information based on the host vehicle coordinate system of the host vehicle to obtain the trajectory points.
7. The method according to claim 1, characterized in that The method further includes: Obtaining the road information in front of the host vehicle; When the road information in front indicates that there is a target road area that meets the preset road conditions in front of the host vehicle, performing the step of selecting a plurality of second vehicles from a first vehicle in front of the host vehicle and traveling in the same direction as the host vehicle; After determining the target driving trajectory from the historical driving trajectories based on the matching degree, the method further includes: Controlling the host vehicle to travel through the target road area based on the target driving trajectory.
8. A driving trajectory determination device, characterized in that, The device includes: A selection module, configured to select a plurality of second vehicles from a first vehicle in front of the host vehicle and traveling in the same direction as the host vehicle; An acquisition module, configured to obtain the historical driving trajectories respectively corresponding to each of the second vehicles; A matching degree module, configured to match the predicted driving trajectory of the host vehicle with the historical driving trajectory to obtain the matching degree corresponding to each historical driving trajectory; A driving trajectory module, configured to determine a target driving trajectory from the historical driving trajectories based on the matching degree.
9. An electronic device, characterized in that, The electronic device includes a processor and a memory, and the memory stores a program or instruction running on the processor. When the program or the instruction is executed by the processor, the driving trajectory determination method according to any one of claims 1 to 7 is implemented.
10. A readable storage medium, characterized in that, When the instructions in the readable storage medium are executed by the processor of the electronic device, the electronic device is enabled to execute the driving trajectory determination method according to any one of claims 1 to 7.