A method for constructing a simulated traffic flow and a simulation device

By reading traffic scene files from a forward-built traffic scene library and controlling the continuous transition of simulated vehicles between different scenes, the problem of simulated traffic flow covering a single scene in existing technologies is solved, and low-cost, high-coverage simulated traffic flow construction is achieved.

CN114091223BActive Publication Date: 2025-11-07YINWANG INTELLIGENT TECHNOLOGIES CO LTD

Patent Information

Application Number
CN202010857186.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-08-24
Publication Date
2025-11-07
Estimated Expiration
2040-08-24

AI Technical Summary

Technical Problem

Existing methods for constructing simulated traffic flow rely on the collection of real traffic flow data, which is costly and the constructed simulated traffic flow only covers a single scenario, making it impossible to comprehensively test the continuous switching between different scenarios.

Method used

By reading traffic scene files from a forward-built traffic scene library, the system controls the continuous transition of simulated vehicles between different scenes, generating simulated traffic flow and covering the continuous switching between different scenes.

Benefits of technology

This reduced data collection costs, improved the comprehensiveness and completeness of the test, ensured that the simulated traffic flow could cover continuous switching of multiple scenarios, and enhanced the coverage of the test.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114091223B_ABST
    Figure CN114091223B_ABST
Patent Text Reader

Abstract

The embodiment of the application discloses a kind of construction method and simulation equipment of simulating traffic flow, it can be applied to the field of automatic driving simulation test, the method comprises: first, for different simulation test purposes, the traffic scene library that meets the test demand is constructed in positive direction, the number of each traffic scene file in traffic scene library, the proportion of traffic scene file belonging to different traffic scene type can be customized, high flexibility, compared with collecting real traffic flow data, without labeling, low cost, easy to obtain, and consider comprehensive, not limited by the collection data, can guarantee test completeness;Second, simulation equipment reads traffic scene file from traffic scene library in turn, and controls simulation vehicle to transition from the initial state of last scene to the terminal state of current scene, realize the continuous distribution of different simulation scenes, so that the simulation traffic flow generated can cover the test part of different scene continuous switching;Finally, for each simulation scene, the corresponding test result is generated in real time, high efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the field of simulation test of automatic driving, and in particular to a method for constructing a simulation traffic flow and a simulation device. BACKGROUND

[0002] The development of an automatic driving system follows a process from simulation to real vehicle test. Simulation experiment, as a zero-risk and rapid iteration test method, lays a solid foundation for the on-road test of automatic driving. Simulation can quickly test the performance of automatic driving algorithms.

[0003] The basis of simulation experiment is to construct a simulation traffic flow first. At present, the commonly used way to construct a simulation traffic flow is to first label the traffic flow original data collected from a real road, train a neural network model using the labeled original data, so as to realize the classification function of different test scenes in the traffic flow, then use random sampling to combine the classified different test scenes in order to generate a simulation traffic flow file, and finally import the generated simulation traffic flow file into a simulation software, such as CARLA as shown in the following figure. Figure 1

[0004] However, the traffic flow original data needs to be labeled and has a high collection cost. In addition, the simulation traffic flow constructed is essentially a single scene output by the simulation software, and only a single scene is used for testing, which misses the test part of continuous switching between different scenes, resulting in incomplete testing. SUMMARY

[0005] The embodiments of the present application provide a method for constructing a simulation traffic flow and a simulation device, which are used to read traffic scene files from a forwardly constructed traffic scene library, realize continuous distribution of different simulation scenes, and thus the generated simulation traffic flow can cover the test part of continuous switching between different simulation scenes.

[0006] Based on this, the embodiments of the present application provide the following technical solutions:

[0007] ​In a first aspect, the embodiments of the present application first provide a construction method of a simulation traffic flow, which can be used in the field of automatic driving. The method comprises the following steps. First, a simulation device reads a first traffic scene file from a traffic scene library. The traffic scene library is obtained through forward construction, that is, a plurality of traffic scene files obtained through forward construction are a plurality of scene files constructed based on subject knowledge. Different from traditional collected traffic flow raw data (that is, valuable scenes are analyzed and extracted from collected real traffic flow raw data, which is a data-based analysis method), it is clear that which types of traffic scenes are included in the traffic scene library obtained through forward construction and the number of each type of traffic scene. The traffic scene library comprises a plurality of traffic scene files. Each traffic scene file in the plurality of traffic scene files comprises a duration of a respective traffic scene and a running state of each simulation vehicle at each unit time within the duration in the respective traffic scene. Each traffic scene file corresponds to a certain traffic scene type. The traffic scene types are divided according to a preset principle. The single-function scenes faced by automatic driving can be classified through test analysis of automatic driving scenes, for example, following driving, stopping when encountering an obstacle, left and right lane changing, etc. The actual road scenes faced by automatic driving can also be classified, for example, rural road scenes, no lane line scenes, intersection scenes, highway scenes, mountain road scenes, etc. The specific principle for dividing the traffic scene types is not limited. Then, the simulation device controls each simulation vehicle to transit from a second running state to a first running state. The second running state refers to the running state of each simulation vehicle at the last unit time of a second traffic scene file, that is, the termination state of the last read traffic scene file. The first running state refers to the running state of each simulation vehicle at the first unit time of the first traffic scene file, that is, the initial state of the currently read traffic scene file. The second traffic scene file is a traffic scene file generated by simulation software for a first simulation scene. Subsequently, the simulation device generates a second simulation scene from the first traffic scene file through simulation software with the first running state as a new starting state. The first simulation scene is a simulation scene generated last time before the second simulation scene. Finally, the generated first simulation scene and the second simulation scene constitute the simulation traffic flow of the embodiments of the present application.

[0008] In the above-mentioned embodiments of the present application, firstly, for different simulation test purposes, a traffic scenario library conforming to test requirements can be constructed in a forward direction, the number of traffic scenario files of each type of traffic scenario in the traffic scenario library and the traffic scenario types can be customized, the flexibility is high, compared with collecting real traffic flow data, no labeling is required, the cost is low, easy to obtain, and comprehensive consideration, not limited by collected data, the test completeness can be guaranteed; secondly, the simulation device reads the traffic scenario files (i.e., the second traffic scenario file and the first traffic scenario file) from the traffic scenario library constructed in the forward direction in sequence, and controls the simulation vehicle to transition from the initial state of the previous scene to the termination state of the current scene, realizes the continuous allocation of two simulation scenes, and thus the generated simulation traffic flow can cover the test part of the continuous switching of two scenes, so that the test is more comprehensive.

[0009] In a possible design of the first aspect, the simulation device controls each simulation vehicle to transition from the second running state to the first running state within a specified time length (for example, 3 seconds) by using a self-provided driver model. The driving style (for example, aggressive type, conservative type, etc.) of the driver model of each simulation vehicle can be set by itself, and details are not described herein.

[0010] In the above-mentioned embodiments of the present application, since the self-provided driver model is generally an ideal driving model, the switching between two scenes can be smooth, the running curve of the simulation vehicle is smoother, and is closer to the real driving scene.

[0011] In a possible design of the first aspect, the simulation device repeatedly performs the step of generating the second simulation scene until a preset condition is reached. It should be noted that the simulation device can be any form of computer device, such as a personal computer, a server, etc., and details are not limited herein.

[0012] In the above-mentioned embodiments of the present application, the simulation device reads multiple traffic scenario files from the traffic scenario library constructed in the forward direction in sequence for simulation until a prediction condition is reached, and controls the simulation vehicle to transition from the initial state of the previous scene to the termination state of the current scene, realizes the continuous allocation of multiple different simulation scenes, and thus the generated simulation traffic flow can cover the test part of the continuous switching of different scenes, and the simulation traffic flow obtained by the embodiments of the present application is composed of a larger number of simulation scenes, and is comprehensive.

[0013] In a possible design of the first aspect, the manner of judging whether the preset condition is met can be various. In one manner of judging whether the preset condition is met, when the number of simulation scenarios generated by the simulation software reaches a preset value, it is considered that the preset condition is met. For example, assume that the preset value n is set as 300, and the current running scenario is scenario i. When the running of scenario i is completed, if i = i + 1 < 300, it is considered that the preset condition is not met, and the traffic scenario file is continuously read from the traffic scenario library, and the simulation traffic flow is in a continuous construction process. When i = i + 1 = 300, it is considered that the preset condition is met, and the 300 continuous read and running simulation scenarios construct the simulation traffic flow.

[0014] In the above embodiment of the application, the condition of terminating the construction of the simulation traffic flow is specifically described. This termination manner does not limit that each traffic scenario file in the traffic scenario library must be read, but only requires that the read traffic scenario file reaches a preset number, and emphasizes the randomness of the construction of the simulation traffic flow.

[0015] In a possible design of the first aspect, another manner of judging whether the preset condition is met can also be that when the running time of the simulation software reaches a preset time length, it is considered that the preset condition is met. For example, assume that the preset time length t is set as 20 hours (h). When the running of scenario i is completed, the simulation device judges whether the running time of the simulation software reaches 20 h. When the running of scenario i is completed and , it is considered that the preset condition is not met, and the traffic scenario file is continuously read from the traffic scenario library, and the simulation traffic flow is in a continuous construction process. When the running of scenario i is completed and , it is considered that the preset condition is met, and the continuous read and running simulation scenarios construct the simulation traffic flow.

[0016] In the above embodiment of the application, another condition of terminating the construction of the simulation traffic flow is specifically described. This termination manner limits the total running time of the simulation software, and because the running time period can be set by itself, the probability of the simulation software being unexpectedly interrupted in the running process is reduced.

