A method and system for visualizing three-dimensional modeling of underground pipe networks
The proposed method and system for three-dimensional modeling of underground pipe networks address inefficiencies and inaccuracies in existing methods by using centralized data processing and collision detection, resulting in high-precision models and reduced errors in construction projects.
Patent Information
- Application Number
- CN202411597447.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-11
- Publication Date
- 2025-03-14
- Estimated Expiration
- 2044-11-11
AI Technical Summary
Current methods for three-dimensional modeling of underground pipe networks are inefficient, time-consuming, and lack precision, leading to errors in construction projects due to the difficulty in accurately representing complex pipe line distributions.
A method and system for high-precision three-dimensional modeling of underground pipe networks using a centralized algorithm for data processing, three-dimensional collision detection, and data reconnection techniques to create accurate pipe line models and visualize the network effectively.
The method ensures high accuracy in three-dimensional modeling, reducing errors in construction projects and improving efficiency and cost-effectiveness by automating the process and simplifying data visualization.
Smart Images

Figure CN119091063B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of big data three-dimensional modeling of water supply pipe networks, and in particular to a method and system for visualizing three-dimensional modeling of underground pipe networks. Background Art
[0002] Understanding the actual number and spatial distribution of pipelines in urban underground pipe networks is a necessary process for urban management and construction, and is also an effective means to combat disasters and avoid urban pipe network accidents.
[0003] In the prior art, a two-dimensional composition mode is often used to establish a description mechanism for the distribution of pipelines in an underground pipeline network. This composition mode is difficult to effectively describe and express a large amount of pipeline network information, and thus requires a transformation to a composition mode with multi-dimensional display.
[0004] At present, the method for 3D modeling of underground pipe networks is manual or semi-automatic modeling, which is time-consuming and labor-intensive, and has a huge workload. It is difficult to meet the current market requirements in terms of cost, efficiency and standardization. In addition, with the increasing number of underground pipe network pipelines, the underground pipeline distribution information obtained through this 3D modeling method has the technical defect of low fitting accuracy, which often leads to the occurrence of wrong digging and misjudgment of pipelines in construction projects. Summary of the invention
[0005] The technical problem to be solved by the present invention is how to perform high-efficiency and low-loss three-dimensional modeling of underground pipe networks based on existing data, so that the constructed underground pipe network model has high accuracy. In order to overcome the defects of the above prior art, the present invention provides a three-dimensional modeling visualization method and system for underground pipe networks, including a three-dimensional modeling visualization method for underground pipe networks and a three-dimensional modeling visualization system for underground pipe networks.
[0006] The present invention provides a method for visualizing three-dimensional modeling of an underground pipe network, comprising the following steps:
[0007] S1: Obtain information of each pipe point in the area to be modeled and information of all pipelines passing through all pipe points from a two-dimensional underground pipeline database, and connect all pipelines to obtain a directed connected pipeline graph;
[0008] S2: centralizing the coordinates of all pipe points and the endpoints of all pipelines in the directed connected pipeline graph using a centralization algorithm, and performing pipeline geometry correction for three-dimensional collision detection to obtain a directed connected corrected pipeline graph;
[0009] S3: Based on the two-dimensional underground pipeline database, determine the types of pipelines represented by all pipelines in the directed connected corrected pipeline diagram, three-dimensional coordinate parameters of endpoints, cross-sectional size parameters and parameter assignment information, and obtain a pipeline information library;
[0010] S4: Based on the two-dimensional underground pipeline database, three-dimensional coordinates are created, rotated, data stretched, and parameters are assigned to all the pipe points in the directed connected corrected pipeline diagram to obtain a pipe point information library;
[0011] S5: Based on the pipeline information database and the pipe point information database, obtain the pipeline three-dimensional image information of the area to be modeled by breaking and reconnecting the pipe;
[0012] S6: Visualizing the pipeline three-dimensional image information by establishing octree nodes and dividing them into levels.
[0013] The three-dimensional modeling visualization method of underground pipe network disclosed in the present invention constructs a directed connected pipeline diagram with edges representing pipelines through the information of each pipe point in the area to be modeled and the information of all pipelines passing through all pipe points, and then geometrically corrects the directed connected pipeline diagram through the pipeline geometry correction method of three-dimensional collision detection to obtain a directed connected corrected pipeline diagram, ensuring that the three-dimensional modeling has high accuracy and avoiding the occurrence of wrong digging and misjudgment of pipelines in construction projects. Subsequently, the pipeline information library is obtained by retrieving the type of pipelines represented by all pipelines, the three-dimensional coordinate parameters of the endpoints, the cross-sectional size parameters and the parameter assignment information, and the three-dimensional coordinates of the pipe points are created, rotated, data stretched and parameter assigned to obtain the pipe point information library. The three-dimensional image information of the pipeline in the area to be modeled is obtained by using the pipeline information library and the pipe point information library through the broken pipe reconnection method, ensuring the accurate reconstruction of the three-dimensional image, and the accuracy is further improved. Finally, visualization is performed through the establishment of octree nodes and the hierarchical division method to ensure convenient information query. The method disclosed in the present invention has low loss, slows down the computational complexity, thereby reducing the workload, and can better meet the current market requirements in terms of cost, efficiency and standardization.
[0014] In a possible implementation, the process of centralization in step S2 includes the following steps:
[0015] By traversing all the pipe point coordinates of the directed connected pipeline graph and the endpoint coordinates of all pipelines to calculate the three-dimensional bounding box of these coordinates, and obtaining the data center point of the three-dimensional bounding box;
[0016] Subtract the coordinates of the data center point from the coordinates of each pipeline point, the coordinates of each pipeline intersection, and the coordinates of each pipeline endpoint to obtain the corresponding centralized coordinates, and obtain a centralized directed connected pipeline graph;
[0017] Through the above-mentioned form of centralized processing, it is possible to ensure that the amount of computation in subsequent processes is reduced, the computational complexity is reduced, and at the same time ensure the unbiased nature of data processing, which is more consistent with the actual situation.
[0018] In a possible implementation manner, the process of performing pipeline geometry correction for three-dimensional collision detection in step S2 comprises the following steps:
[0019] S201: extracting all pipeline intersections that cannot be matched with pipeline points in the centralized directed connected pipeline graph to obtain a plurality of unmatched intersections;
[0020] S202: taking the first unmatched intersection among the plurality of unmatched intersections as the current intersection according to the first traversal order, and then executing the next step;
[0021] S203: Determine whether the two pipelines forming the current intersection are pipelines of the same type, and whether the current intersection is the endpoint of one of the pipelines;
[0022] If they are pipelines of the same type, and the current intersection is the endpoint of one of the pipelines, the revised pipelines of the two pipelines are respectively regarded as themselves, and then step S211 is executed;
[0023] If they are pipelines of the same type, and the current intersection is not the endpoint of one of the pipelines, then execute step S204;
[0024] If they are not pipelines of the same type, and the current intersection is the endpoint of one of the pipelines, then execute step S208;
[0025] If they are not pipelines of the same type, and the current intersection is not the endpoint of one of the pipelines, then execute step S204;
[0026] S204: Calculating the length of the common perpendicular line of the two pipelines forming the current intersection to obtain the distance between the two pipelines, and determining whether the distance between the two pipelines is greater than the sum of the maximum dimensions of the cross sections of the two pipelines;
[0027] If yes, the revised pipelines of the two pipelines are regarded as themselves respectively, and then step S211 is executed;
[0028] If not, proceed to the next step;
[0029] S205: Obtain the intersection point of the common perpendicular line of the two pipelines at the current intersection and the two pipelines and the midpoint of the intersection point of the common perpendicular line and the two pipelines, and then execute the next step;
[0030] S206: a first correction vector is obtained by taking the direction formed by the intersection of the common perpendicular line and one of the pipelines pointing to the midpoint as the direction and half of the sum of the maximum cross-sectional dimensions of the two pipelines as the size, a point corresponding to the coordinates obtained by adding the central coordinates of the intersection of the common perpendicular line and the pipeline to the first correction vector is taken as the first correction point, a new pipeline formed by taking the starting end point of the pipeline as the starting point and the first correction point as the end point is taken as the first correction pipeline of the pipeline, a new pipeline formed by taking the first correction point as the starting point and the end point of the pipeline as the end point is taken as the second correction pipeline of the pipeline, and then the pipeline is deleted and the next step is executed;
[0031] S207: Take the direction formed by the intersection of the common perpendicular line and the other pipeline pointing to the midpoint as the direction and take half of the sum of the maximum cross-sectional dimensions of the two pipelines as the size to obtain a second correction vector, take the point corresponding to the coordinates obtained by adding the central coordinates of the intersection of the common perpendicular line and the pipeline to the coordinates of the second correction vector as the second correction point, take the starting end point of the pipeline as the starting point and the second correction point as the end point to form a new pipeline as the first correction pipeline of the pipeline, take the second correction point as the starting point and the end point of the pipeline as the end point to form a new pipeline as the second correction pipeline of the pipeline, then delete the pipeline and execute step S211;
[0032] S208: Calculating the length of the common perpendicular line of the two pipelines forming the current intersection to obtain the distance between the two pipelines, and determining whether the distance between the two pipelines is greater than the sum of the maximum cross-sectional dimensions of the two pipelines;
[0033] If yes, then the revised pipelines of the two pipelines are regarded as themselves respectively, and then step S211 is executed;
[0034] If not, proceed to the next step;
[0035] S209: Obtain a pipeline with the current intersection point as its endpoint from among the two pipelines, and regard the revised pipeline of the pipeline as itself, and then execute the next step;
[0036] S210: Obtain a pipeline that does not use the current intersection as its endpoint from the two pipelines, and obtain the intersection of this pipeline and the common perpendicular line of the two pipelines, use the direction formed by the current intersection pointing to the intersection of the common perpendicular line of the pipeline and the two pipelines as the direction and use the sum of the maximum cross-sectional dimensions of the two pipelines as the size to obtain a third correction vector, use the point corresponding to the coordinates obtained by adding the central coordinates of the current intersection to the third correction vector as the third correction point, use the starting endpoint of the pipeline as the starting point and the third correction point as the end point to form a new pipeline as the first correction pipeline of the pipeline, use the third correction point as the starting point and the end point of the pipeline as the end point to form a new pipeline as the second correction pipeline of the pipeline, then delete the pipeline and execute the next step;
[0037] S211: Determine whether a plurality of the unmatched intersections have been traversed;
[0038] If yes, execute step S3;
[0039] If not, the next unmatched intersection is used as the current intersection, and then the process returns to step S203;
[0040] The above-mentioned form of pipeline geometry correction based on three-dimensional collision detection can reduce the data error caused by two-dimensional data, thereby facilitating more accurate collection of pipeline information and pipe point information of the pipeline represented by the pipeline, ensuring high accuracy of three-dimensional modeling, and further avoiding the occurrence of wrong digging and misjudgment of pipelines in construction projects.
[0041] In a possible implementation manner, step S3 includes the following steps:
[0042] S301: determining the first correction pipeline of the directed connected correction pipeline graph according to the proposed starting point, taking the first correction pipeline as the current pipeline, and then executing the next step;
[0043] S302: Obtain the number of cross-sectional dimension parameters of the pipeline before correction corresponding to the current pipeline from the two-dimensional underground pipeline database. If the number is 2, it is determined that the pipeline type represented by the current pipeline is a square tube; if the number is 1, it is determined that the pipeline type represented by the current pipeline is a round tube. After determining the pipeline type represented by the current pipeline, the next step is executed;
[0044] S303: obtaining the starting point coordinates and starting point elevation of the pipeline before correction corresponding to the current pipeline from the two-dimensional underground pipeline database, constructing the three-dimensional coordinates of the starting point of the pipeline represented by the pipeline, obtaining the ending point coordinates and ending point elevation of the pipeline before correction corresponding to the current pipeline from the two-dimensional underground pipeline database, constructing the three-dimensional coordinates of the ending point of the pipeline represented by the pipeline, and then executing the next step;
[0045] S304: Obtaining the diameter size information of the cross section of the pipeline before correction corresponding to the current pipeline from the two-dimensional underground pipeline database, obtaining the pipeline cross section size parameters of the pipeline represented by the pipeline, and then executing the next step;
[0046] S305: Obtaining text attribute content of the pipeline before correction corresponding to the current pipeline from the two-dimensional underground pipeline database, obtaining pipeline parameter assignment information of the pipeline represented by the pipeline, and then executing the next step;
[0047] S306: Determine whether all correction pipelines of the directed connected correction pipeline graph have been traversed;
[0048] If yes, execute step S4;
[0049] If not, the next corrected pipeline is used as the current pipeline, and then the step S302 is executed again;
[0050] This scheme can determine the type of pipelines represented by all pipelines in the directed connected corrected pipeline diagram, the three-dimensional coordinate parameters of the endpoints, the cross-sectional size parameters and the parameter assignment information. Due to the previous geometric correction, the information obtained in the pipeline information library is more accurate and complete.
[0051] In a possible implementation manner, step S4 includes the following steps:
[0052] S401: determining the first pipe point of the directed connected corrected pipeline graph according to the second traversal order, taking the first pipe point as the current pipe point, and then executing the next step;
[0053] S402: Retrieving the coordinates and elevation data of the current pipe point from the two-dimensional underground pipeline database to obtain the three-dimensional coordinates of the current pipe point, and retrieving the coordinate origin information corresponding to the coordinates of the current pipe point, and then executing the next step;
[0054] S403: Determine the number of correction pipelines passing through the current pipeline point in the directed connected correction pipeline graph;
[0055] If the number is equal to 0 or greater than 2, use 0 as the rotation angle and proceed to the next step;
[0056] If the number is 1, the angle between the pipeline direction of the corrected pipeline passing through the current pipeline point and the specified direction is used as the rotation angle, and the next step is executed;
[0057] If the number is 2, the angle between the sum vector of the two corrected pipelines passing through the current pipeline point and the specified direction is used as the rotation angle, and the next step is executed;
[0058] S404: rotating the current pipe point around the coordinate origin corresponding to its coordinates by a rotation angle, obtaining the three-dimensional coordinate information of the rotated pipe point corresponding to the current pipe point, and then executing the next step;
[0059] S405: Determine whether the model size data of the current pipe point is empty;
[0060] If yes, proceed to the next step;
[0061] If not, execute step S407;
[0062] S406: Determine whether the attachment type corresponding to the current pipe point is a fixed model type;
[0063] If yes, the pipe point data of the current pipe point is not stretched, and step S408 is directly executed;
[0064] If not, the cross-sectional dimension parameters of the pipeline represented by the modified pipeline passing through the current pipe point are retrieved, and the model data of the current pipe point is supplemented according to the cross-sectional dimension parameters to stretch the pipe point data of the current pipe point, and then step S408 is executed;
[0065] S407: Determine whether the attachment type corresponding to the current pipe point is a fixed model type;
[0066] If yes, do not stretch the data of the current pipe point, and directly execute the next step;
[0067] If not, the cross-sectional dimension parameters and elevation data of the pipeline represented by the revised pipeline passing through the current pipe point are retrieved, and the model data of the current pipe point is revised according to the cross-sectional dimension parameters and elevation data to stretch the pipe point data of the current pipe point, and then the next step is executed;
[0068] S408: Retrieve the pipe point text attribute content of the current pipe point to assign pipe point parameters to the current pipe point, and then execute the next step;
[0069] S409: Determine whether all the pipeline points of the directed connected corrected pipeline graph have been traversed;
[0070] If yes, execute step S5;
[0071] If not, the next pipe point is used as the current pipe point, and then the process returns to step S402;
[0072] This solution can more accurately realize the three-dimensional coordinate creation, rotation, data stretching and parameter assignment of all pipe points in the directed connected modified pipeline diagram, and the obtained pipe point information database has the advantages of complete and accurate information.
[0073] In a possible implementation manner, step S5 includes the following steps:
[0074] S501: determining the first pipe point from the pipe point information database according to the third traversal order, and taking the pipe point as the currently unconnected pipe point, and then executing the next step;
[0075] S502: Retrieving the associated information of the currently unconnected pipe point according to the pipe point number of the currently unconnected pipe point to determine the number of pipeline endpoints associated with the currently unconnected pipe point;
[0076] If the number is 2, the pipeline information of the two endpoints is retrieved from the pipeline information library, and then the next step is executed; wherein the pipeline information includes the type of the pipeline obtained by the step S3, the three-dimensional coordinate parameters of the endpoints, the cross-sectional size parameters and the parameter assignment information;
[0077] If the number is 3, the pipeline information of the three endpoints is retrieved from the pipeline information library, and then step S504 is executed;
[0078] If the number is greater than 3, the pipeline information of these endpoints is retrieved from the pipeline information library, and then a pipeline connection between the currently unconnected pipe point and these endpoints is established according to the currently retrieved association information, and the pipeline information of the pipeline represented by the connecting pipeline is determined according to the pipeline information of these endpoints, and then step S505 is executed;
[0079] S503: Determine whether the angle between the two endpoints and the angle determined by the currently unconnected pipe point and having the currently unconnected pipe point as the vertex is less than 5 degrees or between 70 degrees and 85 degrees;
[0080] If so, a pipeline connection between the currently unconnected pipe point and the two endpoints is established by a two-on / off pipe reconnection method, and the pipeline information of the pipeline represented by the connecting pipeline is determined according to the pipeline information of the two endpoints, and then step S505 is executed;
[0081] If not, a pipeline connection is established between the currently unconnected pipe point and the two endpoints according to the currently retrieved association information, and the pipeline information of the pipeline represented by the connecting pipeline is determined according to the pipeline information of the two endpoints, and step S505 is executed;
[0082] S504: Determine whether any of the three angles determined by the line connecting the three endpoints and the currently unconnected pipe point and having the currently unconnected pipe point as a common vertex has an angle size less than 5 degrees or between 70 degrees and 85 degrees;
[0083] If so, a pipeline connection between the currently unconnected pipe point and the three endpoints is established by a three-way pipe disconnection and reconnection method, and the pipeline information of the pipeline represented by the connecting pipeline is determined according to the pipeline information of the three endpoints, and then the next step is executed;
[0084] If not, a pipeline connection between the currently unconnected pipe point and the three endpoints is established according to the currently retrieved association information, and the pipeline information of the pipeline represented by the connecting pipeline is determined according to the pipeline information of the three endpoints, and then the next step is executed;
[0085] S505: Determine whether all control points in the control point information database have been traversed;
[0086] If yes, proceed to the next step;
[0087] If not, the next pipe point is taken as the currently unconnected pipe point, and then the step S502 is executed again;
[0088] S506: Retrieve the association information between the currently unconnected endpoints, establish a pipeline connection between the currently unconnected endpoints according to the association information, and determine the pipeline information of the pipeline represented by the connecting pipeline according to the pipeline information of these endpoints, and then execute step S6;
[0089] Through the above-mentioned two-dimensional or three-dimensional broken pipe reconnection method, on the basis of the capacity of the pipeline information library and the pipe point information library, the three-dimensional image information of the pipeline in the area to be modeled is relatively reasonable, and the complexity is controllable, and the three-dimensional information of the pipeline network can be expressed more accurately.
[0090] Another technical solution of the present invention is to provide a three-dimensional modeling and visualization system for underground pipe networks, the system comprising:
[0091] The retrieval module is configured to obtain information of each pipe point in the area to be modeled and information of all pipelines passing through all pipe points from a two-dimensional underground pipeline database, and connect all pipelines to obtain a directed connected pipeline graph in which edges represent pipelines;
[0092] A correction module is configured to centralize the coordinates of all pipe points and the endpoints of all pipelines in the directed connected pipeline graph using a centralization algorithm, and perform pipeline geometry correction for three-dimensional collision detection to obtain a directed connected corrected pipeline graph;
[0093] The pipeline module is configured to determine the types, endpoint three-dimensional coordinate parameters, cross-sectional dimension parameters and parameter assignment information of the pipelines represented by all pipelines in the directed connected corrected pipeline diagram based on the two-dimensional underground pipeline database, and obtain a pipeline information library;
[0094] A pipe point module is configured to create three-dimensional coordinates, rotate, stretch data and assign parameters to all pipe points in the directed connected corrected pipeline diagram based on the two-dimensional underground pipeline database to obtain a pipe point information library;
[0095] A three-dimensional module is configured to obtain the pipeline three-dimensional image information of the area to be modeled by using the pipeline information library and the pipeline point information library through a pipe breaking and reconnecting method;
[0096] A visualization module is configured to visualize the pipeline three-dimensional image information by establishing an octree node and dividing it into levels;
[0097] in,
[0098] The correction module is electrically connected to the retrieval module, the pipeline module is electrically connected to the correction module, the pipe point module is electrically connected to the correction module, the three-dimensional module is electrically connected to the pipeline module and the pipe point module respectively, and the visualization module is electrically connected to the three-dimensional module.
[0099] The system disclosed in the present invention constructs a directed connected pipeline diagram with edges representing pipelines according to the information of each pipe point in the area to be modeled and the information of all pipelines passing through all pipe points by setting a call module; and by setting a correction module, the directed connected pipeline diagram can be geometrically corrected by the pipeline geometric correction method of three-dimensional collision detection to obtain a directed connected corrected pipeline diagram, thereby ensuring that the three-dimensional modeling has high accuracy and avoiding the occurrence of wrong digging and misjudgment of pipelines in construction projects. At the same time, by setting the pipeline module, the type of pipelines represented by all pipelines, the three-dimensional coordinate parameters of the endpoints, the cross-sectional size parameters and the parameter assignment information are retrieved to obtain the pipeline information library, and by setting the pipe point module, the three-dimensional coordinates of the pipe points are created, rotated, data stretched and the parameters are assigned to obtain the pipe point information library, and by setting the three-dimensional module, the three-dimensional image information of the pipelines in the area to be modeled is obtained by using the pipe information library and the pipe point information library in the broken pipe reconnection method, thereby ensuring the accurate reconstruction of the three-dimensional image and improving the accuracy again. Finally, by setting the three-dimensionalization module, visualization is performed in the form of octree node establishment and hierarchical division to ensure convenient information query. The system disclosed in the present invention has the characteristics of fully automated operation, low loss, reduced computational complexity and thus reduced workload, and can better meet current market requirements in terms of cost, efficiency and standardization.
[0100] In a possible implementation, the correction module includes:
[0101] A centralization unit is configured to centralize all pipe point coordinates and endpoint coordinates of all pipelines of the directed connected pipeline graph using a centralization algorithm to obtain a centralized directed connected pipeline graph;
[0102] A geometry correction unit is configured to perform geometry correction on the centralized directed connected pipeline graph by a pipeline geometry correction method of three-dimensional collision detection to obtain the directed connected corrected pipeline graph;
[0103] in,
[0104] The centralization unit is electrically connected to the retrieval module, the geometry correction unit is electrically connected to the centralization unit, and the pipeline module and the pipe point module are both electrically connected to the geometry correction unit. BRIEF DESCRIPTION OF THE DRAWINGS
[0105] Figure 1 A flowchart of a method for visualizing three-dimensional modeling of an underground pipe network is disclosed for Example 1 of the present application;
[0106] Figure 2 This is a flow chart of pipeline geometry correction for three-dimensional collision detection in step S2 disclosed in the first embodiment of the present application;
[0107] Figure 3 This is a schematic diagram of two skew pipelines in Example 1 of the present application;
[0108] Figure 4 This is a schematic diagram of orthogonal projection of two non-planar pipelines in Example 1 of the present application;
[0109] Figure 5 This is a schematic diagram of a geometric correction method for two skew pipelines in Example 1 of the present application;
[0110] Figure 6 This is a schematic diagram of orthogonal projection of two non-planar pipelines in which the intersection of the projection lines in the first embodiment of the present application is the intersection of one of the pipelines;
[0111] Figure 7 This is a schematic diagram of another geometric correction method for two skew pipelines in Example 1 of the present application;
[0112] Figure 8 This is a flowchart corresponding to step S3 disclosed in Embodiment 1 of the present application;
[0113] Fig. 9 This is a flowchart corresponding to step S4 disclosed in Embodiment 1 of the present application;
[0114] Fig.10 This is a flowchart corresponding to step S5 disclosed in Embodiment 1 of the present application;
[0115] Fig.11 This is a schematic diagram of the structure of an underground pipe network three-dimensional modeling visualization system disclosed in Example 2 of the present application;
[0116] Fig.12 It is a model image obtained by an underground pipe network three-dimensional modeling visualization system disclosed in Example 2 of the present application. DETAILED DESCRIPTION
[0117] First, those skilled in the art should understand that these implementations are only used to explain the technical principles of the embodiments of the present application, and are not intended to limit the protection scope of the embodiments of the present application. Those skilled in the art can make adjustments to them as needed to adapt to specific application scenarios.
[0118] In the description of the embodiments of the present application, it should be noted that, unless otherwise clearly specified and limited, the terms "electrical connection" and "electrical connection relationship" should be understood in a broad sense, that is, referring to a connection method with an electrical relationship, for example, it can be a circuit connection through a conductive wire, or it can be an electrical connection through a radio signal channel (channel), or a combination of the two. In addition, "electrical connection" and "electrical connection relationship" can be based on mechanical connection (such as a conductive wire set in a connecting key); it can be a direct connection or an indirect connection through an intermediate medium. For those of ordinary skill in the art, the specific meanings of the above terms in the embodiments of the present application can be understood according to specific circumstances.
[0119] In addition, unless otherwise clearly specified and limited, the term "pipeline diagram" should be understood as a connected graph consisting of nodes and edges, that is, according to the definition of (graph theory), the nodes are the endpoints or pipe points of the pipeline, and the edges are the pipelines. The "pipeline diagram" can be expressed not only in the form of a structural diagram, but also in mathematical language (such as matrix form or tensor form).
[0120] In the embodiments of the present application, unless otherwise clearly specified and limited, a first feature being "above" or "below" a second feature may mean that the first and second features are in direct contact, or the first and second features are in indirect contact through an intermediate medium. Moreover, a first feature being "above", "above" or "above" a second feature may mean that the first feature is directly above or obliquely above the second feature, or simply means that the first feature is higher in level than the second feature. A first feature being "below", "below" or "below" a second feature may mean that the first feature is directly below or obliquely below the second feature, or simply means that the first feature is lower in level than the second feature.
[0121] Two embodiments will be used below, and the present application will be further described in detail in conjunction with the accompanying drawings and specific embodiments.
[0122] Embodiment 1:
[0123] The database used in the embodiment of the present application includes a pipeline model library, a pipe point model library and a two-dimensional underground pipeline database.
[0124] The pipeline model library is used to retrieve relevant information about pipelines, which records a variety of pipeline models. Pipeline models are template models of different types of pipelines, including drainage, water supply, power supply, communication, and gas. The information in the template model includes geometric data (such as pipeline length, endpoint coordinates, cross-sectional dimensions, inner and outer diameters), material, color, and pipeline type. The pipeline type includes square tubes and round tubes. The information in the template model can be set dynamically.
[0125] The pipe point model library is used to retrieve relevant information about pipe points, including fixed pipe point models and adjustable pipe point template models. Among them, fixed pipe point models are objects with relatively fixed sizes in real life, including street lights, transformers, traffic lights, and fire hydrants. Adjustable pipe point template models are objects with simple structures in real life, although their sizes cannot be unified, including round wells, square wells, rain grates, sewage grates, manholes, and handholes.
[0126] The 2D underground pipeline database stores multiple types of 2D underground pipeline network data, which are divided into drainage, water supply, power supply, communication and gas according to their types. Each type of underground pipeline network data contains pipeline data and pipe point data.
[0127] The pipeline data includes the pipeline starting point coordinates, pipeline end point coordinates, pipeline number, pipeline starting point number, pipeline end point number, pipeline starting point elevation, pipeline end point elevation, pipeline starting point buried depth, pipeline end point buried depth, pipeline diameter, pipeline type and other pipeline attributes. The pipe point data includes pipe point coordinates, pipe point number, pipe point accessory type, pipe point elevation, pipe point diameter, pipe point buried depth and other pipe point attributes.
[0128] See also Figure 1 As shown, the embodiment of the present application discloses a method for visualizing three-dimensional modeling of an underground pipe network. Figure 1 is a flow chart of the method, the method comprising the following steps:
[0129] S1: Obtain information of each pipe point in the area to be modeled and information of all pipelines passing through all pipe points from a two-dimensional underground pipeline database, and connect all pipelines according to the pipeline network structure information of the area to be modeled to obtain a directed connected pipeline graph in which each edge represents a pipeline.
[0130] In the two-dimensional underground pipeline database, the information of the pipe point is the pipe point data, and the pipeline information is the pipeline data. According to national regulations, different pipe points have different pipe point numbers, and the same is true for pipelines. Due to the requirements of the pipeline network structure, the pipeline numbers of all pipelines passing through a certain pipe point must be associated with the pipe point number of the pipe point. Therefore, this association is used in combination with the pipeline network structure of the area to be modeled to obtain a directed connected pipeline diagram.
[0131] S2: Centralize the coordinates of all pipe points and endpoints of all pipelines in the directed connected pipeline graph using a centralization algorithm, and perform pipeline geometry correction for three-dimensional collision detection to obtain a directed connected corrected pipeline graph.
[0132] The centralization process in step S2 of the present embodiment includes the following steps: first, all the pipe point coordinates and the endpoint coordinates of all pipelines in the directed connected pipeline graph are traversed to calculate the three-dimensional bounding box of these coordinates, and the data center point of the three-dimensional bounding box is obtained; then, the coordinates of each pipe point, the coordinates of each pipeline intersection and the endpoint coordinates of each pipeline are subtracted from the coordinates of the data center point to obtain the corresponding centralized coordinates, and the centralized directed connected pipeline graph is obtained.
[0133] See also Figure 2 As shown, the process of pipeline geometry correction for three-dimensional collision detection in step S2 of this embodiment includes the following steps:
[0134] S201: extracting all pipeline intersections that cannot be matched with pipeline points in the centralized directed connected pipeline graph to obtain multiple unmatched intersections.
[0135] like Figure 3 and Figure 4 As shown in the figure, pipelines with pipeline intersections refer to two non-parallel pipelines in different planes that are orthogonally projected onto a plane that passes through one of the pipelines and is perpendicular to the vertical direction. The projection lines of the two pipelines are intersecting line segments. The intersection point is the intersection of the intersection of the projection lines on one of the pipelines. If the projection corresponding point (i.e., the intersection point) is not a pipe point, it is considered that the point cannot be matched with the pipe point.
[0136] Figure 3 The non-planar line segments AB and CD in the figure represent two non-parallel pipelines in different planes. Figure 4 The plane in is a plane passing through pipeline AB and perpendicular to the vertical direction, and the dotted line segment For pipelines in plane Orthogonal projection on It intersects with pipeline AB at point M, which is the intersection point. Point M is not the endpoint of any pipeline.
[0137] S202: taking the first unmatched intersection among the multiple unmatched intersections as the current intersection according to the first traversal order, and then executing the next step.
[0138] S203: Determine whether the two pipelines forming the current intersection are pipelines of the same type, and whether the current intersection is the endpoint of one of the pipelines;
[0139] If they are pipelines of the same type, and the current intersection is the endpoint of one of the pipelines, the revised pipelines of the two pipelines are respectively regarded as themselves, and then step S211 is executed;
[0140] If they are pipelines of the same type, and the current intersection is not the endpoint of one of the pipelines, then execute step S204;
[0141] If they are not pipelines of the same type, and the current intersection is the endpoint of one of the pipelines, then execute step S208;
[0142] If they are not pipelines of the same type, and the current intersection is not the endpoint of one of the pipelines, step S204 is executed.
[0143] S204: Calculating the length of the common perpendicular line of the two pipelines forming the current intersection to obtain the distance between the two pipelines, and determining whether the distance between the two pipelines is greater than the sum of the maximum dimensions of the cross sections of the two pipelines;
[0144] If yes, the revised pipelines of the two pipelines are regarded as themselves respectively, and then step S211 is executed;
[0145] If not, proceed to the next step.
[0146] S205: Obtain the intersection point of the common perpendicular line of the two pipelines at the current intersection and the two pipelines and the midpoint of the intersection point of the common perpendicular line and the two pipelines, and then execute the next step.
[0147] Figure 3 The line segment PQ in is the common perpendicular line of pipelines AB and CD, point P is the intersection point of the common perpendicular line and pipeline AB, point Q is the intersection point of the common perpendicular line and pipeline CD, and point O is the midpoint of point P and point Q.
[0148] S206: Take the direction formed by the intersection of the common perpendicular line and one of the pipelines pointing to the midpoint as the direction and take half of the sum of the maximum cross-sectional dimensions of the two pipelines as the size to obtain the first correction vector, take the point corresponding to the coordinates obtained by adding the central coordinates of the intersection of the common perpendicular line and the pipeline to the first correction vector as the first correction point, take the starting end point of the pipeline as the starting point and the first correction point as the end point to form a new pipeline as the first correction pipeline of the pipeline, take the first correction point as the starting point and the end point of the pipeline as the end point to form a new pipeline as the second correction pipeline of the pipeline, then delete the pipeline and execute the next step.
[0149] like Figure 5As shown, for pipeline AB, point A is the starting point and point B is the end point. It is assumed that the pipelines represented by pipeline AB and pipeline CD are both circular pipelines. In this case, the cross section is a circular surface, and its radius is the cross-sectional size. After inputting the parameters, the first correction point is point E, and then, line segment AE and line segment EB are the two correction pipelines of pipeline AB. Pipeline AB in the figure has been deleted.
[0150] S207: Take the direction formed by the intersection of the common perpendicular line and the other pipeline pointing to the midpoint as the direction and take half of the sum of the maximum cross-sectional dimensions of the two pipelines as the size to obtain the second correction vector, take the point corresponding to the coordinates obtained by adding the central coordinates of the intersection of the common perpendicular line and the pipeline to the second correction vector as the second correction point, take the starting end point of the pipeline as the starting point and the second correction point as the end point to form a new pipeline as the first correction pipeline of the pipeline, take the second correction point as the starting point and the end point of the pipeline as the end point to form a new pipeline as the second correction pipeline of the pipeline, then delete the pipeline and execute step S211.
[0151] like Figure 5 As shown, for pipeline CD, point C is the starting point and point D is the end point. After inputting the parameters, the second correction point is point F, and then line segment CF and line segment FD are the two correction pipelines of pipeline CD. Pipeline CD in the figure has been deleted.
[0152] S208: Calculating the length of the common perpendicular line of the two pipelines forming the current intersection to obtain the distance between the two pipelines, and determining whether the distance between the two pipelines is greater than the sum of the maximum cross-sectional dimensions of the two pipelines;
[0153] If yes, the revised pipelines of the two pipelines are regarded as themselves respectively, and then step S211 is executed;
[0154] If not, proceed to the next step.
[0155] S209: Obtain the pipeline with the current intersection point as its endpoint in the two pipelines, regard the revised pipeline of the pipeline as itself, and then execute the next step.
[0156] S210: Obtain a pipeline from the two pipelines that does not use the current intersection as its endpoint, and obtain the intersection of this pipeline and the common perpendicular line of the two pipelines, use the direction formed by the current intersection point pointing to the intersection of this pipeline and the common perpendicular line of the two pipelines as the direction and use the sum of the maximum cross-sectional dimensions of the two pipelines as the size to obtain a third correction vector, use the point corresponding to the coordinates obtained by adding the central coordinates of the current intersection to the third correction vector as the third correction point, use the starting endpoint of the pipeline as the starting point and the third correction point as the end point to form a new pipeline as the first correction pipeline of the pipeline, use the third correction point as the starting point and the end point of the pipeline as the end point to form a new pipeline as the second correction pipeline of the pipeline, then delete the pipeline and execute the next step.
[0157] See also Figure 6 and Figure 7 As shown, pipeline HI and pipeline JK are in the plane passing through pipeline HI. The orthogonal projections on are intersecting line segments, and the intersection point is point H. Figure 6 The dashed line segment HR in the figure is the pipeline JK in the plane Orthographic projection on . Figure 7 As shown in the figure, for pipeline HI, point H is the starting point, point I is the end point, and the correction pipeline of pipeline HI is itself. For pipeline JK, after the parameters are input, the third correction point is point S, and then the line segment JS and the line segment SK are the two correction pipelines of pipeline JK. Pipeline JK in the figure has been deleted.
[0158] S211: Determine whether a plurality of the unmatched intersections have been traversed;
[0159] If yes, execute step S3;
[0160] If not, the next unmatched intersection is used as the current intersection, and then the process returns to execute step S203.
[0161] S3: Based on the two-dimensional underground pipeline database, determine the types of pipelines represented by all pipelines in the directed connected modified pipeline diagram, the three-dimensional coordinate parameters of the endpoints, the cross-sectional size parameters and the parameter assignment information, and obtain the pipeline information library.
[0162] See also Figure 8 As shown, in this embodiment, step S3 includes the following steps:
[0163] S301: Determine the first correction pipeline of the directed connected correction pipeline graph according to the proposed starting point, take the first correction pipeline as the current pipeline, and then execute the next step.
[0164] S302: Obtain the number of cross-sectional dimension parameters of the pipeline before correction corresponding to the current pipeline from the two-dimensional underground pipeline database. If the number is 2, it is determined that the pipeline type represented by the current pipeline is a square tube; if the number is 1, it is determined that the pipeline type represented by the current pipeline is a round tube. After determining the pipeline type represented by the current pipeline, execute the next step.
[0165] S303: Obtain the starting point coordinates and starting point elevation of the pipeline before correction corresponding to the current pipeline from the two-dimensional underground pipeline database, construct the three-dimensional coordinates of the pipeline starting point of the pipeline represented by the pipeline, obtain the ending point coordinates and ending point elevation of the pipeline before correction corresponding to the current pipeline from the two-dimensional underground pipeline database, construct the three-dimensional coordinates of the pipeline ending point of the pipeline represented by the pipeline, and then execute the next step;
[0166] S304: Obtain the diameter dimension information of the cross section of the pipeline before correction corresponding to the current pipeline from the two-dimensional underground pipeline database, obtain the pipeline cross section dimension parameters of the pipeline represented by the pipeline, and then execute the next step.
[0167] S305: Obtain the text attribute content of the pipeline before correction corresponding to the current pipeline from the two-dimensional underground pipeline database, obtain the pipeline parameter assignment information of the pipeline represented by the pipeline, and then execute the next step.
[0168] S306: Determine whether all correction pipelines of the directed connected correction pipeline graph have been traversed;
[0169] If yes, the pipeline information database has been established and step S4 can be executed;
[0170] If not, the next revised pipeline is used as the current pipeline, and then the process returns to step S302.
[0171] S4: Based on the two-dimensional underground pipeline database, three-dimensional coordinates are created, rotated, data stretched, and parameters are assigned for all pipe points in the directed connected modified pipeline diagram to obtain a pipe point information library.
[0172] See also Fig. 9 As shown, in this embodiment, step S4 includes the following steps:
[0173] S401: Determine the first pipe point of the directed connected corrected pipeline graph according to the second traversal order, take the first pipe point as the current pipe point, and then execute the next step.
[0174] S402: retrieve the coordinates and elevation data of the current pipe point from the two-dimensional underground pipeline database to obtain the three-dimensional coordinates of the current pipe point, retrieve the coordinate origin information corresponding to the coordinates of the current pipe point, and then execute the next step.
[0175] S403: Determine the number of correction pipelines passing through the current pipe point in the directed connected correction pipeline graph;
[0176] If the number is equal to 0 or greater than 2, use 0 as the rotation angle and proceed to the next step;
[0177] If the number is 1, the angle between the pipeline direction of the corrected pipeline passing through the current pipeline point and the specified direction is used as the rotation angle. In this embodiment, the specified direction is the north direction. After obtaining the rotation angle, the next step is executed;
[0178] If the number is 2, the angle between the sum vector of the two corrected pipelines passing through the current pipeline point and the specified direction is used as the rotation angle to execute the next step.
[0179] S404: Rotate the current tube point around the coordinate origin corresponding to its coordinates by an angle. The rotation direction can be determined according to its coordinates. For example, if the first coordinate is the largest, it rotates in a clockwise direction, otherwise it rotates in a counterclockwise direction. Obtain the three-dimensional coordinate information of the rotated tube point corresponding to the current tube point, and then execute the next step.
[0180] S405: Determine whether the model size data of the current pipe point is empty;
[0181] If yes, proceed to the next step;
[0182] If not, execute step S407.
[0183] S406: Determine whether the attachment type corresponding to the current pipe point is a fixed model type;
[0184] If yes, the pipe point data of the current pipe point is not stretched, and step S408 is directly executed;
[0185] If not, the cross-sectional dimension parameters of the pipeline represented by the modified pipeline passing through the current pipe point are retrieved, and the model data of the current pipe point is supplemented according to the cross-sectional dimension parameters to stretch the pipe point data of the current pipe point, and then step S408 is executed.
[0186] S407: Determine whether the attachment type corresponding to the current pipe point is a fixed model type;
[0187] If yes, do not stretch the data of the current pipe point, and directly execute the next step;
[0188] If not, retrieve the cross-sectional dimension parameters and elevation data of the pipeline represented by the revised pipeline passing through the current pipe point, revise the model data of the current pipe point according to the cross-sectional dimension parameters and elevation data to stretch the pipe point data of the current pipe point, and then execute the next step.
[0189] S408: Retrieve the pipe point text attribute content of the current pipe point to assign pipe point parameters to the current pipe point, and then execute the next step.
[0190] S409: Determine whether all the pipe points of the directed connected corrected pipeline graph have been traversed;
[0191] If yes, the management point information database has been established and step S5 can be executed;
[0192] If not, the next pipe point is used as the current pipe point, and the process returns to step S402.
[0193] S5: Obtain the pipeline three-dimensional image information of the area to be modeled by using the pipeline information library and the pipe point information library through the pipe breaking and reconnecting method.
[0194] See also Fig.10 As shown, in this embodiment, step S5 includes the following steps:
[0195] S501: Determine the first pipe point from the pipe point information library according to the third traversal order, and use the pipe point as the currently unconnected pipe point, and then execute the next step.
[0196] S502: Retrieving the associated information of the currently unconnected pipe point according to the pipe point number of the currently unconnected pipe point, that is, determining which endpoints the pipe point is connected to, so as to determine the number of pipeline endpoints associated with the currently unconnected pipe point;
[0197] If the number is 2, the pipeline information of the two endpoints is retrieved from the pipeline information library, and then the next step is executed; wherein the pipeline information includes the type of the pipeline obtained in step S3, the three-dimensional coordinate parameters of the endpoints, the cross-sectional size parameters and the parameter assignment information;
[0198] If the number is 3, the pipeline information of the three endpoints is retrieved from the pipeline information library, and then step S504 is executed;
[0199] If the number is greater than 3, the pipeline information of these endpoints is retrieved from the pipeline information library, and then a pipeline connection is established between the currently unconnected pipe point and these endpoints based on the currently retrieved association information, and the pipeline information of the pipeline represented by the connecting pipeline is determined based on the pipeline information of these endpoints, and then step S505 is executed.
[0200] S503: Determine whether the angle between the two endpoints and the angle determined by the currently unconnected pipe point and having the currently unconnected pipe point as the vertex is less than 5 degrees or between 70 degrees and 85 degrees;
[0201] If so, a pipeline connection between the currently unconnected pipe point and the two endpoints is established by a two-on / off pipe reconnection method, and the pipeline information of the pipeline represented by the connecting pipeline is determined according to the pipeline information of the two endpoints, and then step S505 is executed;
[0202] If not, a pipeline connection between the currently unconnected pipe point and the two endpoints is established according to the currently retrieved association information, and the pipeline information of the pipeline represented by the connecting pipeline is determined according to the pipeline information of the two endpoints, and then step S505 is executed.
[0203] The process of establishing a pipeline connection between the current unconnected pipe point and the two endpoints by the two-way disconnection and reconnection method can be as follows: Let us assume that the two endpoints are point A and point B, the previous unconnected pipe point is point O, and the two endpoints are reset, which may be called point C and point D. Mathematical operations are used to solve the problem so that the angles of ∠C0D, ∠ACO and ∠BDO are not less than 5 degrees or between 70 and 85 degrees, and then the positions of point C and point D are determined, and AC, CO, OD and DB are all pipelines.
[0204] S504: Determine whether any of the three angles determined by the line connecting the three endpoints and the currently unconnected pipe point and having the currently unconnected pipe point as a common vertex has an angle size less than 5 degrees or between 70 degrees and 85 degrees;
[0205] If so, a pipeline connection between the currently unconnected pipe point and the three endpoints is established by means of a three-way pipe disconnection and reconnection method, and the pipeline information of the pipeline represented by the connecting pipeline is determined according to the pipeline information of the three endpoints, and then the next step is executed;
[0206] If not, a pipeline connection between the currently unconnected pipe point and the three endpoints is established according to the currently retrieved association information, and the pipeline information of the pipeline represented by the connecting pipeline is determined according to the pipeline information of the three endpoints, and then the next step is executed.
[0207] The method of establishing the pipeline connection between the current unconnected pipe point and the three endpoints by the three-way pipe disconnection and reconnection method is as follows: let us assume that the three endpoints are point A, point B and point C, the previous unconnected pipe point is point O, and reset the three endpoints, which may be called point D, point E and point F. Through mathematical calculation, solve the problem so that the angles of ∠A0B, ∠AOC, ∠BOC, ∠ADO, ∠BEO and ∠CFO are not less than 5 degrees or between 70 degrees and 85 degrees, and then determine the positions of point D, point E and point F, and let AD, DO, OE, EB, CF and FO be pipelines.
[0208] S505: Determine whether all control points in the control point information database have been traversed;
[0209] If yes, proceed to the next step;
[0210] If not, the next pipe point is taken as the currently unconnected pipe point, and the process returns to step S502.
[0211] S506: Retrieve the association information between the currently unconnected endpoints, that is, retrieve the pipeline connection status between each unconnected endpoint, establish the pipeline connection between the currently unconnected endpoints based on this association information, and determine the pipeline information of the pipeline represented by the connecting pipeline based on the pipeline information of these endpoints, and then execute step S6.
[0212] S6: Visualizing the pipeline three-dimensional image information by means of octree hierarchical division.
[0213] The octree is a recursive tree structure, each internal node has eight child nodes, each of which represents a sub-region of the original space volume. The octree partitioning and establishment of the tree node tree is to divide the pipeline three-dimensional image information obtained in step S5 into regular sub-volumes, each of which stores one or more three-dimensional pipeline objects or three-dimensional pipe point objects. This display technology is an existing technology and will not be described in detail here.
[0214] The three-dimensional modeling visualization method of underground pipe network disclosed in this embodiment constructs a directed connected pipeline diagram with edges representing pipelines through the obtained information of each pipe point in the area to be modeled and the information of all pipelines passing through all pipe points, and then geometrically corrects the directed connected pipeline diagram through the pipeline geometry correction method of three-dimensional collision detection to obtain a directed connected corrected pipeline diagram, ensuring that the three-dimensional modeling has high accuracy and avoiding the occurrence of wrong digging and misjudgment of pipelines in construction projects. Subsequently, the pipeline information library is obtained by retrieving the type of pipelines represented by all pipelines, the three-dimensional coordinate parameters of the endpoints, the cross-sectional size parameters and the parameter assignment information, and the three-dimensional coordinates of the pipe points are created, rotated, data stretched and parameter assigned to obtain the pipe point information library. The three-dimensional image information of the pipeline in the area to be modeled is obtained by using the pipeline information library and the pipe point information library through the broken pipe reconnection method, which ensures the accurate reconstruction of the three-dimensional image and improves the accuracy again. Finally, visualization is performed through the establishment of octree nodes and the hierarchical division method to ensure convenient information query. The method disclosed in the present invention has low loss, reduces the computational complexity and thus reduces the workload, and can better meet the current market requirements in terms of cost, efficiency and standardization.
[0215] Embodiment 2:
[0216] See also Fig.11 As shown, this embodiment discloses a three-dimensional modeling and visualization system for an underground pipe network, the system comprising a retrieval module, a correction module, a pipeline module, a pipe point module, a three-dimensional module and a visualization module, wherein the correction module is electrically connected to the retrieval module, the pipeline module is electrically connected to the correction module, the pipe point module is electrically connected to the correction module, the three-dimensional module is electrically connected to the pipeline module and the pipe point module respectively, and the visualization module is electrically connected to the three-dimensional module.
[0217] In the system, the retrieval module is configured to obtain information of each pipe point in the area to be modeled and information of all pipelines passing through all pipe points from a two-dimensional underground pipeline database, and connect all pipelines to obtain a directed connected pipeline diagram with edges representing pipelines; the correction module is configured to centralize the coordinates of all pipe points and the end point coordinates of all pipelines in the directed connected pipeline diagram using a centralization algorithm, and perform pipeline geometry correction for three-dimensional collision detection to obtain a directed connected corrected pipeline diagram; the pipeline module is configured to determine the type of pipelines represented by all pipelines in the directed connected corrected pipeline diagram based on the two-dimensional underground pipeline database, the three-dimensional coordinate parameters of the end points, the cross-sectional size parameters and the parameter assignment information, and obtain a pipeline information library; the pipe point module is configured to create three-dimensional coordinates, rotate, stretch data and assign parameters for all pipe points in the directed connected corrected pipeline diagram based on the two-dimensional underground pipeline database, and obtain a pipe point information library; the three-dimensional module is configured to obtain the three-dimensional image information of the pipelines in the area to be modeled by using the pipeline information library and the pipe point information library through the broken pipe reconnection method; the visualization module is configured to visualize the three-dimensional image information of the pipelines through the establishment of octree nodes and the hierarchical division method.
[0218] Please continue to see Fig.11 As shown, in this embodiment, the correction module includes a centralization unit and a geometric correction unit, wherein the centralization unit is electrically connected to the retrieval module, the geometric correction unit is electrically connected to the centralization unit, and the pipeline module and the pipe point module are both electrically connected to the geometric correction unit. The centralization unit is configured to centralize all pipe point coordinates and endpoint coordinates of all pipelines of the directed connected pipeline graph by a centralization algorithm to obtain a centralized directed connected pipeline graph; the geometric correction unit is configured to perform geometric correction on the centralized directed connected pipeline graph by a pipeline geometric correction method of three-dimensional collision detection to obtain the directed connected corrected pipeline graph.
[0219] Fig.12 It is a part of the model image of a certain underground pipeline area obtained by the system, and it is divided into the top layer, middle layer and bottom layer in order from top to bottom. The top layer is the pipeline network closest to the ground. The data of this part is simplified in plane based on the establishment of octree nodes and hierarchical division. The three-dimensional data is simplified into surface data. There are only pipelines but no pipe points. The surface data is created by connecting the two end lines of the pipeline with the diameter as the width. The middle layer is located below the top layer. For the layer simplification of the middle layer, the pipeline data is three-dimensional quadrangular prism data, there is a pipe point model, and the pipe point model is simplified. The quadrangular prism data is connected by connecting the two end lines of the pipeline with the diameter as the width and height. The bottom layer is the lowest layer, and its pipeline data is ordinary octagonal prism data, and the pipeline model is not simplified.
[0220] The system disclosed in this embodiment, by setting a call module, constructs a directed connected pipeline diagram with edges representing pipelines according to the information of each pipe point in the area to be modeled and the information of all pipelines passing through all pipe points; by setting a correction module, the directed connected pipeline diagram can be geometrically corrected by the pipeline geometric correction method of three-dimensional collision detection to obtain a directed connected corrected pipeline diagram, ensuring that the three-dimensional modeling has high accuracy, avoiding the occurrence of wrong digging and misjudgment of pipelines in construction projects. At the same time, by setting the pipeline module, the type of pipeline represented by all pipelines, the three-dimensional coordinate parameters of the endpoints, the cross-sectional size parameters and the parameter assignment information are retrieved to obtain the pipeline information library, and at the same time, by setting the pipe point module, the three-dimensional coordinates of the pipe points are created, rotated, data stretched and parameter assigned to obtain the pipe point information library, and by setting the three-dimensional module, the three-dimensional image information of the pipeline in the area to be modeled is obtained by using the pipe information library and the pipe point information library in the way of breaking and reconnecting the pipe, which ensures the accurate reconstruction of the three-dimensional image and improves the accuracy again. Finally, by setting the three-dimensional module, visualization is performed in the form of octree node establishment and hierarchical division to ensure convenient information query. The system disclosed in the present invention has the characteristics of fully automated operation, low loss, reduced computational complexity and thus reduced workload, and can better meet current market requirements in terms of cost, efficiency and standardization.
[0221] In the description of the embodiments of the present application, it should be noted that in the description of the present application, terms such as "inside" and "outside" indicating directions or positional relationships are based on the directions or positional relationships shown in the drawings. This is only for the convenience of description, and does not indicate or imply that the device or component must have a specific orientation, be constructed and operated in a specific orientation. Therefore, it cannot be understood as a limitation on the present application.
[0222] In the description of the present application, the description with reference to the terms "one embodiment", "some embodiments", "in the present embodiment", "specific example", or "some examples" etc. means that the specific features, mechanisms, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present application. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, mechanisms, materials or characteristics described may be combined in a suitable manner in any one or more embodiments or examples. In addition, those skilled in the art may combine and combine the different embodiments or examples described in this specification and the features of the different embodiments or examples, without contradiction.
[0223] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any changes or substitutions that can be easily thought of by a person skilled in the art within the technical scope disclosed in the present application should be included in the protection scope of the present application. Therefore, the protection scope of the present application shall be based on the protection scope of the claims.
Claims
1. A method for visualizing three-dimensional modeling of an underground pipe network, characterized in that: The steps include: S1: Obtain information of each pipe point in the area to be modeled and information of all pipelines passing through all pipe points from a two-dimensional underground pipeline database, and connect all pipelines to obtain a directed connected pipeline graph; S2: centralizing the coordinates of all pipe points and the endpoints of all pipelines in the directed connected pipeline graph using a centralization algorithm, and performing pipeline geometry correction for three-dimensional collision detection to obtain a directed connected corrected pipeline graph; S3: Based on the two-dimensional underground pipeline database, determine the types of pipelines represented by all pipelines in the directed connected corrected pipeline diagram, three-dimensional coordinate parameters of endpoints, cross-sectional size parameters and parameter assignment information, and obtain a pipeline information library; S4: Based on the two-dimensional underground pipeline database, three-dimensional coordinates are created, rotated, data stretched, and parameters are assigned to all the pipe points in the directed connected corrected pipeline diagram to obtain a pipe point information library; S5: Based on the pipeline information database and the pipe point information database, obtain the pipeline three-dimensional image information of the area to be modeled by breaking and reconnecting the pipe; S6: Visualizing the three-dimensional image information of the pipeline by means of an octree hierarchical division method; The process of centralization in step S2 includes the following steps: By traversing all the pipe point coordinates of the directed connected pipeline graph and the endpoint coordinates of all pipelines to calculate the three-dimensional bounding box of these coordinates, and obtaining the data center point of the three-dimensional bounding box; Subtract the coordinates of the data center point from the coordinates of each pipeline point, the coordinates of each pipeline intersection, and the coordinates of each pipeline endpoint to obtain the corresponding centralized coordinates, and obtain a centralized directed connected pipeline graph; The process of pipeline geometry correction in step S2 for three-dimensional collision detection includes the following steps: S201: extracting all pipeline intersections that cannot be matched with pipeline points in the centralized directed connected pipeline graph to obtain a plurality of unmatched intersections; S202: taking the first unmatched intersection among the plurality of unmatched intersections as the current intersection according to the first traversal order, and then executing the next step; S203: Determine whether the two pipelines forming the current intersection are pipelines of the same type, and whether the current intersection is the endpoint of one of the pipelines; If they are pipelines of the same type, and the current intersection is the endpoint of one of the pipelines, the revised pipelines of the two pipelines are respectively regarded as themselves, and then step S211 is executed; If they are pipelines of the same type, and the current intersection is not the endpoint of one of the pipelines, then execute step S204; If they are not pipelines of the same type, and the current intersection is the endpoint of one of the pipelines, then execute step S208; If they are not pipelines of the same type, and the current intersection is not the endpoint of one of the pipelines, then execute step S204; S204: Calculating the length of the common perpendicular line of the two pipelines forming the current intersection to obtain the distance between the two pipelines, and determining whether the distance between the two pipelines is greater than the sum of the maximum dimensions of the cross sections of the two pipelines; If yes, the revised pipelines of the two pipelines are regarded as themselves respectively, and then step S211 is executed; If not, proceed to the next step; S205: Obtain the intersection point of the common perpendicular line of the two pipelines at the current intersection and the two pipelines and the midpoint of the intersection point of the common perpendicular line and the two pipelines, and then execute the next step; S206: a first correction vector is obtained by taking the direction formed by the intersection of the common perpendicular line and one of the pipelines pointing to the midpoint as the direction and half of the sum of the maximum cross-sectional dimensions of the two pipelines as the size, a point corresponding to the coordinates obtained by adding the central coordinates of the intersection of the common perpendicular line and the pipeline to the first correction vector is taken as the first correction point, a new pipeline formed by taking the starting end point of the pipeline as the starting point and the first correction point as the end point is taken as the first correction pipeline of the pipeline, a new pipeline formed by taking the first correction point as the starting point and the end point of the pipeline as the end point is taken as the second correction pipeline of the pipeline, and then the pipeline is deleted and the next step is executed; S207: Take the direction formed by the intersection of the common perpendicular line and the other pipeline pointing to the midpoint as the direction and take half of the sum of the maximum cross-sectional dimensions of the two pipelines as the size to obtain a second correction vector, take the point corresponding to the coordinates obtained by adding the central coordinates of the intersection of the common perpendicular line and the pipeline to the coordinates of the second correction vector as the second correction point, take the starting end point of the pipeline as the starting point and the second correction point as the end point to form a new pipeline as the first correction pipeline of the pipeline, take the second correction point as the starting point and the end point of the pipeline as the end point to form a new pipeline as the second correction pipeline of the pipeline, then delete the pipeline and execute step S211; S208: Calculating the length of the common perpendicular line of the two pipelines forming the current intersection to obtain the distance between the two pipelines, and determining whether the distance between the two pipelines is greater than the sum of the maximum cross-sectional dimensions of the two pipelines; If yes, the revised pipelines of the two pipelines are regarded as themselves respectively, and then step S211 is executed; If not, proceed to the next step; S209: Obtain a pipeline with the current intersection point as its endpoint from among the two pipelines, and regard the revised pipeline of the pipeline as itself, and then execute the next step; S210: Obtain a pipeline that does not use the current intersection as its endpoint from the two pipelines, and obtain the intersection of this pipeline and the common perpendicular line of the two pipelines, use the direction formed by the current intersection pointing to the intersection of the common perpendicular line of the pipeline and the two pipelines as the direction and use the sum of the maximum cross-sectional dimensions of the two pipelines as the size to obtain a third correction vector, use the point corresponding to the coordinates obtained by adding the central coordinates of the current intersection to the third correction vector as the third correction point, use the starting endpoint of the pipeline as the starting point and the third correction point as the end point to form a new pipeline as the first correction pipeline of the pipeline, use the third correction point as the starting point and the end point of the pipeline as the end point to form a new pipeline as the second correction pipeline of the pipeline, then delete the pipeline and execute the next step; S211: Determine whether a plurality of the unmatched intersections have been traversed; If yes, execute step S3; If not, the next unmatched intersection is used as the current intersection, and then the process returns to execute step S203.
2. The underground pipe network three-dimensional modeling visualization method according to claim 1, characterized in that: The step S3 comprises the following steps: S301: determining the first correction pipeline of the directed connected correction pipeline graph according to the proposed starting point, taking the first correction pipeline as the current pipeline, and then executing the next step; S302: Obtaining the number of cross-sectional dimension parameters of the pipeline before correction corresponding to the current pipeline from the two-dimensional underground pipeline database, and if the number is 2, determining that the pipeline type represented by the current pipeline is a square pipe; If the number is 1, it is determined that the pipeline type represented by the current pipeline is a round pipe, and the next step is executed after the pipeline type represented by the current pipeline is determined; S303: obtaining the starting point coordinates and starting point elevation of the pipeline before correction corresponding to the current pipeline from the two-dimensional underground pipeline database, constructing the three-dimensional coordinates of the starting point of the pipeline represented by the pipeline, obtaining the ending point coordinates and ending point elevation of the pipeline before correction corresponding to the current pipeline from the two-dimensional underground pipeline database, constructing the three-dimensional coordinates of the ending point of the pipeline represented by the pipeline, and then executing the next step; S304: Obtaining the diameter size information of the cross section of the pipeline before correction corresponding to the current pipeline from the two-dimensional underground pipeline database, obtaining the pipeline cross section size parameters of the pipeline represented by the pipeline, and then executing the next step; S305: Obtaining text attribute content of the pipeline before correction corresponding to the current pipeline from the two-dimensional underground pipeline database, obtaining pipeline parameter assignment information of the pipeline represented by the pipeline, and then executing the next step; S306: Determine whether all correction pipelines of the directed connected correction pipeline graph have been traversed; If yes, execute step S4; If not, the next revised pipeline is used as the current pipeline, and then the process returns to execute step S302.
3. The underground pipe network three-dimensional modeling visualization method according to claim 2, characterized in that: The step S4 comprises the following steps: S401: determining the first pipe point of the directed connected corrected pipeline graph according to the second traversal order, taking the first pipe point as the current pipe point, and then executing the next step; S402: Retrieving the coordinates and elevation data of the current pipe point from the two-dimensional underground pipeline database to obtain the three-dimensional coordinates of the current pipe point, and retrieving the coordinate origin information corresponding to the coordinates of the current pipe point, and then executing the next step; S403: Determine the number of correction pipelines passing through the current pipeline point in the directed connected correction pipeline graph; If the number is equal to 0 or greater than 2, use 0 as the rotation angle and proceed to the next step; If the number is 1, the angle between the pipeline direction of the corrected pipeline passing through the current pipeline point and the specified direction is used as the rotation angle, and the next step is executed; If the number is 2, the angle between the sum vector of the two corrected pipelines passing through the current pipeline point and the specified direction is used as the rotation angle, and the next step is executed; S404: rotating the current pipe point around the coordinate origin corresponding to its coordinates by a rotation angle, obtaining the three-dimensional coordinate information of the rotated pipe point corresponding to the current pipe point, and then executing the next step; S405: Determine whether the model size data of the current pipe point is empty; If yes, proceed to the next step; If not, execute step S407; S406: Determine whether the attachment type corresponding to the current pipe point is a fixed model type; If yes, the pipe point data of the current pipe point is not stretched, and step S408 is directly executed; If not, the cross-sectional dimension parameters of the pipeline represented by the modified pipeline passing through the current pipe point are retrieved, and the model data of the current pipe point is supplemented according to the cross-sectional dimension parameters to stretch the pipe point data of the current pipe point, and then step S408 is executed; S407: Determine whether the attachment type corresponding to the current pipe point is a fixed model type; If yes, do not stretch the data of the current pipe point, and directly execute the next step; If not, the cross-sectional dimension parameters and elevation data of the pipeline represented by the revised pipeline passing through the current pipe point are retrieved, and the model data of the current pipe point is revised according to the cross-sectional dimension parameters and elevation data to stretch the pipe point data of the current pipe point, and then the next step is executed; S408: Retrieve the pipe point text attribute content of the current pipe point to assign pipe point parameters to the current pipe point, and then execute the next step; S409: Determine whether all the pipeline points of the directed connected corrected pipeline graph have been traversed; If yes, execute step S5; If not, the next pipe point is used as the current pipe point, and then the process returns to execute step S402.
4. The underground pipe network three-dimensional modeling visualization method according to claim 3, characterized in that: The step S5 comprises the following steps: S501: determining the first pipe point from the pipe point information database according to the third traversal order, and taking the pipe point as the currently unconnected pipe point, and then executing the next step; S502: Retrieving the associated information of the currently unconnected pipe point according to the pipe point number of the currently unconnected pipe point to determine the number of pipeline endpoints associated with the currently unconnected pipe point; If the number is 2, the pipeline information of the two endpoints is retrieved from the pipeline information library, and then the next step is executed; wherein the pipeline information includes the type of the pipeline obtained by the step S3, the three-dimensional coordinate parameters of the endpoints, the cross-sectional size parameters and the parameter assignment information; If the number is 3, the pipeline information of the three endpoints is retrieved from the pipeline information library, and then step S504 is executed; If the number is greater than 3, the pipeline information of these endpoints is retrieved from the pipeline information library, and then a pipeline connection between the currently unconnected pipe point and these endpoints is established according to the currently retrieved association information, and the pipeline information of the pipeline represented by the connecting pipeline is determined according to the pipeline information of these endpoints, and then step S505 is executed; S503: Determine whether the angle of the angle determined by the two endpoints and the currently unconnected pipe point and having the currently unconnected pipe point as the vertex is less than 5 degrees or between 70 degrees and 85 degrees; If so, a pipeline connection between the currently unconnected pipe point and the two endpoints is established by a two-on / off pipe reconnection method, and the pipeline information of the pipeline represented by the connecting pipeline is determined according to the pipeline information of the two endpoints, and then step S505 is executed; If not, a pipeline connection between the currently unconnected pipe point and the two endpoints is established according to the currently retrieved association information, and the pipeline information of the pipeline represented by the connecting pipeline is determined according to the pipeline information of the two endpoints, and then step S505 is executed; S504: Determine whether any of the three angles determined by the line connecting the three endpoints and the currently unconnected pipe point and having the currently unconnected pipe point as a common vertex has an angle size less than 5 degrees or between 70 degrees and 85 degrees; If so, a pipeline connection between the currently unconnected pipe point and the three endpoints is established by a three-way pipe disconnection and reconnection method, and the pipeline information of the pipeline represented by the connecting pipeline is determined according to the pipeline information of the three endpoints, and then the next step is executed; If not, a pipeline connection between the currently unconnected pipe point and the three endpoints is established according to the currently retrieved association information, and the pipeline information of the pipeline represented by the connecting pipeline is determined according to the pipeline information of the three endpoints, and then the next step is executed; S505: Determine whether all control points in the control point information database have been traversed; If yes, proceed to the next step; If not, the next pipe point is taken as the currently unconnected pipe point, and then the step S502 is executed again; S506: Retrieve the association information between currently unconnected endpoints, establish a pipeline connection between currently unconnected endpoints based on the association information, and determine the pipeline information of the pipeline represented by the connecting pipeline based on the pipeline information of these endpoints, and then execute step S6.
5. A three-dimensional modeling and visualization system for underground pipe networks, characterized in that: The method for three-dimensional modeling and visualization of an underground pipe network according to any one of claims 1 to 4 comprises: The retrieval module is configured to obtain information of each pipe point in the area to be modeled and information of all pipelines passing through all pipe points from a two-dimensional underground pipeline database, and connect all pipelines to obtain a directed connected pipeline graph in which edges represent pipelines; A correction module is configured to centralize the coordinates of all pipe points and the endpoints of all pipelines in the directed connected pipeline graph using a centralization algorithm, and perform pipeline geometry correction for three-dimensional collision detection to obtain a directed connected corrected pipeline graph; The pipeline module is configured to determine the types, endpoint three-dimensional coordinate parameters, cross-sectional dimension parameters and parameter assignment information of the pipelines represented by all pipelines in the directed connected corrected pipeline diagram based on the two-dimensional underground pipeline database, and obtain a pipeline information library; A pipe point module is configured to create three-dimensional coordinates, rotate, stretch data and assign parameters to all pipe points in the directed connected corrected pipeline diagram based on the two-dimensional underground pipeline database to obtain a pipe point information library; A three-dimensional module is configured to obtain the three-dimensional image information of the pipeline in the area to be modeled by using the pipeline information library and the pipeline point information library in a broken pipe reconnection manner; A visualization module is configured to visualize the pipeline three-dimensional image information by establishing an octree node and dividing it into levels; in, The correction module is electrically connected to the retrieval module, the pipeline module is electrically connected to the correction module, the pipe point module is electrically connected to the correction module, the three-dimensional module is electrically connected to the pipeline module and the pipe point module respectively, and the visualization module is electrically connected to the three-dimensional module.
6. The underground pipe network three-dimensional modeling visualization system according to claim 5, characterized in that: The correction module comprises: A centralization unit is configured to centralize all pipe point coordinates and endpoint coordinates of all pipelines of the directed connected pipeline graph using a centralization algorithm to obtain a centralized directed connected pipeline graph; A geometry correction unit is configured to perform geometry correction on the centralized directed connected pipeline graph by a pipeline geometry correction method of three-dimensional collision detection to obtain the directed connected corrected pipeline graph; in, The centralization unit is electrically connected to the retrieval module, the geometry correction unit is electrically connected to the centralization unit, and the pipeline module and the pipe point module are both electrically connected to the geometry correction unit.
Citation Information
Patent Citations
3D automatic modeling and scheduling rendering method for integrated pipe network
CN106683198A
Three-dimensional modeling and visual management method and device for underground pipe network of coal preparation plant
CN114898052A