A high-value scene screening method for automatic driving simulation test

CN122549230BActive Publication Date: 2026-09-29CHINA MERCHANTS CHONGQING COMM RES & DESIGN INST
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202611038964.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-07-14
Publication Date
2026-09-29
Estimated Expiration
2046-07-14

AI Technical Summary

Technical Problem

穷举式测试需遍历场景库中所有场景,虽能保证测试覆盖度,但计算资源消耗极高,测试周期漫长,无法满足自动驾驶技术快速迭代的需求

Benefits of technology

(1)通过对海量场景库进行预处理与特征提取,结合改进的评价模型进行快速预测,能够在极短时间内从数百万计的场景中锁定潜在的高价值场景,显著缩短了测试周期,降低了计算资源的消耗,满足了自动驾驶技术快速迭代的工程需求。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122549230B_ABST
    Figure CN122549230B_ABST
Patent Text Reader

Abstract

The application relates to a high-value scene screening method for automatic driving simulation testing and belongs to the technical field of automatic driving simulation testing. In view of the problems of a large simulation test scene library, large test workload, low screening efficiency and inaccurate capture of high-value scenes, the application carries out preprocessing on original simulation scene data, constructs a scene feature matrix, constructs a high-value scene evaluation model based on an improved random forest algorithm and trains the model, calculates the high-value probability of the scene through the model, screens an initial high-value scene set, eliminates redundant scenes by adopting a density-based spatial clustering algorithm, calculates the core degree of the scene in each clustering cluster, and selects representative scenes to form a final high-value scene subset. The application intelligently and quickly extracts a small amount of high-value scenes, significantly reduces the simulation test workload, improves the test efficiency, accurately captures extreme dangerous scenes and edge scenes, and ensures the diversity and representativeness of the scene subset under the premise of ensuring the test coverage and effectiveness.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of autonomous driving simulation testing technology and relates to a method for screening high-value scenarios for autonomous driving simulation testing. Background Technology

[0002] With the rapid development of autonomous driving technology, scenario-based simulation testing has become a core means of verifying the safety and reliability of autonomous driving systems. Faced with a massive number of possible test scenarios, the size of the simulation scenario library is growing exponentially. Directly adopting full-scenario testing would result in huge consumption of computing resources and time costs, making it difficult to implement in engineering practice.

[0003] Existing autonomous driving simulation tests mostly employ either exhaustive testing or random sampling testing. Exhaustive testing requires traversing all scenarios in the scenario library, which, while ensuring test coverage, consumes extremely high computational resources and has a long testing cycle, failing to meet the needs of rapid iteration in autonomous driving technology. Random sampling testing, while reducing the number of test scenarios, lacks specificity and cannot accurately capture extreme and dangerous scenarios and edge scenarios crucial for system performance verification. This easily leads to test omissions and makes it difficult to fully verify the reliability of autonomous driving systems under complex operating conditions, resulting in insufficient validity of test results.

[0004] To address the aforementioned issues, some existing technologies attempt to screen high-value scenarios through manual annotation. However, this method is inefficient and highly subjective, failing to meet the screening needs of massive scenario libraries. Other methods employ simple feature matching for screening, which cannot comprehensively measure the overall testing value of scenarios, easily leading to the omission of high-value scenarios or an excessive number of redundant scenarios. Furthermore, existing screening methods often ignore the diversity and representativeness of scenarios, resulting in incomplete coverage of the selected scenario subsets, and the test results failing to fully reflect the true performance of the autonomous driving system.

[0005] Therefore, there is an urgent need for a high-value scenario selection method for autonomous driving simulation testing that can intelligently and quickly extract a small subset of high-value scenarios from a large scenario library. This method can significantly reduce the workload of simulation testing and improve testing efficiency while ensuring test coverage and effectiveness, thus solving the technical pain points of existing technologies such as long test cycles, high resource consumption, and poor screening targeting. Summary of the Invention

[0006] In view of this, the purpose of this invention is to provide a method for screening high-value scenarios for autonomous driving simulation testing.

[0007] To achieve the above objectives, the present invention provides the following technical solution: A method for selecting high-value scenarios for autonomous driving simulation testing includes the following steps: S1: Preprocess the original simulation scene data to construct the scene feature matrix; S2: A high-value scene evaluation model is constructed based on the random forest algorithm with an attention feature weighting layer, and the high-value scene evaluation model is trained using labeled samples. The attention feature weighting layer assigns attention weights to different dimension feature parameters in the scene feature matrix, and the attention-weighted feature vector is input into the random forest classification layer for high-value probability prediction. S3: Calculate the high-value probability of all scenarios using the trained model, and select an initial set of high-value scenarios; S4: The initial high-value scene set is clustered using the density-based spatial clustering (DBSCAN) algorithm to eliminate redundant scenes; S5: Calculate the coreness of the scene in each cluster and select representative scenes to form the final high-value scene subset; S6: Use the subset of high-value scenarios for simulation testing, collect the test efficiency improvement rate and test coverage, and verify the effectiveness of the screening results.

[0008] Furthermore, S1 includes: Obtain raw scene data including road parameters, traffic participant parameters, environmental parameters, event parameters, and parameters related to the test target; Remove invalid scenarios and abnormal data scenarios with a data missing rate of 10% or higher; Five core feature parameters are extracted for each scenario: scenario type feature, risk level feature, complexity feature, scenario scarcity feature, and test value correlation feature; The Min-Max Normalization method is used to map all feature parameters to the [0,1] interval to construct the scene feature matrix.

