A method and system for analyzing a simulation map
By analyzing and discretizing the structure data of the vehicle-mounted high-precision map files, the data mismatch and loss of high-precision maps are solved when converting them into simulated maps, and the conversion efficiency and free configuration of the simulation test environment are improved.
Patent Information
- Application Number
- CN202310481884.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-04-28
- Publication Date
- 2025-08-22
- Estimated Expiration
- 2043-04-28
AI Technical Summary
In the prior art, high-precision maps have problems of data mismatch and loss when converted into simulation maps, and the conversion process is cumbersome, resulting in low free configuration of the simulation test environment.
By obtaining the on-board high-precision map file and parsing it into structure data, performing discrete processing, obtaining discrete map data, and converting the vehicle coordinate information into discrete data, and finally converting it into structure data to achieve one-to-one matching.
It solves the problem of data mismatch and loss when converting high-precision maps into simulated maps, and improves the efficiency of map conversion and the free configuration capability of the simulation test environment.
Smart Images

Figure CN116521808B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of autonomous driving simulation testing, and in particular to a simulation map parsing method system. Background Art
[0002] With the development and refinement of related fields of high-precision maps for autonomous driving, the current simulation test environment has a demand for more freedom in high-precision maps. However, the mainstream vehicle-side high-precision maps are basically in the hands of high-precision map providers (such as AutoNavi, Baidu, NavInfo, etc.), and contain some customized content and privatized protocols. As a result, the simulation test environment has a strong dependence on the high-precision maps used when setting up, and the degree of free configuration is relatively low.
[0003] The industry's most commonly used high-precision map data format for setting up simulation test environments is OpenDrive, an open-source map format that can be created and edited manually. However, autonomous driving algorithms typically use vehicle-based high-precision map data as input. Existing technical approaches involve developing a map format conversion tool to convert and match vehicle-based high-precision map data to OpenDrive data for simulation. Using this method, the algorithm under test directly accesses the map constructed using the vehicle-based high-precision map data, while other simulated virtual vehicles access the matching OpenDrive map data. However, because OpenDrive represents an abstract map, particularly curve processing using cubic polynomial fitting, while vehicle-based high-precision maps represent lanes as discrete points, a one-to-one match between the OpenDrive high-precision map data used in simulation and the vehicle-based high-precision map data is not possible. This results in the test vehicle and other simulated virtual vehicles being in different worlds, resulting in inaccurate vehicle position matching and significant information loss. Furthermore, converting between different map formats is cumbersome, making this toolchain highly algorithm-dependent.
[0004] Therefore, a new map parsing solution is needed to solve the above problems. Summary of the Invention
[0005] One purpose of the present invention is to provide a simulation map parsing method system to solve the problem of data mismatch and data loss when converting high-precision maps into simulation maps in the prior art.
[0006] A further object of the present invention is to simplify the conversion method and improve the conversion efficiency of the map.
[0007] In particular, the present invention provides a method for parsing a simulated map, comprising the following steps:
[0008] Obtaining an onboard high-precision map file and the current coordinate information of the vehicle, parsing the onboard high-precision map file into structured data, and obtaining the current road information of the vehicle based on the coordinate information;
[0009] performing discretization processing on the structure data to obtain discretized map data;
[0010] acquiring, according to the current road information of the vehicle, first discrete data corresponding to the current road information in the discretized map data;
[0011] First structural data of the current road information in the structural data is obtained according to the first discrete data, and the first structural data is transmitted to a simulation model.
[0012] Furthermore, the discretization processing of the structure data to obtain discretized map data includes:
[0013] Acquire geometric information and text information of the map file in the structure data;
[0014] Calculating the map coordinates of the lane centerline and the road data based on the geometric information and the text information;
[0015] The map coordinates and the road data are integrated into a preset structure to obtain discretized map data.
[0016] Furthermore, the step of obtaining the current road information of the vehicle according to the coordinate information further includes:
[0017] The current coordinate information of the vehicle is obtained, and the current coordinate information is compared with the coordinate information in the discretized map data to find the coordinates of the map waypoint closest to the current coordinate information of the vehicle.
[0018] Furthermore, the step of obtaining the current road information of the vehicle according to the coordinate information further includes:
[0019] Obtaining the starting position information of the road according to the map waypoint coordinates;
[0020] According to the starting position information, the vehicle moves a preset distance along the extension direction of the road based on the global planning path, and takes the moved position as the starting point to provide the lane information according to the global planning path.
[0021] Furthermore, the lane information is arranged in the order of the left lane of the vehicle, the lane where the vehicle is located, and the right lane of the vehicle.
[0022] Furthermore, the road information includes the current road name of the vehicle and the current lane position of the vehicle.
[0023] Furthermore, the parsing method is run in a robot operating system operating environment.
[0024] The present invention also discloses a simulation map analysis system, including a analysis device, the analysis device including a memory and a processor, the memory storing a control program, and the control program is used to implement the above-mentioned simulation map analysis method when executed by the processor.
[0025] The present invention obtains a vehicle-mounted high-precision map file, parses the vehicle-mounted high-precision map file into structured data, and then discretizes the structured data to obtain discretized map data; then obtains the vehicle's coordinate information, and converts the coordinate information into first discrete data, and then converts the first discrete data into structured data, so that the high-precision map file data can finally be converted into structured data one-to-one, thereby solving the problem of data mismatch and data loss in the prior art when the high-precision map is converted into a simulation map.
[0026] Furthermore, the present invention can directly run the simulation environment and expand the degree of freedom of the simulation scene, thereby improving the efficiency of map conversion.
[0027] Based on the following detailed description of specific embodiments of the present invention in conjunction with the accompanying drawings, those skilled in the art will become more aware of the above and other objects, advantages and features of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] Hereinafter, some specific embodiments of the present invention will be described in detail in an exemplary and non-limiting manner with reference to the accompanying drawings. The same reference numerals in the accompanying drawings indicate the same or similar components or parts. It should be understood by those skilled in the art that these drawings are not necessarily drawn to scale. In the accompanying drawings:
[0029] Figure 1 is a first flow chart of a parsing method according to one embodiment of the present invention;
[0030] Figure 2 is a second flow chart of a parsing method according to one embodiment of the present invention;
[0031] Figure 3 is a third flow chart of the parsing method according to an embodiment of the present invention. DETAILED DESCRIPTION
[0032] It should be noted that the logic and / or steps represented in the flowchart or described in other ways herein, for example, can be considered as a sequenced list of executable instructions for implementing logical functions, and can be specifically implemented in any computer-readable medium for use by an instruction execution system, device or equipment (such as a computer-based system, a system including a processor or other system that can fetch instructions from an instruction execution system, device or equipment and execute instructions), or used in combination with these instruction execution systems, devices or equipment.
[0033] For the purposes of the description of this embodiment, a "computer-readable medium" can be any device that can contain, store, communicate, propagate, or transmit a program for use with an instruction execution system, device, or apparatus, or in conjunction with such instruction execution systems, devices, or apparatus. More specific examples (a non-exhaustive list) of computer-readable media include the following: an electrical connection having one or more wires (electronic devices), a portable computer disk cartridge (magnetic devices), a random access memory (RAM), a read-only memory (ROM), an erasable and editable read-only memory (EPROM or flash memory), a fiber optic device, and a portable compact disc read-only memory (CDROM). In addition, the computer-readable medium can even be paper or other suitable medium on which the program can be printed, since the program can be obtained electronically, for example, by optically scanning the paper or other medium, followed by editing, deciphering, or processing in other suitable ways as necessary, and then stored in a computer memory.
[0034] It should be understood that various parts of the present invention can be implemented using hardware, software, firmware, or a combination thereof. In the above-described embodiments, multiple steps or methods can be implemented using software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented using hardware, as in another embodiment, any one of the following technologies known in the art or a combination thereof can be used: a discrete logic circuit having a logic gate circuit for implementing a logic function on a data signal, an application-specific integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.
[0035] Figure 1 is a first flow chart of a parsing method according to an embodiment of the present invention. Figure 3 is a third flow chart of a parsing method according to an embodiment of the present invention. Figure 1 and Figure 3 As shown, the analysis method of the simulation map includes the following steps:
[0036] S1. Obtain the vehicle's high-precision map file and the vehicle's current coordinate information, parse the vehicle's high-precision map file into structured data, and obtain the vehicle's current road information based on the coordinate information;
[0037] S2. Discretize the structure data to obtain discretized map data;
[0038] S3. Acquire first discrete data corresponding to the current road information in the discretized map data according to the current road information of the vehicle;
[0039] S4. Obtain first structural data of the current road information in the structural data according to the first discrete data, and transmit the first structural data to the simulation model.
[0040] Specifically, first obtain the vehicle-mounted high-precision map file, read the high-precision map file line by line, convert the high-precision map file into corresponding data according to the keyword, and store the data in a structure to form structure data.
[0041] Next, we retrieve specific lane information for each road from the structured data. Using the road geometry and lane width data, we use a coordinate offset and rotation algorithm to calculate the map coordinates and associated data for the desired point on the lane centerline. By integrating this discrete point data into the pre-set structure, we obtain discretized map data.
[0042] After obtaining the discretized map data, the current vehicle coordinate information can be projected into the discretized map data. The vehicle's current coordinate road information is compared with the information in the discretized map data to obtain the first discrete data corresponding to the vehicle's current road information within the discretized map data. This first discrete data is then integrated and packaged into a structure to obtain first structured data. This first structured data is then sent to the simulation model for simulation testing.
[0043] In this embodiment, a vehicle-mounted high-precision map file is obtained and parsed into structured data, and then the structured data is discretized to obtain discretized map data; then the coordinate information of the vehicle is obtained and converted into first discrete data, and the first discrete data is converted into structured data, so that the high-precision map file data can finally be converted into structured data one-to-one, thereby solving the problem of data mismatch and data loss when the high-precision map is converted into a simulation map in the prior art.
[0044] Figure 2 is a second flow chart of the parsing method according to one embodiment of the present invention. In a further embodiment, Figure 2 As shown, the step of discretizing the structure data to obtain discretized map data also includes:
[0045] S20, obtaining geometric information and text information of the map file in the structure data;
[0046] S21. Calculate the map coordinates of the lane centerline and road data based on the geometric information and the text information;
[0047] S22. Integrate the map coordinates and road data into a preset structure to obtain discretized map data.
[0048] Specifically, the detailed information for each lane on each road is obtained from the structured data. Using the road geometry and lane width data, coordinate offset and rotation operations are used to calculate the map coordinates and related data (including XYZ coordinates, the slope of the tangent line at the point, the curvature of the corresponding curve, and the distance along the lane axis) of the desired point on the lane centerline. By integrating this discrete point data into the pre-set structure, the discretized map data is obtained.
[0049] In this embodiment, by discretizing the structure data, the vehicle's location information can be more accurately matched with the high-precision map file after the vehicle's coordinate information is subsequently acquired.
[0050] In a specific embodiment, the current coordinate information of the vehicle is compared with the coordinate information in the discretized map data to find the coordinates of the map waypoint closest to the current coordinate information of the vehicle, thereby obtaining the first discrete data corresponding to the current road information of the vehicle.
[0051] After obtaining the first discrete data, the first discrete data must be converted into first structured data. After obtaining the vehicle's coordinate information, the vehicle's current road information can be obtained. This road information includes the vehicle's current road name (road ID) and lane position (lane position ID). After obtaining the vehicle's road information, the vehicle's starting position can be obtained. Based on this starting position information, the vehicle moves a preset distance along the road's extension direction, taking the globally planned path as a reference. Lane information is provided based on the globally planned path, starting from the moved position.
[0052] In addition, the lane information is arranged in the order of the left lane of the own vehicle, the lane where the own vehicle is located, and the right lane of the own vehicle, and then the lane information is calculated and integrated and packaged into a structure to form a complete first structure data.
[0053] Specifically, after obtaining the discretized map data, the vehicle's current coordinates are obtained from the vehicle computer system. The vehicle's current coordinates (X, Y, Heading) are compared with the coordinates of the discrete waypoints on the map to find the coordinates of the map waypoint closest to the vehicle's current coordinates. The road corresponding to this waypoint coordinate is the first discrete data corresponding to the vehicle's road information.
[0054] When converting the first discrete data into the first structured data, after obtaining the vehicle's coordinate information, the vehicle's current road information can be obtained, and the road information includes the vehicle's current road name (road ID) and the vehicle's current lane position (lane position ID). After obtaining the vehicle's road information, the vehicle's starting position information can be obtained. Then, based on the starting position information, the vehicle moves a preset distance along the extension direction of the road with the global planned path as a reference, and uses the moved position as the starting point to provide lane information according to the global planned path.
[0055] Among them, the lane information is arranged in the order of the left lane of the own vehicle, the lane where the own vehicle is located, and the right lane of the own vehicle, and the preset distance can be adjusted according to different vehicle models and sizes, so as to calculate and integrate the lane information and package it in a structure to form a complete first structure data.
[0056] In this embodiment, after obtaining the road information of the vehicle, the starting position information of the road can be obtained. Then, based on the starting position information, the preset distance is moved along the extension direction of the road with the global planning path as the reference, and the lane information is provided according to the global planning path with the moved position as the starting point, so as to further obtain the lane information of the vehicle. By moving the preset distance, the amount of calculation can be further reduced, thereby improving the conversion efficiency of the map.
[0057] It's important to note that the simulation map parsing method described in this article operates within the Robot Operating System (ROS) environment. It reads high-precision map files in the OpenDrive format and provides the simulation algorithm with lane information about the vehicle's surroundings via a ROS topic, structured according to the / worldmodel / processed_map data structure. This method can also be applied to other environments with simple adjustments.
[0058] The present invention also discloses a simulation map parsing system, comprising a parsing device, the parsing device comprising a memory and a processor, wherein the memory stores a control program, which, when executed by the processor, is used to implement the above-mentioned simulation map parsing method.
[0059] At this point, those skilled in the art will recognize that, although a number of exemplary embodiments of the present invention have been shown and described in detail herein, many other variations or modifications consistent with the principles of the present invention may be directly determined or derived from the disclosure of the present invention without departing from the spirit and scope of the present invention. Therefore, the scope of the present invention should be understood and deemed to cover all such other variations or modifications.
Claims
1. A method for analyzing a simulation map, characterized in that: The following steps are involved: Obtaining an onboard high-precision map file and the current coordinate information of the vehicle, parsing the onboard high-precision map file into structured data, and obtaining the current road information of the vehicle based on the coordinate information; performing discretization processing on the structure data to obtain discretized map data; acquiring, according to the current road information of the vehicle, first discrete data corresponding to the current road information in the discretized map data; Obtaining first structural data of the current road information in the structural data according to the first discrete data, and transmitting the first structural data to a simulation model; The parsing of the vehicle-mounted high-precision map file into structured data includes: obtaining the vehicle-mounted high-precision map file, reading the high-precision map file line by line, converting the high-precision map file into corresponding data according to keywords, and storing the data in a structure to form structured data; The discretization of the structured data to obtain discretized map data includes: obtaining specific information of each lane under each road in the structured data, using the road geometry information and lane width data therein to calculate the map coordinates and related data of the required points on the lane centerline through a coordinate offset rotation algorithm, and integrating the discrete point data into a preset structure to obtain the discretized map data; The obtaining, based on the current road information of the vehicle, first discrete data corresponding to the current road information in the discretized map data includes: projecting the obtained current coordinate information of the vehicle into the discretized map data, and comparing the vehicle's current coordinate road information with information in the discretized map data to obtain the first discrete data corresponding to the current road information of the vehicle in the discretized map data.
2. The analysis method according to claim 1, wherein: The step of obtaining the current road information of the vehicle according to the coordinate information further includes: The current coordinate information of the vehicle is obtained, and the current coordinate information is compared with the coordinate information in the discretized map data to find the coordinates of the map waypoint closest to the current coordinate information of the vehicle.
3. The analysis method according to claim 2, characterized in that The step of obtaining the current road information of the vehicle according to the coordinate information further includes: Obtaining the starting position information of the road according to the map waypoint coordinates; According to the starting position information, the vehicle moves a preset distance along the extension direction of the road based on the global planning path, and takes the moved position as the starting point to provide the lane information according to the global planning path.
4. The analysis method according to claim 3, wherein: The lane information is arranged in the order of the left lane of the vehicle, the lane where the vehicle is located, and the right lane of the vehicle.
5. The analysis method according to claim 4, characterized in that The road information includes the current road name of the vehicle and the current lane position of the vehicle.
6. The analysis method according to claim 1, wherein: The parsing method is run in a robot operating system running environment.
7. A simulation map analysis system, characterized in that: The method comprises a parsing device, the parsing device comprising a memory and a processor, the memory storing a control program, and the control program being used to implement the parsing method of the simulation map according to any one of claims 1 to 6 when executed by the processor.
Citation Information
Patent Citations
Test evaluation method and device for high-precision map, vehicle and medium
CN114440929A
Simulation test method and device of controller, electronic equipment and storage medium
CN115327950A