Rapid point cloud labeling method based on three-dimensional CAD model and RGB value thereof

Through the RGB value mapping table and grid uniform sampling technology based on the three-dimensional CAD model, the rapid automatic labeling of point cloud data is achieved, solving the problems of low labeling efficiency and poor quality in the existing technology, and improving the labeling accuracy and application value.

CN119206079APending Publication Date: 2024-12-27UNIV OF ELECTRONICS SCI & TECH OF CHINA
View PDF 0 Cites 3 Cited by

Patent Information

Application Number
CN202411360597.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-27
Publication Date
2024-12-27

AI Technical Summary

Technical Problem

The prior art has problems such as inefficient, high cost and poor automatic labeling quality in point cloud data annotation, especially in dealing with complex three-dimensional geometric details and achieving high-precision automated labeling.

Method used

Using the fast point cloud labeling method based on the three-dimensional CAD model and its RGB value, the color information of the point cloud corresponds to the three-dimensional spatial location by establishing a category-RGB value-label mapping table, and the color information of the point cloud is corresponding to the three-dimensional spatial location, so as to achieve rapid automatic labeling of different three-dimensional and shape surfaces. . The method includes assigning standard colors to complex models in CAD software, grid processing, exporting PLY format files, assigning RGB values, performing uniform sampling and expansion points, and determining the label based on the RGB values ​​matching the mapping table.

Benefits of technology

It greatly reduces manual participation, improves labeling efficiency and data set quality, can accurately distinguish and mark different three-dimensional and shape surfaces, and is suitable for three-dimensional modeling, product quality inspection and other fields, enhancing the application value of point cloud data.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119206079A_ABST
    Figure CN119206079A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of three-dimensional computer vision and point cloud processing, and provides a point cloud rapid labeling method based on a three-dimensional CAD model and RGB values thereof. The method aims at solving the problems that in the deep learning data set construction process, three-dimensional point cloud semantic information labeling efficiency is low, the labor cost is high, and the automatic labeling quality is poor. The color information of the three-dimensional point cloud is effectively converted into the semantic label, so that quick and automatic labeling of different three-dimensional and profile surfaces in the point cloud is realized. The method comprises the steps of establishing a category-RGB value-label mapping table, carrying out CAD entity modeling and assigning a standard color to an entity surface geometrical shape, setting entity model gridding parameters and exporting the entity model gridding parameters as a PLY format, assigning color RGB values of mesh model patches to vertexes, uniformly sampling expansion points of the mesh model patches, traversing the points and reading the RGB values, and finally obtaining a model. And adding labels according to the category-RGB value-label mapping table, and the like. The method can be applied to the fields of three-dimensional modeling, product quality detection, industrial design and the like.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to the technical field of three-dimensional computer vision and point cloud processing, and provides a point cloud fast annotation method based on a three-dimensional CAD model and its RGB values. Background Art

[0002] Point cloud, as a collection of discrete points in three-dimensional space, has become an important carrier for three-dimensional data collection, processing and analysis due to its rich location, color and other attribute information. Point cloud data can be captured through a variety of advanced equipment and technologies, including but not limited to lidar scanning, structured light projection technology, photogrammetry, depth sensor detection and sampling from three-dimensional models. The processing and analysis of point clouds usually involves point cloud registration, filtering, segmentation, reconstruction and other algorithms to achieve various applications, such as three-dimensional modeling, reverse engineering, autonomous driving, etc.

[0003] With the vigorous development of artificial intelligence, especially deep learning technology, the processing of point cloud data has shown significant advantages such as end-to-end learning, efficient processing of high-dimensional data, strong environmental adaptability and automatic feature learning. Deep learning models have shown superior versatility and efficiency in point cloud task processing, and can directly serve tasks such as point cloud object detection and semantic segmentation, providing great flexibility for dealing with diverse scenarios and applications. However, deep learning algorithms have a strong dependence on large-scale, high-quality, labeled training data sets.

[0004] The current mainstream method of point cloud annotation is for specialized operators to manually annotate point by point using professional annotation software such as CloudCompare. This method faces the dilemma of low work efficiency and susceptibility to subjective factors. In addition, due to the natural disorder, sparsity and uneven distribution of point cloud data, problems such as missing labels and mislabeling are very likely to occur during the manual annotation process, which seriously affects the training effect and prediction accuracy of the deep learning model.