[0017] In a possible design of the first aspect, another way of judging whether the preset condition is met can also be that each traffic scenario file in the traffic scenario library is read at least once, indicating that the preset condition is met. Specifically, if there is a traffic scenario file in the traffic scenario library that has never been read, it indicates that the preset condition is not met, and the above process is repeated to continue reading traffic scenario files from the traffic scenario library; if each traffic scenario file has been read at least once, it indicates that the preset condition is met, at which point the simulation ends after the current scenario i is run, and no traffic scenario file is read from the traffic scenario library. It should be noted that in some embodiments of the present application, for the traffic scenario files that have been read, the simulation device can mark them, and then when reading again, it can read them in turn from the remaining traffic scenario files that have not been read, or it can directly read them randomly from the entire traffic scenario library (that is, without distinguishing between traffic scenario files that have been read and traffic scenario files that have not been read), but all traffic scenario files in the entire traffic scenario library have been read at least once. The reading method of the traffic scenario files is not limited here.

[0018] In the above embodiments of the present application, another condition for terminating the construction of the simulation traffic flow is specifically described, which limits that each traffic scenario file in the traffic scenario library needs to be read at least once, that is, each simulation scenario in the constructed simulation traffic flow appears at least once, thereby improving the completeness of the test.

[0019] In a possible design of the first aspect, since the constructed simulation traffic flow can be used for multiple purposes, for example, it can be used to reproduce or pre-grasp the traffic operation status of an existing system or a future system, thereby explaining and analyzing complex traffic phenomena; it can also be used to optimize the studied traffic system. The use of the constructed simulation traffic flow is not limited here. In some embodiments of the present application, the constructed simulation traffic flow can be specifically used to test the related functions and performance of an intelligent driving vehicle. Specifically, the simulation device imports an automatic driving algorithm into the simulation software, tests the automatic driving algorithm based on different detection types, and obtains the test results of the automatic driving algorithm in each simulation scenario.

[0020] In the above embodiments of the present application, the to-be-tested automatic driving algorithm is imported into the simulation software to test the performance of the related automatic driving algorithm in each simulation scenario in the constructed simulation traffic flow, which is strong in implementability.

[0021] In a possible design of the first aspect, when there is a test result that does not meet a preset requirement, the simulation device can also mark the traffic scenario file corresponding to the test result, and subsequently, when reading the traffic scenario file from the traffic scenario library, the frequency of reading the traffic scenario file is increased, that is, the frequency of reading the first traffic scenario file after marking is higher than the frequency of reading the first traffic scenario file before marking.

[0022] In the foregoing embodiments of the present application, a difficult case library can be formed in a closed loop, and the traffic scenario file with a poor test result can be subsequently read more frequently, thereby improving the optimization efficiency of the automatic driving algorithm.

[0023] In a possible design of the first aspect, the detection types include, but are not limited to, at least one of collision detection, speed limit detection, on-road detection, intersection lane change detection, end point detection, lane centering detection, emergency braking detection, acceleration detection, unnecessary braking detection, or smoothness detection. The collision detection is used to determine whether the ego vehicle collides with surrounding obstacles; the speed limit detection is used to determine whether the ego vehicle exceeds the road speed limit of the current lane; the on-road detection is used to determine whether the ego vehicle is driving on the correct road; the intersection lane change detection is used to determine whether the ego vehicle changes lanes before the intersection to enter the correct lane; the end point detection is used to determine whether the ego vehicle is within a certain range of the end point; the lane centering detection is used to determine whether the ego vehicle is in the lane center; the emergency braking detection is used to determine whether the braking of the ego vehicle is too urgent to affect the driving comfort; the acceleration detection is used to determine whether the acceleration / deceleration of the ego vehicle exceeds a preset threshold and whether the acceleration / deceleration frequency is too high; the unnecessary braking detection is used to determine whether the ego vehicle has unnecessary braking behavior; and the smoothness detection is used to determine whether the speed fluctuation of the ego vehicle is too large.

[0024] In the foregoing embodiments of the present application, the test content of each detection type is specifically described, the test is highly targeted and comprehensive, and the implementation is strong.

[0025] In a possible design of the first aspect, in order to ensure the completeness of the classification of the traffic scenario library, the embodiments of the present application divide the traffic scenario types to which the traffic scenario files in the traffic scenario library belong into 9 categories in a cross manner, that is, the traffic scenario files for testing free driving in the current lane, the traffic scenario files for testing obstacle avoidance driving in the current lane, the traffic scenario files for testing left lane change, the traffic scenario files for testing right lane change, the traffic scenario files for testing left lane change cancellation, the traffic scenario files for testing right lane change cancellation, the traffic scenario files for testing following in the current lane, the traffic scenario files for testing stopping in the current lane due to obstacles, and the traffic scenario files for testing parking on the roadside. Therefore, in the embodiments of the present application, for different test purposes, the plurality of traffic scenario files in the traffic scenario library at least include at least one of the 9 categories of traffic scenario types.

[0026] In the above-mentioned embodiments of the present application, the types of traffic scenarios included in the traffic scenario library being constructed, the number of traffic scenario files of each type, and the proportion of traffic scenario files belonging to different traffic scenario types can be customized, and the flexibility is high.

[0027] The second aspect of the embodiments of the present application provides a simulation device having a function of implementing the method of the above-mentioned first aspect or any one of the possible implementation manners of the first aspect. The function can be implemented by hardware, or can be implemented by hardware executing corresponding software. The hardware or software includes one or more modules corresponding to the above-mentioned function.

[0028] The third aspect of the embodiments of the present application provides a simulation device, which can include a memory, a processor, and a bus system, wherein the memory is used to store a program, and the processor is used to call the program stored in the memory to execute the method of the first aspect of the present application or any one of the possible implementation manners of the first aspect.

[0029] The fourth aspect of the present application provides a computer readable storage medium, which stores instructions, and when the instructions are run on a computer, the computer can execute the method of the above-mentioned first aspect or any one of the possible implementation manners of the first aspect.

[0030] The fifth aspect of the embodiments of the present application provides a computer program or computer program product, which, when run on a computer, makes the computer execute the method of the above-mentioned first aspect or any one of the possible implementation manners of the first aspect. BRIEF DESCRIPTION OF DRAWINGS

[0031] Figure 1 A schematic diagram of a currently existing method of constructing a simulation traffic flow;

[0032] Figure 2 A flowchart of the method of constructing a simulation traffic flow provided by the embodiments of the present application;

[0033] Figure 3 A visual process diagram of importing a certain traffic scenario file into simulation software for running provided by the embodiments of the present application;

[0034] Figure 4 A schematic diagram of a constructed traffic scenario library provided by the embodiments of the present application;

[0035] Figure 5 A schematic diagram of a switching process between two scenarios provided by the embodiments of the present application;

[0036] Figure 6An example of continuously reading traffic scenario files from a traffic scenario library until a preset condition is reached is provided for the embodiments of the present application;

[0037] Figure 7 Another example of continuously reading traffic scenario files from a traffic scenario library until a preset condition is reached is provided for the embodiments of the present application;

[0038] Figure 8 Another example of continuously reading traffic scenario files from a traffic scenario library until a preset condition is reached is provided for the embodiments of the present application;

[0039] Figure 9 An internal logic diagram of continuous scenario allocation is provided for the embodiments of the present application;

[0040] Figure 10 A structural diagram of a simulation device is provided for the embodiments of the present application;

[0041] Figure 11 A structural diagram of another simulation device is provided for the embodiments of the present application;

[0042] Figure 12 A structural diagram of another simulation device is provided for the embodiments of the present application;

[0043] Figure 13 A structural diagram of another simulation device is provided for the embodiments of the present application. DETAILED DESCRIPTION

[0044] The embodiments of the present application provide a construction method of simulating traffic flow and a simulation device, which are used for reading traffic scenario files from a traffic scenario library constructed in a forward direction, realizing continuous allocation of different simulation scenarios, and thus generating a simulation traffic flow capable of covering a test part of continuous switching of different simulation scenarios.

[0045] The terms "first", "second", etc. in the specification and claims of the present application and in the above-described drawings are used to distinguish similar objects, and do not necessarily indicate a specific order or sequence. It should be understood that the terms thus used can be interchanged under appropriate circumstances, which is merely a distinguishing manner adopted in the description of the embodiments of the present application for the objects with the same attribute in the description. In addition, the terms "include" and "have" and any variations thereof are intended to cover non-exclusive inclusion, so that a process, method, system, product or device containing a series of units does not have to be limited to those units, but can include other units not clearly listed or inherent to the process, method, product or device.

[0046] In order to better understand the scheme of the embodiments of the present application, the related terms and concepts that may be involved in the embodiments of the present application are introduced as follows.

[0047] Traffic flow: refers to the flow formed by the continuous driving of vehicles on the road, and in a broad sense, it also includes the flow of other vehicles and the flow of people. In a certain period of time, on the road section not affected by the transverse intersection, the traffic flow is in a continuous flow state, and when encountering a signal light control at the intersection, it is in a discontinuous flow state. Generally, according to the composition in the traffic flow, the traffic flow can be divided into: motor vehicle flow, non-motor vehicle flow, and mixed traffic flow.

[0048] Traffic flow simulation: constructing a traffic flow of a target demand in a simulation scene, or simulating a traffic flow in a real scene, for constructing a dynamic simulation field and testing related functions and performance of an intelligent driving vehicle. In the embodiments of the present application, for the convenience of understanding, the simulation traffic flow is taken as an example for illustration.

[0049] Forward construction of traffic scene library: refers to a method of constructing a traffic scene library based on knowledge, which depends on the specific scene structure, comprehensively learns the knowledge of various related disciplines, analyzes the types of static and dynamic elements that need to be processed by the autonomous driving system, and combines the test requirements of the autonomous driving system to obtain the traffic scene library. This forward construction method emphasizes interpretability. Compared with the traditional collection of raw traffic flow data (that is, analyzing and extracting valuable scenes from the collected raw traffic flow data, which is a data-based analysis method), the types of scenes included in the forwardly constructed traffic scene library and the number of each type of scene are clear. In the embodiments of the present application, the traffic scene library is constructed by the present application, and the traffic scene library constructed by the present application includes a plurality of traffic scene files. The plurality of traffic scene files can belong to different traffic scene types, and the traffic scene types are divided according to the preset principle in the embodiments of the present application.

