Building plane segmentation method based on three-dimensional point cloud

文档序号:9334 发布日期:2021-09-17 浏览:28次 中文

1. A building plane segmentation method based on three-dimensional point cloud data is characterized by comprising the following steps:

step 1: and roughly dividing the building plane by using a region growing algorithm, and removing roughly extracted plane points from original building points to obtain residual point data.

Step 2: the boundary points of the coarse plane are extracted using the maximum value of the angle between vectors formed between a point on the tangent plane and its neighboring points.

And step 3: and obtaining the corner points of the intersection of the two planes according to the distance threshold from the residual points to the boundary points of the extracted rough plane, and combining the roughly extracted plane points with the corresponding corner points to obtain the optimal plane segmentation.

2. The method for building plane segmentation based on three-dimensional point cloud data according to claim 1, wherein the step 1 further comprises:

and carrying out coarse extraction on the building plane by adopting a region growing algorithm. The idea of this algorithm is to select the point with the smallest curvature as the initial seed point. And the adjacent points of the seed point meet the included angle value between the normal vector of the point and the normal vector of the current seed point. Furthermore, their curvature values are smaller than the set curvature values. These are considered new seed points and region growing continues until the seed point sequence is empty. The adjacency points are considered to belong to the same plane. The specific process is as follows:

(1) the curvatures for all points are calculated and the minimum curvature point is added to the set of seed points.

(2) And calculating the normal vectors of the current seed point and the adjacent points thereof. And if the adjacent point of the current seed point not only meets the included angle value between the normal vector of the point and the normal vector of the current seed point, but also the curvature value is smaller than the set curvature value, the adjacent point reaches the seed point sequence.

(3) Deleting the current seed point, regarding the adjacent points as new seed points, and continuing the growth of the region.

(4) This process will continue until the seed point sequence is empty.

3. The method for building plane segmentation based on three-dimensional point cloud data according to claim 1, wherein the step 2 further comprises: after obtaining normal vectors of all the points, judging whether the normal vectors are positioned on the boundary of the plane by using the maximum included angle criterion of the vectors formed by the points and the adjacent points on the tangent plane. A suitable number of boundary points are required to calculate the distance of the remaining points to the boundary points of the crude extraction plane. If the angle threshold is too small, many interior points will be considered as boundary points. If the angle threshold is too large, some boundary points may be lost. The process of extracting the boundary points of the rough extraction plane is as follows:

(1) the normal vector of a curved surface consisting of one point and its neighboring points is calculated. The tangent plane is calculated from the normal vector.

(2) These points are projected onto the tangent plane.

(3) The angle between the vectors formed by these adjacent points on the tangent plane is calculated.

(4) If the maximum included angle between the adjacent vectors is larger than a set threshold value, the vectors are regarded as boundary points; otherwise, the interior point is considered.

4. The method for building plane segmentation based on three-dimensional point cloud data according to claim 1, wherein the step 3 further comprises: and after the boundary point is obtained, extracting a coplanar point intersected by the two planes by using a distance threshold value from the residual point to the boundary point of the crude extraction plane, wherein the residual point is obtained by removing the crude extraction plane point from the original point of the building. And combining the roughly extracted plane points with the corresponding coplanar points to obtain the optimal plane segmentation.

Background

With the rapid development of urbanization in China, the rapid growth of urban population and the rapid demand of smart city construction, a three-dimensional building model becomes an important component of a digital city, and is widely applied in the fields of urban planning, environmental simulation, cultural heritage protection and the like. The building plane contains rich and intuitive detail information and is an indispensable or indispensable component for building three-dimensional modeling. Building plane point cloud segmentation is a precondition and a foundation for realizing digital city three-dimensional model reconstruction, and how to extract building plane information from point cloud data with high efficiency and high precision becomes one of important tasks of building three-dimensional reconstruction. The building plane data is mainly obtained by three methods: aerial photogrammetry, depth cameras and lidar scanners, which may provide dense point cloud data of building planes. Detailed texture patterns of planar features of buildings can be obtained by aerial photogrammetry. The depth camera may record the distance of an object to the camera. The laser radar scanner can acquire high-density and high-precision geometric structure information of objects at different positions and can provide a three-dimensional building model of high-quality point cloud data.