[0005] Point Cloud Annotation refers to the process of manually or automatically labeling point cloud data in three-dimensional space, assigning specific label information to each point, a group of points, or the entire object in the point cloud data. Point cloud annotation is the basis for deep learning model training in the fields of autonomous driving, robot navigation, 3D reconstruction, etc. Through high-quality annotated data, the model can learn how to extract useful structural information and semantic information from raw, unprocessed point cloud data, thereby achieving accurate information, perception, and analysis.

[0006] The labels of point clouds can be classification labels, bounding boxes, semantic segmentation labels, or key point coordinates, so that machine learning algorithms can understand and identify the objects and environmental features contained in the point cloud. The specific meanings of the four commonly used annotations are:

[0007] 1. Classification labeling: Assigning a category label to a single point, such as marking a point as a car, pedestrian, tree, or member of another predefined category.

[0008] 2. Bounding box annotation: Define a three-dimensional bounding box for the target object in the point cloud to indicate the position and size of the object.

[0009] 3. Semantic segmentation and annotation: Annotation is performed at the point cloud level, that is, a label is assigned to each point to indicate which category it belongs to, so that different types of areas can be distinguished, such as roads, buildings, vegetation, etc.

[0010] 4. Key point marking: For objects with complex shapes, mark the locations of their significant feature points, such as human joints, center points of vehicle parts, etc.

[0011] At present, point cloud annotation can be divided into three types according to the working mode, namely manual annotation, automatic annotation and semi-automatic annotation.

[0012] 1) Manual labeling

[0013] Manual annotation is the most common point cloud annotation method, which requires annotators to classify and segment the point cloud data. The advantage of this method is that the annotation quality is high, but the disadvantage is that it is time-consuming and labor-intensive, and it is difficult to meet the processing requirements of large-scale data sets.

[0014] The detailed steps of manual annotation are as follows: In the data preparation stage, the original point cloud data needs to be imported into special point cloud processing and annotation software, such as CloudCompare, PCL (Point Cloud Library) supporting tools, Labelbox, CVAT, etc. These tools support point cloud visualization and interactive operations. In the visualization interface, the annotator can directly observe and analyze the point cloud data, which usually displays the different distances and reflection intensity information of the object in the form of colored points, and then annotates the semantic labels point by point. The point cloud manual annotation method has significant accuracy advantages in three-dimensional data processing, especially for complex scenes, fuzzy boundaries and the recognition and segmentation of new categories. It can provide highly flexible and meticulous label information. However, the shortcomings of this method are also prominent: first, the manual annotation of large-scale point cloud data sets is huge, time-consuming and costly; second, the consistency between different annotators is difficult to ensure, and rigorous quality control and standardized processes are required; third, the efficiency of manual processing is much lower than that of automated algorithms, which cannot meet the needs of efficient processing in the era of big data; finally, subjective factors such as fatigue may lead to an increase in annotation errors, which restricts the application and development of this method in large-scale projects. Therefore, although manual labeling is indispensable in some specific scenarios, with the advancement of technology, the industry is actively developing automatic or semi-automatic point cloud labeling tools to overcome these limitations.

[0015] 2) Automatic labeling

[0016] Automatic labeling is the process of automatically classifying and segmenting point cloud data through computer algorithms. The advantages of this method are fast labeling speed and low cost, but the disadvantages are that the labeling quality may be low and a large amount of training data is required to optimize the algorithm. Currently, commonly used automatic labeling methods include semantic segmentation based on deep learning and cluster analysis.

[0017] The point cloud automatic annotation method uses machine learning and deep learning techniques to automatically identify and mark various objects in three-dimensional point cloud data by training models. This method first relies on a large-scale point cloud dataset with precise manual annotations, and inputs these data into deep neural networks such as PointNet and PointCNN designed for processing point clouds for training. During the training process, the model learns to extract effective information from the spatial distribution, density and features of the point cloud to achieve semantic segmentation or target detection of objects. The advantage of automatic annotation is that it can process massive data quickly and on a large scale, significantly improve annotation efficiency, and reduce manual burden. However, its accuracy is limited by algorithm performance, training data quality and scene complexity. For some fuzzy boundaries, severe occlusion or rare situations, the annotation effect may not be as fine and accurate as manual annotation. Therefore, in practical applications, it is often combined with semi-automatic means for optimization and verification.

