Method and device for extracting point cloud contour

Through point cloud segmentation and topological contour extraction technology, the existing technology problems of point cloud contour extraction being unable to represent topological structure and noise interference are solved, and the accurate extraction and denoising effect of point cloud contours is achieved.

CN118587235APending Publication Date: 2024-09-03SHANGHAI BOCHU ELECTRONIC TECH CORP LTD
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202410688437.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-30
Publication Date
2024-09-03

AI Technical Summary

Technical Problem

Existing point cloud contour extraction methods cannot accurately represent the topological structure of point clouds, especially when complex structures and noise exist, it is difficult to obtain complete and accurate contours.

Method used

The original point cloud is divided into sub-point clouds through the point cloud segmentation algorithm, and topological contours are extracted for each sub-point cloud to generate outer contours and inner contours, and remove noise to improve extraction accuracy.

Benefits of technology

It achieves accurate extraction of point cloud contours, can clearly represent the topological structure of the contour, reduces the extraction complexity, improves accuracy and eliminates interference from adjacent parts.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118587235A
    Figure CN118587235A
Patent Text Reader

Abstract

The invention provides a method and a device for extracting a point cloud contour. The method for extracting the point cloud contour comprises the following steps: acquiring an original point cloud; performing a point cloud segmentation operation on the original point cloud to obtain one or more sub-point clouds; and performing a topological contour extraction operation on each of the one or more sub-point clouds to generate a point cloud contour with a topological structure of the original point cloud, the topological contour extraction operation performed on each of the one or more sub-point clouds including performing an initial contour extraction operation on the sub-point clouds, and performing a topological contour extraction operation on each of the one or more sub-point clouds to generate a point cloud contour with a topological structure of the original point cloud, the point cloud profile with the topological structure is used for obtaining a sub-point cloud initial profile, and a profile topology generation operation is performed on the sub-point cloud initial profile to generate an outer profile and an inner profile of the sub-point cloud, and wherein the point cloud profile with the topological structure of the original point cloud comprises the outer profile and the inner profile for each of the one or more sub-point clouds.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates generally to computer graphics, and more particularly to a method and apparatus for extracting contours of a point cloud. Background Art

[0002] With the improvement of automation and intelligence in industrial manufacturing, especially in automated manufacturing and processing scenarios, the application of part point cloud data is becoming more and more widespread. Generally speaking, point cloud data is often obtained by scanning parts placed on machine tools using laser sensors. This type of point cloud data is usually represented as an unordered point set. In practical applications, it is necessary to automatically identify and locate parts by processing point cloud data so that the machine can obtain appropriate parts from the machine tool for production and processing.

[0003] In order to accurately identify and locate parts, the processing of point cloud data should at least include the extraction of point cloud contours and the determination of their topological structure. In fact, accurately extracting the point cloud contours helps to determine the position of the parts on the machine tool through the external boundaries of the parts, and determining the topological structure of the point cloud contours based on the accurate extraction of the point cloud contours helps to identify the internal and external boundaries of each part, thereby facilitating the accurate acquisition and placement of the part.

[0004] However, the point cloud contours extracted by the currently commonly used point cloud extraction methods still appear as disordered point sets, which cannot indicate the topological structure of the point cloud contours. In addition, these existing point cloud extraction methods cannot adapt to the contour extraction of complex point clouds and are not robust enough to noise. As an example, in the point cloud contour extraction method based on alphaShape, the rolling ball radius r is set so that the rolling ball rolls through the point cloud, and the points through which the rolling ball rolls form a contour point set of the point cloud. However, on the one hand, the contour point set obtained by this method is still disordered and cannot be well distinguished between different parts and the internal and external contours of parts; and on the other hand, when the parts represented by the point cloud data have a porous structure, or when the point cloud data contains a lot of noise, it is difficult to eliminate the interference of adjacent contours or noise by setting the rolling ball radius to obtain a complete and accurate point cloud contour. Summary of the invention

[0005] The present invention provides a method and device for extracting point cloud contours, which can accurately extract point cloud contours with topological structures. Specifically, in the point cloud contour extraction scheme proposed in the present invention, the original point cloud is first segmented into one or more sub-point clouds based on the point cloud segmentation algorithm, and then the point cloud contour is extracted for each sub-point cloud, thereby eliminating the interference of the point cloud data of the adjacent parts on the extraction of the point cloud contour of the current part, thereby improving the accuracy of contour extraction. On this basis, the point cloud contour extraction scheme proposed in the present invention further performs a topological generation operation, processes the extracted sub-point cloud contours to generate the outer contour and inner contour of the sub-point cloud, thereby, each part can be characterized by the outer contour point set and the inner contour point set of the corresponding sub-point cloud, and obtains a point cloud contour with a topological structure. In addition, the technical solution proposed in the present invention further proposes a corresponding denoising operation based on the parts themselves and their placement on the machine tool, and first removes the noise in the original point cloud data before processing the original point cloud data, thereby further improving the accuracy of point cloud contour extraction.

[0006] According to a first aspect of the present invention, a method for extracting point cloud contours is provided, the method comprising: acquiring an original point cloud; performing a point cloud segmentation operation on the original point cloud to obtain one or more sub-point clouds; and performing a topological contour extraction operation on each of the one or more sub-point clouds to generate a point cloud contour with a topological structure for the original point cloud, wherein performing a topological contour extraction operation on each of the one or more sub-point clouds comprises: performing an initial contour extraction operation on the sub-point cloud to obtain an initial contour of the sub-point cloud, and performing a contour topology generation operation on the initial contour of the sub-point cloud to generate an outer contour and an inner contour of the sub-point cloud, and wherein the point cloud contour with a topological structure of the original point cloud includes an outer contour and an inner contour for each of the one or more sub-point clouds.

[0007] The method as described above is characterized in that performing a contour topology generation operation on the initial contour of the sub-point cloud includes: calculating the initial outer boundary of the sub-point cloud based on the initial contour of the sub-point cloud; determining whether a contour point on the initial contour of the sub-point cloud is within the initial outer boundary, wherein the contour point includes a first contour point; and in response to determining that the first contour point is not within the initial outer boundary, generating the outer contour of the sub-point cloud based on the first contour point.

[0008] A method as described in any of the above items, characterized in that the contour points also include second contour points, and performing a contour topology generation operation on the initial contour of the sub-point cloud also includes: in response to determining that the second contour point is within the initial outer boundary, performing a clustering operation on the second contour point to obtain a candidate inner contour point cluster; and generating one or more inner contours of the sub-point cloud based on the candidate inner contour point cluster.

[0009] The method as described in any of the above items is characterized in that generating one or more inner contours of the sub-point cloud based on the candidate inner contour point cluster includes: determining whether the number of points included in the candidate inner contour point cluster is greater than a point number threshold; and in response to determining that the number of points included in the candidate inner contour point cluster is greater than the point number threshold, generating the one or more inner contours of the sub-point cloud based on the candidate inner contour point cluster.