[0050] Simulation scene: also known as virtual scene, a virtual scene for testing an intelligent driving vehicle in a simulation environment, which contains static, quasi-static and dynamic elements and other multi-dimensional elements.

[0051] The embodiments of the present application will be described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present application, not all the embodiments. Those skilled in the art can know that, with the development of technology and the appearance of new scenes, the technical solutions provided by the embodiments of the present application are also applicable to similar technical problems.

[0052] First, the present application provides a method for constructing a simulation traffic flow, as shown in Figure 2 The method can include the following steps:

[0053] 201、positively constructing a traffic scenario library, the traffic scenario library comprising a plurality of traffic scenario files, each of the plurality of traffic scenario files comprising a duration of a respective traffic scenario and a running state of a simulated vehicle at each unit time within the duration in the respective traffic scenario.

[0054] Firstly, a traffic scenario library meeting the test needs is positively constructed. The traffic scenario library constructed in the present application comprises a plurality of traffic scenario files, that is, the plurality of traffic scenario files positively constructed are a plurality of scene files constructed based on subject knowledge. Unlike traditional collection of traffic flow raw data (that is, valuable scenes are analyzed and extracted from collected real traffic flow raw data, which is a data-based analysis method), it is clear what types of traffic scenarios are included in the positively constructed traffic scenario library and the number of each type of traffic scenario. Each traffic scenario file corresponds to a type of traffic scenario. The traffic scenario types are divided according to a preset principle. The single-function scenarios faced by autonomous driving can be classified through test analysis of autonomous driving scenarios, such as following a car, stopping when encountering an obstacle, and changing lanes to the left or right. The actual road scenarios faced by autonomous driving can also be classified, such as rural road scenarios, no-lane-line scenarios, intersection scenarios, highway scenarios, and mountain road scenarios. The specific principle for dividing traffic scenario types is not limited. It should be noted that the various traffic scenarios described in the embodiments of the present application refer to traffic application scenarios.

[0055] Preferably, in order to ensure the completeness of the traffic scenario library, in some embodiments of the present application, considering that the action issued by the autonomous driving planning control part includes horizontal and vertical parts, the corresponding function points are orthogonally output to obtain the corresponding traffic scenario types, ensuring the completeness of the test analysis. One specific classification of traffic scenario types can be as shown in Table 1:

[0056] Table 1: One classification example of traffic scenario types in the traffic scenario library

[0057]

[0058] As can be seen from Table 1, in order to ensure the completeness of the classification of the traffic scenario library, the embodiments of the present application divide the traffic scenario types to which the traffic scenario files in the traffic scenario library belong into 9 categories by an orthogonal method, which are: traffic scenario files for testing free driving in the current lane, traffic scenario files for testing obstacle avoidance and detour in the current lane, traffic scenario files for testing left lane changing, traffic scenario files for testing right lane changing, traffic scenario files for testing cancellation of left lane changing, traffic scenario files for testing cancellation of right lane changing, traffic scenario files for testing following a car in the current lane, traffic scenario files for testing stopping when encountering an obstacle in the current lane, and traffic scenario files for testing parking on the side of the road.

[0059] The above classification method has the following advantages: 1) compared with collecting real traffic flow data, no labeling is required, the cost is low, and it is easy to obtain; 2) comprehensive consideration, not limited by collected data, can guarantee test completeness (traditional simulation traffic flow is biased towards blind measurement or uses neural network to learn traffic flow in a specific area and generates random traffic flow, both of which cannot explain how many scenarios are tested, and the scene coverage has poor explainability), while avoiding the limitations of real traffic flow data in terms of region and time; 3) the number of each type of traffic scene file and the proportion of traffic scene files belonging to different traffic scene types can be customized, and the flexibility is high.

[0060] It should be noted that the 9 categories of traffic scene types of the traffic scene files in the above traffic scene library are to ensure the completeness of the traffic scene types in the traffic scene library, and in some embodiments of the present application, the traffic scene types of the traffic scene files in the traffic scene library can also be constructed for different test purposes. For example, if only lane centering detection is desired, the traffic scene library constructed can only include at least one of the three traffic scene types of the traffic scene files for testing free driving in the current lane, the traffic scene files for testing following in the current lane, and the traffic scene files for testing stopping due to obstacles in the current lane.

[0061] In summary, in the embodiments of the present application, the traffic scene library constructed in the positive direction includes a plurality of traffic scene files, which can include at least one of the above 9 categories of traffic scene types based on different test purposes. Similarly, which traffic scene types are included in the traffic scene library constructed in the positive direction, the number of each type of traffic scene file, and the proportion of traffic scene files belonging to different traffic scene types can be customized, and the flexibility is high.

[0062] It should be noted that the traffic scene files described above include the duration of each traffic scene and the running state of each simulation vehicle at each unit time within the duration of each traffic scene. For ease of understanding, the following examples are provided for illustration. Please refer to Figure 3 The visualization process of importing a simulation software for a certain traffic scene file is assumed to have a traffic scene duration of 30 seconds, a refresh frequency of 1 time per second for each simulation vehicle, and 4 simulation vehicles in this scenario (such as Figure 3If the traffic scenario file corresponds to a scenario duration of 30 seconds and each simulation vehicle has a refresh frequency of 2 seconds, then there are 15 unit instants (every 2 seconds in 30 seconds corresponds to a unit instant) in the duration, and each simulation vehicle saves the relevant parameters of a corresponding running state at each unit instant (i.e., the 2ndsecond, the 4thsecond, the 6thsecond,..., the 30thsecond are the 1stunit instant, the 2ndunit instant,..., the 15thunit instant, respectively), which can be, for example, the position and speed of the simulation vehicle. The running state of each simulation vehicle corresponding to the first unit instant (i.e., the 2ndsecond in 30 seconds) of the traffic scenario file can be referred to as the initial state of the traffic scenario file, and the running state of each simulation vehicle corresponding to the last unit instant (i.e., the 30thsecond in 30 seconds, which is the 15thunit instant) of the traffic scenario file can be referred to as the terminal state of the traffic scenario file. Figure 3 For example, the simulation vehicle of the dashed line is in the running state of the previous unit instant, and the simulation vehicle of the solid line is in the running state of the current unit instant. For example, still taking Figure 3 as an example, assuming that the traffic scenario file corresponds to a scenario duration of 30 seconds, each simulation vehicle has a refresh frequency of 2 seconds, and there are 4 simulation vehicles in the scenario, then there are 15 unit instants (every 2 seconds in 30 seconds corresponds to a unit instant) in the duration, and each simulation vehicle saves the relevant parameters of a corresponding running state at each unit instant (i.e., the 2ndsecond, the 4thsecond, the 6thsecond,..., the 30thsecond are the 1stunit instant, the 2ndunit instant,..., the 15thunit instant, respectively), which can be, for example, the position and speed of the simulation vehicle. The running state of each simulation vehicle corresponding to the first unit instant (i.e., the 2ndsecond in 30 seconds) of the traffic scenario file can be referred to as the initial state of the traffic scenario file, and the running state of each simulation vehicle corresponding to the last unit instant (i.e., the 30thsecond in 30 seconds, which is the 15thunit instant) of the traffic scenario file can be referred to as the terminal state of the traffic scenario file.

[0063] For ease of understanding, a traffic scenario library constructed in a forward direction is shown as follows, please refer to Figure 4 A traffic scenario library constructed by the embodiments of the present application, which includes n traffic scenario types (n≥1) such as scenario type A, scenario type B,..., and scenario type N. Each traffic scenario type includes a certain number of traffic scenario files (which can be set by the user), and each traffic scenario file includes the relevant parameter information of each simulation vehicle in the scenario (such as the running state at each unit instant described above). Taking scenario file A1 as an example, scenario file A1 includes the duration T of the scenario, the position and speed (t is a certain unit time), the position of the vehicle 2 at each unit time and speed ,..., the position of the vehicle m at each unit time and speed .

[0064] It should be noted that although the traffic scenario library is obtained by forward construction, if a high-risk scenario is encountered in a real driving scenario, it can also be abstracted into a traffic scenario file and supplemented into the traffic scenario library, so that the forms of the scenarios in the traffic scenario library are more diverse.

[0065] 202. Read a first traffic scenario file from the traffic scenario library.

[0066] After the traffic scenario library is constructed, the simulation device can read a traffic scenario file from the traffic scenario library, and the currently read traffic scenario file can be referred to as a first traffic scenario file. In the embodiments of the present application, the simulation device can be any form of computer device, such as a personal computer, a server, etc., and the specific form is not limited here.

[0067] It should be noted that the simulation device can read the traffic scenario file from the traffic scenario library in the following ways, but is not limited to: 1) each traffic scenario file included in the traffic scenario library can be stored in the storage module of the simulation device, and the simulation device can directly read from the storage module; 2) each traffic scenario file included in the traffic scenario library is stored in another device, and the simulation device reads the traffic scenario file from the other device through wireless connection or wired connection.

[0068] 203. Control the simulation vehicle to transition from a second running state to a first running state, the second running state being the running state of the simulation vehicle at the last unit time of the second traffic scenario file, the first running state being the running state of the simulation vehicle at the first unit time of the first traffic scenario file, the second traffic scenario file being the traffic scenario file on which the first simulation scenario is generated by the simulation software.