[0009] Furthermore, the risk level characteristics are assessed through risk scoring. Quantification, the calculation formula is:

[0010] in, For the first i Risk level rating for each scenario For collision probability weights, For the frequency weighting of emergency braking, The probability weights for the sudden appearance of obstacles are 1, and the sum of the three is 1. , , The first i Normalized values ​​of collision probability, emergency braking frequency, and sudden obstacle appearance probability in each scenario.

[0011] Furthermore, the complexity feature is evaluated through complexity scoring. Quantification, the calculation formula is:

[0012] in, For the first i The complexity score of each scenario For the first j The weights of each complexity metric, For the first i The first scenario j The normalized value of a complexity index, This is the coupling correction coefficient, with a value ranging from 0 to 0.2.

[0013] Furthermore, in S2, the structure of the high-value scene evaluation model includes an input layer, an attention feature weighting layer, and a random forest classification layer; The attention feature weighting layer is used to weight the input feature vector, resulting in a weighted feature vector. The calculation formula is:

[0014] in, For the first j Attention weights for each feature parameter. For the first j A unit vector of features.

[0015] Furthermore, in step S3, the threshold for selecting the initial high-value scene set is 0.8, meaning that the probability of selecting high-value scenes is [not specified]. The scenarios constitute the initial set of high-value scenarios.

[0016] Furthermore, in S4, the neighborhood radius of the density-based spatial clustering algorithm DBSCAN... Set to 0.2, minimum number of samples Set it to 5; When the cosine similarity of the feature vectors of two scenes is greater than or equal to 0.8, they are judged as similar scenes and assigned to the same cluster.

[0017] Furthermore, in S5, the coreness of the scene The calculation formula is:

[0018] in, For the first k In the cluster, the th i The core nature of each scenario For the first kThe total number of scenarios contained in each cluster. For the first k In the cluster, the th i The first scenario and the first t Cosine similarity of feature vectors for each scene.

[0019] Furthermore, in step S6, the formula for calculating the screening effect evaluation index E is as follows:

[0020] in, To improve testing efficiency, To test coverage, For weighting coefficients; when When the screening results are deemed satisfactory.

[0021] Furthermore, the size of the final high-value scenario subset S Determined through an adaptive adjustment function, the calculation formula is as follows:

[0022] in, m This represents the total number of scenes in the scene library. To test the target complexity, the value range is [0,1].

[0023] The beneficial effects of this invention are as follows: (1) By preprocessing and extracting features from a massive scene library and combining it with an improved evaluation model for rapid prediction, it is possible to lock in potential high-value scenes from millions of scenes in a very short time, significantly shortening the testing cycle, reducing the consumption of computing resources, and meeting the engineering needs of rapid iteration of autonomous driving technology.

[0024] (2) By constructing a multi-dimensional feature system covering scenario type, risk level, complexity, scarcity, and test value correlation, and combining it with an improved random forest algorithm that incorporates an attention mechanism, the intrinsic relationship between scenario features and test value can be deeply explored. This method effectively overcomes the subjectivity and blindness of traditional random sampling, and can accurately identify extreme dangerous scenarios and edge scenarios that are of key significance to the safety verification of autonomous driving systems, thus avoiding test omissions.

[0025] (3) By introducing a density clustering algorithm to deduplicatize and cluster the selected scenarios, and selecting the most representative core scenarios from each cluster, the problem of high scenario redundancy in traditional screening methods is solved. This enables the final output of a small subset of scenarios to fully cover various complex traffic conditions and potential risks, ensuring the comprehensiveness and reliability of the test results, and fully verifying the real performance boundaries of the autonomous driving system with minimal testing cost.

[0026] Other advantages, objectives, and features of the invention will be set forth in part in the description which follows, and in part will be apparent to those skilled in the art from the following examination, or may be learned from practice of the invention. The objectives and other advantages of the invention can be realized and obtained through the following description. Attached Figure Description

[0027] To make the objectives, technical solutions, and advantages of the present invention clearer, the preferred embodiments of the present invention will be described in detail below with reference to the accompanying drawings, wherein: Figure 1 Flowchart for screening and validating high-value scenarios. Detailed Implementation

[0028] The following specific examples illustrate the implementation of the present invention. Those skilled in the art can easily understand other advantages and effects of the present invention from the content disclosed in this specification. The present invention can also be implemented or applied through other different specific embodiments, and various details in this specification can be modified or changed based on different viewpoints and applications without departing from the spirit of the present invention. It should be noted that the illustrations provided in the following embodiments are only schematic representations of the basic concept of the present invention. Unless otherwise specified, the following embodiments and features can be combined with each other.

[0029] The accompanying drawings are for illustrative purposes only and are schematic diagrams, not actual pictures. They should not be construed as limiting the invention. To better illustrate the embodiments of the invention, some parts in the drawings may be omitted, enlarged, or reduced, and do not represent the actual product dimensions. It is understandable to those skilled in the art that some well-known structures and their descriptions may be omitted in the drawings.

[0030] In the accompanying drawings of the embodiments of the present invention, the same or similar reference numerals correspond to the same or similar components. In the description of the present invention, it should be understood that if terms such as "upper," "lower," "left," "right," "front," and "rear" indicate the orientation or positional relationship based on the orientation or positional relationship shown in the drawings, they are only for the convenience of describing the present invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, the terms used to describe positional relationships in the drawings are only for illustrative purposes and should not be construed as limiting the present invention. For those skilled in the art, the specific meaning of the above terms can be understood according to the specific circumstances.

