Simulation data packet recording method and device, electronic equipment and storage medium

By cache data in the intelligent driving simulation process and filtering target frames using the comfort evaluation model to generate package recording files, the problem of long-term storage resource occupation and positioning problems caused by large data volume is solved, and efficient package recording file management is achieved.

CN120493397APending Publication Date: 2025-08-15GUANGZHOU AUTOMOBILE GROUP CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510530537.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-24
Publication Date
2025-08-15

AI Technical Summary

Technical Problem

In the prior art, the amount of simulation data packets (bag packets) during intelligent driving simulation testing is too large, which leads to the long time required for algorithm engineers to locate problems and the storage resources are occupied by a large amount.

Method used

The simulation data is cached in the intelligent driving simulation process, and the motion parameters of each data frame are obtained, and the comfort threshold is determined using the pre-trained comfort evaluation model. Only target frames with comfort scores higher than the threshold are recorded to generate a packet record file.

Benefits of technology

It reduces the amount of data in the packaged files, improves the efficiency of algorithm engineers to locate problems, and reduces the use of storage resources.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120493397A_ABST
    Figure CN120493397A_ABST
Patent Text Reader

Abstract

The invention discloses a simulation data packet recording method and device, electronic equipment and a storage medium. The method comprises the steps of caching simulation data in an intelligent driving simulation process; for each data frame in the cached simulation data, acquiring motion parameters of the main vehicle from the data frame; acquiring a comfort score of the data frame according to the motion parameter; acquiring a comfort threshold value of the data frame according to the speed, the driving curvature and a pre-trained comfort evaluation model in the motion parameters; determining a target frame in a plurality of data frames included in the simulation data; the simulation data in the cached simulation data in the target time period is converted, a packet recording file is obtained, and the target time period comprises the timestamp of the target frame. According to the technical scheme provided by the embodiment of the invention, on one hand, the time required by an algorithm engineer for positioning problems can be shortened, the positioning efficiency is improved, and on the other hand, the storage resources occupied by the packet recording file are reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of simulation technology, and in particular to a simulation data recording method, device, electronic device and storage medium. Background Art

[0002] At present, cloud simulation platforms are usually used to conduct large-scale and comprehensive testing and verification of intelligent driving algorithms, so that problems with intelligent driving algorithms can be located during the development stage, reducing the time and cost of subsequent actual vehicle testing.

[0003] In related technologies, when electronic devices conduct intelligent driving simulation tests, they record all simulation data into a bag package in a specific format. Algorithm engineers screen the algorithm problems related to themselves in the bag package and solve the above problems.

[0004] In related technologies, due to the large amount of data in the bag package, on the one hand, it takes a long time for algorithm engineers to locate the problem, resulting in low positioning efficiency; on the other hand, the bag package occupies more storage resources. Summary of the Invention

[0005] The present application proposes a simulation data recording method, device, electronic device and storage medium.

[0006] In a first aspect, an embodiment of the present application provides a simulation data recording method, comprising: caching simulation data in an intelligent driving simulation process; obtaining motion parameters of a main vehicle from each data frame in the cached simulation data, the motion parameters including speed, lateral acceleration, longitudinal acceleration, yaw angular velocity, and driving curvature; obtaining a comfort score of the data frame according to the motion parameters; obtaining a comfort threshold of the data frame according to the speed and driving curvature in the motion parameters and a pre-trained comfort evaluation model; determining a target frame among multiple data frames included in the simulation data, the target frame being a data frame whose comfort score is greater than the comfort threshold; converting the simulation data within a target time period in the cached simulation data to obtain a recording file, wherein the target time period includes a timestamp of the target frame.

[0007] In a second aspect, an embodiment of the present application provides a simulation data recording device, comprising: a cache module for caching simulation data in an intelligent driving simulation process; a parameter acquisition module for acquiring, for each data frame in the cached simulation data, the first motion parameter of the main vehicle from the data frame, the motion parameters including speed, lateral acceleration, longitudinal acceleration, yaw angular velocity and driving curvature; a score determination module for acquiring the comfort score of the data frame according to the motion parameters; a threshold determination module for acquiring the comfort threshold of the data frame according to the speed and driving curvature in the motion parameters and a pre-trained comfort evaluation model; a target frame determination module for determining a target frame among multiple data frames included in the simulation data, the target frame being a data frame whose comfort score is greater than the comfort threshold; a recording module for converting the simulation data within a target time period in the cached simulation data to obtain a recording file, the target time period including the timestamp of the target frame.

[0008] In a third aspect, an embodiment of the present application provides an electronic device comprising: a memory; one or more processors coupled to the memory; and one or more programs, wherein the one or more applications are stored in the memory and configured to be executed by the one or more processors, and the one or more programs are configured to execute the method of the first aspect.

[0009] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, in which computer program instructions are stored. The computer program instructions can be called by a processor to execute the method described in the first aspect.

