GPS-based high-precision simulation map construction method and system
Through GPS track point conversion and track point density enhancement technology, high-precision simulation maps are generated, which solves the high-cost problem in the existing technology, realizes the construction of high-precision simulation maps and guarantees real effects.
Patent Information
- Application Number
- CN202410438568.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-04-12
- Publication Date
- 2024-08-23
AI Technical Summary
The construction cost of existing high-precision simulation maps is high, and it is difficult to achieve a one-to-one simulation effect with the real environment.
By obtaining the GPS track points of the collection vehicle, converting them to the ground coordinate system, calculating and judging the lane track type and slope changes, and increasing the density of track points at equal intervals, the track point coordinates are input into the OpenDrive file to generate a simulation map for simulation scenario testing.
It realizes the construction of high-precision simulation maps, reduces the cost of construction of simulation maps, and ensures the simulation effect of real roads.
Smart Images

Figure CN118533190A
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of autonomous driving, and in particular relates to a method and system for constructing a high-precision simulation map based on GPS. Background Art
[0002] With the development of autonomous driving technology, more and more automobile manufacturers are developing L3 autonomous driving functions. Simulation testing of autonomous driving is an important task. It can test the performance indicators of autonomous driving functions. To achieve a one-to-one simulation effect with the real environment, the restoration of high-precision simulation maps is essential.
[0003] At present, the construction of high-precision simulation maps usually requires that the collection vehicle use laser radar, vehicle-mounted cameras, combined navigation and other equipment to conduct field perception and collection, and then use image recognition, point cloud data modeling and other technologies to realize the construction of simulation maps. Although this method has high map accuracy, the implementation cost is also very high. Summary of the invention
[0004] In view of this, an embodiment of the present invention provides a method and system for constructing a high-precision simulated map based on GPS, which is used to solve the problem of high cost in constructing existing high-precision simulated maps.
[0005] In a first aspect of an embodiment of the present invention, a method for constructing a high-precision simulated map based on GPS is provided, comprising:
[0006] Get the GPS location of the collection vehicle's track points and convert the GPS location to the ground coordinate system;
[0007] Obtain adjacent track points, calculate and determine lane track type and slope change based on the coordinates of the adjacent track points in the ground coordinate system, and increase the track point density at equal intervals;
[0008] The coordinates of the trajectory points are input into the OpenDrive file to generate a simulation map, the simulation map is loaded and a simulation scenario test is performed.
[0009] In a second aspect of an embodiment of the present invention, a high-precision simulation map construction system based on GPS is provided, comprising:
[0010] Coordinate conversion module, used to obtain the GPS location of the collection vehicle trajectory point and convert the GPS location to the ground coordinate system;
[0011] The road fitting module is used to obtain adjacent trajectory points, calculate and determine the lane trajectory type and slope change according to the coordinates of the adjacent trajectory points in the ground coordinate system, and increase the density of trajectory points at equal intervals;
[0012] The map generation module is used to input the coordinates of the track points into the OpenDrive file to generate a simulation map, and load the simulation map to perform simulation scenario testing.
[0013] In a third aspect of an embodiment of the present invention, an electronic device is provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the method described in the first aspect of the embodiment of the present invention when executing the computer program.
[0014] In a fourth aspect of an embodiment of the present invention, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the method provided in the first aspect of the embodiment of the present invention are implemented.
[0015] In the embodiment of the present invention, after converting the GPS track points of the collected vehicle into the ground coordinate system, the lane track type and slope change are calculated and determined according to the coordinates of the adjacent track points, the density of track points is increased equidistantly to fit the lane, the track points are written into the OpenDrive file to generate a simulation map, and the simulation scene test is performed by loading the simulation map. This not only realizes the construction of high-precision simulation maps, but also effectively reduces the construction cost of simulation maps and ensures the simulation effect of real roads. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0017] Figure 1 A flowchart of a method for constructing a high-precision simulated map based on GPS provided by an embodiment of the present invention;
[0018] Figure 2 A schematic diagram of trajectory points provided for one embodiment of the present invention;
[0019] Figure 3 A schematic diagram of the structure of a high-precision simulation map construction system based on GPS provided by one embodiment of the present invention;
[0020] Figure 4 A schematic structural diagram of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0021] In order to make the purpose, features and advantages of the present invention more obvious and easy to understand, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the embodiments described below are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0022] It should be understood that the term "including" and other similar expressions in the specification or claims of the present invention and the above-mentioned drawings are intended to cover non-exclusive inclusions, such as a process, method, system, or device including a series of steps or units is not limited to the listed steps or units. In addition, "first" and "second" are used to distinguish different objects, not to describe a specific order.
[0023] See also Figure 1 , a flowchart of a method for constructing a high-precision simulated map based on GPS provided by an embodiment of the present invention includes:
[0024] S101, obtaining the GPS location of the collection vehicle track point, and converting the GPS location to a ground coordinate system;
[0025] When the data collection vehicle is driving on the real-life road, it will record the vehicle's trajectory information in real time, obtain the coordinates of the vehicle's trajectory points, and convert the latitude and longitude and altitude in the GPS positioning to the plane's xyz coordinate system, using xy to represent the plane coordinates and z to represent the altitude.
[0026] S102, obtaining adjacent trajectory points, calculating and determining the lane trajectory type and slope change according to the coordinates of the adjacent trajectory points in the ground coordinate system, and increasing the density of the trajectory points at equal intervals;
[0027] The adjacent trajectory points are several adjacent trajectory points in the vehicle trajectory. Generally, three adjacent trajectory points are taken to determine information such as lane type and slope change.
[0028] Specifically, three adjacent trajectory points are obtained, and according to the slopes of two adjacent trajectory points, it is determined whether the three trajectory points form a straight line; if the three trajectory points do not form a straight line, it is determined that the three trajectory points form a curve, and the radius of curvature is calculated according to the coordinates of the three trajectory points; when the horizontal heights of the three trajectory points are inconsistent, it is determined whether the trajectory points are uphill or downhill according to the changes in the horizontal heights of the three trajectory points.
[0029] Among them, new track points are added at a predetermined distance between adjacent track points, and the coordinates of the new track points are calculated. New track points are evenly added at a certain distance between adjacent track points, such as adding a point every 0.1m.
[0030] For example, Figure 2 As shown, for the calculation of road curvature, first take the horizontal and vertical coordinates of the three trajectory points, A (x1, y1), B (x2, y2), C (x3, y3), the slope of point AB is k1 = (y2-y1) / (x2-x1), and the slope of point BC is k2 = (y3-y2) / (x3-x2). If k1 = k2, the three points ABC form a straight line, and new points are added between ABC at a certain distance (such as 0.1m) to form dense point coordinates.
[0031] If the three trajectory points are C(x4,y4), D(x5,y5), and E(x6,y6), the slope of point CD is k3=(y5-y4) / (x5-x4), and the slope of point DE is k4=(y6-y5) / (x6-x5). If k3≠k4, then the three points CDE constitute a curve. The coordinates of the three points CDE can be solved to obtain the coordinates of the center O. Assuming the coordinates of the center are (x0,y0), the radius of curvature is: r=sqrt((y3-y0)*(y3-y0)+(x3-x0)*(x3-x0)). Take points F and C on the circle with a distance of 0.1m. The central angle formed by points F, O and C is a, a=arcs in((0.1*180) / (pi*r)), then the horizontal and vertical coordinates of the newly added point F are: x=x3+r*sin(a), y=y3+rr*cos(a), and several points are evenly added to the three points CDE, with a distance of 0.1 between the points. The coordinate calculation method is the same as that of point F, and the coordinates of all points are obtained.
[0032] For the calculation of road slope, the xy coordinates are replaced with xz coordinates, and the xz coordinates of all dense points of road slope are calculated. The xy coordinates of all dense points related to the road curvature and the z coordinates (i.e., horizontal height) related to the slope are calculated. Then, the lane curvature trajectory coordinates and ramp coordinates of each trajectory point constitute the three-dimensional coordinates of the simulated road.
[0033] S103, inputting the coordinates of the trajectory points into the OpenDrive file to generate a simulation map, loading the simulation map and performing a simulation scenario test.
[0034] Optionally, the coordinates of the trajectory points and the ramp coordinates are written into the OpenDrive file in sequence, and the road parameter values are set to obtain a high-precision simulation map.
[0035] Write the coordinates of the track points and ramps into the field attribute values of the track points and ramps corresponding to the OpenDrive file in xodr format in turn, set the road length, width, lane line color and line type and other parameter values in the corresponding fields, and you can generate an OpenDrive file of a high-precision simulation map.
[0036] Specifically, the coordinates of the lane bending trajectory are written into the opendrive file with code as <geometry hdg="0"length="0.1"s="0.1"x="0.0"y="0.0"><line / >. A geometry attribute corresponds to a coordinate point. hdg represents the radian value corresponding to the yaw angle from the current point to the next point, which can be calculated through the coordinates of two points. Length represents the length from the current point to the next point. s represents the total length of the road from the starting point to the current point. x and y represent the coordinate values of the current point. The above attribute values are written into the opendrive file in the order of the lane trajectory point coordinates. The lane slope coordinates are written into the opendrive file with code as <elevationProfile><elevation a="100"b="0.1"c="0"d="0"s="0" / ><elevation a="100.01"b="0.1"c="0"d="0"s="0.1" / >< / elevationProfile>, a in elevation represents the altitude of the coordinates of the current point, b represents the height value of the rise or fall for every 1m of advance, s represents the distance from the starting point to the current point, and the z coordinates of all points on the slope are written into a in turn, b is obtained by subtracting the z values of two points, and s is obtained by accumulating the distance differences of multiple points. The number of lanes is written into the laneSection attribute from 1 to n, the id in the lane field, the road width is written into a in the width field, the lane line color, width, and linear information are written into roadMark, and the road length information is written into the length in the road attribute. After all the above information is assigned, a high-precision map containing simulated roads can be generated.
[0037] Load high-precision simulation maps on the VTD simulation software, build simulation scenarios, and test the simulation scenarios by running VTD.
[0038] In this embodiment, by converting the GPS data of the trajectory points into ground coordinates, fitting the simulated road trajectories to the ground coordinate points, and refining the trajectory points, the refined trajectory points are written into the opendrive file to generate a high-precision simulation map that is highly consistent with the real road. By building a simulation scene, it is loaded into the vtd simulation software for simulation testing, which not only achieves high-precision map simulation, but also reduces the cost of building the simulation map and ensures the simulation test effect.
[0039] It should be understood that the serial numbers of the steps in the above embodiments do not imply a sequence of execution, and the execution sequence of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present invention.
[0040] Figure 3 A schematic diagram of the structure of a high-precision simulation map construction system based on GPS provided in an embodiment of the present invention, the system comprising:
[0041] The coordinate conversion module 310 is used to obtain the GPS location of the collection vehicle track point and convert the GPS location to the ground coordinate system;
[0042] The road fitting module 320 is used to obtain adjacent track points, calculate and determine the lane track type and slope change according to the coordinates of the adjacent track points in the ground coordinate system, and increase the track point density at equal intervals;
[0043] Specifically, three adjacent trajectory points are obtained, and according to the slopes of two adjacent trajectory points, it is determined whether the three trajectory points form a straight line;
[0044] If the three trajectory points do not form a straight line, the three trajectory points are determined to form a curve, and the curvature radius is calculated according to the coordinates of the three trajectory points;
[0045] When the levels of the three track points are inconsistent, the track points are judged to be uphill or downhill according to the changes in the levels of the three track points.
[0046] Wherein, new trajectory points are added at a predetermined distance between adjacent trajectory points, and the coordinates of the new trajectory points are calculated.
[0047] The map generation module 330 is used to input the coordinates of the track points into the OpenDrive file to generate a simulation map, and load the simulation map to perform simulation scenario testing.
[0048] Specifically, the coordinates of the trajectory points and the ramp coordinates are written into the OpenDrive file in sequence, and the road parameter values are set to obtain a high-precision simulation map.
[0049] Those skilled in the art can clearly understand that for the convenience and brevity of description, the specific working process of the above-described system and module can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.
[0050] Figure 4 1 is a schematic diagram of the structure of an electronic device provided by an embodiment of the present invention. The electronic device is used to construct a high-precision simulation map. Figure 4 As shown, the electronic device 4 of this embodiment includes: a memory 410, a processor 420 and a system bus 430, wherein the memory 410 includes an executable program 4101 stored thereon, and those skilled in the art can understand that Figure 4 The electronic device structure shown in the figure does not constitute a limitation of the electronic device, and may include more or less components than shown in the figure, or combine certain components, or arrange the components differently.
[0051] Combine the following Figure 4 A detailed introduction to the various components of electronic equipment:
[0052] The memory 410 can be used to store software programs and modules, and the processor 420 executes various functional applications and data processing of the electronic device by running the software programs and modules stored in the memory 410. The memory 410 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc.; the data storage area may store data created according to the use of the electronic device (such as cache data), etc. In addition, the memory 410 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other volatile solid-state storage devices.
[0053] The memory 410 includes an executable program 4101 of a network request method, and the executable program 4101 can be divided into one or more modules / units, which are stored in the memory 410 and executed by the processor 420 to perform high-precision map simulation, etc. The one or more modules / units can be a series of computer program instruction segments that can complete specific functions, and the instruction segments are used to describe the execution process of the executable program 4101 in the electronic device 4. For example, the executable program 4101 can be divided into functional modules such as a coordinate conversion module, a road fitting module, and a map generation module.
[0054] The processor 420 is the control center of the electronic device. It uses various interfaces and lines to connect various parts of the entire electronic device. It executes various functions of the electronic device and processes data by running or executing software programs and / or modules stored in the memory 410, and calling data stored in the memory 410, so as to monitor the overall status of the electronic device. Optionally, the processor 420 may include one or more processing units; preferably, the processor 420 may integrate an application processor and a modem processor, wherein the application processor mainly processes the operating system, application programs, etc., and the modem processor mainly processes wireless communications. It is understandable that the above-mentioned modem processor may not be integrated into the processor 420.
[0055] The system bus 430 is used to connect the various functional components inside the computer, and can transmit data information, address information, and control information. Its types can be, for example, PCI bus, ISA bus, CAN bus, etc. The instructions of the processor 420 are transmitted to the memory 410 through the bus, and the memory 410 feeds back data to the processor 420. The system bus 430 is responsible for the data and instruction exchange between the processor 420 and the memory 410. Of course, the system bus 430 can also be connected to other devices, such as network interfaces, display devices, etc.
[0056] In the embodiment of the present invention, the executable program executed by the processor 420 included in the electronic device includes:
[0057] Get the GPS location of the collection vehicle's track points and convert the GPS location to the ground coordinate system;
[0058] Obtain adjacent track points, calculate and determine lane track type and slope change based on the coordinates of the adjacent track points in the ground coordinate system, and increase the track point density at equal intervals;
[0059] The coordinates of the trajectory points are input into the OpenDrive file to generate a simulation map, the simulation map is loaded and a simulation scenario test is performed.
[0060] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and modules described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0061] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0062] As described above, the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features thereof may be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for constructing a high-precision simulation map based on GPS, characterized in that: include: Get the GPS location of the collection vehicle's track points and convert the GPS location to the ground coordinate system; Obtain adjacent track points, calculate and determine lane track type and slope change based on the coordinates of the adjacent track points in the ground coordinate system, and increase the track point density at equal intervals; The coordinates of the trajectory points are input into the OpenDrive file to generate a simulation map, the simulation map is loaded and a simulation scenario test is performed.
2. The method according to claim 1, characterized in that: The step of obtaining adjacent track points and calculating and determining the lane track type and slope change according to the coordinates of the adjacent track points in the ground coordinate system includes: Get three adjacent trajectory points, and determine whether the three trajectory points form a straight line based on the slopes of two adjacent trajectory points; If the three trajectory points do not form a straight line, the three trajectory points are determined to form a curve, and the curvature radius is calculated according to the coordinates of the three trajectory points; When the levels of the three track points are inconsistent, the track points are judged to be uphill or downhill according to the changes in the levels of the three track points.
3. The method according to claim 1, characterized in that The equidistant increase in trajectory point density includes: New trajectory points are added at a predetermined distance between adjacent trajectory points, and the coordinates of the new trajectory points are calculated.
4. The method according to claim 1, characterized in that: The step of inputting the coordinates of the track points into the OpenDrive file to generate a simulation map includes: The trajectory point coordinates and ramp coordinates are written into the OpenDrive file in turn, and the road parameter values are set to obtain a high-precision simulation map.
5. A high-precision simulation map construction system based on GPS, characterized in that: include: Coordinate conversion module, used to obtain the GPS location of the collection vehicle trajectory point and convert the GPS location to the ground coordinate system; The road fitting module is used to obtain adjacent trajectory points, calculate and determine the lane trajectory type and slope change according to the coordinates of the adjacent trajectory points in the ground coordinate system, and increase the density of trajectory points at equal intervals; The map generation module is used to input the coordinates of the track points into the OpenDrive file to generate a simulation map, and load the simulation map to perform simulation scenario testing.
6. The system according to claim 5, characterized in that The step of obtaining adjacent track points and calculating and determining the lane track type and slope change according to the coordinates of the adjacent track points in the ground coordinate system includes: Get three adjacent trajectory points, and determine whether the three trajectory points form a straight line based on the slopes of two adjacent trajectory points; If the three trajectory points do not form a straight line, the three trajectory points are determined to form a curve, and the curvature radius is calculated according to the coordinates of the three trajectory points; When the levels of the three track points are inconsistent, the track points are judged to be uphill or downhill according to the changes in the levels of the three track points.
7. The system according to claim 5, characterized in that The equidistant increase in trajectory point density includes: New trajectory points are added at a predetermined distance between adjacent trajectory points, and the coordinates of the new trajectory points are calculated.
8. The system according to claim 5, characterized in that The step of inputting the coordinates of the track points into the OpenDrive file to generate a simulation map includes: The trajectory point coordinates and ramp coordinates are written into the OpenDrive file in turn, and the road parameter values are set to obtain a high-precision simulation map.
9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of a method for constructing a high-precision simulated map based on GPS as described in any one of claims 1 to 4 are implemented.
10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed, the steps of a method for constructing a high-precision simulated map based on GPS as described in any one of claims 1 to 4 are implemented.