[0031] Please see Figure 1 The purpose of this invention is to provide a method for screening high-value scenarios for autonomous driving simulation testing, and its key technical solutions are as follows: Step 1. Preprocessing of the simulation test scenario library The core objective of this step is to transform the original simulation scene data into standardized feature data that can be used for model training and selection, completely eliminating the dimensional differences between features of different dimensions. Simultaneously, it comprehensively extracts multi-dimensional feature parameters that characterize the testing value of the scene, constructing a unified and standardized scene feature system. This provides a data foundation for subsequent high-value scene evaluation model training, cluster analysis, and scene selection. The specific operation process is as follows: 1.1 Original Scene Data Collection and Processing Acquire an autonomous driving simulation scenario library, which typically covers various typical application scenarios such as urban open roads, closed parks, highways, and port and factory areas. Each original scenario must contain complete dynamic and static data, specifically including: road parameters (road type, number of lanes, intersection type, speed limit information), traffic participant parameters (number of vehicles, vehicle speed, number of pedestrians, pedestrian movement trajectory, number of non-motorized vehicles), environmental parameters (weather conditions, light intensity, road surface conditions), event parameters (collision risk events, emergency braking events, sudden obstacle appearance events), and test target association parameters (matching degree with perception, decision-making, control, and other algorithm tests). Denoising the collected original scenario data, removing invalid scenarios with a data missing rate ≥10% (i.e., in a single scenario, the missing rate of any one of the above five parameter categories is ≥10%) and abnormal data scenarios (such as vehicle speed exceeding 150km / h, number of pedestrians exceeding 100, etc., which do not conform to actual scenarios), to ensure the accuracy of subsequent feature extraction.

[0032] 1.2 Multidimensional Feature Parameter Extraction For each valid scenario after processing, five types of core feature parameters are extracted one by one. The extraction method, quantization method and calculation logic of each type of feature parameter are as follows: 1) Scene type characteristics The application scenario category used to characterize the test scenarios is a fundamental feature that distinguishes different test scenarios, ensuring that the selected scenario subset can cover different autonomous driving application scenarios. Specifically, it covers urban open road scenarios, closed park scenarios, highway scenarios, and port and factory area scenarios, and can also be expanded to Robotaxi scenarios, unmanned last-mile logistics scenarios, and automated sanitation vehicle scenarios, etc., according to actual testing needs.

[0033] The quantization method uses one-hot encoding, assuming the total number of scene types is... k Then the type feature of each scene can be represented as a k A binary vector, where only the position corresponding to the scene type is 1, and the rest are 0. For example, if the scene type is one of four categories: urban open road, closed park, Robotaxi, and highway, then the open road scene is encoded as follows: The closed park scene is coded as follows And so on, the encoded data is denoted as ,in , i Indicates the first i One scenario, j Indicates the first j Scene type.

[0034] 2) Risk level characteristics This feature, used to characterize the risk level of a scenario to an autonomous driving system, is one of the core features for judging the value of scenario testing. High-risk scenarios (such as high collision risk and frequent emergency braking) are of greater value for verifying the performance of autonomous driving systems. This feature is calculated based on three key risk indicators in the scenario: collision probability. Emergency braking frequency Probability of sudden obstacle appearance Calculate risk score The specific process is as follows: ① Determine the weight of each risk indicator; the collision probability weight can be determined through expert scoring. Emergency braking frequency weighting Obstacle sudden occurrence probability weight The weights satisfy ,For example , , .

[0035] ② Normalize each risk indicator. The original indicator values ​​are in the range of [0,1], and the normalized indicator values ​​are obtained. , , The normalization formula adopts min-max Standardized formula.

[0036] ③ Calculate the risk score The function expression is:

[0037] in: For the first i The risk level score for each scenario ranges from [0,1]. The higher the score, the greater the risk level of the scenario to the autonomous driving system. , , The first i Normalized values ​​of three risk indicators for each scenario.

[0038] 3) Complexity characteristics Used to characterize the complexity of a scenario, complex scenarios (such as dense vehicle and pedestrian traffic, complex intersections, and severe weather conditions) can more comprehensively verify the adaptability of autonomous driving systems and are an important characteristic of high-value scenarios. This feature is calculated based on five key complexity indicators in the scenario: number of vehicles. Number of pedestrians Number of road intersections Traffic signal complexity Meteorological and environmental complexity The complexity score can be calculated using the entropy method. The specific process is as follows: ① Normalize the five complexity metrics to obtain normalized metric values. , , , , .

[0039]

[0040] In the formula The first feature in scene complexity j The raw values ​​of each indicator (e.g.) j= 1 represents the complexity feature of the scene. (value); The first feature in scene complexity j Normalized values ​​of each complexity metric; , The complexity feature of all scenarios j The maximum and minimum values ​​of each indicator.

[0041] ② Calculate the information entropy of each indicator ( j =1~5, corresponding to 5 complexity indices), the function expression is:

[0042]

[0043] in, m The total number of all scenarios. Indicates the first i Among the scene complexity features, the first one is... j The proportion of the normalized value of a metric to the sum of the normalized values ​​of that metric across all scenarios, if Then define .

[0044] ③ Calculate the weights of the five key complexity metrics. The function expression is:

[0045] ④ Computational complexity score A coupling correction term is introduced, and its functional expression is:

[0046] in, For the first i The complexity score of each scenario ranges from [0,1]. The higher the score, the more complex the scenario. For the first i The first scenario j Normalized values ​​of each complexity metric; m This represents the total number of scenes in the scene library. This is the coupling correction coefficient (value range 0~0.2, which can be determined through calibration). The product term is the normalized value of the indicators. When multiple highly complex indicators exist at the same time, the product term significantly amplifies the score, reflecting the risk amplification effect of "multiple complex factors superimposed".