The traditional segmentation algorithm designs feature descriptors according to some basic characteristics of the point cloud, such as geometric features, color information and the like, and then establishes a feature filter based on the feature descriptors for segmentation. The conventional method mainly comprises: 1) hough Transform (Hough Transform): the Hough transform is mainly used to detect geometric shapes (such as straight lines, planes and circles) with given features. 2) Random sample consensus algorithm (RANSAC): the RANSAC algorithm detects a plane by estimating mathematical model parameters and performs point cloud data plane segmentation. 3) The region growing algorithm: region growing algorithms are classical methods of detecting planes, circles and other parametric shapes. The basic idea of the algorithm is to find out a seed pixel randomly in a segmentation region, take the seed pixel as an initial point, gather pixels with similar characteristics to the seed pixel in a neighboring region in the initial point region to obtain a new pixel, and grow the obtained new pixel as a new seed pixel until no pixels with similar characteristics to the seed pixel exist in the neighboring region. Although, the region growing algorithm may segment the building planes. But results in the absence of intersection points of two planes, and the RANSAC algorithm causes excessive segmentation of the planes. The Hough transform algorithm has large calculation amount, occupies a large amount of memory and exponentially increases the calculation complexity and the memory capacity along with the increase of parameters and data amount because each point needs to participate in multiple times of voting. Therefore, most studies combine the region growing algorithm with other methods to detect the building plane, and although these methods can extract the point cloud data of the building plane, the operation is complex.

Disclosure of Invention

In order to accurately divide the building plane from the three-dimensional point cloud data, the invention combines a region growing algorithm with a distance algorithm based on boundary points, and provides a building plane dividing method based on three-dimensional point cloud.

The technical scheme adopted by the invention is as follows: a building plane segmentation method based on three-dimensional point cloud is characterized by comprising the following steps:

step 1: and roughly dividing the building plane by using a region growing algorithm, and removing points of the roughly extracted plane from the original building points to obtain residual point data.

Step 2: the boundary points of the coarse plane are extracted by using the maximum value of the included angle between the vectors formed between the point on the tangent plane and the adjacent points.

And step 3: and obtaining the corner points of the intersection of the two planes according to the distance threshold from the residual points to the boundary points of the extracted rough plane, and combining the roughly extracted plane points with the corresponding corner points to obtain the optimal plane segmentation.

For the building plane segmentation algorithm, due to the fact that Hough transformation is large in calculation amount and large in occupied memory, the RANSAC algorithm is prone to generate excessive segmentation, and the region growing algorithm is prone to lack of intersection points of two planes. The invention provides a building plane point cloud segmentation algorithm by combining a region growing algorithm and a distance algorithm based on boundary points. Compared with RANSAC algorithm, the method can not only segment different targets on the same plane without excessive segmentation, but also acquire the angular point which can not be extracted by the region growing algorithm and is intersected by the two planes.

Drawings

FIG. 1 is a flow chart of an embodiment of the present invention;

FIG. 2 is a diagram of boundary point extraction according to an embodiment of the present invention, (a) raw data, (b) boundary point extraction result;

FIG. 3 is an original point cloud of cottage according to an embodiment of the present invention;

FIG. 4 is an original point cloud of a rectangle in an embodiment of the present invention;

FIG. 5 is a graph of the result of the planar segmentation of cottage according to the embodiment of the present invention;

FIG. 6 is a graph showing the result of plane segmentation of the rectangle in the embodiment of the present invention.

Detailed Description

The present invention will be described in further detail with reference to the accompanying drawings, which are provided for the purpose of facilitating understanding of the present invention and are not intended to limit the present invention.

Referring to fig. 1, the invention provides a building plane segmentation method based on three-dimensional point cloud, which comprises the following specific steps:

1. crude extraction of the plane