[0010] A method as described in any of the above items, characterized in that calculating the initial outer boundary of the sub-point cloud includes: mapping the initial contour of the sub-point cloud to an image, wherein the image includes image points corresponding to contour points in the initial contour of the sub-point cloud, and the image points indicate one or more image contours of the image; calculating the areas of the one or more image contours; and finding the image contour with the largest area among the one or more image contours, and wherein determining whether the contour point is within the initial outer boundary includes: determining whether the image point of the image is within the image contour with the largest area, wherein the image point of the image being within the image contour with the largest area indicates that the contour point corresponding to the image point is within the initial outer boundary.

[0011] The method as described in any of the above items is characterized in that calculating the initial outer boundary of each point cloud also includes: performing image preprocessing operations on the image, wherein the image preprocessing operations at least include smoothing operations, binarization operations, and image opening and closing operations.

[0012] A method as described in any of the above items, characterized in that calculating the initial outer boundary of the sub-point cloud includes: calculating the concave hull boundary of the contour points of the initial contour of the sub-point cloud, wherein the concave hull boundary is used as the initial outer boundary of the sub-point cloud, and wherein determining whether the contour point is within the initial outer boundary includes: determining whether the contour point of the initial contour of the sub-point cloud is within the concave hull boundary.

[0013] A method as described in any of the above items is characterized in that the method also includes: preprocessing the original point cloud to remove points in the original point cloud whose z coordinate values ​​are less than or equal to the reference Z value, and wherein performing a point cloud segmentation operation on the original point cloud includes: performing the point cloud segmentation operation on the preprocessed original point cloud.

[0014] The method as described in any of the above items is characterized in that performing a point cloud segmentation operation on a preprocessed original point cloud includes: calculating the curvature of each point in the preprocessed original point cloud; selecting a point in the preprocessed original point cloud whose curvature is less than a curvature threshold as a seed point, and using a neighboring point of the seed point whose normal includes an angle less than an angle threshold with the normal of the seed point as a candidate point, to perform a region growing algorithm on the preprocessed original point cloud to obtain one or more point clusters; and providing the one or more point clusters as the one or more sub-point clouds.

[0015] The method as described in any of the above items is characterized in that performing a contour extraction operation on the sub-point cloud includes: performing contour extraction on the sub-point cloud via a point cloud contour extraction algorithm based on a normal vector or a point cloud contour extraction algorithm based on an alphaShape.

[0016] According to a second aspect of the present invention, a device for extracting point cloud contours is provided, the device comprising: a point cloud segmentation module, the point cloud segmentation module being configured to: acquire an original point cloud; perform a point cloud segmentation operation on the original point cloud to obtain one or more sub-point clouds; and a topology contour extraction module, the point cloud contour extraction module being coupled to the point cloud segmentation module, being configured to perform a topology contour extraction operation on each of the one or more sub-point clouds through the following steps to generate a point cloud contour with a topological structure for the original point cloud: perform an initial contour extraction operation on the sub-point cloud to obtain an initial contour of the sub-point cloud; and perform a contour topology generation operation on the initial contour of the sub-point cloud to generate an outer contour and an inner contour of the sub-point cloud, and wherein the point cloud contour with a topology structure for the original point cloud includes an outer contour and an inner contour for each of the one or more sub-point clouds.

[0017] The device as described above is characterized in that the point cloud segmentation module is also configured to: pre-process the original point cloud to remove points in the original point cloud whose z coordinate values ​​are less than or equal to the reference Z value; and perform the point cloud segmentation operation on the pre-processed original point cloud.

[0018] The device as described in any of the above items is characterized in that, in order to perform a contour topology generation operation on the initial contour of the sub-point cloud, the topology contour extraction module is configured to: calculate the initial outer boundary of the sub-point cloud based on the initial contour of the sub-point cloud; determine whether the contour points on the initial contour of the sub-point cloud are within the initial outer boundary, wherein the contour points include a first contour point; and in response to determining that the first contour point is not within the initial outer boundary, generate the outer contour of the sub-point cloud based on the first contour point.

[0019] The device as described in any of the above items is characterized in that the contour points also include second contour points, and in order to perform a contour topology generation operation on the initial contour of the sub-point cloud, the topology contour extraction module is also configured to: in response to determining that the second contour point is within the initial outer boundary, perform a clustering operation on the second contour point to obtain a candidate inner contour point cluster; and generate one or more inner contours of the sub-point cloud based on the candidate inner contour point cluster.

[0020] The device as described in any of the above items is characterized in that, in order to generate one or more inner contours of the sub-point cloud based on the candidate inner contour point cluster, the topology contour extraction module is configured to: determine whether the number of points included in the candidate inner contour point cluster is greater than a point number threshold; and in response to determining that the number of points included in the candidate inner contour point cluster is greater than the point number threshold, generate the one or more inner contours of the sub-point cloud based on the candidate inner contour point cluster.

[0021] The device as described in any of the above items is characterized in that the topological contour extraction module is configured to: map the initial contour of the sub-point cloud to an image, wherein the image includes image points corresponding to contour points in the initial contour of the sub-point cloud, and the image points indicate one or more image contours of the image; calculate the area of ​​the one or more image contours; find the image contour with the largest area among the one or more image contours; and determine whether the image point of the image is within the image contour with the largest area, the image point including a first image point; in response to determining that the first image point is not within the image contour with the largest area, determine that the contour point corresponding to the image point is not within the initial outer boundary of the sub-point cloud.

[0022] The device as described in any of the above items is characterized in that the topological contour extraction module is also configured to: perform image preprocessing operations on the image, wherein the image preprocessing operations at least include smoothing operations, binarization operations, and image opening and closing operations.

[0023] The device as described in any of the above items is characterized in that the topological contour extraction module is configured to: calculate the concave hull boundary of the contour points of the initial contour of the sub-point cloud; determine whether the contour points of the initial contour of the sub-point cloud are within the concave hull boundary; and in response to determining that the first contour point is not within the concave hull boundary, determine that the first contour point is not within the initial outer boundary of the sub-point cloud.

[0024] According to a third aspect of the present invention, there is provided a component positioning device for determining the position of one or more components, the component positioning device comprising: a sensing device for sensing the one or more components to generate original point cloud data representing the one or more components; and a device as described in any one of the above second aspects of the present invention, the device being coupled to the sensing device.

[0025] According to a fourth aspect of the present invention, there is provided a machine-readable medium having instructions stored thereon, wherein when the instructions are executed by a machine, the machine executes the method as described above in any one of the methods according to the first aspect of the present invention.

[0026] According to a fifth aspect of the present invention, a computing device is provided, comprising: a processor; and a memory, the memory being coupled to the processor and configured to store instructions, which, when executed by the processor, cause the processor to perform a method as described above in any one of the methods according to the first aspect of the present invention.

[0027] According to a sixth aspect of the present invention, there is provided a computer program product, comprising a computer program, wherein the computer program implements the method as described above in any one of the first aspects of the present invention when executed. BRIEF DESCRIPTION OF THE DRAWINGS

[0028] Some examples of apparatus and / or methods will be described below by way of example only and with reference to the accompanying drawings, in which:

[0029] Figure 1 A flow chart showing a contour extraction method according to an embodiment of the present invention;

[0030] Figure 2 A flow chart showing a contour extraction method according to an embodiment of the present invention;