[0010] In a fifth aspect, an embodiment of the present application provides a computer program product, which, when instructions in the computer program product are executed, is used to implement the method described in the first aspect.

[0011] Compared with the existing technology, the technical solution provided by the embodiment of the present application first caches the simulation data when executing the intelligent driving simulation process, and then performs a comfort evaluation on each data frame in the cached simulation data, and determines the comfort threshold of each data frame based on a pre-trained comfort evaluation model, and screens out target frames with a comfort score greater than the comfort threshold. Only the simulation data within a time period including the target frame is recorded, and there is no need to record all the simulation data. The data volume of the recorded file is greatly reduced. On the one hand, it can reduce the time required for algorithm engineers to locate the problem and improve the positioning efficiency. On the other hand, it reduces the storage resources occupied by the recorded file. BRIEF DESCRIPTION OF THE DRAWINGS

[0012] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present application. For those skilled in the art, other drawings can be obtained based on these drawings without creative work.

[0013] Figure 1 It is a schematic diagram of an implementation environment provided by an embodiment of the present application.

[0014] Figure 2 This is a flowchart of a simulation data recording method provided by an embodiment of the present application.

[0015] Figure 3 This is a flowchart of a simulation data recording method provided by another embodiment of the present application.

[0016] Figure 4 This is a flowchart of a simulation data recording method provided by another embodiment of the present application.

[0017] Figure 5 This is a block diagram of a simulation data recording device provided by an embodiment of the present application.

[0018] Figure 6 This is a structural block diagram of an electronic device provided by an embodiment of the present application. DETAILED DESCRIPTION

[0019] The embodiments of the present application are described in detail below. Examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present application and are not to be construed as limiting the present application.

[0020] In order to enable those skilled in the art to better understand the solutions of the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without making creative efforts are within the scope of protection of this application.

[0021] Please refer to Figure 1 , which shows a schematic diagram of an implementation environment provided by an embodiment of the present application. The implementation environment includes an electronic device 100, which runs a cloud simulation platform 10, and further includes an intelligent packet recording module 20.

[0022] The cloud simulation platform 10 is used to execute the intelligent driving simulation process. Optionally, the cloud simulation platform 10 includes a parameter setting module 110, a simulation engine module 120 and a tested algorithm module 130.

[0023] The parameter setting module 10 is used to set simulation parameters and packet recording time parameters. Simulation parameters include simulation modes, such as worldsim, logsim, and virtual city. Packet recording parameters include forward and backward time parameters. The forward time parameter indicates the time interval between the start of packet recording and the timestamp of the target frame. The backward time parameter indicates the time interval between the end of packet recording and the timestamp of the target frame. The parameter setting module 110 also provides the above-mentioned packet recording time parameters to the intelligent packet recording module 130.

[0024] The simulation engine module 120 is used to provide traffic environment information and positioning information to the algorithm module under test 130, and to receive control signals provided by the algorithm module under test 130, such as the driving trajectory of the main vehicle and the motion parameters of each trajectory point of the main vehicle on the driving trajectory, including speed, acceleration, yaw angular velocity, driving curvature, etc.

[0025] The tested algorithm module 130 is the test subject of this simulation process and is used to generate control signals based on the traffic environment information and positioning information provided by the simulation engine module 120. The tested algorithm module 130 can load different tested algorithms according to different simulation objectives, such as decision-making and planning algorithms, prediction algorithms, navigation algorithms, control algorithms, and perception fusion algorithms.

[0026] The intelligent package recording module 20 includes a pre-trained comfort evaluation model 210 , a data conversion submodule 220 , and a package uploading submodule 230 .

[0027] The comfort evaluation model 210 is used to determine a corresponding comfort threshold based on the motion parameters of the data frame. The comfort evaluation model 210 can be trained by an electronic device or a server, which is not limited in this embodiment of the application. The data conversion submodule 220 is used to convert the buffered data into a bag in a specified format. The bag upload submodule 230 is used to upload the bag to a specified device.

[0028] In related technologies, when simulating intelligent driving, all simulation data needs to be recorded. The amount of data in the recorded files is very large. On the one hand, it takes up a lot of storage resources. On the other hand, when problems occur in the simulation process, algorithm engineers need to locate the problems in the complete recorded files, which takes a long time and has low positioning efficiency.

[0029] Based on the problems existing in the related technology, an embodiment of the present application provides a simulation data recording method. When executing the intelligent driving simulation process, the simulation data is first cached, and then the comfort evaluation is performed on each data frame in the cached simulation data. The comfort threshold of each data frame is determined based on a pre-trained comfort evaluation model, and the target frames with a comfort score greater than the comfort threshold are screened out. Only the simulation data within a time period including the target frame is recorded, and there is no need to record all the simulation data. The data volume of the recorded file is greatly reduced. On the one hand, it can reduce the time required for algorithm engineers to locate the problem and improve the positioning efficiency. On the other hand, it reduces the storage resources occupied by the recorded file.