[0047] 4) Scene scarcity characteristics This feature is used to characterize the rarity of a scene within the scene library. Rare scenes are often edge scenes in testing and have high testing value. This feature is quantified using the reciprocal of the frequency of similar scenes, and the specific calculation process is as follows: ① Construct scene feature vectors based on scene characteristics and elements (such as scene type, risk level, complexity, number of traffic participants, etc.). Then, use the K-means clustering algorithm to group similar scenes into several "scene clusters".

[0048] ② Calculate the first i Frequency of occurrence of each scene The function expression is:

[0049] ③ Calculate the scarcity feature value of the scene The function expression is:

[0050] in: For the first i The scarcity feature value of a scenario; the larger the value, the higher the scarcity feature value. For the first i The frequency of occurrence of each scene, with values ​​ranging from [0,1]. For the first i The number of scenes in the scene cluster to which each scene belongs. m This represents the total number of scenes in the scene library. This is the smoothing coefficient, with a value of 0.001.

[0051] 5) Test value association features This feature characterizes the correlation between testing scenarios and the testing requirements of autonomous driving systems. Different testing objectives (such as perception algorithm testing, decision-making algorithm testing, and control algorithm testing) have different requirements for scenarios; the higher the correlation, the greater the value of the scenario to that testing objective. This feature calculates the correlation between the scenario and the testing objective using cosine similarity. The specific process is as follows: ① Construct the feature vector of the test target The weights of each feature are set according to the test objective. For example, suppose the target feature vector of the decision algorithm is... The weights are consistent with the initial weights of the subsequent attention mechanism.

[0052] ② Construct the first i Feature vectors of each scene It consists of standardized values ​​of four types of features: scenario type, risk level, complexity, and scarcity.

[0053] ③ Calculate cosine similarity The function expression is:

[0054] For the first i The correlation between a scenario and the test target is measured in terms of the range [0,1]. The higher the correlation, the greater the test value of the scenario for the test target. For the first i Feature vectors of each scene; To test the target feature vector; It is the dot product of two vectors; , These are the magnitudes of the two vectors, respectively.

[0055] 1.3 Data Standardization Processing Since the five types of feature parameters mentioned above have different dimensions, directly using them for calculation would lead to an imbalance in feature weights. Therefore, the min-max standardization method is used to uniformly map all feature parameters to the [0,1] interval to eliminate the difference in dimensions. The standardization formula is as follows:

[0056] in, For the first i The first scenario j The standardized values ​​of the feature parameters, ranging from [0,1], are used for subsequent model training and computation. For the first i The first scenario jThe original values ​​of each feature parameter (such as the original value of the risk level score, the original value of the scarcity feature, etc.); For all scenarios, the first j The minimum value of each characteristic parameter; For all scenarios, the first j The maximum value of each feature parameter; i This is the scene index, with a value range of [1, ...]. m ], m This represents the total number of scenes in the scene library. j The index is the feature parameter index, with a value range of [1, n], where n is the total number of dimensions of the feature parameters (in this invention). n =5).

[0057] 1.4 Calculation of Comprehensive Evaluation Value of Scene Features To accurately quantify the synergistic impact of various feature parameters, initially screen out candidate scenes with high potential value, and reduce the computational cost of subsequent model training, a scene feature comprehensive evaluation function is introduced. The function formula is as follows:

[0058] in: No. i The higher the value, the higher the initial screening priority of the scene, and the greater the probability of it being judged as a high-value scene. This evaluation value integrates the influence of all core features and is used to initially filter low-value scenes, reducing the amount of data required for model training. n The total number of dimensions of scene feature parameters. In this invention, the core features are 5 categories. The initial weights are assigned to the following features: scenario type, risk level, complexity, scenario scarcity, and test value correlation. The initial values, verified through extensive experimentation, can be set to 0.1, 0.35, 0.15, 0.1, or 0.3 (and can be dynamically adjusted according to the actual test objectives).

[0059] 1.5 Scene Feature Matrix Construction Standardized each scenario n Each feature parameter is grouped into one row. m Each scene consists of m×n Scene feature matrix The matrix expression is:

[0060] in This is the scene feature matrix, which is the core input data for subsequent high-value scene evaluation model training, similarity calculation, and cluster analysis.

[0061] Step 2. Construction and Training of High-Value Scenario Evaluation Model The core objective of this step is to build an evaluation model that can accurately distinguish between high-value and non-high-value scenarios. By introducing an attention mechanism to optimize feature weights, the model's accuracy in identifying high-value scenarios is improved. Simultaneously, by training the model with labeled samples, it is ensured that the model can adapt to the screening requirements of different scenario libraries. The specific operation process is as follows: 2.1 High-Value Scenario Evaluation Model Structure Design Based on scene feature matrix A high-value scene evaluation model is constructed using a random forest algorithm with an attention-weighted layer. This model introduces an attention mechanism to the traditional random forest, assigning appropriate weights to feature parameters of different dimensions, emphasizing the influence of risk level features and test value correlation features (these two types of features are the core determinants of scene test value). The model structure consists of three layers: an input layer, an attention-weighted layer, and a random forest classification layer, as detailed below: (1) Input layer: Input scene feature matrix, each input sample is a feature vector of a single scene. The input dimension is n (Total dimension of feature parameters, in this invention) n =5).