[0031] Figure 3 A flowchart showing a contour topology generation operation according to an embodiment of the present invention;

[0032] Figure 4 A flowchart showing a contour topology generation operation according to an embodiment of the present invention;

[0033] Figure 5 A flowchart showing a contour topology generation operation according to an embodiment of the present invention;

[0034] Figure 6 A flowchart showing a point cloud segmentation operation according to an embodiment of the present invention is shown;

[0035] Figure 7 A schematic block diagram showing a contour extraction device according to an embodiment of the present invention;

[0036] Figure 8 A schematic block diagram showing a component positioning device according to an embodiment of the present invention;

[0037] Fig. 9 An original point cloud is shown as an example;

[0038] Fig.10 The sub-point clouds obtained by performing the point cloud segmentation operation according to the embodiment of the present invention are exemplarily shown;

[0039] Fig.11 exemplarily showing an initial contour obtained by performing an initial contour extraction operation on a sub-point cloud according to an embodiment of the present invention; and

[0040] Fig.12 The point cloud contour with a topological structure obtained by executing the contour generation method according to an embodiment of the present invention is exemplarily shown. DETAILED DESCRIPTION

[0041] In the following description, numerous specific details are set forth. However, it should be understood that embodiments of the present invention may be practiced without these specific details. In other instances, well-known circuits, structures, and techniques are not shown in detail to avoid obscuring the understanding of this description.

[0042] References in the specification to "one embodiment," "an embodiment," "an example embodiment," etc. indicate that the described embodiment may include a particular feature, structure, or characteristic, but not every embodiment may include the particular feature, structure, or characteristic. Furthermore, such phrases do not necessarily refer to the same embodiment. Furthermore, when a particular feature, structure, or characteristic is described in conjunction with an embodiment, it is considered to be within the knowledge of those skilled in the art to affect such feature, structure, or characteristic in conjunction with other embodiments, whether or not explicitly described.

[0043] For purposes of this disclosure, the phrase "A and / or B" means (A), (B), or (A and B). For purposes of this disclosure, the phrase "A, B, and / or C" means (A), (B), (C), (A and B), (A and C), (B and C), or (A, B, and C).

[0044] In the following description and claims, the term "coupled" and its derivatives may be used. In certain embodiments, "coupled" may be used to indicate that two or more elements are in direct physical or electrical contact with each other. However, "coupled" may also mean that two or more elements are not in direct contact with each other, but still cooperate or interact with each other.

[0045] In automatic manufacturing and processing scenarios, the parts to be processed are placed on the machine tool, and the sensors scan these parts to obtain their original point clouds, which represent the various feature points on the parts and the machine tool sensed by the sensors, and each feature point corresponds to a point in the original point cloud. In order to accurately characterize the positions of these points, an orthogonal coordinate system is usually established with the sensor as the origin, and these feature points are represented by the coordinates of these points in the orthogonal coordinate system. As an example, a point cloud can be represented as an unordered point set {(x1, y1, z1); (x2, y2, z2); (x3, y3, z3); ​​... (xn, yn, zn)}. Point cloud contour extraction is to extract points from the unordered point set that are used to represent the external or internal boundaries of the parts. The results of the conventional point cloud contour extraction method are usually represented as another unordered point set composed of these points representing the boundaries.

[0046] The present invention proposes a point cloud contour extraction scheme capable of accurately extracting a point cloud contour with a topological structure.

[0047] Figure 1 A flow chart of a point cloud contour extraction method 100 according to an embodiment of the present invention is shown.

[0048] like Figure 1 As shown, method 100 starts at box 102, where an original point cloud is obtained. As an example, the original point cloud can be obtained by scanning the corresponding object with a sensor such as a laser, infrared, or ultrasonic. According to an embodiment of the present invention, a line laser sensor can be used to scan multiple parts placed on a machine tool to obtain an original point cloud representing these parts. As an example, Fig. 9 The figure shows the original point cloud obtained by scanning multiple parts placed on the machine tool using a line laser sensor.

[0049] like Figure 1 As shown, method 100 also includes box 104, in which a point cloud segmentation operation is performed on the original point cloud to obtain one or more sub-point clouds. As an exemplary embodiment, clustering based on the curvature, normal vector, tangent plane, etc. of the point, a region growing algorithm, etc. can be used to segment the original point cloud. According to an embodiment of the present invention, in an exemplary application scenario, the upper surface of a component that meets the specifications is usually a plane, and the original point cloud acquired by the line laser sensor represents the upper surface of the plane, so that the original point cloud can be segmented into one or more sub-point clouds based on the curvature and normal vector angle of the point, and these sub-point clouds each represent a separate component. This exemplary point cloud segmentation operation is referred to below. Figure 6 To further describe in detail. And as an example, Fig.10 The Fig. 9 The original point cloud shown in FIG. 1 is subjected to a point cloud segmentation operation to obtain multiple sub-point clouds.

[0050] like Figure 1 As shown, the method 100 further includes block 106 , at which a topology contour extraction operation is performed on a single sub-point cloud among the one or more sub-point clouds obtained in block 104 .

[0051] According to an embodiment of the present invention, performing a topological contour extraction operation on a single sub-point cloud further includes: at box 1062, performing an initial contour extraction operation on the sub-point cloud to obtain an initial contour of the sub-point cloud of the sub-point cloud; and at box 1064, performing a contour topology generation operation on the initial contour of the sub-point cloud to generate an outer contour and an inner contour of the sub-point cloud. According to an embodiment of the present invention, at box 1062, an alphaShape-based contour extraction method may be used to extract the initial contour of the sub-point cloud of the sub-point cloud. Alternatively, according to an embodiment of the present invention, a normal-based contour extraction algorithm may be used to take each point in the sub-point cloud as a corner point, calculate the angle between the point and its neighboring points in the tangent plane of the point, and take the point whose maximum angle is greater than the angle threshold as a contour point to extract the initial contour of the sub-point cloud. According to an embodiment of the present invention, the contour topology generation operation performed on the initial contour of the sub-point cloud at block 1064 can distinguish the inner contour points and the outer contour points included in the initial contour of the sub-point cloud by determining the initial outer boundary of the sub-point cloud and based on whether the points in the sub-point cloud are within the initial outer boundary, and generate the inner contour and the outer contour of the sub-point cloud accordingly. Figure 3-Figure 4 This contour topology generation operation is described in further detail.

[0052] like Figure 1 As shown, the method 100 further includes a frame 108, at which it is determined whether there are any sub-point clouds that have not been processed (i.e., the topology contour extraction operation has not been performed). When it is determined at frame 108 that there are no sub-point clouds that have not been processed, the method 100 ends at frame 110; and when it is determined at frame 108 that there are still sub-point clouds that have not been processed, the method 100 returns to frame 106 and repeats the operations at frame 106 (including frame 1062-frame 1064) until all the sub-point clouds obtained at frame 104 are processed.

