Unmanned vehicle simulation data generation method, electronic equipment and storage medium
By generating shadow maps and driving data of simulation scenes and simulated vehicles, the problem of insufficient real driving data collection in unmanned driving is solved, high-quality simulated driving data support is provided, and the training and testing effects of unmanned driving algorithms are improved.
Patent Information
- Application Number
- CN202510896369.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-30
- Publication Date
- 2025-10-17
AI Technical Summary
In autonomous driving technology, real driving data in certain scenarios is difficult to collect, resulting in a small number of real samples in these scenarios, which cannot meet the training, testing and verification requirements of autonomous driving related algorithms.
By generating a simulation scene based on real point cloud data, setting a simulated vehicle, and determining the shadow map and simulated driving data based on the generation time and location of the real point cloud data, including generating the shadow map and simulated driving data of the simulated vehicle, and using the real driving data of the existing vehicle in the real point cloud data to generate the simulated driving data of the simulated vehicle.
Obtaining more realistic simulated driving data in a simulation environment solves the problem of insufficient and difficult-to-collect real vehicle driving data, provides sufficient sample support for unmanned driving-related algorithms, and improves the accuracy and efficiency of simulation testing.
Smart Images

Figure CN120807758A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present disclosure relates to the technical field of unmanned vehicle simulation, and particularly relates to an unmanned vehicle simulation data generation method, an electronic device and a storage medium. BACKGROUND
[0002] In the research and development process of unmanned driving technology, the driving data collected by a vehicle in a real road environment is a key sample data source. In the related technology, due to the difficulty in collecting real driving data of a vehicle in some scenarios, the number of real samples in these scenarios is small, which cannot meet the training, testing and verification requirements of unmanned driving related algorithms. SUMMARY
[0003] To overcome the problems in the related technology, the present disclosure provides an unmanned vehicle simulation data generation method, an electronic device and a storage medium.
[0004] According to a first aspect of an embodiment of the present disclosure, an unmanned vehicle simulation data generation method is provided, comprising:
[0005] generating a simulation scene according to real point cloud data;
[0006] setting a simulation vehicle in the simulation scene according to a generation time and a generation position of the real point cloud data, and generating a shadow map corresponding to the simulation vehicle;
[0007] generating simulation driving data of the simulation vehicle according to real driving data of an existing vehicle in the real point cloud data.
[0008] In some embodiments, the shadow map of the simulation vehicle is generated in the following manner:
[0009] determining a height angle and an azimuth angle corresponding to a real sun position according to the generation time and the generation position of the real point cloud data;
[0010] determining a shadow projection area of the simulation vehicle in the simulation scene based on the height angle and the azimuth angle;
[0011] generating the shadow map of the simulation vehicle according to the shadow projection area.
[0012] In some embodiments, the generating simulation driving data of the simulation vehicle according to real driving data of an existing vehicle in the real point cloud data comprises:
[0013] determining a position relationship between each pixel in the simulation scene and the shadow map in a self-vehicle perspective according to camera parameters of the self-vehicle in the real point cloud data;
[0014] render a simulation scene from a perspective of the ego vehicle, and reduce brightness of a pixel in the simulation scene covered by the shadow map according to the positional relationship;
[0015] render the simulation vehicle into a simulation scene from a perspective of the ego vehicle according to the camera parameter of the ego vehicle, to generate image data of the simulation vehicle.
[0016] In some embodiments, the generating the simulation driving data of the simulation vehicle according to the real driving data of the existing vehicle in the real point cloud data comprises:
[0017] moving each real trajectory point of the ego vehicle in the real point cloud data to a target direction corresponding to the real trajectory point by a target distance, to obtain a simulation trajectory point corresponding to the real trajectory point; wherein the target direction corresponding to each real trajectory point is perpendicular to a driving direction of the ego vehicle when the ego vehicle is at the real trajectory point, and the target direction corresponding to each real trajectory point points to the same side of the ego vehicle;
[0018] generating the simulation driving data of the simulation vehicle based on the simulation trajectory point.
[0019] In some embodiments, the generating the simulation driving data of the simulation vehicle according to the real driving data of the existing vehicle in the real point cloud data comprises:
[0020] extending a real trajectory point corresponding to a last frame of the ego vehicle in the real point cloud data to a driving direction of the ego vehicle by a target distance, to form a driving trajectory extension segment; wherein the target distance is an expected driving distance of the ego vehicle within a target frame number; discretizing the trajectory extension segment into a plurality of extension trajectory points according to the target frame number, the number of the extension trajectory points being the same as the target frame number; taking an i-th real trajectory point in the driving direction of the ego vehicle in the plurality of real trajectory points as a starting point of the simulation vehicle, and taking the starting point, real trajectory points after the starting point, and the plurality of extension trajectory points as simulation trajectory points of the simulation vehicle; and generating simulation driving data of the simulation vehicle based on the simulation trajectory points; or
[0021] extend a real trajectory point corresponding to a first frame of the ego vehicle in the real point cloud data by a target distance in a direction opposite to a driving direction of the ego vehicle to form a driving trajectory extension segment, wherein the target distance is an expected driving distance of the ego vehicle within a target frame number; discretize the trajectory extension segment into a plurality of extension trajectory points according to the target frame number, a number of the extension trajectory points being the same as the target frame number; take an ith real trajectory point in the driving direction of the ego vehicle in the plurality of real trajectory points as a terminal point of the simulation vehicle, and take the terminal point, a real trajectory point before the terminal point, and the plurality of extension trajectory points as simulation trajectory points of the simulation vehicle; and generate simulation driving data of the simulation vehicle based on the simulation trajectory points.
[0022] wherein i is equal to the target frame number.
[0023] In some embodiments, the setting the simulation vehicle in the simulation scene comprises:
[0024] replacing any vehicle generated according to the real point cloud data in the simulation scene with the simulation vehicle;
[0025] The generating the simulation driving data of the simulation vehicle according to the real driving data of the existing vehicle in the real point cloud data comprises:
[0026] taking real trajectory points of the replaced vehicle in the real point cloud data as simulation trajectory points of the simulation vehicle;
[0027] generating simulation driving data of the simulation vehicle based on the simulation trajectory points.
[0028] In some embodiments, the method further comprises:
[0029] sequentially traversing each simulation trajectory point, and determining a simulation driving trajectory containing each simulation trajectory point as a correct driving trajectory in a case where each simulation trajectory point satisfies a trajectory checking condition;
[0030] wherein the trajectory checking condition comprises at least one of the following:
[0031] in a case where the simulation vehicle is located at the simulation trajectory point, distances between a bounding box of the simulation vehicle and each point cloud annotation box in the real point cloud data are greater than a preset value;
[0032] in a case where the simulation vehicle is located at the simulation trajectory point, a point cloud annotation type below the bounding box of the simulation vehicle is a road type.
[0033] In some embodiments, the generating the simulation driving data of the simulation vehicle according to the real driving data of the existing vehicle in the real point cloud data comprises:
[0034] In the simulation scene, a laser radar position of the ego vehicle in the real point cloud data is taken as a starting point, and a light ray is projected to a position of each point in the real point cloud data;
[0035] Based on an intersection of the projected light ray and the simulation vehicle in the simulation scene, simulation point cloud data is constructed.
[0036] According to a second aspect of the embodiments of the present disclosure, an electronic device is provided, comprising:
[0037] a processor; and
[0038] a memory configured to store executable instructions of the processor;
[0039] The processor is configured to execute the method according to the first aspect by executing the executable instructions.
[0040] According to a third aspect of the embodiments of the present disclosure, a computer readable storage medium is provided, which stores a computer program. The computer program is executed by a processor to implement the method according to the first aspect.
[0041] The scheme provided by the embodiments of the present disclosure can generate a simulation scene according to real point cloud data. According to a generation time and a generation position of the real point cloud data, a simulation vehicle is set in the simulation scene, and a shadow map corresponding to the simulation vehicle is generated. According to real driving data of an existing vehicle in the real point cloud data, simulation driving data of the simulation vehicle is generated. By setting a virtual simulation vehicle in the simulation scene generated from the real point cloud data, the embodiments of the present disclosure can obtain relatively real simulation driving data of the simulation vehicle in the simulation environment. BRIEF DESCRIPTION OF DRAWINGS
[0042] Figure 1 A flowchart of a simulation data generation method of an unmanned vehicle in the embodiments of the present disclosure is shown.
[0043] Figure 2 A flowchart of a shadow map generation method in the embodiments of the present disclosure is shown.
[0044] Figure 3 A flowchart of a simulation trajectory point generation method in the embodiments of the present disclosure is shown.
[0045] Figure 4 A flowchart of a simulation trajectory point generation method in the embodiments of the present disclosure is shown.
[0046] Figure 5 A flowchart of a simulation trajectory point generation method in the embodiments of the present disclosure is shown.
[0047] Figure 6A schematic diagram showing another simulation trajectory point generation method in the embodiments of the present disclosure is shown.
[0048] Figure 7 A structural schematic diagram of a simulation data generation device for unmanned vehicles in the embodiments of the present disclosure is shown.
[0049] Figure 8 A structural schematic diagram of an electronic device in the embodiments of the present disclosure is shown. DETAILED DESCRIPTION
[0050] The exemplary embodiments will be described in detail herein with reference to the accompanying drawings. The following description relates to the accompanying drawings, in which the same numbers represent the same or similar elements throughout the several drawings. The implementations described in the following exemplary embodiments do not represent all implementations consistent with the present disclosure. Instead, they are merely examples of apparatuses and methods consistent with some aspects of the present disclosure as detailed in the appended claims.
[0051] In addition, the terms "first", "second", and the like used in the present disclosure are merely used to distinguish descriptions, and cannot be understood as indicating or implying relative importance.
[0052] First, a simulation data generation method for unmanned vehicles is provided in the embodiments of the present disclosure, which can be executed by any electronic device.
[0053] Figure 1 A flowchart of a simulation data generation method for unmanned vehicles in the embodiments of the present disclosure is shown, as shown in Figure 1 The method provided in the embodiments of the present disclosure includes the following S101-S103.
[0054] S101, generating a simulation scene according to real point cloud data.
[0055] Exemplarily, the real point cloud data can be understood as point cloud data collected in a real scene. For example, the real point cloud data can be collected in a real scene by a laser radar (LiDAR), a depth camera or other sensor devices, which can provide high-precision three-dimensional spatial information and generate corresponding real point cloud data.
[0056] Exemplarily, by processing and analyzing the real point cloud data, key elements such as terrain, vehicles, buildings, road markings and obstacles can be extracted, and then reconstructed into corresponding three-dimensional models in the simulation environment to generate a simulation scene.
[0057] S102, setting a simulation vehicle in the simulation scene according to the generation time and generation position of the real point cloud data, and generating a shadow map corresponding to the simulation vehicle.
[0058] In some embodiments, the simulated vehicle in the embodiments of the present disclosure is a vehicle that does not exist in the real point cloud data.
[0059] Exemplarily, the simulated vehicle type can be a vehicle that is not common in the real scene. For example, in a mine unmanned scene, the vehicle that is not common can be a bus, a shovel, a road roller, etc. Since the simulation scene is generated according to the real point cloud data, by setting this type of vehicle in the simulation scene, more realistic driving data of this type of vehicle can be obtained in the simulation environment, thereby solving the problem that the sample number of the driving data of this type of vehicle is small and difficult to collect. In addition, the number of simulated vehicles can be one or more, and the embodiments of the present disclosure do not limit this.
[0060] In some embodiments, the setting manner of the simulated vehicle in the simulation scene can refer to the generation time and the generation position of the real point cloud data. The generation time of the real point cloud data can be obtained through the timestamp of the generation of the real point cloud data. The generation position of the real point cloud data can be obtained based on the position information recorded by the positioning module carried by the ego vehicle at the moment of the generation of the real point cloud data.
[0061] Specifically, the generation time of the real point cloud data reflects the moment of the generation of the real point cloud data. The generation position of the real point cloud data indirectly reflects the position of the real point cloud data collection subject (for example, a vehicle carrying a laser radar, hereinafter referred to as "ego vehicle") at the moment of the generation of the real point cloud data. The position of the ego vehicle in the simulation scene can be obtained by mapping the position to the simulation scene. Since the perception range of the ego vehicle is known, the simulated vehicle can be set in the perception range of the ego vehicle in the simulation scene, so as to obtain the simulation driving data of the simulated vehicle.
[0062] For example, the simulated vehicle can be set in front of, behind, left side of or right side of the ego vehicle, and a certain distance is kept between the simulated vehicle and the ego vehicle. The distance can be greater than the safe distance of vehicle driving, and can be less than the maximum radius of the perception range of the ego vehicle. For another example, any existing vehicle in the real point cloud data can be replaced by the simulated vehicle. Since the real point cloud data is collected by the ego vehicle in the real scene, the existing vehicle in the real point cloud data is in the perception range of the ego vehicle.
[0063] That is to say, the position of the simulated vehicle in the simulation scene can be accurately placed in the perception range of the ego vehicle in combination with the position of each frame of the ego vehicle or other existing vehicles in the real point cloud data, and the simulated vehicle has a relatively real position relationship with the ego vehicle.
[0064] In some embodiments, the illumination angle of a light source (e.g., the sun or an artificial light source) in a real scene can be determined based on the generation time and location of the real point cloud data, thereby adding a shadow map to the simulated vehicle in the simulated scene. The shadow map can enhance the lighting and shadow effects of the simulated vehicle in the simulated scene, making the simulated vehicle more realistic, thereby improving the fidelity of the collected simulated driving data of the simulated vehicle.
[0065] S103 , generating simulated driving data of a simulated vehicle based on the real driving data of the existing vehicle in the real point cloud data.
[0066] In some embodiments, real driving data of an existing vehicle can be extracted from the real point cloud data. The real driving data includes at least the position information of the existing vehicle in each frame of the real point cloud data, i.e., the real trajectory points of the existing vehicle. Using the real trajectory points of the existing vehicle as a reference, the position of the simulated vehicle in each frame of the real point cloud data, i.e., the simulated trajectory points of the simulated vehicle, can be determined, thereby ensuring that the simulated trajectory points of the simulated vehicle match the trajectory points generated by vehicle driving in the real environment.
[0067] After determining the simulation trajectory points of each frame of the simulated vehicle, the position of the simulated vehicle in each frame in the simulation scene can be clarified, so as to generate simulated driving data of the simulated vehicle.
[0068] It is worth noting that the simulated driving data generated by the embodiments of the present disclosure can be multimodal. For example, it can include image data and point cloud data of the simulated vehicle from the perspective of the vehicle itself, as well as the simulated vehicle's speed, acceleration, heading angle, position information, etc., which are not limited by the embodiments of the present disclosure.
[0069] In other words, the real driving data may also include the speed, acceleration, and heading angle of each frame of the existing vehicle in the real point cloud data. This can be used as a reference to determine the speed, acceleration, and heading angle of the simulated vehicle, which is not limited in the present embodiment.
[0070] For example, the speed of the simulated vehicle can be maintained in a fixed proportional relationship with the speed of any existing vehicle in the real point cloud data. For example, the speed can be the same as the existing vehicle's speed, or 90% of the existing vehicle's speed. Of course, the speed of the simulated vehicle can also be independent of the speed of the existing vehicle, but can be dynamically adjusted based on the position information of the existing vehicle. For example, by adaptively setting the speed of the simulated vehicle, the simulated vehicle can always be parallel to the existing vehicle.
[0071] Based on the same principle, the acceleration, heading angle, etc. of the simulated vehicle are also kept in a fixed proportional relationship with the existing vehicle, or dynamically adjusted according to the position information of the existing vehicle. This embodiment of the present disclosure will not be elaborated on this.
[0072] In some embodiments, by changing the collection environment of the real point cloud data, simulation driving data in different environments can also be generated. For example, real point cloud data in different weathers, different temperatures and different road conditions can be collected, and corresponding simulation driving data can be generated based on the method provided in the present disclosure, so as to obtain simulation driving data corresponding to various complex road conditions.
[0073] Therefore, by setting a virtual simulation vehicle in the generation of a simulation scene from real point cloud data, the present embodiment can obtain relatively real simulation driving data of the simulation vehicle in the simulation environment. Thus, the technical problem of less real driving data of the vehicle and difficulty in collecting the real driving data is solved, and sufficient sample support can be provided for the test and test of the related algorithm of the unmanned vehicle.
[0074] The above is combined with Figure 1 The method for generating simulation data of an unmanned vehicle provided in the present disclosure is described in detail. The following will be combined with Figure 2 The method for generating shadow maps in the present embodiment is further described.
[0075] Figure 2 A flowchart of a method for generating a shadow map in the present embodiment is shown, as shown in the figure, the method comprises the following S201-S203. Figure 2
[0076] S201, according to the generation time and the generation position of the real point cloud data, the height angle and the azimuth angle corresponding to the real sun position are determined.
[0077] In some embodiments, according to the generation time and the generation position of the real point cloud data, the height angle and the azimuth angle of the sun in the real environment corresponding to the real point cloud data can be determined by the solar position algorithm (SPA). Based on the height angle and the azimuth angle of the real sun, the relative position relationship between the sun and the simulation vehicle in the simulation scene can be determined.
[0078] Among them, the height angle can be understood as the angle of the sun relative to the ground, which determines the angle between the sunray and the ground. The azimuth angle can be understood as the angle of the sun relative to the ground reference direction (for example, the north direction), which is used to describe the horizontal projection direction of the sunray.
[0079] S202, based on the height angle and the azimuth angle, the shadow projection area of the simulation vehicle in the simulation scene is determined.
[0080] In some embodiments, the state of the sunlight irradiating on the simulation vehicle can be calculated according to the altitude angle and azimuth angle of the real sun, in combination with the geometric model of the simulation vehicle (such as the height and width of the vehicle body) in the simulation scene, using a lighting model (for example, a ray tracing technique or a ray casting algorithm), and then the shadow projection area of the simulation vehicle in the simulation scene can be determined.
[0081] For example, the direction of the sunlight irradiation can be determined according to the altitude angle and azimuth angle of the real sun. Then, the intersection of the sunlight and the geometric model of the simulation vehicle is determined through the ray casting algorithm, and then the shadowing state of the simulation vehicle to the sunlight can be determined. In the simulation scene, the area that can be shadowed by the simulation vehicle to the sunlight is the shadow projection area of the simulation vehicle.
[0082] In some embodiments, when determining the shadow projection area of the simulation vehicle, the influence of the objects around the simulation vehicle on the shadow projection area can also be considered. For example, the buildings, other vehicles and other objects in the simulation scene can form a shadow to the sunlight before the simulation vehicle, or change the propagation path of the sunlight through reflection, refraction and other optical phenomena. In order to eliminate the influence of the objects around the simulation vehicle on the shadow projection area, when determining the shadow projection area of the simulation vehicle, the objects within a certain range around the simulation vehicle can be modeled and the corresponding materials can be set to simulate the influence of the objects around the simulation vehicle on the propagation path of the sunlight.
[0083] In some embodiments, since the altitude angle and azimuth angle of the real sun change over time, even if the simulation vehicle is in a static state, its shadow projection area is dynamically changing. Therefore, whenever the altitude angle or azimuth angle of the sun changes, the shadow projection area of the simulation vehicle can be dynamically updated to ensure that the shadow effect in the simulation scene is always consistent with the lighting conditions in the real environment, and the reality of the shadow generation is improved.
[0084] S203, generate a shadow map of the simulation vehicle according to the shadow projection area.
[0085] In some embodiments, the shadow projection area and the non-projection area in the simulation scene can be respectively marked with different labels. By reducing the display brightness of the shadow projection area, the generation of the shadow map can be realized to simulate the shadow effect under the approximate lighting conditions in the real scene.
[0086] It is worth noting that when rendering the simulation vehicle and its shadow map, the shadow map can be rendered first, and then the vehicle model of the simulation vehicle can be rendered to avoid incorrect shadowing of the simulation vehicle by the shadow map.
[0087] Exemplarily, in the process of generating the shadow map, an anti-aliasing technique can also be adopted to refine the shadow edges, eliminate unnatural phenomena in the shadow transition, and ensure that the generated shadow effect is smoother and more realistic.
[0088] Through the implementation of the above steps, the embodiment of the present disclosure can accurately calculate the position of the sun based on the generation time and position of the real point cloud data, thereby dynamically generating the shadow map of the simulation vehicle in the simulation scene. This method not only enables efficient shadow simulation, but also ensures that the shadow effect is consistent with the lighting conditions in the real environment, providing more realistic support for lighting effects in autonomous driving systems, simulation platforms, and virtual reality.
[0089] It can be understood that the above embodiments are directed to the generation of shadow maps in outdoor scenes with the sun as the main light source. For scenes dominated by artificial light sources, such as nighttime scenes or indoor scenes, the emission position of the artificial light source can be determined based on the emission object of the artificial light source shown in the real point cloud data, and then the shadow projection area of the simulation vehicle in the simulation scene can be determined in a similar manner, and the shadow map of the simulation vehicle can be generated based on the shadow projection area. The embodiment of the present disclosure does not repeat the description.
[0090] The above describes the generation method of the shadow map, and the construction method of the simulation scene has been described in detail. Next, the generation method of part of the simulation driving data will be described exemplarily in combination with Figure 3 and Figure 4 .
[0091] In some embodiments, the simulation driving data can include image data of the simulation vehicle. Please refer to Figure 3 , Figure 3 for a flowchart showing a method for generating image data in an embodiment of the present disclosure. The method includes the following steps:
[0092] S301, determining the positional relationship between each pixel in the simulation scene and the shadow map in the self-vehicle perspective based on the camera parameters of the self-vehicle in the real point cloud data.
[0093] In some embodiments, the camera parameters of the self-vehicle can be obtained, including the intrinsic and extrinsic parameters of the self-vehicle camera. The intrinsic parameters include focal length, principal point coordinates, etc., and the extrinsic parameters include the position and orientation of the camera relative to the self-vehicle coordinate system. These parameters can be obtained during the calibration of the camera and can be used to accurately map the relationship between the camera perspective and the objects in the simulation scene.
[0094] Exemplarily, according to the intrinsic and extrinsic parameters of the camera, the pixels and the shadow map in the simulation scene can be projected into the two-dimensional imaging plane of the ego vehicle camera respectively, so as to obtain the position of each pixel in the camera field of view in the simulation scene and the positional relationship with the shadow map. The shadow map is determined in advance in the simulation scene. Figure 2 The embodiment shown in the simulation scene is determined in advance.
[0095] S302, render the simulation scene from the perspective of the ego vehicle, and reduce the brightness of the pixels in the simulation scene covered by the shadow map according to the positional relationship.
[0096] In some embodiments, after projecting each pixel in the simulation scene into the two-dimensional imaging plane of the ego vehicle camera, a graphics rendering engine (such as OpenGL, DirectX, Vulkan, etc.) can be used to render the simulation scene into the imaging plane of the ego vehicle camera. Subsequently, according to the positional relationship between the shadow map obtained in step S301 and the pixels, the pixels covered by the shadow in the simulation scene (i.e., the pixels at the same position as the shadow map) can be determined, and the brightness of these pixels can be reduced to simulate the shadow effect.
[0097] In a specific implementation, a light attenuation module can be set in a fragment shader, which is used to reduce the light intensity of the pixel area covered by the shadow map in proportion, so as to effectively simulate the shadow effect in the real world.
[0098] In addition, in addition to reducing the brightness of the pixels covered by the shadow map, the blur degree and other characteristics of the pixels can also be adjusted according to the scene requirements, further improving the authenticity of the shadow effect in the image data.
[0099] S303, according to the camera parameters of the ego vehicle, render the simulation vehicle into the simulation scene from the perspective of the ego vehicle to generate image data of the simulation vehicle.
[0100] In some embodiments, after completing the rendering of the simulation scene from the perspective of the ego vehicle and adjusting the shadow effect, the simulation vehicle can be rendered into the scene next.
[0101] Specifically, the simulation vehicle can be rendered into the simulation environment that has been rendered using a similar rendering method as rendering the simulation environment in combination with the camera parameters of the ego vehicle, and the embodiments of the present disclosure do not make redundant descriptions.
[0102] Exemplarily, after the simulation vehicle is rendered, image data containing the simulation scene, the simulation vehicle, and the shadow map from the perspective of the ego vehicle camera can be finally generated. The image data can be used as a static image or as a frame of video, and the embodiments of the present disclosure do not make limitations.
[0103] It is worth noting that in the process of generating the image data of the simulation vehicle, the simulation scene and the shadow map in the simulation scene are first rendered, and then the simulation vehicle in the simulation scene is rendered. In this way, the shadow map can be designed to a certain extent to avoid the inappropriate occlusion and coverage of the simulation vehicle.
[0104] The simulation scene, the simulation vehicle and the shadow map of the simulation vehicle can be generated according to the camera parameters of the ego vehicle, so that more realistic visual data can be provided for the unmanned system, and the accuracy and efficiency of the simulation test of the unmanned vehicle can be improved.
[0105] In some embodiments, the simulation driving data can include point cloud data of the simulation vehicle. Please refer to Figure 4 , Figure 4 A flowchart of a method for generating point cloud data in an embodiment of the present disclosure is shown, which includes the following steps:
[0106] S401, in the simulation scene, the position of the laser radar of the ego vehicle in the real point cloud data is taken as the starting point, and the light rays are projected to the positions of each point in the real point cloud data.
[0107] In some embodiments, the position of the laser radar of the ego vehicle can be obtained from the real point cloud data and corresponded to the simulation scene. Then, the light rays can be projected to the positions of each point in the real point cloud data in the simulation scene, taking the position as the starting point, to simulate the behavior of the laser radar in the real scene. The direction and angle of each light ray can be determined according to the scanning range and viewing angle of the laser radar.
[0108] S402, based on the intersection of the projected light rays in the simulation scene and the simulation vehicle, the simulation point cloud data is constructed.
[0109] In some embodiments, the intersection of each light ray and the entity in the simulation scene can be calculated based on the ray tracing algorithm, so as to obtain the simulation point cloud data containing the simulation vehicle.
[0110] Exemplarily, the simulation point cloud data can not only show the spatial position of the simulation vehicle, but also contain other features such as the intensity of the reflected echo, semantic information and texture information, which are not limited by the embodiments of the present disclosure. The obtained simulation point cloud data can be used as input to the automatic driving or unmanned vehicle perception algorithm for further analysis and testing, such as obstacle detection, path planning, etc.
[0111] The embodiments of the present disclosure construct accurate simulation point cloud data containing the simulation vehicle by projecting light rays in the simulation environment and obtaining the intersection of the light rays and each entity in the simulation scene based on the position of the lidar in the real point cloud data. This process provides high-quality and realistic point cloud data for related application scenarios such as autonomous driving and unmanned vehicle perception algorithms, which can effectively support the testing and optimization of related algorithms.
[0112] As can be known from the above detailed description of S103, when generating the simulation driving data of the simulation vehicle, the simulation trajectory points of the simulation vehicle can be determined in advance by taking any existing vehicle trajectory point in the real point cloud data as a reference, and then the position of the simulation vehicle in each frame of simulation driving data is determined, so that the running trajectory of the simulation vehicle in the simulation environment conforms to the trajectory generated by the vehicle driving behavior in the real environment.
[0113] For ease of understanding, the determination method of the simulation trajectory point in the embodiments of the present disclosure will be described in detail below.
[0114] Firstly, the determination method of the simulation trajectory point will be described in combination with Figure 5 and Figure 6 , the method of generating the simulation trajectory point by taking the real trajectory point of the ego vehicle in the real point cloud data as a reference.
[0115] In some embodiments, please refer to Figure 5 , the determination method of the simulation trajectory point can be:
[0116] Each real trajectory point of the ego vehicle in the real point cloud data is moved by a target distance in a target direction corresponding to the real trajectory point to obtain a simulation trajectory point corresponding to the real trajectory point.
[0117] Wherein, the target direction corresponding to each real trajectory point is perpendicular to the driving direction of the ego vehicle when the ego vehicle is at the real trajectory point, and the target direction corresponding to each real trajectory point points to the same side of the ego vehicle.
[0118] For example, the i th real trajectory point of the ego vehicle in the real point cloud data can be moved by a target distance to the left side of the driving direction to obtain the i th simulation trajectory point of the simulation vehicle. Wherein, i is a positive integer, and n is the number of real trajectory points, which can also be understood as the total number of frames of the real point cloud data. Accordingly, the simulation trajectory points that travel in the same direction as the ego vehicle and always keep parallel can be generated.
[0119] For example, the i-th real trajectory point of the ego vehicle in the real point cloud data can be moved to the left of the driving direction by a target distance to obtain the n-i-th simulation trajectory point of the simulation vehicle. Wherein, i is a positive integer, and n is the number of real trajectory points, which can also be understood as the total number of frames of real point cloud data. It can be understood that the difference between this example and the above example is that this example generates trajectory points driving towards the ego vehicle. Although the trajectory points generated by this example are associated with each other, the simulation driving trajectory obtained is still parallel to the real trajectory of the ego vehicle, but is driving towards the ego vehicle in the driving direction.
[0120] Based on the same principle, the "to the left of the driving direction" in the above examples can be changed to "to the right of the driving direction", and the embodiments of the present disclosure will not be repeated.
[0121] Based on the generated simulation trajectory points, the position of the simulation vehicle in each frame of simulation driving data can be determined, and the simulation driving data of the simulation vehicle can be generated.
[0122] In some embodiments, please refer to Figure 6 The determination method of the simulation trajectory point can be:
[0123] The real trajectory point corresponding to the last frame of the real point cloud data of the ego vehicle is extended to the driving direction of the ego vehicle by a target distance to form a driving trajectory extension section. Wherein, the target distance is the expected driving distance of the ego vehicle within the target frame number.
[0124] According to the target frame number, the trajectory extension section is discretized into a plurality of extension trajectory points, and the number of extension trajectory points is the same as the target frame number.
[0125] The i-th real trajectory point in the driving direction of the ego vehicle in the plurality of real trajectory points is taken as the starting point of the simulation vehicle, and the starting point, the real trajectory point after the starting point and the plurality of extension trajectory points are taken as the simulation trajectory points of the simulation vehicle. Wherein, i is equal to the target frame number.
[0126] The embodiment of the present disclosure can generate a simulation trajectory point that is always located in front of the ego vehicle and maintains a target distance with the ego vehicle. It can be understood that, since the simulation trajectory point is always in front of the ego vehicle trajectory point, although in the first few frames of the simulation data, a real trajectory point that is always spaced apart from the real trajectory point where the ego vehicle is currently located by a target number of frames can be found and directly used as the simulation trajectory point of the simulation vehicle. However, in the last few frames of the simulation data, since the real trajectory point where the ego vehicle is currently located may not be able to find a real trajectory point that is exactly spaced apart from the real trajectory point where the ego vehicle is currently located by a target number of frames, the real trajectory point corresponding to the last frame of the ego vehicle in the real point cloud data can be extended by a target distance in the direction of travel of the ego vehicle to form an extended travel trajectory segment, and the extended segment can be decomposed into a plurality of extended trajectory points corresponding to the target number of frames. Thus, even if the real trajectory point where the ego vehicle is currently located is the real trajectory point of the last frame in the real point cloud data, an extended trajectory point that is spaced apart from the real trajectory point where the ego vehicle is currently located by a target number of frames can be found in the extended trajectory point as the simulation trajectory point of the simulation vehicle in the last frame.
[0127] That is, the distance between the simulation vehicle and the ego vehicle can be set as D, the total number of frames of the current real point cloud data is N, and the position of each frame of the simulation vehicle is calculated in the following manner.
[0128] Suppose Pe(0) is the position of the ego vehicle in the first frame, and Pe(i) is the position of the ego vehicle in the i-th frame, then the target distance L = Length(Pe(i)-Pe(0)).
[0129] Let the initial state i = 1, and in the case of L < D, let i = i + 1 until L >= D. Thus, the target number of frames between the trajectory points of the simulation vehicle and the ego vehicle can be determined as i, and further the travel trajectory of the ego vehicle can be extended by a distance D in the direction of travel, and the extended distance D can be discretized into trajectory points corresponding to i frames. At this time, the position of the simulation vehicle at time t is Po(t) = Pe(t+i).
[0130] After determining the simulation trajectory point corresponding to each frame of the simulation vehicle, the position of the simulation vehicle in each frame of the simulation driving data can be determined, and further the simulation driving data of the simulation vehicle can be generated.
[0131] In some embodiments, a simulation trajectory point that always follows behind the ego vehicle and maintains a target distance with the ego vehicle can also be generated based on a similar manner.
[0132] Specifically, the real trajectory point corresponding to the first frame of the ego vehicle in the real point cloud data can be extended by a target distance in the opposite direction of the travel direction of the ego vehicle to form an extended travel trajectory segment. The target distance is the expected travel distance of the ego vehicle within the target number of frames.
[0133] Discretize the extended trajectory segment into a plurality of extended trajectory points according to the target frame number, and the number of extended trajectory points is the same as the target frame number.
[0134] Take the i-th real trajectory point in the plurality of real trajectory points in the driving direction of the ego vehicle as the end point of the simulation vehicle, and take the end point, the real trajectory point before the end point, and the plurality of extended trajectory points as the simulation trajectory points of the simulation vehicle. Wherein, i is equal to the target frame number.
[0135] It can be understood that the difference between the embodiment of the present disclosure and the previous embodiment is that the simulation trajectory points generated by the embodiment of the present disclosure are always located behind the ego vehicle, while the simulation trajectory points generated by the previous embodiment are always located in front of the ego vehicle. Therefore, contrary to the previous embodiment, in the embodiment of the present disclosure, since the real trajectory point where the ego vehicle is currently located may not be able to find a real trajectory point that is spaced apart from the real trajectory point where the ego vehicle is currently located by the target frame number in the initial few frames of the simulation data, the real trajectory point corresponding to the first frame of the ego vehicle in the real point cloud data can be extended by a target distance in the opposite direction of the driving direction of the ego vehicle to form an extended trajectory segment, and the extended segment can be decomposed into a plurality of extended trajectory points corresponding to the target frame number.
[0136] That is, the distance between the simulation vehicle and the ego vehicle can be set as D, the total frame number of the current real point cloud data is N, and the position of the simulation vehicle in each frame can be calculated in turn as follows.
[0137] Assuming that Pe(N-1) is the position of the ego vehicle in the last frame, and Pe(i) is the position of the ego vehicle in the i-th frame, the target distance L = Length(Pe(i)-Pe(N-1)).
[0138] Let the initial state i = N-2, and in the case of L < D, let i = i-1 until L >= D. In this way, the target frame number of the trajectory point interval between the simulation vehicle and the ego vehicle can be determined as i, and the driving trajectory of the ego vehicle can be further extended by a distance D in the opposite direction of its driving direction, and the extended distance D can be discretized into trajectory points corresponding to i frames. At this time, the position of the simulation vehicle at time t is Po(t) = Pe(t-i).
[0139] After determining the simulation trajectory point corresponding to each frame of the simulation vehicle, the position of the simulation vehicle in each frame of the simulation driving data can be determined, and the simulation driving data of the simulation vehicle can be generated.
[0140] Next, the method of generating simulation trajectory points by taking the real trajectory points of other vehicles in the real point cloud data as a reference will be introduced.
[0141] Exemplarily, when the simulation vehicle is set in S102 above, any vehicle in the simulation scene generated according to the real point cloud data can be replaced by the simulation vehicle. That is, the simulation vehicle can be directly set at the position of the vehicle already in the simulation scene. In this case, the real trajectory points of the vehicle to be replaced in the real point cloud data can be directly taken as the simulation trajectory points of the simulation vehicle.
[0142] In this way, since the existing vehicle has been replaced by the simulation vehicle, the driving trajectory points of the simulation vehicle can be made the same as the driving trajectory points of the existing vehicle in the real point cloud data, so that the simulation vehicle simulates the driving behavior of the existing vehicle, and the authenticity of the simulation trajectory points is improved.
[0143] Based on the generated simulation trajectory points, the position of the simulation vehicle in each frame of simulation driving data can be determined, and the simulation driving data of the simulation vehicle can be generated.
[0144] In some embodiments, for the simulation trajectory points generated in the above way, the rationality of the simulation trajectory formed by the simulation trajectory points can be checked in the following way.
[0145] Exemplarily, each simulation trajectory point can be traversed in sequence, and in the case that each simulation trajectory point meets the trajectory checking condition, the simulation driving trajectory containing each simulation trajectory point is determined as a correct driving trajectory.
[0146] The trajectory checking condition includes at least one of the following: in the case that the simulation vehicle is located at the simulation trajectory point, the distance between the bounding box of the simulation vehicle and each point cloud bounding box in the real point cloud data is greater than a preset value; in the case that the simulation vehicle is located at the simulation trajectory point, the point cloud bounding box below the bounding box of the simulation vehicle is of a road type.
[0147] Through the trajectory rationality checking, the simulation vehicle can be prevented from interfering with other objects in the simulation scene or being set at an obviously unreasonable position in the simulation scene.
[0148] Based on the same inventive concept, another unmanned vehicle simulation data generation device is also provided in the embodiments of the present disclosure, as follows. Since the principle of solving problems of the unmanned vehicle simulation data generation device embodiment is similar to the method embodiment shown above, the implementation of the unmanned vehicle simulation data generation device embodiment can be referred to the implementation of the method embodiment shown above, and the repeated parts will not be described herein. Figure 1 The method embodiment shown above, and the repeated parts will not be described herein. Figure 1 The method embodiment shown above, and the repeated parts will not be described herein.
[0149] Figure 7 The structure of an unmanned vehicle simulation data generation device in the embodiments of the present disclosure is shown. As shown in FIG. 1, the device comprises a simulation vehicle setting unit 1001, a simulation trajectory point generation unit 1002, a simulation trajectory rationality checking unit 1003, and a simulation driving data generation unit 1004. Figure 7As shown, the unmanned vehicle simulation data generation apparatus 700 comprises:
[0150] A first generation module 701 is configured to generate a simulation scene according to real point cloud data.
[0151] A setting module 702 is configured to set a simulation vehicle in the simulation scene and generate a shadow map corresponding to the simulation vehicle according to a generation time and a generation position of the real point cloud data.
[0152] A second generation module 703 is configured to generate simulation driving data of the simulation vehicle according to real driving data of an existing vehicle in the real point cloud data.
[0153] In some embodiments, the setting module 702 is configured to determine an altitude angle and an azimuth angle corresponding to a real sun position according to the generation time and the generation position of the real point cloud data; determine a shadow projection area of the simulation vehicle in the simulation scene based on the altitude angle and the azimuth angle; and generate the shadow map of the simulation vehicle according to the shadow projection area.
[0154] In some embodiments, the second generation module 703 is configured to determine a positional relationship between each pixel in the simulation scene and the shadow map in a self-vehicle perspective according to camera parameters of the self-vehicle in the real point cloud data; render the simulation scene in the self-vehicle perspective and reduce the brightness of the pixels in the simulation scene covered by the shadow map according to the positional relationship; and render the simulation vehicle into the simulation scene in the self-vehicle perspective according to the camera parameters of the self-vehicle to generate image data of the simulation vehicle.
[0155] In some embodiments, the second generation module 703 is configured to move each real trajectory point of the self-vehicle in the real point cloud data to a target direction corresponding to the real trajectory point by a target distance to obtain a simulation trajectory point corresponding to the real trajectory point; wherein the target direction corresponding to each real trajectory point is perpendicular to a driving direction of the self-vehicle when the self-vehicle is at the real trajectory point, and the target direction corresponding to each real trajectory point points to the same side of the self-vehicle; and generate the simulation driving data of the simulation vehicle based on the simulation trajectory points.
[0156] In some embodiments, the second generation module 703 is configured to extend a real trajectory point corresponding to a last frame of the self-vehicle in the real point cloud data to a driving direction of the self-vehicle by a target distance to form an extended driving track segment; wherein the target distance is an expected driving distance of the self-vehicle within a target frame number; discretize the extended driving track segment into a plurality of extended trajectory points according to the target frame number, the number of the extended trajectory points being the same as the target frame number; take an i-th real trajectory point in the driving direction of the self-vehicle in the plurality of real trajectory points as a starting point of the simulation vehicle, and take the starting point, the real trajectory points after the starting point, and the plurality of extended trajectory points as simulation trajectory points of the simulation vehicle; and generate the simulation driving data of the simulation vehicle based on the simulation trajectory points; wherein i is equal to the target frame number.
[0157] In some embodiments, the second generation module 703 is configured to extend the real trajectory point corresponding to the first frame of the ego vehicle in the real point cloud data to the opposite direction of the driving direction of the ego vehicle by a target distance to form a driving trajectory extension segment; the target distance is the expected driving distance of the ego vehicle within a target frame number; the trajectory extension segment is discretized into a plurality of extension trajectory points according to the target frame number, and the number of the extension trajectory points is the same as the target frame number; the i th real trajectory point in the driving direction of the ego vehicle in the plurality of real trajectory points is taken as the end point of the simulation vehicle, and the end point, the real trajectory point before the end point, and the plurality of extension trajectory points are taken as the simulation trajectory points of the simulation vehicle; the simulation driving data of the simulation vehicle is generated based on the simulation trajectory points; and i is equal to the target frame number.
[0158] In some embodiments, the setting module 702 is configured to replace any vehicle generated according to the real point cloud data in the simulation scene with the simulation vehicle. The second generation module 703 is configured to take the real trajectory point of the replaced vehicle in the real point cloud data as the simulation trajectory point of the simulation vehicle, and generate the simulation driving data of the simulation vehicle based on the simulation trajectory point.
[0159] In some embodiments, the second generation module 703 is further configured to sequentially traverse each simulation trajectory point, and determine that the simulation driving trajectory containing each simulation trajectory point is a correct driving trajectory in a case where each simulation trajectory point satisfies a trajectory checking condition. The trajectory checking condition includes at least one of the following: the distance between the bounding box of the simulation vehicle and each point cloud bounding box in the real point cloud data is greater than a preset value in a case where the simulation vehicle is located at the simulation trajectory point; and the point cloud bounding box below the bounding box of the simulation vehicle is of a road type in a case where the simulation vehicle is located at the simulation trajectory point.
[0160] In some embodiments, the second generation module 703 is configured to project a light ray to the position of each point in the real point cloud data from the laser radar position of the ego vehicle in the real point cloud data in the simulation scene; and construct the simulation point cloud data based on the intersection of the projected light ray and the simulation vehicle in the simulation scene.
[0161] Those skilled in the art can understand that each aspect of the present disclosure can be implemented as a system, a method or a program product. Therefore, each aspect of the present disclosure can be embodied as a whole hardware embodiment, a whole software embodiment (including firmware, microcode, etc.), or an embodiment combining hardware and software aspects, which can be collectively referred to as "circuitry", "module" or "system".
[0162] The electronic device 800 capable of implementing the embodiments of the present disclosure will be described below with reference to the accompanying drawings. Figure 8 Figure 8 The electronic device 800 shown is merely one example and should not be taken as limiting the scope of the present disclosure.
[0163] As shown in Figure 8 The electronic device 800 is in the form of a general computing device. Components of the electronic device 800 can include, but are not limited to, at least one processing unit 810, at least one memory unit 820, a bus 830 connecting different system components, including the memory unit 820 and the processing unit 810.
[0164] The memory unit stores program codes which can be executed by the processing unit 810, so that the processing unit 810 performs the steps described in the above “Exemplary Method” section according to various exemplary embodiments of the present disclosure.
[0165] In some embodiments, the processing unit 810 can perform the following steps of the above method embodiments: generating a simulation scene according to real point cloud data; setting a simulation vehicle in the simulation scene according to the generation time and the generation position of the real point cloud data, and generating a shadow map corresponding to the simulation vehicle; and generating simulation driving data of the simulation vehicle according to real driving data of an existing vehicle in the real point cloud data.
[0166] The memory unit 820 can include a readable medium in the form of a volatile memory unit, such as a random access memory (RAM) 8201 and / or a cache memory unit 8202, and can further include a read-only memory (ROM) 8203.
[0167] The memory unit 820 can further include program / utility 8204 having a set of programs / modules 8205, including but not limited to, an operating system, one or more applications, other programs / modules, and program data, each of which or a combination thereof can include implementation of a network environment.
[0168] The bus 830 can represent one or more of several types of bus structures, including a memory bus or memory controller, a peripheral bus, a graphics acceleration bus, a processing bus, or a local bus using any of a variety of bus architectures.
[0169] The electronic device 800 can also communicate with one or more external devices 840 such as a keyboard or pointing device, a Bluetooth device, or a Figure 8 network adapter 860. As will be understood, however, data that is transferred between components of the electronic device 800 can be encrypted to prevent unauthorized access to the data. Similarly, processors can be supplemented by, or incorporated in, special purpose logic circuitry as required. Also, any or all of the individual components of the electronic device 800 and / or the individual functional elements of the software implementations can be implemented as integrated circuits, discrete elements, or components otherwise assembled by a process, such as an additive process, a subtractive process, or both. The order of execution or performance of the methods illustrated and described herein is not essential, and that the individual steps as written can not be performed in chronological order. Rather, all
[0170] From the above description of embodiments, it is manifest that the example embodiments described herein can be implemented by software and / or by hardware components. It is further manifest that the techniques of the present disclosure can be realized in software, firmware, hardware, or any combination thereof. Therefore, the techniques of the present disclosure can be realized in a centralized fashion in one computer system or network, or in a distributed fashion where different elements are spread across several computer systems or sub-systems. Any kind of computer system, or other apparatus adapted for carrying out the methods described herein, is suited. A typical combination of hardware and software could be a general purpose computer system, with a computer program that, when being loaded and executed, controls the computer system such that it carries out the methods described herein.
[0171] In an exemplary embodiment of the present disclosure, a computer readable storage medium can also be provided, which can be a readable signal medium or a readable storage medium. The program product stored on the computer readable storage medium can be used to implement the method of the present disclosure. In some possible embodiments, various aspects of the present disclosure can also be implemented in the form of a program product, which includes program codes for causing an end device to perform the steps described in the "Exemplary Methods" section according to various exemplary embodiments of the present disclosure when the program product is run on the end device.
[0172] Through the description of the above embodiments, those skilled in the art can easily understand that the example embodiments described herein can be implemented by software, or by software in combination with necessary hardware. Therefore, the technical solutions according to the embodiments of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash disk, a mobile hard disk, or the like) or a network, and includes a number of instructions to make a computing device (which can be a personal computer, a server, a mobile terminal, or a network device, etc.) execute the methods according to the embodiments of the present disclosure.
[0173] Other embodiments of the present disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the features disclosed herein. The present disclosure is intended to cover any variations, uses, or adaptations of the present disclosure following the general principles thereof and including such departures from the present disclosure that come within known use or custom in the art to which the present disclosure pertains. The specification and examples are to be regarded as illustrative only, and the true scope and spirit of the present disclosure are indicated by the appended claims.
Claims
1. A method for generating simulation data for an unmanned vehicle, characterized in that: include: Generate simulation scenes based on real point cloud data; Setting a simulated vehicle in the simulation scene according to the generation time and generation location of the real point cloud data, and generating a shadow map corresponding to the simulated vehicle; The simulated driving data of the simulated vehicle is generated based on the real driving data of the existing vehicle in the real point cloud data.
2. The method according to claim 1, characterized in that The shadow map of the simulated vehicle is generated as follows: Determine the altitude and azimuth corresponding to the actual sun position according to the generation time and generation location of the actual point cloud data; Determining a shadow casting area of the simulated vehicle in the simulation scene based on the altitude angle and the azimuth angle; A shadow map of the simulated vehicle is generated according to the shadow projection area.
3. The method according to claim 1 or 2, characterized in that The generating of the simulated driving data of the simulated vehicle according to the real driving data of the existing vehicle in the real point cloud data comprises: Determining, based on the camera parameters of the ego vehicle in the real point cloud data, the positional relationship between each fragment and the shadow map in the simulation scene from the perspective of the ego vehicle; Rendering a simulation scene from the perspective of the vehicle, and reducing the brightness of fragments in the simulation scene that are covered by the shadow map based on the positional relationship; The simulated vehicle is rendered into a simulated scene from the perspective of the vehicle according to the camera parameters of the vehicle, and image data of the simulated vehicle is generated.
4. The method according to claim 1, wherein The generating of the simulated driving data of the simulated vehicle according to the real driving data of the existing vehicle in the real point cloud data comprises: Each real trajectory point of the ego vehicle in the real point cloud data is moved by a target distance in a target direction corresponding to the real trajectory point to obtain a simulated trajectory point corresponding to the real trajectory point; wherein the target direction corresponding to each real trajectory point is perpendicular to the driving direction of the ego vehicle when it is located at the real trajectory point, and the target direction corresponding to each real trajectory point points to the same side of the ego vehicle; Based on the simulation trajectory points, simulated driving data of the simulated vehicle is generated.
5. The method according to claim 1, wherein The generating of the simulated driving data of the simulated vehicle according to the real driving data of the existing vehicle in the real point cloud data comprises: Extend the real trajectory point corresponding to the last frame of the ego vehicle in the real point cloud data by a target distance in the driving direction of the ego vehicle to form an extended driving trajectory segment; wherein the target distance is the expected driving distance of the ego vehicle within the target number of frames; according to the target number of frames, discretize the extended trajectory segment into multiple extended trajectory points, and the number of the extended trajectory points is the same as the target number of frames; among the multiple real trajectory points, the i-th real trajectory point in the driving direction of the ego vehicle is used as the starting point of the simulated vehicle, and the starting point, the real trajectory points after the starting point, and the multiple extended trajectory points are used as simulated trajectory points of the simulated vehicle; based on the simulated trajectory points, generate simulated driving data of the simulated vehicle; or Extend the real trajectory point corresponding to the first frame of the ego vehicle in the real point cloud data by a target distance in the opposite direction of the ego vehicle's travel direction to form an extended travel trajectory segment; wherein the target distance is the expected travel distance of the ego vehicle within the target number of frames; discretize the extended trajectory segment into a plurality of extended trajectory points according to the target number of frames, and the number of the extended trajectory points is the same as the target number of frames; take the i-th real trajectory point in the travel direction of the ego vehicle among the plurality of real trajectory points as the end point of the simulated vehicle, and take the end point, the real trajectory point before the end point, and the plurality of extended trajectory points as simulated trajectory points of the simulated vehicle; and generate simulated travel data of the simulated vehicle based on the simulated trajectory points; Wherein, i is equal to the target number of frames.
6. The method according to claim 1, wherein The step of setting a simulated vehicle in the simulation scene includes: Replacing any vehicle in the simulation scene generated based on the real point cloud data with the simulated vehicle; The generating of the simulated driving data of the simulated vehicle according to the real driving data of the existing vehicle in the real point cloud data comprises: Using the real trajectory points of the replaced vehicle in the real point cloud data as the simulated trajectory points of the simulated vehicle; Based on the simulation trajectory points, simulated driving data of the simulated vehicle is generated.
7. The method according to any one of claims 4 to 6, characterized in that The method further comprises: Traversing each simulation trajectory point in turn, and when each simulation trajectory point satisfies the trajectory checking condition, determining that the simulation driving trajectory containing each simulation trajectory point is the correct driving trajectory; The trajectory checking condition includes at least one of the following: When the simulated vehicle is located at the simulated trajectory point, the distances between the bounding box of the simulated vehicle and each point cloud annotation box in the real point cloud data are greater than a preset value; When the simulated vehicle is located at the simulated trajectory point, the point cloud annotation type below the bounding box of the simulated vehicle is a road type.
8. The method according to claim 1, characterized in that The generating of the simulated driving data of the simulated vehicle according to the real driving data of the existing vehicle in the real point cloud data comprises: In the simulation scene, using the laser radar position of the vehicle in the real point cloud data as a starting point, projecting light to the position of each point in the real point cloud data; Construct simulation point cloud data based on the intersection of the projected light in the simulation scene and the simulated vehicle.
9. An electronic device, characterized in that: include: processor; as well as a memory for storing executable instructions of the processor; The processor is configured to perform the method according to any one of claims 1 to 8 by executing the executable instructions.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 8 is implemented.