Training method of driving environment model and prediction method of driving environment information

By constructing multiple parallel single models and randomly sampling training samples to calculate the difference in prediction results, the problem of real data acquisition in driving environment model training is solved, and efficient and accurate model training is achieved.

CN114818484BActive Publication Date: 2024-09-27TSINGHUA UNIVERSITY
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210401858.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-04-18
Publication Date
2024-09-27
Estimated Expiration
2042-04-18

AI Technical Summary

Technical Problem

In the existing technology, the training process of the driving environment model requires a large amount of real driving data, especially the data of dangerous and extreme driving scenes, which is difficult to obtain, resulting in high costs.

Method used

Multiple parallel single models are constructed. The initial parameters of each single model are different. The training sample set is obtained through random sampling and the model is trained. The difference of the prediction results is calculated. If it is less than the preset threshold, it is determined to be a driving environment model. Reduce the use of real driving data.

Benefits of technology

It effectively saves the usage of real driving data, improves the training efficiency and accuracy of the driving environment model, and reduces costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114818484B
    Figure CN114818484B
Patent Text Reader

Abstract

The present application relates to a method and device for training a driving environment model, a method and device for predicting driving environment information, a computer device, a storage medium and a computer program product. The method comprises: constructing an initial environment model, the initial environment model comprising a plurality of monomer models; obtaining a training sample set corresponding to each monomer model, and training the corresponding monomer model through each training sample set to obtain a trained environment model; inputting a test sample into the trained environment model to obtain the driving environment prediction information of the next moment corresponding to each trained monomer model; the test sample comprises the driving environment sample information of the current moment and the current decision action sample information; calculating the difference of the driving environment prediction information of each next moment, and determining the trained environment model as the driving environment model when the difference is less than a preset threshold. The use of this method can save the use of real driving data in the process of training the driving environment model.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of intelligent vehicle technology, and in particular to a method and device for training a driving environment model, a method and device for predicting driving environment information, a computer device, a storage medium, and a computer program product. Background Art

[0002] With the application of artificial intelligence technology in the field of intelligent transportation and vehicles, intelligent vehicles have gradually entered people's field of vision. Generally speaking, the autonomous driving software system of intelligent vehicles can be divided into four modules: perception, positioning, decision-making and control. Among them, the decision-making module is equivalent to the brain of the intelligent vehicle, which plays a vital role in realizing high-level autonomous driving and even unmanned driving.

