A point pair feature based digital-analog alignment method
By using a point-pair feature-based digital model alignment method, the nominal and actual points of the workpiece under test are obtained, the target point set is determined, and iterative optimization is performed under the constraints of no coordinate system or preset coordinate system. This solves the problems of low efficiency and low accuracy in the existing technology and improves the detection accuracy.
Patent Information
- Application Number
- CN202210155398.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-02-21
- Publication Date
- 2025-12-19
- Estimated Expiration
- 2042-02-21
AI Technical Summary
In existing technologies, such as industrial automation inspection, the method of matching key features by looking up tables is inefficient and inaccurate, resulting in poor accuracy of the rigid body transformation matrix.
A point-pair feature-based digital model alignment method is adopted to obtain point-pair features, including nominal points and actual points, to determine the target point set. Under the condition of no coordinate system constraints or preset coordinate system constraints, the optimal alignment result is obtained by iterative optimization through the initial alignment result and the deviation distance constraint.
It improves the matching efficiency and accuracy of key features during the inspection of the workpiece and enhances the precision of the rigid body transformation matrix.
Smart Images

Figure CN114511689B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of industrial automation, and in particular to a digital model alignment method based on point-to-feature. BACKGROUND
[0002] In the industrial automation application of 3D technology, the size and specification of a to-be-measured workpiece can be detected by the difference between the point cloud data of the to-be-measured workpiece and the standard model data.
[0003] In the related art, the key features (such as corner points, edge points, center points, curvature change points, sampling points, etc.) in the standard model are modeled, and the first information (such as position, angle, curvature, etc.) of the key features is recorded and constructed into a lookup table containing the key features and their information. The same key features and corresponding second information are extracted from the point cloud data of the to-be-measured workpiece. The most matching key features are found in the lookup table through a matching strategy (the matching strategy is that the difference between the first information and the second information is the smallest). The rigid transformation matrix is obtained by establishing a rigid transformation relationship using the most matching key features. However, the way of determining the most matching key features through the matching strategy is low in efficiency and accuracy, resulting in poor accuracy of the rigid transformation matrix. SUMMARY
[0004] The present application provides a digital model alignment method based on point-to-feature to solve the technical problems of low efficiency and low accuracy in matching key features in the detection process of a to-be-measured workpiece.
[0005] To achieve the above purpose, the embodiments of the present application adopt the following technical solutions:
[0006] The present application provides a digital model alignment method based on point-to-feature, which comprises the following steps:
[0007] Obtain point-to-feature, which comprises nominal points and actual points; wherein the nominal points are key features in the grid model data of a to-be-measured workpiece; the actual points are key features in the point cloud data of the to-be-measured workpiece and correspond to the nominal points;
[0008] Determine a target point set, wherein the target points in the target point set are actual points corrected according to the nominal points in the effective direction;
[0009] Under the condition of no coordinate system constraint or a preset coordinate system constraint, determine an initial alignment result according to the target point set and the nominal point set.
[0010] In one implementation manner, after the initial alignment result is determined, the method further comprises:
[0011] Iteratively optimize the initial alignment result according to the deviation distance constraint to obtain an optimal alignment result.
[0012] In an implementation, the determining of the initial alignment result comprises:
[0013] determining the gravity centers of the target points and the nominal points;
[0014] decentering the target points by the gravity centers of the target points and decentering the nominal points by the gravity centers of the nominal points;
[0015] determining an initial alignment result, the initial alignment result comprising a rotation matrix and a translation, the rotation matrix being determined by an equation established by the decentered target points and the decentered nominal points, and the translation being determined by the gravity centers of the target points, the gravity centers of the nominal points and the rotation matrix.
[0016] In an implementation, the determining of the initial alignment result comprises:
[0017] determining a plurality of alignment results according to the target point set and the nominal point set, the alignment result comprising a rotation matrix and a translation;
[0018] selecting the alignment result with the least difference between the target point set after transformation according to the preset coordinate system constraint and the nominal point set as the initial alignment result;
[0019] wherein, the coordinate system constraint comprises a rotation constraint and a translation constraint.
[0020] In an implementation, the determining of the alignment result comprises the following steps:
[0021] determining the gravity centers of the target points and the nominal points;
[0022] correcting the gravity centers of the target points and the nominal points according to the translation constraint;
[0023] decentering the target points by the corrected gravity centers of the target points and decentering the nominal points by the corrected gravity centers of the nominal points;
[0024] determining a rotation matrix and resetting a corresponding rotation angle according to the rotation constraint, the rotation matrix being determined by an equation established by the decentered target points and the decentered nominal points;
[0025] determining a translation by the rotation matrix after the rotation angle is reset and resetting a corresponding coordinate according to the translation constraint.
[0026] In an implementation, the determining of the alignment result comprises the following steps:
[0027] determining a rotation matrix, and resetting corresponding rotation angles according to the rotation constraint, the rotation matrix being determined by an equation established by the target point and the nominal point;
[0028] determining a translation amount by the rotation matrix after resetting the rotation angles, and resetting corresponding coordinates according to the translation constraint.
[0029] In an implementation, the determining of the alignment result comprises the following steps:
[0030] determining the barycenter of the target point and the nominal point;
[0031] decentering the target point by the barycenter of the target point, and decentering the nominal point by the barycenter of the nominal point;
[0032] determining a rotation matrix, the rotation matrix being determined by an axis rotation matrix composed of rotation angles in each direction;
[0033] determining a translation amount by the rotation matrix after resetting the rotation angles, and resetting corresponding coordinates according to the translation constraint.
[0034] In an implementation, in the actual point according to the nominal point in the effective direction is reserved in the actual point in the type of the effective direction, and the coordinate data in the direction dimension of other directions except the effective direction is replaced by the coordinate data in the nominal point.
[0035] In an implementation, the iterative optimization of the initial alignment result according to the deviation distance constraint comprises:
[0036] obtaining the deviation of each target point after rigid transformation from the corresponding nominal point; and marking the use points according to the deviation, the use points being the points after rigid transformation of each target point. The termination of the iterative optimization comprises the following cases:
[0037] when the number of the use points obtained increases or decreases to a minimum preset value with the number of iterations, the iterative optimization is terminated;
[0038] when the proportion of the use points obtained to the total number of points is less than a preset minimum number of matching point pairs, the iterative optimization is terminated;
[0039] when the marking and the marking condition of the use points obtained in two adjacent times are consistent, the iterative optimization is terminated;
[0040] when the maximum number of iterations is reached, the iterative optimization is terminated.
[0041] According to the technical scheme, the application provides a number model alignment method based on point pair features, point pair features are acquired, the point pair features include nominal points and actual points; the nominal points are key features in grid model data of a workpiece to be measured; the actual points are key features in point cloud data of the workpiece to be measured and correspond to the nominal points; target point sets are determined, target points in the target point sets are actual points corrected according to the nominal points in effective directions; initial alignment results are determined according to the target point sets and nominal point sets under no coordinate system constraint condition or a preset coordinate system constraint condition; the initial alignment results are iteratively optimized according to deviation distance constraints to obtain optimal alignment results. The application is beneficial to selecting stable and reliable key features from data through diversity of point pair features, so that the application is widely used in fast matching scenes; the alignment result freedom is limited through effective direction constraints and coordinate system constraints, and then interference point pairs are removed through iterative optimization of deviation distance constraints, so that the accuracy of the alignment result is improved. BRIEF DESCRIPTION OF DRAWINGS
[0042] In order to more clearly illustrate the technical scheme in the embodiments of the application or the prior art, the drawings needed to be used in the embodiments or the prior art description will be briefly introduced. Obviously, the drawings in the following description are only some embodiments of the application, and other drawings can be obtained by those skilled in the art without creative labor.
[0043] Figure 1 A flowchart of a number model alignment method based on point pair features in an embodiment of the application;
[0044] Figure 2 A schematic diagram of a nominal point in grid model data in an embodiment of the application;
[0045] Figure 3 A schematic diagram of an actual point in point cloud data in an embodiment of the application;
[0046] In the drawings: 10-grid model data; 11-nominal point; 20-point cloud data; 21-actual point. DETAILED DESCRIPTION
[0047] In order to make the person in the technical field better understand the application scheme, the technical scheme in the embodiments of the application will be clearly and completely described below in combination with the drawings in the embodiments of the application. Obviously, the described embodiments are only some embodiments of the application, not all embodiments. Based on the embodiments in the application, all other embodiments obtained by those skilled in the art without creative labor should be within the protection scope of the application.
[0048] It is to be understood that the terminology "first", "second" and the like used in the specification and the claims of the application as well as the preceding description of the drawings is merely used to distinguish similar objects and does not necessarily imply a specific order or chronology. It is to be understood that the data thus used can be interchanged, where appropriate, so that the embodiments of the application described herein can be carried out in a different order than the one described here. Furthermore, the terms "comprising" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, processes, methods, systems, products or devices that comprise a list of steps or units need not be limited to those steps or units that are clearly listed, but can include other steps or units that are not clearly listed or inherent to such processes, methods, products or devices.
[0049] The application will be further described in detail below with reference to the accompanying drawings:
[0050] Some embodiments of the application provide a point-to-feature-based number model alignment method, as shown in Figure 1 The method comprises the following steps:
[0051] S101, acquiring point-to-feature, the point-to-feature comprising nominal points and actual points.
[0052] The nominal points are key features in the grid model data of the workpiece to be measured, and the actual points are key features in the point cloud data of the workpiece to be measured and correspond to the nominal points; wherein, in the workpiece to be measured, obvious edges, corners, holes, grooves, spheres, cylinders and cones can be used as features for stable matching, and these curvature mutation features (edges, corners, etc.) and geometric centers (holes, grooves, spheres, cylinders and cones) are defined as key features; the key features can be corner points, edge points, circle centers, curvature change mutation points, sampling points, etc. For example, the key features of a four-prism (i.e. the shape after cutting off the top of a four-prism) are the vertices of the upper and lower quadrilaterals, i.e. 8 corner points (each corner point is the intersection of 3 planes).
[0053] The acquisition of the point-to-feature comprises the following steps: acquiring the grid model data and the point cloud data of the workpiece to be measured; determining the point-to-feature according to the corresponding nominal points and actual points.
[0054] The workpiece to be measured is a machining workpiece that needs to be detected.
[0055] As shown in Figure 2 , Figure 3As shown, the nominal point 11 in the grid model data 10 and the actual point 21 in the point cloud data 20 are determined to correspond to each other; the nominal point or the actual point includes but is not limited to the following key features: end points of three-dimensional line segments, three-dimensional straight line intersection points, three-plane intersection vertices, three-dimensional circle centers, sphere centers, cuboid vertices, three-dimensional rectangular corner points or centers, cylinder upper and lower base circle centers, conical vertices, slot hole centers, tower or prism vertices, which can be obtained by least squares or minimum containment method fitting, or can be obtained by geometric calculation.
[0056] In an embodiment, key features such as the intersection of three planes, the end points of the point cloud edge extraction, the center of the fitted three-dimensional circle (cylinder, cone, etc. Circular shape), the center of the slot hole, and the point with the largest curvature change in the point cloud data can be obtained by a fast extraction algorithm in the region of interest of the grid model data or point cloud data of the workpiece to be measured. The key features in the grid model and point cloud data of the workpiece to be measured correspond to each other, the operation amount is reduced by specifying the region of interest, and the accuracy of the key feature matching relationship is ensured.
[0057] S102, determine a target point set, and the target point in the target point set is an actual point corrected according to a nominal point in an effective direction.
[0058] The effective direction includes XYZ direction, XY direction, XZ direction, YZ direction, X direction, Y direction, and Z direction. The target point retains the coordinate in the corresponding direction dimension of the actual point through the type of the effective direction, and the remaining direction dimension coordinate is replaced with the data in the nominal point. For example, the actual point is g, and the nominal point is q; g x ,g y ,g z X, Y, and Z coordinates of the actual point, respectively, q x ,q y ,q z X, Y, and Z coordinates of the nominal point, respectively, and the target point p obtained by the correction method is as follows:
[0059]
[0060] S103, determine an initial alignment result according to the target point set and the nominal point set under the condition of no coordinate system constraint.
[0061] Determine the center of gravity of the target point set and the center of gravity of the nominal point set
[0062] Decenter the target point set Decenter the nominal point set Obtain the solution equation of the rotation matrix
[0063] Since the rotation matrix R satisfies the rotation orthogonality, i.e. RR T = I, the expression ||Rx i -y i || 2 As follows:
[0064]
[0065] According to the matrix operation, and are scalars, and satisfy Then the expression ||Rx i -y i || 2 As follows:
[0066]
[0067] Since and are scalars, and are irrelevant to the final optimization result; substituting the above expression ||Rx i -y i || 2 into the solving equation of the rotation matrix, as follows:
[0068]
[0069] Let X = [x1 x2…x n ], Y = [y1 y2…y n ], according to the trace property of the multiplication matrix, then:
[0070]
[0071] Let S = XY T , and perform singular value decomposition (SVD) on the matrix S, i.e. S = UΣV T , then
[0072] tr(RXY T ) = tr(RS) = tr(RUΣV T ) = tr(ΣV T RU) = tr(ΣM)
[0073] In the formula, M = V T RU, since V, R, U are all orthogonal matrices, M is also an orthogonal matrix.
[0074] According to the orthogonality of the matrix M:
[0075]
[0076] where m j is a column of the orthogonal matrix M, m ij is an element of the orthogonal matrix M.
[0077] Since Σ is a diagonal matrix, we have:
[0078]
[0079] Then
[0080]
[0081] The above formula can take the maximum value only when the matrix M is the identity matrix I. Then the rotation matrix R can be obtained as:
[0082]
[0083] The matrix R calculated above can be a rotation matrix or a mirror matrix:
[0084]
[0085] where det() represents the determinant of the matrix. In order to ensure that R is a rotation matrix, it is necessary to make a correction in the case of a mirror matrix, and at the same time, it is necessary to satisfy that tr(ΣM) is maximum, then we have:
[0086]
[0087] Then the rotation matrix R is:
[0088]
[0089] Then the translation amount
[0090] Determine an initial alignment result, the initial alignment result including a rotation matrix and a translation amount.
[0091] S104, under the constraint condition of a preset coordinate system, determine an initial alignment result, the initial alignment result being an alignment result in which the target point has the minimum difference with the nominal point after being transformed according to the constraint of the preset coordinate system.
[0092] The nominal point set is a collection of nominal points. The coordinate system constraint is a rotation constraint and a translation constraint, that is, the rotation angle in the rotation matrix and the translation amount are limited, and the limitation includes X-direction translation limitation, Y-direction translation limitation, Z-direction translation limitation, rotation limitation around the X-axis, rotation limitation around the Y-axis, rotation limitation around the Z-axis, each limitation can be set, and the value of the corresponding dimension after the limitation is 0.
[0093] According to the preset coordinate system constraint, the alignment result (i.e. the rotation matrix and the translation) is determined in the following cases.
[0094] In one case: the center of gravity of the target point set is determined and the center of gravity of the nominal point set
[0095] According to the translation constraint, the center of gravity of the target point set is corrected to obtain and the center of gravity of the nominal point set is corrected to obtain That is, the center of gravity of the target point and the nominal point is corrected according to the translation limit in the preset coordinate system constraint.
[0096] Decenter the target point set Decenter the nominal point set Get the solving equation of the rotation matrix
[0097] Since the rotation matrix R satisfies the rotation orthogonality, i.e. RR T = I, the expression ||Rx i -y i || 2 As follows:
[0098]
[0099] According to matrix operations, and are scalars, and satisfy Then the expression ||Rx i -y i || 2 As follows:
[0100]
[0101] Since and are scalars, and are irrelevant to the final optimization result; Substitute the above expression ||Rx i -y i || 2 into the solving equation of the rotation matrix, as follows:
[0102]
[0103] Let X = [x1 x2…x n ], Y = [y1 y2…y n ], according to the trace property of the multiplication matrix, then:
[0104]
[0105] Let S = XY TSVD decomposition of matrix S, i.e. S = U∑V T
[0106] tr(RXY T ) = tr(RS) = tr(RU∑V T ) = tr(∑V T RU) = tr(∑M)
[0107] where M = V T RU, since V, R, U are all orthogonal matrices, M is also an orthogonal matrix.
[0108] From the orthogonality of matrix M, we have:
[0109]
[0110] where m j is a column of the orthogonal matrix M, and m ij is an element of the orthogonal matrix M.
[0111] Since ∑ is a diagonal matrix, we have:
[0112]
[0113]
[0114]
[0115] The above formula can take the maximum value only when matrix M is the identity matrix I. Then the rotation matrix R can be obtained as:
[0116]
[0117] The matrix R calculated above may be a rotation matrix or a mirror matrix:
[0118]
[0119] where det() represents the determinant of the matrix. In order to ensure that R is a rotation matrix, the mirror matrix case needs to be corrected, and at the same time, tr(∑M) needs to be maximized, so we have:
[0120]
[0121] Then the rotation matrix R is:
[0122]
[0123] According to the rotation constraint, the corresponding rotation angles X, Y, Z are reset to 0.
[0124] Calculate the translation amount After the translation amount is calculated, the corresponding X, Y, Z coordinates are reset according to the translation constraint.
[0125] In yet another case: the solving equation of the rotation matrix is
[0126] Since the rotation matrix R satisfies the rotation orthogonality, that is, RR T = I, the expression ||Rp i -q i || 2 As follows:
[0127]
[0128] According to matrix operations, and are scalars, and satisfy Then the expression ||Rp i -q i || 2 As follows:
[0129]
[0130] Since and are scalars, and are irrelevant to the final optimization result; Substitute the above expression ||Rp i -q i || 2 into the solving equation of the rotation matrix, as follows:
[0131]
[0132] Let X = [p1 p2…p n ], Y = [q1 q2…q n ], according to the trace properties of the multiplication matrix, then:
[0133]
[0134] Let S = XY T , and perform SVD decomposition on the matrix S, that is, S = UΣV T , then
[0135] tr(RXY T ) = tr(RS) = tr(RUΣV T ) = tr(ΣV T RU) = tr(ΣM)
[0136] In the formula, M = V T RU, since V, R, U are all orthogonal matrices, M is also an orthogonal matrix.
[0137] From the orthogonality of matrix M, we have:
[0138]
[0139] where m j is a column of the orthogonal matrix M, m ij is an element of the orthogonal matrix M.
[0140] Since Σ is a diagonal matrix, we have:
[0141]
[0142] Then
[0143]
[0144] The above formula can take the maximum value only when the matrix M is the identity matrix I. Then the rotation matrix R can be obtained as:
[0145]
[0146] The matrix R calculated above can be a rotation matrix or a mirror matrix:
[0147]
[0148] where det() represents the determinant of the matrix. In order to ensure that R is a rotation matrix, it is necessary to modify the mirror matrix case, and at the same time meet the requirement that tr(ΣM) is maximum, then we have:
[0149]
[0150] Then the rotation matrix R is:
[0151]
[0152] According to the rotation constraint, reset the corresponding rotation angles X, Y, Z to 0.
[0153] Let y i ' = Rx i (i = 1,..., n), x i ∈ X, then the center of gravity of the nominal point set is the center of gravity of the target point set
[0154] Calculate the translation amount After calculating the translation amount, reset the corresponding X, Y, Z coordinates according to the translation constraint.
[0155] In another case: determine the center of gravity of the target point set and the center of gravity of the nominal point set
[0156] Decentering target point set Decentering nominal point set Get the solution equation of rotation matrix
[0157] Solve rotation angle step by step, that is, solve the following three linear equations:
[0158]
[0159] In the formula, x i and y i are the decentered target points and nominal points; v i is the result point after x i is transformed by Rx; u i is the result point after v i is transformed by Ry; Rx, Ry, and Rz are rotation matrices around the X, Y, and Z axes, respectively:
[0160]
[0161] In the formula, α, β, and γ represent the rotation angles around the X, Y, and Z axes, respectively.
[0162] Then the rotation matrix R is: R = RxRyRz.
[0163] According to the rotation constraint, the corresponding rotation angles X, Y, and Z are reset to 0.
[0164] Calculate the translation amount After calculating the translation amount, reset the corresponding X, Y, and Z coordinates according to the translation constraint.
[0165] Get the alignment results under the above different conditions, and select the alignment result with the smallest difference between the target point set after transformation according to the preset coordinate system constraint and the nominal point set as the initial alignment result.
[0166] In some embodiments, the initial alignment result can be solved and optimized by using global optimization algorithms such as LM (Levenberg-Marquardt) algorithm, genetic algorithm, ant colony algorithm, or heuristic methods such as hill climbing algorithm and tabu search algorithm.
[0167] Under the accuracy requirement, the numerical model alignment method based on point pair features can further include the following steps to further improve the accuracy of the alignment result.
[0168] S105, iteratively optimize the initial alignment result according to the deviation distance constraint to obtain an optimal alignment result.
[0169] According to the deviation distance constraint, the target point set and the nominal point set corresponding to the initial alignment result are updated, and the iterative optimization process is as follows:
[0170] The deviation of each target point after the rigid body transformation from the corresponding nominal point is obtained. The rigid body transformation includes translation, rotation, etc.
[0171] According to the deviation, the use points are marked, the use points are the points after the rigid body transformation of each target point; when the deviation is less than the maximum deviation distance threshold, the mark of the use point is True, and the use point is retained; when the deviation is greater than or equal to the maximum deviation distance threshold, the mark of the use point is False, and the use point is discarded;
[0172] In the iterative optimization process, when the number of obtained use points increases or decreases to a minimum preset value with the number of iterations, the iterative optimization is terminated. When the proportion of the obtained use points to the total number of points is less than a preset minimum number of matching point pairs, the iterative optimization is terminated. When the marks of the obtained use points and the mark situation are consistent before and after two times, the iterative optimization is terminated. When the maximum number of iterations is reached, the iterative optimization is terminated.
[0173] The optimal alignment result includes an alignment transformation relationship, a point set after conversion of actual points, a deviation distance, and an RMS error.
[0174] From the above technical solutions, the application provides a number model alignment method based on point pair features, acquires point pair features, and the point pair features include nominal points and actual points; wherein the nominal points are key features in the grid model data of the workpiece to be measured; the actual points are key features in the point cloud data of the workpiece to be measured, and correspond to the nominal points; a target point set is determined, and the target points in the target point set are actual points corrected according to the nominal points in the effective direction; under the condition of no coordinate system constraint or a preset coordinate system constraint, an initial alignment result is determined according to the target point set and the nominal point set; the initial alignment result is iteratively optimized according to the deviation distance constraint to obtain an optimal alignment result. Through the diversity of point pair features, the application is beneficial to selecting stable and reliable key features from data, so that the applicable fast matching scene is extensive; the effective direction constraint and the coordinate system constraint can limit the freedom degree of the alignment result, and then the interference point pairs are removed through the deviation distance constraint iterative optimization, so as to improve the precision of the alignment result.
[0175] The above content only illustrates the technical idea of the application, and cannot limit the protection scope of the application. Any modification made according to the technical idea of the application on the basis of the technical solution falls within the protection scope of the claims of the application.
[0176] Furthermore, the order of the processing elements and sequences, unless specifically stated by the claim, are not intended to be limiting, although the use of a particular order or sequence does not preclude the use of another order or sequence, unless explicitly claimed. The descriptions, definitions and / or terminology employed throughout this disclosure are used for the purpose of describing and teaching the embodiments of the present application, and are not intended to limit the scope of the claims. Although the foregoing disclosure has been described in some detail for the purposes of clarity and understanding, it will be apparent that certain changes and modifications can be practiced within the scope of the appended claims. Accordingly, the foregoing description is intended to be illustrative only and not restrictive. For example, while the above-described system components can be implemented by hardware devices, they can also be implemented by software solutions only, such as installing the described system on an existing server or mobile device.
[0177] Similarly, it is to be noticed that the term "comprising", used in the description, is not intended to exclude other elements or steps. It is to be understood that the embodiments can also be in the form of a computer program containing one or more sequences of machine-readable instructions coded for execution by a programmable machine such as a computer, mobile device, or the like. The machine-readable instructions are stored in a memory of the machine, which can be a machine readable storage medium. The instructions are used to program the machine to perform a process, such as one of the processes described herein. The instructions can be software written in any suitable machine language, including, but not limited to, C, C++, Java, Python, or the like. The software can be coded by a person of ordinary skill in the art writing code using the language and / or tools of the trade for the programming language.
[0178] Each patent, patent application, publication, document, article, book, specification, and / or other material cited, referenced, or otherwise referred to herein is hereby incorporated by reference in its entirety, except for any disclaimer of any portion of the citation, which shall remain retained. That incorporation by reference is done solely for the limited purpose of adding information to the disclosure herein, and should not be construed as authorizing the incorporation by reference of any statement, claim, limitation, or other material that would otherwise be insufficiently disclosed under 35 U.S.C. § 112, or 37 C.F.R. § 1.57, or that would introduce into the disclosure herein any amendment that would not otherwise be permitted. To the extent that any material incorporated by reference contradicts or conflicts with this disclosure, including defined terms, the disclosure herein controls.
Claims
1. A method for point-to-feature based digital-to-model alignment, the method comprising: The method comprises the following steps: obtaining a pair of features, the pair of features comprising a nominal point and an actual point; wherein the nominal point is a key feature in the grid model data of the workpiece to be measured; the actual point is a key feature in the point cloud data of the workpiece to be measured, and corresponds to the nominal point; determining a target point set, the target point in the target point set being an actual point corrected according to the nominal point in an effective direction; under a no-coordinate system constraint condition or a preset coordinate system constraint condition, determining an initial alignment result according to the target point set and a nominal point set; under the no-coordinate system constraint condition, the determination of the initial alignment result comprises the following steps: determining the barycenters of the target points and the nominal points; decentering the target points by the barycenters of the target points and decentering the nominal points by the barycenters of the nominal points; determining an initial alignment result, the initial alignment result comprising a rotation matrix and a translation amount, the rotation matrix being determined by an equation established by the decentered target points and the decentered nominal points, and the translation amount being determined by the barycenters of the target points, the barycenters of the nominal points and the rotation matrix; under the preset coordinate system constraint condition, the determination of the initial alignment result comprises the following steps: determining a plurality of alignment results according to the target point set and the nominal point set, the alignment result comprising a rotation matrix and a translation amount; selecting, as the initial alignment result, the alignment result in which the target point set after being transformed according to the preset coordinate system constraint has the minimum difference with the nominal point set; wherein the coordinate system constraint comprises a rotation constraint and a translation constraint; the actual point corrected according to the nominal point in an effective direction is a coordinate data in a corresponding direction dimension reserved in the actual point according to the type of the effective direction, and the coordinate data in other direction dimensions except the effective direction is replaced by the coordinate data in the nominal point; The effective directions include XYZ direction, XY direction, XZ direction, YZ direction, X direction, Y direction, and Z direction; the target point reserves the coordinates of the corresponding direction dimensions in the actual point through the type of the effective direction, and the coordinates of the remaining direction dimensions are replaced with the data in the nominal point, where the actual point is g and the nominal point is q; g x ,g y ,g z X, Y, and Z coordinates of the actual point, respectively, q x ,q y ,q z X, Y, and Z coordinates of the nominal point, respectively, and the target point p obtained by the correction method is as follows:
2. The method of claim 1, wherein, after the initial alignment result is determined, the method further comprises the following steps: iteratively optimizing the initial alignment result according to a deviation distance constraint to obtain an optimal alignment result.
3. The method of claim 1, wherein, under the preset coordinate system constraint condition, the determination of the alignment result comprises the following steps: determining the barycenters of the target points and the nominal points; correcting the barycenters of the target points and the nominal points according to the translation constraint; decentering the target points by the corrected barycenters of the target points and decentering the nominal points by the corrected barycenters of the nominal points; determining a rotation matrix and resetting a corresponding rotation angle according to the rotation constraint, the rotation matrix being determined by an equation established by the decentered target points and the decentered nominal points; determining a translation amount by the rotation matrix after the rotation angle is reset, and resetting a corresponding coordinate according to the translation constraint.
4. The method of claim 1, wherein, under the preset coordinate system constraint condition, the determination of the alignment result comprises the following steps: determining a rotation matrix and resetting a corresponding rotation angle according to the rotation constraint, the rotation matrix being determined by an equation established by the target points and the nominal points; determining a translation amount by the rotation matrix after the rotation angle is reset, and resetting a corresponding coordinate according to the translation constraint.
5. The method of claim 1, wherein, under the preset coordinate system constraint condition, the determination of the alignment result comprises the following steps: determining the barycenters of the target points and the nominal points; decentering the target points by the center of gravity of the target points, and decentering the nominal points by the center of gravity of the nominal points; determining a rotation matrix, the rotation matrix being determined by an axis rotation matrix of a rotation angle of each direction; determining a translation amount by the rotation matrix after resetting the rotation angle, and resetting the corresponding coordinates according to the translation constraint.
6. The point-to-feature based number model alignment method of claim 2, wherein, iteratively optimizing the initial alignment result according to a deviation distance constraint, including: obtaining a deviation between each target point after rigid body transformation and the corresponding nominal point; labeling the use points according to the deviation, the use points being the points of each target point after rigid body transformation.
7. The method according to claim 6, characterized in that: terminating the iterative optimization when the number of use points obtained constantly increases or decreases to a minimum preset value with the number of iterations; terminating the iterative optimization when the proportion of the use points obtained to the total number of points is less than a preset minimum matching point pair proportion; terminating the iterative optimization when the labeling and labeling situation of the use points obtained in two adjacent times are consistent; terminating the iterative optimization when a maximum number of iterations is reached.
Citation Information
Patent Citations
Space positioning method based on digital codes
CN105046629A
A point clouds ghosting effects detection system for autonomous driving vehicles
US20210327128A1