[0018] 3) Semi-automatic labeling

[0019] Semi-automatic annotation is a combination of manual and automatic annotation, and is currently the most commonly used annotation method. Usually, automatic annotation is used to preliminarily process the data, and then the preliminary results are manually corrected and improved. The advantage of this method is that it not only ensures the annotation speed, but also takes into account the annotation quality, but there are still certain limitations. Its shortcomings are mainly reflected in two aspects: First, although semi-automatic annotation reduces the workload, it still requires a considerable degree of manual intervention, especially in complex scenes, the manual workload is greatly increased; second, it depends on the initial algorithm performance. If the algorithm does not recognize targets of a specific type or form well, the subsequent manual revision workload will also increase significantly. The semi-automatic point cloud annotation method embodies the effective complementarity of artificial intelligence and human wisdom in practical applications, and achieves a balance between the efficiency and accuracy of point cloud data processing. It is currently the mainstream data preprocessing method in the fields of autonomous driving, robot navigation, etc.

[0020] In view of the current development status of point cloud data annotation technology, different solutions have been proposed to improve the speed and quality of point cloud annotation. Patent "Point cloud data annotation method, device, equipment and medium" [1]The original point cloud dataset is divided into multiple subsets, and then the pre-trained prediction model is used to classify and predict these subsets respectively, and the labeling results of each point in the original point cloud dataset are determined based on the predicted categories and probabilities. This method has two major limitations: on the one hand, it relies on the high accuracy of the pre-trained model. If the model performance is not good, the overall accuracy of the labeled dataset is difficult to guarantee; on the other hand, it requires a large-scale and comprehensive point cloud dataset to train the prediction model, that is, a large number of well-labeled point clouds are required to ensure that a labeled dataset with good robustness is obtained. The patent "CN202111565263.3 A method, system, device and medium for point cloud labeling and dataset production" introduces a point cloud labeling method that combines depth image and RGB image information. By processing the same label object in the color image to make it appear in a single color, the point cloud data (RGB point cloud) with RGB information is extracted accordingly, and the RGB thresholds of various objects are set accordingly to further label the point cloud data. (In this proposal, the term "RGB point cloud" is used to refer specifically to the point set containing the spatial coordinates of the point and the corresponding color information (RGB value).) The advantage of this method is that it can make full use of the existing mature two-dimensional image target detection algorithm to achieve more accurate annotation of the RGB point cloud. However, this method is only applicable to point cloud data containing RGB information on the one hand, and the color information collected in the real environment is often affected by various environmental factors on the other hand, so it is not ideal to use color directly as the basis for classification. The patent "CN111062255A Three-dimensional Point Cloud Annotation Method, Device, Equipment and Storage Medium" proposes to use a three-dimensional view to display the point cloud and annotate it by contour selection. The user can observe the point cloud from multiple perspectives and select the part to be annotated. The system recognizes the contour and annotates it uniformly. Although this contour-based selection method simplifies the annotation process to a certain extent, it still fails to break through the annotation bottleneck of the entire point cloud or larger-scale shapes, and cannot effectively meet the needs of fine-grained and multi-level annotation of three-dimensional point clouds, such as the task of fine-grained annotation of different three-dimensional surfaces such as cylinders, spheres, cones, tori and planes in the point cloud.

[0021] In summary, although the existing technology has made certain progress in the field of point cloud data annotation, it still faces many challenges, especially in processing complex three-dimensional geometric details and achieving high-precision automatic annotation. There is an urgent need for more intelligent, flexible and universal new annotation methods and systems. Summary of the invention

[0022] The purpose of the present invention is to address the problems of low efficiency, high labor cost and poor quality of automatic annotation of three-dimensional point cloud semantic information in the process of building deep learning data sets, and propose a point cloud semantic information annotation method based on a three-dimensional CAD model, which effectively converts the color information of the three-dimensional point cloud into semantic labels, thereby realizing fast and automatic annotation of different solids and shapes in the point cloud. This method corresponds the color information of the point cloud to the three-dimensional spatial position, can accurately distinguish and mark different solids and shapes, has a simple principle, an efficient algorithm, can greatly reduce the workload of manual participation, improves the annotation efficiency and the quality of the data set, and lays a good foundation for the efficient application of deep learning methods in the field of three-dimensional point cloud analysis.