Region growing is a segmentation algorithm based on spatial proximity and homogeneity. The invention adopts a region growing algorithm to carry out coarse extraction on the building plane. The normal vector and the curvature are basic characteristics of the curved surface and are important bases for identifying the characteristics of the curved surface. And performing rough extraction on the plane by using a region growing algorithm, and estimating normal vectors and curvatures of sampling points to obtain plane segmentation. The invention estimates normal vectors and curvatures of points by using a curved surface consisting of adjacent points, and calculates normal vectors of points by using principal component analysis or eigenvectors and eigenvalues of covariance matrices generated by the adjacent points. p is a radical ofiIf the covariance matrix C is any point on the plane, the corresponding covariance matrix C is:in the formula, n is piNumber of adjacent points of (1), psBeing the center of the adjacent points. p is a radical ofiThe normal vector of (a) is:wherein λjIs the jth eigenvalue of the covariance matrix,is the jth feature vector. The normal vector is the eigenvector corresponding to the smallest eigenvalue. Due to the fact thatCharacteristic value lambda012Represents the degree of variation of a point with three main directions, so piCan be approximated as:wherein λ012Is the eigenvalue of the covariance matrix.

The specific process of the region growing and dividing algorithm comprises the following steps: 1) the curvatures for all points are calculated and the minimum curvature point is added to the set of seed points. 2) And calculating the normal vectors of the current seed point and the adjacent points thereof. And if the adjacent point of the current seed point not only meets the included angle value of the normal vector of the point and the normal vector of the current seed point, but also the curvature value of the adjacent point is smaller than the set curvature value, the adjacent point reaches the seed point sequence. 3) Deleting the current seed point, regarding the adjacent points as new seed points, and continuing the growth of the region. 4) This process will continue until the seed point sequence is empty.

2. Boundary point extraction

The boundary points of the rough extraction plane are extracted according to the maximum value of the vector included angle formed by the points on the tangent plane and the adjacent points. After obtaining normal vectors of all the points, judging whether the normal vectors are positioned on the boundary of the plane by using the maximum included angle criterion of the vectors formed by the points and the adjacent points on the tangent plane. An appropriate number of boundary points need to be extracted to calculate the distance of the remaining points to the boundary points of the crude extraction plane. If the angle threshold is too small, many interior points will be considered as boundary points. If the angle threshold is too large, some boundary points may be lost (as in FIG. 2).

And (3) boundary point extraction process of the rough extraction plane: 1) the normal vector of a curved surface consisting of one point and its neighboring points is calculated. The tangent plane is calculated from the normal vector. 2) These points are projected onto the tangent plane. 3) The angle between the vectors formed by these adjacent points on the tangent plane is calculated. 4) If the maximum included angle between the adjacent vectors is larger than a set threshold value, the vectors are regarded as boundary points; otherwise, the interior point is considered.

3. Optimal plane acquisition

After the boundary points are obtained, the residue is utilizedAnd extracting a coplanar point where the two planes intersect by using a distance threshold value from the point to the boundary point of the crude extraction plane. The residual points are obtained by removing crude extraction plane points from the original points of the building. The remaining points are denoted by P (x, y, z). The boundary point of the coarse extraction plane is denoted as Q (l, m, n). The distance d (P, Q) from the remaining points to the boundary points is:

and finally, obtaining the corner points of intersection of the two planes according to the distance threshold from the residual points to the boundary points of the extracted rough plane, and combining the roughly extracted plane points with the corresponding corner points to obtain the optimal plane segmentation. Fig. 3 and 4 are the original point cloud data of the building, and fig. 5 and 6 are the plane segmentation results of the present invention.

The above description is only one embodiment of the present invention, and not all or only one embodiment, and any equivalent modifications of the technical solutions of the present invention may be adopted by those skilled in the art within the protection scope of the present invention without departing from the protection scope of the present invention as defined by the appended claims.

完整详细技术资料下载
上一篇:石墨接头机器人自动装卡簧、装栓机
下一篇:一种三维图像的切割方法及电子设备

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!