A method and device for constructing a vehicle lane-changing model
By integrating the first decision tree model and the pre-stored decision tree model in autonomous driving vehicles, a fusion lane change model is built, which solves the problem of similar decision styles of autonomous lane change in different vehicles, and improves the degree of anthropomorphism and passenger experience of autonomous driving.
Patent Information
- Application Number
- CN202210185748.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-02-28
- Publication Date
- 2025-07-11
- Estimated Expiration
- 2042-02-28
AI Technical Summary
Since the existing autonomous lane change strategies are mostly based on the same lane change decision model, different vehicles have similar decision styles when autonomous lane change, and the passenger experience is poor.
By obtaining the lane change data of the vehicle in the manual driving scenario, a first decision tree model is built and fused with the pre-stored second decision tree model to form a fusion lane change model to guide lane change decisions in the autonomous driving scenario.
It improves the degree of anthropomorphism of vehicle autonomous driving and enhances the passenger's riding experience.
Smart Images

Figure CN114670833B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of autonomous driving, and particularly to a method and device for constructing a vehicle lane change model. Background Art
[0002] Automatic Lane Change (ALC) is one of the core technologies in autonomous driving technology. Through the automatic lane change technology, a vehicle can autonomously complete the lane change and merging behavior without driver intervention, thereby greatly improving the driving efficiency of the vehicle in autonomous driving. The performance of vehicle automatic lane change largely depends on the quality of the automatic lane change strategy. A high-quality automatic lane change strategy can generate a lane change intention "anthropomorphically" at an appropriate time and space to prepare for the execution of the automatic lane change.
[0003] However, the existing automatic lane change strategies are generated based on a pre-constructed lane change decision model, and the lane change decision models are mostly trained using a large amount of historical driving simulation data. In this way, the differences between the lane change decision models used in different vehicles are small, which makes the decision-making styles of different vehicles similar during automatic lane change, the "anthropomorphic" degree of autonomous driving is low, and the riding experience of passengers is poor. Summary of the Invention
[0004] The present invention provides a method and device for constructing a vehicle lane change model, which solves the problems of low "anthropomorphic" degree during the autonomous driving process of the vehicle and poor riding experience of passengers.
[0005] To achieve the above object, the present invention adopts the following technical solutions:
[0006] In a first aspect, the present invention provides a method for constructing a vehicle lane change model, the method comprising:
[0007] Obtain M groups of lane change data of the vehicle in a manual driving scenario, each group of lane change data being used to indicate the data of the vehicle each time it changes lanes, and each group of lane change data including the values of N driving attributes, where M and N are integers greater than 1;
[0008] Determine a first decision tree model according to the value of each driving attribute included in each group of lane change data and the preset range corresponding to each driving attribute;
[0009] Determine a fusion lane change model according to the first decision tree model and a pre-stored second decision tree model; the fusion lane change model is used for lane change decision-making of the vehicle in an autonomous driving scenario.
[0010] In a possible implementation manner, determining a merged lane-changing model according to a first decision tree model and a pre-stored second decision tree model includes: determining a merged split value for each driving attribute according to a first target split value of each driving attribute included in the first decision tree model and a second target split value of each driving attribute included in the pre-stored second decision tree model; determining the order of the merged split value of each driving attribute according to the order of the first target split value of each driving attribute included in the first decision tree model and the order of the second target split value of each driving attribute included in the second decision tree model; and determining the merged lane-changing model according to the merged split value of each driving attribute and the order of the merged split value of each driving attribute.
[0011] In a possible implementation manner, determining a first decision tree model according to the value of each driving attribute included in each group of lane-changing data and the preset range corresponding to each driving attribute includes: determining at least one split value of each driving attribute and the order of each split value of each driving attribute according to the value of each driving attribute included in each group of lane-changing data and the preset range corresponding to each driving attribute; and determining the first decision tree model according to at least one split value of each driving attribute and the order of each split value of each driving attribute.
[0012] In a possible implementation manner, determining a first decision tree model according to at least one split value of each driving attribute and the order of each split value of each driving attribute includes: when each driving attribute corresponds to a first target split value, determining the first decision tree model according to the first target split value of each driving attribute and the order of the first target split value of each driving attribute; when at least one of the N driving attributes corresponds to multiple split values, determining an initial decision tree model according to at least one split value of each driving attribute and the order of each split value of each driving attribute, and pruning the initial decision tree model to obtain the first decision tree model, where the first target split value of each driving attribute included in the first decision tree model is one of at least one split value of the corresponding driving attribute.
[0013] In a possible implementation manner, determining at least one split value of each driving attribute and the order of each split value of each driving attribute according to the value of each driving attribute included in each group of lane-changing data and the preset range corresponding to each driving attribute includes: determining multiple alternative split values corresponding to each driving attribute according to the preset range corresponding to each driving attribute and the pre-stored split algorithm; calculating the Gini coefficient of each alternative split value corresponding to each driving attribute according to the value of each driving attribute included in each group of lane-changing data; and determining at least one split value of each driving feature and the order of each split value of each driving attribute according to the magnitude of the Gini coefficient of each alternative split value corresponding to each driving attribute.
[0014] In a possible implementation, each set of lane change data further includes the value of the weather attribute, and the values of the weather attributes of the M sets of lane change data are the same; correspondingly, the second decision tree model is obtained under the condition of the value of the weather attribute of the M sets of lane change data.
[0015] In a possible implementation, after determining the fusion lane change model, the method for constructing a vehicle lane change model further includes: continuously obtaining lane change data of the vehicle in a manual driving scenario; when the total amount of the continuously obtained lane change data meets a preset condition, determining a new first decision tree model according to the lane change data that meets the preset condition; and determining a new fusion lane change model according to the new first decision tree model and the fusion lane change model.
[0016] In a second aspect, the present invention provides a device for constructing a vehicle lane change model, including:
[0017] An acquisition module, configured to acquire M sets of lane change data of the vehicle in a manual driving scenario, each set of lane change data is used to indicate the data when the vehicle changes lanes each time, and each set of lane change data includes the values of N driving attributes, where M and N are integers greater than 1;
[0018] A first determination module, configured to determine a first decision tree model according to the value of each driving attribute included in each set of lane change data acquired by the acquisition module and the preset range corresponding to each driving attribute;
[0019] A second determination module, configured to determine a fusion lane change model according to the first decision tree model determined by the first determination module and a pre-stored second decision tree model; the fusion lane change model is used for lane change decision-making of the vehicle in an autonomous driving scenario.
[0020] In a possible implementation, the second determination module is specifically configured to: determine the fusion split value of each driving attribute according to the first target split value of each driving attribute included in the first decision tree model and the second target split value of each driving attribute included in the pre-stored second decision tree model; determine the order of the fusion split value of each driving attribute according to the order of the first target split value of each driving attribute included in the first decision tree model and the order of the second target split value of each driving attribute included in the second decision tree model; and determine the fusion lane change model according to the fusion split value of each driving attribute and the order of the fusion split value of each driving attribute.
[0021] In a possible implementation manner, the first determination module is specifically configured to: determine at least one splitting value of each driving attribute and the bit order of each splitting value of each driving attribute according to the value of each driving attribute included in each group of lane-changing data and the preset range corresponding to each driving attribute; determine the first decision tree model according to at least one splitting value of each driving attribute and the bit order of each splitting value of each driving attribute.
[0022] In a possible implementation manner, the first determination module is specifically configured to: when each driving attribute corresponds to a first target splitting value, determine the first decision tree model according to the first target splitting value of each driving attribute and the bit order of the first target splitting value of each driving attribute; when at least one of the N driving attributes corresponds to multiple splitting values, determine the initial decision tree model according to at least one splitting value of each driving attribute and the bit order of each splitting value of each driving attribute, and perform pruning processing on the initial decision tree model to obtain the first decision tree model, where the first target splitting value of each driving attribute included in the first decision tree model is one of at least one splitting value of the corresponding driving attribute.
[0023] In a possible implementation manner, the first determination module is specifically configured to: determine multiple alternative splitting values corresponding to each driving attribute according to the preset range corresponding to each driving attribute and the pre-stored splitting algorithm; calculate the Gini coefficient of each alternative splitting value corresponding to each driving attribute according to the value of each driving attribute included in each group of lane-changing data; determine at least one splitting value of each driving attribute and the bit order of each splitting value of each driving attribute according to the magnitude of the Gini coefficient of each alternative splitting value corresponding to each driving attribute.
[0024] In a possible implementation manner, each group of lane-changing data further includes the value of the weather attribute, and the values of the weather attributes of the M groups of lane-changing data are the same; correspondingly, the second decision tree model is obtained under the condition of the value of the weather attribute of the M groups of lane-changing data.
[0025] In a possible implementation manner, the device for constructing the vehicle lane-changing model further includes a third determination module and a decision module; the acquisition module is further configured to, in an autonomous driving scenario, acquire the value of the target weather attribute and the value of each target driving attribute of the vehicle; the third determination module is configured to determine the target fusion lane-changing model corresponding to the value of the target weather attribute; the decision module is configured to determine whether the vehicle changes lanes according to the value of each target driving attribute by using the target fusion lane-changing model.
[0026] In a possible implementation, the obtaining module is further configured to continuously obtain lane change data of the vehicle in a manual driving scenario; the first determining module is further configured to, when the total data volume of the continuously obtained lane change data meets a preset condition, determine a new first decision tree model according to the lane change data that meets the preset condition; the second determining module is further configured to determine a new fused lane change model according to the new first decision tree model and the fused lane change model.
[0027] In a third aspect, the present invention provides a lane change decision method, which is characterized by comprising:
[0028] In an autonomous driving scenario, obtain the current target lane change data of the vehicle, where the target lane change data includes the value of the target weather attribute and the value of each of N target driving attributes, and N is an integer greater than 1;
[0029] Determine a target fused lane change model corresponding to the value of the target weather attribute, where the target fused lane change model is obtained according to a first decision tree model and a pre-stored second decision tree model, and the first decision tree model is obtained according to M sets of lane change data of the vehicle in a manual driving scenario, and M is an integer greater than 1;
[0030] According to the value of each target driving attribute, use the target fused lane change model to determine whether the vehicle changes lanes.
[0031] In a fourth aspect, the present invention provides a lane change decision device, which is characterized by comprising:
[0032] An obtaining module, configured to obtain the current target lane change data of the vehicle in an autonomous driving scenario, where the target lane change data includes the value of the target weather attribute and the value of each of N target driving attributes, and N is an integer greater than 1;
[0033] A third determining module, configured to determine a target fused lane change model corresponding to the value of the target weather attribute obtained by the obtaining module, where the target fused lane change model is obtained according to a first decision tree model and a pre-stored second decision tree model, and the first decision tree model is obtained according to M sets of lane change data of the vehicle in a manual driving scenario, and M is an integer greater than 1;
[0034] A decision module, configured to determine whether the vehicle changes lanes according to the value of each target driving attribute obtained by the obtaining module and using the target fused lane change model determined by the third determining module.
[0035] Fifth aspect, the present invention provides a vehicle, characterized in that the vehicle includes: a processor and a memory; the memory is used to store computer program code, and the computer program code includes computer instructions; when the processor executes the computer instructions, the vehicle executes the method for constructing a vehicle lane-changing model according to the first aspect and any possible implementation manner thereof, or executes the lane-changing decision-making method according to the third aspect and any possible implementation manner thereof.
[0036] Sixth aspect, the present invention provides a computer-readable storage medium, on which computer instructions are stored. When the computer instructions run on a computer device, the computer device is caused to execute the method for constructing a vehicle lane-changing model according to the first aspect and any possible implementation manner thereof, or execute the lane-changing decision-making method according to the third aspect and any possible implementation manner thereof.
[0037] Seventh aspect, the present invention provides a computer program product, which includes computer instructions. When the computer instructions run on a computer device, the computer device is caused to execute the method for constructing a vehicle lane-changing model according to the first aspect and any possible implementation manner thereof, or execute the lane-changing decision-making method according to the third aspect and any possible implementation manner thereof.
[0038] In the method for constructing a vehicle lane-changing model provided by the embodiments of the present invention, the vehicle obtains M groups of lane-changing data of the vehicle in a manual driving scenario, where each group of lane-changing data is used to indicate the data when the vehicle changes lanes each time, and each group of lane-changing data includes values of N driving attributes. M and N are integers greater than 1. And according to the value of each driving attribute included in each group of lane-changing data, and the preset range corresponding to each driving attribute, a first decision tree model is determined, and according to the first decision tree model and a pre-stored second decision tree model, a fusion lane-changing model is determined. The fusion lane-changing model is used for lane-changing decision-making of the vehicle in an autonomous driving scenario. The present invention obtains a fusion lane-changing model by fusing the first decision tree model and the pre-stored second decision tree model, so that the decision-making style of the vehicle during autonomous lane-changing using the fusion lane-changing model is closer to the driving style of the vehicle during manual driving, thereby improving the "humanization" degree of vehicle autonomous driving and enhancing the experience of passengers during vehicle autonomous driving. Description of the Drawings
[0039] Figure 1 It is a schematic diagram of an application scenario of a method for constructing a vehicle lane-changing model provided by an embodiment of the present invention;
[0040] Figure 2 It is one of the flowcharts of a method for constructing a vehicle lane-changing model provided by an embodiment of the present invention;
[0041] Figure 3 It is one of the structural schematic diagrams of a decision tree model provided by an embodiment of the present invention;
[0042] Figure 4 This is the second structural schematic diagram of a decision tree model provided by an embodiment of the present invention;
[0043] Figure 5 This is the second flowchart of a method for constructing a vehicle lane change model provided by an embodiment of the present invention;
[0044] Figure 6 This is the structural schematic diagram of a device for constructing a vehicle lane change model provided by an embodiment of the present invention;
[0045] Figure 7 This is the flowchart of a lane change decision method provided by an embodiment of the present invention;
[0046] Figure 8 This is the structural schematic diagram of a lane change decision device provided by an embodiment of the present invention. Detailed implementation manners
[0047] Next, the technical solutions in the embodiments of the present invention will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without making creative efforts shall fall within the protection scope of the present invention.
[0048] Hereinafter, the terms "first" and "second" are only used for descriptive purposes and cannot be understood as indicating or implying relative importance or implicitly specifying the quantity of the indicated technical features. Thus, the features defined with "first" and "second" may explicitly or implicitly include one or more of such features. In the description of the embodiments of the present disclosure, unless otherwise specified, the meaning of "a plurality" is two or more. Additionally, the use of "based on" or "according to" means open and inclusive because a process, step, calculation, or other action "based on" or "according to" one or more of the stated conditions or values can in practice be based on additional conditions or values beyond those stated.
[0049] To solve the problem of low "humanization" level during the automatic driving process of a vehicle and poor riding experience of passengers, an embodiment of the present invention provides a method and device for constructing a vehicle lane-changing model. A computer device obtains M groups of lane-changing data of the vehicle in a manual driving scenario, where each group of lane-changing data is used to indicate the data when the vehicle changes lanes each time, and each group of lane-changing data includes values of N driving attributes. M and N are integers greater than 1. Then, according to the value of each driving attribute included in each group of lane-changing data and the preset range corresponding to each driving attribute, a first decision tree model is determined. And according to the first decision tree model and a pre-stored second decision tree model, a fusion lane-changing model is determined. The fusion lane-changing model is used for lane-changing decision-making of the vehicle in an automatic driving scenario. By fusing the first decision tree model and the pre-stored second decision tree model to obtain the fusion lane-changing model, the decision-making style of the vehicle during autonomous lane-changing using the fusion lane-changing model is closer to the driving style during vehicle manual driving, thereby improving the "humanization" level of vehicle automatic driving and enhancing the riding experience of passengers during the vehicle automatic driving process.
[0050] Figure 1 Schematic diagram of an application scenario of a method for constructing a vehicle lane-changing model provided by an embodiment of the present invention. As Figure 1 shown, the application scenario may include: vehicle 10, computer device 20, and target vehicle 30.
[0051] During the manual driving process of vehicle 10, whenever vehicle 10 changes lanes to a side lane, a sensor in vehicle 10 can obtain a group of lane-changing data of vehicle 10 at this moment. For example, a group of lane-changing data may include data such as the relative distance and relative speed between vehicle 10 and surrounding target vehicle 30, and send the group of lane-changing data to computer device 20. When the total data volume of the obtained lane-changing data by computer device 20 reaches a preset condition, according to the total lane-changing data, a first decision tree model is determined, and then the first decision tree model and the pre-stored second decision tree model are fused to obtain a fusion lane-changing model, and the fusion lane-changing model is sent to vehicle 10 for the lane-changing decision-making of vehicle 10 in subsequent automatic driving scenarios.
[0052] In another possible application scenario, only the vehicle 10 and the target vehicle 30 may be included. In this scenario, during the manual driving process of the vehicle 10, whenever the vehicle 10 changes lanes to one side lane, the sensors in the vehicle 10 can obtain a set of lane-changing data of the vehicle 10 at this moment. For example, a set of lane-changing data may include data such as the relative distance and relative speed between the vehicle 10 and the surrounding target vehicles 30. When the total data volume of the obtained lane-changing data of the vehicle 10 reaches a preset condition, according to the total lane-changing data, a first decision tree model is determined, and then the first decision tree model and the pre-stored second decision tree model are fused to obtain a fused lane-changing model, so as to facilitate the lane-changing decision of the vehicle 10 in subsequent autonomous driving scenarios.
[0053] Figure 2 The flowchart of a method for constructing a vehicle lane-changing model provided by an embodiment of the present invention is shown as Figure 2 shown. The method for constructing a vehicle lane-changing model may include the following steps S201-S203.
[0054] S201. Obtain M sets of lane-changing data of the vehicle in the manual driving scenario, each set of lane-changing data is used to indicate the data when the vehicle changes lanes each time, and each set of lane-changing data includes the values of N driving attributes, where M and N are integers greater than 1.
[0055] Among them, the driving attributes may include, but are not limited to, the relative distance and speed between the vehicle and the surrounding target vehicles. For example, the relative speed v of the vehicle with the vehicle in front in the same lane sf , the relative distance d between the vehicle and the vehicle in front in the same lane sf , the relative speed v of the vehicle with the vehicle in front in the target lane tf , the relative distance d between the vehicle and the vehicle in front in the target lane tf , the relative speed v of the vehicle with the vehicle behind in the target lane td , the relative distance d between the vehicle and the vehicle behind in the target lane td . In addition, the driving attributes may further include the speed ratio v e , and the speed ratio = (target vehicle speed - current vehicle speed) / target vehicle speed, where the target vehicle speed may be the target driving vehicle speed of the vehicle in the autonomous driving scenario. It can be understood that in the manual driving scenario, each time the vehicle changes lanes, a set of lane-changing data at the current moment will be generated accordingly.
[0056] In a possible implementation manner, the computer device may obtain M sets of lane-changing data of the vehicle in the manual driving scenario, each set of lane-changing data is used to indicate the data when the vehicle changes lanes each time, and each set of lane-changing data includes the values of N driving attributes, where M and N are integers greater than 1.
[0057] In another possible implementation, each set of lane-changing data may further include the value of the weather attribute, which is used to represent the weather condition during lane-changing, such as rainy day, snowy day, or foggy day, etc. It can be understood that the values of the weather attributes of the above M sets of lane-changing data are the same.
[0058] S202. Determine the first decision tree model according to the value of each driving attribute included in each set of lane-changing data and the preset range corresponding to each driving attribute.
[0059] Among them, the decision tree model is a model with a tree structure. Each of its internal nodes represents a test on an attribute, each branch represents a test output, and each leaf node represents a category. The decision tree model usually uses the maximum expected benefit value or the lowest expected cost as the decision criterion, solves the benefit values of various solutions under different conditions through a graphical method, and then makes a decision by comparing the benefit values.
[0060] In the generation process of the first decision tree model in this embodiment, essentially, all driving attributes are sorted according to a certain standard to obtain the ordinal number of each driving attribute, and the splitting value of each driving attribute is determined. The splitting value is the critical value when the driving attribute node splits. It can be understood that the computer device can, according to the value of each driving attribute included in each set of lane-changing data and the preset range corresponding to each driving attribute, traverse all alternative splitting values within the value range of each driving attribute, calculate their importance respectively, and determine several splitting values with higher importance and their corresponding ordinal numbers according to the magnitudes of the importance of all alternative splitting values, so as to determine the first decision tree model. The importance can be represented by the Gini coefficient. The smaller the Gini coefficient, the higher the importance. The importance can also be represented by the information gain. The larger the information gain, the higher the importance.
[0061] Specifically, the vehicle can determine at least one splitting value of each driving attribute and the ordinal number of each splitting value of each driving attribute according to the value of each driving attribute included in each set of lane-changing data and the preset range corresponding to each driving attribute, and determine the first decision tree model according to at least one splitting value of each driving attribute and the ordinal number of each splitting value of each driving attribute.
[0062] Exemplarily, when determining at least one split value for each driving attribute and the order of each split value of each driving attribute, the computer device may calculate the Gini coefficient of each alternative split value included in each driving attribute according to the value of each driving attribute included in each set of lane change data and the preset range corresponding to each driving attribute, and determine at least one split value of each driving characteristic and the order of each split value of each driving attribute according to the magnitude of the Gini coefficient of each alternative split value included in each driving attribute. It can be understood that the Gini coefficient can measure the purity of a driving attribute for classifying a set of lane change data. A driving attribute with a smaller Gini coefficient represents that the driving attribute has a stronger classification ability for a set of lane change data, has a greater impact on the behavior to be decided, and is more referenceable, and should be preferentially used for decision-making judgment. Among them, the Gini coefficient can be calculated by the following formulas (1) and (2):
[0063]
[0064] Gini(D,A)=|D1| / |D|*Gini(D1)+|D2| / |D|*Gini(D2); Formula (2)
[0065] where k is the number of all categories after classification based on the split value of a certain driving attribute, p k is the probability of occurrence of the kth category, Gini(D,A) is the Gini coefficient of the driving attribute A in the lane change data D, and D1 and D2 are the two categories into which the lane change data is divided based on the driving attribute A.
[0066] In a possible implementation, as Figure 3 shown, when each driving attribute corresponds to a first target split value, the vehicle may determine a first decision tree model as Figure 3 shown according to the first target split value of each driving attribute and the order of the first target split value of each driving attribute.
[0067] In another possible implementation, as Figure 4 shown, when there is at least one driving attribute among the N driving attributes that corresponds to multiple split values, the vehicle may determine a model as Figure 4The initial decision tree model shown. Since the establishment process of the decision tree model completely depends on the training samples (M sets of lane-changing data), this initial decision tree model can produce a perfect fitting effect for the training samples. However, such an initial decision tree model is too large and complex for the test samples and may result in a relatively high classification error rate. This phenomenon is called overfitting. Based on this, the vehicle can also perform pruning on the initial decision tree model to obtain the first decision tree model, thereby solving the overfitting problem. It can be understood that the first target split value of each driving attribute included in the first decision tree model can be one of at least one split value of the corresponding driving attribute.
[0068] Exemplarily, the pruning process can be pre-pruning (also known as pre-pruning). Since the construction method of all decision tree models stops creating branches only when the system entropy cannot be further reduced, in order to avoid overfitting of the decision tree model, stop conditions can be set in advance, for example: the sample data on the subtree all belong to the same category; the maximum tree depth is reached; the number of samples at the subtree node is less than a certain threshold, or less than a certain proportion; when the subtree node is split according to the optimal partitioning criterion, the number of samples of its subtree is less than a certain threshold, or less than a certain proportion; the optimal partitioning gain is less than a certain threshold, such as the error value, etc. These methods can, to a certain extent, make the decision tree stop growing in advance, prevent the unrestricted generation of tree branches, and thus avoid overfitting to a certain extent.
[0069] Exemplarily, the pruning process can also be post-pruning, that is, pruning is performed on the overfitted decision tree that has been generated to obtain a simplified pruned decision tree. There are various post-pruning methods. For example, Reduced-Error Pruning (REP). This pruning method considers each internal node as a candidate for pruning. If the error rate of the decision tree after pruning a certain node does not increase on the validation set, then the node is deleted. Otherwise, it is retained, and the above operation is repeated until all internal nodes are traversed. Another example is Pessimistic Error Pruning (PEP). This method determines the pruning of the subtree based on the error rate before and after pruning. If the misclassification rate of this single node after pruning is less than the sum of the misclassification rate of the subtree with this node as the root node before pruning and the standard deviation of the misclassification rate, then pruning is performed on this node, otherwise this node is retained. Another example is Cost-Complexity Pruning (CCP). This method defines the cost and complexity for any subtree T t defines the cost and complexity, and a parameter a that measures the relationship between the cost and complexity. The cost refers to the misclassified samples increased due to the replacement of the subtree T t by leaf nodes during the pruning process, and the complexity represents the subtree T after pruning tThe reduced leaf node tree, where a represents the relationship between the reduction in the complexity of the tree after pruning and the cost, and its value range is non-zero positive real numbers. And for any internal node, when a satisfies the following formula (3), the total loss before and after pruning remains unchanged, that is, it reaches a balance state between the reduction in complexity and the increase in misclassification rate.
[0070] a = (C(t) - C(T t )) / (|T t | - 1); Formula (3)
[0071] Where C(t) is the prediction error of the node, C(T t ) is the prediction error of the subtree T t , |T t | is the number of nodes in the subtree T t . Based on the above formula, calculate the a value of each non-leaf node from bottom to top, and then cut off the subtree with the smallest a value each time, so as to obtain a series of subtree sequences. Finally, based on the error rate on the validation set, select the best decision tree in the subtree sequence.
[0072] It can be understood that since each group of lane-changing data can also include the value of the weather attribute, and the values of the weather attributes of the M groups of lane-changing data are the same, the first decision tree model determined by the vehicle can indicate the lane-changing decision style of the vehicle during manual driving in a specific weather condition. That is to say, the vehicle can classify and store the lane-changing data obtained in the manual driving scenario according to the value of the weather attribute in each group of lane-changing data. Based on this, under each weather attribute, the vehicle can determine the first decision tree model corresponding to the weather attribute, so as to indicate the lane-changing decision style of the vehicle in the manual driving scenario under different weather conditions.
[0073] S203. Determine a fusion lane-changing model according to the first decision tree model and the pre-stored second decision tree model; the fusion lane-changing model is used for the lane-changing decision of the vehicle in the autonomous driving scenario.
[0074] Among them, the second decision tree model can be a lane-changing decision model trained based on a large amount of driving simulation data or historical driving data. The second decision tree model can be obtained under the condition of the value of the weather attribute of the M groups of lane-changing data.
[0075] Specifically, the vehicle can determine the fusion lane-changing model according to the first decision tree model and the pre-stored second decision tree model through the model fusion idea. The fusion lane-changing model can be used for the lane-changing decision of the vehicle in the autonomous driving scenario.
[0076] In this embodiment, the vehicle obtains M sets of lane-changing data of the vehicle in the manual driving scenario. Each set of lane-changing data is used to indicate the data when the vehicle changes lanes each time. Each set of lane-changing data includes the values of N driving attributes. M and N are integers greater than 1. Then, according to the value of each driving attribute included in each set of lane-changing data and the preset range corresponding to each driving attribute, a first decision tree model is determined. And according to the first decision tree model and the pre-stored second decision tree model, a fusion lane-changing model is determined. The fusion lane-changing model is used for the lane-changing decision of the vehicle in the automatic driving scenario. In this embodiment, a fusion lane-changing model is obtained by fusing the first decision tree model and the pre-stored second decision tree model, so that the decision-making style of the vehicle when autonomously changing lanes using the fusion lane-changing model is closer to the driving style of the vehicle when driving manually, thereby improving the "anthropomorphic" degree of the vehicle's automatic driving and enhancing the experience of passengers during the vehicle's automatic driving process.
[0077] Optionally, on the basis of the above embodiment, in combination with Figure 2 , as Figure 5 shown, the above step S203 further includes:
[0078] S501. Determine the fusion split value of each driving attribute according to the first target split value of each driving attribute included in the first decision tree model and the second target split value of each driving attribute included in the pre-stored second decision tree model.
[0079] It can be understood that when the same driving attribute has different target split values in the first decision tree model and the second decision tree model respectively, the vehicle can fuse the target split values.
[0080] Specifically, the vehicle can determine the fusion split value of each driving attribute according to the first target split value of each driving attribute included in the first decision tree model and the second target split value of each driving attribute included in the pre-stored second decision tree model.
[0081] In a possible implementation manner, the specific fusion method of the split values is as the following formula (4):
[0082] V f =(1-λ)*V o +λ*V n ; Formula (4)
[0083] where V f is the fusion split value after fusion, V o is the second target split value of this driving attribute in the second decision tree model, V n is the first target split value of this driving attribute in the first decision tree model, and λ is the split value fusion coefficient, which is a predetermined constant and determines the update speed of the split value fusion algorithm.
[0084] S502. Determine the order of the fusion splitting value of each driving attribute according to the order of the first target splitting value of each driving attribute included in the first decision tree model and the order of the second target splitting value of each driving attribute included in the second decision tree model.
[0085] It can be understood that when the same driving attribute is in different decision orders in the first decision tree model and the second decision tree model respectively, the vehicle can also fuse the orders.
[0086] Specifically, the vehicle can determine the order of the fusion splitting value of each driving attribute according to the order of the first target splitting value of each driving attribute included in the first decision tree model and the order of the second target splitting value of each driving attribute included in the second decision tree model.
[0087] In a possible implementation, the specific fusion method is as follows in formula (5):
[0088] O f = (1 - β) * O o + β * O n ; Formula (5)
[0089] where O f is the order of the fusion splitting value, O o is the order of this driving attribute in the second decision tree model, O n is the order of this driving attribute in the first decision tree model, and β is the order fusion coefficient, which is a predetermined constant and determines the update speed of the order fusion algorithm.
[0090] S503. Determine the fusion lane-changing model according to the fusion splitting value of each driving attribute and the order of the fusion splitting value of each driving attribute.
[0091] Specifically, the vehicle can determine the fusion lane-changing model according to the fusion splitting value of each driving attribute and the order of the fusion splitting value of each driving attribute.
[0092] In addition, since the first decision tree model and the second decision tree model corresponding to different weather attributes are different, different fusion lane-changing models can be obtained corresponding to different weather attributes for making lane-changing decisions in the automatic driving scenario under different weather conditions.
[0093] Further, after determining the fusion lane-changing model, the vehicle can continue to obtain the lane-changing data of the vehicle in the manual driving scenario, and when the total data volume of the continuously obtained lane-changing data meets the preset conditions, determine a new first decision tree model according to the lane-changing data that meets the preset conditions, and determine a new fusion lane-changing model according to the new first decision tree model and the fusion lane-changing model. In this way, the fusion lane-changing model used by the vehicle during autonomous driving will be continuously optimized and updated as the manual driving process progresses, making the lane-changing decision-making style of the vehicle during autonomous driving increasingly close to the lane-changing decision-making style of manual driving, thereby continuously improving the "humanization" level of the vehicle's autonomous driving and enhancing the passenger experience during the vehicle's autonomous driving process.
[0094] In a possible implementation, when the total number of data groups of the continuously obtained lane-changing data meets the preset conditions, for example, when the number of data groups reaches M groups, the vehicle can determine a new first decision tree model according to the lane-changing data that meets the preset conditions.
[0095] In another possible implementation, when the size of the total data volume of the continuously obtained lane-changing data is higher than the preset data volume size, for example, when the size of the data volume is higher than 20Kb, the vehicle can determine a new first decision tree model according to the lane-changing data that meets the preset conditions.
[0096] In this embodiment, the vehicle determines the fusion splitting value of each driving attribute according to the first target splitting value of each driving attribute included in the first decision tree model and the second target splitting value of each driving attribute included in the pre-stored second decision tree model, determines the order of the fusion splitting value of each driving attribute according to the order of the first target splitting value of each driving attribute included in the first decision tree model and the order of the second target splitting value of each driving attribute included in the second decision tree model, and determines the fusion lane-changing model according to the fusion splitting value of each driving attribute and the order of the fusion splitting value of each driving attribute, thereby realizing the fusion of the first decision tree model and the second decision tree model. The fusion lane-changing model obtained based on this can make the decision-making style of the vehicle during autonomous lane-changing closer to the driving style of the vehicle during manual driving, thereby improving the "humanization" level of the vehicle's autonomous driving and enhancing the passenger experience during the vehicle's autonomous driving process.
[0097] Figure 6 Shows a schematic diagram of the composition of a possible vehicle lane-changing model construction device, as Figure 6 shown, the vehicle lane-changing model construction device may include an acquisition module 61, a first determination module 62, and a second determination module 63.
[0098] An acquisition module 61, configured to acquire M groups of lane-changing data of a vehicle in a manual driving scenario, where each group of lane-changing data is used to indicate data when the vehicle changes lanes each time, and each group of lane-changing data includes values of N driving attributes, and M and N are integers greater than 1.
[0099] A first determination module 62, configured to determine a first decision tree model according to the value of each driving attribute included in each group of lane-changing data acquired by the acquisition module 61 and the preset range corresponding to each driving attribute.
[0100] A second determination module 63, configured to determine a fusion lane-changing model according to the first decision tree model and a pre-stored second decision tree model; the fusion lane-changing model is used for lane-changing decision-making of the vehicle in an autonomous driving scenario.
[0101] Optionally, the second determination module 63 is specifically configured to: determine a fusion split value of each driving attribute according to the first target split value of each driving attribute included in the first decision tree model determined by the first determination module 62 and the second target split value of each driving attribute included in the pre-stored second decision tree model; determine the order of the fusion split value of each driving attribute according to the order of the first target split value of each driving attribute included in the first decision tree model and the order of the second target split value of each driving attribute included in the second decision tree model; determine the fusion lane-changing model according to the fusion split value of each driving attribute and the order of the fusion split value of each driving attribute.
[0102] Optionally, the first determination module 62 is specifically configured to: determine at least one split value of each driving attribute and the order of each split value of each driving attribute according to the value of each driving attribute included in each group of lane-changing data and the preset range corresponding to each driving attribute; determine the first decision tree model according to at least one split value of each driving attribute and the order of each split value of each driving attribute.
[0103] Optionally, the first determination module 62 is specifically configured to: when each driving attribute corresponds to a first target split value, determine the first decision tree model according to the first target split value of each driving attribute and the order of the first target split value of each driving attribute; when there is at least one driving attribute among the N driving attributes that corresponds to multiple split values, determine an initial decision tree model according to at least one split value of each driving attribute and the order of each split value of each driving attribute, and perform pruning processing on the initial decision tree model to obtain the first decision tree model, and the first target split value of each driving attribute included in the first decision tree model is one of at least one split value of the corresponding driving attribute.
[0104] Optionally, the first determination module 62 is specifically configured to: calculate the Gini coefficient of each alternative split value included in each driving attribute, determine at least one split value of each driving feature and the rank of each split value of each driving attribute according to the magnitudes of the Gini coefficients of each alternative split value included in each driving attribute.
[0105] Optionally, each group of lane change data further includes the value of the weather attribute, and the values of the weather attributes of the M groups of lane change data are the same; correspondingly, the second decision tree model is obtained under the condition of the value of the weather attribute of the M groups of lane change data.
[0106] Optionally, the obtaining module 61 is further configured to continue to obtain the lane change data of the vehicle in the manual driving scenario; the first determination module 62 is further configured to, when the total amount of the continuously obtained lane change data meets a preset condition, determine a new first decision tree model according to the lane change data that meets the preset condition; the second determination module 63 is further configured to determine a new fusion lane change model according to the new first decision tree model and the fusion lane change model.
[0107] Certainly, the apparatus for constructing a vehicle lane change model provided by the embodiments of the present invention includes but is not limited to the above modules.
[0108] The apparatus for constructing a vehicle lane change model provided by the embodiments of the present invention is used to execute the above-mentioned method for constructing a vehicle lane change model, and thus can achieve the same effect as the above-mentioned method for constructing a vehicle lane change model.
[0109] Another embodiment of the present invention further provides a lane change decision method, as Figure 7 shown, the lane change decision method includes:
[0110] S701. In the autonomous driving scenario, obtain the current target lane change data of the vehicle, where the target lane change data includes the value of the target weather attribute and the value of each target driving attribute among N target driving attributes, and N is an integer greater than 1.
[0111] S702. Determine the target fusion lane change model corresponding to the value of the target weather attribute, where the target fusion lane change model is obtained according to the first decision tree model and the pre-stored second decision tree model, and the first decision tree model is obtained according to M groups of lane change data of the vehicle in the manual driving scenario, and M is an integer greater than 1.
[0112] S703. According to the value of each target driving attribute, use the target fusion lane change model to determine whether the vehicle changes lanes.
[0113] In this embodiment, when the vehicle is in an autonomous driving scenario, it acquires the value of the target weather attribute and the value of each target driving attribute of the vehicle at present, determines the target fusion lane-changing model corresponding to the value of the target weather attribute, and determines whether the vehicle changes lanes by using the target fusion lane-changing model according to the value of each target driving attribute. Since the target fusion lane-changing model is obtained by fusing the first decision tree model and the second decision tree model under specific weather attributes, when the vehicle uses the target fusion lane-changing model to make lane-changing decisions, it can be closer to the lane-changing style when the vehicle is manually driven, thereby improving the "humanization" degree of the vehicle's autonomous driving and enhancing the experience of passengers during the vehicle's autonomous driving process.
[0114] Figure 8 FIG. shows a schematic composition diagram of a possible lane-changing decision device, as Figure 8 shown, the lane-changing decision device includes an acquisition module 81, a third determination module 82, and a decision module 83.
[0115] The acquisition module 81 is configured to acquire the current target lane-changing data of the vehicle in an autonomous driving scenario, where the target lane-changing data includes the value of the target weather attribute and the value of each target driving attribute among N target driving attributes, and N is an integer greater than 1;
[0116] The third determination module 82 is configured to determine the target fusion lane-changing model corresponding to the value of the target weather attribute acquired by the acquisition module 81. The target fusion lane-changing model is obtained according to the first decision tree model and the pre-stored second decision tree model. The first decision tree model is obtained according to M groups of lane-changing data of the vehicle in a manual driving scenario, and M is an integer greater than 1;
[0117] The decision module 83 is configured to determine whether the vehicle changes lanes by using the target fusion lane-changing model determined by the third determination module 82 according to the value of each target driving attribute acquired by the acquisition module 81.
[0118] Another embodiment of the present invention further provides a vehicle, which includes: a processor and a memory; the memory is used to store computer program code, and the computer program code includes computer instructions; when the processor executes the computer instructions, the vehicle executes the method for constructing a vehicle lane-changing model shown in the above method embodiment, or the lane-changing decision method shown in the above method embodiment.
[0119] Another embodiment of the present invention further provides a computer-readable storage medium, in which computer instructions are stored. When the computer instructions run on a computer device, the computer device is caused to execute each step executed by the computer device in the method flow shown in the above method embodiment.
[0120] Another embodiment of the present invention further provides a computer program product, which includes computer instructions. When the computer instructions run on a computer device, the computer device is caused to execute each step performed by the computer device in the method flow shown in the above method embodiment.
[0121] As described above, the above are only specific embodiments of the present invention, but the protection scope of the present invention is not limited thereto. Any changes or substitutions within the technical scope disclosed by the present invention should be covered within the protection scope of the present invention. Therefore, the protection scope of the present invention should be subject to the protection scope of the claims.
Claims
1. A method for constructing a vehicle lane-changing model, characterized in that, Including: Obtain M groups of lane-changing data of the vehicle in the manual driving scenario, where each group of lane-changing data is used to indicate the data when the vehicle changes lanes each time, and each group of lane-changing data includes values of N driving attributes, and M and N are integers greater than 1; Determine a first decision tree model according to the value of each driving attribute included in each group of lane-changing data and the preset range corresponding to each driving attribute; Determine a fusion lane-changing model according to the first decision tree model and a pre-stored second decision tree model; The fusion lane-changing model is used for the lane-changing decision of the vehicle in the automatic driving scenario.
2. The method for constructing a vehicle lane-changing model according to claim 1, wherein The determining the fusion lane-changing model according to the first decision tree model and the pre-stored second decision tree model includes: Determine the fusion split value of each driving attribute according to the first target split value of each driving attribute included in the first decision tree model and the second target split value of each driving attribute included in the pre-stored second decision tree model; Determine the order of the fusion split value of each driving attribute according to the order of the first target split value of each driving attribute included in the first decision tree model and the order of the second target split value of each driving attribute included in the second decision tree model; Determine the fusion lane-changing model according to the fusion split value of each driving attribute and the order of the fusion split value of each driving attribute.
3. The method for constructing a vehicle lane-changing model according to claim 1 or 2, characterized in that, The determining the first decision tree model according to the value of each driving attribute included in each group of lane-changing data and the preset range corresponding to each driving attribute includes: Determine at least one split value of each driving attribute and the order of each split value of each driving attribute according to the value of each driving attribute included in each group of lane-changing data and the preset range corresponding to each driving attribute; Determine the first decision tree model according to at least one split value of each driving attribute and the order of each split value of each driving attribute.
4. The method for constructing a vehicle lane change model according to claim 3, wherein The determining the first decision tree model according to at least one split value of each driving attribute and the order of each split value of each driving attribute includes: When each driving attribute corresponds to a first target split value, determine the first decision tree model according to the first target split value of each driving attribute and the order of the first target split value of each driving attribute; When there is at least one driving attribute among the N driving attributes corresponding to multiple split values, determine an initial decision tree model according to at least one split value of each driving attribute and the order of each split value of each driving attribute, and perform pruning processing on the initial decision tree model to obtain the first decision tree model, and the first target split value of each driving attribute included in the first decision tree model is one of at least one split value of the corresponding driving attribute.
5. The method for constructing a vehicle lane-changing model according to claim 3, wherein The determining at least one split value of each driving attribute and the order of each split value of each driving attribute according to the value of each driving attribute included in each group of lane-changing data and the preset range corresponding to each driving attribute includes: Determine multiple alternative split values corresponding to each driving attribute according to the preset range corresponding to each driving attribute and a pre-stored split algorithm; Calculate the Gini coefficient of each alternative split value corresponding to each driving attribute according to the value of each driving attribute included in each set of lane change data; Determine at least one split value of each driving attribute and the ordinal number of each split value of each driving attribute according to the magnitude of the Gini coefficient of each alternative split value corresponding to each driving attribute.
6. The method for constructing a vehicle lane change model according to claim 1 or 2, characterized in that Each set of lane change data further includes the value of the weather attribute, and the values of the weather attributes of the M sets of lane change data are the same; Correspondingly, the second decision tree model is obtained under the condition of the value of the weather attribute of the M sets of lane change data.
7. The method for constructing a vehicle lane-changing model according to claim 1 or 2, characterized in that After determining the fusion lane change model, the method for constructing the vehicle lane change model further includes: Continuously obtain the lane change data of the vehicle in the manual driving scenario; When the total data volume of the continuously obtained lane change data meets a preset condition, determine a new first decision tree model according to the lane change data that meets the preset condition; Determine a new fusion lane change model according to the new first decision tree model and the fusion lane change model.
8. An apparatus for constructing a vehicle lane change model, characterized in that, The device for constructing the vehicle lane change model includes: An acquisition module, configured to acquire M sets of lane change data of the vehicle in the manual driving scenario, each set of lane change data is used to indicate the data of the vehicle each time it changes lanes, and each set of lane change data includes the values of N driving attributes, where M and N are integers greater than 1; A first determination module, configured to determine a first decision tree model according to the value of each driving attribute included in each set of lane change data acquired by the acquisition module and the preset range corresponding to each driving attribute; A second determination module, configured to determine a fusion lane change model according to the first decision tree model determined by the first determination module and a pre-stored second decision tree model; the fusion lane change model is used for the lane change decision of the vehicle in the autonomous driving scenario.
9. A lane-changing decision-making method, characterized in that, Includes: In the autonomous driving scenario, acquire the current target lane change data of the vehicle, where the target lane change data includes the value of the target weather attribute and the value of each target driving attribute among N target driving attributes, and N is an integer greater than 1; Determine a target fusion lane change model corresponding to the value of the target weather attribute, where the target fusion lane change model is obtained according to a first decision tree model and a pre-stored second decision tree model, and the first decision tree model is obtained according to M sets of lane change data of the vehicle in the manual driving scenario, and M is an integer greater than 1; According to the value of each target driving attribute, use the target fusion lane change model to determine whether the vehicle changes lanes.
10. A lane change decision-making device, characterized in that, Includes: An acquisition module, configured to acquire the current target lane change data of the vehicle in the autonomous driving scenario, where the target lane change data includes the value of the target weather attribute and the value of each target driving attribute among N target driving attributes, and N is an integer greater than 1; A third determination module, configured to determine a target fusion lane change model corresponding to the value of the target weather attribute acquired by the acquisition module, where the target fusion lane change model is obtained according to a first decision tree model and a pre-stored second decision tree model, and the first decision tree model is obtained according to M sets of lane change data of the vehicle in the manual driving scenario, and M is an integer greater than 1; A decision-making module, configured to determine whether the vehicle changes lanes according to the values of each target driving attribute obtained by the obtaining module and by using the target fusion lane-changing model determined by the third determination module.
11. A vehicle, characterized in that, The vehicle includes: a processor and a memory; the memory is configured to store computer program code, and the computer program code includes computer instructions; when the processor executes the computer instructions, the vehicle executes the method for constructing a vehicle lane-changing model according to any one of claims 1-7, or executes the lane-changing decision-making method according to claim 9.
12. A computer-readable storage medium, characterized in that, It includes computer instructions, and when the computer instructions run on a computer device, the computer device is caused to execute the method for constructing a vehicle lane-changing model according to any one of claims 1-7, or execute the lane-changing decision-making method according to claim 9.
Citation Information
Patent Citations
Vehicle lane changing auxiliary method and system and vehicle
CN108639048A
Automobile driving mode self-adaptive matching method
CN113954855A