[0062] (2) Attention Feature Weighting Layer: Its core function is to assign weights based on the importance of features, increase the weight of core features (risk level, test value correlation) and reduce the influence of secondary features. The function expression for the weighting process is as follows:

[0063]

[0064]

[0065]

[0066] in, For the first i The feature vector of a scene after attention weighting; For the first j The attention weights for each feature parameter range from [0,1]. The initial values ​​are consistent with the weights of the comprehensive evaluation function in step 1 (scenario type 0.1, risk level 0.35, complexity 0.15, scarcity 0.1, test value correlation 0.3), and will be optimized through model training. For the first j A unit vector of each feature, used to maintain dimensionality consistency of the features; For the first i The first scenario j The standardized values ​​of each feature parameter. For the firstj The importance score of each feature is obtained by weighting the feature importance of each decision tree in the random forest algorithm; The number of decision trees in the random forest. For the first t The weights of each decision tree (set according to the prediction accuracy of the decision tree). For the first t The first decision tree j Importance scores for each feature.

[0067] (3) Random forest classification layer: by T The system consists of several decision trees, with the input being attention-weighted feature vectors. The output is the first... i High probability of value in a scenario (Value range [0,1]), representing the probability that the scene is a high-value scene. Each decision tree is constructed using the CART (Classification and Regression Tree) algorithm. Samples are extracted from the training set through bootstrap sampling to construct the training set for each decision tree. The splitting nodes of each decision tree are selected using the Gini coefficient, and the calculation function of the Gini coefficient is as follows:

[0068] in, Let Gini coefficient be the value of node D, ranging from [0, 0.5]. The smaller the Gini coefficient, the higher the purity of the node and the better the classification effect. For node D, the first k The proportion of samples of different classes (high-value and non-high-value). k =1 indicates a high-value scenario. k =2 indicates a non-high-value scenario, satisfying the condition. .

[0069] The final output of Random Forest (high value probability) The weighted average of the outputs of T decision trees is expressed by the following function:

[0070]

[0071] In the formula, For the first i The probability of a scenario being high-value is given, with values ​​ranging from [0,1]. The higher the value, the greater the likelihood that the scenario is a high-value scenario. Let t be the weight of the t-th decision tree, which is set according to the prediction accuracy of the decision tree. The higher the prediction accuracy, the greater the weight. For the t-th decision tree, the first... iThe prediction result for each scenario takes the value of 1 (predicted as a high-value scenario) or 0 (predicted as a non-high-value scenario). T The number of decision trees in the random forest can be set to 100 in this invention (after multiple experimental verifications, 100 decision trees can balance model accuracy and computational efficiency).

[0072] 2.2 Training Set Preparation Select scene samples labeled with high-value tags (high-value and non-high-value) as the training set. The number of training set samples should meet the model training requirements, usually about 10% of the total size of the scene library. The ratio of high-value scenes to non-high-value scenes should be 1:1 to ensure the balance of model training and avoid overfitting.

[0073] The labeling of high-value tags must follow clear quantitative rules to ensure objectivity and consistency. The labeling rules are: risk level scoring. Test value correlation A scenario is labeled as a high-value scenario if it meets any of the following conditions: complexity score Scene scarcity feature value Other scenarios are labeled as non-high-value scenarios. To further improve the objectivity of high-value tagging and avoid the subjective bias of manual tagging, a high-value scenario judgment function is introduced. This function is constructed based on the comprehensive feature evaluation value and core feature thresholds, quantifying the tagging rules into a mathematical function, as shown in the following formula:

[0074] in, No. i The high-value label for each scenario is a binary variable, where 1 indicates that the scenario is high-value and 0 indicates that the scenario is not high-value. This label is the label value used by the model during training to guide the model in learning the feature patterns of high-value scenarios.

[0075] 2.3 Model Training and Optimization A five-fold cross-validation method was used to train the high-value scenario evaluation model. The specific process of five-fold cross-validation is as follows: the training set is randomly divided into 5 non-overlapping subsets, and the number of samples in each subset is approximately equal; 4 subsets are selected as the training set and 1 subset is selected as the validation set, the model is trained and the prediction accuracy of the validation set is calculated; this is repeated 5 times to obtain the prediction accuracy of the 5 validation sets, and the average of them is taken as the final validation accuracy of the model.

[0076] (1) During model training, the core parameters that need to be optimized include: the number of decision trees T in the random forest and the maximum depth of the decision trees. Initial values ​​of attention weights Gini coefficient threshold for split nodes The optimization objective is to minimize the model's prediction error, i.e., to minimize the mean squared error. Loss , represented as ,in Loss The calculation formula is:

[0077] In the formula, The model prediction error corresponding to the current candidate parameter combination is represented by mean squared error, with a value range of [0,1]. The smaller the error, the better the model prediction effect. The number of samples in the validation set.

[0078] (2) Training termination condition: When the model's validation set prediction accuracy reaches a preset threshold (not less than 90%), and after 3 consecutive iterations (each iteration adjusts a set of parameters), the improvement in prediction accuracy is determined. If the training fails, the training stops, and a high-value scene evaluation model is obtained; if the preset threshold is not reached, the parameters are adjusted and the training process is repeated.

[0079] Step 3. Initial High-Value Scenarios Screening The core objective of this step is to utilize a trained high-value scene evaluation model to quickly select scenes with high-value potential from the scene database, forming an initial high-value scene set. Simultaneously, a density clustering algorithm is used to group scenes with high similarity into one category, eliminating scene redundancy and laying the foundation for subsequent extraction of representative scenes. The specific operation process is as follows: 3.1 Probability Prediction of High-Value Scenarios The scene feature matrix X (feature vectors of all scenes) obtained from the preprocessing in step 1 is input one by one into the trained high-value scene evaluation model. Through the model's attention feature weighting layer and random forest classification layer, the high-value probability of each scene is output. .