[0003] Since the cost of testing and training the decision-making algorithm in a real environment is high, it is generally combined with testing and training using a driving environment model in a virtual environment. The driving environment model can predict the driving environment information of the target vehicle after executing the current decision action (i.e., obtaining the predicted driving environment information at the next moment) based on the current driving environment information (such as the target vehicle's own driving state information, other vehicles, pedestrians, traffic lights, road conditions, etc. in the driving environment) and the current decision action information of the target vehicle (such as changing lanes, braking, turning, etc.), so as to generate the simulation environment at the next moment based on the predicted information, or directly determine whether an accident such as a collision occurs based on the predicted information, so as to test whether the decision-making algorithm of the target vehicle is safe and reliable.

[0004] Since the prediction results of the driving environment model directly affect the testing and training effects of the decision-making algorithm, the prediction accuracy of the driving environment model is very important. In the related technology, in order to ensure the prediction accuracy of the driving environment model, a large amount of real driving data is required in the training process of the driving environment model. However, it is difficult to obtain real driving data and the acquisition cost is high, especially for dangerous driving, extreme driving and other scenes. It is urgent to have a training method for a driving environment model that can save the use of real driving data. Summary of the invention

[0005] Based on this, it is necessary to provide a training method and device for a driving environment model, a prediction method and device for driving environment information, a computer device, a computer-readable storage medium and a computer program product that can save the use of real driving data in response to the above-mentioned technical problems.

[0006] In a first aspect, the present application provides a method for training a driving environment model. The method comprises:

[0007] Constructing an initial environment model, wherein the initial environment model includes a plurality of parallel monomer models with the same structure, and each of the monomer models has different initial parameters;

[0008] Acquire a training sample set corresponding to each of the monomer models, and train the corresponding monomer model through each of the training sample sets to obtain a trained environment model; each training sample in the training sample set includes driving environment sample information at the current moment, current decision action sample information, and driving environment sample information at the next moment;

[0009] Inputting the test sample into the trained environment model to obtain the driving environment prediction information at the next moment corresponding to each trained single model; the test sample includes the driving environment sample information at the current moment and the current decision action sample information;

[0010] The difference of the driving environment prediction information at each of the next moments is calculated, and when the difference is less than a preset threshold, the trained environment model is determined as the driving environment model.

[0011] In one embodiment, the obtaining of the training sample sets corresponding to the individual models includes:

[0012] Obtain an initial training sample set;

[0013] For each of the monomer models, the initial training sample set is randomly sampled with replacement, and a set consisting of a preset number of training samples obtained by sampling is determined as the training sample set corresponding to the monomer model.

[0014] In one embodiment, the calculating the difference of the driving environment prediction information at each next moment includes:

[0015] The variance is calculated according to the driving environment prediction information at each next moment, and the obtained variance value is determined as the difference degree.

[0016] In one of the embodiments, the training sample set includes training samples corresponding to multiple driving scene types;

[0017] The step of inputting the test sample into the trained environment model to obtain the driving environment prediction information at the next moment corresponding to each trained monomer model includes:

[0018] For each of the driving scene types, input the test sample corresponding to the driving scene type into the trained environment model to obtain the driving environment prediction information at the next moment corresponding to each trained single model;

[0019] The calculating the difference of the driving environment prediction information at each of the next moments, and determining the trained environment model as the driving environment model when the difference is less than a preset threshold, comprises:

[0020] For each of the driving scene types, the difference of the driving environment prediction information at each next moment under the driving scene type is calculated, and when the difference is less than a preset threshold, the trained environment model is determined as the driving environment model corresponding to the driving scene type.

[0021] In a second aspect, the present application also provides a method for predicting driving environment information. The method comprises:

[0022] Obtain the current driving environment information and current decision action information;

[0023] The driving environment information at the next moment is predicted based on the driving environment information at the current moment, the current decision action information, and the driving environment model; wherein the driving environment model is trained by the training method of the driving environment model described in the first aspect.

[0024] In one embodiment, the driving environment model includes a plurality of monomer models; predicting the driving environment information at the next moment according to the driving environment information at the current moment, the current decision action information, and the driving environment model includes:

[0025] Inputting the current driving environment information and the current decision action information into a driving environment model to obtain driving environment prediction information at the next moment corresponding to each monomer model included in the driving environment model;

[0026] According to each of the driving environment prediction information at the next moment and a preset reward function, a reward value of each of the driving environment prediction information at the next moment is calculated, and the driving environment prediction information at the next moment with the smallest reward value is determined as the driving environment information at the next moment.

[0027] In a third aspect, the present application also provides a training device for a driving environment model. The device comprises:

[0028] A construction module, used for constructing an initial environment model, wherein the initial environment model comprises a plurality of parallel monomer models with the same structure, and each monomer model has different initial parameters;

[0029] A training module, used to obtain a training sample set corresponding to each of the monomer models, and train the corresponding monomer model through each of the training sample sets to obtain a trained environment model; each training sample in the training sample set includes driving environment sample information at the current moment, current decision action sample information, and driving environment sample information at the next moment;

[0030] A testing module, used to input a test sample into the trained environment model to obtain the driving environment prediction information at the next moment corresponding to each trained monomer model; the test sample includes the driving environment sample information at the current moment and the current decision action sample information;

[0031] The calculation module is used to calculate the difference of the driving environment prediction information at each next moment, and when the difference is less than a preset threshold, determine the trained environment model as the driving environment model.

[0032] In one embodiment, the training module is specifically used for:

[0033] Obtain an initial training sample set; for each of the monomer models, perform random sampling with replacement on the initial training sample set, and determine a set consisting of a preset number of training samples obtained by sampling as the training sample set corresponding to the monomer model.

[0034] In one embodiment, the computing module is specifically used for:

[0035] The variance is calculated according to the driving environment prediction information at each next moment, and the obtained variance value is determined as the difference degree.

[0036] In one embodiment, the training sample set includes training samples corresponding to multiple driving scene types; and the test module is specifically used for:

[0037] For each of the driving scene types, input the test sample corresponding to the driving scene type into the trained environment model to obtain the driving environment prediction information at the next moment corresponding to each trained single model;

[0038] The calculation module is specifically used for:

[0039] For each of the driving scene types, the difference of the driving environment prediction information at each next moment under the driving scene type is calculated, and when the difference is less than a preset threshold, the trained environment model is determined as the driving environment model corresponding to the driving scene type.

[0040] In a fourth aspect, the present application also provides a driving environment information prediction device. The device comprises:

[0041] An acquisition module is used to obtain the current driving environment information and current decision action information;

[0042] A prediction module is used to predict the driving environment information at the next moment based on the driving environment information at the current moment, the current decision action information, and the driving environment model; wherein the driving environment model is trained by the training method of the driving environment model described in the first aspect.

[0043] In one embodiment, the driving environment model includes a plurality of monomer models; and the prediction module is specifically used for:

[0044] The driving environment information at the current moment and the current decision action information are input into the driving environment model to obtain the driving environment prediction information at the next moment corresponding to each monomer model contained in the driving environment model; based on each driving environment prediction information at the next moment and a preset reward function, the reward value of each driving environment prediction information at the next moment is calculated, and the driving environment prediction information at the next moment with the smallest reward value is determined as the driving environment information at the next moment.

[0045] In a fifth aspect, the present application further provides a computer device, wherein the computer device comprises a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the steps of the method described in the first aspect or the second aspect are implemented.

[0046] In a sixth aspect, the present application further provides a computer-readable storage medium, wherein a computer program is stored thereon, and when the computer program is executed by a processor, the steps of the method described in the first aspect or the second aspect are implemented.

[0047] In a seventh aspect, the present application further provides a computer program product, wherein the computer program product comprises a computer program, and when the computer program is executed by a processor, the steps of the method described in the first aspect or the second aspect are implemented.

[0048] The training method and device of the driving environment model, the prediction method and device of the driving environment information, the computer device, the storage medium and the computer program product are constructed by constructing an initial environment model including multiple monomer models, wherein the structures of the monomer models are the same but the initial parameters are different, and then the training sample sets corresponding to the monomer models are used to train the monomer models respectively, and then the test samples are input into the trained environment model, so that the trained monomer models process the test samples respectively, and the prediction results corresponding to the trained monomer models (i.e., the driving environment prediction information at the next moment) are obtained, and then the difference of each prediction result is calculated. If the difference is less than a preset threshold, the trained environment model is determined as the target driving environment model. In this method, the test samples used only need to include the driving environment information and the current decision action information at the current moment. Therefore, the test samples can use customized driving data, thereby saving the use of real driving data in the process of training the driving environment model. BRIEF DESCRIPTION OF THE DRAWINGS

[0049] Figure 1 is a flowchart of a method for training a driving environment model in one embodiment;

[0050] Figure 2 A schematic diagram of a process for obtaining a training sample set corresponding to each monomer model in an embodiment;

[0051] Figure 3 is a schematic flow chart of a method for predicting driving environment information in one embodiment;

[0052] Figure 4 is a structural diagram of a driving environment model in an example;

[0053] Figure 5 is a structural block diagram of a training device for a driving environment model in one embodiment;

[0054] Figure 6 is a structural block diagram of a device for predicting driving environment information in one embodiment;

[0055] Figure 7 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION

[0056] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0057] First, before specifically introducing the technical solution of the embodiment of the present application, the technical background or technical evolution context based on the embodiment of the present application is introduced. In the related art, in order to ensure the prediction accuracy of the driving environment model, a large amount of real driving data is needed in the training process of the driving environment model. For example, in the training process of the model, real driving data is generally collected as a sample set, and then the sample set is divided into a training sample set and a test sample set. The model is first trained using the training sample set to fit the model parameters, and then the accuracy of the trained model is evaluated using the test sample set. Specifically, the prediction accuracy is calculated according to the prediction result of the model and the target value (true value) in the test sample. If the expected accuracy is achieved, the model is considered to have been trained. If the expected accuracy is not achieved, the sample in the training sample set or the hyperparameter of the model needs to be changed and retrained. However, it is difficult to obtain real driving data and the acquisition cost is high, especially the real driving data of dangerous driving, extreme driving and other scenes is difficult to obtain. Based on this background, the applicant has proposed a training method for the driving environment model of the present application through long-term research and development and experimental verification, which can save the use of real driving data in the process of training the driving environment model. In addition, it should be noted that the applicant has devoted a lot of creative work to the discovery of the technical problem of the present application and the technical solutions introduced in the following embodiments.