[0053] Thus, according to an embodiment of the present invention, a point cloud contour with a topological structure of the original point cloud can be obtained through method 100. As an exemplary implementation, such a point cloud contour with a topological structure can be represented as a contour set of each sub-point cloud, including the outer contour Contour of each sub-point cloud. ext and inner contour inter (If there is an inner contour), each outer contour and inner contour is a set of corresponding contour points. For example, the point cloud contour with topological structure of the original point cloud can be expressed as Contour = {(Contour ext ,Contour inter1,Contour inter2 ),(Contour ext ),(Contour ext ,Contour inter1 ,Contour inter2 ,Contour inter3 ),(Contour ext ,Contour inter )}.

[0054] Therefore, the point cloud contour extracted by the contour extraction method proposed in the present invention can clearly represent the topological structure of the contour, so as to accurately characterize the geometric features of the object. In addition, since the original point cloud is first segmented into one or more sub-point clouds based on the point cloud segmentation algorithm before point cloud contour extraction, point cloud contour extraction can be performed for each sub-point cloud, which can reduce the complexity of point cloud contour extraction, save computing resources, and eliminate the interference of point cloud data of neighboring parts on the point cloud contour extraction of the current part, thereby improving the accuracy of contour extraction. As an example, Fig.11 According to an embodiment of the present invention, Fig.10 The initial contours of each sub-point cloud obtained by performing an initial contour extraction operation on the sub-point cloud shown in FIG. 1 , wherein different colors are used to distinguish the initial contours of each sub-point cloud.

[0055] Figure 2 A flow chart of a point cloud contour extraction method 200 according to an embodiment of the present invention is shown.

[0056] like Figure 2 As shown, the method 200 starts at block 202, where an original point cloud is obtained. According to an embodiment of the present invention, a line laser sensor may be used to scan a plurality of parts placed on a machine tool to obtain original point clouds representing these parts.

[0057] like Figure 2 As shown, method 200 further includes box 203, where the obtained raw point cloud is preprocessed to remove noise. According to an embodiment of the present invention, in an exemplary application scenario, a component is supported by a tooth tip of a machine tool. Therefore, when a line laser sensor is used to sense the component, the characteristic points on the tooth tip are also scanned by the sensor as raw point cloud data, resulting in more noise in the raw point cloud obtained at box 202. As an example, Fig. 9The figure shows the original point cloud obtained by scanning multiple parts placed on the machine tool using a line laser sensor, which shows the noise caused by the machine tool tooth tip. In order to ensure the accuracy of point cloud segmentation and point cloud contour extraction, appropriate preprocessing operations are required to remove these noises. Since the parts are supported on the tooth tips of the machine tool, in the same orthogonal coordinate system, the value of the z coordinate (i.e., the height) of the corresponding feature point on the upper surface of the parts must be greater than the height of the tooth tip. According to an embodiment of the present invention, by setting a plane with a height equal to the height of the tooth tip as a reference plane and eliminating points in the point cloud that are on or below the reference plane, the noise in the point cloud can be effectively removed. According to an embodiment of the present invention, the height of the reference plane can be set to a reference Z value, and the original point cloud can be preprocessed by removing points in the original point cloud whose z coordinate values ​​are less than or equal to the reference Z value to effectively remove the noise in the original point cloud.

[0058] like Figure 2 As shown, method 200 also includes box 204, in which a point cloud segmentation operation is performed on the preprocessed original point cloud to obtain one or more sub-point clouds. According to an embodiment of the present invention, in an exemplary application scenario, the upper surface of a component that meets the specifications is usually a plane, and the original point cloud acquired by the line laser sensor represents the upper surface of the plane. Therefore, the preprocessed original point cloud can be segmented into one or more sub-point clouds based on the curvature of the point and the angle of the normal vector. This point cloud segmentation operation based on the curvature of the point and the angle of the normal vector can also further remove noise, so that the accuracy of point cloud segmentation and subsequent contour extraction is improved. The following will refer to Figure 6 This point cloud segmentation operation based on curvature and normal vector angle is further described in detail.

[0059] like Figure 2 As shown, the method 200 further includes blocks 206 to 210, and the operations at blocks 206 to 210 are the same as those described above with reference to Figure 1 The operations in blocks 106 to 110 are similar and will not be described in detail here to avoid obscuring the understanding of the present invention.

[0060] Figure 3 A flow chart of a contour topology generation operation 300 for generating a contour topology of a sub-point cloud according to an embodiment of the present invention is shown.

[0061] like Figure 3 As shown, operation 300 starts at block 302, where an initial outer boundary of a sub-point cloud is calculated based on an initial contour of the sub-point cloud. According to an embodiment of the present invention, the initial outer boundary of the sub-point cloud can be calculated based on each contour point of the initial contour of the sub-point cloud using a rolling ball method.

[0062] like Figure 3As shown, operation 300 may further include block 304, at which it is determined whether each contour point is within the initial outer boundary of the sub-point cloud calculated at block 302. According to an embodiment of the present invention, the position of the contour point relative to the initial outer boundary may be determined based on the coordinates of each contour point, and thereby it is determined whether the contour point is within the initial outer boundary.

[0063] like Figure 3 As shown, operation 300 may also include block 306, where, in response to determining at block 304 that the contour point is not within the initial outer boundary, the contour point may be correspondingly determined as an outer contour point for generating an outer contour of the sub-point cloud, and the outer contour of the sub-point cloud may be generated based on these determined outer contour points. According to an embodiment of the present invention, the outer contour of the sub-point cloud may be represented as a set of outer contour points.

[0064] like Figure 3 As shown, operation 300 may also include box 308, at which, in response to determining at box 304 that the contour point is within the initial outer boundary, the contour point may be correspondingly determined as a candidate inner contour point for the inner contour of the sub-point cloud, and one or more candidate inner contour point clusters may be generated based on these candidate inner contour points through a clustering operation. Subsequently, at box 310, one or more inner contours of the sub-point cloud are generated based on the candidate inner contour point clusters generated at box 308. According to an embodiment of the present invention, in the case where the sub-point cloud only includes an outer contour but does not have an inner contour, via the contour topology generation operation 300, a point cloud contour with a topological structure of the sub-point cloud may be generated based on the initial contour of the sub-point cloud, represented as a set of outer contour points.

[0065] like Figure 3 As shown, operation 300 may also optionally include: at box 309, determining whether the number of points included in the candidate inner contour point cluster is greater than a point number threshold T Pnum ; and at box 311, in response to determining that the number of points included in the candidate inner contour point cluster is less than or equal to the point number threshold T Pnum On this basis, according to an embodiment of the present invention, the candidate inner contour point clusters based on which one or more inner contours of the sub-point cloud are generated at box 310 are candidate inner contour point clusters screened based on the number of points included in the point clusters, that is, at box 310, the candidate inner contour point clusters whose number of included points is greater than the point number threshold T are discarded. Pnum The candidate inner contour point clusters provide one or more inner contours as sub-point clouds.

[0066] Next, refer to Figure 4 The image space-based contour topology generation operation 400 is described.

[0067] like Figure 4As shown, operation 400 starts at block 402, where the initial outline of the sub-point cloud is mapped to the image space, and is mapped to a corresponding image in the image space. According to an embodiment of the present invention, the outline points included in the initial outline of the sub-point cloud can be mapped to image points (e.g., pixel points) in the image space, and these image points constitute one or more image outlines of the image, and accordingly, the image outline also corresponds to the initial outline of the sub-point cloud.