[0080] 3.2 Initial High-Value Scenarios Selection A high-value probability preset threshold of 0.8 was set (verified through multiple experiments; this threshold effectively filters low-value scenarios while ensuring a high capture rate for high-value scenarios; the threshold can be adjusted according to actual testing needs) to filter out high-value scenarios. These scenarios form the initial high-value scenario set. The set expression is: The size of this collection is typically 5%-10% of the total size of the scene library, which reduces the number of scenes to be processed later while retaining most of the high-value scenes.

[0081] 3.3 Density Clustering DBSCAN Processing Due to the initial high-value scene set There may be a large number of redundant scenes with high similarity (such as multiple urban road scenes that differ only slightly in the number of vehicles). If these scenes are used directly for testing, it will increase the testing workload. Therefore, the density clustering algorithm DBSCAN is used to cluster the initial set of high-value scenes, grouping scenes with high similarity into one category, resulting in multiple scene clusters. Each cluster represents a class of similar high-value scenes. The specific process is as follows: (1) Similarity calculation The core of clustering is calculating the similarity between scenes. This invention uses cosine similarity of feature vectors as a similarity metric, which can effectively measure the degree of similarity between the feature vectors of two scenes. The calculation function of cosine similarity is as follows:

[0082] in, For the first i The first scenario and the first t The cosine similarity of the feature vectors of two scenes ranges from [0,1]. The closer the value is to 1, the higher the similarity between the two scenes. , These are the feature vectors of the i-th and t-th scenes, respectively (from the initial set of high-value scenes). ; The dot product of two vectors. , These are the magnitudes of the two vectors, respectively.

[0083] Set the similarity threshold to 0.8. When the cosine similarity between two scenes is... Scenes that are deemed to have a high degree of similarity are grouped into the same cluster.

[0084] (2) DBSCAN clustering parameter settings The core parameters of the DBSCAN algorithm include the neighborhood radius. and minimum sample size The rationality of parameter settings directly affects the clustering effect. This invention has been verified through multiple sets of experiments, and the recommended parameter settings are as follows: , The meanings of the parameters and the basis for their settings are as follows: 1) Neighborhood radius The value is 0.2, corresponding to a cosine similarity threshold of 0.8 (because cosine similarity is negatively correlated with vector distance; the smaller the distance, the higher the similarity. When the vector distance ≤ 0.2, the cosine similarity ≥ 0.8). This value is used to define the neighborhood range of each scene, i.e., the range of vector distances to that scene ≤ 0.2. All of these scenarios belong to samples within the neighborhood of that scenario.

[0085] 2) Minimum number of samples The value is 5, used to define the criterion for determining the core point, that is, when the number of samples in the neighborhood of a certain scene is ≥ When the value of a scene is not high, it is considered a core point. The core point is the core of the cluster, and samples in the neighborhood around the core point will be classified into the same cluster. Otherwise, the scene is considered a noise point and will be removed from the initial set of high-value scenes (noise points are usually scenes with abnormal features and low test value).

[0086] 3) Clustering results output The DBSCAN algorithm was used to analyze the initial set of high-value scenarios. After clustering, multiple scene clusters were obtained. ,in Indicates the first p Clusters ( p =1,2,..., k ), each cluster Includes ≥ In each scenario, the total number of scenarios in all clusters is less than or equal to the size of the initial high-value scenario set (after removing noise points). The scenario similarity within each cluster is high, while the scenario similarity between clusters is low, thus eliminating scenario redundancy.

[0087] Step 4. Scene Subset Optimization and Extraction The core objective of this step is to select the most representative scenarios from each scenario cluster, and then aggregate them to form a final high-value scenario subset. This subset needs to minimize the number of scenarios while ensuring test coverage, thereby significantly reducing the workload of simulation testing. The specific process is as follows: 4.1 Calculation of Scene Coreness Coreness measures the representativeness of a single scene within its cluster. A higher coreness indicates that the scene's features better reflect the characteristics of the entire cluster. Selecting the scene with the highest coreness as the representative scene of that cluster ensures that the test value of that cluster is fully covered. Coreness is calculated based on the average similarity between a scene and all other scenes within the cluster, using the following formula:

[0088] in, : No. k In the cluster, the th i The coreness of a scene ranges from 0 to 1. The closer the coreness is to 1, the stronger the representativeness of the scene in the cluster and the better it reflects the scene characteristics of the entire cluster. Coreness is the core indicator for selecting representative scenes.

[0089] : No. k The total number of scenarios contained in each cluster, with a value range of ≥2.