[0023] In order to achieve the above purpose, the present invention adopts the following technical solutions:

[0024] A method for rapid annotation of point clouds based on a three-dimensional CAD model and its RGB values, characterized by comprising the following steps:

[0025] Step 1: According to the categories involved in the specific labeling task labels, a category-RGB value-label mapping table is established to ensure that different three-dimensional or surface point clouds have significant color differences during the visual labeling process;

[0026] Step 1.1, determine the specific category of the labeling task and assign a unique label to each category;

[0027] Step 1.2, set an RGB value other than black for each category to form a mapping relationship between color and category;

[0028] Step 1.3: Integrate the categories, RGB values, and labels into a mapping table to ensure consistency and recognizability of the annotations;

[0029] Step 1.4: Preset a specific category "boundary point", corresponding to those points that belong to two or more categories at the same time, fix its label to 0, and fix its color to black, that is, RGB value (0, 0, 0);

[0030] Step 1.5: The user adjusts and confirms the category-RGB value-label mapping table according to specific task requirements.

[0031] Step 2: Use computer-aided design (CAD) software to perform three-dimensional solid modeling on the complex model, and assign standard colors to each solid or surface of the solid model according to the category-RGB value-label mapping table established in step 1;

[0032] Step 2.1, create a 3D solid model of the complex model in CAD software;

[0033] Step 2.2, according to the mapping table in step 1, select the corresponding RGB value for each part of the solid model;

[0034] Step 2.3: Apply the selected color to the corresponding solid or surface of the solid model.

[0035] Step 3: Set the meshing parameters of the solid model and export it to PLY format to save and reproduce the color information of the solid model surface.

[0036] Step 3.1, adjust the mesh size and roughness parameters according to the geometric complexity, surface smoothness and target application scenario of the solid model, export the model into a PLY format file, generate a triangular or quadrilateral unit mesh, that is, discretize the solid surface into polygonal patches. The PLY file format can ensure that each mesh patch carries the color RGB value of its corresponding category;

[0037] Step 4: Assign the mesh model patch color RGB value to the vertex

[0038] Step 4.1, traverse all vertices in the mesh model and their associated face sets;

[0039] Step 4.2, access the color attributes of all faces adjacent to each vertex;

[0040] Step 4.3: When all the faces associated with a vertex have the same color, assign the RGB value of the color to the vertex;

[0041] Step 4.4: When a vertex is associated with a patch with two or more colors, the vertex color is assigned to black, that is, the RGB value is (0, 0, 0).

[0042] However, the point cloud model derived from the PLY grid model, especially the point cloud of regular surface, is often a sparse point cloud with very few points or even only boundary points, so the number of points needs to be further expanded to meet the needs of subsequent processing.

[0043] Step 5: Uniformly sample expansion points on mesh model patches

[0044] Step 5.1, access each patch in the PLY file exported in step 3;

[0045] Step 5.2: Perform uniform grid sampling inside each patch to generate a new point set;

[0046] Step 5.3, assign the patch color RGB value to the sampling point, ensuring that the new point has the same RGB value as the patch;

[0047] Step 5.4: Merge the sampled point cloud with the point cloud obtained in step 4 to generate higher density point cloud data with consistent color characteristics.

[0048] Step 6: Read the RGB values ​​from the traversal points and add labels by comparing them with the category-RGB value-label mapping table.

[0049] Step 6.1, traverse each point in the point cloud and read its RGB value;

[0050] Step 6.2, match the read RGB value with the category-RGB value-label mapping table constructed in step 1;

[0051] Step 6.3, determine the classification label of each point according to the matching results;

[0052] Step 6.4: Add classification labels to corresponding points to complete automatic annotation of the point cloud.

[0053] This process uses color information to convert the categories of point cloud shapes into semantic labels, achieving fast and automatic labeling; subsequently, a point cloud data table containing coordinates, RGB values ​​and labels can be generated to record and verify the labeling results.