[0068] like Figure 4 As shown, according to an embodiment of the present invention, operation 400 may also optionally include box 403, at which the image mapped at box 402 is preprocessed. According to an embodiment of the present invention, the image may be smoothed based on a filtering algorithm such as a Gaussian filter. In addition, according to an embodiment of the present invention, a binarization operation may be performed on the image to convert it into a binary image, and a morphological opening and closing operation may be performed to further filter noise in the image.

[0069] like Figure 4 As shown, operation 400 further includes block 404, where the area of ​​one or more image contours is calculated. According to an embodiment of the present invention, the area of ​​the image contour can be calculated based on OpenCV (e.g., using the contourArea function in the OpenCV library) and according to the pixel points corresponding to the image contour.

[0070] like Figure 4 As shown, operation 400 also includes block 406, at which the image contour with the largest area is found. According to an embodiment of the present invention, a sorting algorithm can be used to sort the image contours based on the area and determine the image contour with the largest area. Alternatively, according to an embodiment of the present invention, each image contour can be traversed to find the image contour with the largest area.

[0071] like Figure 4 As shown, operation 400 further includes block 408, at which it is determined whether the image point is within the image contour with the largest area found at block 406. According to an embodiment of the present invention, it can be determined based on OpenCV (for example, using the pointPolygonTest function in the OpenCV library) whether each pixel point of the image is within the image contour with the largest area.

[0072] like Figure 4As shown, operation 400 further includes box 410. At box 410, in response to determining at box 408 that the image point is not within the image contour with the largest area, it can be determined that the contour point of the initial contour of the sub-point cloud corresponding to the image point is not within the initial outer boundary, that is, the contour point can be used as an outer contour point for generating the outer contour of the sub-point cloud. Subsequently, operation 400 can proceed to box 412, at which the outer contour of the sub-point cloud is generated based on the outer contour point determined at box 410. According to an embodiment of the present invention, the outer contour of the sub-point cloud can be represented as a set of outer contour points.

[0073] like Figure 4 As shown, operation 400 also includes box 414. At box 414, in response to determining at box 408 that the image point is within the image contour with the largest area, it can be determined that the contour point of the initial contour of the sub-point cloud corresponding to the image point is within the initial outer boundary, that is, the contour point can be used as a candidate inner contour point for generating the inner contour of the sub-point cloud.

[0074] like Figure 4 As shown, operation 400 may also include blocks 416-419, where the operations at blocks 416-419 are similar to those described above. Figure 3 The operations of the described blocks 308 to 311 are similar and will not be described in detail here to avoid obscuring the understanding of the present invention.

[0075] Next, refer to Figure 5 1 and 10. A contour topology generation operation 500 according to another embodiment of the present invention is described.

[0076] like Figure 5 As shown, operation 500 starts at block 502. At block 502, a rolling ball method is used to calculate the concave hull boundary of the sub-point cloud based on each contour point of the initial contour of the sub-point cloud by setting an appropriate rolling ball radius r. According to an embodiment of the present invention, the concave hull boundary of the sub-point cloud can be used as its initial outer boundary.

[0077] like Figure 5 As shown, operation 500 may further include block 504, at which it is determined whether each contour point is within the concave hull boundary of the sub-point cloud calculated at block 502. According to an embodiment of the present invention, the position of the contour point relative to the concave hull boundary may be determined based on the coordinates of each contour point, and thereby it is determined whether the contour point is within the concave hull boundary.

[0078] like Figure 5 As shown, operation 500 may also include box 506. At box 506, in response to determining at box 504 that the contour point is not within the concave hull boundary of the sub-point cloud, the contour point can be correspondingly determined as an outer contour point for generating an outer contour of the sub-point cloud, and the outer contour of the sub-point cloud can be generated based on these determined outer contour points.

[0079] like Figure 5 As shown, operation 500 may also include box 508. At box 508, in response to determining at box 504 that the contour point is within the concave hull boundary of the sub-point cloud, the contour point can be correspondingly determined as a candidate inner contour point for the inner contour of the sub-point cloud, and one or more candidate inner contour point clusters can be generated based on these candidate inner contour points through a clustering operation.

[0080] like Figure 5 As shown, operation 500 may also include blocks 509 to 511, and the operations at blocks 509 to 511 are the same as those described above. Figure 3 The operations of the described blocks 309 to 311 are similar and will not be described in detail here to avoid obscuring the understanding of the present invention.

[0081] As an example, Fig.12 The embodiment according to the present invention shows Fig.11 The initial outline of the sub-point cloud shown in FIG. 1 is a point cloud outline with a topological structure obtained by performing the outline topology generation operation, wherein different colors are used to distinguish the inner outline from the outer outline, and further to distinguish between different inner outlines. Fig.12 The point cloud contour with topological structure is shown Fig. 9 The components shown in the figure have a good correspondence, that is, the geometric features of each component can be clearly and accurately characterized.

[0082] Next reference Figure 6 The point cloud segmentation operation 600 based on curvature and normal vector angle is described.

[0083] like Figure 6 As shown, operation 600 starts at block 602, where the curvature of each point in the point cloud is calculated. According to an embodiment of the present invention, an original point cloud may be obtained and the curvature of each point in the original point cloud may be calculated. According to another embodiment of the present invention, a pre-processed original point cloud (e.g., a denoised original point cloud) may be obtained and the curvature of each point in the pre-processed original point cloud may be calculated.

[0084] like Figure 6 As shown, operation 600 may also include block 604, where it is determined whether the curvature of the point is less than a curvature threshold T Curv In an exemplary scenario, since the upper surface of the component that meets the specification is substantially flat, the curvature threshold T Curv Set to a small value close to zero. According to an embodiment of the present invention, the curvature threshold T may be set according to specific part specifications, manufacturing tolerances, etc. Curv Set to experience value.

[0085] like Figure 6As shown, the operation 600 may also include block 606, at which, in response to determining at block 604 that the curvature of the point is greater than or equal to the curvature threshold T Curv , this point can be ignored and not used as the seed point of the region growing algorithm.

[0086] like Figure 6 As shown, the operation 600 may also include block 608, at which, in response to determining at block 604 that the curvature of the point is less than a curvature threshold T Curv , the point can be added to the seed point set as the seed point of the region growing algorithm. Thus, by traversing the point cloud based on the curvature of the point, the corresponding seed point set can be generated.

[0087] like Figure 6 As shown, operation 600 may also include box 610, at which a seed point is selected. According to an embodiment of the present invention, the seed point set may be sorted based on the curvature of the point, and the point with the smallest curvature in the seed point set may be selected as the seed point in each iteration round. According to another embodiment of the present invention, other methods may be used to select the seed point, such as selecting any point in the seed point set that has not been processed in each iteration round as the seed point of the current round.

[0088] like Figure 6 As shown, operation 600 may further include block 612, where the angle between the normal of the neighboring point of the selected seed point and the normal of the seed point is calculated. According to an embodiment of the present invention, the number K of neighboring points to be calculated may be determined based on data sparsity of the point cloud data, etc. According to an embodiment of the present invention, the number K of neighboring points may be set to an empirical value based on an application scenario.