[0030] Please refer to Figure 2 , which shows a flow chart of a simulation data recording method provided by an embodiment of the present application. The method includes the following process.

[0031] S201, in the intelligent driving simulation process, cache simulation data.

[0032] The simulation data includes multiple data frames, each of which includes traffic environment information, positioning information, and control information output by the algorithm under test based on the traffic environment information and positioning information.

[0033] Traffic environment information includes road information for the vehicle's current route (e.g., number of lane lines, current lane, lane boundaries, road boundaries), traffic sign information for the current route (e.g., speed limits, traffic light status), and obstacle information for the current route (e.g., motion parameters of other vehicles, distance between other vehicles and the vehicle). Positioning information includes the vehicle's position on the current route.

[0034] The control information includes the motion parameters of the host vehicle, including but not limited to: speed, acceleration, yaw rate, and driving curvature. Acceleration includes lateral acceleration and longitudinal acceleration.

[0035] Before the intelligent driving simulation process begins, the electronic device can also set packet recording time parameters. Optionally, the electronic device displays a settings interface, which includes a first settings area and / or a second settings area. The first settings area is used for the technician to set the forward time parameters, and the second settings area is used for the technician to set the backward time parameters. The first settings area can be an input box, and the second settings area can be an input box.

[0036] Before the intelligent driving simulation process begins, the electronic device can also set the simulation mode. Optionally, the above-mentioned setting interface also includes a third setting area for the technician to set the simulation mode. Specifically, after receiving the simulation mode setting signal, the electronic device displays a simulation mode list, receives a selection signal for a target simulation mode in the simulation mode list, and uses the selected target simulation mode as the simulation mode used in the current simulation process.

[0037] S202 : For each data frame in the buffered data, obtain motion parameters of the data frame.

[0038] The aforementioned motion parameters include the vehicle's speed, lateral acceleration, longitudinal acceleration, yaw rate, and curvature. Acceleration includes both lateral and longitudinal acceleration. The electronic device can directly read the motion parameters for each data frame from the cached data.

[0039] S203: Calculate a comfort score of the data frame based on the motion parameters.

[0040] The comfort score quantifies the level of comfort perceived by passengers during driving. A higher comfort score indicates a lower level of comfort; a lower comfort score indicates a higher level of comfort. Generally speaking, a lower rate of acceleration during driving indicates greater passenger comfort. Furthermore, a lower rate of curvature during driving indicates greater passenger comfort.

[0041] In some embodiments, the electronic device obtains a specified functional relationship, and determines a comfort score of the data frame based on the specified functional relationship and motion parameters.

[0042] The specified functional relationship is used to indicate the relationship between the first motion parameter and the comfort score. The specified functional relationship can be modeled by a technician and stored locally on the electronic device. The electronic device directly reads the specified functional relationship and then substitutes the motion parameters into the specified functional relationship to obtain the comfort score of the data frame.

[0043] Optionally, the specified functional relationship is expressed by the following calculation formula:

[0044]

[0045] Where v is the speed, k is the driving curvature, w is the yaw rate, a y is the longitudinal acceleration, a x is the lateral acceleration.

[0046] According to the above specified functional relationship, it can be seen that the greater the speed and the greater the driving curvature, the greater the proportion of lateral comfort will be, making the evaluation more scientific and reasonable.

[0047] S204 : Determine a comfort threshold of the data frame based on the speed, the driving curvature, and the pre-trained comfort evaluation model in the motion parameters.

[0048] The electronic device inputs the speed and driving curvature of the motion parameters into a pre-trained comfort evaluation model, which then outputs a comfort threshold. The training process of the comfort evaluation model will be described in the following embodiments.

[0049] In some embodiments, the comfort evaluation model can be expressed using the following formula:

[0050] f=a0+a1x+a2y+a3x 3 +a4y 3 +a5xy.

[0051] Where a0, a1, a2, a3, a4, and a5 are coefficients determined based on training. The electronic device substitutes speed as x and curvature as y into the above equation, and the resulting f is the comfort threshold.

[0052] The embodiment of the present application does not limit the execution order of S203 and S204. The electronic device may execute S203 first and then execute S204; it may execute S204 first and then execute S203; it may also execute S203 and S204 simultaneously.

[0053] S205 , determining a target frame among a plurality of data frames included in the simulation data.

[0054] The target frame refers to a data frame whose comfort score is greater than the comfort threshold. The number of target frames can be one or more.

[0055] S206: Convert the simulation data within the target time period in the cached simulation data to obtain a recording file.

[0056] The target time period includes the timestamp of the target frame. The data size of the packet recording file generated by packet processing the simulation data within the target time period is much smaller than the data size of the packet recording file generated by packet processing the complete simulation data. This greatly reduces the data size of the packet recording file, which not only shortens the time required for algorithm engineers to locate problems and improves location efficiency, but also reduces the storage resources occupied by the packet recording file.