[0058] The training method of the driving environment model provided in the embodiment of the present application can be applied to a terminal, a server, or a system including a terminal and a server, and implemented through the interaction between the terminal and the server. Among them, the terminal can be, but is not limited to, various personal computers, laptops, smart phones, tablet computers, Internet of Things devices, portable wearable devices, etc. The server can be implemented with an independent server or a server cluster consisting of multiple servers.

[0059] In one embodiment, Figure 1 As shown, a training method for a driving environment model is provided, and the method is applied to a terminal as an example for explanation, including the following steps:

[0060] Step 101: construct an initial environment model.

[0061] The initial environment model includes multiple parallel monomer models with the same structure, and the initial parameters of each monomer model are different.

[0062] In implementation, the terminal can construct multiple parallel monomer models with the same structure and parameters to form an initial environment model. For example, a monomer model can be constructed based on a graph neural network. Among them, the initial parameters of each monomer model are different. For example, the terminal can initialize each weight in the graph neural network, and the initial value of each weight can be sampled from a preset random distribution. The number of monomer models can be flexibly set according to actual conditions, and it can be greater than 2, and can be 6 to 10.

[0063] Step 102, obtaining the training sample sets corresponding to the individual models, and training the corresponding individual models through the training sample sets to obtain the trained environment model.

[0064] Each training sample in the training sample set includes the driving environment sample information at the current moment, the current decision action sample information, and the driving environment sample information at the next moment. Each training sample can be real driving data collected when the vehicle is driving in a real driving environment, or can be obtained and processed from an existing real driving database.

