Electric power tower point cloud registration method and device fusing normal vector clustering
Through the combination of normal vector clustering and iterative nearest point algorithm, the problems of low point cloud registration accuracy and poor convergence are solved, and the precise registration and structural identification of the point cloud data of the power pole tower are achieved.
Patent Information
- Application Number
- CN202411287485.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-13
- Publication Date
- 2024-12-17
AI Technical Summary
When the existing point cloud registration method processes point cloud data with large differences in density and resolution, it has low accuracy and poor algorithm convergence, which has failed to effectively solve the registration problems of sparse point clouds and dense point clouds.
Using the method of fusion vector clustering, point cloud data is divided into voxels, normal vectors are calculated through principal component analysis algorithm, clustering algorithm divides clusters, selects representative point clouds, match point clouds using binary tree search algorithm, and iterates through The nearest point algorithm calculates the transformation parameters until the preset convergence error range is reached.
The accuracy and convergence speed of point cloud registration are improved, the structure of power pole towers is effectively identified, point cloud data of different densities and resolutions are distinguished, and the registration accuracy reduction problem caused by density and resolution differences is overcome.
Smart Images

Figure CN119151998A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of point cloud registration or other related fields, and in particular to a method and device for point cloud registration of a power tower integrating normal vector clustering. Background Art
[0002] With the development of drones, lidar and 3D reconstruction, point cloud data is increasingly used in the power industry. Point cloud data provides rich data information for the inspection and maintenance of power towers by capturing the 3D geometric information of objects, and plays a huge role in the planning and maintenance of power systems. Point cloud data usually exists in the form of points, and each point contains its coordinate information in 3D space. In the power industry, it is crucial to effectively align these point cloud data. Through alignment, different point cloud data can be ensured to maintain consistency and accuracy, providing a reliable basis for the analysis and research of power towers.
[0003] In the related art, point cloud registration methods include iterative closest point algorithms. The iterative closest point algorithm achieves registration by finding the minimum distance between two sets of point cloud data. This algorithm usually assumes that the two sets of input point cloud data have the same density and resolution. However, in practical applications, due to the limitations of sensor performance and the influence of environmental factors, as well as different scanning angles and distances, the collected point cloud data often have different densities and resolutions, that is, there are sparse point clouds and dense point clouds. Sparse point clouds usually refer to point cloud data with fewer data points that cannot completely cover the surface information of objects. Dense point clouds refer to point cloud data that contains more data points and can describe the surface features of objects in detail. When processing point cloud data with large differences in density and resolution, the registration accuracy of the iterative closest point algorithm will be reduced, and it may even fail to converge to the correct registration result.
[0004] To address the above-mentioned problems, no effective solution has been proposed yet. Summary of the invention
[0005] The embodiment of the present invention provides a method and device for power tower point cloud registration integrating normal vector clustering, so as to at least solve the technical problems of low point cloud registration accuracy and poor algorithm convergence in the related art.
[0006] According to one aspect of an embodiment of the present invention, a method for point cloud registration of a power tower integrating normal vector clustering is provided, comprising: scanning a power tower to obtain point cloud data, dividing the point cloud data into different voxels, wherein a voxel is a spatial cube and each voxel contains one or more point cloud data; using a principal component analysis algorithm to calculate the normal vectors of all point cloud data in each voxel, using a clustering algorithm to divide all point cloud data in each voxel into different clusters, and determining a representative point cloud of each cluster; selecting a target point cloud and a source point cloud from the representative point clouds, and using a binary tree search algorithm to determine a matching point cloud of each source point cloud in the target point cloud to obtain a plurality of matching pairs; using an iterative closest point algorithm to calculate transformation parameters of the matching pairs, calculating a registration error based on the matching pairs and the transformation parameters, and merging the source point cloud and the target point cloud when the registration error reaches a preset convergence error range.
[0007] Optionally, the step of scanning the power pole tower to obtain point cloud data and dividing the point cloud data into different voxels includes: using a laser scanner to scan the power pole tower from different perspectives to obtain point cloud data; using a geographic information system to preprocess the point cloud data, the preprocessing includes removing noise data and irrelevant data of the point cloud data, wherein the irrelevant data includes tree point clouds and obstacle point clouds; based on the distribution density of the point cloud data and a preset voxel size, dividing the point cloud space into multiple voxels of equal size, wherein the point cloud space is the spatial range covered by all point cloud data; based on the coordinates of the point cloud data in the point cloud space, dividing the point cloud data into different voxels.
[0008] Optionally, the step of using a principal component analysis algorithm to calculate the normal vector of each point cloud data includes: calculating the covariance matrix of each point cloud data; performing eigendecomposition on the covariance matrix to obtain multiple eigenvalues and their corresponding eigenvectors; and determining the eigenvector corresponding to the minimum eigenvalue as the normal vector of the point cloud data.
[0009] Optionally, a clustering algorithm is used to divide the point cloud data into different clusters, and the steps of determining the representative point cloud of each cluster include: for different cluster numbers, calculating the sum of the squares of the distances from all normal vectors to the cluster center closest to them; based on the sum of the squares of the distances, determining the target cluster number, and dividing the point cloud data into different clusters based on the target cluster number; based on each cluster, determining the point cloud data closest to the cluster center as the representative point cloud of the cluster; sorting all representative point clouds and adding an index to each representative point cloud.
[0010] Optionally, a binary tree search algorithm is used to determine the matching point cloud of each source point cloud in the target point cloud to obtain a plurality of matching pairs, including: selecting a subset of points from the source point cloud and the target point cloud as new source point cloud and target point cloud; calculating the distance between the source point cloud and the target point cloud to establish a binary tree for the target point cloud; based on the binary tree, determining the matching point cloud of each source point cloud in the target point cloud to obtain a plurality of matching pairs; removing matching pairs whose distance from the source point cloud to the target point cloud exceeds a preset threshold; and assigning weights to each matching pair based on the distance between the source point cloud and the target point cloud in the matching pair.
[0011] Optionally, the transformation parameters include a rotation matrix and a translation vector, and the steps of calculating the transformation parameters of the matching pair using an iterative closest point algorithm include: calculating the center of mass of the source point cloud and the target point cloud, wherein the center of mass is the center position of the source point cloud and the target point cloud; based on the center of mass, calculating the covariance matrix between the source point cloud and the target point cloud in the matching pair; performing singular value decomposition on the covariance matrix to obtain a rotation matrix; and based on the rotation matrix, calculating the translation vector.
[0012] Optionally, the step of calculating the transformation parameters of the matching pair using an iterative closest point algorithm also includes: defining an error function, which is used to evaluate the alignment quality; inputting the matching pair and its corresponding transformation parameters into the error function to obtain the alignment error; performing Taylor expansion processing on the error function to obtain an error linear system; solving the error linear system to obtain new transformation parameters, and iteratively updating the coordinates of the source point cloud and the target point cloud in the matching pair.
[0013] According to another aspect of an embodiment of the present invention, there is also provided a power pole tower point cloud registration device integrating normal vector clustering, comprising: a scanning unit, used to scan the power pole tower to obtain point cloud data, and divide the point cloud data into different voxels, wherein the voxel is a spatial cube, and each voxel contains one or more point cloud data; a clustering unit, used to calculate the normal vector of all point cloud data in each voxel using a principal component analysis algorithm, and divide all point cloud data in each voxel into different clusters using a clustering algorithm, and determine the representative point cloud of each cluster; a matching unit, used to select a target point cloud and a source point cloud from the representative point cloud, and determine the matching point cloud of each source point cloud in the target point cloud using a binary tree search algorithm to obtain multiple matching pairs; an iteration unit, used to calculate the transformation parameters of the matching pair using an iterative nearest point algorithm, calculate the registration error based on the matching pair and the transformation parameters, and merge the source point cloud and the target point cloud when the registration error reaches a preset convergence error range.
[0014] Optionally, the scanning unit includes: an acquisition module, which is used to use a laser scanner to scan the power pole tower from different perspectives to obtain point cloud data; a preprocessing module, which is used to use a geographic information system to preprocess the point cloud data, the preprocessing includes removing noise data and irrelevant data of the point cloud data, wherein the irrelevant data includes tree point clouds and obstacle point clouds; a first division module, which divides the point cloud space into multiple voxels of equal size based on the distribution density of the point cloud data and a preset voxel size, wherein the point cloud space is the spatial range covered by all point cloud data; a second division module, which divides the point cloud data into different voxels based on the coordinates of the point cloud data in the point cloud space.
[0015] Optionally, the clustering unit includes: a first calculation module, used to calculate the covariance matrix of each point cloud data; a first decomposition module, used to perform eigendecomposition on the covariance matrix to obtain multiple eigenvalues and their corresponding eigenvectors; a first determination module, used to determine the eigenvector corresponding to the minimum eigenvalue as the normal vector of the point cloud data.
[0016] Optionally, the clustering unit includes: a second calculation module, which is used to calculate the sum of the squares of the distances from all normal vectors to the nearest cluster center for different cluster numbers; a second determination module, which determines the target cluster number based on the sum of the squares of the distances, and divides the point cloud data into different clusters based on the target cluster number; a third determination module, which determines the point cloud data closest to the cluster center as the representative point cloud of the cluster based on each cluster; and a sorting module, which is used to sort all representative point clouds and add an index to each representative point cloud.
[0017] Optionally, the matching unit includes: a selection module, used to select a subset of points from the source point cloud and the target point cloud as new source point cloud and target point cloud; a third calculation module, used to calculate the distance between the source point cloud and the target point cloud, and establish a binary tree for the target point cloud; a fourth determination module, based on the binary tree, determines the matching point cloud of each source point cloud in the target point cloud to obtain multiple matching pairs; a removal module, used to remove matching pairs in which the distance from the source point cloud to the target point cloud exceeds a preset threshold; an allocation module, which assigns weights to each matching pair based on the distance between the source point cloud and the target point cloud in the matching pair.
[0018] Optionally, the iteration unit includes: a fourth calculation module, used to calculate the center of mass of the source point cloud and the target point cloud, wherein the center of mass is the center position of the source point cloud and the target point cloud; a fifth calculation module, based on the center of mass, calculates the covariance matrix between the source point cloud and the target point cloud in the matching pair; a second decomposition module, used to perform singular value decomposition on the covariance matrix to obtain a rotation matrix; and a sixth calculation module, based on the rotation matrix, calculates a translation vector.
[0019] Optionally, the iteration unit also includes: a definition module, used to define an error function, which is used to evaluate the quality of registration; an input module, used to input the matching pairs and their corresponding transformation parameters into the error function to obtain the registration error; an expansion module, used to perform Taylor expansion processing on the error function to obtain an error linear system; an update module, used to solve the error linear system to obtain new transformation parameters, and iteratively update the coordinates of the source point cloud and the target point cloud in the matching pair.
[0020] According to another aspect of an embodiment of the present invention, a computer-readable storage medium is also provided, wherein the computer-readable storage medium includes a stored computer program, wherein when the computer program is running, the device where the computer-readable storage medium is located is controlled to execute any one of the above-mentioned power tower point cloud registration methods integrating normal vector clustering.
[0021] According to another aspect of an embodiment of the present invention, there is also provided an electronic device, comprising one or more processors and a memory, wherein the memory is used to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement any one of the above-mentioned power tower point cloud registration methods integrating normal vector clustering.
[0022] According to another aspect of an embodiment of the present invention, a computer program product is further provided, including a computer program, which, when executed by a processor, implements the steps of any one of the above-mentioned methods for power tower point cloud registration integrating normal vector clustering.
[0023] In the present disclosure, point cloud data is obtained by scanning power poles and towers, and the point cloud data is divided into different voxels. The principal component analysis algorithm is used to calculate the normal vectors of all point cloud data in each voxel. The clustering algorithm is used to divide all point cloud data in each voxel into different clusters, and the representative point cloud of each cluster is determined. Then, the target point cloud and the source point cloud are selected from the representative point cloud, and the matching point cloud of each source point cloud is determined in the target point cloud by a binary tree search algorithm to obtain multiple matching pairs. Finally, the iterative closest point algorithm is used to calculate the transformation parameters of the matching pairs, and the registration error is calculated based on the matching pairs and the transformation parameters. When the registration error reaches a preset convergence error range, the source point cloud and the target point cloud are merged to achieve accurate registration of the point cloud data of the power pole tower. The present invention can effectively identify the structure of power poles and towers through the calculation of normal vectors and the application of clustering algorithms, maintain the geometric features of power poles and towers during the registration process, and improve the registration accuracy. Through voxelization processing, it can effectively distinguish point cloud data of different densities and resolutions, and overcome the defect of reduced registration accuracy when processing point cloud data with large differences in density and resolution. The matching point cloud is searched through a binary tree search algorithm, combined with error calculation and parameter updating, which significantly improves the convergence speed of registration, thereby solving the technical problems of low point cloud registration accuracy and poor algorithm convergence in related technologies. BRIEF DESCRIPTION OF THE DRAWINGS
[0024] The drawings described herein are used to provide a further understanding of the present invention and constitute a part of this application. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings:
[0025] Figure 1 is a flow chart of an optional power tower point cloud registration method integrating normal vector clustering according to an embodiment of the present invention;
[0026] Figure 2 is a schematic diagram of an optional power tower point cloud registration method integrating normal vector clustering according to an embodiment of the present invention;
[0027] Figure 3 is a schematic diagram of an optional power tower point cloud registration device integrating normal vector clustering according to an embodiment of the present invention;
[0028] Figure 4 It is a hardware structure block diagram of an electronic device (or mobile device) for a power pole tower point cloud registration method integrating normal vector clustering according to an embodiment of the present invention. DETAILED DESCRIPTION
[0029] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.
[0030] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0031] It should be noted that the power pole tower point cloud registration method and device integrated with normal vector clustering in the present disclosure can be used in the field of point cloud registration technology. When the power pole tower point cloud data is registered by integrating normal vector clustering, it can also be used in any field except the field of point cloud registration technology. When the power pole tower point cloud data is registered by integrating normal vector clustering, the present disclosure does not limit the application field of the power pole tower point cloud registration method and device integrated with normal vector clustering.
[0032] The following embodiments of the present invention can be applied to various systems / applications / devices for point cloud registration of power towers fused with normal vector clustering. The present invention obtains point cloud data by scanning the power tower, divides the point cloud data into different voxels, can effectively distinguish point cloud data of different densities and resolutions, calculates the normal vectors of all point cloud data in each voxel by using the principal component analysis algorithm, divides all point cloud data in each voxel into different clusters by using the clustering algorithm, determines the representative point cloud of each cluster, can effectively identify the structure of the power tower, maintains the geometric features of the power tower during the registration process, improves the registration accuracy, selects the target point cloud and the source point cloud from the representative point cloud, and uses the binary tree search algorithm to determine the matching point cloud of each source point cloud in the target point cloud, obtains multiple matching pairs, and significantly improves the convergence speed of the registration, finally calculates the transformation parameters of the matching pair by using the iterative closest point algorithm, calculates the registration error based on the matching pair and the transformation parameters, and merges the source point cloud and the target point cloud when the registration error reaches the preset convergence error range, thereby realizing the accurate registration of the point cloud data of the power tower.
[0033] The present invention is described in detail below in conjunction with various embodiments.
[0034] Embodiment 1
[0035] According to an embodiment of the present invention, an embodiment of a method for point cloud registration of power towers integrating normal vector clustering is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.
[0036] Figure 1 is a flow chart of an optional power tower point cloud registration method integrating normal vector clustering according to an embodiment of the present invention, such as Figure 1 As shown, the method comprises the following steps:
[0037] Step S101 : Scan the power pole tower to obtain point cloud data, and divide the point cloud data into different voxels, wherein a voxel is a space cube, and each voxel contains one or more point cloud data.
[0038] Point cloud data is a collection of a large number of points used to represent the surface features of objects or scene features in three-dimensional space. Point cloud data is usually obtained by 3D scanners, laser radars, stereo cameras and other equipment. Point cloud data is widely used. In the power industry, point cloud data is obtained by regularly scanning power towers and analyzing them to understand the deformation, cracks, corrosion and other conditions of power tower structures and to detect safety hazards in a timely manner.
[0039] After scanning the power pole tower to obtain point cloud data, the embodiment of the present invention divides the point cloud data into different voxels. Voxels are small cubes in the point cloud space, and the point cloud space is the spatial range covered by all point cloud data. The embodiment of the present invention divides the point cloud space into a number of voxels of equal size, and then divides all power pole tower point cloud data into corresponding voxels according to their coordinates in the point cloud space. By performing such voxelization processing on the point cloud data, point cloud data of different densities and resolutions can be effectively distinguished, overcoming the problem of reduced registration accuracy of the iterative closest point algorithm when processing point cloud data with large differences in density and resolution.
[0040] Optionally, the step of scanning the power pole tower to obtain point cloud data and dividing the point cloud data into different voxels includes: using a laser scanner to scan the power pole tower from different perspectives to obtain point cloud data; using a geographic information system to preprocess the point cloud data, the preprocessing includes removing noise data and irrelevant data of the point cloud data, wherein the irrelevant data includes tree point clouds and obstacle point clouds; based on the distribution density of the point cloud data and a preset voxel size, dividing the point cloud space into multiple voxels of equal size, wherein the point cloud space is the spatial range covered by all point cloud data; based on the coordinates of the point cloud data in the point cloud space, dividing the point cloud data into different voxels.
[0041] In the process of scanning the power pole tower to obtain point cloud data and dividing the point cloud data into different voxels, the embodiment of the present invention uses a laser scanner to obtain the point cloud data of the power pole tower. A laser scanner is a device that uses lasers to collect three-dimensional spatial data. It determines the three-dimensional coordinates of the surface points of objects in space by emitting laser beams and measuring the time or phase difference of laser reflection or scattering back, as well as the angles of laser emission and reception, thereby generating point cloud data. The embodiment of the present invention uses a laser scanner to scan the power pole tower from different perspectives to obtain point cloud data of the power pole tower at different perspectives.
[0042] Then, a geographic information system is used to pre-process the point cloud data. A geographic information system is a computer system used to store, analyze, manage and display geographic spatial data. It can help users better understand and predict geographical phenomena through spatial analysis and data visualization. The embodiment of the present invention uses a geographic information system to pre-process the collected power pole tower point cloud data. The pre-processing process includes removing noise data and irrelevant data in the point cloud data, wherein the irrelevant data is usually object data other than power pole towers, such as tree point clouds, vehicles, buildings and other obstacle point clouds.
[0043] After collecting and preprocessing the point cloud data, the embodiment of the present invention divides the point cloud data into different voxels. In the process of voxelization, it is first necessary to divide the point cloud space into a number of voxels of the same size. The point cloud space is the three-dimensional space range covered by all power tower point cloud data. Based on the distribution density of the point cloud data and the preset voxel size, the point cloud space is divided into a plurality of small cubes of equal size, each small cube being a voxel. Each point cloud data is divided into corresponding voxels according to its coordinates in the point cloud space, and each voxel can contain one or more point cloud data.
[0044] It should be noted that the embodiment of the present invention encodes the position of each voxel and assigns a voxel index to each voxel. The voxel index of the voxel with coordinates (i, j, k) is:
[0045] idx=i+j×numDivX+k×numDivX×numDivY;
[0046] Where idx is the voxel index of the voxel with coordinates (i, j, k), i, j, k are the coordinates in the X, Y, and Z dimensions respectively, and numDivX and numDivY are the number of voxels along the dimensions and dimensions respectively. By performing encoded linear index processing for each voxel, the voxel position in the three-dimensional space can be encoded into a one-dimensional linear index, which is convenient for storing and retrieving voxels in the computer.
[0047] Step S102 : using a principal component analysis algorithm to calculate the normal vectors of all point cloud data in each voxel, using a clustering algorithm to divide all point cloud data in each voxel into different clusters, and determining a representative point cloud of each cluster.
[0048] Principal component analysis is a statistical strategy that can transform data into a set of independent components, reduce data dimensions, and retain data features. The embodiment of the present invention uses principal component analysis to calculate the normal vectors of all point cloud data in each voxel, and based on the normal vectors, a clustering algorithm is used to divide these point cloud data into different clusters, and the representative point cloud of each cluster is determined. The clustering algorithm can use the K-means clustering algorithm to cluster all the point cloud data in each voxel to obtain multiple different clusters, each cluster contains one or more point cloud data, and one or more point cloud data are selected from these point cloud data as the representative point cloud of this cluster, which is used in the subsequent point cloud data registration step.
[0049] The embodiment of the present invention can effectively identify the structure of the power tower by calculating and clustering the normal vector of the point cloud data, and can further maintain the geometric features of the power tower in the subsequent point cloud data registration step, thereby improving the accuracy of the registration.
[0050] Optionally, the step of using a principal component analysis algorithm to calculate the normal vector of each point cloud data includes: calculating the covariance matrix of each point cloud data; performing eigendecomposition on the covariance matrix to obtain multiple eigenvalues and their corresponding eigenvectors; and determining the eigenvector corresponding to the minimum eigenvalue as the normal vector of the point cloud data.
[0051] When using the principal component analysis algorithm to calculate the normal vector of each point cloud data, the covariance matrix of each point cloud data must be calculated first. The formula of the covariance matrix is:
[0052]
[0053] Among them, C is the covariance matrix of the point cloud data, k is the number of the nearest neighbors of the point cloud data, and p i ,i=1:k is the nearest neighbor point cloud data, is the average value of all nearest neighbor point cloud data. The nearest neighbor point cloud data is the k point cloud data closest to the point cloud data in the same voxel. The number of nearest neighbor point cloud data k can be set by yourself. The point cloud data is a three-dimensional vector. The average value of all nearest neighbor point cloud data It is also a three-dimensional vector, which is obtained by calculating the average value of each coordinate component of all nearest neighbor point cloud data in the X, Y, and Z dimensions.
[0054] After the covariance matrix of the point cloud data is calculated, the covariance matrix is subjected to eigenvalue decomposition to obtain multiple independent eigenvalues and their corresponding eigenvectors. In the embodiment of the present invention, the eigenvector corresponding to the minimum eigenvalue is determined as the normal vector of the point cloud data.
[0055] Optionally, a clustering algorithm is used to divide the point cloud data into different clusters, and the steps of determining the representative point cloud of each cluster include: for different cluster numbers, calculating the sum of the squares of the distances from all normal vectors to the cluster center closest to them; based on the sum of the squares of the distances, determining the target cluster number, and dividing the point cloud data into different clusters based on the target cluster number; based on each cluster, determining the point cloud data closest to the cluster center as the representative point cloud of the cluster; sorting all representative point clouds and adding an index to each representative point cloud.
[0056] In the step of using a clustering algorithm to divide point cloud data into different clusters, the embodiment of the present invention needs to determine the number of divided clusters. The embodiment of the present invention uses the Elbow strategy to determine the size of K in the K-means clustering algorithm, that is, the number of divided clusters.
[0057] In the El bow strategy, the number of clusters K is usually tested starting from 1. For different numbers of clusters, after running the clustering algorithm on all point cloud data in a voxel, K clusters can be obtained, and the error calculation is performed on these K clusters. The clustering error is the sum of the squares of the distances between the normal vectors of all point cloud data in a voxel and its nearest cluster center, which can be expressed as:
[0058]
[0059] Among them, WCSS k is the clustering error of cluster number K, x i is the normal vector of the point cloud data, n is the number of normal vectors of all point cloud data, μ j is the cluster center closest to the normal vector, c kis the set of cluster centers. By calculating the clustering error for each possible number of clusters K, the number of clusters and its corresponding sum of squared distances are plotted in the graph. Since more clusters mean that the distance between the points in each cluster and its cluster center is smaller, the sum of squared distances usually decreases as the number of clusters increases. By finding the "elbow" point in the graph, that is, the point where the curve of the sum of squared distances in the graph decreases significantly, the point can be determined as the most appropriate number of clusters K. The "elbow" point usually means that the effect of continuing to increase the number of clusters on reducing the sum of squared distances is no longer significant. If the number of clusters is increased further, the computational complexity and the risk of overfitting will also increase, but the effect of reducing the sum of squared distances is very weak. Under such risks, it is no longer worthwhile to continue to increase the number of clusters, so the "elbow" point is determined as the optimal number of clusters.
[0060] After determining the number of clusters, the embodiment of the present invention clusters all point cloud data in a voxel based on the number of clusters to obtain K clusters. In each cluster, the point cloud data closest to the cluster center is determined as the representative point cloud of the cluster. All representative point clouds are then sorted and an index is added to each representative point cloud.
[0061] By selecting the representative point cloud of each cluster, the originally complex point cloud data can be simplified into a smaller set, reducing the complexity of the calculation and the amount of data that needs to be processed during the point cloud data registration process. By sorting and adding indexes to the determined representative point clouds, the point cloud data can be quickly queried and accessed during the point cloud data registration process, improving the registration efficiency.
[0062] Step S103 , selecting a target point cloud and a source point cloud from the representative point cloud, and using a binary tree search algorithm to determine a matching point cloud of each source point cloud in the target point cloud to obtain a plurality of matching pairs.
[0063] In an embodiment of the present invention, after obtaining the representative point cloud, the target point cloud and the source point cloud are selected in the representative point cloud, and a binary tree search algorithm is used to determine the matching point cloud of each source point cloud to obtain multiple matching pairs, each matching pair includes a source point cloud and a target point cloud, and after the matching pairs are updated and iterated by the iterative nearest point algorithm, the source point cloud and the target point cloud will be rotated and translated, and finally merged to achieve the registration of the point cloud data.
[0064] The target point cloud is usually the side scanning points of the power tower, while the point clouds from other perspectives are usually the source point clouds. The binary tree search algorithm is a search algorithm for finding specific elements in a binary tree data structure. It can quickly query the target element through the branch structure of the binary tree without traversing the entire data set. The embodiment of the present invention uses a binary tree search algorithm to search in the target point cloud to find the most suitable matching point cloud for each source point cloud. The source point cloud is paired with the found matching point cloud to obtain a matching pair for the subsequent point cloud registration process.
[0065] Optionally, a binary tree search algorithm is used to determine the matching point cloud of each source point cloud in the target point cloud to obtain a plurality of matching pairs, including: selecting a subset of points from the source point cloud and the target point cloud as new source point cloud and target point cloud; calculating the distance between the source point cloud and the target point cloud to establish a binary tree for the target point cloud; based on the binary tree, determining the matching point cloud of each source point cloud in the target point cloud to obtain a plurality of matching pairs; removing matching pairs whose distance from the source point cloud to the target point cloud exceeds a preset threshold; and assigning weights to each matching pair based on the distance between the source point cloud and the target point cloud in the matching pair.
[0066] When the embodiment of the present invention uses a binary tree search algorithm to determine the matching point cloud of each source point cloud in the target point cloud, a subset of points will be selected from the source point cloud and the target point cloud to reduce the amount of calculation and improve the efficiency of the algorithm. Then the distance from all source point clouds to all target point clouds is calculated, and a binary tree is established for the target point cloud. The binary tree stores the coordinates of the target point cloud and the distance from the target point cloud to the source point cloud. Then, based on the binary tree, a binary tree search algorithm is used to find the matching point cloud of each source point cloud in the target point cloud. The matching point cloud is usually the target point cloud closest to the source point cloud, that is, the target point cloud with the smallest distance from the source point cloud.
[0067] After determining the matching point cloud of each source point cloud, multiple matching pairs are obtained. The embodiment of the present invention will remove the matching pairs whose distance from the source point cloud to the target point cloud exceeds the preset threshold. Usually, the distance between the source point cloud and the target point cloud in the matching pair is relatively close. By removing the matching pairs whose distance between the source point cloud and the target point cloud exceeds the preset threshold, the matching pairs with a higher probability of error can be removed, thereby improving the accuracy of point cloud registration. Among them, the preset threshold is set automatically, usually based on historical experience. Finally, based on the distance between the source point cloud and the target point cloud in the matching pair, a weight is assigned to each matching pair. The closer the distance, the larger the weight assigned to the matching pair, and the larger the distance, the smaller the weight assigned to the matching pair. The accuracy of point cloud registration can be improved by weight assignment.
[0068] Step S104, using an iterative closest point algorithm to calculate transformation parameters of the matching pair, calculating a registration error based on the matching pair and the transformation parameters, and merging the source point cloud and the target point cloud when the registration error reaches a preset convergence error range.
[0069] The embodiment of the present invention uses an iterative closest point algorithm to achieve point cloud data registration. The iterative closest point algorithm is an algorithm widely used for three-dimensional point cloud registration. It aligns one point cloud (source point cloud) with another point cloud (target point cloud) so that the source point cloud can be optimally matched to the position and direction of the target point cloud. The iterative closest point algorithm continuously adjusts the position and direction of the source point cloud in an iterative manner until the distance error between the source point cloud and the target point cloud is minimized.
[0070] In an embodiment of the present invention, the transformation parameters between the source point cloud and the target point cloud in the matching pair are calculated by using an iterative closest point algorithm, including a rotation matrix and a translation vector, so that the source point cloud can be optimally aligned to the target point cloud. In the process of iterative alignment of the algorithm, the registration error of each iteration is calculated. When the registration error reaches a preset convergence error range, the iteration process is terminated, the source point cloud and the target point cloud are merged, and the registration of the point cloud data is completed. Among them, the preset convergence error range is set by itself, and is usually determined based on historical experience.
[0071] Optionally, the transformation parameters include a rotation matrix and a translation vector, and the steps of calculating the transformation parameters of the matching pair using an iterative closest point algorithm include: calculating the center of mass of the source point cloud and the target point cloud, wherein the center of mass is the center position of the source point cloud and the target point cloud; based on the center of mass, calculating the covariance matrix between the source point cloud and the target point cloud in the matching pair; performing singular value decomposition on the covariance matrix to obtain a rotation matrix; and based on the rotation matrix, calculating the translation vector.
[0072] In an embodiment of the present invention, the iterative process of the iterative closest point algorithm can be divided into four steps. The first step is to calculate the centroid of the source point cloud and the target point cloud, where the centroid is the geometric center of the source point cloud data set and the target point cloud data set; the second step is to subtract the corresponding centroids from the source point cloud and the target point cloud, respectively, and then calculate the covariance matrix between the source point cloud and the target point cloud to capture the dependency between the two point clouds; the third step is to perform singular value decomposition on the covariance matrix, which can realize the extraction of key data features of the covariance matrix and the dimensionality reduction of the data features to obtain the rotation matrix; the fourth step is to calculate the translation vector based on the rotation matrix. The rotation matrix and the translation vector are the transformation parameters for aligning the source point cloud to the target point cloud. After the source point cloud is processed by the rotation matrix and then by the translation vector, it can be aligned to the target point cloud to achieve the registration of the point cloud data.
[0073] Optionally, the step of calculating the transformation parameters of the matching pair using an iterative closest point algorithm also includes: defining an error function, which is used to evaluate the alignment quality; inputting the matching pair and its corresponding transformation parameters into the error function to obtain the alignment error; performing Taylor expansion processing on the error function to obtain an error linear system; solving the error linear system to obtain new transformation parameters, and iteratively updating the coordinates of the source point cloud and the target point cloud in the matching pair.
[0074] In the embodiment of the present invention, the iterative closest point algorithm is used to realize the registration process of point cloud data, and the least squares strategy is used to iteratively optimize the transformation parameters of the matching pair. The least squares strategy finds the optimal transformation parameters, that is, the rotation matrix and the translation vector, by minimizing the error function. The error function is defined as:
[0075]
[0076] Where E is the registration error, p i is the source point cloud in the i-th matching pair, q i is the target point cloud in the ith matching pair, N is the number of matching pairs, R is the rotation matrix of the ith matching pair, and t is the translation vector of the ith matching pair. By inputting the matching pairs and their corresponding transformation parameters into the error function, the registration error can be obtained. The registration error can measure the distance between the source point cloud and the target point cloud in all matching pairs, and then evaluate the registration quality.
[0077] The embodiment of the present invention iteratively searches for the optimal transformation parameters by minimizing the error function. The iterative formula can be expressed as:
[0078]
[0079] Among them, R j is the new rotation matrix, t j is the new translation vector, represents minimization, p i is the source point cloud in the i-th matching pair, q i is the target point cloud in the i-th matching pair, N is the number of matching pairs, R is the rotation matrix of the i-th matching pair, and t is the translation vector of the i-th matching pair. Since the error function is a nonlinear function, the solution process is very complicated. Therefore, the embodiment of the present invention performs Taylor expansion on the error function to transform it into a linear system to simplify the solution process. By solving the linear system, new transformation parameters are obtained, so that the coordinates of the source point cloud and the target point cloud in the matching pair can be iteratively updated, and the rotation matrix and the translation vector are continuously optimized to minimize the alignment error of the source point cloud to the target point cloud. When the alignment error meets the preset convergence error range, the iterative process is terminated, the source point cloud and the target point cloud are merged, and the alignment of the point cloud data is completed.
[0080] Figure 2 is a schematic diagram of an optional power tower point cloud registration method integrating normal vector clustering according to an embodiment of the present invention, Figure 2In the paper, the point cloud registration method of power tower integrated with normal vector clustering is divided into four processes, namely, data acquisition and processing stage, point cloud clustering stage based on normal vector, point cloud registration stage and registration iteration stage. In the data acquisition and processing stage, point cloud data is obtained by scanning the power tower, and the point cloud data is preprocessed before entering the point cloud clustering stage based on normal vector. In the point cloud clustering stage, the principal component analysis algorithm is used to calculate the normal vectors of all point cloud data in each voxel, and the point cloud data is clustered based on the normal vector to obtain representative point clouds of multiple clusters. In the point cloud registration stage, the target point cloud and the source point cloud are selected from the representative point cloud, and the binary tree search algorithm is used to find the nearest neighbor of each source point cloud in the target point cloud, that is, the matching point cloud, and then multiple matching pairs are obtained, and the matching pairs whose distance from the source point cloud to the target point cloud exceeds the preset threshold are removed. In the point cloud registration stage, the iterative closest point algorithm is used to calculate the rotation matrix and translation vector of the matching pair. The rotation matrix and translation vector are iteratively updated by minimizing the registration error. When the registration error is less than the preset error threshold range, the algorithm reaches the convergence condition and ends the iterative process to achieve the optimal registration of the source point cloud and the target point cloud.
[0081] The above-mentioned power pole tower point cloud registration method integrating normal vector clustering provides the steps of obtaining point cloud data by scanning the power pole tower, dividing the point cloud data into different voxels, using the principal component analysis algorithm to calculate the normal vectors of all point cloud data in each voxel, using the clustering algorithm to divide all point cloud data in each voxel into different clusters, determining the representative point cloud of each cluster, and then selecting the target point cloud and the source point cloud from the representative point cloud, using the binary tree search algorithm to determine the matching point cloud of each source point cloud in the target point cloud to obtain multiple matching pairs, and finally using the iterative closest point algorithm to calculate the transformation parameters of the matching pairs, and calculating the registration error based on the matching pairs and the transformation parameters. When the registration error reaches a preset convergence error range, the source point cloud and the target point cloud are merged to achieve accurate registration of the power pole tower point cloud data.
[0082] The embodiment of the present invention can effectively identify the structure of the power tower through the calculation of normal vectors and the application of clustering algorithms, maintain the geometric features of the power tower during the registration process, reduce the influence of noise data and irrelevant data on the registration results, and improve the registration accuracy; through voxelization processing, it can effectively distinguish point cloud data of different densities and resolutions, and overcome the defect of reduced registration accuracy when processing point cloud data with large differences in density and resolution; through the search for matching point clouds through the binary tree search algorithm, combined with error calculation and parameter update, the convergence speed of registration is significantly improved, and the clustering strategy of normal vectors can also reduce the amount of calculation and improve the overall processing efficiency, especially when processing large and complex point cloud data, it can greatly reduce the amount of algorithm calculation; in the point cloud registration of complex structures such as power towers, through the combination of normal vector clustering and iterative nearest point algorithm, it is possible to improve the registration accuracy of point cloud data, enhance the convergence efficiency of the algorithm, and greatly improve the work efficiency of power tower detection and maintenance.
[0083] The following is a detailed description in conjunction with another embodiment.
[0084] Embodiment 2
[0085] The power tower point cloud registration device integrated with normal vector clustering provided in this embodiment includes multiple implementation units, each of which corresponds to each implementation step in the above-mentioned embodiment 1.
[0086] Figure 3 is a schematic diagram of an optional power tower point cloud registration device integrating normal vector clustering according to an embodiment of the present invention, such as Figure 3 As shown, the power tower point cloud registration device integrating normal vector clustering may include: a scanning unit 30 , a clustering unit 31 , a matching unit 32 , and an iteration unit 33 .
[0087] The scanning unit 30 is used to scan the power pole tower to obtain point cloud data, and divide the point cloud data into different voxels, wherein the voxel is a space cube, and each voxel contains one or more point cloud data.
[0088] The clustering unit 31 is used to calculate the normal vectors of all the point cloud data in each voxel by using the principal component analysis algorithm, divide all the point cloud data in each voxel into different clusters by using the clustering algorithm, and determine the representative point cloud of each cluster.
[0089] The matching unit 32 is used to select a target point cloud and a source point cloud from the representative point cloud, and to determine a matching point cloud of each source point cloud in the target point cloud using a binary tree search algorithm to obtain a plurality of matching pairs.
[0090] The iteration unit 33 is used to calculate the transformation parameters of the matching pair by using the iterative closest point algorithm, calculate the registration error based on the matching pair and the transformation parameters, and merge the source point cloud and the target point cloud when the registration error reaches a preset convergence error range.
[0091] The above-mentioned power pole tower point cloud registration device integrating normal vector clustering can obtain point cloud data by scanning the power pole tower through the scanning unit 30, divide the point cloud data into different voxels, calculate the normal vector of all point cloud data in each voxel by the principal component analysis algorithm through the clustering unit 31, divide all point cloud data in each voxel into different clusters by the clustering algorithm, determine the representative point cloud of each cluster, and then select the target point cloud and source point cloud from the representative point cloud by the matching unit 32, and determine the matching point cloud of each source point cloud in the target point cloud by the binary tree search algorithm to obtain multiple matching pairs, and finally calculate the transformation parameters of the matching pairs by the iterative nearest point algorithm through the iterative unit 33, calculate the registration error based on the matching pairs and the transformation parameters, and merge the source point cloud and the target point cloud when the registration error reaches the preset convergence error range to achieve accurate registration of the power pole tower point cloud data. This embodiment can effectively identify the structure of the power tower through the calculation of normal vectors and the application of clustering algorithms, maintain the geometric features of the power tower during the registration process, and improve the registration accuracy. Through voxelization processing, it can effectively distinguish point cloud data of different densities and resolutions, and overcome the defect of reduced registration accuracy when processing point cloud data with large differences in density and resolution. The matching point cloud is searched through a binary tree search algorithm, combined with error calculation and parameter updating, which significantly improves the convergence speed of the registration, thereby solving the technical problems of low point cloud registration accuracy and poor algorithm convergence in related technologies.
[0092] Optionally, the scanning unit 30 includes: an acquisition module, which is used to use a laser scanner to scan the power pole tower from different perspectives to obtain point cloud data; a preprocessing module, which is used to use a geographic information system to preprocess the point cloud data, the preprocessing includes removing noise data and irrelevant data of the point cloud data, wherein the irrelevant data includes tree point clouds and obstacle point clouds; a first division module, which divides the point cloud space into multiple voxels of equal size based on the distribution density of the point cloud data and a preset voxel size, wherein the point cloud space is the spatial range covered by all point cloud data; a second division module, which divides the point cloud data into different voxels based on the coordinates of the point cloud data in the point cloud space.
[0093] Optionally, the clustering unit 31 includes: a first calculation module, used to calculate the covariance matrix of each point cloud data; a first decomposition module, used to perform eigendecomposition on the covariance matrix to obtain multiple eigenvalues and their corresponding eigenvectors; a first determination module, used to determine the eigenvector corresponding to the minimum eigenvalue as the normal vector of the point cloud data.
[0094] Optionally, the clustering unit 31 includes: a second calculation module, which is used to calculate the sum of the squares of the distances from all normal vectors to the nearest cluster center for different cluster numbers; a second determination module, which determines the target cluster number based on the sum of the squares of the distances, and divides the point cloud data into different clusters based on the target cluster number; a third determination module, which determines the point cloud data closest to the cluster center as the representative point cloud of the cluster based on each cluster; and a sorting module, which is used to sort all representative point clouds and add an index to each representative point cloud.
[0095] Optionally, the matching unit 32 includes: a selection module, used to select a subset of points from the source point cloud and the target point cloud as new source point cloud and target point cloud; a third calculation module, used to calculate the distance between the source point cloud and the target point cloud, and establish a binary tree for the target point cloud; a fourth determination module, based on the binary tree, determines the matching point cloud of each source point cloud in the target point cloud to obtain multiple matching pairs; a removal module, used to remove matching pairs in which the distance from the source point cloud to the target point cloud exceeds a preset threshold; an allocation module, which assigns weights to each matching pair based on the distance between the source point cloud and the target point cloud in the matching pair.
[0096] Optionally, the iteration unit 33 includes: a fourth calculation module, used to calculate the center of mass of the source point cloud and the target point cloud, wherein the center of mass is the center position of the source point cloud and the target point cloud; a fifth calculation module, based on the center of mass, calculates the covariance matrix between the source point cloud and the target point cloud in the matching pair; a second decomposition module, used to perform singular value decomposition on the covariance matrix to obtain a rotation matrix; and a sixth calculation module, based on the rotation matrix, calculates a translation vector.
[0097] Optionally, the iteration unit 33 also includes: a definition module, used to define an error function, which is used to evaluate the registration quality; an input module, used to input the matching pairs and their corresponding transformation parameters into the error function to obtain the registration error; an expansion module, used to perform Taylor expansion processing on the error function to obtain an error linear system; an update module, used to solve the error linear system to obtain new transformation parameters, and iteratively update the coordinates of the source point cloud and the target point cloud in the matching pair.
[0098] The above-mentioned power tower point cloud registration device integrating normal vector clustering can also include a processor and a memory. The above-mentioned scanning unit 30, clustering unit 31, matching unit 32, iteration unit 33, etc. are all stored in the memory as program units, and the processor executes the above-mentioned program units stored in the memory to realize corresponding functions.
[0099] The processor includes a kernel, which retrieves the corresponding program unit from the memory. One or more kernels can be set, and the point cloud data of the power tower can be accurately aligned by adjusting the kernel parameters.
[0100] The above-mentioned memory may include non-permanent memory in a computer-readable medium, random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash memory (fl ash RAM), and the memory includes at least one storage chip.
[0101] According to another aspect of an embodiment of the present invention, a computer-readable storage medium is also provided, the computer-readable storage medium including a stored computer program, wherein when the computer program is running, the device where the computer-readable storage medium is located is controlled to execute the power tower point cloud registration method integrating normal vector clustering according to any one of the above-mentioned embodiments one.
[0102] According to another aspect of an embodiment of the present invention, there is also provided an electronic device, comprising one or more processors and a memory, the memory being used to store one or more programs, wherein when the one or more programs are executed by one or more processors, the one or more processors implement the power tower point cloud registration method integrating normal vector clustering of any one of the above-mentioned embodiments one.
[0103] The present application also provides a computer program product, including a computer program, which, when executed by a processor, implements the steps of the power tower point cloud registration method integrating normal vector clustering described in each embodiment of the present application.
[0104] The present application also provides a computer program product, including a non-volatile computer-readable storage medium, wherein the non-volatile computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the power tower point cloud registration method integrating normal vector clustering described in each embodiment of the present application are implemented.
[0105] Figure 4 1 is a hardware structure block diagram of an electronic device (or mobile device) for a power pole tower point cloud registration method integrating normal vector clustering according to an embodiment of the present invention. Figure 4 As shown, the electronic device may include one or more ( Figure 4 402a, 402b, ..., 402n are used to illustrate) processor 402 (processor 402 may include but is not limited to a processing device such as a microprocessor MCU or a programmable logic device FPGA), memory 404 for storing data. In addition, it may also include: a display, an input / output interface (I / O interface), a universal serial bus (USB) port (which may be included as one of the ports of the I / O interface), a network interface, a keyboard, a power supply and / or a camera. It can be understood by those skilled in the art that Figure 4 The structure shown is only for illustration and does not limit the structure of the above electronic device. Figure 4More or fewer components as shown, or with Figure 4 Different configurations shown.
[0106] The serial numbers of the above embodiments of the present invention are only for description and do not represent the advantages or disadvantages of the embodiments.
[0107] In the above embodiments of the present invention, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0108] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. Among them, the device embodiments described above are only schematic. For example, the division of the units can be a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of units or modules, which can be electrical or other forms.
[0109] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple units. Some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.
[0110] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0111] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for a computer device (which can be a personal computer, a server or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, read-only memory (ROM, Read-On lyMemory), random access memory (RAM, Random Access Memory), mobile hard disk, magnetic disk or optical disk and other media that can store program codes.
[0112] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principle of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.
Claims
1. A power tower point cloud registration method integrating normal vector clustering, characterized in that: include: Scanning a power pole tower to obtain point cloud data, and dividing the point cloud data into different voxels, wherein the voxel is a space cube, and each voxel contains one or more point cloud data; A principal component analysis algorithm is used to calculate the normal vectors of all the point cloud data in each voxel, and a clustering algorithm is used to divide all the point cloud data in each voxel into different clusters, and a representative point cloud of each cluster is determined; Selecting a target point cloud and a source point cloud from the representative point cloud, and determining a matching point cloud of each source point cloud in the target point cloud using a binary tree search algorithm to obtain a plurality of matching pairs; An iterative closest point algorithm is used to calculate transformation parameters of the matching pair, a registration error is calculated based on the matching pair and the transformation parameters, and when the registration error reaches a preset convergence error range, the source point cloud and the target point cloud are merged.
2. The power tower point cloud registration method according to claim 1, characterized in that: The step of scanning the power pole tower to obtain point cloud data and dividing the point cloud data into different voxels includes: Scanning the power tower from different viewing angles using a laser scanner to obtain the point cloud data; Preprocessing the point cloud data using a geographic information system, wherein the preprocessing includes removing noise data and irrelevant data from the point cloud data, wherein the irrelevant data includes tree point clouds and obstacle point clouds; Based on the distribution density of the point cloud data and a preset voxel size, the point cloud space is divided into a plurality of voxels of equal size, wherein the point cloud space is the spatial range covered by all the point cloud data; The point cloud data is divided into different voxels based on the coordinates of the point cloud data in the point cloud space.
3. The power tower point cloud registration method according to claim 1, characterized in that: The step of calculating the normal vector of each point cloud data by using the principal component analysis algorithm comprises: Calculate the covariance matrix of each point cloud data; Performing eigendecomposition on the covariance matrix to obtain multiple eigenvalues and their corresponding eigenvectors; The eigenvector corresponding to the minimum eigenvalue is determined as the normal vector of the point cloud data.
4. The power tower point cloud registration method according to claim 1, characterized in that: The step of using a clustering algorithm to divide the point cloud data into different clusters and determining a representative point cloud of each cluster comprises: For different cluster numbers, the sum of the squares of the distances from all the normal vectors to the nearest cluster center is calculated; Determining a target clustering number based on the sum of squares of the distances, and dividing the point cloud data into different clusters based on the target clustering number; Based on each cluster, determining the point cloud data closest to the cluster center as the representative point cloud of the cluster; All the representative point clouds are sorted, and an index is added to each of the representative point clouds.
5. The power tower point cloud registration method according to claim 1, characterized in that: The step of using a binary tree search algorithm to determine a matching point cloud of each of the source point clouds in the target point cloud to obtain a plurality of matching pairs comprises: Selecting a subset of points from the source point cloud and the target point cloud as a new source point cloud and a new target point cloud; Calculating the distance between the source point cloud and the target point cloud, and establishing a binary tree for the target point cloud; Based on the binary tree, determining a matching point cloud of each of the source point clouds in the target point cloud to obtain a plurality of matching pairs; Removing the matching pairs whose distance from the source point cloud to the target point cloud exceeds a preset threshold; A weight is assigned to each of the matching pairs based on a distance between a source point cloud and a target point cloud in the matching pair.
6. The power tower point cloud registration method according to claim 1, characterized in that: The transformation parameters include a rotation matrix and a translation vector, and the step of calculating the transformation parameters of the matching pair using an iterative closest point algorithm includes: Calculating the centroid of the source point cloud and the target point cloud, wherein the centroid is the center position of the source point cloud and the target point cloud; Based on the centroid, calculating a covariance matrix between a source point cloud and a target point cloud in the matching pair; Performing singular value decomposition on the covariance matrix to obtain the rotation matrix; Based on the rotation matrix, the translation vector is calculated.
7. The power tower point cloud registration method according to claim 6, characterized in that: The step of calculating the transformation parameters of the matching pair using an iterative closest point algorithm also includes: defining an error function, wherein the error function is used to evaluate the registration quality; Inputting the matching pair and its corresponding transformation parameters into the error function to obtain the registration error; Performing Taylor expansion processing on the error function to obtain an error linear system; The error linear system is solved to obtain new transformation parameters, and the coordinates of the source point cloud and the target point cloud in the matching pair are iteratively updated.
8. A power tower point cloud registration device integrating normal vector clustering, characterized in that: include: A scanning unit, used for scanning the power pole tower to obtain point cloud data, and dividing the point cloud data into different voxels, wherein the voxel is a space cube, and each voxel contains one or more point cloud data; A clustering unit, used for calculating the normal vectors of all the point cloud data in each voxel by using a principal component analysis algorithm, dividing all the point cloud data in each voxel into different clusters by using a clustering algorithm, and determining a representative point cloud of each cluster; A matching unit, configured to select a target point cloud and a source point cloud from the representative point cloud, and determine a matching point cloud of each source point cloud in the target point cloud using a binary tree search algorithm to obtain a plurality of matching pairs; An iterative unit is used to calculate the transformation parameters of the matching pair using an iterative closest point algorithm, calculate the registration error based on the matching pair and the transformation parameters, and merge the source point cloud and the target point cloud when the registration error reaches a preset convergence error range.
9. A computer-readable storage medium, characterized in that: The computer-readable storage medium includes a stored computer program, wherein when the computer program is executed, the device where the computer-readable storage medium is located is controlled to execute the power tower point cloud registration method integrating normal vector clustering as described in any one of claims 1 to 7.
10. An electronic device, characterized in that: It includes one or more processors and a memory, wherein the memory is used to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement the power tower point cloud registration method integrating normal vector clustering as described in any one of claims 1 to 7.
Citation Information
Patent Citations
Registration method and device based on improved key points
CN117576172A
Outdoor large-scale scene 3D point cloud registration method based on isolated cluster removal
CN117745780A
Three-dimensional normal distribution transformation positioning method and device based on planar point cloud clustering voxelization, medium and product
CN118501847A
Cited By
Steel structure three-dimensional workpiece welding seam identification and path planning method and system
CN119649053A
Power transmission line point cloud semi-automatic registration method and device, electronic equipment and storage medium
CN120182342A
Three-dimensional point cloud recognition-based cross-crossing and cross-line control method and system for unmanned aerial vehicle
CN120428747A
A method and system for controlling UAV crossing lines based on 3D point cloud recognition
CN120428747B