[0057] In some embodiments, S206 is implemented as follows: determining a target time period based on pre-configured packet recording time parameters, obtaining simulation data within the target time period from cached simulation data, and performing data conversion on the simulation data within the target time period to obtain a packet recording file.

[0058] Optionally, the packet recording time parameter includes a forward time parameter, or / and a backward time parameter. The forward time parameter indicates the time interval between the start time of packet recording and the timestamp of the target frame. The forward time parameter can be customized by the user before the simulation process starts, or it can be set by default by the simulation application. Exemplarily, if the forward time parameter is 10 seconds and the timestamp of the target frame is 32 minutes and 40 seconds, then the start time of packet recording is 32 minutes and 30 seconds. The backward time parameter indicates the time interval between the end time of packet recording and the timestamp of the target frame. The backward time parameter can be customized by the user before the simulation process starts, or it can be set by default by the simulation application. Exemplarily, if the backward time parameter is 10 seconds and the timestamp of the target frame is 32 minutes and 40 seconds, then the start time of packet recording is 32 minutes and 48 seconds.

[0059] In some embodiments, if the time interval between the start time of the cached simulation data and the timestamp of the target frame is less than the forward time parameter, the start time is determined as the packet recording start time. For example, if the timestamp of the target frame is 00:08, the forward time parameter is 10 seconds, and the start time of the cached simulation data is 00:00, then 00:00 is used as the packet recording start time.

[0060] In other embodiments, if the time interval between the saved time of the cached simulation data and the timestamp of the target frame is less than the backward time parameter, the end time is determined as the packet recording end time. For example, if the timestamp of the target frame is 45 minutes and 10 seconds, the backward time parameter is 8 seconds, and the start time of the cached simulation data is 45 minutes and 15 seconds, then 45 minutes and 15 seconds is determined as the packet recording start time.

[0061] In other embodiments, the packet recording time parameters include a duration parameter, and the electronic device determines the moment before the timestamp of the target frame and the time interval between the timestamp of the target frame and the timestamp of the target frame is a specified time interval as the start time of packet recording, and determines the moment after the timestamp of the target frame and the time interval between the timestamp of the target frame and the timestamp of the target frame is a specified time interval as the end time of packet recording, and the specified time interval is half of the duration parameter.

[0062] The simulated cache data is typically formatted as an in-memory data structure, binary, or serialized object. The packet file can be formatted as a bag. The electronic device uses a data conversion module to convert the cache data within the target time period into a corresponding format, generating a packet file.

[0063] To sum up, the technical solution provided by the embodiment of the present application, when executing the intelligent driving simulation process, first caches the simulation data, then performs a comfort evaluation on each data frame in the cached simulation data, and determines the comfort threshold of each data frame based on a pre-trained comfort evaluation model, and screens out target frames with a comfort score greater than the comfort threshold, and only records the simulation data within a time period including the target frame, without having to record all the simulation data. The data volume of the recorded file is greatly reduced. On the one hand, it can reduce the time required for algorithm engineers to locate the problem and improve the positioning efficiency. On the other hand, it reduces the storage resources occupied by the recorded file.

[0064] Please refer to Figure 3 , which shows a flow chart of a simulation data recording method provided by an embodiment of the present application. The method includes the following process.

[0065] S301, cache simulation data during the intelligent driving simulation process.

[0066] S302 : For each data frame in the buffered data, obtain motion parameters of the host vehicle from the data frame.

[0067] The above motion parameters include the speed, lateral acceleration, longitudinal acceleration, yaw rate, and driving curvature of the main vehicle.

[0068] S303: Obtain the distance between the host vehicle and the target vehicle.

[0069] The target vehicle is the vehicle closest to the host vehicle. The electronic device can directly read the distance between the host vehicle and the target vehicle from the data frame.

[0070] S304: Obtain the relative speed between the host vehicle and the target vehicle in a specified direction.

[0071] The designated direction refers to the direction of the line connecting the host vehicle and the target vehicle. Optionally, the electronic device obtains a first projection value of the host vehicle's speed in the designated direction and a second projection value of the target vehicle's speed in the designated direction. The difference between the first projection value and the second projection value is the relative speed of the host vehicle and the target vehicle in the designated direction.

[0072] S305 : Obtain collision time based on the distance and the relative speed in the specified direction.

[0073] The electronic device determines the ratio of the distance and the relative speed in the above-specified direction as the collision time.

[0074] S306: If the collision time is greater than a specified threshold, obtain a comfort score of the data frame according to the motion parameters.

[0075] If the collision time is less than the specified threshold, it indicates that the probability of the host vehicle colliding with another vehicle is high. In this case, the control signal output by the tested algorithm module should not be evaluated based on comfort, but rather on safety. Therefore, the subsequent steps are not executed. If the collision time is greater than the specified threshold, it indicates that the probability of the host vehicle colliding with another vehicle is low. In this case, the control signal output by the tested algorithm module should still be evaluated based on comfort. Therefore, the comfort score of the data frame is obtained based on the first motion parameter.