[0065] The driving environment sample information at the current moment includes the driving state information of the vehicle itself, such as the current position, speed, vehicle type, etc., as well as the state information of other elements in the driving environment at the current moment, including the driving state information of other vehicles around the vehicle, pedestrian state information, traffic light state information, etc. The current decision action sample information is the decision action made by the vehicle based on the driving environment sample information at the current moment, such as turning, deceleration, lane change, braking, etc. The driving environment sample information at the next moment is the driving environment information after the vehicle executes the current decision action, including the driving state information of the vehicle itself and the state information of other elements in the driving environment.

[0066] In implementation, the terminal can obtain the training sample set corresponding to each monomer model. For example, the collected training samples can be stored in a data set, and the terminal can directly obtain the data set as the training sample set corresponding to each monomer model, or the data set can be sampled to obtain the training sample set corresponding to each monomer model. Then, the terminal can train the corresponding monomer model through each training sample set, and when the preset training conditions are met, the trained environment model is obtained.

[0067] Step 103 , input the test sample into the trained environment model to obtain the driving environment prediction information at the next moment corresponding to each trained single model.

[0068] The test sample includes the current driving environment sample information and the current decision action sample information. It is understandable that since the test sample only needs to include the current driving data, the test sample can be the real driving data collected, the driving data defined by the user, or the driving data randomly generated according to the preset rules, which can be flexibly set according to the actual situation.

[0069] In this embodiment, the terminal can obtain a test sample. For example, the terminal can randomly sample from a pre-stored test sample set to obtain a test sample, or the user can input the current driving environment sample information and the current decision action sample information in the terminal as a test sample. Then, the terminal can input the test sample into the trained environmental model, and process the test sample through each monomer model (which is a trained monomer model) contained in the environmental model to obtain the driving environment prediction information of the next moment corresponding to each monomer model. If the number of monomer models is n, then n driving environment prediction information of the next moment can be obtained (which can be recorded as s′1, s′2, s′3…s′ n ).

[0070] Step 104 , calculating the difference between the driving environment prediction information at each next moment, and when the difference is less than a preset threshold, determining the trained environment model as the driving environment model.

[0071] In implementation, the terminal can calculate the difference of the driving environment prediction information at each next moment according to the driving environment prediction information at each next moment. The difference can represent the degree of difference of each driving environment prediction information. Then, the terminal can compare the calculated difference with the preset threshold. If the difference is less than the preset threshold, it can be considered that the trained environment model has achieved the expected prediction accuracy, and the trained environment model can be determined as the target driving environment model. If the difference is greater than or equal to the preset threshold, it can be considered that the trained environment model has not achieved the expected effect, cannot be directly used as a driving environment model, and needs to be retrained. It can be understood that a test sample can be used to test the trained environment model, and the difference corresponding to the test sample can be compared with the preset threshold. It can also be tested using multiple test samples, and then the mean is calculated based on the difference corresponding to the multiple test samples, and the mean is used as the final difference to compare with the preset threshold.

[0072] In the above-mentioned training method of the driving environment model, an initial environment model including multiple monomer models is constructed, and the training sample set corresponding to each monomer model is used for training. Then, the test sample is input into the trained environment model to obtain the prediction results of each trained monomer model (i.e., the driving environment prediction information at the next moment). The prediction effect of the environment model is evaluated according to the difference between each prediction result. Among them, the test sample only needs to include the driving environment information and the current decision action information at the current moment, and there is no need to calculate the prediction accuracy through the true value and predicted value of the test sample. Therefore, the test sample can use customized driving data, thereby saving the use of real driving data in the process of training the driving environment model.

[0073] In one embodiment, Figure 2 As shown, the process of obtaining the training sample set corresponding to each monomer model in step 102 specifically includes the following steps:

[0074] Step 201: Obtain an initial training sample set.

[0075] In implementation, each collected training sample may be stored in a data set in advance, and the terminal may obtain the data set as an initial training sample set.

[0076] Step 202: For each single model, perform random sampling with replacement on the initial training sample set, and use a set consisting of a preset number of training samples obtained by sampling as the training sample set corresponding to the single model.

[0077] In implementation, for each monomer model, the terminal can perform random sampling with replacement on the initial training sample set obtained in step 201, and use the set of sampled training samples as the training sample set corresponding to the monomer model. The number of samples is a preset value, which can be consistent with the number of samples included in the initial training sample set, or a certain proportion of the number of samples included in the initial training sample set (such as 80%, 90%, etc.). For example, if the initial training sample set contains K training samples and the number of samples is K, the terminal can perform independent (i.e., with replacement) random sampling K times from the initial training sample set to obtain K training samples as the training sample set corresponding to a monomer model. If the number of monomer models is n, the terminal can repeat the aforementioned sampling process n times to obtain n training sample sets, and one training sample set corresponds to one monomer model.

