1. Introduction
With the continuing expansion of urban areas causing issues including traffic congestion, a lack of public services, and the deterioration of the urban environment, the development and exploitation of urban underground spaces is becoming increasingly important. Utility tunnels, which incorporate multiple types of municipal pipelines, are important underground infrastructure in cities for the integrated management and maintenance of pipelines from numerous departments. To maintain the daily operation of utility tunnels, a procedure for investigation and inspection is indispensable [
1,
2]. Currently, the digitalized maintenance of utility tunnels is still at a low level. Usually, the as-built utility tunnel is different from what was initially designed, which makes maintenance more time-consuming. Accurate building information models (BIM) of the as-built utility tunnels make it more efficient for technical staff to perform maintenance work according to the real situation of the utility tunnels, which is significant for the digitalized management of utility tunnels.
With the development of 3D laser scanners, the cost of laser scanning is declining while the accuracy is improving. Three-dimensional laser scanning has been increasingly used to obtain point cloud data from large building scenes with advantages such as non-contact scanning, wide range, and high accuracy [
3,
4]. Scan-to-BIM is a common modeling technique that utilizes a 3D laser scanner to capture the point cloud of a building and model it in BIM applications. It is far more efficient than traditional methods of single-point surveying with a total station, which is extensively employed in the architecture, engineering, construction, and facility management (AEC/FM) fields. Presently, various commercial applications or plugins such as Undet and Edgewise [
5] offer manual or semi-automatic [
6] shape detection and generation of models from point cloud data, with the former for building modeling and the latter for industries with pipes [
7]. Regarding utility tunnels with complex internal pipelines and crowded facilities, the existence of occlusions will lead to incomplete data in the scanning results [
8]. If existing commercial applications or other methods are used, topological errors can severely affect the quality of the model. Therefore, establishing a precise BIM model for utility tunnels from point cloud data is still a challenging task [
9,
10].
Several difficulties in using the scan-to-BIM method to model utility tunnels are as follows: (1) the structure of utility tunnels is narrow and packed with intricate interior pipe distributions; (2) segmenting building structures and extracting semantic information of pipes from point clouds with noise and occlusion is challenging; and (3) fitting planes and cylinders based on the extracted clouds may have redundancy and topological errors, making topological relationships of walls and pipe connections difficult to establish. In complicated point cloud environments, available point cloud classification and extraction algorithms currently struggle to reliably identify building structures and segment pipes and their auxiliary facilities.
In this study, a novel method for generating topologically consistent BIM models of utility tunnels is proposed. The main contributions are summarized as follows. (1) A line feature extraction algorithm based on an improved mean-shift and a medial axes extraction algorithm based on local symmetry are proposed to extract parameters of wall and pipeline objects from the hierarchically segmented point clouds. (2) A topology reconstruction method for BIM objects is proposed to recover the topology of wall and pipeline objects through searching and extracting their neighbor information in collinear, perpendicular, and intersecting situations to construct a topologically consistent BIM model.
The remainder of this paper is organized as follows. In
Section 2, relevant research on utility tunnel modeling is reviewed. In
Section 3, the proposed hierarchical segmentation approach and semi-automatic modeling method are introduced for utility tunnels. In
Section 4, the proposed method is applied to a utility tunnel engineering case. In
Section 5, the application of the proposed method to the engineering case is discussed. Finally, in
Section 6, the experiments are summarized and future work is provided.
2. Related Work
The scan-to-BIM approach [
11,
12] has been widely employed in numerous building modeling [
13] applications in the AEC/FM field. In the field of underground space accident search and rescue [
14,
15,
16], relevant research has received increasing attention from researchers. As a significant underground infrastructure, the modeling of utility tunnels can be divided into structure modeling and pipe modeling. Recent research on utility tunnel modeling will be discussed in this section.
Research and applications on building modeling, including the classification of building scenes and the extraction of building structure elements, are currently well-developed. Ai et al. [
17] proposed a modeling method based on consistent topological rules, which preprocesses semantic information to obtain evenly structured patches and estimates boundaries using an edge-based primitive extraction method. The model is finally reconstructed to achieve building structure modeling in complex environments. Xiong et al. [
18] proposed an automatic modeling algorithm based on unsupervised learning. Core structural components (walls, ceilings, and floors) were recognized and modeled first. Then, openings in the building surface were recognized using a support vector machine (SVM) classifier. Finally, a 3D hole-filling algorithm was used to reconstruct occluded regions not within an opening. The approaches discussed above primarily create planar models of common buildings. However, recognizing structural elements from cloud scenes with noise and occlusions will cause topology errors in the constructed model. As a result, many scholars use the cellular nature of indoor rooms to reconstruct building structures through space partitioning and room reconstruction [
19,
20,
21]. Geometric elements (such as wall lines) are extracted first to construct the cell complex. The graph cuts optimization algorithm is subsequently utilized to recover the building surface geometry. However, regarding the structural modeling of utility tunnels, it is necessary not only to fit surface features but also to construct parametric models based on the wall thickness and height. Furthermore, the interior space of a utility tunnel can be considered an isolated room with a vast length-to-width ratio; thus, building modeling in this area involves problems of fitting and modeling superlong walls.
Another important task in utility tunnel modeling is to model pipelines. Current research on pipeline modeling primarily focuses on pipeline recognition and extraction. Multiple parameters, including orientation, radius, and length [
22], must be determined during the process of pipeline recognition and extraction, which varies from the extraction of building planes. Various methods have been presented by scholars for pipeline detection. Random sample consensus (RANSAC) [
23,
24], Hough transform [
25,
26,
27], Gaussian sphere-based methods, and machine learning methods [
28,
29] are common approaches that can be used independently or in combination for pipeline shape detection. Proposed by Fischier and Bolles [
30], the RANSAC algorithm is widely used in the computer vision (CV) domain. This algorithm calculates the parameters of the target mathematical model based on a set of sample datasets containing outliers, thus obtaining a set of effective data. Schnabel et al. [
31] proposed an efficient RANSAC for detecting primitives such as planes, spheres, and cylinders from point clouds. This method begins by generating a hypothetical cylinder from two points and their corresponding normal vectors. Then, the hypothetical cylinder is validated as a cylinder by calculating how many points are on it within the distance and normal-deviation thresholds. However, when repeatedly detecting cylinders, thresholds between different models are needed, and the output of the algorithm depends on the initial selection of the points. The results are occasionally not robust and cannot handle outliers, noise, or incomplete data.
The detection of cylinders in point clouds using the Hough transform [
32] comprises two steps: first, identifying the cylinder’s orientation, and second, estimating its radius and position. To identify a cylinder, one point
on its axis, one direction vector
, and an estimated radius r are needed. However, computational challenges occur by dealing with an intricate high-dimensional Hough space in this approach. In Ahemd’s work [
33], a method that reduces the computational complexity by detecting cylinders in a low-dimensional space is proposed. Furthermore, in Patil’s work [
34], the cylinder’s orientation is roughly estimated using a Gaussian sphere at first. Then, the radius is estimated with an improved algebraic circle fitting algorithm. Finally, the connected regions are reconstructed by determining the nearest cylinder relationships. This approach, however, can only detect straight pipes parallel to the orthogonal axis and performs poorly with superlong pipes. The detection results for pipes with elbows are relatively disappointing.
In the process of extracting cylindrical primitives, Gaussian spheres are mainly used to detect the direction of cylindrical pipes. Chaperon et al. [
35] proposed a method for extracting cylinders from unstructured point clouds based on the combination of RANSAC and Gaussian spheres. Initially, constraint planes in the Gaussian image are extracted to build a three-dimensional point set with direction. Cylinders are subsequently extracted from the point set. The RANSAC method guarantees the robustness of the extraction result. Liu et al. [
1] proposed a cylinder detection method based on Gaussian images for detecting the orientation of pipelines. The problem of rebuilding pipeline equipment in 3D space is simplified into a set of circular detection problems in 2D space. This approach, however, can only extract pipes that are parallel or perpendicular to the ground. Qiu et al. [
36] applied a Gaussian sphere to obtain global similarity and detect the axial direction of cylinders. The mean-shift algorithm is used to detect large circles in noise-filled Gaussian spheres. Cylinders are located by fitting 2D circles mapped from points on a plane and the straight pipe segments are smoothly connected. Finally, T-joints and elbows are detected and modeled to restore the connectivity of the pipeline.
Additionally, extracting the pipeline medial axes [
6] by transforming the problem of pipeline detection or cylinder recognition into skeleton extraction has been the focus of several researchers. These approaches have superiority in handling scenes with noise and missing point clouds. Liu et al. [
37] proposed a BIM automation reconstruction method for full-size complex tubular engineering structures (CTES) based on TLS, which particularly introduces a new algorithm for extracting the medial axis of tubular structures. In the beginning, a region-growing-based extended axis algorithm is utilized to segment the point cloud, and then the geometric parameters of the tubular structure are estimated using a slicing method. Jin [
38] used three-dimensional sphere detection to calculate the center point and radius of the cylinder by RANSAC fitting and utilized the points of the curved part of the pipeline to estimate the medial curve at the connection section of the pipeline. Similarly, in Jin’s other work [
39], RANSAC was used to estimate the medial axis and radius based on the trajectory of the sphere model, and the medial axis data were checked using principal component analysis (PCA). The outliers in the candidate values of the medial axis were filtered out using a filtering approach. Czerniawski et al. [
40] located and extracted the central axis of the pipeline from dense and cluttered point cloud data obtained from a laser scanner by adopting local data grading curvature estimation, clustering, and feature bag matching.
Deep learning approaches for the automatic recognition of pipelines in point cloud scenes are under rapid development as deep learning technology advances. A novel deep learning network for extracting pipes in mechanical, electrical, and plumbing (MEP) systems is presented by Xu et al. [
28]. A dataset is established according to the actual engineering situation, but this method has a low classification accuracy for the boundary part of the input data, and the research is still in its early stages, with few digital categories available. Kim et al. [
41] also used deep learning approaches for the automatic identification of pipelines in their study. A pipeline and automatic elbow-recognition method is proposed based on curvature information and convolutional neural network primitive classification. This method enables the recognition of simple and S-shaped elbows. This approach, however, is insufficiently accurate when detecting lengthy pipeline sections and is strongly influenced by crowded scenes, making it difficult to handle complex long pipeline sections with elbows in utility tunnels. Moreover, labeling and training data are costly in that a considerable number of samples must be labeled as training sets.
The pipeline modeling approaches described above are mostly intended for pipes with short lengths, few elbows, or no elbows at all. Currently, few studies regarding the approaches for dealing with pipe connections are presented, particularly in utility tunnels. However, it is typical that superlong pipes with many elbows exist in utility tunnel scenes. If extracted directly from the point cloud of a utility tunnel with the present methods, topological errors will affect the quality of the model, which is an urgent problem.
Research on urban building modeling takes the lead in the present studies on scan-to-BIM, while research on utility tunnel modeling is not as popular. During the modeling process of utility tunnels, two categories of objects are created: building structures (wall facades, floors, ceilings, etc.) and pipes. Building structure modeling is comparable to modeling common buildings, and extensive studies have been conducted on the classification of point cloud scenes and the extraction of structural elements. The majority of pipeline modeling research focuses on the identification and extraction of pipe cylinders. It is a comprehensive issue that pipes cannot be explored as an isolated point cloud in utility tunnels but must be considered alongside various types of pipelines and auxiliary facilities in utility tunnels. In addition, many difficulties still exist in the connection of utility tunnel building structures, as well as the identification, segmentation, and extraction of superlong pipes. Therefore, hierarchical segmentation and accurate construction of the topological relationship among building elements are needed. As a result, a hierarchical segmentation method is presented in this paper for the unsupervised recognition and extraction of various elements in utility tunnels. Another topology reconstruction method is presented to avoid probable redundancies and topological errors in the procedure of generating BIM models.
3. Proposed Methods
The suggested method for generating topologically consistent BIM models of utility tunnels is depicted in
Figure 1, which comprises five major steps: (1) point cloud preprocessing, including the segmentation and filtering of point clouds; (2) hierarchical segmentation of point clouds (in this step, building structures containing walls, ceilings, floors, and pipe systems are segmented based on the calculation of point cloud perpendicularity using a threshold method); (3) extraction of building structures and pipe parameters, geometric parameters such as wall lines, wall heights, and pipe axes; (4) topology reconstruction, which reconstructs the topological relationship of the building object by fusing segmented wall lines and pipe axes; and (5) BIM object reconstruction, which includes reconstructing the BIM model of the utility tunnel using the topologically reconstructed wall lines and pipe axes.
3.1. Preprocessing
The raw point cloud data P have been precisely registered. Segmenting and filtering point clouds are two aspects of point cloud preprocessing. Considering the large length-to-width ratio and irregular outer contour of the utility tunnel, as well as the occlusion and incomplete point cloud data of the internal pipe system, a large amount of time is required if semantic segmentation and shape identification are carried out on the entire point cloud. Thus, as illustrated in
Figure 2, partitioning the utility tunnel’s point cloud data into blocks is an effective strategy.
Point cloud filtering is the other task of point cloud preprocessing. Outliers may be included in the scanning results during the 3D laser scanning process due to the surrounding environment and instrument-related reasons. Outliers not only degrade the quality of the whole point cloud but also impair local point cloud feature estimation, resulting in inaccurate computation outputs. To filter and denoise the point cloud data in this paper, a statistical outlier removal approach (SOR) is applied. This method performs statistical analysis on each point in the point cloud’s neighborhood, and outliers that do not adhere to the preset statistical distribution are deleted. A point number threshold is set according to a statistical model to check all points in the point cloud data. Points that fail to meet the threshold are removed as outliers.
3.2. Hierarchical Segmentation of the Point Cloud
The internal structure of the integrated utility tunnel is quite complicated, and the objects that must be built in its BIM modeling process typically include wall facades, floors, ceilings, pipes, and their auxiliary facilities, which need to be retrieved from the point cloud. Many researchers have included point cloud pre-segmentation in their pipe extraction research, but the classification of pipes in utility tunnels remains a difficult topic. In this paper, a hierarchical segmentation method for extracting the building elements required for BIM modeling from a point cloud is presented. In the beginning, the perpendicularity of the point cloud blocks is calculated. Then, threshold segmentation is utilized to distinguish facades and planes based on the perpendicularity calculation results, which are identified as wall facades, floors and ceilings. Finally, the floors and ceilings are separated from the segmented point cloud blocks using the slicing approach. As illustrated in
Figure 3, after hierarchical segmentation, wall facades, floors, ceilings, and the pipe system are precisely separated, with wall facades, floors and ceilings meeting the needs of further modeling of building structures. The remaining point cloud of pipes and their auxiliary facilities is further used for reconstructing the pipe system.
3.3. Extraction of Structure Parameters
The point cloud of wall facades obtained through hierarchical segmentation is subsequently used to extract wall line features and height information. The wall lines, height, and thickness are three critical parameters for generating a precise BIM model of walls. Among them, wall lines and height cannot be directly obtained and need to be extracted from the point cloud. After horizontally slicing the point cloud blocks, wall line features are retrieved with the mean-shift algorithm. The process of slicing the point cloud blocks is shown in
Figure 4. Accurate wall point clouds are obtained by selecting proper elevations and thicknesses to slice. Line features are extracted according to the slice afterward. These wall line features are made up of several short line segments that need to be restored to complete wall lines.
To estimate the height of the building facade, a clustering algorithm is employed. The principle is to identify and cluster point clouds of different elevations (classified along the
Z-axis direction). The clustering results are used to generate the elevation distribution histogram. The height of the building facade is the absolute distance between the peak values in the histogram (as shown in
Figure 5).
3.4. Extraction of the Pipe Parameters
3.4.1. Medial Axis Point Set Extraction
The extraction of the medial axis point set of the pipeline is discussed in this section. Based on the symmetry of cylinders, a method of mirror reflection is proposed to extract the medial axis point of the pipeline from the point cloud. Regarding a certain point cloud
of a pipe, if a point
p and its nearest neighbor
N are in the point cloud, the neighbor point
has symmetry. As shown in
Figure 6, for each point
in
, the mirror reflection corresponding relationship can be acquired by reflecting it on the mirror plane and finding the nearest neighbor within a fixed radius. After determining the mirror reflection’s corresponding relationship, the Levenberg-Marquardt (LM) algorithm (Formula (1)) is used to minimize the distance between the mirror reflected points and their corresponding points and optimize the original symmetrical plane.
where
is the mirror reflection plane, represented by the point
p and the normal vector
n, and the reflection plane is calculated through PCA. Points
and
are a pair of symmetric points near the mirror reflection plane
S in the point cloud.
An accurate symmetrical plane can be obtained using the mirror reflection symmetry approach, and the extraction of the pipe medial axis point set is then considered. The direction of the pipe is determined by the intersection point direction of the symmetrical plane with the nearest point set. The point cloud of the pipe cross-section is obtained based on this direction, and the RANSAC circle fitting method is subsequently used to calculate the axis point set of the pipeline. As shown in
Figure 7, the medial axis point set of the entire pipe can be obtained after repeated calculations of the circle fitting approach. Finally, filtering methods are used to denoise and remove outliers.
3.4.2. Medial Axis Polyline Extraction
After obtaining the medial axis point set of the pipeline, the next step is to extract the pipeline medial axis line. In this section, an improved mean-shift algorithm is used to refine the medial axis point set, and RANSAC is used to extract the axis line. First, the axis point set is randomly sampled with 10% of the input points chosen as initial samples to reduce computational complexity. The sampling points are skewed towards the maximum point density region. The conventional mean-shift algorithm is then enhanced by applying the normalization formula [
42,
43] (Formulas (2)–(4)) to extract the medial axis point set of pipes from the original point cloud and modify the sample points of the original point cloud.
The classical mean shift algorithm is represented by the first term in Formula (2). The second term is a regularization term that prevents the refined sampled points from excessively clustering when they shrink to their local central positions. λ is the equilibrium constant between the two terms and it is usually set to the empirical value μ = 0.35. The RANSAC method is used to recover the pipeline medial axis after point cloud refinement. First, two points and are chosen at random from the axis point set to generate a hypothetical straight line. Then, the number of remaining points that fall on the hypothetical straight line is examined to determine if it meets the predetermined criteria. The hypothesis is regarded as reliable if it fits the pre-set threshold. Following a series of random tests, the parameters of the hypothetical straight line with the greatest number of supporting points are selected as the parameters of the pipe medial axis. This process is repeated for each point cloud block to obtain the pipeline axis line set . Finally, each medial axis line li in the medial axis line set is smoothed. The radius of the pipe is determined by the average radius of all fitted circles on the medial axis line. In this section, the parameters of orientation and radius that are necessary for the reconstruction of pipes are obtained.
3.5. Topology Reconstruction
We acquired a preliminary wall line segment set
and a pipeline axis line segment set
in
Section 3.3 and
Section 3.4. In this section, the topological relationships of these segments are reconstructed by merging them into continuous polylines. In Sets
and
and their adjacent line segments, there are three spatial relationships between the line segments, as illustrated in
Figure 8: collinear, perpendicular, and intersecting. We propose a method for fusing of collinear line segments and merging intersecting line segments based on line feature sampling and neighbor search (perpendicularity is a special case of intersection). The suggested method is introduced below, taking the topological reconstruction of wall lines as an example. The topological reconstruction procedures of the medial axis of the pipe are comparable.
The first step is to search for neighboring line segments. Above all, the line segments in set are sampled uniformly with a pre-set sampling interval to produce a set of sampling points . Then, a data structure is constructed based on the sampling point set and the line segments to which they belong, where , , and represent the spatial position of the sampling point, and represents the ID of the line segment from the set of the wall line segments to which the sampling point belongs. Then, a KD-tree is constructed for the point-line set , and for each endpoint and of each line segment, neighboring points within a radius R are searched, and neighboring line segments are identified based on the ID of . This process is iterated until all endpoints of all line segments are traversed, obtaining the neighborhood Mi of each line segment, which constitutes the set of neighboring domains .
The second step is to fuse collinear line segments. First, each line segment in set and its neighboring line segments are traversed to determine if is parallel to . The longer of the two collinear line segments is selected as the direction for the fused line segment . Next, the neighboring line segment and are projected onto the chosen direction , and the coordinates of ’s endpoints are updated accordingly. The information from is added to , and the information related to the neighboring line segment is removed from . Then, the information of all other line segments except for is updated, and the set of the wall line segments is updated accordingly. Finally, this process is repeatedly performed until all collinear line segments have been fused, and the updated wall line segment set is denoted by .
The last step is to merge intersecting line segments. First, each line segment in the set
and its neighbors is traversed. If the neighboring line segments form a certain angle with the current line segment, the intersection point
of the neighboring line segment and the current line segment are determined. The position relationships between the intersection point
and the current line segment are determined in three cases: on the line segment, on the extended line, or on the reverse extended line. If the current line segment has multiple neighboring line segments, the distance value
from each intersection point
to the endpoint of the current line segment is calculated, and the elements in
are sorted. The distance adjustment value
is selected as the endpoint of the line segment. Then, the endpoint coordinates of the current line segment are updated based on the distance adjustment value. Finally, all line segments in
are traversed until all line segments are updated to merge the intersecting lines. A schematic illustration of the topological reconstruction of the wall line features and pipe medial axes is shown in
Figure 9.
3.6. Reconstruction of the BIM Objects
Using the aforementioned method, relevant parameters are obtained for generating BIM structures and pipe objects. In this stage, a Revit plugin for semi-automatically generating BIM objects within a utility tunnel is developed.
Solid wall objects are created for modeling building structures based on the user-input wall thickness, the extracted wall line features, and the wall height. The WallCreate function provided by Revit is used to generate BIM solid wall objects. Rebuilding BIM walls relies on the elevation, wall type, and thickness parameters. Gaussian clustering is utilized to extract the elevations
by sorting the bottom elevations of walls. The wall type is determined by the wall material and thickness. To create BIM solid wall objects, the proper elevation, wall type, and wall thickness are chosen for each wall line. Topological connection relationships between walls are established, and reference information is appended.
Table 1 shows some examples of the structure and relevant parameters.
The PipeCreate function provided by Revit requires six major parameters when modeling pipe systems: the type of pipe system, pipe type, elevation, pipe diameter, and the starting and ending points of the pipe. Element filters are used to select the target pipe system type and pipe type. The pipes’ elevation Hp is calculated using Gaussian clustering similarly. To generate a BIM pipe object, the appropriate pipe system type, pipe type, elevation, and diameter are selected for each pipe medial axis. The topological connection relationships between pipe segments are established, and connectors are added to the elbows’ positions (as shown in
Figure 10). Notably, the pipe model is generated automatically in the Revit mechanical template and then needs to be linked to the Revit architectural template in which the model of the building structure lies. The semi-automatic modeling of the utility tunnel is now finished. The structural features and relationships that comprise the utility tunnel are depicted in
Figure 11.
6. Conclusions
A novel method for generating topologically consistent BIM models of utility tunnels is proposed in this paper and it is applied to the modeling of the utility tunnel under Pearl Bay Plaza. The classification problem in complicated point cloud situations is solved with the proposed method of hierarchical segmentation by extracting walls, floors, ceilings, and the pipe system from point cloud blocks. Wall line features are extracted using an improved mean-shift algorithm, and bottom elevations of walls are extracted using Gaussian clustering. The mean-shift algorithm is also used to refine the pipe medial axis point set obtained by the medial axis extraction algorithm based on local symmetry, and the RANSAC method is used to extract segments of the pipe medial axes. Finally, a topologically consistent 3D model of the utility tunnel is reconstructed with the proposed topology reconstruction method by searching neighbor information of the wall and pipeline centerlines and establishing collinear, perpendicular, and intersecting scenarios. The effective application of this method verifies its reliability and provides a dependable solution for scan-to-BIM work in similar structures.
However, in this study, only the BIM modeling of underground utility tunnels is studied, and the modeling of aboveground buildings is not considered. Additionally, in-depth modeling of pipes, such as valves and flanges, was not performed in this study.
In our future work, pipeline components such as valves and flanges, will be identified from point clouds or pictures based on deep learning algorithms. Regarding the combination of modeling ground and underground building structures, we will use UAV images to reconstruct the ground buildings. Then, the ground and underground models will be incorporated into an integrated BIM model by aligning the model coordinates.