[0076] S307 , obtaining a comfort threshold of the data frame according to the speed, the driving curvature, and the pre-trained comfort evaluation model in the motion parameters.

[0077] S308: Determine a target frame among the multiple data frames included in the simulation data.

[0078] The target frame refers to a data frame whose comfort score is greater than the comfort threshold.

[0079] S309: convert the simulation data within the target time period in the cached simulation data to obtain a recording file.

[0080] The target period includes the timestamp of the target frame.

[0081] To sum up, the technical solution provided by the embodiment of the present application also calculates the expected collision time between the main vehicle and the target vehicle before performing a comfort evaluation on the data frame. If the expected collision time is short, the subsequent steps are not executed. Since when the expected collision time is short, the control signal output by the algorithm module under test should not be evaluated based on comfort but on safety. Therefore, the data frame does not need to be evaluated for comfort, thereby avoiding the situation where the packet is still recorded when the algorithm under test is working normally.

[0082] The following describes the training process of the comfort evaluation model. The training process of the comfort evaluation model includes the following steps.

[0083] S401, obtaining multiple sets of training data.

[0084] Each set of training data in the multiple sets of training data includes the speed, driving curvature and calibrated comfort score of the vehicle.

[0085] In some embodiments, the electronic device obtains multiple sets of training data in the following manner: obtain multiple sets of initial training data, determine the speed interval and the driving curvature interval based on the multiple sets of initial training data; divide the speed interval into n speed sub-intervals, and divide the driving curvature interval into m driving curvature sub-intervals, the n speed sub-intervals and the m driving curvature sub-intervals constitute p cells, n is an integer greater than 1, m is an integer greater than 1, and p is the product of m and n; for the i-th cell among the p cells, obtain the calibrated comfort score corresponding to the i-th cell, and use the median speed of the i-th cell, the median driving curvature and the calibrated comfort score corresponding to the i-th cell as a set of training data, where i is an integer less than or equal to p.

[0086] Multiple sets of initial training data include vehicle motion parameters and comfort scores determined based on these parameters. The initial training data is natural driving data. Vehicles collect their own motion parameters through onboard sensors while driving and report these parameters to a server. The server then determines the comfort score corresponding to each vehicle's reported motion parameters based on a specified functional relationship, generating multiple sets of initial training data.

[0087] For multiple sets of initial training data, the server discretizes all comfort scores into two sub-intervals: speed and travel curvature, to obtain speed intervals and travel curvature intervals. The lower limit of the speed interval is the minimum speed value in the multiple sets of initial training data, and the upper limit of the speed interval is the maximum speed value in the multiple sets of initial training data. The lower limit of the travel curvature interval is the minimum travel curvature value in the multiple sets of initial training data, and the upper limit of the travel curvature interval is the maximum travel curvature value in the multiple sets of initial training data. The electronic device divides the speed interval into n speed sub-intervals according to a preset first step length. The electronic device divides the travel curvature interval into n travel curvature sub-intervals according to a preset second step length.

[0088] For example, if the first step length is 2 m / s and the vehicle speed range is 0-36 m / s, the speed range is divided into 18 speed sub-ranges. Another example is if the second step length is 0.005 and the driving curvature range is 0-0.2, the driving curvature range is divided into 40 driving curvature sub-ranges. These 18 speed sub-ranges and 40 driving curvature sub-ranges form 720 cells, each of which corresponds to a large number of comfort scores.

[0089] The process of determining the calibrated comfort score corresponding to the i-th cell includes: performing statistical analysis on the comfort scores included in the i-th cell to obtain the local threshold corresponding to the i-th cell; removing the comfort scores in the i-th cell that are greater than the local threshold; and determining the mean of the remaining comfort scores in the i-th cell as the calibrated comfort score corresponding to the i-th cell.

[0090] In some embodiments, the local threshold is calculated using the following formula: y=μ+2*σ, where μ is the mean of all comfort scores corresponding to the i-th cell, and σ is the standard deviation of all comfort scores corresponding to the i-th cell.

[0091] For example, the speed sub-interval of the first cell is 0-2 m / s, the driving curvature sub-interval is 0-0.005, the number of all comfort scores corresponding to the first cell is 80, the mean is 25, and the standard deviation is 0.5. Therefore, the local threshold is 26. There are 3 comfort scores of 27, 27.2, and 26.5, which exceed the above local threshold. Therefore, the calibrated comfort score corresponding to the first cell is (80*25-27-27.2-26.5) / 77=24.92. At this time, a set of training data corresponding to the first cell is 1 m / s, 0.0025, and 24.92.

[0092] The server calculates the training data corresponding to all cells and obtains multiple sets of training data.

[0093] In some embodiments, after obtaining multiple sets of initial training data, the server first uses a statistical method to remove abnormal scores. Specifically, the server removes the initial training data whose deviation between the comfort score and the normal distribution curve is greater than a preset value as abnormal data.