[0069] After the simulation device reads the first traffic scenario file, it can control each simulation vehicle through the control interface of the simulation software. Specifically, first, control each simulation vehicle to transition from a second running state to a first running state, wherein the second running state is the running state of the simulation vehicle at the last unit time of the second traffic scenario file (i.e., the termination state of the previous traffic scenario file), the first running state is the running state of the simulation vehicle at the first unit time of the first traffic scenario file (i.e., the initial state of the current traffic scenario file), and the second traffic scenario file is the traffic scenario file on which the first simulation scenario is generated by the simulation software. Whether it is the first traffic scenario file or the second traffic scenario file, it is a traffic scenario file read from the traffic scenario library.

[0070] It should be noted that, in some embodiments of the present application, the simulation device controlling the simulation vehicle to transition from the second operating state to the first operating state can be to control the simulation vehicle to transition from the second operating state to the first operating state within a specified time (e.g., within 3 seconds) by the self-contained driver model, and the advantage of such switching is that the self-contained driver model is generally an ideal driving model, which can make the switching between the two scenes smooth and the operating curve of the simulation vehicle smoother. The driving style (e.g., aggressive, conservative, etc.) of the driver model of each simulation vehicle can be set by itself, and details are not repeated here.

[0071] 204、with the first operating state as the starting state, generating a second simulation scene according to the first traffic scene file by the simulation software.

[0072] After the simulation device controls each simulation vehicle to transition from the second operating state to the first operating state, the first operating state is taken as the starting state, and the second simulation scene is continuously generated according to the first traffic scene file, wherein the first simulation scene is the simulation scene generated last time before the second simulation scene.

[0073] It should be noted that, in some embodiments of the present application, if the first traffic scene file is the first traffic scene file for building the simulation traffic flow, then in this case, no transition is needed, and the current simulation scene can be directly generated by the simulation software.

[0074] 205、repeating steps 202 to 204 until a preset condition is reached.

[0075] After the simulation device controls each simulation vehicle to run through a simulation scene, it further switches to the next simulation scene for continuous running, and steps 202 to 204 are repeatedly executed until a preset condition is reached, so that multiple traffic scene files are continuously and sequentially imported into the simulation software and run, and the simulation scenes obtained in sequence form a continuous simulation traffic flow, which covers the test part of the continuous switching of different simulation scenes.

[0076] It should be noted that, if there are only two traffic scene files in the traffic scene library, or the simulation device only needs to read two traffic scene files, then in some embodiments of the present application, step 205 can not be needed.

[0077] It should be further noted that, in some embodiments of the present application, the order of reading the traffic scene files is not limited, which can be sequentially read from the traffic scene library at random, or can be read according to a preset rule, such as preferentially reading the traffic scene files that have not been read, and details are not limited here.

[0078] The following is an example ofFigure 5 For example, it is specifically shown how to switch between two scenarios. First, the simulation device reads the traffic scenario file corresponding to scenario 1 from the traffic scenario library and imports the traffic scenario file into the simulation software, and then the simulation software runs scenario 1 based on the traffic scenario file. When scenario 1 ends, the running state of each simulation vehicle (for example, three simulation vehicles are taken as an example) is the termination state of scenario 1, as shown in the solid line on the left half of the simulation vehicle in Figure 5 For example, it is specifically shown how to switch between two scenarios. First, the simulation device reads the traffic scenario file corresponding to scenario 1 from the traffic scenario library and imports the traffic scenario file into the simulation software, and then the simulation software runs scenario 1 based on the traffic scenario file. When scenario 1 ends, the running state of each simulation vehicle (for example, three simulation vehicles are taken as an example) is the termination state of scenario 1, as shown in the solid line on the left half of the simulation vehicle in Figure 5 For example, it is specifically shown how to switch between two scenarios. First, the simulation device reads the traffic scenario file corresponding to scenario 1 from the traffic scenario library and imports the traffic scenario file into the simulation software, and then the simulation software runs scenario 1 based on the traffic scenario file. When scenario 1 ends, the running state of each simulation vehicle (for example, three simulation vehicles are taken as an example) is the termination state of scenario 1, as shown in the solid line on the left half of the simulation vehicle in Figure 5 For example, it is specifically shown how to switch between two scenarios. First, the simulation device reads the traffic scenario file corresponding to scenario 1 from the traffic scenario library and imports the traffic scenario file into the simulation software, and then the simulation software runs scenario 1 based on the traffic scenario file. When scenario 1 ends, the running state of each simulation vehicle (for example, three simulation vehicles are taken as an example) is the termination state of scenario 1, as shown in the solid line on the left half of the simulation vehicle in

[0079] It should be noted that in the embodiments of the present application, the simulation vehicles set by different scenarios may also be different, Figure 5 For example, it is specifically shown how to switch between two scenarios. First, the simulation device reads the traffic scenario file corresponding to scenario 1 from the traffic scenario library and imports the traffic scenario file into the simulation software, and then the simulation software runs scenario 1 based on the traffic scenario file. When scenario 1 ends, the running state of each simulation vehicle (for example, three simulation vehicles are taken as an example) is the termination state of scenario 1, as shown in the solid line on the left half of the simulation vehicle in Figure 5 For example, it is specifically shown how to switch between two scenarios. First, the simulation device reads the traffic scenario file corresponding to scenario 1 from the traffic scenario library and imports the traffic scenario file into the simulation software, and then the simulation software runs scenario 1 based on the traffic scenario file. When scenario 1 ends, the running state of each simulation vehicle (for example, three simulation vehicles are taken as an example) is the termination state of scenario 1, as shown in the solid line on the left half of the simulation vehicle in Figure 5 For example, it is specifically shown how to switch between two scenarios. First, the simulation device reads the traffic scenario file corresponding to scenario 1 from the traffic scenario library and imports the traffic scenario file into the simulation software, and then the simulation software runs scenario 1 based on the traffic scenario file. When scenario 1 ends, the running state of each simulation vehicle (for example, three simulation vehicles are taken as an example) is the termination state of scenario 1, as shown in the solid line on the left half of the simulation vehicle in

[0080] It should be noted that in the embodiments of the present application, the simulation vehicles set by different scenarios may also be different,

[0081] It should be noted that in the embodiments of the present application, the simulation vehicles set by different scenarios may also be different,

[0082] It should be further noted that the simulation vehicle in the embodiments of the present application presents different modes in different simulation test modes, for example, the simulation device can flexibly adapt to different types of simulation test modes such as software-in-the-loop (SIL) simulation mode, hardware-in-the-loop (HIL) simulation mode, vehicle-in-the-loop (VIL) simulation mode, etc., which is a common method in the industry, and will not be described here. In the above embodiments of the present application, the simulation vehicle is presented in the form of a vehicle for ease of understanding.

[0083] It should be further noted that in some embodiments of the present application, there are various ways to judge whether the preset condition is met, including but not limited to the following:

[0084] (1) When the number of simulation scenarios generated by the simulation software reaches a preset value, it means that the preset condition is met.

[0085] For details, please refer to Figure 6 , Figure 6 For an example of continuously reading traffic scenario files from the traffic scenario library until the preset condition is met, the simulation device reads the traffic scenario file corresponding to scenario i from the traffic scenario library, and loads the initial state corresponding to scenario i to each simulation vehicle. After each simulation vehicle obtains the initial state of scenario i, it uses the built-in driver model to transition (the driver model style can be customized), that is, from the end state of the previous scenario i-1 to the initial state of the current scenario i. Then it is judged whether the transition is completed within the specified time length. If not, the transition process is repeated. If yes, it enters the initial state of scenario i and runs the current scenario i until the end (i.e., moves according to the positions and speeds of each simulation vehicle at different unit times in the corresponding traffic scenario file), and further judges whether i=i+1 reaches the preset value n. If not, the above process is repeated and the traffic scenario file is continuously read from the traffic scenario library. If yes, the traffic scenario file is not continuously read from the traffic scenario library and the simulation ends. For example, assuming that the preset value n is set to 300, when i=i+1<300, it means that the preset condition has not been met, and the traffic scenario file is continuously read from the traffic scenario library. At this time, the simulation traffic flow is in a continuous construction process. When i=i+1=300, it means that the preset condition is met, and the 300 continuous read and run simulation scenarios constitute the simulation traffic flow described in the present application.

[0086] (2) When the running time length of the simulation software reaches a preset time length, it means that the preset condition is met.

[0087] For details, please refer to Figure 7 , Figure 7Another embodiment provided by the present application is to continuously read traffic scenario files from the traffic scenario library until a preset condition is reached, which is similar to the above embodiment, except that Figure 6 In the corresponding embodiment, the difference is that Figure 7 The judgment is whether the running time of the simulation software reaches the preset time t, if not, the above process is repeated to continue reading traffic scenario files from the traffic scenario library; if so, the simulation ends without continuing to read traffic scenario files from the traffic scenario library. For example, assuming that the preset time t is set to 20 hours (h), every time the scene i ends, the simulation device will judge once whether the running time of the current simulation software reaches 20 hours, when the scene i ends and The running time of the simulation software does not reach 20 hours, it means that the preset condition is not reached, and the simulation traffic flow is in the process of continuous construction, so the simulation device continues to read traffic scenario files from the traffic scenario library; when the scene i ends and The running time of the simulation software reaches 20 hours, it means that the preset condition is reached, so the simulation device does not continue to read traffic scenario files from the traffic scenario library after the current scene i ends.

[0088] (3) Each traffic scenario file in the traffic scenario library is read at least once, which means that the preset condition is reached.

[0089] For details, please refer to Figure 8 , Figure 8 Another embodiment provided by the present application is to continuously read traffic scenario files from the traffic scenario library until a preset condition is reached, which is similar to the above embodiment, except that Figure 6 In the corresponding embodiment, the difference is that Figure 8 The judgment is whether each traffic scenario file in the traffic scenario library is read at least once, if there is a traffic scenario file in the traffic scenario library that is not read at all, it means that the preset condition is not reached, then the above process is repeated to continue reading traffic scenario files from the traffic scenario library; if each traffic scenario file is read at least once, it means that the preset condition is reached, so the simulation ends without continuing to read traffic scenario files from the traffic scenario library after the current scene i ends.