[0089] like Figure 6 As shown, the operation 600 may further include a block 614, at which it is determined whether the angle calculated at the block 612 is less than an angle threshold T ang According to an embodiment of the present invention, the curvature threshold T can be set according to specific part specifications, manufacturing tolerances, etc. ang Set to experience value.

[0090] like Figure 6 As shown, operation 600 may also include block 616, at which, in response to determining at block 614 that the angle between the normal of one or more of the K neighboring points and the normal of the seed point is greater than or equal to the angle threshold T ang , discard the one or more neighboring points.

[0091] like Figure 6As shown, the operation 600 may also include a block 618, at which, in response to determining at block 614 that the angle between the normal of one or more of the K neighboring points and the normal of the seed point is less than an angle threshold T ang , add the one or more neighboring points to the current point cluster. Thus, according to an embodiment of the present invention, based on the K nearest neighbor algorithm, a point cluster can be grown in the current iteration round, and the point cluster can be provided as a sub-point cloud of the original point cloud.

[0092] like Figure 6 As shown, operation 600 may further include block 620, where it is determined whether there are any unprocessed seed points in the seed point set (i.e., seed points that have not yet participated in the growth process as seed points). Subsequently, in response to determining at block 620 that there are no unprocessed seed points in the seed point set, operation 600 ends at block 622; in response to determining at block 620 that there are still unprocessed seed points in the seed point set, the process returns to block 610 to repeat the region growing process described above in the next iteration round.

[0093] According to the embodiment of the present invention, since the upper surface of the parts that meet the specifications is usually a plane, the original point cloud obtained by the line laser sensor represents the upper surface of the plane, so this point cloud segmentation operation based on the curvature of the point and the angle of the normal vector can also further remove the noise in the original point cloud, so that the accuracy of point cloud segmentation and subsequent contour extraction is improved. As an example, Fig.10 FIG. 4 shows the result of executing the point cloud segmentation operation based on curvature and normal vector angle according to an embodiment of the present invention, wherein each sub-point cloud is distinguished by different colors, and these sub-point clouds correspond to Fig. 9 The various components shown in Fig.10 As shown, the point cloud segmentation operation according to the embodiment of the present invention can effectively combat noise and clearly segment the original point cloud into various sub-point clouds for representing separate parts.

[0094] The present invention also provides a point cloud contour extraction device, which can accurately extract the point cloud contour with a topological structure.

[0095] Figure 7 A point cloud contour extraction device 700 according to an embodiment of the present invention is schematically shown.

[0096] like Figure 7 As shown, the device 700 includes a point cloud segmentation module 702. According to an embodiment of the present invention, the point cloud segmentation module 702 may be configured to obtain raw point cloud data from an external sensing device (such as a laser sensor) or a processing device (eg, a processor).

[0097] According to an embodiment of the present invention, the point cloud segmentation module 702 may also be configured to perform a point cloud segmentation operation on the acquired original point cloud to obtain one or more sub-point clouds. As an exemplary implementation, the point cloud segmentation module 702 may be configured to perform clustering, regional growing algorithms, etc. based on the curvature, normal vector, tangent plane, etc. of the point to segment the original point cloud. According to an embodiment of the present invention, in an exemplary application scenario, the point cloud segmentation module 702 may be configured to segment the original point cloud into one or more sub-point clouds based on the curvature and normal vector angle of the point, and these sub-point clouds each represent a separate component. According to an embodiment of the present invention, the point cloud segmentation module 702 may also be configured to pre-process the original point cloud and perform a point cloud segmentation operation on the pre-processed original point cloud. As an exemplary implementation, in the exemplary application scenario where the component is supported by the tooth tip of the machine tool as described above, a plane with a height equal to the tooth tip height may be set as a reference plane and points on or below the reference plane in the point cloud may be removed, thereby effectively removing noise in the point cloud. According to an embodiment of the present invention, the point cloud segmentation module 702 can be configured to pre-process the original point cloud by removing points in the original point cloud whose z coordinate values ​​are less than or equal to a reference value, so as to effectively remove noise in the original point cloud, wherein the height of the reference plane can be set to the reference value.

[0098] like Figure 7 As shown, the device 700 also includes a topology contour extraction module 704, which can be coupled to the point cloud segmentation module 702 to receive one or more sub-point clouds obtained by segmenting the original point cloud from the point cloud segmentation module 702. According to an embodiment of the present invention, the topology contour extraction module 704 is configured to perform a topology contour extraction operation on each of the one or more sub-point clouds to generate a point cloud contour with a topological structure of the original point cloud. According to an embodiment of the present invention, the topology contour extraction module 704 can be configured to perform a topology contour extraction operation on each sub-point cloud through the following steps: performing an initial contour extraction operation on the sub-point cloud to obtain an initial contour of the sub-point cloud; and performing a contour topology generation operation on the obtained initial contour of the sub-point cloud to generate an outer contour and an inner contour of the sub-point cloud. According to an embodiment of the present invention, the point cloud contour with a topological structure of the original point cloud includes an outer contour and an inner contour for each of the one or more sub-point clouds.

[0099] According to an embodiment of the present invention, the contour topology generation module 704 can be configured to calculate the initial outer boundary of the sub-point cloud based on the initial contour of the sub-point cloud, and distinguish the inner contour and outer contour included in the initial contour of the sub-point cloud by determining whether the contour points of the initial contour of the sub-point cloud are within the initial outer boundary.

[0100] According to an embodiment of the present invention, the contour topology generation module 704 may be configured to determine the contour point as an outer contour point in response to determining that the contour point is not within the initial outer boundary, and accordingly generate the outer contour of the sub-point cloud based on these determined outer contour points. According to an embodiment of the present invention, the outer contour of the sub-point cloud may be represented as a set of outer contour points. According to an embodiment of the present invention, the contour generation module 704 may be configured to determine the contour point as a candidate inner contour point for the inner contour of the sub-point cloud in response to determining that the contour point is within the initial outer boundary, and generate one or more inner contours of the sub-point cloud based on these candidate inner contour points through a clustering operation. Thus, the contour generation module 704 can further distinguish between different inner contours of the sub-point cloud.

[0101] According to an embodiment of the present invention, the contour generation module 704 may be configured to further filter the point clusters generated by the clustering operation. As an exemplary implementation, the contour generation module 704 may be configured to filter the number of points included in the candidate inner contour point clusters generated based on clustering. Pnum To perform screening: In response to determining that the number of points included in the candidate inner contour point cluster is less than or equal to the point number threshold T Pnum , discard the candidate inner contour point cluster; and in response to determining that the number of points included in the candidate inner contour point cluster is greater than the point number threshold T Pnum , providing these candidate inner contour point clusters as one or more inner contours of the sub-point cloud.

[0102] Therefore, the point cloud contour extraction device provided by the present invention can not only distinguish the point cloud data used to characterize each component, and distinguish between its outer contour and inner contour, but also can further distinguish different inner contours, thereby being able to clearly represent the topological structure of the point cloud contour, and thus being able to accurately characterize the geometric features of the object. In addition, since the original point cloud is first segmented into one or more sub-point clouds based on the point cloud segmentation algorithm before the point cloud contour is extracted, the point cloud contour can be extracted for each sub-point cloud, which can reduce the complexity of the point cloud contour extraction, save computing resources, and eliminate the interference of the point cloud data of the neighboring components on the point cloud contour extraction of the current component, thereby improving the accuracy of contour extraction.

