A Deep Learning-Based Method for Dimension Detection of Precast Wall Structures Based on Point Cloud
By using deep learning algorithms and point cloud data processing technology, the problems of low efficiency and insufficient accuracy of traditional detection methods have been solved, enabling efficient and accurate detection of wall dimensions, adapting to complex structures, providing intuitive visualization results, and improving construction quality control.
Patent Information
- Application Number
- CN202510639514.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-19
- Publication Date
- 2026-03-10
- Estimated Expiration
- 2045-05-19
Smart Images

Figure CN120612359B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of building engineering quality inspection technology, specifically a point cloud-based method for detecting the dimensions of prefabricated walls based on deep learning. Background Technology
[0002] With the rapid development of prefabricated building technology, prefabricated walls, as an important component of building structures, directly affect the overall safety and construction efficiency of buildings through their dimensional accuracy and quality control. Traditional methods for wall dimension inspection mainly rely on manual measurement or simple measuring tools. These methods have the following significant problems: First, manual measurement is inefficient and cannot meet the needs of rapid construction in large-scale prefabricated buildings; second, the measurement accuracy is limited and easily affected by human factors and environmental conditions, leading to inaccurate data; third, traditional methods are difficult to adapt to the dimension inspection of walls with complex structures, especially when the walls have special structures such as holes or uneven surfaces, which greatly increases the measurement difficulty and makes it difficult to guarantee the reliability of the results.
[0003] In modern construction engineering, accurate measurement of wall dimensions is crucial for ensuring construction quality, optimizing material usage, and improving construction efficiency. For example, in the production of precast walls, dimensional deviations can lead to inaccurate component installation, increasing construction costs and time. On the construction site, rapid measurement of wall dimensions can promptly detect damage during transportation or installation, preventing subsequent construction problems. Therefore, developing an efficient, accurate, and adaptable method for measuring wall dimensions has become a pressing technical challenge in the field of prefabricated buildings. Summary of the Invention
[0004] The technical problem to be solved by the present invention is to provide a point cloud-based method for detecting the dimensions of prefabricated walls, which integrates deep learning algorithms with point cloud data processing technology to achieve automated and high-precision detection of wall dimensions.
[0005] The technical solution of this invention is as follows:
[0006] A deep learning-based method for detecting the dimensions of prefabricated wall structures using point clouds includes the following steps:
[0007] (1) Collect point cloud data of the structural surface of the precast wall component to be tested and construct a point cloud image dataset;
[0008] (2) Preprocess the point cloud data in the point cloud image to remove noise points and redundant data points to obtain preprocessed point cloud data;
[0009] (3) Use a grid-based point cloud segmentation algorithm to separate the point cloud data of the prefabricated wall components from the point cloud image;
[0010] (4) Construct a PointNet model, extract feature points of the boundary of the precast wall components, and obtain the clusters of the boundary of the precast wall components through the DBSCAN density clustering algorithm. Calculate the length and width of the precast wall components based on the cluster information.
[0011] (5) In the point cloud image of the precast wall components, use visualization tools to visualize the point cloud and display the calculated length and width data of the precast wall components on the point cloud image.
[0012] The point cloud data of the structural surface of the prefabricated wall component to be tested was acquired using a 3D laser camera.
[0013] The specific steps for preprocessing the point cloud data are as follows:
[0014] S21. Downsampling processing: Select a set radius as... The point cloud space is divided into spheres. The point closest to the center of the sphere is selected as the sampling point to replace all points in the sphere. Only the sampling point of each sphere is retained in the point cloud, and the position of the sampling point does not move.
[0015] S22. Noise Reduction Processing: For each of the remaining sampling points, search its neighbor point set with a set given radius. When the number of neighbor points in the neighbor point set is less than the set minimum neighbor number threshold, mark the point as an outlier and remove it from the sampling points.
[0016] S23. Normalization processing: Normalize the remaining sampling points after denoising to eliminate scale differences in point cloud data, so that point cloud data of different sizes have the same scale.
[0017] The specific steps of the downsampling process are as follows:
[0018] S211. Select the center point of the sphere. Randomly select an initial point from the point cloud as the center point of the sphere. Then, search and confirm the points inside the sphere, that is, calculate the points in the point cloud relative to the center point. The distance will be no greater than the set radius. The points are included in the current sphere, as shown in the following formula (1):
[0019] (1);
[0020] In equation (1), Represents the set of points inside the current sphere. Represents a point within the current sphere. Represents a point in a point cloud. Represents the center point of the sphere. Represents Euclidean distance. Represents the set radius;
[0021] S212, The set of points within the current sphere In the middle, find the distance from the center point. nearest point As the sampling point of the current sphere, the sampling point replaces other points within the current sphere. The position of the sampling point does not change. The selection process is shown in equation (2) below:
[0022] (2);
[0023] In equation (2), Represents any point within the sphere other than the center point. Represents the center point of the sphere. Represents Euclidean distance;
[0024] S213. Update point cloud and sphere center: Remove all points inside the searched sphere, randomly select a new sphere center point from the remaining points in the point cloud, repeat steps S21 and S22 to search for points inside the sphere and update the sampling points of the sphere, until all points in the point cloud data have been searched and processed or the required number of sampling points has been reached.
[0025] The specific steps of the noise reduction process are as follows:
[0026] S221. For each sampling point Calculate its value at a given radius. Neighbor set , see the following formula (3) for details:
[0027] (3);
[0028] In equation (3), Representative sampling point and sampling points The Euclidean distance between them;
[0029] S222, when sampling point neighbor set The number of middle neighbor points is less than the set minimum neighbor number threshold. When this happens, the sampling point is removed from the sampling point set. .
[0030] The specific steps of the normalization process are as follows:
[0031] S231. Calculate the geometric center of the point cloud, as shown in the following formula (4):
[0032] (4);
[0033] In equation (4), This represents the geometric center of the point cloud composed of the remaining sampled points after denoising. This represents the total number of sampling points remaining after denoising. These are the coordinates of the i-th sampling point in the point cloud composed of the remaining sampling points after denoising;
[0034] S232. Translate the point cloud to a position with the geometric center as the origin, and update the coordinate data of the point cloud, as shown in the following formula (5):
[0035] (5);
[0036] In equation (5), Represents the coordinates of the sampled point after translation. Represents the sampled coordinates before translation ;
[0037] S233. Calculate the maximum distance from the origin to all denoised sampling points after translation. , see the following formula (6) for details:
[0038] (6);
[0039] S234. Scale the point cloud to a unit sphere so that the maximum distance between all points in the point cloud is 1, as shown in the following formula (7):
[0040] (7);
[0041] In equation (7), This represents the coordinates of the point after normalization.
[0042] The specific steps for separating the point cloud data of prefabricated wall components from the point cloud image using a grid-based point cloud segmentation algorithm are as follows:
[0043] S31. Define the mesh size and then perform mesh mapping, as shown in the following formula (8):
[0044] (8);
[0045] In equation (8), These are the coordinates of any point in the preprocessed point cloud data after grid mapping. These are the coordinates of any point in the preprocessed point cloud data. , , The three-dimensional dimensions of the mesh;
[0046] S32. Calculate the geometric features of the point cloud within each grid cell, including the normal vector and curvature, to provide necessary geometric information for subsequent segmentation. The consistency of the normal vector direction is the key basis for determining whether the point clouds belong to the same region. The calculation of the normal vector is shown in the following formula (9):
[0047] (9);
[0048] In equation (9), This represents the normal vector of the i-th grid cell. Represents the coordinates of a point within a grid cell. Represents the coordinates of the center point of the grid cell. Represents the number of points within a grid cell;
[0049] The curvature calculation first involves calculating the local covariance matrix of the i-th mesh element. , see the following formula (10) for details:
[0050] (10);
[0051] In equation (10), This represents the transpose operation;
[0052] Then calculate the covariance matrix. eigenvalues , and ,and Then calculate the curvature using the following formula (11). ;
[0053] (11);
[0054] S33. Calculate the data density of the point cloud within each grid cell, as shown in the following formula (12):
[0055] (12);
[0056] In equation (12), This represents the point cloud density of the i-th grid cell. Represents the volume of the i-th grid cell;
[0057] S34, Set threshold and Data density The grid cells within the threshold range are divided into wall point clouds, as shown in the following formula (13):
[0058] (13);
[0059] In equation (13), Representative wall dot cloud;
[0060] S35. Geometric feature-based segmentation: Based on the normal vector and curvature geometric features, the segmentation results are further refined to remove mis-segmented point clouds in the background. The specific steps are as follows:
[0061] The normal vectors of all mesh elements are calculated based on equation (9). The mesh elements with inconsistent normal vector directions are filtered out.
[0062] Calculate the unit normal vector between any two points within a single grid cell in the remaining grid cells. and The angle between , see the following formula (14) for details:
[0063] (14);
[0064] In equation (14), and It is the unit normal vector between any two points within a single grid cell. Represents the magnitude of the vector;
[0065] Set the maximum normal angle of the structural surface of the precast wall component. When the angle between all normal vectors within a grid cell All are not greater than If the condition is met, the grid cell is preliminarily determined to be a structural surface of a precast wall component; otherwise, the point cloud data in the grid cell is filtered and removed.
[0066] Then, curvature determination is performed, and a curvature threshold is set. When the i-th grid cell calculated by equation (11) Not greater than If the condition is met, the grid cell is determined to be a structural surface of the precast wall component, and the point cloud data of the precast wall component is separated from the point cloud image. Otherwise, the point cloud data in the grid cell is filtered and removed, and the remaining point cloud data in the grid cell is the point cloud data of the precast wall component.
[0067] The steps for calculating the unit normal vector of a point within a single grid cell are as follows:
[0068] First, select any point within a single grid cell. Construct its neighborhood point set :
[0069] ;
[0070] Calculate the set of neighboring points center point , see the following formula (15) for details:
[0071] (15);
[0072] In equation (15), Representative point The neighborhood points are the points in the point cloud data that are far from the point. The nearest point; Represents the set of neighboring points The total number of points in the middle neighborhood;
[0073] Then the center point Neighborhood point set Substitute all neighboring points into equation (10) to calculate the set of neighboring points. The local covariance matrix, In the substitution formula (10) , In the substitution formula (10) , In the substitution formula (10) ;
[0074] Then calculate the neighborhood point set eigenvalues of the local covariance matrix , and ,and , , and Each corresponds to one of the three feature vectors. , and The smallest eigenvalue corresponding feature vector That is, a point The normal vector is normalized according to the following equation (16) to obtain the point. unit normal vector ;
[0075] (16);
[0076] In equation (16), It is a point The corresponding unit normal vector, Represents the magnitude of the vector.
[0077] The specific steps for constructing the PointNet model, extracting feature points of the precast wall component boundaries, obtaining clusters of the precast wall component boundaries using the DBSCAN density clustering algorithm, and calculating the length and width of the precast wall components based on the cluster information are as follows:
[0078] S41. Construct the PointNet model. The PointNet model includes an input layer, a feature extraction layer, a global feature layer, and an output layer.
[0079] The input layer is used to input the point cloud data of the precast wall components. The three-dimensional coordinate information of each point is as follows: ;
[0080] The feature extraction layer extracts features from each point using multiple fully connected layers and the ReLU activation function. The initial features of the m-th point in the point cloud data of the precast wall component are: After processing by the fully connected layer of the j-th layer and the ReLU activation function, new features are obtained. ,in and These are the weights and biases of the j-th layer in the feature extraction layer;
[0081] The global feature layer aggregates the features of all points through max pooling to obtain the global features. , Represents the local features of each point. It is the index of the last layer of the feature extraction layer;
[0082] The output layer is used to process global features After passing through the fully connected layer, the final result is output, which is the global features first. Broadcast to each point, then compare with the local features of each point. By piecing together the data, the combined features of each point are formed. , The process involves concatenating the data, followed by calculating the probability that each point belongs to a boundary point using a fully connected layer and a sigmoid activation function. , see the following formula (17) for details;
[0083] (17);
[0084] In equation (17), and These are the weights and biases of the fully connected layers in the output layer. Represents the sigmoid activation function;
[0085] S42. Set a probability threshold. ,Will Greater than The points are identified as feature points of the boundary of the precast wall components;
[0086] S43. Using the DBSCAN density clustering algorithm, clusters are obtained for the boundary portion of the precast wall components. First, the neighborhood radius is set. The minimum number of points (minPts) is calculated, and then the feature points of the identified precast wall component boundaries are input into the DBSCAN density clustering algorithm. The set of feature points of the precast wall component boundaries is then obtained. Feature points The coordinates are The DDBSCAN density clustering algorithm is used to divide the feature points of the boundary of the prefabricated wall components into multiple clusters, each cluster representing a boundary part of the wall.
[0087] S44, The set of feature points for a boundary portion of the wall is: Feature points The coordinates are Calculate the centroid coordinates of each boundary region. , see the following formula (18) for details:
[0088] (18);
[0089] In equation (18), Representative point set The total number of midpoints;
[0090] S45. Calculate the length and width of the wall: The centroids of the left and right boundary portions of the wall are respectively... and ,but and The coordinates are respectively and The centroids of the upper and lower boundary portions of the wall are respectively and ,but and The coordinates are respectively and Then the length of the wall and width The results are obtained by calculation using equations (19) and (20) respectively.
[0091] (19);
[0092] (20).
[0093] Advantages of this invention:
[0094] (1) The present invention preprocesses the collected point cloud data, specifically including downsampling, denoising and normalization. Through the orderly arrangement of the above preprocessing processes, the point cloud image dataset is cleaned, noise points and redundant data are reduced, and the efficiency of subsequent point cloud data extraction and clustering is improved.
[0095] (2) The present invention uses a grid-based point cloud segmentation algorithm to separate the point cloud data of the precast wall components from the point cloud image, which can effectively separate the point cloud data of the precast wall components from the background, providing a basis for subsequent geometric feature extraction and size measurement.
[0096] (3) The present invention constructs a PointNet model, extracts feature points of the boundary of prefabricated wall components, and obtains the boundary points of prefabricated wall components through the DBSCAN density clustering algorithm. The PointNet model can directly learn global features from point cloud data. Specifically, it performs independent feature extraction on each point and then obtains global features through max pooling. The DBSCAN density clustering algorithm can automatically determine the number of clusters and has good robustness to noise points.
[0097] (4) The present invention can calculate the length and width of the precast wall components based on the boundary point coordinates of the precast wall components, and display them on the point cloud image to present the wall size data intuitively, so that construction personnel can complete the quality control of the wall based on the wall size data. Attached Figure Description
[0098] Figure 1 This is a flowchart of the present invention. Detailed Implementation
[0099] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0100] See Figure 1 A method for detecting the dimensions of prefabricated walls based on point clouds using deep learning, specifically including the following steps:
[0101] (1) Use a 3D laser camera to collect point cloud data of the structural surface of the precast wall component to be tested, and construct a point cloud image dataset;
[0102] (2) Preprocess the point cloud data in the point cloud image to remove noise points and redundant data points to obtain preprocessed point cloud data;
[0103] The specific steps for preprocessing point cloud data are as follows:
[0104] S21. Downsampling processing, specifically:
[0105] S211. Select the center point of the sphere. Randomly select an initial point from the point cloud as the center point of the sphere. Then, search and confirm the points inside the sphere, that is, calculate the points in the point cloud relative to the center point. The distance will be no greater than the set radius. The points are included in the current sphere, as shown in the following formula (1):
[0106] (1);
[0107] In equation (1), Represents the set of points inside the current sphere. Represents a point within the current sphere. Represents a point in a point cloud. Represents the center point of the sphere. Represents Euclidean distance. Represents the set radius;
[0108] S212, The set of points within the current sphere In the middle, find the distance from the center point. nearest point As the sampling point of the current sphere, the sampling point replaces other points within the current sphere. The position of the sampling point does not change. The selection process is shown in equation (2) below:
[0109] (2);
[0110] In equation (2), Represents any point within the sphere other than the center point. Represents the center point of the sphere. Represents Euclidean distance;
[0111] S213. Update point cloud and sphere center: Remove all points inside the searched sphere, randomly select a new sphere center point from the remaining points in the point cloud, and repeat steps S21 and S22 to search for points inside the sphere and update the sphere's sampling points until all points in the point cloud data have been searched and processed or the required number of sampling points has been reached.
[0112] S22. Noise reduction processing, specifically:
[0113] S221. For each sampling point Calculate its value at a given radius. Neighbor set , see the following formula (3) for details:
[0114] (3);
[0115] In equation (3), Representative sampling point and sampling points The Euclidean distance between them;
[0116] S222, when sampling point neighbor set The number of middle neighbor points is less than the set minimum neighbor number threshold. When this happens, the sampling point is removed from the sampling point set. ;
[0117] S23. Normalization Processing: Normalization processing is performed on the remaining sampling points after denoising to eliminate scale differences in the point cloud data, ensuring that point cloud data of different sizes have the same scale. Specifically:
[0118] S231. Calculate the geometric center of the point cloud, as shown in the following formula (4):
[0119] (4);
[0120] In equation (4), This represents the geometric center of the point cloud composed of the remaining sampled points after denoising. This represents the total number of sampling points remaining after denoising. These are the coordinates of the i-th sampling point in the point cloud composed of the remaining sampling points after denoising;
[0121] S232. Translate the point cloud to a position with the geometric center as the origin, and update the coordinate data of the point cloud, as shown in the following formula (5):
[0122] (5);
[0123] In equation (5), Represents the coordinates of the sampled point after translation. Represents the sampled coordinates before translation ;
[0124] S233. Calculate the maximum distance from the origin to all denoised sampling points after translation. , see the following formula (6) for details:
[0125] (6);
[0126] S234. Scale the point cloud to a unit sphere so that the maximum distance between all points in the point cloud is 1, as shown in the following formula (7):
[0127] (7);
[0128] In equation (7), Represents the coordinates of the point after normalization;
[0129] (3) Use a grid-based point cloud segmentation algorithm to separate the point cloud data of the prefabricated wall components from the point cloud image. The specific steps are as follows:
[0130] S31. Define the mesh size and then perform mesh mapping, as shown in the following formula (8):
[0131] (8);
[0132] In equation (8), These are the coordinates of any point in the preprocessed point cloud data after grid mapping. These are the coordinates of any point in the preprocessed point cloud data. , , The three-dimensional dimensions of the mesh;
[0133] S32. Calculate the geometric features of the point cloud within each grid cell, including the normal vector and curvature. The calculation of the normal vector is shown in the following formula (9):
[0134] (9);
[0135] In equation (9), This represents the normal vector of the i-th grid cell. Represents the coordinates of a point within a grid cell. Represents the coordinates of the center point of the grid cell. Represents the number of points within a grid cell;
[0136] The curvature calculation first involves calculating the local covariance matrix of the i-th mesh element. , see the following formula (10) for details:
[0137] (10);
[0138] In equation (10), This represents the transpose operation;
[0139] Then calculate the covariance matrix. eigenvalues , and ,and Then calculate the curvature using the following formula (11). ;
[0140] (11);
[0141] S33. Calculate the data density of the point cloud within each grid cell, as shown in the following formula (12):
[0142] (12);
[0143] In equation (12), This represents the point cloud density of the i-th grid cell. Represents the volume of the i-th grid cell;
[0144] S34, Set threshold and Data density The grid cells within the threshold range are divided into wall point clouds, as shown in the following formula (13):
[0145] (13);
[0146] In equation (13), Representative wall dot cloud;
[0147] S35. Geometric feature-based segmentation: Based on the normal vector and curvature geometric features, the segmentation results are further refined to remove mis-segmented point clouds in the background. The specific steps are as follows:
[0148] The normal vectors of all mesh elements are calculated based on equation (9). The mesh elements with inconsistent normal vector directions are filtered out.
[0149] Calculate the unit normal vector between any two points within a single grid cell in the remaining grid cells. and The angle between , see the following formula (14) for details:
[0150] (14);
[0151] In equation (14), Represents the magnitude of the vector; and It is the unit normal vector between any two points within a single grid cell. The steps for calculating the unit normal vector of a point within a single grid cell are as follows:
[0152] First, select any point within a single grid cell. Construct its neighborhood point set :
[0153] ;
[0154] Calculate the set of neighboring points center point , see the following formula (15) for details:
[0155] (15);
[0156] In equation (15), Representative point neighborhood points, Represents the set of neighboring points The total number of middle neighbor points, ;
[0157] Then the center point Neighborhood point set Substitute all neighboring points into equation (10) to calculate the set of neighboring points. The local covariance matrix, In the substitution formula (10) , In the substitution formula (10) , In the substitution formula (10) ;
[0158] Then calculate the neighborhood point set eigenvalues of the local covariance matrix , and ,and , , and Each corresponds to one of the three feature vectors. , and The smallest eigenvalue corresponding feature vector That is, a point The normal vector is normalized according to the following equation (16) to obtain the point. unit normal vector ;
[0159] (16);
[0160] In equation (16), It is a point The corresponding unit normal vector, Represents the magnitude of the vector;
[0161] Set the maximum normal angle of the structural surface of the precast wall component. When the angle between all normal vectors within a grid cell All are not greater than If the condition is met, the grid cell is preliminarily determined to be a structural surface of a precast wall component; otherwise, the point cloud data in the grid cell is filtered and removed.
[0162] Then, curvature determination is performed, and a curvature threshold is set. When the i-th grid cell calculated by equation (11) Not greater than If the condition is met, the grid cell is determined to be a structural surface of the precast wall component, that is, the point cloud data of the precast wall component is separated from the point cloud image. Otherwise, the point cloud data in the grid cell is filtered and removed, and the remaining point cloud data in the grid cell is the point cloud data of the precast wall component.
[0163] (4) Construct a PointNet model, extract feature points of the boundaries of precast wall components, and obtain the boundary points of the precast wall components using the DBSCAN density clustering algorithm. Calculate the length and width of the precast wall components based on the coordinate information of the boundary points. The specific steps are as follows:
[0164] S41. Construct the PointNet model. The PointNet model includes an input layer, a feature extraction layer, a global feature layer, and an output layer.
[0165] The input layer is used to input the point cloud data of the precast wall components. The three-dimensional coordinate information of each point is as follows: ;
[0166] The feature extraction layer extracts features from each point using multiple fully connected layers and the ReLU activation function. The initial features of the m-th point in the point cloud data of the precast wall component are: After processing by the fully connected layer of the j-th layer and the ReLU activation function, new features are obtained. ,in and These are the weights and biases of the j-th layer in the feature extraction layer;
[0167] The global feature layer aggregates the features of all points through max pooling to obtain the global features. , Represents the local features of each point. It is the index of the last layer of the feature extraction layer;
[0168] The output layer is used to process global features After passing through the fully connected layer, the final result is output, which is the global features first. Broadcast to each point, then compare with the local features of each point. By piecing together the data, the combined features of each point are formed. , The process involves concatenating the data, followed by calculating the probability that each point belongs to a boundary point using a fully connected layer and a sigmoid activation function. , see the following formula (17) for details;
[0169] (17);
[0170] In equation (17), and These are the weights and biases of the fully connected layers in the output layer. Represents the sigmoid activation function;
[0171] S42. Set a probability threshold. ,Will Greater than The points are identified as feature points of the boundary of the precast wall components;
[0172] S43. Using the DBSCAN density clustering algorithm, clusters are obtained for the boundary portion of the precast wall components. First, the neighborhood radius is set. The minimum number of points (minPts) is calculated, and then the feature points of the identified precast wall component boundaries are input into the DBSCAN density clustering algorithm. The set of feature points of the precast wall component boundaries is then obtained. Feature points The coordinates are The DDBSCAN density clustering algorithm is used to divide the feature points of the boundary of the prefabricated wall components into multiple clusters, each cluster representing a boundary part of the wall.
[0173] S44, The set of feature points for a boundary portion of the wall is: Feature points The coordinates are Calculate the centroid coordinates of each boundary region. , see the following formula (18) for details:
[0174] (18);
[0175] In equation (18), Representative point set The total number of midpoints;
[0176] S45. Calculate the length and width of the wall: The centroids of the left and right boundary portions of the wall are respectively... and ,but and The coordinates are respectively and The centroids of the upper and lower boundary portions of the wall are respectively and ,but and The coordinates are respectively and Then the length of the wall and width The results are obtained by calculation using equations (19) and (20) respectively.
[0177] (19);
[0178] (20);
[0179] (5) In the point cloud image of the precast wall components, use visualization tools to visualize the point cloud and display the calculated length and width data of the precast wall components on the point cloud image. The specific steps are as follows:
[0180] S51. First, mark the dimension data by marking the length and width data of the detected prefabricated wall components on the point cloud visualization interface.
[0181] S52. Draw dimension lines on the point cloud visualization interface to display the measured dimension range; the dimension line consists of two parallel lines and a vertical line connecting the two parallel lines, with dimension values marked on the vertical line; and add text annotations, adding text labels to the point cloud visualization interface to display the specific values of the dimension data, specifically marking "length" and "width" on the upper and left edges of the precast wall components respectively.
[0182] Performance Analysis:
[0183] A total of 304 wall datasets were collected for the experiment, including 246 training datasets and 58 test datasets. These datasets contain prefabricated wall panels of different specifications and sizes. In this experiment, a wall dataset of 304 samples was collected to cover prefabricated wall panels of different specifications and sizes, ensuring data diversity and representativeness. To fully utilize the data and reasonably evaluate model performance, the dataset was divided into training and test sets. The training dataset, containing 246 samples (approximately 81% of the total), was used for model training and optimization; the test dataset, containing 58 samples (approximately 19% of the total), was used for model testing and evaluation.
[0184] The detection method in this embodiment of the invention is compared with the traditional Candy operator detection method. The comparison results are shown in Table 1 below. In this experiment, the embodiment of the invention uses a combination of the PointNet model and the BSCAN density clustering algorithm to extract and calculate the length and width dimensions of the prefabricated components. The traditional Candy operator detection method has certain limitations in extracting dimension information, especially when processing complex shapes and high-density point cloud data, where its efficiency and accuracy are relatively poor.
[0185] This embodiment, based on the PointNet model and BSCAN density clustering algorithm, achieves significant optimizations in both average detection time and average detection error, resulting in an overall detection performance improvement of approximately 30% compared to the Candy operator detection method. This improvement not only enhances the efficiency and accuracy of precast component size detection but also provides stronger technical support for precast component quality control and production management, demonstrating significant practical application value.
[0186] Table 1
[0187]
[0188] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their equivalents.
Claims
1. A deep learning-based point cloud precast wall size detection method, characterized by: Specifically comprising the following steps: (1) Point cloud data of the structure surface of the wall prefabricated component to be tested is collected to obtain a point cloud image dataset; (2) The point cloud data in the point cloud image is preprocessed to remove noise points and redundant data points, and the preprocessed point cloud data is obtained; (3) The point cloud data of the wall prefabricated component is separated from the point cloud image using a grid-based point cloud segmentation algorithm, and the specific steps are as follows: S31, define the grid size, then perform grid mapping, see formula (8) below: (8); In formula (8), is the coordinate of any point in the preprocessed point cloud data after grid mapping, is the coordinate of any point in the preprocessed point cloud data, , , is the three-dimensional size of the grid; S32, calculate the geometric features of the point cloud in each grid unit, including the normal vector and the curvature, which provide necessary geometric information for subsequent segmentation, and the direction consistency of the normal vector is the key basis for judging whether the point cloud belongs to the same region, see formula (9) below: (9); In formula (9), a normal vector representing the i-th grid cell, a coordinate representing a point within the grid cell, a coordinate representing a center point of the grid cell, a number of points within the grid cell; The calculation of the curvature first calculates the local covariance matrix of the i-th grid cell , as shown in the following equation (10): (10); In formula (10), represents a transpose operation; The eigenvalues of the covariance matrix , , and are then calculated, and the curvature is calculated according to equation (11) (11); S33, calculate the data density of the point cloud in each grid unit, see formula (12) below: (12); In formula (12), a point cloud density representing the i-th grid cell, a volume representing the i-th grid cell; S34, set a threshold value and data density Grid cells within the threshold range are divided into wall point clouds, as shown in the following formula (13): (13); In formula (13), represent the wall point cloud; S35, based on the segmentation of geometric features, further refine the segmentation results according to the normal vector and curvature geometric features, and remove the misclassified point cloud in the background, and the specific steps are as follows: Based on formula (9), the normal vectors of all grid units are calculated, and the grid units with inconsistent normal vector directions are screened out; calculating an angle between the unit normal vectors of any two points within a single grid cell in the remaining grid cells and between the unit normal vectors of any two points within a single grid cell in the remaining grid cells , specifically as follows (14): (14); In formula (14), and is the unit normal vector of any two points within a single grid cell, denotes the magnitude of the vector. Setting the maximum normal vector included angle of wall prefabricated component structural surface When all normal vector included angles in the grid unit are not greater than , it is preliminarily determined that the grid unit belongs to the structural surface of the wall prefabricated component, otherwise the point cloud data in the grid unit is screened and removed; Then curvature determination is performed, and a curvature threshold is set When the i-th grid cell calculated by formula (11) Not greater than Then it is finally determined that the grid cell belongs to the structural surface of the wall prefabricated part, that is, the point cloud data of the wall prefabricated part is separated from the point cloud image, otherwise, the point cloud data in the grid cell is screened and removed, and the remaining point cloud data in the grid cell is the point cloud data of the wall prefabricated part; (4) A PointNet model is constructed to extract feature points of the wall prefabricated component boundary, and a clustering cluster of the wall prefabricated component boundary part is obtained through a DBSCAN density clustering algorithm, and the length and width of the wall prefabricated component are calculated according to the clustering cluster information, and the specific steps are as follows: S41, construct a PointNet model, which includes an input layer, a feature extraction layer, a global feature layer, and an output layer; The input layer is used for inputting point cloud data of the wall prefabricated component, and three-dimensional coordinate information of each point is ; The feature extraction layer extracts features of each point through a plurality of fully connected layers and ReLU activation functions, and the initial feature of the mth point in the wall prefabricated component point cloud data is After being processed by the jth fully connected layer and the ReLU activation function, a new feature is obtained, where and are the weight and bias of the jth layer in the feature extraction layer. The global feature layer aggregates the features of all points through a max-pooling operation to obtain a global feature , representing the local feature of each point, is an index of the last layer of the feature extraction layer; The output layer is used to combine the global feature After the fully connected layer, the final result is output, i.e., first broadcast the global feature to each point, then concatenate with the local feature of each point to form the comprehensive feature of each point , representing the concatenation, then calculate the probability of each point belonging to the boundary point through the fully connected layer and the sigmoid activation function , see formula (17) for details; (17); In formula (17), and are weights and biases of the fully connected layer in the output layer, represents a sigmoid activation function; S42, set a probability threshold , the greater than points are identified as the feature points of the wall prefabricated component boundary; S43, obtain the clustering cluster of the wall prefabricated component boundary part through the DBSCAN density clustering algorithm, first set the neighborhood radius and the minimum point number minPts, then input the identified feature points of the wall prefabricated component boundary into the DBSCAN density clustering algorithm, the feature point set of the wall prefabricated component boundary is , the coordinates of the feature points are , the feature points of the wall prefabricated component boundary are divided into multiple clustering clusters through the DBSCAN density clustering algorithm, and each clustering cluster represents a boundary part of the wall. S44, the feature point set of one boundary part of the wall body is , the coordinates of the feature point , the centroid coordinates of each boundary part are calculated , see the following formula (18) for details: (18); In formula (18), representative point set total number of midpoints; S45, calculating the length and width of the wall: the center of mass of the left and right two boundary parts of the wall are respectively and , then and coordinates are respectively and ; the center of mass of the upper and lower two boundary parts of the wall are respectively and , then and coordinates are respectively and ; then the length and the width of the wall are calculated by the following formula (19) and formula (20) respectively; (19); (20); (5) In the point cloud image of the wall prefabricated component, a visualization tool is used to visualize the point cloud, and the calculated length and width data of the wall prefabricated component are displayed on the point cloud image.
2. The deep learning-based point cloud precast wall size detection method according to claim 1, characterized in that: The point cloud data of the structure surface of the wall prefabricated component to be tested is collected using a 3D laser camera.
3. The deep learning-based point cloud precast wall size detection method according to claim 1, characterized in that: The specific steps of preprocessing the point cloud data are as follows: S21, downsampling processing: selecting a sphere with a set radius of The point cloud space is segmented, and the closest point to the center of the sphere is selected as a sampling point to replace all points in the sphere. Only the sampling points of each sphere are retained in the point cloud, and the position of the sampling points does not move. S22, denoising: for each point in the remaining sampling points, search its neighbor point set through a given radius, and when the number of neighbor points in the neighbor point set is less than the set minimum neighbor number threshold, mark the point as an outlier and remove it from the sampling points; S23, normalization: normalize the remaining sampling points after denoising to eliminate the scale difference of the point cloud data, so that point cloud data of different sizes have the same scale.
4. The deep learning-based point cloud precast wall size detection method according to claim 3, characterized in that: The specific steps of downsampling processing are as follows: S211. Select the center point of the sphere. Randomly select an initial point from the point cloud as the center point of the sphere. Then, search and confirm the points inside the sphere, that is, calculate the points in the point cloud relative to the center point. The distance will be no greater than the set radius. The points are included in the current sphere, as shown in the following formula (1): (1); In formula (1), represent a set of points within a current sphere, represent a point within a current sphere, represent a point in a point cloud, represent a center point of a sphere, represent a Euclidean distance, represent a set radius; S212, a set of points in the current sphere The closest point to the center point is found , as the sampling point of the current sphere, other points in the current sphere are replaced by the sampling point, the position of the sampling point does not move, and the sampling point The selection process of the sampling point is shown in the following formula (2): (2); In formula (2), represents any point in the current sphere except the center point, represents the center point of the sphere, represents the Euclidean distance; S213, update the point cloud and the sphere center: remove all points in the searched sphere, randomly select a new sphere center point from the remaining points of the point cloud, and repeat steps S21 and S22 to search for points in the sphere and update the sampling points of the sphere until all points in the point cloud data are searched and processed or the required number of sampling points is reached.
5. The deep learning-based point cloud precast wall size detection method according to claim 3, characterized in that: The specific steps of denoising are as follows: S221、For each sampling point , calculate its neighbor point set within a given radius , see formula (3) below: (3); In formula (3), represent the Euclidean distance between the sampling points and the sampling points ; S222、when the number of neighbor points in the neighbor point set of the sampling point is less than a set minimum neighbor number threshold , then remove the sampling point from the sampling point set . .
6. The deep learning-based point cloud precast wall size detection method according to claim 3, characterized in that: The specific steps of normalization are as follows: S231, calculate the geometric center of the point cloud, see formula (4) below: (4); In formula (4), represents the geometric center of the point cloud composed of the remaining sampling points after denoising, represents the total number of the remaining sampling points after denoising, is the coordinate of the i-th sampling point in the point cloud composed of the remaining sampling points after denoising. S232, the point cloud is translated to a position with the geometric center as the origin, and the coordinate data of the point cloud is updated, and the specific formula (5) is as follows: (5); In formula (5), represent the translated sample point coordinates, represent the sample coordinates before translation ; S233、Calculate the maximum distance of all denoised sampling points after translation to the origin See the following formula (6) for details: (6); S234, the point cloud is scaled into a unit sphere, so that the maximum distance of all points in the point cloud is 1, and the specific formula (7) is as follows: (7); In formula (7), represents the normalized point coordinates.
7. The deep learning-based point cloud precast wall size detection method according to claim 1, characterized in that: The calculation step of the unit normal vector of the point in the single grid unit is: First, select an arbitrary point in a single grid cell , construct its neighborhood set : ; Computing a set of neighborhood points of the center point Specifically, see equation (15) below: (15); In formula (15), representative point neighbor points of the representative point, are the points in the point cloud data closest to the representative point; representative point total number of neighbor points in the neighbor point set representative point The center point , the neighborhood point set , all neighborhood points in the neighborhood point set are brought into formula (10) to calculate the local covariance matrix of the neighborhood point set , , , , , ; Then calculate the neighborhood point set eigenvalues of the local covariance matrix , and ,and , , and Corresponding to three feature vectors respectively , and The smallest eigenvalue Corresponding feature vector That is, a point The normal vector is normalized according to the following equation (16) to obtain the point. unit normal vector ; (16); In formula (16), is a point a corresponding unit normal vector, denotes the vector length.
Citation Information
Patent Citations
Outdoor large-scale scene 3D point cloud registration method based on isolated cluster removal
CN117745780A
Hybrid model-based bridge member geometric feature determination method
CN119941827A