[0090] It should be noted that in some embodiments of the present application, for the read traffic scenario files, the simulation device will be marked, and then read again, which can be read from the remaining traffic scenario files that have not been read, or can be randomly read in the entire traffic scenario library (i.e. without distinguishing between read and unread traffic scenario files), but all traffic scenario files in the entire traffic scenario library are read at least once. The reading method of the traffic scenario file is not limited here.

[0091] ​The constructed simulation traffic flow can be used for various purposes, for example, to reproduce or pre-understand the traffic operation of an existing system or a future system, so as to explain and analyze complex traffic phenomena; or to optimize the traffic system being studied. The use of the constructed simulation traffic flow is not limited here.

[0092] Preferably, in the embodiments of the present application, the constructed simulation traffic flow can be specifically used for testing the related functions and performance of the intelligent driving vehicle. Therefore, in some embodiments of the present application, the automatic driving algorithm to be tested can also be imported into the simulation software described above to test the performance of the related automatic driving algorithm in each scenario of the constructed simulation traffic flow. Based on different detection types, the target simulation vehicle equipped with the automatic driving algorithm can be tested to obtain the test results in each simulation scenario. Specifically, in the first aspect, the traffic rules in the real world can be abstracted into result evaluation criteria, and then the speed, position and other state information of the ego vehicle (i.e., the target simulation vehicle) and the surrounding vehicles (i.e., each simulation vehicle in each scenario) during the entire test process are read through simulation testing, so as to quantitatively evaluate the performance of the ego vehicle in the simulation traffic flow. Finally, the result evaluation report in each simulation scenario can be implemented with strong practicability. The detection types of the result evaluation report include, but are not limited to, at least one of collision detection, speed limit detection, on-road detection, intersection lane change detection, end point detection, lane centering detection, sudden braking detection, acceleration detection, unnecessary braking detection or smoothness detection. The item description of each detection type can be as shown in Table 2:

[0093] Table 2: Detection types of result evaluation report

[0094]

[0095] In the second aspect, when the test result does not meet the preset requirements, the simulation device marks the traffic scenario file corresponding to the test result. The purpose of the marking is to improve the frequency of reading the traffic scenario file corresponding to the test result in the future when reading the traffic scenario file from the traffic scenario library, i.e., to make the frequency of reading the first traffic scenario file after marking higher than the frequency of reading the first traffic scenario file before marking. For ease of understanding, the following example is given: when the ego vehicle is subjected to collision detection, it is found that the test result of the ego vehicle in the simulation scenario w does not meet the preset safety requirement (e.g., a scratch occurs with a surrounding simulation vehicle), so the simulation device can mark the traffic scenario file w' corresponding to the simulation scenario w. Based on the marking, the frequency of reading the traffic scenario file w' is improved, and the traffic scenario file w' is more likely to be read by the simulation software in the future. The advantage of this is that a difficult example library can be formed in a closed loop, and the simulation scenario with poor test results can be repeatedly tested to improve the optimization efficiency of the automatic driving algorithm.

[0096] It should be noted here that in the embodiments of the present application, it is not limited to when the automatic driving algorithm is imported into the simulation software. It can be imported before the simulation traffic flow is constructed, or it can be imported during the running of the scene. The specific time is not limited here.

[0097] In the above embodiments of the present application, first, for different simulation test purposes, a traffic scene library conforming to the test requirements is constructed in a forward direction. The number of traffic scene files of each type of traffic scene in the traffic scene library and the proportion of traffic scene files belonging to different traffic scene types can be customized, which has high flexibility, low cost and is easy to obtain compared to collecting real traffic flow data, without labeling; and it is comprehensive and not limited by the collected data, which can ensure test completeness; second, the simulation device reads the traffic scene files from the forwardly constructed traffic scene library to realize the continuous allocation of different simulation scenes, so that the generated simulation traffic flow can cover the test part of the continuous switching of different simulation scenes.