[0090] : No. k In the cluster, the th i The first scenario and the first t One scenario ( t ≠ i The cosine similarity of the feature vectors of two scenes is denoted as cosine similarity, with a value range of [0,1]. It is used to measure the degree of similarity between two scenes.

[0091] 4.2 Selection of Representative Scenarios Clustering for each scenario Calculate the core degree of all scenarios within the cluster. The scene with the highest core score is selected as the representative scene of the cluster. If multiple scenes have the same core score (all of which are the maximum value), the scene with the highest core score is selected. The highest-value scenario is used as the representative scenario to ensure that the overall value of the representative scenario is optimal.

[0092] 4.3 Setting and Adjusting the Size of Scene Subsets Based on testing requirements, the size of the preset scenario subset is usually 1%-5% of the total size of the scenario library. This size can be dynamically adjusted according to the testing accuracy requirements: the larger the size, the higher the test coverage, but the greater the testing workload; the smaller the size, the less the testing workload, but the test coverage may decrease.

[0093] The adaptive adjustment function for the size of the scene subset is as follows, which can be based on the total size of the scene library. m and test target complexity Automatically determine the size of the scene subset S :

[0094] in, S The size of the final high-value scenario subset, taking a positive integer value; This represents the total number of scenes in the scene library. The complexity of the test target is used to characterize the core feature dimensions involved in the current simulation test target and their importance, with a value range of [0,1].

[0095] Calculate according to the following formula:

[0096] in, , , , and These represent the identifiers for whether the test target involves scenario type features, risk level features, complexity features, scenario scarcity features, and test value correlation features, respectively; a value of 1 is assigned when the test target involves the corresponding feature, and a value of 0 is assigned when it does not; 0.1, 0.35, 0.15, 0.1, and 0.3 are the initial weights of scenario type features, risk level features, complexity features, scenario scarcity features, and test value correlation features, respectively. Therefore, the more high-weight features the test target involves, the higher the probability of success. The larger the size, the larger the corresponding subset of high-value scenarios. S The larger.

[0097] 4.4 Extraction of the final high-value scene subset Representative scenes from all scene clusters are aggregated. If the number of aggregated scenes equals the preset subset size, it is directly used as the final high-value scene subset. If the number of aggregated scenes is less than the preset subset size, the scenes with the second-highest coreity from each cluster are selected to supplement the preset size. If the number of aggregated scenes is greater than the preset subset size, the comprehensive feature evaluation value of all representative scenes is calculated. Select The highest-value scenes are retained up to a preset size, ultimately resulting in a subset of high-value scenes. This completes the screening of high-value scenarios.

[0098] Step 5. Verify the screening results The core objective of this step is to verify the testing effectiveness of the final high-value scenario subset. This is achieved by using the subset for simulation testing, collecting key test metrics, and comparing them with preset standards. If the requirements are not met, relevant parameters are adjusted, and the screening process is repeated until the screening results are satisfactory. This ensures that the scenario subset can fully verify the performance of the autonomous driving system while reducing workload. The specific process is as follows: 5.1 Simulation Testing and Key Indicator Collection The high-value scene subset extracted in step 4 Used for autonomous driving simulation testing, two core key indicators are collected during the testing process: test efficiency improvement rate and test coverage. The definitions and calculation methods of each indicator are as follows: (1) Testing efficiency verification Compare the simulation testing workload before and after screening to verify the efficiency improvement of the screening method. Specific verification steps are as follows: 1) If the existing exhaustive testing method is used, for the entire scenario library ( m Simulation tests were conducted in several scenarios, and the time required for the tests was estimated and recorded. And computational resource consumption.

[0099] 2) Simulation tests were conducted using the high-value scenarios selected by this invention, and the time required for the tests was estimated and recorded. And computational resource consumption.

[0100] 3) Calculate the test efficiency improvement rate using the following formula:

[0101] Verification criteria: Efficiency improvement rate ≥ 80%, that is, the test time after screening does not exceed 20% of the exhaustive test time, which greatly reduces the workload of simulation testing and meets the needs of rapid iteration of autonomous driving technology.

[0102] (2) Test coverage verification The simulation tests before and after the selection are compared to measure the coverage of the high-value scene subset across all high-value scene types. The value ranges from [0, 100%]. The higher the coverage, the more comprehensive the high-value scene types the subset can cover, and the better the test results. The calculation function is as follows:

[0103] in, The number of scenario types covered in the high-value scenario subset (such as high-risk scenarios, complex scenarios, scarce scenarios, etc.). This is the total number of preset scene types.

[0104] Verification criteria: Scene type coverage ≥ 95%, ensuring coverage of all preset scene types and avoiding incomplete scene coverage.

[0105] 5.2 Comprehensive Verification and Judgment of Screening Results To quantify the suitability of the screening results, a comprehensive judgment method is adopted, and a screening effectiveness evaluation function is introduced:

[0106] in, To filter the performance evaluation index, the value range is [0,1]. The weighting coefficient is specifically the test efficiency improvement rate. The weighting coefficient is 0.3. For test coverage The weighting coefficient is set to 0.7.

[0107] The actual collected and calculated test efficiency improvement rate and test coverage Substitute into the following formula to calculate the screening effect evaluation index. :

[0108] Among them, the test efficiency improvement rate The calculation formula is:

[0109] Test coverage The calculation formula is:

[0110] in, The test time required to perform simulation testing of the entire scene library using an exhaustive testing method; Test time required for simulation testing using a subset of high-value scenarios; The number of high-value scenario types covered by the high-value scenario subset; This represents the total number of all high-value scene types in the scene library.

[0111] when When the screening results are deemed satisfactory, they are considered acceptable. When necessary, adjust the feature weights, clustering thresholds, or scene subset size of the high-value scene evaluation model, and repeat the screening process until the screening results meet the preset standards.

[0112] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the present invention, and all such modifications or substitutions should be covered within the scope of the claims of the present invention.

Claims