[0054] Because the present invention adopts the above technical means, it has the following beneficial effects:

[0055] Existing point cloud annotations are often directly oriented to point cloud data collected by hardware devices such as RGBD depth cameras or lidars. Although these data have RGB information, due to the influence of factors such as acquisition accuracy and ambient light, these color information is not clear and consistent enough, and it is difficult to directly use them as a basis for classification. This application assigns color information to the CAD model and then converts it directly to RGB point cloud data. Compared with point cloud data that relies on expensive hardware equipment, this method can obtain high-precision RGB point cloud data at a low cost.

[0056] In addition, traditional point cloud annotation mainly focuses on rough annotation at the object level or component level in large-scale scenes, and is not competent for the task of fine annotation of geometric surfaces of point cloud data. The present application also has the ability to quickly annotate point clouds of fine geometric surfaces. By assigning colors to the surface of the CAD model, the geometric surface differences originally limited to the CAD model can be converted into point cloud data, thereby realizing the RGB value-label rapid mapping annotation of point cloud surfaces. This method not only broadens the application scenarios of point cloud annotation technology, but also enhances the application value of point cloud data in the fields of three-dimensional modeling, product quality inspection, industrial design, etc. Therefore, the present invention has certain technical advantages in improving annotation accuracy, reducing costs, and adapting to complex geometric surfaces. BRIEF DESCRIPTION OF THE DRAWINGS

[0057] Figure 1 This is a simplified diagram of the point cloud automatic annotation process;

[0058] Figure 2It is the solid model of the motor assembly after coloring;

[0059] Figure 3 It is the PLY format mesh model of the motor component;

[0060] Figure 4 It is the RGB point cloud of the motor component mapped by the PLY model;

[0061] Figure 5 It is the RGB point cloud of the motor component after grid uniform sampling;

[0062] Figure 6 This is a colored solid model of the lathe top;

[0063] Figure 7 It is the RGB point cloud of the top parts of the lathe;

[0064] Figure 8 Table 1 is a motor component category-RGB value-label mapping table;

[0065] Fig. 9 Table 2 is a table of motor component coordinates, RGB values ​​and labels;

[0066] Fig.10 Table 3 is a lathe top part surface category-RGB value-label mapping table;

[0067] Fig.11 Table 4 shows the coordinates, RGB values ​​and labels of some points in the point cloud of the ejector part. DETAILED DESCRIPTION

[0068] The following is a detailed description of the embodiments of the present invention. Although the present invention will be described and illustrated in conjunction with some specific embodiments, it should be noted that the present invention is not limited to these embodiments. On the contrary, modifications or equivalent substitutions made to the present invention should all be included in the scope of the claims of the present invention.

[0069] In addition, in order to better illustrate the present invention, numerous specific details are given in the following specific embodiments. It will be understood by those skilled in the art that the present invention can also be implemented without these specific details.

[0070] This application proposes a point cloud annotation method based on a three-dimensional CAD model and its RGB value mapping, which can greatly reduce manual workload and achieve true automatic annotation. The main idea is to create a three-dimensional CAD model and add RGB colors to the solid or surface, then use RGB mapping to assign the model face color to the vertex, and use the grid uniform upsampling algorithm to expand the points; discretize the CAD model into a point cloud model and assign the RGB value of the face to the upsampling generated points to obtain an RGB point cloud; finally, compare the RGB value of each point with the preset type-RGB value mapping relationship to obtain the classification of the point and set it as a label.

[0071] The point cloud automatic annotation process proposed in this application is as follows Figure 1 As shown, the method includes the following steps.

[0072] Step 1: Create a category-RGB value-label mapping table based on the categories involved in the specific labeling task label

[0073] For specific point cloud stereo or surface annotation tasks, a category-RGB value-mapping table is constructed. The mapping table is designed to ensure that different stereo or surface point clouds have significant color differences during visualization and annotation, so as to facilitate subsequent deep learning model training.