[0094] S402 : For each set of training data in the plurality of sets of training data, input each set of training data into an initial comfort evaluation model to obtain a comfort score output by the initial comfort evaluation model.

[0095] Optionally, the initial comfort evaluation model is expressed using the following calculation formula:

[0096] f=a0+a1x+a2y+a3x 3 +a4y 3 +a5xy.

[0097] Among them, a0, a1, a2, a3, a4, and a5 are initial coefficients, and the training process is the process of solving a0, a1, a2, a3, a4, and a5.

[0098] S403: Calculate a loss function based on the calibrated comfort score and the output comfort score.

[0099] The loss function is used to indicate the relative error between the calibrated comfort score and the output comfort score.

[0100] Optionally, the loss function is expressed as follows:

[0101]

[0102] S404: Optimize the parameters of the initial comfort evaluation model according to the optimization algorithm to minimize the loss function.

[0103] The optimization algorithm may be a back propagation algorithm, a normalization algorithm, etc., which is not limited in the embodiments of the present application.

[0104] S405, repeat the steps of loss function calculation and model parameter optimization until the stopping condition is met.

[0105] The condition for stopping iteration can be that the loss function is less than a preset value, or the number of iterations is greater than a preset number. The preset value and the preset number can both be set according to the accuracy of the model j.

[0106] Please refer to Figure 5 , which shows a block diagram of a simulation data packet recording device provided by one embodiment of the present application. The device includes: a buffer module 510, a parameter acquisition module 520, a score determination module 530, a threshold determination module 540, a target frame determination module 550, and a packet recording module 560.

[0107] The cache module 510 is used to cache simulation data in the intelligent driving simulation process.

[0108] The parameter acquisition module 520 is used to acquire the motion parameters of the host vehicle from each data frame in the cached simulation data. The motion parameters include speed, lateral acceleration, longitudinal acceleration, yaw angular velocity and driving curvature.

[0109] The score determination module 530 is configured to obtain a comfort score of the data frame according to the motion parameters.

[0110] The threshold determination module 540 is used to obtain the comfort threshold of the data frame according to the comfort evaluation model pre-trained based on the speed and driving curvature in the motion parameters.

[0111] The target frame determination module 550 is configured to determine a target frame from among the multiple data frames included in the simulation data. The target frame refers to a data frame whose comfort score is greater than a comfort threshold.

[0112] The packet recording module 560 is used to convert the simulation data in the target time period in the cached simulation data to obtain a packet recording file, wherein the target time period includes the timestamp of the target frame.

[0113] In some embodiments, the score determination module 530 is configured to obtain a specified functional relationship, which includes a relationship between the comfort score and the motion parameters; and determine the comfort score of the data frame based on the specified functional relationship and the motion parameters.

[0114] In other embodiments, the training process of the comfort evaluation model includes: obtaining multiple sets of training data, each set of training data in the multiple sets of training data includes a second motion parameter of the vehicle and a calibrated comfort score, and the second motion parameter includes speed and driving curvature; for each set of training data in the multiple sets of training data, inputting each set of training data into the initial comfort evaluation model to obtain the comfort score output by the initial comfort evaluation model; calculating the loss function based on the calibrated comfort score and the output comfort score; optimizing the parameters of the initial comfort evaluation model according to the optimization algorithm to minimize the loss function; repeating the steps of loss function calculation and model parameter optimization until the iteration stop condition is met.

[0115] In some embodiments, multiple sets of training data are obtained, including: obtaining multiple sets of initial training data, the multiple sets of initial training data including motion parameters of the vehicle and a comfort score determined based on the motion parameters; determining a speed interval and a driving curvature interval based on the multiple sets of initial training data; dividing the speed interval into n speed sub-intervals, and dividing the driving curvature interval into m driving curvature sub-intervals, the n speed sub-intervals and the m driving curvature sub-intervals forming p cells, n being an integer greater than 1, m being an integer greater than 1, and p being the product of m and n; for the i-th cell among the p cells, obtaining a calibrated comfort score corresponding to the i-th cell; taking the median speed value, the median driving curvature value, and the calibrated comfort score corresponding to the i-th cell as a set of training data, where i is an integer less than or equal to p.

[0116] In some embodiments, obtaining the calibrated comfort score corresponding to the i-th cell includes: performing statistical analysis on the comfort scores included in the i-th cell to obtain a local threshold corresponding to the i-th cell; removing the comfort scores in the i-th cell that are greater than the local threshold; and determining the mean of the remaining comfort scores in the i-th cell as the calibrated comfort score corresponding to the i-th cell.

[0117] In some embodiments, the packet recording module 560 is used to determine the target time period based on pre-configured packet recording time parameters, wherein the packet recording time parameters include forward time parameters, and / or backward time parameters; the forward time parameters indicate the time interval between the start time of packet recording and the timestamp of the target frame, and the backward time parameters indicate the time interval between the end time of packet recording and the timestamp of the target frame; obtain the simulation data within the target time period from the cached simulation data, and perform data conversion on the simulation data within the target time period to obtain a packet recording file.

