Road modeling method and system, terminal equipment and storage medium
By using open-source map data and automated processes, combined with coordinate projection and semantic mapping technologies, the high cost and low efficiency of road modeling in autonomous driving simulation platforms have been solved, enabling the generation of high-precision simulation standard road data and supporting the safety verification of autonomous driving algorithms.
Patent Information
- Application Number
- CN202511578282.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-31
- Publication Date
- 2026-02-24
AI Technical Summary
Existing technologies for road scene modeling in autonomous driving simulation platforms suffer from high costs, low efficiency, and insufficient accuracy. In particular, manual drawing is time-consuming and labor-intensive, LiDAR equipment is expensive and data processing is complex, and existing map data conversion cannot fully retain key information.
By combining open-source map data with automated processes, and through coordinate projection transformation algorithms and road semantic mapping rule bases, the system achieves automatic conversion and completion from raw map data to simulation standard data, including accurate completion of lanes, curvature, elevation, and traffic rules, generating high-precision simulation standard road data.
It significantly reduces hardware and data costs, shortens the modeling cycle, improves the accuracy and reliability of road models, supports the safety verification of autonomous driving algorithms, and provides a fully automated modeling solution.
Smart Images

Figure CN121564252A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of road modeling, and more particularly to a road modeling method, system, terminal device, and storage medium. Background Technology
[0002] With the rapid development of autonomous driving technology, the verification of its safety and reliability has become a core challenge for the industry. Due to the high cost, long cycle, limited scenario coverage, and safety risks of real vehicle testing, virtual testing based on simulation platforms has become a key means of iterating autonomous driving algorithms and verifying their functions.
[0003] Traditional road scene modeling methods relying on simulation platforms primarily depend on manual drawing or reconstruction using LiDAR scanning data. Manual drawing is not only time-consuming and labor-intensive (building a 100-kilometer urban road scene can take weeks or even months), but it is also prone to insufficient scene accuracy due to human error. While LiDAR scanning can acquire high-precision point cloud data, the equipment is expensive (a single set costs over one million yuan), data processing is complex, and it is limited by the collection range, making it difficult to quickly cover large-scale areas. Furthermore, when converting existing map data into simulation format, key information cannot be fully preserved, resulting in insufficient accuracy and further limiting the reliability of road modeling. Summary of the Invention
[0004] This invention provides a road modeling method, system, terminal device, and storage medium, which can improve the accuracy and reliability of road modeling.
[0005] This invention provides a road modeling method, comprising:
[0006] Obtain the original street map data of the road area to be modeled, and determine the original road data based on the original street map data;
[0007] Obtain the original coordinate data and original attribute data of the original road data;
[0008] Based on the preset coordinate projection transformation algorithm, the original coordinate data, and the preset reference points in the road area to be modeled, the current coordinate data is obtained;
[0009] Based on the preset road semantic mapping rule base and the original attribute data, the current attribute data is obtained;
[0010] Based on the current coordinate data and the current attribute data, the current road data is obtained;
[0011] Determine the defective data of the current road data, and select a target completion algorithm from the preset candidate completion algorithms based on the defective data;
[0012] Based on the target completion algorithm, defect completion is performed on the current road data to obtain the target road data;
[0013] Based on the target road data, simulation standard road data is constructed so that the simulation model can obtain the target road model of the road area to be modeled based on the simulation standard road data.
[0014] In the above solution, open-source raw street map data is used as input, eliminating the need for vehicle-mounted LiDAR data collection, thus significantly reducing hardware and data costs. Simultaneously, automated processes replace manual drawing, significantly shortening the modeling cycle and efficiently meeting the needs of constructing large-scale road scenes. Based on a preset coordinate projection transformation algorithm and reference points of the road area to be modeled, the original coordinate data of the raw road data in the geographic coordinate system is accurately transformed to the simulated local inertia coordinate system, resulting in high-precision current coordinate data. This solves the problem of insufficient accuracy in traditional transformations and ensures that the road geometry is consistent with the real scene. Relying on a preset road semantic mapping rule library, the original attribute data of the raw road data is transformed into a system containing various key attributes. The system uses current attribute data that conforms to the simulation model format and contains relevant information. Based on the current coordinate data and the current attribute data, it obtains current road data with more comprehensive data. Then, it uses a target completion algorithm to repair the defective data in the current road data to obtain target road data, further improving the completeness and reliability of the target road data. This breaks through the compatibility barrier between the original street map data format and the simulation standard road data. The final generated simulation standard road data can be directly used to build the target road model without additional manual repair. This achieves full automation from data input to model output, improving the efficiency, accuracy and reliability of target road model construction, and providing reliable support for the safety verification of autonomous driving algorithms.
[0015] Furthermore, the coordinate projection transformation algorithm includes an Earth coordinate transformation algorithm and a local coordinate transformation algorithm. The process of obtaining current coordinate data based on a preset coordinate projection transformation algorithm, the original coordinate data, and preset reference points in the road area to be modeled includes:
[0016] Based on the Earth coordinate transformation algorithm and the original road data, Earth coordinate road data in the Earth's central rectangular coordinate system is obtained;
[0017] Using the reference point as the origin, the current coordinate data is obtained based on the local coordinate transformation algorithm and the Earth coordinate road data.
[0018] In the above scheme, two coordinate system transformations are performed through the Earth coordinate transformation algorithm and the local coordinate transformation algorithm. First, the original road data is converted into Earth-centered rectangular coordinate system data, and then local coordinate data is generated with a preset reference point as the origin. This achieves accurate mapping from global geographic coordinates to simulation local coordinates, solves the conversion compatibility problem between different coordinate systems, and provides a unified coordinate benchmark for subsequent road modeling.
[0019] Furthermore, the original coordinate data includes the original road latitude, original road longitude, and original road elevation. The process of obtaining Earth coordinate road data in the Earth's central rectangular coordinate system based on the Earth coordinate transformation algorithm and the original road data includes:
[0020] Obtain the Earth's circumpolar curvature radius;
[0021] Based on the radius of curvature of the zonal circle, the original road latitude, the original road longitude, and the original road elevation, the Earth coordinate road data is obtained.
[0022] In the above scheme, by introducing the Earth's circumpolar curvature radius parameter and combining the original road latitude, original road longitude and original road elevation, the Earth coordinate road data in the Earth's central rectangular coordinate system is calculated. This refines the influence of Earth's curvature on coordinate transformation and further improves the calculation accuracy of Earth coordinate road data, providing accurate basic data for subsequent local coordinate transformation.
[0023] Further, the target completion algorithm includes lane completion algorithm, curvature completion algorithm, elevation completion algorithm, and traffic rule completion algorithm. The current road data includes current coordinate data and current attribute data. The current coordinate data includes current road latitude and longitude and current road elevation. The current attribute data includes road type, current number of lanes, and current lane traffic data. The step of performing defect completion on the current road data based on the target completion algorithm to obtain target road data includes:
[0024] Based on the lane completion algorithm, the current road latitude and longitude, the road type, and the current number of lanes, the target number of lanes is obtained;
[0025] Based on the curvature completion algorithm and the current road latitude and longitude, the target lane curvature data is obtained;
[0026] Based on the elevation completion algorithm, the current road latitude and longitude, and the current road elevation, the target lane elevation data is obtained;
[0027] Based on the traffic rule completion algorithm, the current road latitude and longitude, and the current lane traffic data, the target lane traffic data is obtained;
[0028] The target road data is obtained based on the target number of lanes, the target lane curvature data, the target lane elevation data, and the target lane traffic data.
[0029] In the above solution, to address potential deficiencies in the current road data such as lanes, curvature, elevation, and traffic rules, a corresponding target completion algorithm is used to generate the target number of lanes, the target lane curvature data, the target lane elevation data, and the target lane traffic data, respectively, thereby achieving comprehensive completion of the road data and ensuring the integrity and accuracy of the target road data.
[0030] Further, obtaining the target number of lanes based on the lane completion algorithm, the current road latitude and longitude, the road type, and the current number of lanes includes:
[0031] The target type is determined from the road types based on the current road latitude and longitude, and the number of reference lanes is determined based on the target type;
[0032] When the number of reference lanes is different from the number of current lanes, the number of current lanes is updated based on the number of reference lanes to obtain the target number of lanes.
[0033] In the above solution, the target type of the road and the corresponding reference number of lanes are determined based on the current road latitude and longitude. The current number of lanes is completed by comparing and updating the reference number of lanes with the current number of lanes, thus solving the problem of missing or incorrect lane numbers in the original road data.
[0034] Further, obtaining the target lane curvature data based on the curvature completion algorithm and the current road latitude and longitude includes:
[0035] The current lane curve is obtained based on a preset road node curve fitting algorithm and the current road latitude and longitude of any three adjacent road nodes;
[0036] Based on a preset set of sampling nodes and the current lane curve, the curvature data of the target lane is obtained.
[0037] In the above scheme, the current lane curve is generated by fitting the latitude and longitude of three adjacent nodes through a road node curve fitting algorithm. Combined with the sampled node set, the curvature data of the target lane is calculated, realizing the accurate conversion from discrete nodes to continuous curvature and filling the blank nodes in the original road data with road curvature related attribute information.
[0038] Further, obtaining the target lane elevation data based on the elevation completion algorithm, the current road latitude and longitude, and the current road elevation includes:
[0039] The elevation value is obtained based on the preset digital elevation model and the current road latitude and longitude.
[0040] The slope value is obtained based on the elevation values of any two road nodes and the current road latitude and longitude.
[0041] The current road elevation is updated based on the elevation value and the slope value to obtain the target lane elevation data.
[0042] In the above scheme, the elevation value is obtained by matching latitude and longitude using a digital elevation model, and the slope value is calculated by combining adjacent nodes to update the current road elevation. This achieves refined completion of elevation data, solves the problem of missing or insufficient accuracy of original elevation information, accurately reflects the road undulation characteristics, and provides road longitudinal profile data that conforms to physical laws for simulation.
[0043] Another embodiment of the present invention also provides a road modeling system, comprising:
[0044] The first acquisition module is used to acquire the original street map data of the road area to be modeled, and to determine the original road data based on the original street map data;
[0045] The second acquisition module is used to acquire the original coordinate data and original attribute data of the original road data;
[0046] The coordinate transformation module is used to obtain the current coordinate data based on a preset coordinate projection transformation algorithm, the original coordinate data, and preset reference points in the road area to be modeled;
[0047] The mapping module is used to obtain the current attribute data based on the preset road semantic mapping rule library and the original attribute data;
[0048] The module is used to obtain the current road data based on the current coordinate data and the current attribute data;
[0049] The selection module is used to determine the defect data of the current road data and select a target completion algorithm from the preset candidate completion algorithms based on the defect data;
[0050] The completion module is used to complete the defects in the current road data based on the target completion algorithm to obtain the target road data;
[0051] The road model generation module is used to construct simulation standard road data based on the target road data, so that the simulation model can obtain the target road model of the road area to be modeled based on the simulation standard road data.
[0052] Another embodiment of the present invention provides a terminal device, including: a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, wherein when the processor executes the computer program, it implements the steps of a road modeling method as described in the present invention.
[0053] Another embodiment of the present invention also provides a computer-readable storage medium item, including: a stored computer program, which, when the computer program is running, controls the device where the computer-readable storage medium is located to perform steps of a road modeling method of the present invention. Attached Figure Description
[0054] To more clearly illustrate the technical solution of this application, the drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.
[0055] Figure 1 This is a flowchart illustrating a road modeling method provided in an embodiment of the present invention;
[0056] Figure 2 This is a schematic diagram of the structure of a road modeling system provided in an embodiment of the present invention. Detailed Implementation
[0057] To make the objectives, technical solutions, and advantages of this application clearer, the technical solutions of this application will be clearly and completely described below with reference to the accompanying drawings of the embodiments. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0058] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application pertains; the terminology used herein is for the purpose of describing particular embodiments only and is not intended to limit the application; the terms “comprising” and “having”, and any variations thereof, in the specification, claims, and foregoing description of the drawings are intended to cover non-exclusive inclusion.
[0059] In the description of the embodiments of this application, technical terms such as "first" and "second" are used only to distinguish different objects and should not be construed as indicating or implying relative importance or implicitly specifying the number, specific order, or primary and secondary relationship of the indicated technical features. In the description of the embodiments of this application, "multiple" means two or more, unless otherwise explicitly defined.
[0060] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of this application. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.
[0061] In the description of the embodiments in this application, the term "and / or" is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, and B existing alone. Additionally, the character " / " in this document generally indicates that the preceding and following related objects have an "or" relationship.
[0062] In the description of the embodiments of this application, the term "multiple" refers to two or more (including two), similarly, "multiple sets" refers to two or more (including two sets), and "multiple pieces" refers to two or more (including two pieces).
[0063] In the description of the embodiments of this application, unless otherwise expressly specified and limited, technical terms such as "installation," "connection," "joining," and "fixing" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral part; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; they can refer to the internal communication of two components or the interaction between two components. For those skilled in the art, the specific meaning of the above terms in the embodiments of this application can be understood according to the specific circumstances.
[0064] See Figure 1 To improve the accuracy and reliability of road modeling, an embodiment of the present invention provides a road modeling method, comprising:
[0065] Step S1: Obtain the original street map data of the road area to be modeled, and determine the original road data based on the original street map data;
[0066] Step S2: Obtain the original coordinate data and original attribute data of the original road data;
[0067] Step S3: Based on the preset coordinate projection transformation algorithm, the original coordinate data, and the preset reference points in the road area to be modeled, obtain the current coordinate data;
[0068] Step S4: Based on the preset road semantic mapping rule base and the original attribute data, obtain the current attribute data;
[0069] Step S5: Obtain the current road data based on the current coordinate data and current attribute data;
[0070] Step S6: Determine the defect data of the current road data, and select the target completion algorithm from the preset candidate completion algorithms based on the defect data;
[0071] Step S7: Based on the target completion algorithm, perform defect completion on the current road data to obtain the target road data;
[0072] Step S8: Construct simulation standard road data based on the target road data, so that the simulation model can obtain the target road model of the road area to be modeled based on the simulation standard road data.
[0073] In the above solution, open-source raw street map data is used as input, eliminating the need for vehicle-mounted LiDAR data collection, thus significantly reducing hardware and data costs. Simultaneously, automated processes replace manual drawing, significantly shortening the modeling cycle and efficiently meeting the needs of constructing large-scale road scenes. Based on a preset coordinate projection transformation algorithm and reference points of the road area to be modeled, the original coordinate data of the raw road data in the geographic coordinate system is accurately transformed to the simulated local inertia coordinate system, resulting in high-precision current coordinate data. This solves the problem of insufficient accuracy in traditional transformations and ensures that the road geometry is consistent with the real scene. Relying on a preset road semantic mapping rule library, the original attribute data of the raw road data is transformed into a system containing various key attributes. The system uses current attribute data that conforms to the simulation model format and contains relevant information. Based on the current coordinate data and the current attribute data, it obtains current road data with more comprehensive data. Then, it uses a target completion algorithm to repair the defective data in the current road data to obtain target road data, further improving the completeness and reliability of the target road data. This breaks through the compatibility barrier between the original street map data format and the simulation standard road data. The final generated simulation standard road data can be directly used to build the target road model without additional manual repair. This achieves full automation from data input to model output, improving the efficiency, accuracy and reliability of target road model construction, and providing reliable support for the safety verification of autonomous driving algorithms.
[0074] In another embodiment, the step of acquiring the original street map data of the road area to be modeled and determining the original road data based on the original street map data specifically includes:
[0075] Obtain the OpenStreeMap map (i.e., OSM map, open-source map data), select the road area to be modeled, and download the map of the area to be modeled to obtain the raw street map data. The OSM map is in OSM format. Read the raw street map data in text format, recursively traverse each attribute node, and extract the key information of node, way, and relationship as the raw road data. It is understandable that road nodes constitute road segments, and road segments constitute the road relationships.
[0076] In another embodiment, the coordinate projection transformation algorithm includes an Earth coordinate transformation algorithm and a local coordinate transformation algorithm. The process of obtaining current coordinate data based on a preset coordinate projection transformation algorithm, the original coordinate data, and preset reference points in the road area to be modeled includes:
[0077] Based on the Earth coordinate transformation algorithm and the original road data, Earth coordinate road data in the Earth's central rectangular coordinate system is obtained;
[0078] Using the reference point as the origin, the current coordinate data is obtained based on the local coordinate transformation algorithm and the Earth coordinate road data.
[0079] It should be noted that the original road data in the Earth-centered Cartesian coordinate system needs to be converted into the current coordinate data in the local coordinate system of the road area to be modeled: First, the original coordinate data is converted into precise (X,Y,Z) coordinates in the Earth-centered Cartesian coordinate system (ECEF) (i.e., Earth coordinate road data); then, through a rotation matrix, the origin of the Earth coordinate road data is translated from the Earth's center to a selected reference point in the road area to be modeled, and the entire coordinate system is rotated so that the three axes point east, north, and zenith, respectively. The resulting current coordinate data in the local coordinate system (ENU) is the x, y, z coordinate used by the nodes in the OpenDRIVE file, where the OpenDRIVE file is an xodr format file, which is the simulation standard road data adapted to the simulation model. By establishing a bidirectional nonlinear mapping model between the inertial coordinate system (a local coordinate system built with the road centerline as the reference) and the Earth-centered Cartesian coordinate system, key road attributes (such as curvature, slope, and relative positional relationships) can be accurately preserved during the conversion process, while improving the coordinate accuracy to the meter level.
[0080] In another embodiment, the original coordinate data includes the original road latitude, original road longitude, and original road elevation. The step of obtaining Earth coordinate road data in the Earth's central rectangular coordinate system based on the Earth coordinate transformation algorithm and the original road data includes:
[0081] Obtain the Earth's circumpolar curvature radius;
[0082] Based on the radius of curvature of the zonal circle, the original road latitude, the original road longitude, and the original road elevation, the Earth coordinate road data is obtained.
[0083] It should be noted that the specific process of converting the original coordinate data to the Earth-Centered Cartesian Coordinate System (ECEF) to obtain the Earth coordinate road data is as follows: For the relevant parameters of the Earth, the existing WGS-84 ellipsoid parameters are used as substitutes (major semi-axis a = 6378137m, flattening f = 1 / 298.257223563, first eccentricity e = 0.081819190842622). Based on this, the curvature radius of the primordial circle is calculated, where the primordial circle refers to the great circle perpendicular to the Earth's meridian. The original coordinate data of any node P is (Lat, Lon, h), where Lat is the original road latitude, Lon is the original road longitude, and h is the original road elevation. The reference point P0 is (Lat0, Lon0, h0).
[0084] Then the radius of curvature of the circle is Where N is the radius of curvature of the ramusoidal circle, a is the semi-major axis in the WGS-84 ellipsoid parameters, and e is the first eccentricity.
[0085] Then, based on the radius of curvature of the ramidal circle, the coordinates are converted to the ECEF coordinate system. The Earth coordinates (X, Y, Z) of any node P are as follows:
[0086] X=(N+h)cos(Lat)cos(Lon); Y=(N+h)cos(Lat)sin(Lon); Z=[N(1-e 2 )+h]sin(Lat).
[0087] Correspondingly, the coordinates (X0, Y0, Z0) of the reference point (Lat0, Lon0, h0) in the Earth's central rectangular coordinate system (ECEF) are obtained:
[0088] X0=(N+h0)cos(Lat0)cos(Lon0); Y0=(N+h0)cos(Lat0)sin(Lon0); Z0=[N(1-e2)+h0]sin(Lat0).
[0089] Furthermore, in the step of obtaining the Earth coordinate road data based on the radius of curvature of the zonal circle, the original road latitude, the original road longitude, and the original road elevation, specifically:
[0090] Using the rotation matrix R, the geocentric direction in ECEF coordinates is converted to the directions of the three axes (east, north, and zenith) in the local coordinate system (ENU). The vectors in ECEF coordinates are calculated as follows: △X = X - X0; △Y = Y - Y0; △Z = Z - Z0. With the reference point as the origin, the current coordinate data in the local coordinate system (ENU) is obtained by applying the rotation matrix R: e = -sin(Lon0)△X + cos(Lon0)△Y; n = -sin(Lat0)cos(Lon0)ΔX - sin(Lat0)sin(Lon0)△Y + cos(Lat0)ΔZ; u = cos(Lat0)cos(Lon0)△X + cos(Lat0)sin(Lon0)△Y + sin(Lat0)△Z. The x-coordinate of any node in the road area to be modeled is X_local = e (i.e., East, representing eastward); the y-coordinate is Y_local = n (i.e., North, representing northward); and the z-coordinate is Z_local = u (i.e., Up, representing zenith direction).
[0091] In another embodiment, based on a preset road semantic mapping rule base and the original attribute data, the current attribute data is obtained, specifically:
[0092] The road semantic mapping library parses raw street map data, systematically mapping the tags (i.e., raw attribute information) from the raw street map data to the current attribute data (e.g., road type, number of lanes, speed limit, etc.) in the initial simulation standard format file. It parses the road type from the raw attribute information to obtain the road type and default attributes in the current attribute information; it parses the lane direction and number of lanes from the raw attribute information to obtain the lane direction and number of lanes in the current attribute information; and it parses the intersection type and traffic rules from the raw attribute information to obtain the intersection type and traffic rules in the current attribute information. It is understood that the current road data includes the current coordinate data and the aforementioned current attribute data.
[0093] In another embodiment, the step of determining the defect data of the current road data and selecting a target completion algorithm from a preset pool of candidate completion algorithms based on the defect data specifically includes:
[0094] The current road data includes current coordinate data and current attribute data. The current coordinate data includes the current road latitude and longitude and the current road elevation. The current attribute data includes the current number of lanes and the current lane traffic data. When the current lane number is incomplete, a lane completion algorithm is selected as the target completion algorithm. When the current road curvature in the current coordinate data is incomplete, a curvature completion algorithm is selected as the target completion algorithm. It is understood that a defective current road curvature means that the discrete nodes are connected to form a broken line instead of a smooth curve. When the current road elevation is incomplete, an elevation completion algorithm is selected as the target completion algorithm. When the current lane traffic data is incomplete, a traffic rule completion algorithm is selected as the target completion algorithm.
[0095] In another embodiment, the target completion algorithm includes a lane completion algorithm, a curvature completion algorithm, an elevation completion algorithm, and a traffic rule completion algorithm. The current road data includes current coordinate data and the current attribute data. The current coordinate data includes the current road latitude and longitude and the current road elevation. The current attribute data includes road type, current number of lanes, and current lane traffic data. The step of performing defect completion on the current road data based on the target completion algorithm to obtain target road data includes:
[0096] Based on the lane completion algorithm, the current road latitude and longitude, the road type, and the current number of lanes, the target number of lanes is obtained;
[0097] Based on the curvature completion algorithm and the current road latitude and longitude, the target lane curvature data is obtained;
[0098] Based on the elevation completion algorithm, the current road latitude and longitude, and the current road elevation, the target lane elevation data is obtained;
[0099] Based on the traffic rule completion algorithm, the current road latitude and longitude, and the current lane traffic data, the target lane traffic data is obtained;
[0100] The target road data is obtained based on the target number of lanes, the target lane curvature data, the target lane elevation data, and the target lane traffic data.
[0101] It should be noted that, given the potential incompleteness or labeling discrepancies in the original street map data, this process also integrates an intelligent data completion strategy. Based on a predefined target completion algorithm, it automatically completes missing key information, obtaining target lane number, target lane curvature data, target lane elevation data, and target lane traffic data, thereby ensuring the generated road network possesses high quality and logical rationality. Finally, all processed and completed geometric information and semantic attributes are synthesized into target road data, which is in JSON format. Its core advantage lies in combining real-world road information with powerful virtual simulation capabilities. This method not only significantly improves development efficiency, reduces costs and risks, but also provides testing flexibility and scenario coverage exceeding real-world limitations, providing a crucial support environment for the training, verification, and continuous iterative optimization of autonomous driving algorithms. This is of great significance for accelerating the maturity and safe deployment of autonomous driving technology.
[0102] In another embodiment, obtaining the target number of lanes based on the lane completion algorithm, the current road latitude and longitude, the road type, and the current number of lanes includes:
[0103] The target type is determined from the road types based on the current road latitude and longitude, and the number of reference lanes is determined based on the target type;
[0104] When the number of reference lanes is different from the number of current lanes, the number of current lanes is updated based on the number of reference lanes to obtain the target number of lanes.
[0105] It should be noted that the target type is determined from the road types based on the current road latitude and longitude, and a default value is obtained from the road semantic mapping rule base: for example, the default number of reference lanes is 3 lanes for highways, 2 lanes for urban arterial roads, and 1 lane for residential roads. When the number of reference lanes is different from the current number of lanes, the current number of lanes is updated based on the reference number of lanes to obtain the target number of lanes. Furthermore, if the road width can be calculated from adjacent nodes, such as a 12-meter distance between two parallel road segments, the default lane width is 3 meters, thus determining the reference number of lanes as 4 lanes. The default number of lanes is then corrected using a geometric heuristic. Further, the geometric heuristic involves analyzing the road geometry when the original road data has no lane information. It calculates the width on both sides of the road centerline using an algorithm and attempts to generate lane lines parallel to the centerline. By analyzing the number and direction of these parallel lines, the most basic lane topology is inferred (for example, a wide road is inferred to be a two-way four-lane road).
[0106] Furthermore, current speed data correction: The current attribute data also includes geofence information. Based on road type and geofence information, the road semantic mapping rule base defines default speed limits for different countries / regions and road types (e.g., speed limit of 50 km / h in city A, speed limit of 120 km / h on highway B). The corresponding default speed limit is automatically assigned based on the current road latitude and longitude, thus obtaining the target speed data.
[0107] In another embodiment, obtaining the target lane curvature data based on the curvature completion algorithm and the current road latitude and longitude includes:
[0108] The current lane curve is obtained based on a preset road node curve fitting algorithm and the current road latitude and longitude of any three adjacent road nodes;
[0109] Based on a preset set of sampling nodes and the current lane curve, the curvature data of the target lane is obtained.
[0110] It's important to note the curvature completion process: the original road data consists of discrete nodes, which, when connected, form a harsh, broken line rather than a smooth curve. Therefore, a spline rendering algorithm (such as cubic spline curves or B-spline curves) is used to fit these original road nodes based on the current road latitude and longitude. At least three road nodes are required to generate a very smooth road reference line that closely matches the actual vehicle trajectory, serving as the current lane curve. Subsequently, a dense set of sampled nodes is pre-defined, including multiple sampled nodes, and the curvature of each sampled node is calculated. This provides the data foundation for generating the arcs and transition curves in OpenDRIVE (the file containing the simulation standard road data adapted to the simulation model).
[0111] In another embodiment, obtaining the target lane elevation data based on the elevation completion algorithm, the current road latitude and longitude, and the current road elevation includes:
[0112] The elevation value is obtained based on the preset digital elevation model and the current road latitude and longitude.
[0113] The slope value is obtained based on the elevation values of any two road nodes and the current road latitude and longitude.
[0114] The current road elevation is updated based on the elevation value and the slope value to obtain the target lane elevation data.
[0115] It should be noted that the current road elevation completion process involves accessing a Digital Elevation Model (DEM) database. This is done by matching the current road latitude and longitude of road nodes in the original road data with the DEM data, assigning a precise elevation value (Z-coordinate) to each road node. This yields the road's longitudinal profile information and calculates the road's slope. Specifically, the horizontal distance is obtained by calculating the difference between the current latitude and longitude coordinates of any two road nodes. The elevation values of these two road nodes are then obtained, resulting in the elevation data difference. The ratio of this elevation data difference to the horizontal distance is the slope. Based on these elevation and slope values, the current road elevation is updated to complete any missing elevation attributes in the original road data.
[0116] Furthermore, the step of obtaining the target lane traffic data based on the traffic rule completion algorithm, the current road latitude and longitude, and the current lane traffic data specifically includes:
[0117] Current lane traffic data includes intersection identification rules, applied traffic rules, and intelligent layout rules. Intersection identification rules identify intersections by analyzing the topological connections between road segments (ways) in the raw road data. The core of this approach is to identify multiple roads sharing the same node. Applied traffic rules, based on local traffic rules (such as right-of-way or main road priority), determine, guided by a rule base, which entrance directions at the intersection require stop signs or traffic lights. Intelligent layout rules automatically generate stop lines on the lane lines at the appropriate locations and create a virtual traffic sign or traffic light controller a certain distance behind the stop line. All these generated elements are tagged with the relevant attributes from the target lane traffic data in OpenDRIVE.
[0118] In existing technologies, whether processing ground truth vehicle data collected by LiDAR-equipped vehicles or applying traditional OSM data, extensive manual adjustments (such as manually correcting coordinate deviations, supplementing missing lane information, and improving traffic rule descriptions) are often required to adapt the data to professional road simulation software. This invention, however, combines the aforementioned semantic reconstruction and coordinate transformation technologies, enabling the transformed OpenDRIVE data to be directly imported into professional road simulation models without manual intervention. This significantly reduces reliance on manual operations and dramatically improves the efficiency of map data application.
[0119] like Figure 2 As shown, based on the above method embodiments, corresponding system embodiments are provided;
[0120] One embodiment of the present invention provides a road modeling system, comprising:
[0121] The first acquisition module is used to acquire the original street map data of the road area to be modeled, and to determine the original road data based on the original street map data;
[0122] The second acquisition module is used to acquire the original coordinate data and original attribute data of the original road data;
[0123] The coordinate transformation module is used to obtain the current coordinate data based on a preset coordinate projection transformation algorithm, the original coordinate data, and preset reference points in the road area to be modeled;
[0124] The mapping module is used to obtain the current attribute data based on the preset road semantic mapping rule library and the original attribute data;
[0125] The module is used to obtain the current road data based on the current coordinate data and the current attribute data;
[0126] The selection module is used to determine the defect data of the current road data and select a target completion algorithm from the preset candidate completion algorithms based on the defect data;
[0127] The completion module is used to complete the defects in the current road data based on the target completion algorithm to obtain the target road data;
[0128] The road model generation module is used to construct simulation standard road data based on the target road data, so that the simulation model can obtain the target road model of the road area to be modeled based on the simulation standard road data.
[0129] It is understood that the above system item embodiments correspond to the method item embodiments of the present invention, and can implement the road modeling method provided by any of the above method item embodiments of the present invention.
[0130] It should be noted that the system embodiments described above are merely illustrative, and some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Furthermore, in the accompanying drawings of the system embodiments provided by this invention, the connection relationships between modules indicate that they have communication connections, which can be specifically implemented as one or more communication buses or signal lines. Those skilled in the art can understand and implement this without any creative effort.
[0131] Based on the above-described embodiment of the road modeling method, another embodiment of the present invention provides a terminal device, which includes a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor. When the processor executes the computer program, it implements a road modeling method according to any embodiment of the present invention.
[0132] For example, in this embodiment, the computer program can be divided into one or more modules, which are stored in the memory and executed by the processor to complete the present invention. The one or more modules may be a series of computer program instruction segments capable of performing a specific function, which describe the execution process of the computer program in the terminal device.
[0133] The terminal device may be a desktop computer, laptop, handheld computer, or cloud server, etc. The terminal device may include, but is not limited to, a processor and a memory.
[0134] The processor can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor can be a microprocessor or any conventional processor. The processor is the control center of the terminal device, connecting all parts of the terminal device via various interfaces and lines.
[0135] Based on the above-described method embodiments, another embodiment of the present invention provides a computer-readable storage medium including a stored computer program, wherein, when the computer program is executed, it controls the device where the computer-readable storage medium is located to execute a road modeling method as described in any of the above-described method embodiments of the present invention.
[0136] The modules / units integrated into the system / terminal device, if implemented as software functional units and sold or used as independent products, can be stored in a computer-readable storage medium. Based on this understanding, all or part of the processes in the above embodiments of the present invention can also be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. The computer-readable medium can include: any entity or system capable of carrying the computer program code, recording media, USB flash drives, portable hard drives, magnetic disks, optical disks, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signals, telecommunication signals, and software distribution media, etc.
[0137] The above description represents the preferred embodiments of the present invention. It should be noted that those skilled in the art can make various improvements and modifications without departing from the principles of the present invention, and these improvements and modifications are also considered to be within the scope of protection of the present invention.
Claims
1. A road modeling method, characterized in that, include: Obtain the original street map data of the road area to be modeled, and determine the original road data based on the original street map data; Obtain the original coordinate data and original attribute data of the original road data; Based on the preset coordinate projection transformation algorithm, the original coordinate data, and the preset reference points in the road area to be modeled, the current coordinate data is obtained; Based on the preset road semantic mapping rule base and the original attribute data, the current attribute data is obtained; Based on the current coordinate data and the current attribute data, the current road data is obtained; Determine the defective data of the current road data, and select a target completion algorithm from the preset candidate completion algorithms based on the defective data; Based on the target completion algorithm, defect completion is performed on the current road data to obtain the target road data; Based on the target road data, simulation standard road data is constructed so that the simulation model can obtain the target road model of the road area to be modeled based on the simulation standard road data.
2. The road modeling method according to claim 1, characterized in that, The coordinate projection transformation algorithm includes an Earth coordinate transformation algorithm and a local coordinate transformation algorithm. The process of obtaining current coordinate data based on a preset coordinate projection transformation algorithm, the original coordinate data, and preset reference points in the road area to be modeled includes: Based on the Earth coordinate transformation algorithm and the original road data, Earth coordinate road data in the Earth's central rectangular coordinate system is obtained; Using the reference point as the origin, the current coordinate data is obtained based on the local coordinate transformation algorithm and the Earth coordinate road data.
3. The road modeling method according to claim 2, characterized in that, The original coordinate data includes the original road latitude, original road longitude, and original road elevation. The process of obtaining Earth coordinate road data in the Earth's central rectangular coordinate system based on the Earth coordinate transformation algorithm and the original road data includes: Obtain the Earth's circumpolar curvature radius; Based on the radius of curvature of the zonal circle, the original road latitude, the original road longitude, and the original road elevation, the Earth coordinate road data is obtained.
4. The road modeling method according to claim 1, characterized in that, The target completion algorithm includes lane completion algorithm, curvature completion algorithm, elevation completion algorithm, and traffic rule completion algorithm. The current road data includes current coordinate data and current attribute data. The current coordinate data includes current road latitude and longitude and current road elevation. The current attribute data includes road type, current number of lanes, and current lane traffic data. The step of performing defect completion on the current road data based on the target completion algorithm to obtain target road data includes: Based on the lane completion algorithm, the current road latitude and longitude, the road type, and the current number of lanes, the target number of lanes is obtained; Based on the curvature completion algorithm and the current road latitude and longitude, the target lane curvature data is obtained; Based on the elevation completion algorithm, the current road latitude and longitude, and the current road elevation, the target lane elevation data is obtained; Based on the traffic rule completion algorithm, the current road latitude and longitude, and the current lane traffic data, the target lane traffic data is obtained; The target road data is obtained based on the target number of lanes, the target lane curvature data, the target lane elevation data, and the target lane traffic data.
5. The road modeling method according to claim 4, characterized in that, The process of obtaining the target number of lanes based on the lane completion algorithm, the current road latitude and longitude, the road type, and the current number of lanes includes: The target type is determined from the road types based on the current road latitude and longitude, and the number of reference lanes is determined based on the target type; When the number of reference lanes is different from the number of current lanes, the number of current lanes is updated based on the number of reference lanes to obtain the target number of lanes.
6. The road modeling method according to claim 4, characterized in that, The process of obtaining target lane curvature data based on the curvature completion algorithm and the current road latitude and longitude includes: The current lane curve is obtained based on a preset road node curve fitting algorithm and the current road latitude and longitude of any three adjacent road nodes; Based on a preset set of sampling nodes and the current lane curve, the curvature data of the target lane is obtained.
7. The road modeling method according to claim 4, characterized in that, The process of obtaining target lane elevation data based on the elevation completion algorithm, the current road latitude and longitude, and the current road elevation includes: The elevation value is obtained based on the preset digital elevation model and the current road latitude and longitude. The slope value is obtained based on the elevation values of any two road nodes and the current road latitude and longitude. The current road elevation is updated based on the elevation value and the slope value to obtain the target lane elevation data.
8. A road modeling system, characterized in that, include: The first acquisition module is used to acquire the original street map data of the road area to be modeled, and to determine the original road data based on the original street map data; The second acquisition module is used to acquire the original coordinate data and original attribute data of the original road data; The coordinate transformation module is used to obtain the current coordinate data based on a preset coordinate projection transformation algorithm, the original coordinate data, and preset reference points in the road area to be modeled; The mapping module is used to obtain the current attribute data based on the preset road semantic mapping rule library and the original attribute data; The module is used to obtain the current road data based on the current coordinate data and the current attribute data; The selection module is used to determine the defect data of the current road data and select a target completion algorithm from the preset candidate completion algorithms based on the defect data; The completion module is used to complete the defects in the current road data based on the target completion algorithm to obtain the target road data; The road model generation module is used to construct simulation standard road data based on the target road data, so that the simulation model can obtain the target road model of the road area to be modeled based on the simulation standard road data.
9. A terminal device, characterized in that, It includes a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, wherein when the processor executes the computer program, it implements a road modeling method as described in any one of claims 1-7.
10. A computer-readable storage medium, characterized in that, include: A stored computer program, wherein, when the computer program is executed, it controls the device containing the computer-readable storage medium to perform a road modeling method as described in any one of claims 1-7.