[0074] Take the category annotation of the point cloud of motor component parts as an example. Different colors correspond to different parts of the motor component. Each part is set with a unique RGB value to represent its color, and each part is assigned a specific label, so that the parts, colors and labels form a unique mapping relationship. The category-RGB value-label mapping table is the correspondence between the classification category, corresponding color and annotation label determined in advance according to the annotation task. Among them, the points with the category of "dividing point" are points that belong to two or more categories at the same time. Their geometric meaning is those points on the boundary line between faces, which exist in most classification tasks, so their labels and colors are fixed to 0 and black (RGB value (0, 0, 0)). Other categories are set by the user according to the actual task, such as Figure 8 Table 1 is the "category-RGB value-label mapping table" of the parts in the motor assembly

[0075] Step 2: CAD solid modeling and assigning standard colors to solid surface geometry

[0076] Computer-Aided Design (CAD) software is used to perform three-dimensional solid modeling on the complex model, and then the "category-RGB value-label mapping table" set in step 1 is used to assign colors to each solid or surface of the solid model. The motor component model after coloring according to Table 1 is as follows Figure 2 shown.

[0077] Step 3: Set the meshing parameters of the solid model and export it to PLY format

[0078] Mainstream 3D CAD software supports meshing of solid models, that is, discretizing the solid surface into polygonal planes, and the most commonly used format is the STL model. However, the STL format only contains the vertex coordinate information of the triangular facets and cannot save color information. Therefore, this application chooses PLY (Polygon File Format) as the output format, which supports facet color attributes and can save and reproduce the color information assigned to the surface of the solid model. Compared with the STL format, it can provide more model surface information for subsequent use.

[0079] PLY is a standard file format for storing 3D data, suitable for saving point cloud and polygon mesh data. It has the advantages of flexibility and scalability, suitable for storing various complex 3D model information, and is supported by many 3D modeling software, computer graphics applications and 3D scanning software, such as MeshLab, CloudCompare and point cloud processing libraries (such as PCL). In terms of structure, PLY files usually contain the following key parts:

[0080] 1) Header: Contains file type identification, file version information, and element list. Elements include vertices, faces, edges, and declares the number and type of attributes contained in each element.

[0081] 2) Attributes: For vertex elements, they include x, y, z coordinates, RGB color values, surface normal vectors or texture coordinates, etc.

[0082] 3) Data Body: Contains the actual numerical data, arranged in the order and format declared in the header.

[0083] When exporting a 3D model to PLY format, the user should adjust the mesh size and roughness parameters according to the geometric complexity of the solid model, the surface smoothness, and the target application scenario to generate triangular or quadrilateral unit meshes with small side lengths. In principle, the finer the mesh division, the higher the accuracy of the subsequent point cloud model and the accuracy of automatic annotation. However, too dense meshing operations will lead to a significant increase in the amount of calculation, so the specific parameter settings should be considered comprehensively in combination with multiple factors.

[0084] Finally, the exported PLY file not only describes the geometric shape of the model, but also carries the color RGB value of each mesh corresponding to its category, which is convenient for the subsequent automatic annotation of the point cloud based on color coding. Figure 3 shown.

[0085] Step 4: Assign the mesh model patch color RGB value to the vertex

[0086] The present application proposes a mesh model vertex color mapping method, which is used to read the face color information from the PLY format file and assign the face color to the vertices that constitute the face. The specific process is: traverse all vertices in the mesh model and their associated shared face sets, and access the color attributes of all faces adjacent to each vertex. When the colors of all faces associated with a vertex are consistent, the RGB color value of the color is assigned to the vertex. When a vertex is associated with two or more colors of faces, the color of the point is assigned to black, that is, the "dividing point".

[0087] Through the above process, it is ensured that even when the vertex is shared by multiple patches of different colors, a distinguishable RGB value can be mapped, avoiding the RGB value conflict caused by directly taking a single patch color. Figure 4 As shown in the figure, the characteristics of the PLY mesh model determine that if the surface of the solid is a regular shape (plane, cylinder, cone, sphere, etc.), the point cloud obtained is a sparse point cloud with a small number of points, and may even have only boundary points.

[0088] Step 5: Uniformly sample expansion points on mesh model patches