[0098] For ease of understanding, the test process of the automatic driving algorithm is described below with a real test example. Please refer to Figure 9 , Figure 9 The internal logic diagram for continuous scene allocation is shown, taking the follow-stop and start functions of adaptive cruise control (ACC) as an example. Assuming that the performance of an automatic driving algorithm in the follow-stop and start functions of ACC needs to be tested, a traffic scene library conforming to the requirements needs to be constructed in advance. Since the follow-stop and start functions of ACC are essentially a combination of lane following and obstacle stopping, the constructed traffic scene library should include traffic scene files of 2 types of traffic scenes, i.e., traffic scene files for testing lane following and traffic scene files for testing lane obstacle stopping. Each type of traffic scene has multiple corresponding traffic scene files, and the traffic scene files of different traffic scene types are cross-read in advance, i.e., the simulation device reads a traffic scene file for testing lane following, then reads a traffic scene file for testing lane obstacle stopping, and then reads a traffic scene file for testing lane following, and so on, until the number of generated simulation scenes reaches a preset value (e.g., 500 times). After the traffic scene library is constructed, the corresponding automatic driving algorithm can be imported into the simulation software, and then the first traffic scene file for lane following (assuming that the traffic scene file is follow_001) is read to run the state (i.e., the simulation device reads the traffic scene file follow_001 to run the state of the first traffic scene file for lane following) of the first traffic scene file for lane following, and then the second traffic scene file for lane obstacle stopping (assuming that the traffic scene file is stop_001) is read to run the state of the second traffic scene file for lane obstacle stopping, and then the third traffic scene file for lane following (assuming that the traffic scene file is follow_002) is read to run the state of the third traffic scene file for lane following, and so on, until the number of generated simulation scenes reaches a preset value (e.g., 500 times). Figure 9 The simulation device reads the traffic scene files through the control unit of the simulation device) a traffic scene file for testing lane following, then reads a traffic scene file for testing lane obstacle stopping, and then reads a traffic scene file for testing lane following, and so on, until the number of generated simulation scenes reaches a preset value (e.g., 500 times). After the traffic scene library is constructed, the corresponding automatic driving algorithm can be imported into the simulation software, and then the first traffic scene file for lane following (assuming that the traffic scene file is follow_001) is read to run the state (i.e., the simulation device reads the traffic scene file follow_001 to run the state of the first traffic scene file for lane following) of the first traffic scene file for lane following, and then the second traffic scene file for lane obstacle stopping (assuming that the traffic scene file is stop_001) is read to run the state of the second traffic scene file for lane obstacle stopping, and then the third traffic scene file for lane following (assuming that the traffic scene file is follow_002) is read to run the state of the third traffic scene file for lane following, and so on, until the number of generated simulation scenes reaches a preset value (e.g., 500 times). Figure 9(①) This operating state includes, but is not limited to, the duration of the corresponding scenario and the operating state of each simulated vehicle within the duration at each unit of time. The operating state of each simulated vehicle corresponding to the first unit of time in the traffic scenario file is called the initial state of the corresponding scenario, and the operating state of each simulated vehicle corresponding to the last unit of time in the traffic scenario file is called the final state of the corresponding scenario. The read traffic scenario file follow_001 can be switched by the switching module within the control unit to access the external interface of the simulation software (i.e.,...). Figure 9 (②) First, the control mode of each simulated vehicle's built-in driver model is switched via the switching module (i.e., ... Figure 9 (③) The initial state of the current traffic scene file follow_001 is sent to each simulated vehicle, and the driver model controls each simulated vehicle to transition to the initial state of the traffic scene file follow_001 within a specified time (i.e., Figure 9 (④) If each simulated vehicle completes the transition within the specified time, feedback is sent to this module (i.e., ... Figure 9 (⑤ in the text), and then this module switches the control mode of the simulated vehicle to the external input control mode (i.e., Figure 9 (⑥) causes the simulated vehicle to perform actions according to the preset scenario in the traffic scenario file follow_001 until the end (i.e. Figure 9 (⑦) Next, the feedback information is sent to the control unit (i.e., ... Figure 9 (⑧) The control unit marks the traffic scene file follow_001 in the traffic scene library accordingly (i.e.) Figure 9 (9) For example, a flag indicating that the data has been read, or a flag indicating that the algorithm has passed the test for the traffic scenario file. Afterwards, the control unit continues to read the running status of the first traffic scenario file for the obstacle-related stop (assuming this traffic scenario file is stop_bf_obstacle_001), i.e., returns to... Figure 9 In step ①, the traffic scene file stop_bf_obstacle_001, which is read, continues to be switched by the switching module to access the external interface of the simulation software (i.e., ... Figure 9 (②) First, the control mode of each simulated vehicle's built-in driver model is switched via the switching module (i.e., ... Figure 9 (③) The initial state of the current traffic scene file stop_bf_obstacle_001 is sent to each simulation vehicle. The driver model, which comes with the vehicle, controls the simulation vehicle to transition to the initial state of the traffic scene file stop_bf_obstacle_001 within a specified time (i.e., ...). Figure 9 (④) If each simulated vehicle completes the transition within the specified time, feedback is sent to this module (i.e., ... Figure 9⑤) in the method 1000, then the module switches the control mode of the simulation vehicle to the external input control mode (i.e. Figure 9 ⑥) in the method 1000, and makes the simulation vehicle act according to the preset scene of the traffic scene file stop_bf_obstacle_001 until the end (i.e. Figure 9 ⑦) in the method 1000. Similarly, the end information is fed back to the control unit (i.e. Figure 9 ⑧) in the method 1000, and the control unit marks the traffic scene file stop_bf_obstacle_001 in the traffic scene library (i.e. Figure 9 ⑨) in the method 1000, such as marking that the traffic scene file has been read, or marking that the algorithm has been tested by the traffic scene file, and so on. In this way, the traffic scene files of the following and stopping-by-obstacle scenes are called from the traffic scene library, and each scene is run by the simulation software to form a simulation traffic flow for testing the related automatic driving algorithm of the following and stopping functions of the ACC.

[0099] In the embodiment corresponding to the method 1000, the simulation device 100 is provided, as shown in FIG. 2. Figure 2 to Figure 9 In order to better implement the above-mentioned scheme of the embodiment of the present application, the related equipment for implementing the above-mentioned scheme is further provided below. For details, please refer to Figure 10 , Figure 10 FIG. 2 is a structural schematic diagram of a simulation device provided by the embodiment of the present application. The simulation device 100 runs the simulation software 1001, and further includes a traffic scene library 1002 and a control unit 1003. The traffic scene library 1002 is obtained by being constructed in a forward direction according to the test purpose in advance, and includes a plurality of traffic scene files. Each traffic scene file includes the duration of the corresponding scene and the running state of each simulation vehicle in the corresponding scene at each unit time within the duration. The control unit 1003 is used to read the traffic scene files from the traffic scene library 1002 in sequence and import them into the simulation software 1001, so as to realize the continuous transition between the plurality of scenes and form a simulation traffic flow. The simulation software 1001 is used to run the imported traffic scene files to generate the corresponding simulation scene.

[0100] In a possible design, the simulation device 100 can further include a result evaluation unit 1004. The result evaluation unit 1004 quantitatively evaluates the performance of the ego vehicle in the traffic flow by reading the state information such as the speed, acceleration and position of the ego vehicle (i.e. the target simulation vehicle) and each simulation vehicle in the scene during the entire test process, including but not limited to collision detection, overspeed detection, emergency braking detection, and so on, and outputs the detection result in real time. Meanwhile, the detection result can also be used as the input of the traffic scene library classification, records the corresponding traffic scene file, and forms a difficult example library (such as a scene that fails the test) in a closed loop to promote the continuous optimization of the algorithm design.

[0101] In a possible design, the simulation device 100 can further include an optional module 1005, which can include one or more of a domain controller 1051, simulation hardware 1052, a vehicle dynamics model 1053, etc., and is configured to flexibly adapt to different types of simulation tests, such as SiL, HiL, and ViL, details of which are not described herein.

[0102] It should be noted that, in some embodiments of the present application, the control unit 1003 and the result evaluation unit 1004 can be plug-ins of the simulation software 1001, or can be independent modules, details of which are not limited herein.

[0103] It should be further noted that the information interaction and execution process between the modules / units in the simulation device 100 are the same as those of the simulation device 100 described in the foregoing embodiments of the present application, and details are not described herein. Figure 2 to Figure 9 The respective embodiments correspond to the same concept, and details can be referred to the descriptions in the foregoing embodiments of the present application, which are not described herein.

[0104] In addition, the embodiments of the present application further provide a simulation device 110, which can be referred to the simulation device 100 described in the foregoing embodiments of the present application. Figure 11 , Figure 11Another structural diagram of the simulation device provided by the embodiment of the present application is shown in FIG. 11. The simulation device 110 includes a reading module 1101, a transition module 1102, and a simulation module 1103. The reading module 1101 is configured to read a first traffic scenario file from a traffic scenario library. The traffic scenario library is obtained by forward construction and includes a plurality of traffic scenario files. The plurality of traffic scenario files obtained by forward construction are a plurality of scenario files constructed based on subject knowledge. Unlike traditional collected traffic flow raw data (i.e., valuable scenarios are analyzed and extracted from collected real traffic flow raw data, which is a data-based analysis method), the types of traffic scenarios included in the traffic scenario library obtained by forward construction and the number of each type of traffic scenario are explicit. Each traffic scenario file in the plurality of traffic scenario files includes a duration of a respective traffic scenario and a running state of each simulation vehicle at each unit time within the duration of the respective traffic scenario. Each traffic scenario file corresponds to a traffic scenario type. The traffic scenario type is divided according to a preset principle. The single-function scenarios faced by autonomous driving can be classified through test analysis of the autonomous driving scenarios, such as following driving, stopping when encountering an obstacle, and left-right lane changing. The actual road scenarios faced by autonomous driving can also be classified, such as rural road scenarios, no-lane-line scenarios, intersection scenarios, highway scenarios, and mountain road scenarios. The specific principle for dividing the traffic scenario type is not limited. The transition module 1102 is configured to control each simulation vehicle to transit from a second running state to a first running state. The second running state is a running state of each simulation vehicle at a last unit time of a second traffic scenario file, i.e., a termination state of the last read traffic scenario file. The first running state is a running state of each simulation vehicle at a first unit time of a first traffic scenario file, i.e., an initial state of the currently read traffic scenario file. The second traffic scenario file is a traffic scenario file for generating a first simulation scenario by simulation software. The simulation module 1103 is configured to generate a second simulation scenario from the first traffic scenario file by simulation software with the first running state as a new starting state, and generate a simulation traffic flow based on the first simulation scenario and the second simulation scenario. The first simulation scenario is a simulation scenario generated last time before the second simulation scenario.

[0105] In the above embodiments of the present application, firstly, for different simulation test purposes, a traffic scene library conforming to test requirements can be constructed in a forward direction, the number of traffic scene files and the traffic scene types of each type of traffic scene file in the traffic scene library can be customized, the flexibility is high, compared with collecting real traffic flow data, no labeling is required, the cost is low, easy to obtain, and comprehensive consideration, not limited by the collected data, the test completeness can be guaranteed; secondly, the simulation device reads the traffic scene files (i.e., the second traffic scene file and the first traffic scene file) from the traffic scene library constructed in the forward direction in turn, and controls the simulation vehicle to transition from the initial state of the previous simulation scene to the termination state of the current simulation scene, realizes the continuous distribution of the two simulation scenes, and generates a simulation traffic flow that can cover the test part of the continuous switching of the two scenes, so that the test is more comprehensive.

[0106] In a possible design, the transition module 1102 is specifically configured to control each simulation vehicle to transition from the second running state to the first running state within a specified time length (for example, within 3 seconds) by using a self-provided driver model. The driving style (for example, aggressive type, conservative type, etc.) of the driver model of each simulation vehicle can be set by itself, and details are not described herein.

[0107] In the above embodiments of the present application, since the self-provided driver model is generally an ideal driving model, the switching between the two scenes can be smooth, the running curve of the simulation vehicle is smoother, and is closer to the real driving scene.

[0108] In a possible design, the simulation device 110 can further include a condition triggering module 1104, configured to trigger the reading module 1101, the transition module 1102, and the simulation module 1103 to repeatedly execute the step of generating the second simulation scene until a preset condition is reached.

[0109] In the above embodiments of the present application, the condition triggering module 1104 is configured to trigger the reading module 1101, the transition module 1102, and the simulation module 1103 to repeatedly execute the step of generating the second simulation scene, so that the simulation device can read multiple traffic scene files in turn from the traffic scene library constructed in the forward direction for simulation until a preset condition is reached, and control the simulation vehicle to transition from the initial state of the previous scene to the termination state of the current scene, realize the continuous distribution of multiple different simulation scenes, and generate a simulation traffic flow that can cover the test part of the continuous switching of different scenes. The simulation traffic flow obtained by the embodiments of the present application is composed of a larger number of simulation scenes, and is comprehensive.

[0110] In a possible design, there can be multiple ways to determine whether the preset condition is met, and one way to determine whether the preset condition is met can be: when the number of simulation scenarios generated by the simulation software reaches a preset value, it is determined that the preset condition is met. For example, assume that the preset value n is set to 300, and the current running scenario is scenario i. When the running of scenario i ends, if i = i + 1 < 300, it is determined that the preset condition is not met, and the traffic scenario file is continuously read from the traffic scenario library, and the simulation traffic flow is in a continuous construction process. When i = i + 1 = 300, it is determined that the preset condition is met, and the 300 continuous simulation scenarios read and run constitute the simulation traffic flow.

[0111] In the above embodiments of the application, a condition for terminating the construction of the simulation traffic flow is specifically described. This termination mode does not require that each traffic scenario file in the traffic scenario library be read, but only requires that the read traffic scenario file reach a preset number, and emphasizes the randomness of the construction of the simulation traffic flow.

[0112] In a possible design, another way to determine whether the preset condition is met can also be: when the running time of the simulation software reaches a preset time length, it is determined that the preset condition is met. For example, assume that the preset time length t is set to 20 hours (h). When the running of scenario i ends, the simulation device determines whether the running time of the simulation software reaches 20 h, and when the running of scenario i ends and the running time of the simulation software is less than 20 h, it is determined that the preset condition is not met, and the traffic scenario file is continuously read from the traffic scenario library, and the simulation traffic flow is in a continuous construction process. When the running of scenario i ends and the running time of the simulation software is greater than or equal to 20 h, it is determined that the preset condition is met, and the continuous simulation scenarios read and run constitute the simulation traffic flow.

[0113] In the above embodiments of the application, another condition for terminating the construction of the simulation traffic flow is specifically described. This termination mode limits the total running time of the simulation software, and because the running time period can be set by the user, the probability of accidental interruption of the simulation software during running is reduced.

[0114] ​​​In a possible design, another way of judging whether the preset condition is met can also be that each traffic scenario file in the traffic scenario library is read at least once, indicating that the preset condition is met. Specifically, if there is a traffic scenario file in the traffic scenario library that has never been read, it indicates that the preset condition is not met, and the above process is repeated to continue reading the traffic scenario file from the traffic scenario library; if each traffic scenario file has been read at least once, it indicates that the preset condition is met, at which time the simulation ends after the current scenario i is run, and no traffic scenario file is read from the traffic scenario library. It should be noted that in some embodiments of the present application, for the traffic scenario files that have been read, the simulation device will be marked, and then when reading again, it can be read from the remaining traffic scenario files that have not been read, or it can be randomly read in the entire traffic scenario library (i.e., without distinguishing between traffic scenario files that have been read and traffic scenario files that have not been read), but all traffic scenario files in the entire traffic scenario library are read at least once. The reading method of the traffic scenario file is not limited here.

[0115] In the above embodiments of the present application, another condition for terminating the construction of the simulated traffic flow is specifically described, which limits that each traffic scenario file in the traffic scenario library needs to be read at least once, that is, each type of simulated scenario in the constructed simulated traffic flow appears at least once, thereby improving the completeness of the test.

[0116] In a possible design, in order to ensure the completeness of the classification of the traffic scenario library, the embodiments of the present application divide the traffic scenario types to which the traffic scenario files in the traffic scenario library belong into 9 categories in an orthogonal manner, which are: traffic scenario files for testing free driving in the current lane, traffic scenario files for testing obstacle avoidance detour in the current lane, traffic scenario files for testing left lane changing, traffic scenario files for testing right lane changing, traffic scenario files for testing left lane changing cancellation, traffic scenario files for testing right lane changing cancellation, traffic scenario files for testing following in the current lane, traffic scenario files for testing stopping in the current lane due to obstacles, and traffic scenario files for testing parking on the roadside. Therefore, in the embodiments of the present application, for different test purposes, the plurality of traffic scenario files in the constructed traffic scenario library at least include at least one of the above 9 categories of traffic scenario types.

[0117] In the above embodiments of the present application, the traffic scenario types contained in the constructed traffic scenario library, the number of traffic scenario files in each category, and the proportion of traffic scenario files belonging to different traffic scenario types can be customized, and the flexibility is high.

[0118] The constructed simulation traffic flow can be used for various purposes, for example, to reproduce or pre-understand the traffic running status of an existing system or a future system, so as to explain and analyze complex traffic phenomena, or to optimize the studied traffic system. In some embodiments of the present application, the constructed simulation traffic flow can be specifically used for testing the related functions and performance of the intelligent driving vehicle.

[0119] Therefore, the embodiments of the present application further provide a simulation device 120, which comprises a reading module 1201, a transition module 1202, a simulation module 1203, a condition triggering module 1204 and a testing module 1205. The reading module 1201, the transition module 1202, the simulation module 1203 and the condition triggering module 1204 have similar functions to the reading module 1101, the transition module 1102, the simulation module 1103 and the condition triggering module 1104 described above, and details are not described herein. The testing module 1205 is configured to import the automatic driving algorithm into the simulation software, test the automatic driving algorithm based on different detection types, and obtain the test result of the automatic driving algorithm in each simulation scenario.

[0120] In the above embodiments of the present application, the automatic driving algorithm to be tested is imported into the simulation software to test the performance of the related automatic driving algorithm in each scenario of the running of the constructed simulation traffic flow, which has strong implementability.

[0121] In a possible design, the testing module 1205 is further configured to: when there is a test result that does not meet the preset requirement, mark the traffic scenario file corresponding to the test result, and subsequently increase the frequency of reading the traffic scenario file corresponding to the test result when reading the traffic scenario file from the traffic scenario library, so as to make the frequency of reading the marked first traffic scenario file higher than the frequency of reading the first traffic scenario file before being marked.

[0122] In the above embodiments of the present application, a difficult case library can be formed in a closed loop, and the scenario with poor test result can be subsequently read more frequently, thereby improving the optimization efficiency of the automatic driving algorithm.

[0123] In a possible design, the detection types include, but are not limited to, at least one of collision detection, speed limit detection, on-road detection, intersection lane change detection, end point arrival detection, lane centering detection, emergency braking detection, acceleration detection, unnecessary braking detection, or smoothness detection. The collision detection is used to determine whether the ego vehicle collides with surrounding obstacles; the speed limit detection is used to determine whether the ego vehicle exceeds the road speed limit of the current lane; the on-road detection is used to determine whether the ego vehicle travels on the correct road; the intersection lane change detection is used to determine whether the ego vehicle changes lanes before the intersection to enter the correct lane; the end point arrival detection is used to determine whether the ego vehicle arrives within a certain range of the end point; the lane centering detection is used to determine whether the ego vehicle is lane centered; the emergency braking detection is used to determine whether the ego vehicle brakes too urgently, affecting driving comfort; the acceleration detection is used to determine whether the acceleration / deceleration of the ego vehicle exceeds a preset threshold, or whether the frequency of acceleration / deceleration is too high; the unnecessary braking detection is used to determine whether the ego vehicle has unnecessary braking behavior; and the smoothness detection is used to determine whether the speed fluctuation of the ego vehicle is too large.

[0124] In the foregoing embodiments of the present application, the test content of each detection type is specifically described, and the implementation is strong.

[0125] It should be noted that in the embodiments of the present application, it is not limited to when the automatic driving algorithm is imported into the simulation software. The automatic driving algorithm can be imported before the simulation traffic flow is constructed, or the automatic driving algorithm can be imported during the running of the scene, and the specific implementation is not limited here. Therefore, the test module 1205 can be located at any position between the reading module 1201, the transition module 1202, the simulation module 1203, and the condition triggering module 1204, and the specific implementation is not limited here. Figure 12 It is illustrated that the test module 1205 is located after the condition triggering module 1204.

[0126] It should be further noted that the information interaction and execution process between the modules / units in the simulation device 110 and the simulation device 120 are the same as those described in the foregoing embodiments of the present application. Figure 2 to Figure 9 The corresponding embodiments are based on the same concept, and the specific content can be referred to the description in the foregoing embodiments of the present application, which will not be repeated here.

[0127] Next, another simulation device provided by the embodiments of the present application is introduced, please refer to Figure 13 , Figure 13 A structural schematic diagram of the simulation device provided by the embodiments of the present application is shown in FIG. 13. The simulation device 1300 can be deployed with any one of the modules described in the corresponding embodiments of the simulation device 100, to implement the functions of the simulation device 100. Figure 10 to Figure 13 Figure 10 to Figure 13 ​In any of the corresponding embodiments of the simulation device, specifically, the simulation device 1300 is implemented by one or more servers, and the simulation device 1300 can be quite different due to different configurations or performances, and can include one or more central processing units (CPUs) 1322 (for example, one or more central processing units) and a memory 1332, one or more storage media 1330 (for example, one or more mass storage devices) for storing application programs 1342 or data 1344. The memory 1332 and the storage media 1330 can be temporary storage or persistent storage. The programs stored in the storage medium 1330 can include one or more modules (not shown in the figure), and each module can include a series of instruction operations on the simulation device 1300. Further, the central processing unit 1322 can be configured to communicate with the storage medium 1330 and execute the series of instruction operations in the storage medium 1330 on the simulation device 1300.

[0128] The simulation device 1300 can also include one or more power supplies 1326, one or more wired or wireless network interfaces 1350, one or more input / output interfaces 1358, and / or one or more operating systems 1341, such as Windows ServerTM, Mac OS XTM, UnixTM, LinuxTM, FreeBSDTM, etc.

[0129] In an embodiment of the present application, the central processing unit 1322 is configured to execute Figure 2 to Figure 9The central processing unit 1322 can be used to execute any one of the methods in the corresponding embodiments. For example, the central processing unit 1322 can be used to: first, read a first traffic scenario file from a traffic scenario library, the traffic scenario library being obtained by forward construction, and the traffic scenario library including a plurality of traffic scenario files, the plurality of traffic scenario files being obtained based on subject knowledge, each of the plurality of traffic scenario files including a duration of a respective traffic scenario and a running state of each simulation vehicle at each unit time within the duration in the respective traffic scenario, each traffic scenario file corresponding to a traffic scenario type, and the traffic scenario type being classified according to a preset principle, which can be classified according to a test analysis of an autonomous driving scenario, such as a following driving, a stopping due to an obstacle, a left / right lane changing, and the like, or can be classified according to an actual road scenario faced by the autonomous driving, such as a rural road scenario, a no-lane line scenario, an intersection scenario, a highway scenario, a mountain road scenario, and the like, and the classification principle of the traffic scenario type is not limited; then, control each simulation vehicle to transit from a second running state to a first running state, the second running state being a running state of each simulation vehicle at a last unit time of a second traffic scenario file, that is, a terminal state of a last read traffic scenario file, and the first running state being a running state of each simulation vehicle at a first unit time of the first traffic scenario file, that is, an initial state of a currently read traffic scenario file, and the second traffic scenario file being a traffic scenario file for generating a first simulation scenario by using a simulation software; then, generate a second simulation scenario by using the simulation software from the first traffic scenario file with the first running state as a new initial state, the first simulation scenario being a simulation scenario generated last time before the second simulation scenario, and the last generated simulation scenario constituting the simulation traffic flow in the embodiments of the application.

[0130] It should be noted that the central processing unit 1322 can also be used to execute any one of the methods in the embodiments of the application. Figure 2 to Figure 9 The central processing unit 1322 can be used to execute any one of the methods in the corresponding embodiments. For example, the central processing unit 1322 can be used to: first, read a first traffic scenario file from a traffic scenario library, the traffic scenario library being obtained by forward construction, and the traffic scenario library including a plurality of traffic scenario files, the plurality of traffic scenario files being obtained based on subject knowledge, each of the plurality of traffic scenario files including a duration of a respective traffic scenario and a running state of each simulation vehicle at each unit time within the duration in the respective traffic scenario, each traffic scenario file corresponding to a traffic scenario type, and the traffic scenario type being classified according to a preset principle, which can be classified according to a test analysis of an autonomous driving scenario, such as a following driving, a stopping due to an obstacle, a left / right lane changing, and the like, or can be classified according to an actual road scenario faced by the autonomous driving, such as a rural road scenario, a no-lane line scenario, an intersection scenario, a highway scenario, a mountain road scenario, and the like, and the classification principle of the traffic scenario type is not limited; then, control each simulation vehicle to transit from a second running state to a first running state, the second running state being a running state of each simulation vehicle at a last unit time of a second traffic scenario file, that is, a terminal state of a last read traffic scenario file, and the first running state being a running state of each simulation vehicle at a first unit time of the first traffic scenario file, that is, an initial state of a currently read traffic scenario file, and the second traffic scenario file being a traffic scenario file for generating a first simulation scenario by using a simulation software; then, generate a second simulation scenario by using the simulation software from the first traffic scenario file with the first running state as a new initial state, the first simulation scenario being a simulation scenario generated last time before the second simulation scenario, and the last generated simulation scenario constituting the simulation traffic flow in the embodiments of the application.

[0131] The computer readable storage medium in the embodiments of the application stores a program for signal processing, and when the program is run on a computer, the computer executes the steps performed by the simulation device described in the foregoing embodiment description.

[0132] It should be noted that the apparatus embodiments described above are merely illustrative, and the units described as separate units can or can not be physically separate, and the units displayed as units can or can not be physical units, i.e., can be located in one place, or can be distributed to multiple network units. Part or all of the modules can be selected according to actual needs to achieve the purpose of the embodiment. In addition, the connection relationship between the modules in the apparatus embodiment provided in the present application indicates that there is a communication connection between them, which can be implemented as one or more communication buses or signal lines.

[0133] Through the description of the above embodiments, those skilled in the art can clearly understand that the present application can be realized by means of software and necessary general hardware, and of course can also be realized by special hardware including special integrated circuits, special CPUs, special memories, special components, etc. Generally, functions completed by computer programs can be easily realized by corresponding hardware, and the specific hardware structure for realizing the same function can also be various, such as analog circuit, digital circuit or special circuit, etc. However, for the present application, software program implementation is a better embodiment. Based on such understanding, the technical solutions of the present application can be embodied in the form of software product, which is stored in a readable storage medium, such as computer floppy disk, U disk, mobile hard disk, read only memory (ROM), random access memory (RAM), magnetic disk or optical disk, etc., including a plurality of instructions to make a computer device (which can be a personal computer or a network device, etc.) execute the methods described in various embodiments of the present application.

[0134] In the above embodiments, all or part can be realized by software, hardware, firmware or any combination thereof. When realized by software, it can be realized in the form of computer program product in whole or in part.

[0135] The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the processes or functions described in the embodiments of the present application are generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instructions can be transmitted from one website site, computer, training device or data center to another website site, computer, training device or data center through wired (for example, coaxial cable, optical fiber, digital subscriber line) or wireless (for example, infrared, wireless, microwave, etc.). The computer-readable storage medium can be any available medium that a computer can store or a data storage device such as a training device, a data center, etc. integrated with one or more available media sets. The available media can be a magnetic medium (for example, a floppy disk, a hard disk, a magnetic tape), an optical medium (for example, a high-density digital video disc (digital video disc, DVD)), or a semiconductor medium (for example, a solid state disk (solid state disk, SSD)), etc.

Claims

1. A construction method of simulating traffic flow, characterized by, The method comprises the following steps: reading a first traffic scenario file and a second traffic scenario file from a traffic scenario library, the traffic scenario library comprising a plurality of forwardly constructed traffic scenario files, each of the plurality of traffic scenario files comprising a duration of a respective traffic scenario and a running state of a simulation vehicle in the respective traffic scenario at each unit time within the duration, the plurality of forwardly constructed traffic scenario files being a plurality of scenario files constructed based on subject knowledge; controlling the simulation vehicle to transit from a second running state to a first running state within a specified duration by means of a self-provided driver model, the second running state being a running state of the simulation vehicle at a last unit time of the second traffic scenario file, the first running state being a running state of the simulation vehicle at a first unit time of the first traffic scenario file, the second running state and the first running state being non-continuous motion states, the second traffic scenario file being a traffic scenario file on which a first simulation scenario is generated by simulation software; generating a second simulation scenario by the simulation software based on the first traffic scenario file, with the first running state as a starting state, the first simulation scenario being a simulation scenario generated last time before the second simulation scenario; generating a simulation traffic flow based on the first simulation scenario and the second simulation scenario.

2. The method of claim 1, wherein, Before the step of generating a simulation traffic flow based on the first simulation scenario and the second simulation scenario, the method further comprises the following steps: repeating the step of generating the second simulation scenario until a preset condition is reached.

3. The method of claim 2, wherein, The preset condition comprises the following conditions: a number of simulation scenarios generated by the simulation software reaches a preset value.

4. The method of claim 2, wherein, The preset condition comprises the following conditions: a running duration of the simulation software reaches a preset duration.

5. The method of claim 2, wherein, The preset condition comprises the following conditions: each traffic scenario file in the traffic scenario library is read at least once.

6. The method according to any one of claims 1 to 5, characterized in that, The method further comprises the following steps: importing an automatic driving algorithm into the simulation software, and testing the automatic driving algorithm based on a detection type to obtain a test result of the automatic driving algorithm in the second simulation scenario.

7. The method of claim 6, wherein, The method further comprises the following steps: when the test result does not meet a preset requirement, marking the first traffic scenario file corresponding to the test result, so that a frequency of reading the marked first traffic scenario file is higher than a frequency of reading the first traffic scenario file before being marked.

8. The method according to claim 6 or 7, characterized in that, The detection type comprises at least one of the following types: collision detection, speed limit detection, on-road detection, intersection lane change detection, end point detection, lane centering detection, sudden braking detection, acceleration detection, unnecessary braking detection, and smoothness detection.

9. The method according to any one of claims 1-8, characterized in that, The plurality of traffic scenario files comprises at least one of the following traffic scenario types: A traffic scenario file for testing free driving in the same lane, a traffic scenario file for testing obstacle avoidance in the same lane, a traffic scenario file for testing left lane changing, a traffic scenario file for testing right lane changing, a traffic scenario file for testing left lane changing cancellation, a traffic scenario file for testing right lane changing cancellation, a traffic scenario file for testing following in the same lane, a traffic scenario file for testing stopping in the same lane due to an obstacle, and a traffic scenario file for testing parking by the roadside.

10. An emulation device, comprising: Comprise: a reading module configured to read a first traffic scenario file and a second traffic scenario file from a traffic scenario library, wherein the traffic scenario library comprises a plurality of forward-constructed traffic scenario files, each of the plurality of traffic scenario files comprises a duration of a respective traffic scenario and a running state of a simulation vehicle at each unit time within the duration in the respective traffic scenario, and the plurality of forward-constructed traffic scenario files are a plurality of scenario files constructed based on subject knowledge; a transition module configured to control the simulation vehicle to transit from a second running state to a first running state within a specified duration by using a self-provided driver model, wherein the second running state is a running state of the simulation vehicle at a last unit time of the second traffic scenario file, the first running state is a running state of the simulation vehicle at a first unit time of the first traffic scenario file, the second running state and the first running state are non-continuous motion states, and the second traffic scenario file is a traffic scenario file used to generate a first simulation scenario by using a simulation software; a simulation module configured to generate a second simulation scenario based on the first traffic scenario file by using the simulation software with the first running state as a starting state, and generate a simulation traffic flow based on the first simulation scenario and the second simulation scenario, wherein the first simulation scenario is a simulation scenario generated at a previous time of the second simulation scenario.

11. The apparatus of claim 10, wherein, The device further comprises: a condition triggering module configured to trigger the reading module, the transition module, and the simulation module to repeatedly perform the step of generating the second simulation scenario until a preset condition is reached.

12. The apparatus of claim 11, wherein, The preset condition reached comprises: a number of simulation scenarios generated by using the simulation software reaches a preset value.

13. The apparatus of claim 11, wherein, The preset condition reached comprises: a running duration of the simulation software reaches a preset duration.

14. The apparatus of claim 11, wherein, The preset condition reached comprises: each traffic scenario file in the traffic scenario library is read at least once.

15. The apparatus of any one of claims 10-14, wherein, The device further comprises: a testing module configured to import an automatic driving algorithm into the simulation software, and test the automatic driving algorithm based on a detection type to obtain a test result of the automatic driving algorithm in the second simulation scenario.

16. The apparatus of claim 15, wherein, The testing module is further configured to: when the test result does not meet a preset requirement, mark the first traffic scenario file corresponding to the test result, so that a frequency of reading the marked first traffic scenario file is higher than a frequency of reading the first traffic scenario file before being marked.

17. The apparatus of claim 15 or 16, wherein, The detection type comprises at least one of the following: Collision detection, speed limit detection, on-road detection, intersection lane change detection, end point arrival detection, lane centering detection, sudden braking detection, acceleration detection, unnecessary braking detection, smoothness detection.

18. The apparatus of any one of claims 10-17, wherein, The plurality of traffic scenario files at least include at least one of the following traffic scenario types: A traffic scenario file for testing free driving in the current lane, a traffic scenario file for testing obstacle avoidance detour in the current lane, a traffic scenario file for testing left lane change, a traffic scenario file for testing right lane change, a traffic scenario file for testing left lane change cancellation, a traffic scenario file for testing right lane change cancellation, a traffic scenario file for testing following in the current lane, a traffic scenario file for testing stopping in the current lane due to obstacles, a traffic scenario file for testing parking on the side of the road.

19. A simulation device comprising a processor and a memory, the processor coupled to the memory, characterized in that, the memory is configured to store a program; the processor is configured to execute the program in the memory, causing the simulation device to perform the method of any one of claims 1-9.

20. A computer readable storage medium comprising a program, characterized in that, when it is run on a computer, causing the computer to perform the method of any one of claims 1-9.

21. A computer program product comprising instructions, wherein: when it is run on a computer, causing the computer to perform the method of any one of claims 1-9. when it is run on a computer, causing the computer to perform the method of any one of claims 1-9.

Citation Information

Patent Citations

  • Traffic scene simulation experiment platform and method based on virtual reality

    CN110427682A

  • Traffic information flow construction method and device

    CN111159832A

Cited By

  • Method for constructing simulation traffic flow and simulation device

    WO2022041717A1