A building facade point cloud extraction method
By combining the DBSCAN algorithm with virtual grid and local point cloud density, ground points are adaptively separated and the neighborhood search radius is improved, which solves the problem of low accuracy in building facade point cloud extraction in the existing technology and achieves more efficient and accurate building facade point cloud extraction.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Chinese People's Liberation Army Cyberspace Force Information Engineering University
- Filing Date
- 2022-05-23
- Publication Date
- 2026-05-29
AI Technical Summary
Existing building facade point cloud extraction algorithms suffer from problems such as difficulty in setting parameters reasonably and low extraction accuracy.
The DBSCAN clustering algorithm, which combines virtual grid and local point cloud density, is improved to perform clustering by adaptively separating ground points, filtering out low-lying ground features, and calculating the neighborhood search radius using local point cloud density.
It improves the accuracy and computational efficiency of point cloud extraction from building facades, adapts to point cloud density and shape complexity in different scenarios, and reduces computational costs.
Smart Images

Figure CN115099304B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of point cloud data processing technology, specifically relating to a method for extracting point clouds from building facades. Background Technology
[0002] With the emergence of concepts such as smart cities, Building Information Modeling (BIM), and City Information Modeling (CIM), and the in-depth development of related technologies, the demand for accurately and effectively reconstructing 3D urban models is constantly increasing. LiDAR point cloud data, as a mainstream modeling data source, is playing an increasingly important role in fields such as refined urban management, urban safety analysis, 3D change detection, and navigation.
[0003] Buildings are a major component of urban scenes, and extracting building point clouds from these scenes has been a research focus for many scholars. Compared to airborne laser scanning (ALS) systems, terrestrial laser scanning (TLS) and mobile laser scanning (MLS) systems can acquire high-density point clouds of building facades, thus visually presenting rich details for 3D building reconstruction. Currently, scholars both domestically and internationally have conducted numerous studies on how to accurately and efficiently extract building facades from TLS / MLS point clouds, which can be summarized into the following three categories:
[0004] 1) Two-dimensional methods. These typically involve projecting the point cloud onto a two-dimensional plane and utilizing the differences in projection density, or converting it into a two-dimensional image and using image processing techniques to extract the point cloud of the building facade. However, projection density methods are often affected by other ground features, making it difficult to set a threshold and prone to losing roof information. Image-based methods suffer from information loss during conversion and are unsuitable for complex scenarios.
[0005] 2) Segmentation-based methods. These methods mostly assume that a building consists of multiple planes. First, the scene point cloud is segmented to obtain planar blocks. Then, semantic rules governing buildings are used to identify the planar regions, thereby extracting the building facade point cloud. However, the extraction performance of this method is highly dependent on the segmentation method and semantic rules.
[0006] 3) Classification-based methods. These typically involve first classifying the scene point cloud, and then extracting the point cloud labeled as buildings from the classification results. While this method can classify scene point clouds into different features, facilitating the extraction of building facades, it requires selecting and extracting multiple different classification features and necessitates extensive manual threshold setting, making it difficult to meet the needs of various scenarios.
[0007] In summary, most existing building facade extraction algorithms suffer from problems such as difficulty in setting parameters reasonably and low extraction accuracy. Summary of the Invention
[0008] The purpose of this invention is to provide a method for extracting point clouds of building facades, so as to solve the problem of low accuracy in the extraction of point clouds of building facades in the prior art.
[0009] To address the aforementioned technical problems, this invention provides a method for extracting point clouds from building facades, comprising the following steps:
[0010] 1) Acquire point cloud data, determine the number of optimal neighboring points for each point in the point cloud data, and the farthest distance for each point. The farthest distance for a point refers to the maximum value of the distances between the point and its nearest neighbors under the number of optimal neighboring points.
[0011] 2) Determine the local point cloud density for each point based on the number of its optimal neighbors and the furthest distance:
[0012]
[0013] In the formula, LPD i Let k represent the local point cloud density at point i. i d represents the number of optimal neighborhood points of point i. kimax This represents the farthest distance from point i;
[0014] 3) Based on the local point cloud density of each point, divide all points into N classes according to the magnitude of the local point cloud density, where N≥2; for a class of point cloud, determine the median of the local point cloud density of all points in the class of point cloud, and select the farthest distance of the point corresponding to the median of the local point cloud density as the neighborhood search radius for DBSCAN clustering of each point in the class of point cloud, thereby determining the neighborhood search radius of each point in each class of point cloud.
[0015] 4) Based on the neighborhood search radius of each point, the DBSCAN clustering method is used to cluster the point cloud data;
[0016] 5) Based on the clustering results, extract the point cloud of the building facade.
[0017] The beneficial effects are as follows: This invention combines the optimal neighborhood of each point to calculate the local point cloud density of each point, and applies the local point cloud density to the DBSACAN clustering algorithm. The local point cloud density is used as the basis for subsequently calculating the neighborhood search radius of each point, preventing the phenomenon of multiple clustering blocks appearing in low-density areas when directly using the DBSCAN clustering algorithm, thereby improving the accuracy of subsequent building facade point cloud extraction. Furthermore, considering computational efficiency, this invention divides all point clouds into multiple classes based on local point cloud density. Point clouds within the same class have the same neighborhood search radius during clustering, significantly reducing computational costs and simplifying the calculation process compared to using different neighborhood search radii for each point. Moreover, the neighborhood search radius of point clouds within a class is the median of the local point cloud density of all points in that class, thus choosing a compromise method to ensure accuracy. Experiments show that the method of this invention has higher accuracy in building facade extraction and can better extract building facades with uneven point cloud density distribution and varying degrees of shape complexity.
[0018] Furthermore, in step 1), the number of optimal neighborhood points of a given point is determined using the following method:
[0019] ① Set the initial number of neighboring points k0 for point p; and use the initial number of neighboring points as the current number of neighboring points;
[0020] ② Find the three eigenvalues λ1, λ2, and λ3 corresponding to point p with the current number of neighboring points, where λ1 > λ2 > λ3;
[0021] ③ Calculate the entropy E of point p with respect to the number of neighboring points using the following formula. λ :
[0022] E λ =-L1 ln(L1)-L2 ln(L2)-L3 ln(L3)
[0023]
[0024] ④ Based on the traversal range and traversal step size of the number of neighboring points, repeat steps ② to ③ to calculate the entropy value of each point within the traversal range; select the number of neighboring points corresponding to the minimum entropy value as the optimal number of neighboring points for point p.
[0025] Furthermore, the traversal range is [k min ,k max The traversal step size is: in [k] min ,k1]∪[k2,k max Traversing within the range with a step size of k △1 Traverse the range (k1, k2) with a step size of k. △2 k△1 <k △2 .
[0026] Its beneficial effects are: different traversal step sizes for different ranges allow for a larger total traversal range to be designed, enabling the finding of the most suitable number of optimal neighboring points within a larger traversal range. Furthermore, a larger step size is set within the range where the optimal neighboring point is most likely to appear, and a smaller step size is set within the range where the optimal neighboring point is unlikely to appear, thereby reducing the computational cost of the search range.
[0027] Furthermore, k △1 =1,k △2 =2.
[0028] Furthermore, before determining the optimal number of neighboring points for each point in the point cloud data in step 1), the acquired point cloud data needs to be filtered to remove low-lying ground features.
[0029] Its beneficial effect is that, before clustering, all low-lying features are removed to improve the efficiency of subsequent clustering calculations.
[0030] Further, the screening method includes the following steps: Projecting point cloud data along the z-axis onto the corresponding two-dimensional grid plane, and dividing the data into grids according to a set size to determine the grid where each point is located; determining the elevation value of each point, finding the elevation value corresponding to the lowest point among all points, calculating the elevation difference between the lowest point in each grid and the lowest point among all points, and subtracting the elevation difference corresponding to the grid from the elevation value of each point in the grid to obtain the elevation distribution statistics of each point; dividing the interval between the maximum and minimum values of the elevation distribution statistics into M equally spaced intervals, M>1, and counting the number of points in each equally spaced interval; plotting a frequency histogram with the equally spaced intervals as the abscissa and the number of points as the ordinate; connecting the start and end points of the curve in the frequency histogram to obtain a straight line; calculating the distance from each point on the curve to the straight line; and using the elevation value of the point corresponding to the maximum distance as the elevation threshold for screening ground points and non-ground points; and filtering out points with elevation values less than the elevation threshold.
[0031] Its beneficial effects are: by using the grid method to adaptively separate ground points based on the elevation distribution characteristics, the influence of terrain undulation on elevation distribution can be overcome.
[0032] Furthermore, in step 5), the extraction of building facade point clouds must meet the following three conditions:
[0033]
[0034] h hight ≥h Δ
[0035] lwidth ≥l Δ
[0036] In the formula, n linearity n planarity n scattering These represent the number of linear, planar, and spherical points in the cluster block, respectively, δ n h is the threshold for the proportion of linear and planar points in a cluster block. hight l width These represent the height difference and maximum width of the cluster blocks, respectively, h. Δ l Δ These are the height difference threshold and the maximum width threshold, respectively.
[0037] Its beneficial effects are as follows: This method uses the characteristics of high proportion of linear and planar points in buildings and large cluster block size to refine the extraction of building facade point clouds, thereby improving the accuracy of building facade point cloud extraction.
[0038] Furthermore, N=2, and the division is performed as follows: determine the median of the local point cloud density of all points, classify points whose local point cloud density is greater than the median of the local point cloud density of all points as high-density point cloud class, otherwise classify them as low-density point cloud class.
[0039] Its beneficial effect is that it divides all point clouds into two categories, thereby improving computational efficiency.
[0040] Furthermore, during the screening process, points within the grid whose elevation difference is less than a set elevation difference threshold and whose lowest elevation within the grid is greater than the average elevation of all points should be retained.
[0041] Its beneficial effect is that this method can preserve rooftop point clouds, thus avoiding the situation where rooftop point clouds are treated as low-lying feature points and removed. Attached Figure Description
[0042] Figure 1 This is a flowchart of the building facade point cloud extraction method of the present invention;
[0043] Figure 2(a) is a frequency histogram of the present invention;
[0044] Figure 2(b) is a schematic diagram of the adaptive selection of elevation threshold according to the present invention;
[0045] Figure 3 This is a schematic diagram of the DBSCAN algorithm;
[0046] Figure 4(a) is a schematic diagram of the neighborhood search radius Eps when LPD is low;
[0047] Figure 4(b) is a schematic diagram of the neighborhood search radius Eps when LPD is high;
[0048] Figure 5(a) is a data plot of Data 1;
[0049] Figure 5(b) is a graph of Data 2;
[0050] Figure 6(a) shows the clustering results using the DBSCAN algorithm;
[0051] Figure 6(b) shows the clustering results using the LPD-DBSCAN algorithm;
[0052] Figure 7(a) is the true value map of the building facade point cloud for Data 1;
[0053] Figure 7(b) is the ground truth map of the building facade point cloud for Data 2;
[0054] Figure 8(a) shows the results of extracting Data 1 using the MRG method;
[0055] Figure 8(b) shows the results of extracting Data 2 using the MRG method;
[0056] Figure 9(a) shows the results of extracting Data 1 using the Realworks method;
[0057] Figure 9(b) shows the results of extracting Data 2 using the Realworks method;
[0058] Figure 10(a) shows the results of extracting Data 1 using the EPSB method;
[0059] Figure 10(b) shows the results of extracting Data 2 using the EPSB method;
[0060] Figure 11(a) shows the result of extracting Data 1 using the method of the present invention;
[0061] Figure 11(b) shows the result of extracting Data 2 using the method of the present invention. Detailed Implementation
[0062] To address the issues of difficult parameter setting and low extraction accuracy in building facade extraction algorithms during LiDAR (Light Detection and Ranging) point cloud data processing, this paper proposes a method for building facade point cloud extraction that combines virtual grids with the DBSCAN (Density-Based Spatial Clustering of Applications with Noise) clustering algorithm, which considers local point cloud density. The main contributions of this method are: 1) It proposes an adaptive method for determining the elevation threshold for separating ground points based on elevation distribution characteristics, and uses a grid method to further filter out low-lying ground feature point cloud data, thereby reducing the time complexity of subsequent data processing; 2) It improves the DBSCAN algorithm by proposing the LPD-DBSCAN clustering algorithm, which reduces parameter settings while effectively considering the point cloud density of different regions, resulting in better clustering performance.
[0063] The following detailed description of a method for extracting point clouds from building facades according to the present invention, with reference to the accompanying drawings and embodiments, is provided in detail.
[0064] Example of a method for extracting point clouds from building facades:
[0065] The present invention provides a method for extracting point clouds from building facades, the overall process of which is as follows: Figure 1 As shown. It should be noted that the specific values of some parameter thresholds used in this embodiment will be introduced in the final simulation experiment.
[0066] Step 1: Obtain the raw point cloud data, and adaptively separate ground points based on the elevation distribution characteristics using the grid method to remove point clouds of low-lying features.
[0067] 1. Constructing a virtual grid. The core idea of constructing a virtual grid is to project the point cloud data along the z-axis onto the corresponding two-dimensional grid plane, and divide the grid according to a certain size to facilitate subsequent statistical analysis of the elevation differences between points within the grid. The specific steps are as follows:
[0068] Step 1: Project the original point cloud data onto the xoy plane along the z-axis.
[0069] Step 2: After projection, first set the side length s of the square grid, and then determine the number of rows R and columns C of the grid according to the point cloud planar distribution.
[0070]
[0071] In the formula, x max y max x min y minThese are the maximum and minimum values of x and y in the planar distribution of the projected point cloud, respectively, and ceil() is the rounding up operator.
[0072] Step 3: Create an index for each point and use equation (2) to calculate the grid number of each point.
[0073]
[0074] In the formula, (x i ,y i Let (R) be the plane coordinates of a point. i C i () represents the row and column number of the grid where the point is located.
[0075] 2. Coarse screening to remove ground point clouds. In point cloud data, the elevation values of ground points are generally small, while the elevation values of buildings are larger than those of other features. Furthermore, the number of feature points gradually decreases as the elevation value increases. Based on this characteristic, this invention filters out ground points according to the elevation distribution of the point cloud data. The specific steps are as follows:
[0076] Step 1: To overcome the influence of terrain undulation on elevation distribution, assuming that terrain undulation within a small grid area can be ignored, the elevation value H of the lowest point O in all point cloud data is used. o Based on this, the elevation difference Δh from the lowest point to point O in each grid is calculated sequentially, and the elevation value of each point in the grid is subtracted from Δh to obtain the elevation distribution statistical value. The specific formula is shown in equation (3). Since this method easily excludes rooftop point clouds as low-lying features, this invention adds a rooftop constraint, that is, grid points with small grid elevation differences and whose lowest elevation in the grid is greater than the average elevation of all points are retained.
[0077]
[0078] In the formula, H imin Let the elevation be the lowest point within the i-th grid. Let j be the elevation value of the j-th point within the i-th grid. Let g be the elevation statistics of the j-th point within the i-th grid, g be the total number of grids, and n be the total number of point clouds within the i-th grid.
[0079] Step 2: Calculate the elevation distribution statistics of each point cloud according to formula (3) to obtain the maximum elevation z. max and minimum elevation z min ; the maximum elevation z max and minimum elevation z min Divide the space into M equal parts, with a distance of z between each part. Δ The elevation values were statistically determined to be in the range of z. ΔThe number of points N in each increasing interval; plot the frequency histogram with the elevation value z as the x-axis and the number of points N as the y-axis. The figure is an elevation-frequency curve, as shown in Figure 2(a).
[0080] Step 3: Connect the start and end points of the elevation-frequency curve to obtain a straight line L. Calculate the distance H from each point on the elevation-frequency curve to the straight line L, and statistically determine the point with the largest H, as shown in Figure 2(b). Use the elevation value of this point as the elevation threshold z for filtering ground point clouds and non-ground point clouds. t This point is actually an inflection point on the elevation-frequency curve.
[0081] Step 4: Based on the elevation threshold z t Traverse all grid cells and remove cells whose elevation statistics are less than the elevation threshold z. t The point cloud is used to remove low-profile substrate points and obtain a coarsely screened point cloud.
[0082] Step 2: The LPD-DBSCAN algorithm is used to cluster the point cloud after coarse screening to obtain the clustering results.
[0083] Points on the same feature are spatially adjacent, while different features are connected by the ground. Since many features (such as trees) are missed after the coarse screening, and various features are independent without ground connections after the coarse screening, this step uses a clustering method based on local point cloud density to cluster the point cloud after the coarse screening to assist in further extraction.
[0084] 1. Find the number of optimal neighborhood points for each point.
[0085] To adaptively select parameters (neighborhood search radius Eps) and solve for the dimensionality features of each point in the subsequent clustering process, this step uses an optimal neighborhood calculation method based on feature values to adaptively select an appropriate number of neighboring points for each point. However, the search range of this method needs to be manually set (generally set to [10, 100]). A smaller search range may not be able to find the optimal number of neighboring points, while a larger search range will increase the computational cost. To expand the neighborhood search range while reducing the computational cost, based on the statistical results of the optimal neighborhoods of point clouds for different categories, this invention adopts a segmented approach to traverse the search range with different step lengths for different ranges. The specific steps are as follows:
[0086] Step 1: Set the traversal range for the number of neighboring points k [k min ,k max The initial number of neighborhood points is k. min Among them, the traversal step size k Δ The range of values of 1 is [k] min ,k1]∪[k2,k max ], kΔ The range of 2 is (k1, k2). In this embodiment, k min =10,k max =200, k1=50, k2=180.
[0087] Step 2: Calculate the three eigenvalues λ1, λ2, and λ3 (λ1 > λ2 > λ3) of point p in its k-neighborhood using principal component analysis. Step 3: Calculate the Shannon entropy E of point p in its k-neighborhood based on the eigenvalues obtained in Step 2. λ The calculation formula is:
[0088] E λ =-L1 ln(L1)-L2ln(L2)-L3 ln(L3)
[0089]
[0090] Step 4: Continue searching for the number of neighboring points, k = k + k Δ Repeat Steps 2 through 3 to obtain the entropy value E corresponding to the number of neighborhood points. λ until k = k max .
[0091] Step 5: Compare the entropy value E of point p with different numbers of neighboring points k. λ The size of the entropy, the number of neighborhood points k corresponding to the minimum entropy value, is the optimal neighborhood k of point p. opt .
[0092]
[0093] Step 6: Calculate the number of optimal neighborhood points for each point by following the steps from Sep 1 to Step 5.
[0094] 2. Determine the neighborhood search radius Eps of each point in the LPD-DBSCAN clustering algorithm.
[0095] The DBSCAN algorithm, proposed by Ester Martin et al. in 1996, is a typical density clustering algorithm. This algorithm is unaffected by the size or shape of the data and can divide the data into different categories based on the density of the data. The core idea is to pre-define two parameters for a point set X: the neighborhood search radius Eps and the minimum number of neighborhood points MinPts. Point clusters are then established by iteratively searching for core points that satisfy equation (6). Figure 3As shown, there exists a point set Y, and point A is a point in this point set. Taking MinPts = 4 as an example, there are 4 points in the Eps neighborhood of point A, so point A is called the core point. Then, the other points in its search neighborhood are iteratively judged, that is, points B and D are marked as core points, and points C and E are marked as boundary points (the number of points in the Eps neighborhood is less than 4). Then, the iterative judgment is performed on points B and D until the Eps neighborhood contains only boundary points.
[0096]
[0097] In the formula, Eps(x0) is the set of neighborhood points of point x0, and D(x,x0) is the distance between point x and the core point x0. The number of neighborhood points of the core point x0.
[0098] Point cloud data is non-uniform, with varying point cloud densities in different areas. Features closer to the scanner often have higher point densities than those further away. Therefore, when directly using the DBSCAN algorithm for clustering, multiple cluster segments often appear in areas of low density, affecting subsequent building facade extraction results. To address this issue, this invention calculates the LPD of each point based on the Local Point Cloud Density (LPD) calculation method, combined with an optimal neighborhood point count calculation method. This LPD is then used as the neighborhood search radius for subsequent DBSCAN clustering.
[0099]
[0100] In the formula, LPD i Let d be the local point cloud density, k be the number of the best neighboring points of the current point, and d be the local point cloud density. kimax It is the farthest distance among the k nearest neighbors of the current point with the number of optimal neighbors (hereinafter referred to as the farthest distance of the current point).
[0101] The specific process for determining the optimal neighborhood search radius Eps for each point is as follows:
[0102] Step 1: Calculate the number of optimal neighboring points for each point using the method in Step 1, and then calculate the farthest distance d from the number of optimal neighboring points for each point. max The local point cloud density (LPD) of each point is obtained using formula (7). i .
[0103] Step 2: Based on the local point cloud density of all points, determine the median (LPD) of the local point cloud density for all points. m The local point cloud density is greater than the median of the local point cloud density of all points (LPD). m Point clouds with a density of 0 or less are classified into high-density point clouds, and point clouds with a density of 0 or less are classified into low-density point clouds, thus classifying all points into two categories.
[0104] Step 3: For each point in the low-density point cloud class, determine the median local point cloud density (LPD) of all points in that class of point cloud. sm Select the median LPD of the local point cloud density. sm The farthest distance of the corresponding point is used as the neighborhood search radius for DBSCAN clustering of each point in this type of point cloud; similarly, for each point in a high-density point cloud class, the median local point cloud density (LPD) of all points in this type of point cloud is determined. bm Select the median LPD of the local point cloud density. bm The farthest distance of the corresponding point is used as the neighborhood search radius for DBSCAN clustering of each point in this type of point cloud. Figure 4(a) shows the selection of the neighborhood search radius Eps when LPD is low, and Figure 4(b) shows the selection of the neighborhood search radius Eps when LPD is high.
[0105] 3. Using the neighborhood search radius of each point determined in step 2, the DBSCAN clustering algorithm is used to cluster the point cloud data after the filtering in step 1, thereby obtaining multiple cluster blocks.
[0106] Step 3: Further filter the clustering results from Step 2 to remove other features in the scene (such as trees and utility poles) to achieve accurate point cloud extraction of building facades.
[0107] After clustering using the LPD-DBSCAN algorithm, a small number of outliers still exist. In this step, outliers and small regions (cluster blocks with a total number of points less than T, where T is 20 in this embodiment) are further clustered. Although there are still many other features in the scene (such as trees and utility poles), after clustering, most individual buildings are presented as one category, so semantic rules can be used to perform fine extraction. After calculating the dimensionality features of each point based on the optimal neighborhood, the building facades are finely extracted based on the high proportion of linear and planar points of buildings and the large size of cluster blocks. The semantic rule selection conditions are shown in Equation (9).
[0108]
[0109] In the formula, n linearity n planarity n scattering These represent the number of linear, planar, and spherical points in the clustered blocks, calculated based on dimensionality features, respectively. n h is the threshold for the proportion of linear and planar points in a cluster block. hight l width These represent the height difference and maximum width of the cluster blocks, respectively, h. Δ l Δ These are the height difference threshold and the maximum width threshold, respectively.
[0110] The method will be applied to specific examples below to illustrate the effectiveness of the method of the present invention.
[0111] 1) Experimental Data. All experiments were conducted on a computer with an Intel(R) Core(TM) i7-108750H CPU @ 2.30GHz and 32GB RAM. Two public point cloud datasets obtained from different platforms were selected to verify the effectiveness of the method. The datasets are shown in Figures 5(a) and 5(b). Data 1 comes from a portion of the open-source dataset Robotic 3D Scan Repsitory-12, which was collected by a Riegl VZ-400 terrestrial laser scanner in a certain location. The scene contains six types of terrain features, including buildings, ground, trees, and cars, as shown in Figure 5(a). Data 2 comes from the Paris-rue-Madame open-source dataset, which was collected by an L3D2 mobile laser scanner on rue Madame street in Paris, France. The scene contains 26 types of terrain features, including buildings, ground, vegetation, and cars, as shown in Figure 5(b). It should be noted that the original point cloud data was large in size; therefore, it was downsampled during the experiment to improve computational efficiency.
[0112] 2) Evaluation Indicators. To quantitatively evaluate the performance of the method of the present invention, three indicators, namely correctness, completeness and F1 score, are used to evaluate the building facade extraction results. The specific calculation method is shown in Equation (10).
[0113]
[0114] In the formula, TP (True Positive) represents the number of building facade point clouds correctly extracted by the method, FP (False Positive) represents the number of building facade point clouds incorrectly extracted by the method, and FN (False Negative) represents the number of building facade point clouds not extracted by the method.
[0115] 3) Parameter settings. The method of this invention extracts building facades from experimental data. The main parameters involved include grid side length *s*, elevation difference number *M*, low-feature screening elevation *H*, minimum number of neighborhood points *MinPts* during LPD-DBSCAN clustering, and the threshold for the proportion of linear and planar points *δ*. n Clustering block height difference threshold h Δ and the maximum width threshold l Δ Seven parameters. Among them, if the value of s is too small, it will be difficult to filter out ground points; if it is too large, it will increase the corresponding error. In this embodiment, the value is mainly selected in the range of 1 to 2m; H is set to 3m; the cluster block size is set to 3m×3m; other parameter settings are shown in Table 1.
[0116] Table 1 Experimental parameter settings
[0117]
[0118] 4) Comparison of building facade extraction results.
[0119] ① Clustering Method Comparison. To verify the effectiveness of the LPD-DBSCAN algorithm proposed in this invention, building point cloud data from Experimental Data 1 was used as an example. Clustering was performed using both the DBSCAN algorithm and the LPD-DBSCAN algorithm proposed in this invention. The clustering results are shown in Figure 6(a) and Figure 6(b), respectively. It can be seen that the algorithm of this invention has significant advantages in scenarios with uneven density.
[0120] ② Comparison of different building facade extraction methods. To better evaluate the effectiveness of the method of this invention, three typical methods were selected for comparison with the method of this invention. Method 1: First, the scene point cloud is coarsely classified using the multi-rule region growing (MRG) method based on dimensionality features. Then, corresponding growth criteria are set for segmentation. Finally, the semantic rules of the building facade (segmentation block size h) are combined. p ×l p , normal vector direction range θ p Plane fitting residual T p Method 2: To compare the effectiveness of point cloud classification methods in extracting building facades, this experiment selected the outdoor point cloud classification tool in Trimble Realworks, a point cloud data processing software applicable to different scenarios, to classify the experimental data, thereby extracting the building facades. Method 3: The extraction process (hereinafter referred to as the EPSB method) mainly consists of two steps: removing ground points based on the z-coordinate and the angle between the normal vector and the z-direction; and performing Euclidean distance clustering on non-ground points, combining the areal point ratio of the cluster blocks and the maximum elevation difference to extract the building facades. The maximum terrain undulation h involved is also considered. t Threshold n of the angle between normal vectors t Euclidean clustering distance threshold L t The threshold for the proportion of area points K α The settings for parameters such as the maximum elevation difference ΔH are shown in Table 3.
[0121] The extraction results of the method of this invention and three comparative methods for two different scenarios are shown in Table 4. The true value results of the building facades for Data 1 and Data 2 are as follows: Figure 7(a) , 7(b)As shown in Figures 8(a), 9(a), 10(a), and 11(a), the extraction results and local detail effects of Data 1 extracted using the four methods are shown in Figures 8(b), 9(b), 10(b), and 11(b), respectively. In these figures, the black boxes represent magnified local areas, and the black circles represent areas where the methods are missing or incorrectly extracted.
[0122] Table 2 Parameters of the fine extraction stage of Method 1
[0123]
[0124] Table 3 Method 3 Parameters
[0125]
[0126] Table 4 Comparison of extraction results using different methods
[0127]
[0128] from Figures 8(a) to 10(b)As can be seen, all three comparison methods exhibit missing and incorrectly extracted regions. For the MRG method, the main reason is that in complex scenes, many small segments exist, making it difficult to set parameters when extracting buildings using semantic rules and easily leading to the accidental deletion of small building segments. Additionally, in Data 2, there is a groove on the ground (as shown by the black circle in Figure 8(b)), where the normal vectors of the ground points are disordered, preventing them from being merged with other ground points during the ground point region growing process. For the Realworks method, there are many missing regions (as shown by the black circle in Figure 9). The main reason for this is that the classification features selected by this method have limitations and are not suitable for building regions with poor quality and complex shapes. The main reason for the problems with the EPSB method is that the proportion of areal points calculated based on dimensional features varies in different building point clouds, making it difficult to select the threshold when extracting buildings after clustering, and easily resulting in missed extraction areas (as shown by the black circles in Figure 10(a)). Furthermore, in Data2, this method also suffers from a similar problem to the MRG method: the EPSB method cannot effectively filter out ground points in certain areas when using normal vectors to separate ground points (as shown by the black circles in Figure 10(b)). This causes the building point clouds on both sides to cluster into a single block, making it difficult to obtain good extraction results. Comparing Figures 7(a), 7(b) and 11(a), 11(b), it can be seen that, in stark contrast to the other three methods, the building extraction results of the method in this invention are closer to the true building values. The main reason is that: in the ground point removal stage, only elevation characteristics are needed, without relying on other geometric characteristics, so it is not affected by the terrain's unevenness and has stronger applicability; in the clustering stage, it can adaptively select the neighborhood search radius for clustering, which can solve the problem that the small cluster blocks caused by uneven density in local areas affect the subsequent fine extraction.
[0129] Based on the parameter settings for different methods in Tables 1-3 and Table 4 and Figures 8(a)-11(b) The point cloud extraction results of buildings obtained by different methods, combined with the above analysis of the reasons for missing and incorrectly extracted regions in different methods, can be summarized as follows:
[0130] ① The method of this invention is easier to set parameters, and the extraction results do not depend on the precise selection of parameters. The MRG method requires setting parameters such as principal direction and normal vector during the region growing stage, and the segmentation results are highly dependent on the selection of parameters. In the building extraction stage, setting only the segmentation block size and normal vector direction can easily lead to the wrong extraction of tree points. Therefore, it is necessary to further add constraints (such as plane fitting residuals) to obtain better extraction results. The EPSB method needs to continuously try the maximum undulation threshold according to the terrain undulation during the ground point removal stage. In the building extraction stage, it is necessary to control the proportion of areal points to prevent the wrong screening of buildings and the wrong extraction of other features.
[0131] ② In complex scenarios, the MRG algorithm produces smaller segmented blocks, hindering subsequent building extraction. Realworks' classification-based methods, due to limitations in classification features, are prone to missing extractions, and this method performs better in building extraction from vehicle-mounted point cloud data. While the EPSB method yields better results than the previous two methods, it is prone to missing and incorrect extractions. Compared to other methods, the method described in this invention provides generally good building point cloud extraction results, demonstrating advantages in completeness, accuracy, and F1 score.
[0132] In summary, based on the current practical needs of reconstructing 3D urban models, this invention proposes a method for extracting building facades using ground / vehicle-mounted LiDAR point cloud data, combining virtual grids and the LPD-DBSCAN algorithm. Experiments were conducted with data from two different scenarios. The results show that, compared to comparative methods, the proposed method achieves higher accuracy in building facade extraction, effectively extracting facades with uneven point cloud density distribution and varying degrees of shape complexity. Furthermore, this method is simple in principle, requiring no complex parameter settings or selection of complex architectural semantic rules, and possesses strong adaptability. It provides preliminary support for subsequent extraction of detailed building features (such as windows), geometric features (such as line and surface features), and building modeling, offering reliable building facade information for applications such as building reconstruction and refined urban management.
Claims
1. A method for extracting point clouds from building facades, characterized in that, include: 1) Determine each point in the acquired point cloud data The number of optimal neighborhood points and each point farthest distance ,point The farthest distance refers to that point The maximum distance between its nearest neighbors given the number of its optimal neighbors is determined as follows: : ① Set the initial number of neighboring points k0 of point p and use it as the current number of neighboring points; ② Find the three eigenvalues of point p given the current number of neighborhood points. , ; ③ Calculate the entropy value of point p with respect to the number of its current neighboring points. : ; ④ Based on the traversal range and step size of the neighborhood points, repeat steps ② to ③ to obtain the entropy value of each point within the traversal range; select the number of neighborhood points corresponding to the minimum entropy value as the entropy value of point p. ; 2) Based on each point of and Determine each point Local point cloud density : ; 3) According to each point The size divides all points into N classes, where N≥2; for a class of point cloud, the median of the local point cloud density of all points in the class of point cloud is determined, and the farthest distance of the point corresponding to the median of the local point cloud density is selected as the neighborhood search radius for DBSCAN clustering of each point in the class of point cloud, thereby determining the neighborhood search radius of each point in each class of point cloud. 4) Based on the neighborhood search radius of each point, the DBSCAN clustering method is used to cluster the point cloud data; 5) Based on the clustering results, extract the point cloud of the building facade.
2. The method for extracting point clouds of building facades according to claim 1, characterized in that, The traversal range is The traversal step size is: The traversal step size within the range is k △1 ,exist The traversal step size within the range is k △2 k △1 <k △2 .
3. The method for extracting point clouds from building facades according to claim 2, characterized in that, k △1 =1,k △2 =2。 4. The method for extracting point clouds of building facades according to claim 1, characterized in that, Before determining the optimal number of neighboring points for each point in the point cloud data in step 1), the acquired point cloud data needs to be filtered to remove low-lying ground features.
5. The method for extracting point clouds of building facades according to claim 4, characterized in that, The screening method includes the following steps: Project the point cloud data along the z-axis onto the corresponding two-dimensional grid plane, and divide the grid according to the set size to determine the grid where each point is located; Determine the elevation value of each point, find the elevation value corresponding to the lowest point among all points, calculate the elevation difference between the lowest point in each grid and the lowest point among all points, and subtract the elevation difference corresponding to the grid from the elevation value of each point in the grid. The result is the elevation distribution statistics of each point. The interval between the maximum and minimum values of the elevation distribution statistics is divided into M equally spaced intervals, M>1. The number of points in each equally spaced interval is counted. A frequency histogram is plotted with the equally spaced intervals as the x-axis and the number of points as the y-axis. A straight line is obtained by connecting the start and end points of the curve in the frequency histogram. The distance from each point on the curve to the straight line is calculated. The elevation value of the point corresponding to the maximum distance value is used as the elevation threshold for filtering ground points and non-ground points. Points with elevation values lower than the elevation threshold are filtered out.
6. The method for extracting point clouds of building facades according to claim 1, characterized in that, Step 5) requires the following three conditions to be met when extracting the point cloud of building facades: ; ; ; In the formula, These represent the number of linear, planar, and spherical points in the cluster blocks, respectively. This is the threshold for the proportion of linear and planar points in a cluster block. These represent the height difference and maximum width of the cluster blocks, respectively. These are the height difference threshold and the maximum width threshold, respectively.
7. The method for extracting point clouds of building facades according to claim 1, characterized in that, N=2, and the points are divided as follows: the median of the local point cloud density of all points is determined, and points whose local point cloud density is greater than the median of the local point cloud density of all points are classified as high-density point cloud points, otherwise they are classified as low-density point cloud points.
8. The method for extracting point clouds of building facades according to claim 5, characterized in that, When filtering, points within the grid whose elevation difference is less than the set elevation difference threshold and whose lowest elevation within the grid is greater than the average elevation of all points should be retained.