Method, system and device for accurate registration of maintainable parts based on improved ICP and kd-tree
By combining the normal vector information of the 3D CAD model with the kd-tree structure to optimize point cloud registration, the problems of delayed maintainability test and long ICP algorithm time in traditional methods are solved, and efficient and accurate registration of maintainable components is achieved.
Patent Information
- Application Number
- CN202411629844.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-15
- Publication Date
- 2025-09-30
- Estimated Expiration
- 2044-11-15
AI Technical Summary
Traditional maintainability test methods rely on physical prototypes, resulting in delayed discovery of repair defects, extended R&D cycles, and difficulty in optimization. Existing point cloud registration algorithms, such as ICP, have problems with initial position dependence and long time consumption.
The normal vector information and kd-tree structure of the 3D CAD model are used to optimize the point cloud registration process, and fast registration is achieved through nearest point calculation and efficient search.
It significantly improves the efficiency of point cloud registration, reduces registration time by 30%, and enhances the precise registration capability of maintainable parts.
Smart Images

Figure CN119691829B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of product maintainability testing, and in particular to a method, system and device for accurately registering maintainable components based on an improved ICP and kd tree. Background Art
[0002] Maintainability is an inherent quality attribute of a product, and maintainability engineering plays a crucial role in improving product availability and reducing maintenance costs. With the increasing complexity of product structures and the continuous improvement of usage requirements, improving product maintainability has attracted widespread attention from scholars. Especially for critical equipment and facilities, optimizing maintainability design not only enhances the safety of maintenance operations but also ensures the successful completion of tasks. Therefore, in-depth research on the analysis, testing, and evaluation methods of maintainability design schemes and prototypes plays an important role in improving product quality and ensuring product safety.
[0003] Traditional maintainability testing methods usually rely on physical prototypes or full-scale models, resulting in maintainability assessments often being conducted only after the overall product design is completed. This practice results in a relatively delayed discovery of repair defects, which not only prolongs the product development cycle but also increases the difficulty of subsequent modifications and optimizations. With the continuous development of digital prototype technology and augmented reality (AR) technology, virtual maintenance technology has emerged. Relying on high-fidelity simulation and highly interactive virtual scenes, it enables engineers to realistically simulate and deeply explore the maintenance processes and characteristics of future products. By rehearsing the entire maintenance operation and repair process in virtual reality, this technology can conduct a detailed analysis and rigorous review of the product's maintainability in the early stages of the design, thereby effectively revealing and correcting potential design flaws in advance, thereby optimizing maintenance efficiency and reducing costs.
[0004] Virtual-reality fusion maintainability testing is a cutting-edge maintainability testing strategy. Its fundamental concept aims to address the cost-effectiveness and accuracy shortcomings of traditional physical and virtual maintainability testing models. By seamlessly integrating virtual and physical objects using augmented reality (AR) technology, an integrated virtual-reality fusion maintainability testing environment is constructed and maintainability testing operations are conducted. This can realistically reflect the impact of maintenance scenarios on maintenance prototypes and maintenance processes. Furthermore, by leveraging human perception and interaction with virtual model objects, more realistic and accurate maintainability test data is obtained. A research team from the Air Force Engineering University, addressing the shortcomings of traditional AR maintenance systems in terms of maintenance status perception and judgment, proposed a maintenance process identification strategy based on probabilistic neural networks. This strategy aims to enhance intelligent perception and judgment capabilities during the maintenance process, thereby optimizing maintenance efficiency and accuracy. Yang Kangkang from Nanjing University of Aeronautics and Astronautics proposed building a Vuforia-based augmented assembly guidance system and a Kinect-based augmented assembly guidance system using an open-source AR SDK. Wu Fei from Zhengzhou University proposed a state-driven AR intelligent maintenance system to guide maintenance technicians in the disassembly and assembly of workpieces. Jia Wenzhe from Nanjing University of Science and Technology proposed a rocket launcher maintenance assistance system based on augmented reality. Combining the characteristics of HoloLens glasses and Unity3D platform, he used plane markers and SLAM to achieve system tracking and registration.
[0005] In order to obtain a detailed three-dimensional scene and the pose of spatial objects in maintainability tests, and to achieve pose alignment between the virtual scene and the physical space, point cloud registration has become an important key technology. On the one hand, because the RGBD camera acquisition method is limited by the FOV and is interfered by factors such as angular occlusion and uneven lighting, it is necessary to scan the object under test multiple times to collect more complete point cloud data. However, the point cloud data collected each time is located in a different camera coordinate system, so point cloud registration technology must be applied to unify the measured point cloud into the same coordinate system through appropriate spatial transformation. On the other hand, the acquired point cloud and the point cloud in the virtual space need to be aligned, and registration between the two is required. For the registration of rigid point clouds, the ICP algorithm is a classic method recognized by the industry. However, this method requires the initial positions of the model point cloud and the scene point cloud, and there is a problem of long point cloud registration time. Summary of the Invention
[0006] In response to the above-mentioned problems, the present invention aims to provide a method, system, and device for accurate registration of maintainable components based on improved ICP and kd-tree. First, the normal vector information of the STL triangular mesh in the three-dimensional CAD model is fully utilized. By calculating the closest points between the scene point cloud and the corresponding triangular mesh, these closest points are used as the target corresponding points for registration. Then, the kd-tree data structure is used for efficient nearest neighbor search to optimize the selection of key points in the registration process. By constructing a partition tree of multidimensional space, rapid spatial partitioning and retrieval are achieved. In this process, Euclidean distance is used as a metric to screen the key points for registration, and only key points whose distance to the query point is within a set threshold are retained, thereby significantly improving the efficiency of registration.
[0007] In order to achieve the above object, the technical solution adopted by the present invention is as follows:
[0008] The method for accurate registration of maintainable parts based on improved ICP and kd-tree includes the following steps:
[0009] S1: Obtaining scene point cloud of maintainable parts in the online stage And the model point cloud in the offline stage Preprocess point cloud data;
[0010] S2: Use the normal vector information of the STL triangular mesh in the 3D CAD model and the kd-tree algorithm to determine the point cloud of the scene Point cloud p i The corresponding point q i ;
[0011] S3: Based on matching point pairs (p i ,q i ), calculate the rotation matrix R and translation vector T, and update the scene point cloud P;
[0012] S4: Repeat steps S2 and S3, perform convergence judgment based on the distance mean square error, obtain the optimized rotation matrix R and translation vector T, and achieve accurate alignment of the maintainable components.
[0013] Furthermore, the specific operation of step S2 includes the following steps:
[0014] S201: Calculate the scene point cloud using the normal vector information of the STL triangular mesh in the 3D CAD model Point cloud p i The closest points between the corresponding triangular meshes are used as the target corresponding points for registration;
[0015] S202: Using the Euclidean distance threshold method to remove scene point clouds and model point cloud Noise in
[0016] S203: Use the kd-tree tree to perform nearest neighbor search and determine the point cloud p from the target corresponding points i The corresponding point q i .
[0017] Furthermore, the specific operations of step S201 include: making the model point cloud Contains N x A triangular mesh q i , where q i ={c i0 , c i1 , c i2 |n i}, c i0 , c i1 , c i2 Represents the three vertices of the i-th triangle mesh, n i is the normal vector corresponding to the plane where the triangular mesh is located, for the scene point cloud Point cloud p i Traverse the search model point cloud All the triangular meshes in the adjacent point are obtained i .
[0018] Furthermore, the specific operation of step S203 includes the following steps:
[0019] S2031: Preliminary search: Using the binary structure of the kd tree, recursively search along the tree structure starting from the root node, gradually narrowing the search range according to the partition dimension and partition value of each node until the nearest neighboring point to the given point is found;
[0020] S2032: Backtracking search: After finding the approximate nearest neighbor point, backtracking search is performed along the search path;
[0021] S2033: Iterative search: If a closer data point is found, jump to the corresponding child node space for further search;
[0022] S2034: Termination condition: The search process will continue until the search path is empty, that is, no data point closer than the current nearest neighbor point can be found. At this time, the nearest neighbor point to the given point is output.
[0023] Furthermore, in step S3, the updated scene point cloud P is recorded as P, then
[0024] P`=p i *R+T.
[0025] Furthermore, the specific operation of step S4 includes the following steps:
[0026] S401: Repeat steps S2 and S3 for iteration;
[0027] S402: Calculate the distance mean square error d after the scene point cloud P is updated m ,
[0028]
[0029] Where p′ i Point cloud p i The updated pose, n is the total number of point clouds;
[0030] S403: Convergence judgment: judge Δd=|d m -d m-1 |Whether it is within the set threshold μ, where d m-1 is the distance mean square error before the scene point cloud P is updated; if Δd < μ, the updated rotation matrix R and translation vector T are obtained; if Δd > μ, return to step S2 and continue the random sampling and matching process to further optimize the registration result, and finally obtain the optimized rotation matrix R and translation vector T.
[0031] Furthermore, the present invention also includes a maintainable component precise registration system based on improved ICP and kd-tree, comprising a point cloud preprocessing module, a point cloud matching module, a rigid body registration module and a convergence judgment module;
[0032] The point cloud preprocessing module is used to process the scene point cloud and model point cloud Perform pretreatment;
[0033] The point cloud matching module is used to determine the point cloud Point cloud p i The corresponding point q i ;
[0034] The rigid body registration module is used to calculate the rotation matrix R and translation vector T;
[0035] The convergence judgment module is used for convergence judgment;
[0036] The point cloud preprocessing module, point cloud matching module, rigid body registration module and convergence judgment module are implemented using the method described above.
[0037] Furthermore, the present invention also includes an electronic device, which includes at least one processor and a memory communicatively connected to the processor; wherein the memory stores instructions that can be executed by the processor, and the instructions are executed by the processor to enable the processor to execute the method as described above.
[0038] The beneficial effects of the present invention are:
[0039] This paper proposes a point cloud precision registration method based on an improved and optimized iterative closest point (ICP). First, the normal vector information of the STL triangular mesh of the 3D CAD model is used to find the closest point between the scene point cloud and the corresponding triangular mesh as the target corresponding point for registration. Based on the original ICP algorithm, a kd tree is introduced to quickly search for the closest point pair to reduce the number of iterations. Its robustness has been verified through experiments on multiple sets of public datasets. Compared with LM-ICP, Point-to-plane ICP and traditional ICP algorithms, the algorithm proposed in this paper reduces the registration time by 30%. BRIEF DESCRIPTION OF THE DRAWINGS
[0040] Figure 1 This is a flow chart of the improved iterative closest point algorithm in the present invention.
[0041] Figure 2 This is a schematic diagram of the kd-tree data structure in the present invention.
[0042] Figure 3 This is the Stanford data model object registration effect diagram in the second simulation experiment of the present invention.
[0043] Figure 4 This is the preprocessing of the real engine CAD model in the second simulation experiment of the present invention.
[0044] Figure 5 This is the flow chart of point cloud registration of virtual prototype in simulation experiment 2 of the present invention.
[0045] Figure 6 This is a comparison chart of the registration results of different registration methods in the second simulation experiment of the present invention. DETAILED DESCRIPTION
[0046] In order to enable those skilled in the art to better understand the technical solution of the present invention, the technical solution of the present invention is further described below in conjunction with the accompanying drawings and embodiments.
[0047] Example 1:
[0048] The first embodiment provides a method for accurately registering maintainable components based on improved ICP and kd-tree, as shown in the attached figure. Figure 1 As shown, the specific steps include:
[0049] S1: Obtaining scene point cloud of maintainable parts in the online stage And the model point cloud in the offline stage Preprocess point cloud data;
[0050] Specifically, the 3D CAD prototype model of the maintainable component is downsampled into a point cloud PCD file format. The 3D mesh model in PLY format stores the model's vertices, facets, normal vector textures and other geometric information, and the model point cloud of the maintainable component in the offline stage is obtained. Use depth cameras to obtain scene point clouds of maintainable parts in the online stage Then the scene point cloud and model point cloud Point cloud simplification is performed. It should be noted that the specific operation of this step is existing technology and will not be described in detail in this application.
[0051] Further, S2: using the normal vector information of the STL triangular mesh in the 3D CAD model and the kd-tree algorithm, determine the point cloud with the scene Point cloud p i The corresponding point q i ;
[0052] Specifically, S201: Calculate the scene point cloud using the normal vector information of the STL triangular mesh in the 3D CAD model Point cloud p i The closest points between the corresponding triangular meshes are used as the target corresponding points for registration;
[0053] The present invention adopts the corresponding point search algorithm based on STL triangle mesh. Find the same i The closest point between corresponding triangle meshes. STL models approximate the original CAD design through a large number of triangular facets, striving for a highly accurate approximation of the geometric form. Each triangular facet is defined by the 3D coordinates of its three vertices and an external normal vector. This data structure not only describes the shape of the model but also implicitly expresses the directional information of the model's surface.
[0054] STL model point cloud based on CAD model Contains N x A triangular mesh q i , where q i ={c i0 , c i1 , c i2 |n i}, c i0 , c i1 , c i2 Represents the three vertices of the i-th triangle mesh, n i is the normal vector corresponding to the plane where the triangle mesh is located. The algorithm first searches Middle distance p i The nearest triangle mesh q i , and calculate q iUpper distance p i The nearest point t i as corresponding points.
[0055] The most basic strategy is to analyze the scene point cloud Each point in the search model point cloud All the triangular meshes in , find the nearest triangular mesh q i . However, the algorithm for calculating the shortest distance from a point to the H-angle grid is complex, and the traversal search efficiency is very low. The present invention adopts different strategies according to the complexity of the target CAD model. If the target CAD model is relatively simple, such as a cube, the STL model only contains 12 triangle meshes. When the number of triangle meshes is relatively large, the STL triangle mesh vertices of the target CAD model can be directly used as the target point cloud to search for p i The k nearest neighbor points of p are found, and the triangle where the k nearest neighbor points are located is taken as the distance from p i The nearest candidate H angle grid, select the nearest one as q i .
[0056] S202: Using the Euclidean distance threshold method to remove scene point clouds and model point cloud Noise in
[0057] The distance threshold method can be used as a constraint to remove noise points. Its operations include the following:
[0058] (1) The point cloud data should be uniform, so the distance between corresponding point pairs should not be too large, otherwise they will be regarded as noise points. i and q i If dist is too large, it is considered as a noise point pair and is removed.
[0059] (2) Due to the characteristics of point cloud data itself, the boundary points of the point cloud often form multiple corresponding point pairs, which should be eliminated.
[0060] (3) If and Constitute a corresponding point set, then and The spatial topological relationship of should be consistent. Consider two sets of corresponding points P1 and Q1, and P2 and Q2. If |dist(P1-P2)-dist(Q1-Q2)|≥ε, then it is considered as a noise point and removed, otherwise it is retained.
[0061] S203: Nearest neighbor search: Calculate each p i to q i The Euclidean distance of all points in the kd-tree is calculated and the kd-tree data structure is used for efficient search. By traversing the kd-tree, the distance p is found.i The nearest point q i as matching point pairs. This step ensures fast and accurate nearest neighbor matching.
[0062] Specifically, the kd-tree data structure is as follows Figure 2 As shown in the figure, take the tree construction process of a two-dimensional point set as an example. First, sort all the points in the point set along the x-axis direction. After finding the midpoint A, divide the point set into two subsets along the x-axis direction with point A as the dividing point. Then sort the two subsets along the y-axis direction and continue to divide the subsets according to the midpoint, as shown in the figure. Figure 2 As shown in (a). By cyclically dividing the x-axis and y-axis directions, all points are finally added to the tree structure. The tree construction result of the example point set is as follows Figure 2 As shown in (b).
[0063] Given a point P3 in a point cloud dataset, the process of nearest neighbor search using KD tree is as follows:
[0064] (1) Preliminary search: Using the binary structure of the KD tree, recursively search along the tree structure starting from the root node. Based on the partition dimension and partition value of each node, the search range is gradually narrowed until the nearest neighboring point to the given point P3 is found.
[0065] (2) Backtracking search: Once the approximate nearest neighbor point is found, the algorithm will backtrack along the search path.
[0066] (3) Iterative search: If a closer data point is found, the algorithm will jump to the corresponding child node space for further search.
[0067] (4) Termination condition: The search process will continue until the search path is empty, that is, no data point closer than the current nearest neighbor can be found. At this point, the algorithm outputs the nearest neighbor point to the given point P3.
[0068] Further, step S3: based on the matching point pair (p i ,q i ), calculate the rotation matrix R and translation vector T, and update the scene point cloud P;
[0069] Based on matching point pairs (p i ,q i ), calculate the rotation matrix R and translation vector T. Then, use these parameters to update the scene point cloud P, denoted as P`, then
[0070] P`=p i *R+T
[0071] Furthermore, step S4: repeating steps S2 and S3, performing convergence judgment based on the distance mean square error, obtaining the optimized rotation matrix R and translation vector T, and realizing accurate registration of the maintainable components.
[0072] Specifically, S401: repeat step S2 and step S3 for iteration;
[0073] S402: Calculate the distance mean square error d after the scene point cloud P is updated m ,
[0074]
[0075] Where p` i Point cloud p i The updated pose, n is the total number of point clouds;
[0076] S403: Convergence judgment: judge Δd=|d m -d m-1 |Whether it is within the set threshold μ, where d m-1 is the distance mean square error before the scene point cloud P is updated; if Δd < μ, the updated rotation matrix R and translation vector T are obtained; if Δd > μ, return to step S2 and continue the random sampling and matching process to further optimize the registration result, and finally obtain the optimized rotation matrix R and translation vector T.
[0077] Simulation experiment:
[0078] The feasibility and robustness of the improved iterative closest point algorithm proposed in this invention are verified by simulation experiments. The simulation experiments are conducted on a test platform with specific hardware configuration and software environment. The experimental environment is shown in Table 1 below.
[0079] In terms of data selection, this simulation experiment utilized the Dragon and Drillbit models in the Stanford University 3D point cloud database. These models were scanned multiple times with a 3D scanner to obtain point cloud data, providing rich experimental material for this simulation experiment. By adjusting the number of key points, this simulation experiment verified the accuracy of the improved iterative closest point algorithm (ICP) under different circumstances. In addition, to further verify the practicality of the algorithm, this simulation experiment also used real laboratory data - an engine model, to conduct a virtual-reality fusion test. By comparing with different algorithms, this simulation experiment more comprehensively evaluated the performance of the algorithm proposed in this invention in practical applications.
[0080] Table 1 Experimental environment information
[0081]
[0082] (1) Comparative experimental analysis with the original ICP algorithm
[0083] In order to highlight the advantages and reliability of the improved ICP algorithm proposed in this invention compared with the traditional ICP algorithm, this simulation experiment selected the Stanford University public data set for detailed experimental comparison. Specifically, two objects, Dragon and Drill, were selected as experimental objects. The point cloud data of Drill and Dragon are both high-density point cloud data, with the number of data points reaching tens of thousands. This simulation experiment first uses a voxel filter for downsampling, uses the ISS algorithm to extract key points from the downsampled point cloud data, and then calculates the point cloud corresponding point matching relationship. The three-dimensional structure, point cloud correspondence and point cloud registration effect of the two models are shown in the attached figure. Figure 3 shown.
[0084] In order to deeply compare the performance of the algorithm proposed in the present invention with that of the traditional ICP algorithm, this simulation experiment selected two sets of data sets, Dragon and Drill, for experimental verification. In these experiments, different numbers of key points were extracted, and time and root mean square error (MSE) were used as the main evaluation criteria. In order to ensure the reliability and accuracy of the results, this simulation experiment conducted 20 sets of experimental comparisons for each set of data. The experimental results are shown in Table 2 and Table 3 below. By adjusting the extraction parameters of the key points, this simulation experiment obtained different amounts of point cloud data, and processed and analyzed these data. The experimental data clearly show that the algorithm proposed in the present invention has good performance in both running time and accuracy.
[0085] Table 2. Dragon model precise registration results with different numbers of key points
[0086]
[0087] Table 3. Drill model precise registration results with different numbers of key points
[0088]
[0089] (2) Comparative experimental analysis with other algorithms
[0090] In order to fully demonstrate the advantages of the improved ICP algorithm proposed in the present invention over LM-ICP, Point-to-plane ICP and traditional ICP algorithms, a series of experiments were designed in this simulation experiment. These experiments were carried out under the same key point set and matching conditions to ensure fair and accurate comparison. The Stanford University public data set was selected, which includes multiple different objects to verify the reliability of the algorithm of the present invention. During the experiment, the operation was strictly carried out in accordance with the same experimental settings and parameter configurations. By comparing the performance of various algorithms under the same conditions, the advantages of the improved ICP algorithm proposed in the present invention in terms of accuracy, efficiency, etc. can be more clearly seen.
[0091] The experimental results are shown in Tables 4 and 5 below. These experimental results detail the specific performance of various algorithms on different objects. By comparing and analyzing these data, it can be concluded that the algorithm proposed in this paper has higher accuracy and stability when processing 3D point cloud data.
[0092] Table 4. Experimental comparison of Dragon model objects
[0093]
[0094] Table 5 Drill model object experiment comparison
[0095]
[0096] (3) Analysis of real experimental data
[0097] To further validate the reliability of the proposed algorithm, this simulation experiment used real engine CAD model data from the laboratory as the test object. The CAD model was first preprocessed, including voxel downsampling and noise reduction. Subsequently, the improved iterative closest point algorithm proposed in this paper was used to align the preprocessed data.
[0098] Due to the huge size of engine component point cloud data, pre-processing is crucial. Voxel downsampling and noise reduction techniques are implemented to improve data quality and computational efficiency. Figure 4 It is revealed that the initial pose difference between the pre-processed engine point cloud data and the CAD model is significant, and a registration algorithm is needed to accurately align the two.
[0099] In the experiment, the pre-processed engine CAD model was accurately matched and compared with the traditional iterative closest point (ICP) algorithm, LM-ICP algorithm and Point-to-plane ICP algorithm. Figure 5The model matching process is described in detail, from the initial misalignment state to the final precise matching achieved by this algorithm, and each step reflects the efficiency and accuracy of the algorithm. Figure 6 The difference in the registration results of the algorithms is intuitively demonstrated, and it is obvious that the algorithm of the present invention is better in detail processing and overall alignment. In order to quantitatively evaluate the performance of the algorithm, this simulation experiment also records the running time and registration accuracy of the algorithm, as shown in Table 6 below. The data shows that the algorithm proposed in the present invention reduces the running time by about 30% compared with the traditional ICP algorithm. In addition, Table 7 lists in detail the results obtained by solving the rigid body transformation matrix of the point cloud. This key step is directly related to the registration accuracy of the model and the final alignment effect. It can be seen from the data in the table that the algorithm of the present invention shows higher stability and accuracy when solving the rigid body transformation matrix.
[0100] Table 6 Real data experimental comparison
[0101]
[0102] Table 7 Point cloud rigid body transformation matrix
[0103]
[0104] Example 2:
[0105] The second embodiment provides a repairable component precise registration system based on improved ICP and kd-tree, which specifically includes a point cloud preprocessing module, a point cloud matching module, a rigid body registration module and a convergence judgment module;
[0106] The point cloud preprocessing module is used to process the scene point cloud and model point cloud Perform pretreatment;
[0107] The point cloud matching module is used to determine the point cloud Point cloud p i The corresponding point q i ;
[0108] The rigid body registration module is used to calculate the rotation matrix R and translation vector T;
[0109] The convergence judgment module is used for convergence judgment;
[0110] It should be noted that the point cloud preprocessing module, point cloud matching module, rigid body registration module and convergence judgment module are implemented by using the maintainable component precise registration method based on improved ICP and kd tree described in the first embodiment.
[0111] Example 3:
[0112] Embodiment 3 provides an electronic device, comprising at least one processor and a memory communicatively connected to the processor; wherein the memory stores instructions executable by the processor, and the instructions are executed by the processor to enable the processor to execute the method for precise registration of maintainable parts based on improved ICP and kd-tree described in embodiment 1.
[0113] The basic principles, main features, and advantages of the present invention are shown and described above. Those skilled in the art should understand that the present invention is not limited to the foregoing embodiments. The foregoing embodiments and descriptions are merely illustrative of the principles of the present invention. Various changes and modifications may be made to the present invention without departing from the spirit and scope of the present invention. Such changes and modifications are intended to fall within the scope of the present invention. The scope of protection claimed in the present invention is defined by the appended claims and their equivalents.
Claims
1. A method for accurate registration of maintainable parts based on improved ICP and kd-tree, characterized by: The following steps are involved: S1: Obtaining scene point cloud of maintainable parts in the online stage And the model point cloud in the offline stage , pre-process the point cloud data; S2: Using the normal vector information of the STL triangle mesh in the 3D CAD model and the kd-tree algorithm, determine the scene point cloud Point Cloud The corresponding point ; S3: Based on matching point pairs , calculate the rotation matrix R and translation vectors T , update the scene point cloud P ; S4: Repeat steps S2 and S3, and make a convergence judgment based on the distance mean square error to obtain the optimized rotation matrix R and translation vectors T , achieving precise registration of maintainable parts; The specific operations of step S2 include the following steps: S201: Calculate scene point cloud using the normal vector information of the STL triangle mesh in the 3D CAD model Point Cloud The closest points between the corresponding triangular meshes are used as the target corresponding points for registration; S202: Using the Euclidean distance threshold method to remove scene point clouds and model point cloud Noise in S203: Use the kd-tree tree to perform nearest neighbor search and determine the point cloud from the target corresponding points p i The corresponding point q i ; The specific operations of step S201 include: Contains triangular mesh ,in , Respectively represent i The three vertices of a triangle mesh, is the normal vector corresponding to the plane where the triangular mesh is located, for the scene point cloud Point cloud in p i Traverse the search model point cloud All the triangular meshes in the ; The specific operation of step S203 includes the following steps: S2031: Preliminary search: Using the binary structure of the kd tree, recursively search along the tree structure starting from the root node, gradually narrowing the search range according to the partition dimension and partition value of each node until the nearest neighboring point to the given point is found; S2032: Backtracking search: After finding the approximate nearest neighbor point, backtracking search is performed along the search path; S2033: Iterative search: If a closer data point is found, jump to the corresponding child node space for further search; S2034: Termination condition: The search process will continue until the search path is empty, that is, no data point closer than the current nearest neighbor point can be found. At this time, the nearest neighbor point to the given point is output.
2. The method for accurate registration of maintainable parts based on improved ICP and kd-tree according to claim 1, characterized in that: In step S3, the updated scene point cloud P Recorded as ,but 。 3. The method for accurate registration of maintainable parts based on improved ICP and kd-tree according to claim 2, characterized in that: The specific operation of step S4 includes the following steps: S401: Repeat steps S2 and S3 for iteration; S402: Calculate scene point cloud P Updated distance mean square error , Where, Point Cloud p i The updated pose, n is the total number of point clouds; S403: Convergence Judgment: Judgment Is it within the set threshold? Inside, among them, Point cloud for the scene P The mean square error of the distance before updating; if , then the updated rotation matrix is obtained R and translation vectors T; if , then return to step S2 and continue the random sampling and matching process to further optimize the registration result, and finally obtain the optimized rotation matrix R and translation vectors T .
4. A system for accurately registering maintainable parts based on improved ICP and kd-tree, the system being used to implement the method according to any one of claims 1 to 3, characterized in that: The system includes a point cloud preprocessing module, a point cloud matching module, a rigid body registration module and a convergence judgment module; The point cloud preprocessing module is used to process the scene point cloud and model point cloud Perform pretreatment; The point cloud matching module is used to determine the point cloud Point Cloud p i The corresponding point q i ; Rigid body registration module is used to calculate the rotation matrix R and translation vectors T ; The convergence judgment module is used for convergence judgment.
5. An electronic device, characterized in that: The electronic device includes at least one processor and a memory communicatively connected to the processor; wherein the memory stores instructions executable by the processor, and the instructions are executed by the processor to enable the processor to execute the method according to any one of claims 1 to 3.
Citation Information
Patent Citations
CAD model and triangular mesh full-automatic registration method and device
CN112381862A
Virtual-real fusion maintainability test scene high-precision registration method
CN118587260A