[0078] In this embodiment, the training sample set corresponding to each monomer model is obtained by random sampling with replacement from the initial training sample set. The training samples contained in each training sample set are not completely the same, but have a strong correlation. The difference in the prediction results of each monomer model of the environmental model trained by each training sample set can more accurately reflect the prediction effect or training effect of the environmental model, and then the driving environment model determined according to the difference can ensure that it has the expected prediction accuracy, that is, this method can take into account both the saving of the use of real driving data and the prediction accuracy of the driving environment model.

[0079] In one embodiment, the process of calculating the difference in step 104 specifically includes: calculating the variance according to the driving environment prediction information at each next moment, and determining the obtained variance value as the difference.

[0080] In implementation, the terminal can obtain the n (consistent with the number of single models) driving environment prediction information (s′1, s′2, s′3…s′) of the next moment according to step 103. n ), calculate the variance of the driving environment prediction information at each next moment, and calculate the variance value (which can be recorded as S 2 ) as the difference. In one example, the formula for calculating the variance is as follows:

[0081]

[0082] in, That is, the mean of the driving environment prediction information at each next moment.

[0083] In one embodiment, the training sample set includes training samples corresponding to multiple driving scene types. The process of obtaining the driving environment prediction information at each next moment in step 103 specifically includes: for each driving scene type, inputting the test sample corresponding to the driving scene type into the trained environment model to obtain the driving environment prediction information at the next moment corresponding to each trained single model.

[0084] Correspondingly, the process of determining the driving environment model in step 104 specifically includes: for each driving scene type, calculating the difference of the driving environment prediction information at each next moment under the driving scene type, and when the difference is less than a preset threshold, determining the trained environment model as the driving environment model corresponding to the driving scene type.

[0085] In implementation, driving scenes can be classified, and specific classification standards can refer to the classification standards commonly used in the field or define classification standards by themselves, such as classification according to the degree of danger, which can be divided into normal driving scenes, problem driving scenes, extreme driving scenes, etc., and classification according to the typical state of environmental elements, which can be divided into sunny day-few pedestrians-normal traffic driving scenes, sunny day-many pedestrians-traffic congestion driving scenes, snowy days-few pedestrians-front fault driving scenes, etc. In order to ensure safe driving, the test of intelligent vehicles should cover various possible driving scenes. Therefore, it is theoretically expected that the driving environment model can make accurate predictions in various driving scenes. Therefore, in the training process of the driving environment model, training samples covering multiple driving scene types are generally used for training. The training sample set used in this embodiment includes training samples corresponding to multiple driving scene types. Accordingly, test samples corresponding to each driving scene type can be set to respectively evaluate the prediction effect of the trained environment model under each driving scene type.

[0086] For each driving scene type, the terminal can input the test sample corresponding to the driving scene type into the trained environment model to obtain the driving environment prediction information for the next moment corresponding to each monomer model. Then, the terminal can calculate the difference of the driving environment prediction information for each next moment under the driving scene type. If the difference is less than the preset threshold, the trained environment model can be determined as the driving environment model corresponding to the driving scene type. If the difference is greater than or equal to the preset threshold, it means that the trained environment model cannot make accurate predictions under the driving scene type and should not be used directly as the driving environment model corresponding to the driving scene type. You can increase the training samples of the corresponding driving scene type or modify the hyperparameters of the model and retrain.

[0087] In this embodiment, the prediction effect of the trained environment model under each driving scene type is evaluated respectively through the test samples corresponding to each driving scene type. If the prediction effect under a certain driving scene type reaches the expected value (the difference between the prediction results of each monomer model is less than the preset threshold), the trained environment model can be used as the driving environment model corresponding to the driving scene type. Thus, the driving environment model with high prediction accuracy under the driving scene can be used in a targeted manner for different test scenes to ensure the test effect and training effect of the intelligent vehicle. In addition, since the test samples used in this method can be customized driving data, test samples under various driving scene types can be easily obtained to improve the overall efficiency of model training.

[0088] The embodiment of the present application also provides a method for predicting driving environment information, which can be used to predict driving environment information of a virtual environment, such as for an autonomous driving simulation test simulator, which can generate and display a simulated environment based on the driving environment information predicted by the method to achieve testing and training of a target vehicle in a virtual environment; it can also be used to predict driving environment information of a real environment, such as for an autonomous driving software system of a target vehicle, when the target vehicle is driving in a real driving environment, it can determine a target decision action based on the driving environment information predicted by the method to achieve safe driving. This embodiment is explained by taking the application of this method to a terminal as an example, such as Figure 3 As shown, the method comprises the following steps:

[0089] Step 301, obtaining the current driving environment information and current decision action information.

[0090] In implementation, the terminal can obtain the current driving environment information and current decision action information. The current driving environment information is the status information of each element in the driving environment where the target vehicle is located, including the status information of the target vehicle itself, other vehicles around the target vehicle, pedestrians, traffic lights and other elements.