[0118] In some embodiments, the device further includes a collision time prediction module (not shown). The collision time prediction module is configured to obtain the distance between the host vehicle and the target vehicle; obtain the relative speed of the host vehicle and the target vehicle in a specified direction, where the specified direction is the direction of the line connecting the host vehicle and the target vehicle; and obtain the collision time based on the distance and the relative speed in the specified direction. A score determination module 530 is configured to, if the collision time is greater than a preset threshold, execute the step of obtaining a comfort score for the data frame based on the first motion parameter.

[0119] To sum up, the technical solution provided by the embodiment of the present application, when executing the intelligent driving simulation process, first caches the simulation data, then performs a comfort evaluation on each data frame in the cached simulation data, and determines the comfort threshold of each data frame based on a pre-trained comfort evaluation model, and screens out target frames with a comfort score greater than the comfort threshold, and only records the simulation data within a time period including the target frame, without having to record all the simulation data. The data volume of the recorded file is greatly reduced. On the one hand, it can reduce the time required for algorithm engineers to locate the problem and improve the positioning efficiency. On the other hand, it reduces the storage resources occupied by the recorded file.

[0120] Those skilled in the art will clearly understand that, for the convenience and brevity of description, the specific working processes of the above-described devices and modules can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0121] In several embodiments provided in this application, the coupling between modules may be electrical, mechanical or other forms of coupling.

[0122] In addition, the functional modules in the various embodiments of the present application may be integrated into a processing module, or each module may exist physically separately, or two or more modules may be integrated into a single module. The above-mentioned integrated modules may be implemented in the form of hardware or software functional modules.

[0123] See also Figure 6 , which shows that an embodiment of the present application further provides an electronic device 600, which includes: one or more processors 610, a memory 620, and one or more applications. The one or more applications are stored in the memory 620 and configured to be executed by the one or more processors 610, and the one or more applications are configured to perform the methods described in the above embodiments.

[0124] The processor 610 may include one or more processing cores. The processor 610 utilizes various interfaces and circuits to connect various components within the battery management system. It executes instructions, programs, code sets, or instruction sets stored in the memory 620, as well as accesses data stored in the memory 620, to perform various functions of the battery management system and process data. Optionally, the processor 610 may be implemented using at least one of the following hardware forms: a digital signal processing (DSP), a field-programmable gate array (FPGA), or a programmable logic array (PLA). The processor 610 may integrate one or a combination of a central processing unit (CPU), a graphics processing unit (GPU), and a modem. The CPU primarily handles the operating system, user interface, and application programs; the GPU is responsible for rendering and drawing display content; and the modem handles wireless communications. It is understood that the modem may not be integrated into the processor 610 and may be implemented separately via a communication chip.

[0125] The memory 620 may include a random access memory 620 (Random Access Memory, RAM), and may also include a read-only memory 620 (Read-Only Memory). The memory 620 may be used to store instructions, programs, codes, code sets, or instruction sets. The memory 620 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for implementing at least one function (such as a touch function, a sound playback function, an image playback function, etc.), instructions for implementing the various method embodiments described below, etc. The data storage area may also store data created by the electronic device during use (such as a phone book, audio and video data, chat history data), etc.

[0126] An embodiment of the present application further provides a computer-readable storage medium, which stores computer program instructions. The computer program instructions can be called by a processor to execute the method described in the above embodiment.

[0127] The computer-readable storage medium may be an electronic memory such as a flash memory, an EEPROM (Electrically Erasable Programmable Read-Only Memory), an EPROM, a hard disk, or a ROM. Alternatively, the computer-readable storage medium includes a non-transitory computer-readable storage medium. The computer-readable storage medium has storage space for computer program instructions for executing any of the method steps described above. These computer program instructions may be read from or written to one or more computer program products. The computer program instructions may be compressed in a suitable form.

[0128] The above is only a preferred embodiment of the present application and does not constitute any form of limitation to the present application. Although the present application has been disclosed as above with preferred embodiments, it is not intended to limit the present application. Any person skilled in the art can make some changes or modifications to equivalent embodiments using the technical contents disclosed above without departing from the scope of the technical solution of the present application. However, any brief modifications, equivalent changes and modifications made to the above embodiments based on the technical essence of the present application without departing from the content of the technical solution of the present application are still within the scope of the technical solution of the present application.

Claims

1. A simulation data recording method, characterized in that: The method comprises: In the intelligent driving simulation process, cache simulation data; For each data frame of the cached simulation data, obtaining motion parameters of the host vehicle from the data frame, the motion parameters including speed, lateral acceleration, longitudinal acceleration, yaw angular velocity, and driving curvature; Obtaining a comfort score of the data frame according to the motion parameter; Obtaining a comfort threshold of the data frame according to the speed, the driving curvature, and a pre-trained comfort evaluation model in the motion parameters; Determining a target frame among the plurality of data frames included in the simulation data, the target frame being a data frame whose comfort score is greater than the comfort threshold; The simulation data in the target time period of the cached simulation data is converted to obtain a packet recording file, wherein the target time period includes a timestamp of the target frame.