[0089] The grid uniform sampling algorithm is an upsampling method for point cloud data, which aims to improve the point density and spatial resolution of the point cloud in a regularized manner. Within each grid cell, one or more new points are created according to the preset sampling interval or target density standard. These new points are often located at the geometric center of the grid cell to ensure a uniformly distributed array of points across the entire 3D model surface and volume. The geometric coordinates, color, and other physical properties of the new points (such as reflection intensity, texture coordinates, etc.) can be calculated by interpolation algorithms or directly inherited from the existing properties of the grid cell.

[0090] This application uses a grid uniform sampling method to expand the number of points in the point cloud while ensuring that the expanded points obtain the correct RGB values. The basic process of the algorithm implementation is as follows:

[0091] First, access each patch in the PLY file exported in step 3 and perform grid uniform sampling to generate a new set of points and assign the patch color to the sampled points. Then, after upsampling each patch, merge the resulting point cloud with the sparse point cloud obtained in step 4. Since both point clouds are extended from the PLY model and have the same coordinate system, they can be directly merged without transformation.

[0092] Through the above operations, high-density point cloud data with consistent color characteristics is generated, which effectively retains and enhances the color information of the original CAD model. This method accurately transfers the color of the patch to the point cloud without using color interpolation technology, so it will not cause the appearance of unclassified points. The point cloud of the motor component after upsampling is as follows Figure 5 shown.

[0093] Step 6: Read the RGB values ​​from the points and add labels by comparing the category-RGB value-label mapping table

[0094] Traverse the obtained RGB point cloud, read the RGB three-channel attribute values ​​of each point, and then match these values ​​with the category-RGB value-label mapping table constructed in step 1 to determine the classification label of the point. The automatic labeling results of some points in the motor component point cloud are as follows: Fig. 9 As shown in Table 2, the first three columns are the coordinate values ​​of the point, the fourth to sixth columns are the RGB values ​​of the point, and the last column is the type label.

[0095] The proposed method can also be used for point cloud surface annotation tasks. The color of the 3D point cloud is used to convert the surface category into a semantic label, thereby realizing fast and automatic annotation of different surfaces in the point cloud (such as cylinders, spheres, cones, tori, planes and other curved surfaces). Figure 6 Take a lathe top part as an example. Fig.10 Table 3 is a top part category-RGB value-label mapping table.

[0096] After step 2, the lathe top entity is as follows Figure 6 As shown; the RGB point cloud generated after steps 4 and 5 is as follows Figure 7 As shown; the labels of some points automatically generated after step 6 are as follows Fig.11 As shown in Table 4.

[0097] In summary, the present invention has the following characteristics:

[0098] 1. Conversion of 3D model surface color to RGB point cloud

[0099] The computer-aided design (CAD) software is used to perform entity modeling and assign colors. The model is exported as a PLY mesh file through mesh processing. The mesh uniform upsampling algorithm is used to expand the number of points to the data set production requirements, and the mesh model patch color RGB values ​​are assigned to the mesh vertices. This step accurately assigns the patch RGB information to the generated points, ensuring that the RGB value of each point is consistent with the mesh patch RGB value, and quickly finds the dividing points between different surfaces, greatly improving the efficiency of point cloud segmentation.

[0100] 2. Construction and application of category-RGB value-label mapping table

[0101] A category-RGB value-label mapping table is pre-established to clearly define the correspondence between categories, RGB values, and type labels. After assigning color information to the point cloud, each point in the RGB point cloud is traversed and the mapping table is queried. Matching is performed based on the RGB value of each point. If the RGB value of the point is the same as the RGB value in the mapping table, the point will be assigned the corresponding label in the mapping table. The aforementioned mapping algorithm from the 3D CAD model to the point cloud ensures that colors that are not in the CAD model and the mapping table will not appear in the point cloud.

[0102] 3. Retrieval and classification of demarcation points

[0103] Points located on the boundary lines between faces and volumes are built into the annotation system as a new category. This simplifies the classification method, avoids the conflicts caused by the multiple attributes of the boundary points in previous point cloud annotation methods, and lays a data foundation for the subsequent processing of this type of special points.

[0104] 4. Automatic labeling of point cloud shapes and surfaces

[0105] A new attribute column for storing label information is added to the point cloud data structure. After completing the mapping from color to label, the system automatically adds the matching label value to the corresponding point, thereby realizing automatic labeling of the point cloud.

Claims

