Road data processing method and device, storage medium and electronic device
By vectorizing and overlaying road data, intersections are automatically marked, solving the problem of low data processing efficiency caused by manual drawing and achieving efficient and accurate map generation.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SHANGHAI SHANMA INTELLIGENT TECH CO LTD
- Filing Date
- 2023-12-30
- Publication Date
- 2026-06-19
Smart Images

Figure CN118155061B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of intelligent transportation technology, and more specifically, to a method and apparatus for processing road data, a storage medium, and an electronic device. Background Technology
[0002] In real life, users can obtain vector data from maps. This vector data typically contains only simple information such as road boundaries, building / landmark markings, and locations, which is sufficient for most users. However, for groups that require high data accuracy, the amount of information provided by the map is limited and cannot meet their needs.
[0003] To address this, data modules such as circular roundabouts, regular straight roads, and regular intersections can be pre-built. When a map needs to be built, the map coordinates of the relevant modules can be determined, and then the corresponding modules can be called. However, for irregular areas and irregular intersections, it is not possible to mark them by calling modules. They can only be drawn manually. Manual drawing increases labor costs and reduces data processing efficiency. Moreover, since different people have different drawing abilities and standards, manual drawing will also lead to a wide variety of map versions, which will affect usability.
[0004] It is evident that the road data processing methods in related technologies suffer from low data processing efficiency due to the manual drawing of road data. Summary of the Invention
[0005] This application provides a method and apparatus for processing road data, a storage medium, and an electronic device to at least solve the problem of low data processing efficiency caused by manually drawing road data in related technologies.
[0006] According to one aspect of the embodiments of this application, a method for processing road data is provided, comprising: vectorizing the road data to be processed to obtain a set of road centerlines and a set of road attributes corresponding to each road centerline in the set of road centerlines, wherein the road data to be processed is road data corresponding to a target area; determining a set of road nodes based on the set of road attributes corresponding to each road centerline, wherein each road node in the set of road nodes is the intersection of at least two road centerlines in the set of road centerlines, each road node is associated with at least two sets of road attributes, and the at least two sets of road attributes associated with each road node form the road centerline. At least two road centerlines correspond one-to-one for each road node; based on at least two sets of road attributes associated with each road node, a node buffer is generated for each road node, and based on a set of road attributes corresponding to each road centerline, a road buffer is generated for each road centerline; overlay analysis and dissolution analysis are performed on the node buffers of each road node and the road buffers of each road centerline to obtain road network topology information, wherein the road network topology information is used to indicate the topological relationship between roads and intersections within the target area, the roads within the target area correspond to the set of road centerlines, and the intersections within the target area correspond to the set of road nodes.
[0007] According to another aspect of the embodiments of this application, a road data processing apparatus is also provided, comprising: a processing unit, configured to perform vectorization processing on the road data to be processed to obtain a set of road centerlines and a set of road attributes corresponding to each road centerline in the set of road centerlines, wherein the road data to be processed is road data corresponding to a target area; and a first determining unit, configured to determine a set of road nodes based on the set of road attributes corresponding to each road centerline, wherein each road node in the set of road nodes is the intersection of at least two road centerlines in the set of road centerlines, each road node is associated with at least two sets of road attributes, and the at least two sets of road attributes associated with each road node are used to form a... Each road node has at least two road centerlines that correspond one-to-one; a first generation unit is used to generate a node buffer for each road node based on at least two sets of road attributes associated with each road node, and to generate a road buffer for each road centerline based on a set of road attributes corresponding to each road centerline; an analysis unit is used to perform overlay analysis and dissolution analysis on the node buffers of each road node and the road buffers of each road centerline to obtain road network topology information, wherein the road network topology information is used to indicate the topological relationship between roads and intersections within the target area, the roads within the target area correspond to the set of road centerlines, and the intersections within the target area correspond to the set of road nodes.
[0008] According to another aspect of the embodiments of this application, a computer-readable storage medium is also provided, wherein a computer program is stored in the computer program, and the computer program is configured to execute the above-described method for processing road data when it is run.
[0009] According to another aspect of the embodiments of this application, an electronic device is also provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the aforementioned road data processing method through the computer program.
[0010] In this embodiment, road data is vectorized, and intersections and road network topology information are generated based on the obtained road centerlines and their corresponding road attributes. The road data to be processed is vectorized to obtain a set of road centerlines and a set of road attributes corresponding to each road centerline in the set. The road data to be processed corresponds to the target area. A set of road nodes is determined based on the set of road attributes corresponding to each road centerline. Each road node in the set is the intersection of at least two road centerlines in the set. Each road node is associated with at least two sets of road attributes, and the at least two sets of road attributes associated with each road node correspond one-to-one with the at least two road centerlines forming each road node. A node buffer for each road node is generated based on the at least two sets of road attributes associated with each road node, and a... Road buffer zones for each road centerline; overlay and dissolution analyses are performed on the node buffer zones for each road node and the road buffer zones for each road centerline to obtain road network topology information. This topology information indicates the topological relationships between roads and intersections within the target area. Roads within the target area correspond to a set of road centerlines, and intersections within the target area correspond to a set of road nodes. By vectorizing the road data and determining intersections based on the obtained road centerlines and their corresponding road attributes—that is, determining road nodes, generating node buffer zones, and performing overlay and dissolution analyses on the node buffer zones and road buffer zones—intersections can be automatically labeled based on the relationship between roads and intersections. This reduces the impact of intersection shape on the number of modules required, eliminating the need for manual intersection drawing and improving data processing efficiency. This solves the problem of low data processing efficiency caused by manually drawing road data in related technologies. Attached Figure Description
[0011] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.
[0012] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0013] Figure 1 This is a schematic diagram of the hardware environment for a road data processing method according to an embodiment of this application;
[0014] Figure 2 This is a flowchart illustrating a method for processing road data according to an embodiment of this application;
[0015] Figure 3 This is a schematic diagram of an optional map vector data according to an embodiment of this application;
[0016] Figure 4 This is a schematic diagram of an optional map according to an embodiment of this application;
[0017] Figure 5 This is a schematic diagram of another optional map according to an embodiment of this application;
[0018] Figure 6 This is a schematic diagram of an optional road centerline according to an embodiment of this application;
[0019] Figure 7 This is a schematic diagram of three optional buffers according to an embodiment of this application;
[0020] Figure 8 This is a schematic diagram of an optional remote sensing map according to an embodiment of this application;
[0021] Figure 9 This is a schematic diagram of another optional remote sensing map according to an embodiment of this application;
[0022] Figure 10 This is a schematic diagram of an optional road node according to an embodiment of this application;
[0023] Figure 11 This is a schematic diagram of an optional dissolution analysis according to an embodiment of this application;
[0024] Figure 12 This is a schematic diagram of another optional dissolution analysis according to an embodiment of this application;
[0025] Figure 13 This is a schematic diagram of another optional dissolution analysis according to an embodiment of this application;
[0026] Figure 14This is a schematic diagram of an optional road buffer zone according to an embodiment of this application;
[0027] Figure 15 This is a schematic diagram of an optional road data processing method according to an embodiment of this application;
[0028] Figure 16 This is a schematic diagram of an optional intersection surface according to an embodiment of this application;
[0029] Figure 17 This is a schematic diagram of an optional road network surface according to an embodiment of this application;
[0030] Figure 18 This is a schematic diagram of another optional road network surface according to an embodiment of this application;
[0031] Figure 19 This is a schematic diagram of another optional road data processing method according to an embodiment of this application;
[0032] Figure 20 This is a structural block diagram of an optional road data processing apparatus according to an embodiment of this application;
[0033] Figure 21 This is a structural block diagram of an optional electronic device according to an embodiment of this application. Detailed Implementation
[0034] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present application, and not all embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative effort should fall within the scope of protection of the present application.
[0035] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0036] According to one aspect of the embodiments of this application, a method for processing road data is provided. Optionally, in this embodiment, the above-described road data processing method can be applied to, for example... Figure 1 The hardware environment shown consists of terminal device 102 and server 104. For example... Figure 1 As shown, server 104 is connected to terminal device 102 via a network and can be used to provide services (such as application services) to the terminal or clients installed on the terminal. A database can be set up on the server or independently of the server to provide data storage services for server 104. Cloud computing and / or edge computing services can be configured on the server or independently of the server to provide data processing services for server 104.
[0037] The aforementioned network may include, but is not limited to, at least one of the following: wired network, wireless network. The aforementioned wired network may include, but is not limited to, at least one of the following: wide area network, metropolitan area network, local area network. The aforementioned wireless network may include, but is not limited to, at least one of the following: Wi-Fi, Bluetooth. The terminal device 102 may not be limited to a camera, etc.
[0038] The road data processing method of this application embodiment can be executed by server 104, terminal device 102, or jointly by server 104 and terminal device 102. Alternatively, the road data processing method of this application embodiment can be executed by a client installed on terminal device 102.
[0039] Taking the road data processing method in this embodiment as an example, which is executed by server 104, this embodiment provides a road data processing method. Figure 2 This is a flowchart illustrating a method for processing road data according to an embodiment of this application, as shown below. Figure 2 As shown, the process includes the following steps:
[0040] Step S202: Vectorize the road data to be processed to obtain a set of road centerlines and a set of road attributes corresponding to each road centerline in the set of road centerlines.
[0041] The road data processing method in this embodiment can be applied to scenarios where road data is processed to establish a road network topology. The road data to be processed can be images or other types of road data, such as electronic maps. In this embodiment, electronic map images are used as an example. Here, the electronic map can be a map of an urban area, a highway map, or a map of other areas. An electronic map, also known as a digital map, is a map stored and viewed digitally using computer technology. Navigation systems in mobile phones, vehicles, and other terminals are based on electronic maps. Therefore, the accuracy of the electronic map is one of the important factors affecting navigation effectiveness.
[0042] In real life, users can obtain vector data from maps, such as... Figure 3 As shown, the acquired vector data typically contains only simple information such as road boundaries, building / landmark identification, and location, which is sufficient for most users. However, for certain groups who require high data accuracy, the map provides too little information to meet their needs.
[0043] For example, for urban management departments, this map lacks road markings, the boundaries between roads and buildings on both sides are unclear, and information such as urban green belts cannot be intuitively obtained. Therefore, a clearer and more intuitive map (such as...) is needed. Figure 4 (As shown) to assist relevant departments in urban management.
[0044] like Figure 5 As shown, in related technologies, data modules such as circular roundabouts, ordinary straight roads, and regular intersections can be pre-established. When a map needs to be built, the map coordinates of the relevant modules are determined, and then the corresponding modules can be called. However, for irregular areas and irregular intersections, it is impossible to label them by calling modules; they can only be drawn manually. This method increases labor costs and reduces data processing efficiency. Furthermore, since everyone's drawing ability and standards are different, manual drawing can lead to vastly different map versions, thus affecting usability.
[0045] Furthermore, while related technologies can acquire linear and point data of roads, the processing method involves manually inputting roads and point intersections as vector data sets. In this way, any road or intersection will correspond to multiple road relationships. For example, if road A is connected to three or four roads at its beginning and end, then road A has 6-8 data sets. When searching for road relationships, these 6-8 road data sets need to be searched and matched sequentially. In cases where there are many urban roads, this search method will increase the latency significantly.
[0046] To at least partially solve the aforementioned technical problems, this embodiment employs a method of vectorizing road data and determining intersections and generating road network topology information based on the obtained road centerlines and their corresponding road attributes. This involves determining road nodes, generating node buffers, and performing overlay and dissolution analyses on the node buffers and road buffers. This allows for automatic intersection labeling based on the relationship between roads and intersections, reducing the impact of intersection shape on the number of modules and achieving the goal of eliminating the need for manual intersection drawing, thereby improving data processing efficiency.
[0047] To establish topological relationships between roads and intersections within a target area, one can first acquire road data corresponding to the target area to obtain road data to be processed. This road data is then vectorized to obtain vector data corresponding to the road data to be processed. This vector data includes a set of road attributes corresponding to each road centerline extracted from a set of road centerlines. Vectorization of the road data to be processed refers to map vectorization, extracting road centerlines and their attributes. Vector data inherently contains spatial information, enabling conversion between various coordinate systems, making it suitable for different scenarios and not limited by the business constraints of purely front-end display systems, thus expanding its application scope.
[0048] Here, map vectorization is one of the important methods for acquiring geographic data. Map vectorization is the process of converting raster data into vector data. When a paper map is quantized into a bitmap digital image through optical-to-electronic conversion by a computer graphics and image system, and then processed through image processing and curve vectorization, or directly digitized by manual tracking, a vector map data file is generated that can be displayed, modified, labeled, roamed, calculated, managed, and printed by a Geographic Information System (GIS). This computer data file corresponding to the paper map is called a vectorized electronic map.
[0049] Here, a set of road centerlines may include one or more road centerlines. Road centerlines are generally drawn at the center of the road to divide it into two areas (which may be two symmetrical areas). Each road centerline has a corresponding set of road attributes, which may include, but are not limited to, at least one of the following: road width, number of lanes, road class, and direction of travel (according to traffic rules, left-right bidirectional roads are set on the map's top-down view, with left lanes allowing only left-side traffic and right lanes allowing only right-side traffic). Other types of road attributes may also be included. The road class may be determined by the road's elevation (height), meaning the road class corresponding to each road centerline matches the road surface height corresponding to each road centerline.
[0050] For example, vectorizing road data (such as...) Figure 6 As shown in the figure, the road centerline and its attributes are extracted. The road attributes can include road grade (road grade is used to determine whether they intersect; roads of the same grade will intersect to form an intersection), road width, number of lanes, and directions of travel. The road grade is determined by the road elevation (height).
[0051] During vectorization, a vector map of the target area can be obtained, which can be the road centerline, generating a road centerline (roadCenterLine) layer. Then, road information is obtained, which indicates the road's grade and width. The attributes of the road centerline layer are entered, including the number of lanes, lane width, road width, road grade, and direction of travel.
[0052] Step S204: Determine a set of road nodes based on a set of road attributes corresponding to the centerline of each road.
[0053] Based on a set of road attributes corresponding to each road centerline, it can be determined whether two road centerlines intersect. This intersection can be determined based on the centerline position, the road surface height, or a combination of other information. These intersections are called road nodes. Each road node is the intersection of at least two road centerlines and is associated with at least two sets of road attributes. That is, each road node can be associated with at least two sets of road attributes corresponding to the at least two road centerlines that form that road node. Normally, a road is a continuous line segment on the image. When it intersects with other roads, it generates a node, i.e., a road node.
[0054] For example, based on vector maps and road attributes, it can be determined whether road nodes should be generated between roads, and the nodes that need to be generated can be produced. The nodes are associated with the road information they are connected to, generating a node layer, and the nodes are associated with the road information.
[0055] Step S206: Based on at least two sets of road attributes associated with each road node, generate a node buffer for each road node, and based on a set of road attributes corresponding to each road centerline, generate a road buffer for each road centerline.
[0056] For each road node, buffer analysis can be performed based on at least two sets of road attributes associated with that road node to obtain a point buffer for each road node. Similarly, for each road centerline, a road buffer can be generated based on a set of road attributes corresponding to that centerline. Buffer analysis can be based on a Geographic Information System (GIS). Specifically, this embodiment provides a road network topology establishment method based on GIS buffer analysis and overlay analysis, i.e., a road data processing method based on a GIS.
[0057] Here, GIS is a product of the intersection of geospatial analysis technology and computer information processing technology. It is a computer-based formal information system that can integrate data from multiple sources to provide necessary information for planning and decision-making. Spatial analysis is the main function of GIS. It is a method of analyzing spatial data to formulate rules or make decisions. It applies logical and mathematical models to analyze spatial observations, thereby deriving direct data that can support decision-making. Spatial analysis is the core of GIS. In the past, GIS was mainly characterized by its applicability and technicality. With the development of GIS, spatial analysis has become an important theoretical foundation supporting GIS applications. Currently, spatial analysis has been applied to many fields such as urban planning and management, transportation, water conservancy, geological disasters, earthquake disasters, power, and environmental protection.
[0058] Buffer analysis is a crucial spatial operation function in Geographic Information Systems (GIS). Its basic idea is to establish a buffer zone with a certain radius around a given spatial entity to determine the scope of its influence or service area on the surrounding environment. Buffer analysis is primarily used to address the proximity of features in geospatial data. Generally, buffer analysis is combined with other spatial analysis functions such as overlay analysis, network analysis, and service facility querying to process geospatial information data and solve spatial decision-making problems. Buffer analysis is widely used in urban planning, road traffic management, and environmental monitoring.
[0059] The buffers generated differ depending on the type of target feature. Point buffers are typically circles with a point as the center and a certain distance as the radius; line buffers are parallel strip polygons with a line as the central axis and a certain distance from the central axis; polygon buffers are new polygons generated by extending a certain distance outward or inward from the boundary of a polygon. Among these, the generation of buffers for linear targets is crucial and fundamental. Figure 7 (a), (b), and (c) in the diagram represent the basic methods for establishing buffers for point, line, and polygon elements, respectively. For different application scenarios, special processing can be applied to the target elements to obtain irregular buffers. For example, when storing point data as angles, a fan-shaped buffer can be created; when processing line elements, truncation can be performed, with each line segment having its own buffer, thus obtaining irregular buffers, etc., to better meet actual needs.
[0060] For example, a point buffer (i.e., a node buffer) is generated based on nodes and associated road information as a temporary layer. A line buffer (i.e., a road buffer) is generated based on information such as road width information, thus generating a road polygon layer.
[0061] Determining line buffers and point buffers by combining remote sensing images can be done as follows: Figures 8 to 10 As shown, where, Figure 8 and Figure 9 For remote sensing images, Figure 10 The defined line buffer and point buffer are defined, where the point buffer is the buffer at the intersection of two roads (segments), and the line buffer is the buffer for one road (segment).
[0062] Step S208: Perform overlay and dissolution analysis on the node buffer of each road node and the road buffer of each road centerline to obtain the road network topology information.
[0063] Since node buffers and road buffers are independent and can reside in different layers, and roads within the target area correspond to a set of road centerlines, while intersections within the target area correspond to a set of road nodes, the node buffers based on separate road nodes and road buffers based on road centerlines cannot represent the topological relationships between roads and intersections within the target area. To address this, overlay and dissolve analyses can be performed on the node buffers of each road node and the road buffers of each road centerline to obtain road network topology information. This obtained road network topology information is used to indicate the topological relationships between roads and intersections within the target area.
[0064] Here, overlay analysis refers to superimposing multiple data layers containing spatial features of interest to create a new feature layer. The goal of overlay analysis is to analyze the relationships between spatial characteristics and specific attributes of spatially related objects (e.g., the intersection of two roads forms an intersection). Overlay analysis of multi-layer data not only generates new spatial relationships but also new attribute characteristic relationships, revealing differences, connections, and changes between multiple layers of data. Overlay analysis in GIS includes two main categories: overlay analysis based on vector data and overlay analysis based on raster data. Based on the different graphic characteristics of the overlaid objects, it is divided into three types: point-polygon overlay, line-polygon overlay, and polygon-polygon overlay.
[0065] Dissolution analysis is a special type of spatial aggregation based on polygons or attributes sharing the same category (i.e., boundaries between adjacent polygons are removed or they have the same value for a specified attribute). The goal of dissolution analysis is to merge geographic features that have some spatial overlap or can be categorized into a uniform type, preserving their unique and common features before merging them into a single feature. The number of features participating in the dissolution process is also statistically analyzed. Examples of several feature fusion methods are shown below. Figures 11 to 13 As shown, where, Figure 11 Feature fusion can be based on region color or other region attributes. Figure 12 It is a fusion of elements based on regional overlap. Figure 13 It can be based on the fusion of elements where lines intersect.
[0066] Through the above steps, the road data to be processed is vectorized to obtain a set of road centerlines and a set of road attributes corresponding to each road centerline in the set of road centerlines. The road data to be processed is the road data corresponding to the target area. Based on the set of road attributes corresponding to each road centerline, a set of road nodes is determined. Each road node in the set of road nodes is the intersection of at least two road centerlines in the set of road centerlines. Each road node is associated with at least two sets of road attributes, and the at least two sets of road attributes associated with each road node correspond one-to-one with the at least two road centerlines forming each road node. Based on the at least two sets of road attributes associated with each road node... The system generates a node buffer for each road node based on a set of road attributes, and generates a road buffer for each road centerline based on a set of road attributes corresponding to each road centerline. Overlay and dissolution analyses are performed on the node buffers of each road node and the road buffers of each road centerline to obtain road network topology information. This information indicates the topological relationships between roads and intersections within the target area. Roads within the target area correspond to a set of road centerlines, and intersections within the target area correspond to a set of road nodes. This approach addresses the low data processing efficiency caused by manually drawing road data in related technologies, thus improving overall data processing efficiency.
[0067] In one exemplary embodiment, a set of road attributes corresponding to each road centerline includes the road width corresponding to each road centerline, that is, the road width of a road represented by the road centerline, and at least two sets of road attributes associated with each road node may include at least two road widths associated with each road node.
[0068] Correspondingly, based on at least two sets of road attributes associated with each road node, a node buffer is generated for each road node, including:
[0069] S11, determine the maximum road width associated with each road node from at least two road widths associated with each road node;
[0070] S12, using each road node as the center and the maximum road width associated with each road node as the radius, generate a node buffer for each road node.
[0071] The node buffer can be circular, with its center point being the corresponding road node and its radius being any of the at least two road widths associated with each road node. To ensure the accuracy of subsequent overlay and fusion analyses, the radius of the node buffer for each road node can be the maximum road width among the at least two road widths associated with each road node, i.e., the maximum road width associated with each road node.
[0072] When performing buffer analysis on each road node, the maximum road width associated with each road node can be determined first from the at least two road widths associated with each road node. Then, a node buffer for each road node can be generated with each road node as the center and the maximum road width associated with each road node as the radius.
[0073] For example, when performing buffer analysis on nodes (regular or regular) intersections or areas, road information (e.g., width information) of all roads associated with the node can be obtained. Based on the node and its associated road information, the maximum value of the width information associated with the node (i.e., the maximum width of the road associated with each node) is used as the radius of the point buffer, and the node is used as the center to generate the node's buffer (point buffer). The generated point buffer can be used as a temporary layer.
[0074] For each road centerline, a road buffer zone is generated based on a set of road attributes corresponding to each road centerline, including:
[0075] Two lines are generated by taking the center line of each road as the central axis and shifting each road center line to both sides by half the width of the road corresponding to each road center line. These two lines are then used as road lines to generate the road buffer zone for each road center line.
[0076] The shape of a road buffer zone can be a linear area with a certain width, whose axis can be the corresponding road centerline, and whose width can be determined according to the road width corresponding to the road centerline. To ensure the accuracy of subsequent processing (e.g., determining road edge lines), the width of a road buffer zone for a road centerline can be the road width corresponding to that road centerline.
[0077] When performing road buffer analysis on each road centerline, each road centerline can be used as a central axis, and each road centerline can be translated. That is, each road centerline can be translated to both sides by half the width of the road corresponding to that road centerline. The two lines obtained from the translation can be used as two road lines to generate the road buffer for each road centerline. Here, the two road lines can be used to represent the boundary lines of the corresponding roads.
[0078] Optionally, a set of road centerlines can be divided into a set of target road segments by a set of road nodes. Each target road segment in the set of target road segments is at least a part of a road centerline. Unless contradictory, the operation performed on the road centerline can be performed on the target road segments. Here, some road centerlines can be divided into at least two target road segments by road nodes, and some road centerlines may not be divided into target road segments by road nodes. Therefore, there is a case where one target road segment is also one road centerline. Alternatively, a set of road centerlines can be divided into undivided road centerlines and divided target road segments. The processing logic is similar to that in the previous embodiments and will not be repeated here.
[0079] For example, nodes are associated with road information, and road segment (Link) tables are generated by breaking the road centerline using nodes, resulting in a road segment layer. For (irregular or regular) intersections and areas, when performing buffer analysis on the road centerline, a line buffer is generated based on the road width information and the road segment layer, using the road centerline as the axis and the road width (limited by the road segment's width attribute) as the buffer distance, resulting in a road polygon (roadPolygon) layer. Here, generating the line buffer can be done by translating the road segment (i.e., shifting the centerline a certain width to both sides of the centerline) to obtain the road double lines (the left and right edges of the road), such as... Figure 14 As shown, here, the road width is the line of the buffer zone (i.e., the area width).
[0080] In this embodiment, a node buffer is formed with the road node as the center and the maximum road width associated with the road node as the radius. A road buffer is also generated with the road centerline as the central axis and the road width as the buffer distance. This ensures the accuracy of subsequent overlay and fusion analysis and improves the accuracy of subsequent processing.
[0081] In one exemplary embodiment, a set of road attributes corresponding to each road centerline includes the road grade corresponding to each road centerline and the centerline position of each road centerline. Here, the centerline position refers to the spatial position of the road centerline, which can be a two-dimensional spatial position. The road grade corresponding to each road centerline is matched with the road surface height corresponding to each road centerline. The road grade and road surface height can be positively correlated or negatively correlated, as long as different road layers can be distinguished by the road grade. Correspondingly, a set of road nodes is determined based on the set of road attributes corresponding to each road centerline, including:
[0082] S21, determine a set of candidate nodes based on the centerline position of each road centerline, wherein each candidate node in the set of candidate nodes is associated with at least two road centerlines with the same centerline position;
[0083] S22, determine all candidate nodes in a set of candidate nodes that have corresponding road centerlines of the same road level among at least two road centerlines associated with them as a set of road nodes.
[0084] To determine road nodes, we can first identify a set of candidate nodes based on the centerline position of each road centerline. If the centerline positions of at least two road centerlines intersect (they intersect in two-dimensional space, and in three-dimensional space they can be different layers), the intersection can be identified as a candidate node, thus obtaining a set of candidate nodes. Here, each candidate node is associated with at least two road centerlines with the same centerline position.
[0085] For each candidate node, it can be further determined whether there are at least two road centerlines of the road level among the road centerlines associated with it. If so, it is identified as a road node, thus obtaining a set of road nodes. Here, the number of road centerlines associated with a candidate node and the number of road centerlines associated with it when it is a road node can be the same or different.
[0086] For example, based on the centerline position, if a candidate node is associated with three road centerlines, and two of these are road centerlines of the same road class, then it is associated with two road centerlines when it is a road node.
[0087] For example, when roads intersect and have the same road class, the road centerline data is superimposed. The centerlines intersect in space to generate new nodes, and these nodes are associated with the roads. These nodes are used to divide the road centerlines to form new road segments (at this time, the road segments are still the segments of the centerlines after they have been divided).
[0088] In this embodiment, candidate nodes are determined based on the position of the centerline of the road centerline, and road nodes are selected based on the road grade, which can improve the convenience and accuracy of road node determination.
[0089] The following describes the road data processing method in this embodiment with reference to optional examples. This optional example provides a road network topology establishment scheme based on GIS buffer analysis and overlay analysis, which is used to more accurately determine the positional relationship between roads. Using a GIS data processing platform and related development libraries as tools and road data as the data basis, it realizes the automated and accurate calibration of road signs, which greatly improves the efficiency of road model rendering and demonstration.
[0090] For the analysis process of roads, combined with Figure 15 The process of processing road data in this optional example may include the following steps:
[0091] Step 1: Vectorize the road data and extract the road centerline and its attributes (e.g., road grade, road width, number of lanes, and direction of travel).
[0092] Step 2: For road centerlines that intersect in spatial location, determine whether the road grades are the same. If they are the same, proceed to Step 3; otherwise, ignore the current intersection (the intersection at this time is not an actual intersection, but a different point with the same two-dimensional position but different height position).
[0093] Step 3: Overlay the road centerline to obtain the road node.
[0094] Step 4: Based on road nodes, obtain road segments by using multi-point break lines (road centerlines). Normally, a road is a continuous line segment on the image. When it intersects with other roads, nodes are generated, dividing the road into segments. These cut-off segments are the point break lines, such as... Figure 10 The bold line segment shown.
[0095] Step 5: By translating each road segment, the road boundaries of each segment can be determined.
[0096] Step 6: Add the road signs to their corresponding locations based on the road sign coordinates (coordinates, sign type, etc.). Here, the road sign coordinates can be extracted from road sign information, which describes the road signs and their corresponding coordinates. A sign location point layer (roadObj) can be generated based on the road signs and their corresponding coordinates extracted from the road sign information.
[0097] This optional example demonstrates how a road network topology can be generated simply by knowing the road centerline, road grade, road width, number of lanes, and directions of traffic. This allows for the determination of the relationship between roads and intersections, or the performance of related travel analysis. By using a GIS data processing platform and related development libraries as tools and road data as the foundation, the automated and accurate calibration of road signs can be achieved, greatly improving the efficiency of road model rendering and demonstration.
[0098] In one exemplary embodiment, a set of road centerlines is divided into a set of target road segments by a set of road nodes. Each target road segment in the set of target road segments is at least a part of a road centerline. The meaning and division method of the target road segments are similar to those in the previous embodiments and will not be repeated here. The road surface of the target area may include a set of road buffers of road centerlines. That is, the road buffers of a set of road centerlines are stored as the road surface of the target area and subsequent processing is performed.
[0099] Correspondingly, overlay and dissolution analyses are performed on the node buffer of each road node and the road buffer of each road centerline to obtain road network topology information, including:
[0100] S31, Perform the intersection face determination operation on each road node as the current road node to obtain the intersection face of the target area;
[0101] S32, by performing a fusion process on the road surface and intersection surface of the target area, the road surface and intersection surface of the target area are merged into the road network surface of the target area to obtain the road network topology information. The fusion process includes at least one of the following: merging, dissolving.
[0102] In this embodiment, each road node can correspond to an intersection. Therefore, intersection data (representing the intersection corresponding to that road node) can be generated for each road node, and the intersection face of the target area contains the intersection data corresponding to each road node. Here, the intersection data corresponding to each road node can be obtained by performing an intersection face determination operation with each road node as the current road node.
[0103] When performing the intersection face determination operation, the node buffer of the current road node is the current node buffer, and the road buffers of at least two target road segments connected to the current road node are at least two current road buffers. The execution steps of the intersection face determination operation include: determining the road surface features in the current node buffer that belong to the intersection buffers corresponding to each current road buffer, and the road surface features in each current road buffer that belong to the intersection buffers corresponding to each current road buffer; merging and fusing the determined road surface features to obtain the intersection data corresponding to the current road node, wherein the intersection face of the target area includes the intersection data corresponding to the current road node.
[0104] After obtaining the intersection surfaces of the target area, the road surfaces and intersection surfaces of the target area can be merged. The road surfaces and intersection surfaces of the target area are merged into the road network surface of the target area, thus obtaining the road network topology information. Since the road network surface is obtained by merging the road surfaces and intersection surfaces, it can represent the topological relationship between roads and intersections in the target area, thereby obtaining the road network topology information. Here, the above fusion process can include at least one of the following: merging, dissolving.
[0105] For example, based on road information, buffer calculations can be performed on road nodes and / or road centerlines to determine point buffers (i.e., node buffers, circles with the maximum width of the associated road as their radius) and / or line buffers (i.e., road buffers, whose shape is a parallel strip polygon with the line as its central axis and a distance of 1 / 2 the road width from the central axis). The road buffers are then spatially intersected and clipped with the point buffers to obtain common areas, which are used as temporary layers. The generated temporary layers are then merged and managed as a single layer. The merged layers are then dissolved to remove duplicate parts between layers, finally obtaining the intersection surface data and generating the intersection surface (interPolygon) layer.
[0106] Here, considering the existence of non-cross-shaped intersections such as T-shaped intersections, or situations where road buffers may not be able to form complete intersection buffers due to calculation errors, the intersection buffers of point buffers and line buffers can be determined. The intersection area is determined based on the intersection buffers: the intersection buffers are overlaid sequentially to generate a new feature layer, and the map features obtained from the overlay analysis are merged and dissolved to obtain the intersection area that meets the requirements.
[0107] For example, when roads intersect and are of the same road class, the superimposed buffer zones of the intersecting lines will form an intersection surface. After trimming, merging, and dissolving, the final intersection will be formed (e.g., Figure 4 Regular intersections formed by roundabouts and straight roads, and Figure 7(c)) The intersections within the entire area can be like Figure 16 As shown, the resulting road network surface can be as follows: Figure 17 As shown.
[0108] Here, during the road map creation process, the intersection (topological) relationship between two roads is already determined, eliminating the need to additionally input the relationship between roads, thus improving the efficiency of road network relationship retrieval. Figure 18 As shown, the bolded line segment is obtained through shortest path retrieval, and this line segment is the shortest path between two points generated based on vector data.
[0109] In this embodiment, by generating intersection area data through the intersection buffer between point buffer and line buffer, and merging and dissolving all line buffers and intersection surfaces to generate a road surface layer, the diversity of information display can be improved.
[0110] In one exemplary embodiment, before performing the following intersection face determination operation on each road node as the current road node, the method further includes:
[0111] S41, perform orientation sorting on the vertices of the node buffer of each road node and the vertices of the road buffer of each road centerline to obtain the initial vertex linked list;
[0112] S42, determine the intersection point of the node buffer of each road node with the road buffer of each road centerline, and insert the determined set of intersection points into the initial vertex list to obtain the target vertex list;
[0113] S43, perform vertex tracing operations repeatedly until all intersections in a set of intersections have been visited, resulting in a linked list of tracing vertices;
[0114] S44. Based on the adjacency relationships between vertices belonging to the node buffer and vertices belonging to the road buffer in each of the tracking vertex chains in a set of tracking vertex chains, a set of target road segments is determined.
[0115] In this embodiment, in order to determine each target road segment, the road surface and the node buffer zone surface can be cut sequentially. The cutting steps can be as follows:
[0116] The vertices of the node buffer of each road node and the vertices of the road buffer of each road centerline are oriented and sorted to obtain an initial vertex list. Here, the vertices of the node buffer can be the road nodes therein or vertices determined based on other rules. The vertices of the road buffer can be the two endpoints of the road centerline therein or vertices determined based on other rules.
[0117] Determine the intersection point of the node buffer of each road node with the road buffer of each road centerline, and insert the determined set of intersection points into the initial vertex list to obtain the target vertex list. Here, the intersection point of the node buffer and the road buffer refers to the common point of the two.
[0118] The following vertex tracking operation is performed repeatedly until all intersections in a set of intersections have been visited, resulting in a set of tracking vertex lists: Select an intersection from the unvisited intersections in the target vertex list to obtain the current starting point, and output the current starting point to the current tracking vertex list. With the current starting point as the first tracked vertex, the vertex tracking operation is repeated based on the preset tracking rules until the current starting point is returned, and the tracked vertices are output to the current tracking vertex list. The preset tracking rules are: if the tracked vertex is an exit point, track the vertices in the node buffer; if the tracked vertex is not an exit point, track the vertices in the road buffer. The set of tracking vertex lists includes the current tracking vertex list.
[0119] Based on the adjacency relationships between vertices belonging to the node buffer and vertices belonging to the road buffer in each of the tracking vertex chains, a set of target road segments is determined.
[0120] For example, when cutting the road surface and the node buffer zone surface sequentially, the cutting steps are as follows:
[0121] Step 1: Sort the vertices of the node buffer and the road buffer by orientation;
[0122] Step 2: Find the intersections of the node buffer and the road buffer, and insert these intersections into the vertex linked list in order;
[0123] Step 3: Create an empty polygon vertex linked list. The polygon vertex linked list is used to store the clipping results.
[0124] Step 4: Select any intersection point as the starting point and output it to the vertex table;
[0125] Step 5: If the intersection is an exit point, start tracking the vertices of the node buffer; otherwise, track the vertices of the road buffer.
[0126] Step 6: Track the road buffer and output the vertices to the resulting polygon vertex table until a new intersection is encountered;
[0127] Step 7: Output the new intersection points to the vertex table of the resulting polygon. If the road buffer was tracked in step 6, then the node buffer is tracked, and vice versa.
[0128] Step 8: Repeat steps 6 and 7 until you return to the starting point, forming a result polygon.
[0129] Step 9: Repeat steps 3 through 8 until all intersections have been visited.
[0130] Here, cutting refers to cutting out the intersection area, with the clockwise direction as the order. Tracking means selecting which object to study. Multilinear vertices are arbitrary convex points, and point buffer vertices are any point on the boundary of the buffer. The ultimate goal is to confirm the intersection point and the point set constructed by the clipping logic.
[0131] After the layers are cut, merge them into a single layer.
[0132] This embodiment improves the accuracy and convenience of data cutting by cutting the road surface and the node buffer surface based on the vertices of the node buffer and the road buffer, as well as their intersection.
[0133] In one exemplary embodiment, after vectorizing the road data to be processed, the method further includes:
[0134] S51, based on the number of lanes and lane width information of each road in the target area, perform parallel geometric operations to obtain the lane guide line layer corresponding to the target area;
[0135] S52, based on the lane guide line layer and the lane width information of each road, generates a lane layer corresponding to the target area.
[0136] In this embodiment, a lane layer can be used to determine whether the location data obtained through the positioning system falls within the corresponding lane. For example, the lane layer can be used to determine whether the accessed location data, such as GPS (Global Positioning System) data or radar data, falls within the corresponding lane, thereby performing further trajectory correction, interpolation, and other operations.
[0137] To generate the lane layer, we can first perform parallel geometry operations based on the number of lanes and lane width information of each road in the target area to obtain the lane guide lines for each lane in each road, thus obtaining the lane guide line layer corresponding to the target area. Then, based on the lane guide line layer and the lane width information of each road, we can generate the lane layer corresponding to the target area. Here, based on the lane width and the relationship between the lane guide lines and the lane boundaries, we can generate each lane in each road.
[0138] For example, based on the number of lanes and lane width information, a parallel-geometry operation is performed to generate a lane guide line layer (laneLine, the center line of each lane), and a lane (lanePolygon) layer is generated based on the lane guide line layer and the lane width.
[0139] It should be noted that the various layers generated in the aforementioned embodiments (road surfaces, intersection surfaces, and road network surfaces can be considered as a type of layer) can be vector layers. The elements within these layers can be processed into different attributes, allowing for richer scene illustrations. More layer definitions also provide more possibilities for static or dynamic displays, showcasing more refined simulation scenes. Since road generation is still based on vector data, it can adapt to other road processing methods without conflicting with other data processing methods, thus expanding its scope of application.
[0140] Meanwhile, by redefining the urban road network layer, in addition to including road centerlines, lane surfaces, lane guide lines, intersection surfaces, and road edge lines, it also adds road surfaces and road network surfaces (which integrate intersection surfaces and road surfaces), enabling more multi-dimensional spatial analysis and mapping.
[0141] Furthermore, through automated processes, multiple layers required for urban space management are industrially produced. Compared to the non-standardized results and low efficiency of manual drawing, this achieves consistency in the results produced by different personnel each time, as well as the high efficiency of automated spatial analysis and processing.
[0142] Furthermore, compared to the pure front-end display method of simulating urban roads in pixels, spatial information systems can be introduced into urban simulation. This allows for data display while also enabling the integration, analysis, and display of third-party data based on spatial information. This avoids the difficulty of integrating data and scenarios with multiple data sources due to the limitations of a purely front-end display system.
[0143] In this embodiment, based on the number and width of lanes in the road, lane guide lines are first generated, and then lane layers are generated. The generated lane layers can be used to verify the positioning data, which can improve the accuracy of target positioning.
[0144] In one exemplary embodiment, after merging the road surface and intersection surface of the target area into the road network surface of the target area, the above method further includes:
[0145] S61, by performing spatial element transformation on the road network surface of the target area, the road edge lines within the target area are extracted to obtain the road edge line layer.
[0146] In this embodiment, the location data obtained by the positioning system can be determined based on the road edge line to determine whether it deviates from the road network surface within the target area. The road edge line can be saved as a road edge line layer. To extract the road edge line, spatial feature transformation can be performed on the road network surface of the target area to extract the road edge line within the target area, thereby obtaining the road edge line layer.
[0147] For example, by merging and dissolving all road buffer zones and intersection surfaces to generate a single road surface layer, and then extracting road boundary layers from this layer using a surface-to-line extraction operation, a relatively smooth road network boundary layer can be obtained for the entire area. Road boundaries can be automatically extracted from the road network surfaces through spatial feature transformation, and the system continuously monitors whether the GPS deviates from the road network layer, thus providing timely alerts or corrections.
[0148] Here, the final generated road segment table and node table for topology calculation, for example, can be used for path planning based on Dijkstra's or A* algorithm based on the road segment table and node table, as well as road surface table, lane guide line table, lane table, road boundary line table, and intersection surface table for urban road simulation display. The urban scene can be freely matched with multiple layers to achieve a better display effect.
[0149] In this embodiment, road edges are extracted by transforming the road network surface into spatial elements. The positioning data is then verified based on the extracted road edges, which can improve the accuracy of target positioning.
[0150] The method for processing road data in this embodiment will be described below with reference to an optional example. This optional example provides a road network topology establishment scheme based on GIS buffer analysis and overlay analysis, which can more accurately determine the positional relationship between roads.
[0151] For the process of determining the road network surface from nodes and road centerlines, combined with Figure 19 The process of processing road data in this optional example may include the following steps:
[0152] Step 1: Generate a node buffer zone with the node as the center and the maximum associated road width as the radius;
[0153] Step 2: Generate a road surface buffer zone based on the road centerline, road width, and upstream / downstream information;
[0154] Step 3: Based on the road grade, perform overlay analysis on the node buffer and the road surface buffer to obtain the intersection buffer;
[0155] Step 4: Merge and fuse the features of the road surface buffer zone and intersection buffer zone to obtain the road network surface of the region;
[0156] Step 5: By performing element conversion on the road network surface of the region, the road network boundary lines within the region are obtained.
[0157] This optional example uses a GIS data processing platform and related development libraries as tools and road data as the data foundation to achieve automated and accurate calibration of road signs, greatly improving the efficiency of road model rendering and demonstration.
[0158] It should be noted that, for the sake of simplicity, the foregoing method embodiments are all described as a series of actions. However, those skilled in the art should understand that this application is not limited to the described order of actions, as some steps may be performed in other orders or simultaneously according to this application. Furthermore, those skilled in the art should also understand that the embodiments described in the specification are preferred embodiments, and the actions and modules involved are not necessarily essential to this application.
[0159] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods according to the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM (Read-Only Memory) / RAM (Random Access Memory), magnetic disk, optical disk), and includes several instructions to cause a terminal device (which may be a mobile phone, computer, server, or network device, etc.) to execute the methods of the various embodiments of this application.
[0160] According to another aspect of the embodiments of this application, a road data processing apparatus for implementing the above-described road data processing method is also provided. Figure 20 This is a structural block diagram of an optional road data processing apparatus according to an embodiment of this application, such as... Figure 20 As shown, the device may include:
[0161] The processing unit 2002 is used to perform vectorization processing on the road data to be processed, to obtain a set of road centerlines and a set of road attributes corresponding to each road centerline in the set of road centerlines, wherein the road data to be processed is the road data corresponding to the target area;
[0162] The first determining unit 2004, connected to the processing unit 2002, is used to determine a set of road nodes based on a set of road attributes corresponding to each road centerline. Each road node in the set of road nodes is the intersection of at least two road centerlines in the set of road centerlines. Each road node is associated with at least two sets of road attributes, and the at least two sets of road attributes associated with each road node correspond one-to-one with the at least two road centerlines that form each road node.
[0163] The first generation unit 2006, connected to the first determination unit 2004, is used to generate a node buffer for each road node based on at least two sets of road attributes associated with each road node, and to generate a road buffer for each road centerline based on a set of road attributes corresponding to each road centerline.
[0164] The analysis unit 2008, connected to the first generation unit 2006, is used to perform overlay and dissolution analysis on the node buffer of each road node and the road buffer of each road centerline to obtain road network topology information. The road network topology information is used to indicate the topological relationship between roads and intersections within the target area. Roads within the target area correspond to a set of road centerlines, and intersections within the target area correspond to a set of road nodes.
[0165] It should be noted that the processing unit 2002 in this embodiment can be used to execute the above step S202, the first determining unit 2004 in this embodiment can be used to execute the above step S204, the first generating unit 2006 in this embodiment can be used to execute the above step S206, and the analysis unit 2008 in this embodiment can be used to execute the above step S208.
[0166] Through the above modules, the road data to be processed is vectorized to obtain a set of road centerlines and a set of road attributes corresponding to each road centerline in the set of road centerlines. The road data to be processed is the road data corresponding to the target area. Based on the set of road attributes corresponding to each road centerline, a set of road nodes is determined. Each road node in the set of road nodes is the intersection of at least two road centerlines in the set of road centerlines. Each road node is associated with at least two sets of road attributes, and the at least two sets of road attributes associated with each road node correspond one-to-one with the at least two road centerlines forming each road node. Based on the at least two sets of road attributes associated with each road node... The system generates a node buffer for each road node based on a set of road attributes, and generates a road buffer for each road centerline based on a set of road attributes corresponding to each road centerline. Overlay and dissolution analyses are performed on the node buffers of each road node and the road buffers of each road centerline to obtain road network topology information. This information indicates the topological relationships between roads and intersections within the target area. Roads within the target area correspond to a set of road centerlines, and intersections within the target area correspond to a set of road nodes. This approach addresses the low data processing efficiency caused by manually drawing road data in related technologies, thus improving overall data processing efficiency.
[0167] In one exemplary embodiment, a set of road attributes corresponding to each road centerline includes the road width corresponding to each road centerline.
[0168] Correspondingly, the first generation unit includes a first determining module, and the first generation unit includes a second generation module, wherein,
[0169] The first determining module is used to determine the maximum road width associated with each road node from at least two road widths associated with each road node; the first generating module is used to generate a node buffer for each road node with each road node as the center and the maximum road width associated with each road node as the radius.
[0170] The second generation module is used to generate road buffer zones for each road centerline by taking each road centerline as the central axis and shifting each road centerline to both sides by half the width of the road corresponding to each road centerline.
[0171] In one exemplary embodiment, a set of road attributes corresponding to each road centerline includes the road class corresponding to each road centerline and the centerline position of each road centerline, and the road surface height of each road centerline is matched with the road class corresponding to each road centerline.
[0172] Correspondingly, the first determining unit includes:
[0173] The second determining module is used to determine a set of candidate nodes based on the centerline position of each road centerline, wherein each candidate node in the set of candidate nodes is associated with at least two road centerlines with the same centerline position;
[0174] The third determination module is used to determine all candidate nodes in a set of candidate nodes that have corresponding road centerlines of the same road level among at least two road centerlines associated with them as a set of road nodes.
[0175] In one exemplary embodiment, a set of road centerlines is divided into a set of target road segments by a set of road nodes, and each target road segment in the set of target road segments is at least a part of a road centerline; the road buffer zone of the set of road centerlines is the road surface of the target area.
[0176] Correspondingly, the analysis unit includes:
[0177] The first execution module is used to perform the following intersection face determination operation on each road node as the current road node to obtain the intersection face of the target area. When performing the intersection face data determination operation, the node buffer of the current road node is the current node buffer, and the road buffers of at least two target road segments connected to the current road node are at least two current road buffers. The module determines the road surface features in the current node buffer that belong to the intersection buffer corresponding to each of the at least two current road buffers, and merges and fuses the road surface features in each current road buffer that belong to the intersection buffer corresponding to each current road buffer to obtain the intersection data corresponding to the current road node. The intersection face of the target area includes the intersection data corresponding to the current road node.
[0178] The second execution module is used to merge the road surface and the intersection surface of the target area into a road network surface of the target area by performing fusion processing on the road surface and the intersection surface of the target area, thereby obtaining road network topology information. The fusion processing includes at least one of the following: merging and dissolving.
[0179] In one exemplary embodiment, the above-described apparatus further includes:
[0180] The sorting unit is used to perform directional sorting of the vertices of the node buffer of each road node and the vertices of the road buffer of each road centerline before performing the following intersection face determination operation with each road node as the current road node, to obtain an initial vertex linked list.
[0181] The first execution unit is used to determine the intersection point of the node buffer of each road node and the road buffer of each road centerline, and insert the determined set of intersection points into the initial vertex linked list to obtain the target vertex linked list;
[0182] The second execution unit is used to repeatedly execute the following vertex tracking operation until all intersections in a set of intersections have been visited, resulting in a set of tracking vertex lists: Select an intersection from the unvisited intersections in the target vertex list to obtain the current starting point, and output the current starting point to the current tracking vertex list; Using the current starting point as the first tracked vertex, repeatedly execute the vertex tracking operation based on preset tracking rules until returning to the current starting point, and output the tracked vertices to the current tracking vertex list. The preset tracking rules are: if the tracked vertex is an exit point, track the vertices in the node buffer; if the tracked vertex is not an exit point, track the vertices in the road buffer. The set of tracking vertex lists includes the current tracking vertex list.
[0183] The second determining unit is used to determine a set of target road segments based on the adjacency relationship between vertices belonging to the node buffer and vertices belonging to the road buffer in each of the tracking vertex chains in a set of tracking vertex chains.
[0184] In one exemplary embodiment, the above-described apparatus further includes:
[0185] The third execution unit is used to extract the road edges within the target area by performing spatial element transformation on the road network surface of the target area after merging the road surface and intersection surface of the target area into the road network surface of the target area, thereby obtaining a road edge layer. The road edge layer is used to determine whether the location data obtained by the positioning system deviates from the road within the road network surface of the target area.
[0186] In one exemplary embodiment, the above-described apparatus further includes:
[0187] The fourth execution unit is used to perform parallel geometric operations based on the number of lanes and lane width information of each road in the target area after the road data to be processed is vectorized, so as to obtain the lane guide line layer corresponding to the target area.
[0188] The second generation unit is used to generate a lane layer corresponding to the target area based on the lane guide line layer and the lane width information of each road. The lane layer is used to determine whether the location data obtained by the positioning system falls within the corresponding lane.
[0189] It should be noted that the examples and application scenarios implemented by the above modules and corresponding steps are the same, but are not limited to the content disclosed in the above embodiments. It should also be noted that the above modules, as part of a device, can operate in environments such as... Figure 1 The hardware environment shown can be implemented through software or hardware, and the hardware environment includes the network environment.
[0190] According to another aspect of the embodiments of this application, a storage medium is also provided, which can be located on a smart device. Optionally, in this embodiment, the storage medium can be used to execute program code for any of the road data processing methods described in the embodiments of this application.
[0191] Optionally, in this embodiment, the storage medium may be located on at least one of the network devices in the network shown in the above embodiment.
[0192] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps:
[0193] S1, the road data to be processed is vectorized to obtain a set of road centerlines and a set of road attributes corresponding to each road centerline in the set of road centerlines. The road data to be processed is the road data corresponding to the target area.
[0194] S2, a set of road nodes is determined based on a set of road attributes corresponding to each road centerline, wherein each road node in the set of road nodes is the intersection of at least two road centerlines in the set of road centerlines, each road node is associated with at least two sets of road attributes, and the at least two sets of road attributes associated with each road node correspond one-to-one with the at least two road centerlines that form each road node.
[0195] S3, based on at least two sets of road attributes associated with each road node, generate a node buffer for each road node, and based on a set of road attributes corresponding to each road centerline, generate a road buffer for each road centerline.
[0196] S4. Overlay and dissolve analyses are performed on the node buffer of each road node and the road buffer of each road centerline to obtain road network topology information. The road network topology information is used to indicate the topological relationship between roads and intersections within the target area. Roads within the target area correspond to a set of road centerlines, and intersections within the target area correspond to a set of road nodes.
[0197] Optionally, specific examples in this embodiment can refer to the examples described in the above embodiments, and will not be repeated in this embodiment.
[0198] Optionally, in this embodiment, the storage medium may include, but is not limited to, various media capable of storing program code, such as USB flash drives, ROMs, RAMs, portable hard drives, magnetic disks, or optical disks.
[0199] According to another aspect of the embodiments of this application, an electronic device for implementing the above-described road data processing method is also provided. The electronic device may be a smart device, a server, a terminal, or a combination thereof.
[0200] Figure 21 This is a structural block diagram of an optional electronic device according to an embodiment of this application, such as... Figure 21 As shown, it includes a processor 2102, a communication interface 2104, a memory 2106, and a communication bus 2108. The processor 2102, communication interface 2104, and memory 2106 communicate with each other via the communication bus 2108.
[0201] Memory 2106 is used to store computer programs;
[0202] When processor 2102 executes a computer program stored in memory 2106, it performs the following steps:
[0203] S1, the road data to be processed is vectorized to obtain a set of road centerlines and a set of road attributes corresponding to each road centerline in the set of road centerlines. The road data to be processed is the road data corresponding to the target area.
[0204] S2, a set of road nodes is determined based on a set of road attributes corresponding to each road centerline, wherein each road node in the set of road nodes is the intersection of at least two road centerlines in the set of road centerlines, each road node is associated with at least two sets of road attributes, and the at least two sets of road attributes associated with each road node correspond one-to-one with the at least two road centerlines that form each road node.
[0205] S3, based on at least two sets of road attributes associated with each road node, generate a node buffer for each road node, and based on a set of road attributes corresponding to each road centerline, generate a road buffer for each road centerline.
[0206] S4. Overlay and dissolve analyses are performed on the node buffer of each road node and the road buffer of each road centerline to obtain road network topology information. The road network topology information is used to indicate the topological relationship between roads and intersections within the target area. Roads within the target area correspond to a set of road centerlines, and intersections within the target area correspond to a set of road nodes.
[0207] Optionally, the communication bus can be a PCI (Peripheral Component Interconnect) bus or an EISA (Extended Industry Standard Architecture) bus, etc. This communication bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 21 The symbol is represented by a single thick line, but this does not indicate that there is only one bus or one type of bus. The communication interface is used for communication between the aforementioned electronic device and other devices.
[0208] The memory may include RAM, or non-volatile memory, such as at least one disk storage device. Optionally, the memory may also be at least one storage device located remotely from the aforementioned processor.
[0209] As an example, the memory 2106 described above may include, but is not limited to, the processing unit 2002, the first determining unit 2004, the first generating unit 2006, and the analysis unit 2008 in the resource information pushing device. Furthermore, it may include, but is not limited to, other module units in the resource information pushing device, which will not be elaborated upon in this example.
[0210] The processors mentioned above can be general-purpose processors, including but not limited to: CPU (Central Processing Unit), NP (Network Processor), etc.; they can also be DSP (Digital Signal Processor), ASIC (Application Specific Integrated Circuit), FPGA (Field-Programmable Gate Array), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.
[0211] Optionally, specific examples in this embodiment can refer to the examples described in the above embodiments, and will not be repeated here.
[0212] Those skilled in the art will understand that Figure 21The structure shown is for illustrative purposes only. The device that implements the above road data processing method can be a terminal device, such as a smartphone (e.g., Android phone, iOS phone), tablet computer, handheld computer, mobile internet device (MID), PAD, etc. Figure 21 This does not limit the structure of the aforementioned electronic device. For example, the electronic device may also include components that are more... Figure 21 The more or fewer components shown (such as network interfaces, display devices, etc.), or having the same Figure 21 The different configurations shown.
[0213] Those skilled in the art will understand that all or part of the steps in the various methods of the above embodiments can be implemented by a program instructing the hardware related to the terminal device. The program can be stored in a computer-readable storage medium, which may include: flash drive, ROM, RAM, disk or optical disk, etc.
[0214] The sequence numbers of the embodiments in this application are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments.
[0215] If the integrated units in the above embodiments are implemented as software functional units and sold or used as independent products, they can be stored in the aforementioned computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause one or more computer devices (which may be personal computers, servers, or network devices, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application.
[0216] In the above embodiments of this application, the descriptions of each embodiment have different focuses. For parts not described in detail in a certain embodiment, please refer to the relevant descriptions of other embodiments.
[0217] In the several embodiments provided in this application, it should be understood that the disclosed client can be implemented in other ways. The device embodiments described above are merely illustrative; for example, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces, indirect coupling or communication connection between units or modules, and may be electrical or other forms.
[0218] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of the solution provided in this embodiment, depending on actual needs.
[0219] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or at least two units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0220] The above description is only a preferred embodiment of this application. It should be noted that for those skilled in the art, several improvements and modifications can be made without departing from the principle of this application, and these improvements and modifications should also be considered within the scope of protection of this application.
Claims
1. A method of processing road data, characterized by, include: The road data to be processed is vectorized to obtain a set of road centerlines and a set of road attributes corresponding to each road centerline in the set of road centerlines, wherein the road data to be processed is the road data corresponding to the target area; A set of road nodes is determined based on a set of road attributes corresponding to each road centerline. Each road node in the set of road nodes is the intersection of at least two road centerlines in the set of road centerlines. Each road node is associated with at least two sets of road attributes, and the at least two sets of road attributes associated with each road node correspond one-to-one with the at least two road centerlines that form each road node. Based on at least two sets of road attributes associated with each road node, a node buffer is generated for each road node, and based on a set of road attributes corresponding to each road centerline, a road buffer is generated for each road centerline. Overlay and dissolution analyses are performed on the node buffer of each road node and the road buffer of each road centerline to obtain road network topology information. The road network topology information is used to indicate the topological relationship between roads and intersections within the target area. The roads within the target area correspond to the set of road centerlines, and the intersections within the target area correspond to the set of road nodes.
2. The method of claim 1, wherein, A set of road attributes corresponding to each road centerline includes the road width corresponding to each road centerline; The step of generating a node buffer for each road node based on at least two sets of road attributes associated with each road node includes: determining the maximum road width associated with each road node from at least two road widths associated with each road node; and generating a node buffer for each road node with each road node as the center and the maximum road width associated with each road node as the radius. The step of generating a road buffer zone for each road centerline based on a set of road attributes corresponding to each road centerline includes: using each road centerline as a central axis and two lines obtained by translating each road centerline to both sides by half the width of the road corresponding to each road centerline as two road lines to generate the road buffer zone for each road centerline.
3. The method of claim 1, wherein, A set of road attributes corresponding to each road centerline includes the road grade corresponding to each road centerline and the centerline position of each road centerline, and the road surface height matching the road grade corresponding to each road centerline and the road surface height corresponding to each road centerline; The process of determining a set of road nodes based on a set of road attributes corresponding to the centerline of each road includes: Based on the centerline position of each road centerline, a set of candidate nodes is determined, wherein each candidate node in the set of candidate nodes is associated with at least two road centerlines with the same centerline position; The group of candidate nodes is defined as the set of road nodes if there are at least two road centerlines associated with it that have corresponding road centerlines of the same road level.
4. The method of claim 1, wherein, The set of road centerlines is divided into a set of target road segments by the set of road nodes, and each target road segment in the set of target road segments is at least a part of a road centerline; the road buffer zone of the set of road centerlines is the road surface of the target area; The method involves performing overlay and dissolution analysis on the node buffer of each road node and the road buffer of each road centerline to obtain road network topology information, including: Each road node is treated as a current road node, and the following intersection face determination operation is performed to obtain the intersection face of the target area. When performing the intersection face data determination operation, the node buffer of the current road node is the current node buffer, and the road buffers of at least two target road segments connected to the current road node are at least two current road buffers. The road surface elements in the current node buffer that belong to the intersecting buffers corresponding to each of the at least two current road buffers, and the road surface elements in each current road buffer that belong to the intersecting buffers corresponding to each of the at least two current road buffers, are merged and fused to obtain the intersection data corresponding to the current road node. The intersection face of the target area includes the intersection data corresponding to the current road node. By performing a fusion process on the road surface and the intersection surface of the target area, the road surface and the intersection surface of the target area are merged into the road network surface of the target area to obtain the road network topology information. The fusion process includes at least one of the following: merging and dissolving.
5. The method of claim 4, wherein, Before performing the following intersection face determination operation by treating each road node as the current road node, the method further includes: The vertices of the node buffer of each road node and the vertices of the road buffer of each road centerline are oriented and sorted to obtain an initial vertex linked list; Determine the intersection point between the node buffer of each road node and the road buffer of each road centerline, and insert the determined set of intersection points into the initial vertex list to obtain the target vertex list; The following vertex tracking operation is performed repeatedly until all intersections in the set of intersections have been visited, resulting in a set of tracking vertex lists: An intersection is selected from the unvisited intersections in the target vertex list to obtain the current starting point, and the current starting point is output to the current tracking vertex list. The vertex tracking operation is repeated based on a preset tracking rule, with the current starting point as the first tracked vertex, until the current starting point is returned to, and the tracked vertices are output to the current tracking vertex list. The preset tracking rule is: if the tracked vertex is an exit point, track the vertices in the node buffer; if the tracked vertex is not an exit point, track the vertices in the road buffer. The set of tracking vertex lists includes the current tracking vertex list. Based on the adjacency relationships between vertices belonging to the node buffer and vertices belonging to the road buffer in each of the set of tracking vertex lists, the set of target road segments is determined.
6. The method according to claim 4, characterized in that, After merging the road surface and intersection surface of the target area into the road network surface of the target area, the method further includes: extracting the road edge lines within the target area by performing spatial element transformation on the road network surface of the target area to obtain a road edge line layer, wherein the road edge line layer is used to determine whether the location data obtained by the positioning system deviates from the road within the road network surface of the target area.
7. The method according to any one of claims 1 to 6, characterized in that, After the road data to be processed is vectorized, the method further includes: Based on the number of lanes and lane width information of each road within the target area, parallel geometric operations are performed to obtain a lane guide line layer corresponding to the target area; Based on the lane guide line layer and the lane width information of each road, a lane layer corresponding to the target area is generated, wherein the lane layer is used to determine whether the location data obtained by the positioning system falls within the corresponding lane.
8. A processing device of road data, characterized by, include: The processing unit is used to perform vectorization processing on the road data to be processed, to obtain a set of road centerlines and a set of road attributes corresponding to each road centerline in the set of road centerlines, wherein the road data to be processed is road data corresponding to the target area; The first determining unit is used to determine a set of road nodes based on a set of road attributes corresponding to each road centerline, wherein each road node in the set of road nodes is the intersection of at least two road centerlines in the set of road centerlines, each road node is associated with at least two sets of road attributes, and the at least two sets of road attributes associated with each road node correspond one-to-one with the at least two road centerlines that form each road node. The first generation unit is used to generate a node buffer for each road node based on at least two sets of road attributes associated with each road node, and to generate a road buffer for each road centerline based on a set of road attributes corresponding to each road centerline. The analysis unit is used to perform overlay and dissolution analysis on the node buffer of each road node and the road buffer of each road centerline to obtain road network topology information. The road network topology information is used to indicate the topological relationship between roads and intersections in the target area. The roads in the target area correspond to the set of road centerlines, and the intersections in the target area correspond to the set of road nodes.
9. A computer readable storage medium, characterized in that, The computer-readable storage medium includes a stored program, wherein the program, when executed, performs the method of any one of claims 1 to 7. 10.An electronic device comprising a memory and a processor, the electronic device characterized by, The memory stores a computer program, and the processor is configured to execute the method of any one of claims 1 to 7 through the computer program.