[0091] For the application scenario of autonomous driving simulation test (such as for simulation test simulator), if the current moment is the initial moment of the test, the driving environment information at the current moment can be input by the user or selected in the database, or the terminal can randomly select the driving environment information at the current moment from the pre-stored database. The current decision action information is the decision action (executed decision action) made by the target vehicle based on the driving environment information at the current moment.

[0092] For the application scenarios of the autonomous driving software system, the current driving environment information can be collected by the sensors of the target vehicle. The current decision action information can be one of multiple executable decision action information (decision actions that have not yet been executed), and each executable decision action can be used as the current decision action information one by one, so as to compare the driving environment information at the next moment corresponding to each decision action, and then determine the decision action finally executed by the target vehicle.

[0093] Step 302 , predicting the driving environment information at the next moment based on the driving environment information at the current moment, the current decision action information, and the driving environment model.

[0094] The driving environment model is obtained by training the driving environment model using the training method mentioned above. In one example, the structure of the driving environment model is as follows: Figure 4 As shown, it includes n parallel monomer models.

[0095] In implementation, the terminal can predict the driving environment information after the target vehicle executes the current decision action information (i.e., the driving environment information at the next moment) based on the current driving environment information, the current decision action information, and the driving environment model. For example, the terminal can input the current driving environment information (which can be recorded as s) and the current decision action information (which can be recorded as a) into Figure 4 The driving environment model shown in the figure processes the input data through each monomer model contained in the driving environment model, and outputs the driving environment prediction information (s′1, s′2, s′2…s′) of the next moment corresponding to each monomer model. n Then, the terminal may select a piece of driving environment prediction information according to a preset selection strategy (such as random selection) as the driving environment information at the next moment, or may perform mean calculation or other processing on each piece of driving environment prediction information to obtain the driving environment information at the next moment.

[0096] It can be understood that if the simulation test continues, the driving environment information at the next moment can be used as the new driving environment information at the current moment, and the process returns to step 301 .

[0097] In this embodiment, the driving environment information at the next moment is predicted through the driving environment information at the current moment, the current decision action information, and the driving environment model. During the model training process, the test samples used in the driving environment model only need to include the driving environment information at the current moment and the current decision action information. Therefore, the training process of the driving environment model can use customized driving data to save the use of real driving data, and it is more efficient and less costly than collecting real driving data, thereby improving the overall efficiency of predicting driving environment information and reducing the overall cost.

[0098] Furthermore, in the simulation test application scenario, when this method is used to predict the driving environment information at the next moment, the difference in the prediction results of each individual model can also be calculated. If the difference is low, it can be determined that the prediction information this time (that is, the driving environment information obtained at the next moment) is highly accurate and the test result is highly credible; if the difference is large, a marking reminder can be used so that the user can understand the actual situation of the simulation test.

[0099] In one embodiment, the process of predicting the driving environment information at the next moment in step 302 specifically includes: inputting the driving environment information at the current moment and the current decision action information into the driving environment model to obtain the driving environment prediction information at the next moment corresponding to each monomer model contained in the driving environment model; calculating the reward value of each driving environment prediction information at the next moment according to the driving environment prediction information at each next moment and a preset reward function, and determining the driving environment prediction information at the next moment with the smallest reward value as the driving environment information at the next moment.

[0100] In implementation, the terminal can input the current driving environment information and the current decision action information into the driving environment model to obtain the driving environment prediction information of the next moment corresponding to each monomer model contained in the driving environment model. Then, the terminal can calculate the reward value of the driving environment prediction information of each next moment according to the driving environment prediction information of each next moment and the preset reward function. The reward value can represent the degree of danger or safety of the driving environment. The smaller the reward value, the higher the degree of danger. For example, the terminal can determine whether the target vehicle has an accident such as a collision with other elements in the driving environment based on the driving environment prediction information of the next moment. The preset reward function can be: if a collision occurs, the reward value is -1, and if no collision occurs, the reward value is 0. Furthermore, multiple levels of reward values ​​can be set according to the severity of the collision. The more serious the collision, the smaller the reward value.

[0101] Then, the terminal may determine the driving environment prediction information of the next moment with the smallest reward value as the driving environment information of the next moment. It is understandable that if there are multiple driving environment prediction information with the smallest reward value, one of the multiple driving environment prediction information may be randomly selected as the driving environment information of the next moment, or other processing such as average calculation may be performed to obtain the driving environment information of the next moment.

[0102] In this embodiment, the driving environment prediction information with the smallest reward value is determined as the driving environment information at the next moment, that is, the prediction result with the highest degree of danger among the prediction results of each single model is used as the driving environment information at the next moment. Therefore, when this method is used to test or train the automatic driving decision algorithm, the automatic driving driving decision can avoid dangerous driving to the greatest extent, that is, the safety and reliability of the decision algorithm is improved.

[0103] It should be understood that, although the various steps in the flowcharts involved in the above-mentioned embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments can include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.