2. The method according to claim 1, characterized in that The obtaining of the comfort score of the data frame according to the motion parameter includes: Obtaining a specified functional relationship, wherein the specified functional relationship includes a relationship between a comfort score and a motion parameter; A comfort score of the data frame is determined based on the specified functional relationship and the motion parameter.

3. The method according to claim 1, characterized in that The training process of the comfort evaluation model includes: Acquiring multiple sets of training data, each set of training data in the multiple sets of training data includes a speed, a driving curvature, and a calibrated comfort score of the vehicle; For each set of training data in the plurality of sets of training data, inputting the each set of training data into an initial comfort evaluation model to obtain a comfort score output by the initial comfort evaluation model; Calculating a loss function based on the calibrated comfort score and the output comfort score; Optimizing the parameters of the initial comfort evaluation model according to an optimization algorithm to minimize the loss function; Repeat the steps of loss function calculation and model parameter optimization until the stopping condition is met.

4. The method according to claim 3, characterized in that The obtaining of multiple sets of training data includes: Acquiring multiple sets of initial training data, the multiple sets of initial training data including motion parameters of the vehicle and comfort scores determined based on the motion parameters of the vehicle; determining a speed interval and a driving curvature interval based on the multiple sets of initial training data; Dividing the speed interval into n speed subintervals, and dividing the travel curvature interval into m travel curvature subintervals, the n speed subintervals and the m travel curvature subintervals forming p cells, where n is an integer greater than 1, m is an integer greater than 1, and p is the product of m and n; For the i-th cell among the p cells, obtaining a calibrated comfort score corresponding to the i-th cell; The median speed value, the median running curvature value of the i-th cell, and the calibrated comfort score corresponding to the i-th cell are taken as a set of training data, where i is an integer less than or equal to p.

5. The method according to claim 4, characterized in that The obtaining of the calibrated comfort score corresponding to the i-th cell includes: Performing statistical analysis on the comfort scores included in the i-th cell to obtain a local threshold corresponding to the i-th cell; Removing the comfort score greater than the local threshold in the i-th cell; The average of the remaining comfort scores in the i-th cell is determined as the calibrated comfort score corresponding to the i-th cell.

6. The method according to any one of claims 1 to 5, characterized in that The step of converting the simulation data within the target time period in the cached simulation data to obtain a recording file includes: Determining a target time period based on preconfigured packet recording time parameters, wherein the packet recording time parameters include a forward time parameter and / or a backward time parameter; the forward time parameter indicates the time interval between the start time of packet recording and the timestamp of the target frame, and the backward time parameter indicates the time interval between the end time of packet recording and the timestamp of the target frame; The simulation data within the target time period is acquired from the simulation data in the cache, and data conversion is performed on the simulation data within the target time period to obtain the package recording file.

7. The method according to any one of claims 1 to 5, characterized in that Before obtaining the comfort score of the data frame according to the motion parameter, the method includes: Obtaining the distance between the host vehicle and the target vehicle; Obtaining the relative speed between the host vehicle and the target vehicle in a specified direction, where the specified direction refers to the direction of the line connecting the host vehicle and the target vehicle; Obtaining a collision time based on the distance and the relative speed in the specified direction; If the collision time is greater than a preset threshold, the step of acquiring the comfort score of the data frame according to the motion parameter is performed.

8. A simulation data recording device, characterized in that: The device comprises: A cache module is used to cache simulation data in the intelligent driving simulation process; a parameter acquisition module, configured to acquire, for each data frame of the cached simulation data, motion parameters of the host vehicle from the data frame, the motion parameters including velocity, lateral acceleration, longitudinal acceleration, yaw angular velocity, and travel curvature; a score determination module, configured to obtain a comfort score of the data frame according to the motion parameters; a threshold determination module, configured to obtain a comfort threshold of the data frame according to the speed, the driving curvature, and a pre-trained comfort evaluation model in the motion parameters; a target frame determining module, configured to determine a target frame from among the plurality of data frames included in the simulation data, wherein the target frame refers to a data frame whose comfort score is greater than the comfort threshold; The packet recording module is used to convert the simulation data within the target time period in the cached simulation data to obtain a packet recording file, wherein the target time period includes the timestamp of the target frame.

9. An electronic device, characterized in that: include: Memory; one or more processors coupled to the memory; One or more programs, wherein the one or more application programs are stored in the memory and configured to be executed by the one or more processors, and the one or more programs are configured to perform the method according to any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that The computer-readable storage medium stores computer program instructions, which can be called by a processor to execute the method according to any one of claims 1 to 7.