1. A method for selecting high-value scenarios for autonomous driving simulation testing, characterized in that: Includes the following steps: S1: Obtain the original simulation scenario data containing road parameters, traffic participant parameters, environmental parameters, event parameters, and test target related parameters, and remove invalid scenarios and abnormal data scenarios with a data missing rate of greater than or equal to 10%; extract the scenario type features, risk level features, complexity features, scenario scarcity features, and test value related features for each valid scenario, and use the min-max normalization method to map each feature parameter to the [0,1] interval to construct a scenario feature matrix; wherein, the scenario scarcity feature is determined based on the reciprocal of the occurrence frequency of the corresponding scenario after K-means clustering of the scenario feature vector, and the test value related features are determined based on the cosine similarity between the scenario feature vector and the test target feature vector; S2: Construct a high-value scene evaluation model based on the scene feature matrix, employing an attention feature weighting layer and a random forest classification layer; the attention feature weighting layer assigns initial values ​​of 0.1, 0.35, 0.15, 0.1, and 0.3 to the five feature classes respectively, and optimizes the attention weights during model training, wherein the first... j The importance score of each feature is determined by the first decision tree in the random forest classification layer. j The importance of each feature is obtained by weighting it according to the prediction accuracy of the corresponding decision tree. j The importance scores of the features are obtained after normalization. j Attention weights are assigned to each feature; the attention-weighted scene feature vector is input into the random forest classification layer, and the high-value probability of the scene is output; the high-value scene evaluation model is trained using labeled samples, wherein scenes with a risk level score greater than or equal to 0.7, a test value correlation greater than or equal to 0.7, and a complexity score greater than or equal to 0.6 or a scene scarcity feature value greater than or equal to 0.8 are labeled as high-value scenes, and the rest are labeled as non-high-value scenes; S3: Input the scene feature vectors of each scene into the trained high-value scene evaluation model, calculate the high-value probability of each scene, and select scenes with a high-value probability greater than or equal to 0.8 to form an initial high-value scene set. S4: The initial high-value scene set is clustered using the density-based spatial clustering DBSCAN algorithm. The neighborhood radius of the DBSCAN algorithm is set to 0.2, and the minimum number of samples is set to 5. When the cosine similarity of the feature vectors of two scenes is greater than or equal to 0.8, the two scenes are assigned to the same cluster and noise points are removed. S5: Calculate the following formula k In the cluster, the th i The core importance of each scenario: in, For the first k In the cluster, the th i The core nature of each scenario For the first k The total number of scenarios contained in each cluster. For the first k In the cluster, the th i The first scenario and the first t The cosine similarity of feature vectors of each scene is used; the scene with the highest core degree in each cluster is selected as the representative scene. When multiple scenes have the same core degree and are all the maximum value, the scene with the highest comprehensive feature evaluation value of the five types of features is selected as the representative scene. Based on the total number of scenes in the scene library m and test target complexity The size of the final high-value scenario subset is determined according to the following formula. S : Wherein, the complexity of the test target Determined according to the following formula: in, , , , and These are the identifiers for whether the test target involves scene type features, risk level features, complexity features, scene scarcity features, and test value correlation features, respectively. A value of 1 is assigned if the corresponding feature is involved, and 0 is assigned if the corresponding feature is not involved. Representative scenes from each cluster are summarized. If the number of summarized scenes is less than the stated scale... S At that time, scenes with the second highest core degree are selected from each cluster to supplement the scale. S When the total number of scenarios exceeds the stated scale S At that time, based on the comprehensive evaluation value of the aforementioned characteristics, the values ​​are retained from high to low up to the specified scale. S This yields the final subset of high-value scenarios; S6: Use the final high-value scenario subset for autonomous driving simulation testing to collect data on testing efficiency improvement rates. and test coverage ,in: in, The test time required to perform simulation testing on the entire scene library using an exhaustive testing method. The test time required to perform simulation testing using the aforementioned final high-value scenario subset. The number of high-value scene types covered by the final high-value scene subset. The total number of all high-value scene types in the scene library; the screening effect evaluation index is calculated according to the following formula. E : when E When the value is greater than or equal to 0.9, the screening result is considered acceptable; when... E When the value is less than 0.9, adjust the feature weights, clustering threshold, or size of the final high-value scene subset of the high-value scene evaluation model, and repeat the high-value scene screening process until... E Greater than or equal to 0.

9.

2. The method for selecting high-value scenarios for autonomous driving simulation testing according to claim 1, characterized in that: The risk level characteristics are identified through risk scoring. Quantification, the calculation formula is: in, For the first i Risk level rating for each scenario For collision probability weights, For the frequency weighting of emergency braking, The probability weights for the sudden appearance of obstacles are 1, and the sum of the three is 1. , , The first i Normalized values ​​of collision probability, emergency braking frequency, and sudden obstacle appearance probability in each scenario.

3. The method for selecting high-value scenarios for autonomous driving simulation testing according to claim 1, characterized in that: The complexity feature is scored using complexity. Quantification, the calculation formula is: in, For the first i The complexity score of each scenario For the first j The weights of each complexity metric, For the first i The first scenario j The normalized value of a complexity index, This is the coupling correction coefficient, with a value ranging from 0 to 0.

2.

4. The method for selecting high-value scenarios for autonomous driving simulation testing according to claim 3, characterized in that: In S2, the structure of the high-value scene evaluation model includes an input layer, an attention feature weighting layer, and a random forest classification layer; The attention feature weighting layer is used to weight the input feature vector, resulting in a weighted feature vector. The calculation formula is: in, For the first j Attention weights for each feature parameter. For the first j A unit vector of features.

Citation Information

Patent Citations

  • Automatic driving simulation example compiling method and device, electronic equipment and storage medium

    CN110955159A

  • Automatic driving test scene analysis method and system

    CN113989768A