[0104] Based on the same inventive concept, the embodiment of the present application also provides a training device for a driving environment model for implementing the training method for the driving environment model involved above. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in the embodiments of the training device for one or more driving environment models provided below can refer to the limitations of the training method for the driving environment model above, and will not be repeated here.

[0105] In one embodiment, Figure 5 As shown, a training device 500 for a driving environment model is provided, comprising: a construction module 501, a training module 502, a testing module 503 and a calculation module 504, wherein:

[0106] The construction module 501 is used to construct an initial environment model. The initial environment model includes multiple parallel monomer models with the same structure, and the initial parameters of each monomer model are different.

[0107] The training module 502 is used to obtain the training sample sets corresponding to each monomer model, and train the corresponding monomer model through each training sample set to obtain the trained environment model; each training sample in the training sample set contains the driving environment sample information at the current moment, the current decision action sample information, and the driving environment sample information at the next moment.

[0108] The test module 503 is used to input the test sample into the trained environment model to obtain the driving environment prediction information at the next moment corresponding to each trained single model; the test sample includes the driving environment sample information at the current moment and the current decision action sample information.

[0109] The calculation module 504 is used to calculate the difference of the driving environment prediction information at each next moment, and when the difference is less than a preset threshold, determine the trained environment model as the driving environment model.

[0110] In one embodiment, the training module 502 is specifically used to: obtain an initial training sample set; for each monomer model, perform random sampling with replacement on the initial training sample set, and determine a set consisting of a preset number of training samples obtained by sampling as the training sample set corresponding to the monomer model.

[0111] In one embodiment, the calculation module 504 is specifically used to calculate the variance according to the driving environment prediction information at each next moment, and determine the obtained variance value as the difference degree.

[0112] In one embodiment, the training sample set includes training samples corresponding to multiple driving scene types. The test module 503 is specifically used to: for each driving scene type, input the test sample corresponding to the driving scene type into the trained environment model to obtain the driving environment prediction information corresponding to each trained single model at the next moment.

[0113] Correspondingly, the calculation module 504 is specifically used to: for each driving scene type, calculate the difference of the driving environment prediction information at each next moment under the driving scene type, and when the difference is less than a preset threshold, determine the trained environment model as the driving environment model corresponding to the driving scene type.

[0114] Based on the same inventive concept, the embodiment of the present application also provides a driving environment information prediction device for implementing the driving environment information prediction method involved above. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in the one or more driving environment information prediction device embodiments provided below can refer to the limitations of the driving environment information prediction method above, and will not be repeated here.

[0115] In one embodiment, Figure 6 As shown, a driving environment information prediction device 600 is provided, comprising: an acquisition module 601 and a prediction module 602, wherein:

[0116] The acquisition module 601 is used to acquire the current driving environment information and current decision action information.

[0117] The prediction module 602 is used to predict the driving environment information at the next moment based on the driving environment information at the current moment, the current decision action information, and the driving environment model; wherein the driving environment model is trained by the training method of the driving environment model of the first aspect.

[0118] In one embodiment, the driving environment model includes multiple monomer models. The prediction module 602 is specifically used to: input the current driving environment information and the current decision action information into the driving environment model to obtain the driving environment prediction information of the next moment corresponding to each monomer model included in the driving environment model; calculate the reward value of each driving environment prediction information of the next moment according to the driving environment prediction information of each next moment and the preset reward function, and determine the driving environment prediction information of the next moment with the smallest reward value as the driving environment information of the next moment.

[0119] Each module in the above-mentioned driving environment model training device and driving environment information prediction device can be implemented in whole or in part by software, hardware and a combination thereof. Each of the above-mentioned modules can be embedded in or independent of a processor in a computer device in the form of hardware, or can be stored in a memory in a computer device in the form of software, so that the processor can call and execute the operations corresponding to each of the above modules.

[0120] In one embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as follows: Figure 7 As shown. The computer device includes a processor, a memory, a communication interface, a display screen and an input device connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The communication interface of the computer device is used to communicate with an external terminal in a wired or wireless manner, and the wireless manner can be achieved through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. When the computer program is executed by the processor, a training method for a driving environment model or a prediction method for driving environment information is implemented. The display screen of the computer device can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device can be a touch layer covered on the display screen, or a key, trackball or touchpad set on the computer device housing, or an external keyboard, touchpad or mouse, etc.

[0121] Those skilled in the art will understand that Figure 7 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0122] In one embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps in the above-mentioned method embodiments when executing the computer program.

[0123] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps in the above-mentioned method embodiments are implemented.

[0124] In one embodiment, a computer program product is provided, including a computer program, which implements the steps in the above method embodiments when executed by a processor.

[0125] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties.

[0126] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but are not limited to this.

[0127] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0128] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.

Claims