1. A method for rapid annotation of point clouds based on 3D CAD models and their RGB values, characterized in that: The following steps are involved: Step 1: According to the categories involved in the specific labeling task labels, a category-RGB value-label mapping table is established to ensure that different three-dimensional or surface point clouds have significant color differences during the visual labeling process; Step 2: Use computer-aided design (CAD) software to perform three-dimensional solid modeling on the complex model, and assign standard colors to each solid or surface of the solid model according to the category-RGB value-label mapping table established in step 1; Step 3: Set the meshing parameters of the solid model and export it to PLY format to save and reproduce the color information of the surface of the solid model; Step 4: Assign the RGB value of the mesh model face color to the vertex; Step 5: Uniformly sample expansion points on mesh model patches; Step 6: Read the RGB values ​​from the traversal points and add labels by comparing them with the category-RGB value-label mapping table.

2. A method for rapid annotation of point clouds based on a three-dimensional CAD model and its RGB values ​​according to claim 1, characterized in that: Step 1 includes the following steps: Step 1.1, determine the specific category of the labeling task and assign a unique label to each category; Step 1.2, set an RGB value other than black for each category to form a mapping relationship between color and category; Step 1.3: Integrate the categories, RGB values, and labels into a mapping table to ensure consistency and recognizability of the annotations; Step 1.4: Preset a specific category "boundary point", corresponding to those points that belong to two or more categories at the same time, fix its label to 0, and fix its color to black, that is, RGB value (0, 0, 0); Step 1.5: The user adjusts and confirms the category-RGB value-label mapping table according to specific task requirements.

3. The method for rapid annotation of point clouds based on a three-dimensional CAD model and its RGB values ​​according to claim 1, characterized in that: Step 2 includes the following steps: Step 2.1, create a three-dimensional solid model of the model in CAD software; Step 2.2, according to the mapping table in step 1, select the corresponding RGB value for each part of the solid model; Step 2.3: Apply the selected color to the corresponding solid or surface of the solid model.

4. The method for rapid annotation of point clouds based on a three-dimensional CAD model and its RGB values ​​according to claim 1, characterized in that: Step 3 includes: adjusting the mesh size and roughness parameters according to the geometric complexity, surface smoothness and target application scenario of the solid model, exporting the model as a PLY format file, generating a triangular or quadrilateral unit mesh, that is, discretizing the solid surface into polygonal patches. The PLY file format can ensure that each mesh patch carries the color RGB value of its corresponding category.

5. The method for rapid annotation of point clouds based on a three-dimensional CAD model and its RGB values ​​according to claim 1, characterized in that: Step 4 specifically includes: Step 4.1, traverse all vertices in the mesh model and their associated face sets; Step 4.2, access the color attributes of all faces adjacent to each vertex; Step 4.3: When all the faces associated with a vertex have the same color, assign the RGB value of the color to the vertex; Step 4.4: When a vertex is associated with a patch with two or more colors, the vertex color is assigned to black, that is, the RGB value is (0, 0, 0).

6. The method for rapid annotation of point clouds based on a three-dimensional CAD model and its RGB values ​​according to claim 1, characterized in that: Step 5 specifically includes: Step 5.1, access each patch in the PLY file exported in step 3; Step 5.2: Perform uniform grid sampling inside each patch to generate a new point set; Step 5.3, assign the patch color RGB value to the sampling point, ensuring that the new point has the same RGB value as the patch; Step 5.4: Merge the sampled point cloud with the point cloud obtained in step 4 to generate higher density point cloud data with consistent color characteristics.

7. The method for rapid annotation of point clouds based on a three-dimensional CAD model and its RGB values ​​according to claim 1, characterized in that: Step 6 specifically includes: Step 6.1, traverse each point in the point cloud and read its RGB value; Step 6.2, match the read RGB value with the category-RGB value-label mapping table constructed in step 1; Step 6.3, determine the classification label of each point according to the matching results; Step 6.4: Add classification labels to corresponding points to complete automatic annotation of the point cloud.

Citation Information

Cited By

  • Method and system for automatically generating labels based on CAD entity types

    CN120259605A

  • Label point cloud generation method, system and device and medium

    CN121191164A

  • Mold electrode modeling method based on topological point cloud sampling and PointNet + +

    CN122289611A