[0103] According to an embodiment of the present invention, the contour topology generation module 704 may be configured to map the sub-point cloud initial contour to an image in an image space, and perform a contour topology generation operation by processing the image. According to an embodiment of the present invention, the sub-point cloud initial contour is mapped to an image in an image space, the image includes image points corresponding to contour points in the sub-point cloud initial contour, and these image points constitute one or more image contours included in the image.

[0104] As a non-limiting embodiment, the contour topology generation module 704 can be configured to use the corresponding function provided in the OpenCV library to distinguish the inner contour and the outer contour of the preprocessed binary image based on the pixel point. According to an embodiment of the present invention, the contour topology generation module 704 can be configured to calculate the area of ​​the image contour based on OpenCV (for example, using the contourArea function in the OpenCV library) according to the corresponding pixel points of the image contour, and find the image contour with the largest area. According to an embodiment of the present invention, the contour topology generation module 704 can be configured to determine whether each pixel point of the image is in the image contour with the largest area based on OpenCV (for example, using the pointPolygonTest function in the OpenCV library). Based on the determination of whether each pixel point of the image is in the image contour with the largest area, the contour topology generation module 704 can correspondingly determine whether the contour points corresponding to each pixel point are in the initial outer boundary. According to an embodiment of the present invention, in response to determining that a pixel point is not within the image contour with the largest area, the contour topology generation module 704 may determine the outer contour points based on these pixel points; and in response to determining that the pixel point is not within the image contour with the largest area, the contour topology generation module 704 may determine the corresponding inner contour points based on these pixel points.

[0105] As a non-limiting embodiment, the contour topology generation module 704 can be configured to pre-process the image obtained by mapping. According to an embodiment of the present invention, the image can be smoothed based on filtering algorithms such as Gaussian filtering. In addition, according to an embodiment of the present invention, the image can also be subjected to a binarization operation to be converted into a binary image, and a morphological opening and closing operation is performed to further filter the noise in the image. On this basis, the contour topology generation module 704 can be configured to distinguish between an inner contour and an outer contour based on the pre-processed binary image.

[0106] According to an embodiment of the present invention, the contour topology generation module 704 may also be configured to calculate the initial outer boundary of the sub-point cloud by a rolling ball method. As a non-limiting implementation, the contour topology generation module 704 may use the rolling ball method, based on the contour points of the initial contour of the sub-point cloud, and by setting an appropriate rolling ball radius r to calculate the concave hull boundary of the sub-point cloud, and the concave hull boundary of the sub-point cloud may be used as its initial outer boundary. According to an embodiment of the present invention, the contour topology generation module 704 may determine whether the contour points of the initial contour of the sub-point cloud are within the concave hull boundary of the sub-point cloud, and distinguish the outer contour points from the inner contour points based on this determination, and further generate the outer contour and inner contour of the sub-point cloud.

[0107] The present invention also provides a component positioning device for accurately positioning the component on a machine tool by processing point cloud data representing the component, thereby facilitating the identification of the internal and external boundaries of each component, thereby facilitating accurate acquisition and placement of the component.

[0108] Figure 8 FIG. 8 is a schematic block diagram of a component positioning device 800 according to an embodiment of the present invention.

[0109] like Figure 8 As shown, the device 800 includes a sensing device 802, and includes the above reference Figure 7 The point cloud contour extraction device 700 described. According to an embodiment of the present invention, the sensing device 802 may be configured to be used to scan parts on a machine tool by laser, infrared, ultrasound, etc. to generate point cloud data for characterizing these parts. According to an embodiment of the present invention, the sensing device 802 may be implemented as a line laser sensor. According to an embodiment of the present invention, the point cloud contour extraction device 700 may be coupled to the sensing device 802 to obtain the original point cloud from the sensing device 802 and process it to accurately extract the point cloud contour with a topological structure of the original point cloud.

[0110] The systems and devices described in the embodiments of the present invention may be implemented in the form of hardware, software or a combination thereof.

[0111] One or more aspects of at least one embodiment of the present invention may be implemented as a computer program product, wherein program code is applied to input instructions to perform the functions described herein and generate output information. Output information may be applied to one or more output devices in a known manner. For the purposes of this application, the present invention also provides a computing device, which includes any system with a processor, such as, for example, a digital signal processor (DSP), a microcontroller, an application specific integrated circuit (ASIC) or a microprocessor. The computing device also includes a memory, which is coupled to the processor for storing program code. The program code can be implemented with a high-level procedural programming language or an object-oriented programming language.

[0112] One or more aspects of at least one embodiment of the invention may be implemented by representative instructions stored on a machine-readable medium that represent various logic within a processor, which when read by a machine causes the machine to fabricate logic for performing the techniques described herein.

[0113] The preferred embodiments of the present invention are described in detail above. However, it should be understood that the present invention can be implemented in various ways and variations without departing from its broad spirit and scope. A person skilled in the art can make many modifications and changes based on the concept of the present invention without creative work. Therefore, any technical solution that can be obtained by a person skilled in the art through logical analysis, reasoning or limited experiments based on the concept of the present invention on the basis of the prior art should fall within the scope of protection determined by the claims of the present invention.

Claims

1. A method for extracting a point cloud contour, comprising: Get the original point cloud; Performing a point cloud segmentation operation on the original point cloud to obtain one or more sub-point clouds; as well as performing a topological contour extraction operation on each of the one or more sub-point clouds to generate a point cloud contour with a topological structure of the original point cloud, The performing of a topological contour extraction operation on each of the one or more sub-point clouds comprises: Performing an initial contour extraction operation on the sub-point cloud to obtain an initial contour of the sub-point cloud, and Performing a contour topology generation operation on the initial contour of the sub-point cloud to generate an outer contour and an inner contour of the sub-point cloud, And wherein, the point cloud contour with topological structure of the original point cloud includes an outer contour and an inner contour for each of the one or more sub-point clouds.

2. The method according to claim 1, characterized in that Performing a contour topology generation operation on the initial contour of the sub-point cloud includes: Based on the initial outline of the sub-point cloud, calculating the initial outer boundary of the sub-point cloud; determining whether contour points on the initial contour of the sub-point cloud are within the initial outer boundary, wherein the contour points include a first contour point; and In response to determining that the first contour point is not within the initial outer boundary, an outer contour of the sub-point cloud is generated based on the first contour point.

3. The method according to claim 2, characterized in that The contour points further include a second contour point, and performing a contour topology generation operation on the sub-point cloud initial contour further includes: In response to determining that the second contour point is within the initial outer boundary, performing a clustering operation on the second contour point to obtain a candidate inner contour point cluster; and One or more inner contours of the sub-point cloud are generated based on the candidate inner contour point clusters.

4. The method according to claim 3, characterized in that Generating one or more inner contours of the sub-point cloud based on the candidate inner contour point clusters includes: Determining whether the number of points included in the candidate inner contour point cluster is greater than a point number threshold; and In response to determining that the number of points included in the candidate inner contour point cluster is greater than a point number threshold, the one or more inner contours of the sub-point cloud are generated based on the candidate inner contour point cluster.