1. A method for training a driving environment model, characterized in that: The method comprises: Constructing an initial environment model, wherein the initial environment model includes a plurality of parallel monomer models with the same structure, and each of the monomer models has different initial parameters; Acquire a training sample set corresponding to each of the monomer models, and train the corresponding monomer model through each of the training sample sets to obtain a trained environment model; each training sample in the training sample set includes driving environment sample information at the current moment, current decision action sample information, and driving environment sample information at the next moment; Inputting the test sample into the trained environment model to obtain the driving environment prediction information at the next moment corresponding to each trained single model; the test sample includes the driving environment sample information at the current moment and the current decision action sample information; Calculating the difference of the driving environment prediction information at each of the next moments, and determining the trained environment model as the driving environment model when the difference is less than a preset threshold; Wherein, the step of obtaining the training sample sets corresponding to each of the monomer models includes: Obtain an initial training sample set; For each of the monomer models, the initial training sample set is randomly sampled with replacement, and a set of a preset number of training samples obtained by sampling is determined as a training sample set corresponding to the monomer model; the training sample set includes training samples corresponding to multiple driving scene types; The step of inputting the test sample into the trained environment model to obtain the driving environment prediction information at the next moment corresponding to each trained monomer model includes: For each of the driving scene types, input the test sample corresponding to the driving scene type into the trained environment model to obtain the driving environment prediction information at the next moment corresponding to each trained single model; The calculating the difference of the driving environment prediction information at each of the next moments, and determining the trained environment model as the driving environment model when the difference is less than a preset threshold, comprises: For each of the driving scene types, the difference of the driving environment prediction information at each next moment under the driving scene type is calculated, and when the difference is less than a preset threshold, the trained environment model is determined as the driving environment model corresponding to the driving scene type.

2. The method according to claim 1, characterized in that The calculating the difference of the driving environment prediction information at each next moment includes: The variance is calculated according to the driving environment prediction information at each next moment, and the obtained variance value is determined as the difference degree.

3. A method for predicting driving environment information, characterized in that: The method comprises: Obtain the current driving environment information and current decision action information; The driving environment information at the next moment is predicted based on the driving environment information at the current moment, the current decision action information, and the driving environment model; wherein the driving environment model is trained by the training method of the driving environment model described in any one of claims 1 to 2.

4. The method according to claim 3, characterized in that The driving environment model includes a plurality of monomer models; the predicting the driving environment information at the next moment according to the driving environment information at the current moment, the current decision action information, and the driving environment model includes: Inputting the current driving environment information and the current decision action information into a driving environment model to obtain driving environment prediction information at the next moment corresponding to each monomer model included in the driving environment model; According to each of the driving environment prediction information at the next moment and a preset reward function, a reward value of each of the driving environment prediction information at the next moment is calculated, and the driving environment prediction information at the next moment with the smallest reward value is determined as the driving environment information at the next moment.

5. A training device for a driving environment model, characterized in that: The device comprises: A construction module, used for constructing an initial environment model, wherein the initial environment model comprises a plurality of parallel monomer models with the same structure, and each of the monomer models has different initial parameters; A training module, used to obtain a training sample set corresponding to each of the monomer models, and train the corresponding monomer model through each of the training sample sets to obtain a trained environment model; each training sample in the training sample set includes driving environment sample information at the current moment, current decision action sample information, and driving environment sample information at the next moment; A testing module, used to input a test sample into the trained environment model to obtain the driving environment prediction information at the next moment corresponding to each trained monomer model; the test sample includes the driving environment sample information at the current moment and the current decision action sample information; a calculation module, configured to calculate the difference between the driving environment prediction information at the next moment, and determine the trained environment model as the driving environment model when the difference is less than a preset threshold; Wherein, the training module is specifically used to obtain an initial training sample set; For each of the monomer models, the initial training sample set is randomly sampled with replacement, and a set of a preset number of training samples obtained by sampling is determined as a training sample set corresponding to the monomer model; the training sample set includes training samples corresponding to multiple driving scene types; The step of inputting the test sample into the trained environment model to obtain the driving environment prediction information at the next moment corresponding to each trained monomer model includes: For each of the driving scene types, input the test sample corresponding to the driving scene type into the trained environment model to obtain the driving environment prediction information at the next moment corresponding to each trained single model; The test module is specifically used to calculate, for each driving scene type, the difference of the driving environment prediction information at each next moment under the driving scene type, and when the difference is less than a preset threshold, determine the trained environment model as the driving environment model corresponding to the driving scene type.

6. A driving environment information prediction device, characterized in that: The device comprises: An acquisition module is used to obtain the current driving environment information and current decision action information; A prediction module, used to predict the driving environment information at the next moment based on the driving environment information at the current moment, the current decision action information, and the driving environment model; wherein the driving environment model is trained by the training method of the driving environment model described in any one of claims 1 to 2.

7. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 2 or 3 to 4 are implemented.

8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 2 or 3 to 4 are implemented.

9. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 2 or 3 to 4 are implemented.