5. The method according to claim 2, characterized in that Calculating the initial outer boundary of the sub-point cloud includes: Mapping the sub-point cloud initial contour to an image, wherein the image includes image points corresponding to contour points in the sub-point cloud initial contour, and the image points indicate one or more image contours of the image; calculating areas of the one or more image contours; and Find the image contour with the largest area among the one or more image contours, And wherein determining whether the contour point is within the initial outer boundary comprises: Determine whether the image point of the image is within the image contour with the largest area, wherein the image point of the image is within the image contour with the largest area, indicating that the contour point corresponding to the image point is within the initial outer boundary.

6. The method according to claim 5, characterized in that Calculating the initial outer boundary of each point cloud further includes: Performing an image preprocessing operation on the image, wherein the image preprocessing operation at least includes a smoothing operation, a binarization operation, and an image opening and closing operation.

7. The method according to claim 2, characterized in that Calculating the initial outer boundary of the sub-point cloud includes: Calculating the concave hull boundary of the contour points of the initial contour of the sub-point cloud, wherein the concave hull boundary is used as the initial outer boundary of the sub-point cloud, And wherein determining whether the contour point is within the initial outer boundary comprises: Determine whether the contour points of the initial contour of the sub-point cloud are within the concave hull boundary.

8. The method according to claim 1, characterized in that The method further comprises: Preprocessing the original point cloud to remove points whose z coordinate values ​​are less than or equal to the reference Z value in the original point cloud, And wherein, performing a point cloud segmentation operation on the original point cloud comprises: The point cloud segmentation operation is performed on the preprocessed original point cloud.

9. The method according to claim 8, characterized in that The point cloud segmentation operation performed on the pre-processed original point cloud includes: Calculating the curvature of each point in the preprocessed original point cloud; Selecting points in the preprocessed original point cloud whose curvature is less than a curvature threshold as seed points, and selecting neighboring points of the seed point whose normals have an angle with the normal of the seed point less than an angle threshold as candidate points, to perform a region growing algorithm on the preprocessed original point cloud to obtain one or more point clusters; and The one or more point clusters are provided as the one or more sub-point clouds.

10. The method according to claim 1, characterized in that Performing a contour extraction operation on the sub-point cloud includes: performing contour extraction on the sub-point cloud via a point cloud contour extraction algorithm based on a normal vector or a point cloud contour extraction algorithm based on an alphaShape.

11. A device for extracting a point cloud contour, comprising: A point cloud segmentation module, wherein the point cloud segmentation module is configured to: Get the original point cloud; Performing a point cloud segmentation operation on the original point cloud to obtain one or more sub-point clouds; and A topology contour extraction module, the point cloud contour extraction module is coupled to the point cloud segmentation module, and is configured to perform a topology contour extraction operation on each of the one or more sub-point clouds through the following steps to generate a point cloud contour with a topological structure of the original point cloud: Performing an initial contour extraction operation on the sub-point cloud to obtain an initial contour of the sub-point cloud; as well as Performing a contour topology generation operation on the initial contour of the sub-point cloud to generate an outer contour and an inner contour of the sub-point cloud, And wherein, the point cloud contour with topological structure of the original point cloud includes an outer contour and an inner contour for each of the one or more sub-point clouds.

12. The device according to claim 11, characterized in that The point cloud segmentation module is further configured to: Preprocessing the original point cloud to remove points in the original point cloud whose z coordinate values ​​are less than or equal to the reference Z value; and The point cloud segmentation operation is performed on the preprocessed original point cloud.

13. The device according to claim 11, characterized in that In order to perform a contour topology generation operation on the initial contour of the sub-point cloud, the topology contour extraction module is configured to: Based on the initial outline of the sub-point cloud, calculating the initial outer boundary of the sub-point cloud; determining whether contour points on the initial contour of the sub-point cloud are within the initial outer boundary, wherein the contour points include a first contour point; as well as In response to determining that the first contour point is not within the initial outer boundary, an outer contour of the sub-point cloud is generated based on the first contour point.

14. The device according to claim 13, characterized in that The contour points further include a second contour point, and in order to perform a contour topology generation operation on the sub-point cloud initial contour, the topology contour extraction module is further configured to: In response to determining that the second contour point is within the initial outer boundary, performing a clustering operation on the second contour point to obtain a candidate inner contour point cluster; and One or more inner contours of the sub-point cloud are generated based on the candidate inner contour point clusters.

15. The device according to claim 14, characterized in that In order to generate one or more inner contours of the sub-point cloud based on the candidate inner contour point clusters, the topology contour extraction module is configured to: Determine whether the number of points included in the candidate inner contour point cluster is greater than a point number threshold; as well as In response to determining that the number of points included in the candidate inner contour point cluster is greater than a point number threshold, the one or more inner contours of the sub-point cloud are generated based on the candidate inner contour point cluster.

16. The device according to claim 13, characterized in that The belt topology contour extraction module is configured to: Mapping the sub-point cloud initial contour to an image, wherein the image includes image points corresponding to contour points in the sub-point cloud initial contour, and the image points indicate one or more image contours of the image; calculating the area of ​​the one or more image contours; Finding the image contour with the largest area among the one or more image contours; as well as Determine whether an image point of the image is within the image contour with the largest area, the image point including a first image point; In response to determining that the first image point is not within the image contour with the largest area, it is determined that the contour point corresponding to the image point is not within an initial outer boundary of the sub-point cloud.

17. The device according to claim 16, characterized in that The belt topology contour extraction module is further configured to: Performing an image preprocessing operation on the image, wherein the image preprocessing operation at least includes a smoothing operation, a binarization operation, and an image opening and closing operation.

18. The device according to claim 13, characterized in that The belt topology contour extraction module is configured to: Calculate the concave hull boundary of the contour points of the initial contour of the sub-point cloud; Determining whether the contour point of the initial contour of the sub-point cloud is within the concave hull boundary; and In response to determining that the first contour point is not within the concave hull boundary, determining that the first contour point is not within an initial outer boundary of the sub-point cloud.

19. A component positioning device for determining the position of one or more components, the component positioning device comprising: A sensing device, the sensing device is used to sense the one or more components to generate an original point cloud representing the one or more components; as well as The device of any one of claims 11-18, coupled to the sensing device.

20. A machine-readable medium having instructions stored thereon, wherein when the instructions are executed by a machine, the machine is caused to perform the method according to any one of claims 1 to 10.

21. A computing device comprising: processor; as well as A memory, coupled to the processor, configured to store instructions, which, when executed by the processor, cause the processor to perform the method according to any one of claims 1 to 10.

22. A computer program product comprising a computer program, characterized in that The computer program implements the method according to any one of claims 1 to 10 when executed.

Citation Information

Patent Citations

  • Field block field ridge extraction method, electronic equipment and storage medium

    CN115049925A

  • Cabin driving area division method and system based on point cloud polygon fitting

    CN117152672A

  • Workpiece contour extraction method, storage medium and terminal equipment

    CN117437251A

  • Method and device for transferring statics

    US20140257762A1