A micro bearing surface defect visual detection system

CN122335868BActive Publication Date: 2026-08-28NANTONG SK SEIKO CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202610792189.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-06-03
Publication Date
2026-08-28
Estimated Expiration
2046-06-03

AI Technical Summary

Technical Problem

[0004]本发明解决的技术问题是:现有检测在面对微型轴承尺寸小、表面曲率变化复杂、点云数据易受噪声干扰的特性时,仍存在很多技术瓶颈,传统点云滤波与优化方法多采用固定阈值或基于全局统计的策略,难以在保留微小缺陷细节的同时有效去除离群噪声,导致后续重建精度不足,三维重建过程中,点云到网格的转换常因局部点云分布不均而产生孔洞或失真,影响缺陷识别的准确性,此外,现有缺陷检测手段多依赖人工设定特征或简单几何比对,对微小、异形缺陷的量化能力有限,难以满足高精度、自动化的工业质检需求

Benefits of technology

本发明的有益效果:通过方差优先策略构建Kd树以优化邻域搜索效率,并引入改进的深度神经网络对每个点执行噪声点位移处理,损失函数融合空间距离加权引导项与空间距离约束项,解决了现有方法局部几何结构易失真的问题,实现了噪声点的精准校正与细节保持,现有算法因点云分布不均常导致网格孔洞或失真,本方案将神经网络输出的位移量作为空间距离场的近似值,结合体素化有符号距离场计算与移动立方体算法,显著提升了三维重建的保真度,通过关键点精确配准与多维度几何属性量化,克服了传统人工特征比对难以量化微小异形缺陷的局限,实现了缺陷的精准识别与全面表征,大幅提高了检测系统的自动化水平与量化精度。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122335868B_ABST
    Figure CN122335868B_ABST
Patent Text Reader

Abstract

The application discloses a kind of miniature bearing surface defect visual detection systems, it is related to bearing surface defect detection technical field, including processing module, optimization module, reconstruction module, detection module and generation module, obtain the original point cloud data of bearing to be detected, carry out filtering processing, obtain the processing point cloud data of bearing to be detected, based on variance priority strategy Kd tree is constructed, and utilize the improved deep neural network to each point in the processing point cloud data of bearing to be detected Noise point displacement processing is executed, obtain the point cloud data after updating, and carry out iterative optimization, obtain the fine point cloud data of bearing to be detected, carry out three-dimensional reconstruction, obtain the three-dimensional grid model of bearing to be detected, and with the three-dimensional grid model of standard bearing is registered and defect detection, obtain the three-dimensional grid model of bearing to be detected with defect mark and defect quantization data, and carry out visual processing and report generation, obtain visual detection result and defect detection report.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of bearing surface defect detection technology, and in particular to a visual inspection system for micro bearing surface defects. Background Technology

[0002] In recent years, with the widespread application of miniature bearings in precision machinery, aerospace, medical equipment and high-end manufacturing, surface quality has a decisive impact on the operational stability and service life of equipment. Visual inspection of surface defects in miniature bearings has received widespread attention as a key technology to ensure product quality. Detection methods based on three-dimensional point clouds have gradually become a research hotspot because they can provide rich geometric information.

[0003] However, existing inspection methods still face many technical bottlenecks when dealing with the characteristics of miniature bearings, such as small size, complex surface curvature, and point cloud data being susceptible to noise interference. Traditional point cloud filtering and optimization methods often use fixed thresholds or strategies based on global statistics, which are difficult to effectively remove outlier noise while preserving the details of minute defects, resulting in insufficient accuracy in subsequent reconstruction. During the 3D reconstruction process, the conversion from point cloud to mesh often produces holes or distortions due to uneven distribution of local point clouds, affecting the accuracy of defect identification. In addition, existing defect detection methods mostly rely on manually set features or simple geometric comparisons, which have limited quantification capabilities for minute and irregularly shaped defects, making it difficult to meet the needs of high-precision and automated industrial quality inspection. Summary of the Invention

[0004] The technical problem solved by this invention is that existing detection methods still face many technical bottlenecks when dealing with the characteristics of miniature bearings, such as small size, complex surface curvature changes, and point cloud data being easily affected by noise. Traditional point cloud filtering and optimization methods often use fixed thresholds or strategies based on global statistics, which are difficult to effectively remove outlier noise while preserving the details of minute defects, resulting in insufficient accuracy in subsequent reconstruction. During the 3D reconstruction process, the conversion from point cloud to mesh often produces holes or distortions due to uneven distribution of local point clouds, affecting the accuracy of defect identification. In addition, existing defect detection methods mostly rely on manually set features or simple geometric comparisons, which have limited quantification capabilities for minute and irregularly shaped defects, making it difficult to meet the needs of high-precision and automated industrial quality inspection.

[0005] To solve the above-mentioned technical problems, the present invention provides the following technical solution: a visual inspection system for surface defects of miniature bearings includes a processing module, an optimization module, a reconstruction module, a detection module, and a generation module; The processing module acquires the raw point cloud data of the bearing to be tested, performs filtering on the raw point cloud data, and obtains the processed point cloud data of the bearing to be tested. The optimization module constructs a Kd tree based on a variance-first strategy and uses an improved deep neural network to perform noise point displacement processing on each point in the point cloud data of the bearing to be tested, thereby obtaining updated point cloud data. The updated point cloud data is then iteratively optimized to obtain fine point cloud data of the bearing to be tested. The reconstruction module performs three-dimensional reconstruction based on the fine point cloud data of the bearing to be tested, and obtains a three-dimensional mesh model of the bearing to be tested. The detection module registers the 3D mesh model of the bearing to be tested with the 3D mesh model of the standard bearing and performs defect detection to obtain a 3D mesh model of the bearing to be tested with defect markers and defect quantification data. The generation module performs visualization processing and report generation on the 3D model with defect markers and defect quantification data, resulting in visualized detection results and defect detection reports.

[0006] As a preferred embodiment of the visual inspection system for surface defects of miniature bearings described in this invention, acquiring the original point cloud data of the bearing to be inspected specifically includes: Structured light 3D measurement was used to scan the micro-bearing object to be tested on the stage from multiple perspectives to obtain local point cloud data from multiple perspectives. By stitching together the local point cloud data using preset marker points, the original dense point cloud data is obtained. Filtering specifically includes: The random sampling consensus algorithm is used to remove the planar point cloud data used as the stage from the original dense point cloud data, resulting in point cloud data after background removal. A density-based clustering algorithm is used on the point cloud data after background removal. A preset radius is used as the search neighborhood. Point cloud data with more than a preset threshold of points in the neighborhood are grouped into the same cluster, resulting in multiple clusters. The cluster with the most points in the cluster is selected as the point cloud data of the bearing body, and the point cloud data corresponding to the other clusters are removed to obtain the main point cloud data of the bearing to be detected. The statistical filtering of the main point cloud data includes removing point cloud data with an average distance greater than a first preset distance threshold from the main point cloud data to obtain the processed point cloud data of the bearing to be detected.

[0007] As a preferred embodiment of the visual inspection system for surface defects of a miniature bearing described in this invention, a Kd tree is constructed based on a variance-first strategy according to the processed point cloud data of the bearing to be inspected. The variance-first strategy includes selecting the dimension with the largest variance in the processing point cloud data of the bearing to be tested as the segmentation dimension for spatial partitioning; Based on an improved deep neural network, noise point displacement processing is performed on each point in the point cloud data of the bearing to be inspected. Noise point displacement processing specifically includes: Using the current processing point as the center, search for the neighborhood point set of the current processing point in the Kd tree. The search radius is the product of the preset radius scaling factor and the diagonal length of the bounding box of the processing point cloud data of the bearing to be detected. The neighborhood point set and the current processing point are normalized to obtain the normalized current point and the normalized neighborhood point set; The improved deep neural network employs an improved loss function, the expression of which is: ; in, Represents the loss function. This indicates a spatial distance-weighted leading term. This represents the spatial distance constraint term. This indicates the preset weighting coefficients; The calculation process of the spatial distance weighted guiding term includes: fitting the current processing point to the corresponding neighborhood point set after displacement processing to obtain the local surface; calculating the signed distance from the current processing point to the local surface; and weighting and summing the signed distances according to preset weights to obtain the spatial distance weighted guiding term. The calculation process of the spatial distance constraint term includes: calculating the Euclidean distance between the current processing point and each point in the corresponding neighborhood point set; calculating the difference between the Euclidean distance and the preset target uniform spacing to obtain the distance deviation value; and summing the distance deviation values ​​to obtain the spatial distance constraint term. The normalized neighborhood point set is input into an improved deep neural network for processing, and the output is the shifted normalized points, specifically including: The improved deep neural network consists of an encoder and a decoder; The encoder includes a first convolutional layer, a second convolutional layer, and a third convolutional layer connected in sequence; The first convolutional layer has 3 input channels and 32 output channels. The second convolutional layer has 32 input channels and 64 output channels; The third convolutional layer has 64 input channels and 128 output channels; The normalized neighborhood point set is input into the first convolutional layer, and convolution operation, batch normalization processing and nonlinear activation are performed in sequence to obtain the first activation feature map. The first activation feature map is input into the second convolutional layer, and convolution operation, batch normalization and non-linear activation are performed in sequence to obtain the second activation feature map. The second activation feature map is input into the third convolutional layer, and convolution operation, batch normalization and non-linear activation are performed in sequence to obtain the third activation feature map. The third activation feature map is subjected to max pooling to obtain the global feature vector; The decoder consists of a first fully connected layer, a second fully connected layer, and a third fully connected layer connected in sequence; The first fully connected layer has an input dimension of 128 and an output dimension of 64. The second fully connected layer has an input dimension of 64 and an output dimension of 32. The third fully connected layer has an input dimension of 32 and an output dimension of 3. The global feature vector is input into the first fully connected layer, and the fully connected operation and non-linear activation are performed sequentially to output the first feature vector. The first feature vector is input into the second fully connected layer, and the fully connected operation and non-linear activation are performed in sequence to obtain the second feature vector; The second feature vector is input into the third fully connected layer, and after performing the fully connected operation in sequence, the displacement of the current point is obtained. The normalized current point is displaced according to the displacement amount to obtain the normalized point after displacement; The normalized points after displacement are mapped back to the original coordinate space through inverse transformation to obtain updated points, and the updated point cloud data is constructed based on the updated points. Using the updated point cloud data as input, the Kd tree is reconstructed based on the updated point cloud data, and the noise point displacement processing is repeated n times to obtain the fine point cloud data of the bearing to be detected.

[0008] As a preferred embodiment of the visual inspection system for surface defects in miniature bearings described in this invention, the three-dimensional reconstruction specifically includes: The displacement output by the improved deep neural network is used as an approximation of the spatial distance field; The bounding box of the fine point cloud data of the bearing to be tested is divided into voxels. For each voxel vertex, if there is fine point cloud data within the preset range of the voxel vertex, the projection value of the displacement corresponding to the fine point cloud data in the direction of the normal vector of the point is used as the signed distance value of the voxel vertex, and the sign of the signed distance value is determined according to the sign of the dot product between the voxel vertex and the local surface normal vector. Otherwise, calculate the Euclidean distance between the voxel vertex and the nearest point in the fine point cloud data of the bearing to be detected, and determine the sign of the distance based on the sign of the dot product of the normal vectors of the voxel vertex and the nearest point, which is used as the signed distance value of the voxel vertex. By traversing the vertices of all voxels, the spatial distance field is obtained; The moving cube algorithm is used to extract isosurfaces from the spatial distance field; Iterate through each voxel and compare the distance values ​​at each vertex of the voxel with a preset extraction threshold. Specifically, this includes: If the distance value is greater than the preset extraction threshold, it is marked as 1; otherwise, it is marked as 0. An 8-bit binary index is constructed based on the labels of the 8 vertices. The edges that intersect with the isosurface within the voxel and the connection method are determined by looking up the table. Interpolation calculations are performed on the edges that intersect the isosurface to obtain the intersection point position. Triangular patches are generated based on the intersection point position. By piecing together all the triangular facets, a continuous three-dimensional mesh model of the bearing to be tested is obtained.

[0009] As a preferred embodiment of the visual inspection system for surface defects of miniature bearings described in this invention, the registration and defect detection specifically include: The ISS algorithm is used to calculate the eigenvalues ​​of the local neighborhood covariance matrix of each point in the three-dimensional mesh model of the bearing to be inspected, resulting in three eigenvalues. These three eigenvalues ​​are arranged in descending order of size and are denoted as the first eigenvalue, the second eigenvalue, and the third eigenvalue. The ISS algorithm is used to calculate the eigenvalues ​​of the local neighborhood covariance matrix of each point for the three-dimensional mesh model of the standard bearing. Three eigenvalues ​​are obtained and arranged in descending order of size, and are denoted as the fourth eigenvalue, the fifth eigenvalue, and the sixth eigenvalue. Select points from all points in the 3D mesh model of the bearing to be tested that simultaneously satisfy the first point selection condition to obtain the key point set of the bearing to be tested; The first selection condition includes that the ratio of the first feature value to the second feature value is greater than a first preset threshold, and the ratio of the second feature value to the third feature value is greater than a second preset threshold. From all points in the 3D mesh model of the standard bearing, select points that simultaneously satisfy the second point selection condition to obtain the key point set of the standard bearing; The second selection criteria include that the ratio of the fourth feature value to the fifth feature value is greater than the third preset threshold, and the ratio of the fifth feature value to the sixth feature value is greater than the fourth preset threshold. Based on the key point set of the bearing to be tested and the key point set of the standard bearing, generate the feature vector corresponding to the fast point feature histogram descriptor for each key point, and obtain the feature vector of the key point of the bearing to be tested and the feature vector of the key point of the standard bearing. Calculate the Euclidean distance between the feature vectors of the key points of the bearing to be detected and the feature vectors of the key points of the standard bearing. Take the key points corresponding to the feature vector pairs with the smallest Euclidean distance as matching point pairs, and construct a set of matching point pairs based on the matching point pairs.

[0010] As a preferred embodiment of the visual inspection system for surface defects of micro bearings described in this invention, the following is described: based on a set of matching point pairs, a random sampling consensus algorithm is used to repeatedly perform sampling evaluation processing until the iteration termination condition is met or the preset number of iterations is reached, and the initial alignment posture is output. The sampling and evaluation process specifically includes: Randomly select at least 3 non-collinear point pairs from the set of matching point pairs, and calculate the candidate rigid body transformation matrix based on the spatial coordinates of the key point of the bearing to be detected and the spatial coordinates of the key point of the standard bearing in the point pair. The candidate rigid body transformation matrix is ​​used to transform the matching point pairs of the bearing key points to be detected, and the transformed bearing key points to be detected are obtained. Calculate the Euclidean distance between the key points of the bearing to be detected after transformation and the corresponding key points of the standard bearing, and calculate the number of matching point pairs whose Euclidean distance is less than the second preset distance threshold as the number of interior points. After each iteration, if the current number of inliers is greater than the maximum number of inliers, then update the maximum number of inliers and save the rigid body transformation matrix of the current candidate. The iteration termination condition includes the current number of interior points being greater than a preset threshold for the number of interior points. After the iteration is complete, the saved rigid body transformation matrix is ​​used as the initial alignment pose.

[0011] As a preferred embodiment of the visual inspection system for surface defects of a micro bearing described in this invention, the following steps are taken: based on the initial alignment posture, the iterative nearest point algorithm is used to iteratively optimize the rotation matrix and translation matrix corresponding to the initial alignment posture until the change in the rotation matrix is ​​less than a preset rotation threshold and the change in the translation matrix is ​​less than a preset translation threshold, thereby obtaining the registered three-dimensional mesh model of the bearing to be inspected. Calculate the Euclidean distance from each vertex of the registered 3D mesh model of the bearing to be inspected to the nearest vertex of the standard 3D mesh model. Mark vertices with Euclidean distances greater than a preset defect threshold as defect points. The area formed by all marked defect points and connected triangular facets is taken as the defect region, thus obtaining a 3D mesh model of the bearing to be inspected with defect markings.

[0012] As a preferred embodiment of the visual inspection system for surface defects of miniature bearings described in this invention, the method involves calculating geometric attribute indices of the defect area to obtain quantitative defect data, specifically including: Calculate the Euclidean distance from all points within the defect area to the nearest vertex of the standard bearing 3D mesh model, take the maximum value of the Euclidean distance as the maximum depth, and calculate the average value of the Euclidean distance as the average depth. The area of ​​all triangular facets within the defective region is summed to obtain the surface area. The defect region is discretized into right prisms with triangular facets as the base and extending along the normal direction, and the volume is accumulated to form the defect volume; The principal axis direction of the defect region is calculated by principal component analysis, and the minimum circumscribed cuboid is constructed to obtain the length, width, and height. The angle between the normal vectors of adjacent facets at the edge of the defect region is calculated as the difference in the direction of the normal vectors; Maximum depth, average depth, surface area, defect volume, length, width, height, and difference in normal vector direction are used as defect quantification data.

[0013] As a preferred embodiment of the visual inspection system for surface defects of miniature bearings described in this invention, the visualization processing specifically includes: The 3D model with defect markings is rendered, the 3D mesh model of the standard bearing is displayed in the first preset color, the defect area is highlighted in the second preset color, and the results are displayed through the 3D rendering window to obtain a visualized inspection result.

[0014] As a preferred embodiment of the visual inspection system for surface defects in miniature bearings described in this invention, wherein: The beneficial effects of this invention are as follows: A Kd-tree is constructed using a variance-first strategy to optimize neighborhood search efficiency. An improved deep neural network is introduced to perform noise point displacement processing on each point. The loss function integrates a spatial distance weighted guiding term and a spatial distance constraint term, solving the problem of easy distortion of local geometric structures in existing methods. This achieves accurate correction of noise points and preservation of details. Existing algorithms often result in mesh holes or distortion due to uneven point cloud distribution. This scheme uses the displacement output by the neural network as an approximation of the spatial distance field. Combined with voxelized signed distance field calculation and the moving cube algorithm, it significantly improves the fidelity of 3D reconstruction. Through precise registration of key points and quantization of multi-dimensional geometric attributes, it overcomes the limitation of traditional manual feature comparison in quantifying small irregular defects, achieving accurate identification and comprehensive characterization of defects, and greatly improving the automation level and quantification accuracy of the detection system. Attached Figure Description

[0015] Figure 1 This is a basic flowchart of a visual inspection system for surface defects in miniature bearings, provided as an embodiment of the present invention. Detailed Implementation

[0016] To make the above-mentioned objects, features and advantages of the present invention more apparent and understandable, the specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments.

[0017] Example, refer to Figure 1As an embodiment of the present invention, a visual inspection system for surface defects of micro bearings is provided, including a processing module, an optimization module, a reconstruction module, a detection module and a generation module; The processing module acquires the raw point cloud data of the bearing to be tested, performs filtering on the raw point cloud data, and obtains the processed point cloud data of the bearing to be tested. The optimization module constructs a Kd tree based on a variance-first strategy and uses an improved deep neural network to perform noise point displacement processing on each point in the point cloud data of the bearing to be tested, thereby obtaining updated point cloud data. The updated point cloud data is then iteratively optimized to obtain fine point cloud data of the bearing to be tested. The reconstruction module performs three-dimensional reconstruction based on the fine point cloud data of the bearing to be tested, and obtains a three-dimensional mesh model of the bearing to be tested. The detection module registers the 3D mesh model of the bearing to be tested with the 3D mesh model of the standard bearing and performs defect detection to obtain a 3D mesh model of the bearing to be tested with defect markers and defect quantification data. The generation module performs visualization processing and report generation on the 3D model with defect markers and defect quantification data, resulting in visualized detection results and defect detection reports.

[0018] In one embodiment, to accurately obtain the surface geometry information of the miniature bearing, the processing module first acquires the original point cloud data of the bearing to be tested and filters it to obtain the processed point cloud data of the bearing to be tested. This effectively removes background and outlier noise, laying a data foundation for subsequent high-precision processing. Addressing the difficulty of traditional filtering methods in simultaneously removing noise and preserving minute defects, the optimization module constructs a Kd-tree based on a variance-first strategy to improve neighborhood search efficiency. It then utilizes an improved deep neural network to perform noise point displacement processing on each point in the processed point cloud data of the bearing to be tested. Through iterative optimization, it obtains the refined point cloud data of the bearing to be tested, achieving accurate correction of noise points and effective preservation of local details. To convert the discrete point cloud data into a format suitable for geometric analysis... For continuous surfaces, the reconstruction module performs 3D reconstruction based on the fine point cloud data of the bearing under test, obtaining a 3D mesh model of the bearing under test, providing a high-fidelity geometric carrier for defect detection. To achieve automatic defect identification and quantification, the detection module registers the 3D mesh model of the bearing under test with the 3D mesh model of a standard bearing and performs defect detection, obtaining a 3D mesh model of the bearing under test with defect markers and defect quantification data, overcoming the limitation of traditional methods in quantifying small irregular defects. Finally, the generation module performs visualization processing and report generation on the 3D model with defect markers and defect quantification data, obtaining visualized detection results and defect detection reports. A complete visual inspection process for surface defects of micro bearings has been constructed, significantly improving the automation level and quantification accuracy of the inspection.

[0019] Obtain the raw point cloud data of the bearing to be inspected, specifically including: Structured light 3D measurement was used to scan the micro-bearing object to be tested on the stage from multiple perspectives to obtain local point cloud data from multiple perspectives. By stitching together the local point cloud data using preset marker points, the original dense point cloud data is obtained. The filtering process specifically includes: The random sampling consensus algorithm is used to remove the planar point cloud data used as the stage from the original dense point cloud data, resulting in point cloud data after background removal. A density-based clustering algorithm is used on the point cloud data after background removal. A preset radius is used as the search neighborhood. Point cloud data with more than a preset threshold of points in the neighborhood are grouped into the same cluster, resulting in multiple clusters. The cluster with the most points in the cluster is selected as the point cloud data of the bearing body, and the point cloud data corresponding to the other clusters are removed to obtain the main point cloud data of the bearing to be detected. The statistical filtering of the main point cloud data includes removing point cloud data with an average distance greater than a first preset distance threshold from the main point cloud data to obtain the processed point cloud data of the bearing to be detected.

[0020] In one embodiment, to ensure that visual inspection of surface defects in miniature bearings can acquire complete and high-quality original point cloud data, the processing module specifically acquires the original point cloud data of the bearing to be inspected by using structured light 3D measurement technology to scan the actual miniature bearing to be inspected placed on the stage from four perspectives. An overlap of approximately 45° is maintained between adjacent perspectives to ensure the integrity of the point cloud, thereby obtaining local point cloud data from the four perspectives. Subsequently, the local point cloud data is stitched together using preset marker points. Specifically, no less than three non-collinear marker points are pasted on the stage and the bearing surface. The spatial coordinates of each marker point are extracted from the local point cloud data from different perspectives, and the correspondence between the marker points is established. The rigid body transformation matrix between each perspective is calculated using the singular value decomposition method based on the spatial correspondence of the marker points, and the local point clouds are unified to the same coordinate system to obtain the original dense point cloud data. This step, through multi-view scanning and stitching, obtains the geometric information of the complete bearing surface from the physical level, laying the data foundation for subsequent accurate filtering and reconstruction, and avoiding the data loss problem caused by single-view scanning. To accurately separate the bearing body from the original dense point cloud and remove noise and background interference, the filtering process includes: applying a random sampling consensus algorithm to the original dense point cloud data, setting a planar model as the fitting target, and classifying point clouds less than 0.5 mm away from the planar model as stage planar point clouds and removing them, resulting in point cloud data after background removal. The 0.5 mm distance effectively removes stage planar point clouds while avoiding accidental deletion of bearing body point clouds that are too close, achieving accurate separation of background and subject. This step quickly removes the stage, the main background interference, from a macroscopic level, reducing the amount of data for subsequent processing and improving the accuracy of body extraction. A density-based clustering algorithm is then applied to the background-removed point cloud data, setting the search radius (preset radius) to 0.3 mm. The 0.3 mm radius is based on 1.5 times the average spacing of the point clouds.A 3mm neighborhood range ensures that the effective connections between adjacent points in the bearing body point cloud are covered, while also excluding discrete, small noise points from the main cluster, achieving reliable separation of the bearing body from background noise. A preset threshold of 30 points within the neighborhood is set to ensure that dense areas of the main point cloud are completely clustered into a single cluster, while discrete, small noise points cannot form effective clusters due to insufficient neighborhood points, achieving precise separation of the bearing body from noise. The preset threshold of 30 points ensures that the main point cloud is completely clustered into a single cluster within the search radius due to sufficient points. To ensure accurate separation of the bearing body from noise, the method addresses the issue of insufficient discrete noise points preventing clustering. By iterating through the clustering results, several clusters are formed. The combination of a preset radius and a preset point count threshold effectively distinguishes between dense bearing body point clouds and discrete, small noise points, ensuring that the bearing body is completely clustered into one cluster while noise points form several smaller clusters, thus accurately segmenting the bearing body. The cluster with the most points is selected as the bearing body point cloud data, and the point cloud data corresponding to the other clusters are discarded, resulting in the main point cloud data of the bearing to be detected. This step ensures that all subsequent processing focuses on the bearing itself, avoiding interference with noise. Points were mistakenly included in subsequent optimization and reconstruction processes. Statistical filtering of the main point cloud data includes calculating the average distance between each point and its preset number of nearest neighbors (30), obtaining the mean and standard deviation of the global distance. Setting the preset number to 30 nearest neighbors ensures sufficient sample size to smooth local fluctuations when calculating the average distance, while avoiding excessive smoothing of details due to an overly large neighborhood. This accurately represents the local point cloud density characteristics and provides a reliable statistical benchmark for outlier identification. Point cloud data with an average distance greater than a first preset distance threshold are considered outliers and removed, resulting in the processed bearing to be detected. Point cloud data, where the first preset distance threshold is set as the sum of the global mean and twice the standard deviation, effectively removes sparse outlier noise while preserving the local geometric details of the main point cloud. This step further eliminates sparse outlier noise deviating from the bearing body surface, preserving minute defect features while improving the cohesion and quality of the point cloud data, providing clean and reliable data input for subsequent noise point displacement processing based on deep neural networks. This module, through the organic combination of multi-view stitching and multi-level filtering, achieves a complete transformation from raw scan data to high-quality processed point clouds, ensuring the integrity and accuracy of the input data.

[0021] Based on the variance-first strategy, a Kd-tree is constructed using the variance-first strategy based on the processed point cloud data of the bearing to be detected; The variance-first strategy includes selecting the dimension with the largest variance in the processing point cloud data of the bearing to be tested as the segmentation dimension for spatial partitioning; Based on an improved deep neural network, noise point displacement processing is performed on each point in the point cloud data of the bearing to be inspected. Noise point displacement processing specifically includes: Using the current processing point as the center, search for the neighborhood point set of the current processing point in the Kd tree. The search radius is the product of the preset radius scaling factor and the diagonal length of the bounding box of the processing point cloud data of the bearing to be detected. The neighborhood point set and the current processing point are normalized to obtain the normalized current point and the normalized neighborhood point set; The improved deep neural network uses an improved loss function, which is expressed as follows: ; in, Represents the loss function. This indicates a spatial distance-weighted leading term. This represents the spatial distance constraint term. This indicates the preset weighting coefficients; The calculation process of the spatial distance weighted guiding term includes: fitting the current processing point to the corresponding neighborhood point set after displacement processing to obtain the local surface; calculating the signed distance from the current processing point to the local surface; and weighting and summing the signed distances according to preset weights to obtain the spatial distance weighted guiding term. The calculation process of the spatial distance constraint term includes: calculating the Euclidean distance between the current processing point and each point in the corresponding neighborhood point set; calculating the difference between the Euclidean distance and the preset target uniform spacing to obtain the distance deviation value; and summing the distance deviation values ​​to obtain the spatial distance constraint term. The normalized neighborhood point set is input into an improved deep neural network for processing, and the output is the shifted normalized points, specifically including: The improved deep neural network consists of an encoder and a decoder; The encoder includes a first convolutional layer, a second convolutional layer, and a third convolutional layer connected in sequence; The first convolutional layer has 3 input channels and 32 output channels. The second convolutional layer has 32 input channels and 64 output channels; The third convolutional layer has 64 input channels and 128 output channels; The normalized neighborhood point set is input into the first convolutional layer, and convolution operation, batch normalization processing and nonlinear activation are performed in sequence to obtain the first activation feature map. The first activation feature map is input into the second convolutional layer, and convolution operation, batch normalization and non-linear activation are performed in sequence to obtain the second activation feature map. The second activation feature map is input into the third convolutional layer, and convolution operation, batch normalization and non-linear activation are performed in sequence to obtain the third activation feature map. The third activation feature map is subjected to max pooling to obtain the global feature vector; The decoder consists of a first fully connected layer, a second fully connected layer, and a third fully connected layer connected in sequence; The first fully connected layer has an input dimension of 128 and an output dimension of 64. The second fully connected layer has an input dimension of 64 and an output dimension of 32. The third fully connected layer has an input dimension of 32 and an output dimension of 3. The global feature vector is input into the first fully connected layer, and the fully connected operation and non-linear activation are performed sequentially to output the first feature vector. The first feature vector is input into the second fully connected layer, and the fully connected operation and non-linear activation are performed in sequence to obtain the second feature vector; The second feature vector is input into the third fully connected layer, and after performing the fully connected operation in sequence, the displacement of the current point is obtained. The normalized current point is displaced according to the displacement amount to obtain the normalized point after displacement; The normalized points after displacement are mapped back to the original coordinate space through inverse transformation to obtain updated points, and the updated point cloud data is constructed based on the updated points. The updated point cloud data is used as input, and the Kd tree is reconstructed based on the updated point cloud data. The noise point displacement processing is repeated n times to obtain the fine point cloud data of the bearing to be detected.

[0022] In one embodiment, to ensure that the optimization module can accurately correct noise points in the point cloud and effectively preserve the minute defect features of the micro-bearing surface, the optimization module specifically includes constructing a Kd-tree based on a variance-first strategy and performing noise point displacement processing using an improved deep neural network: Based on a variance-first strategy, a Kd-tree is constructed according to the processed point cloud data of the bearing to be detected. Specifically, the dimension with the largest variance in the current processed point cloud data of the bearing to be detected is selected as the segmentation dimension for spatial partitioning. This step, by prioritizing the segmentation of dimensions with large variance, makes the point cloud more evenly divided in directions with significant spatial distribution differences, improving the efficiency and accuracy of subsequent neighborhood search; each of the processed point cloud data of the bearing to be detected... The noise point displacement processing is performed by using the current processing point as the center and searching for the neighborhood point set of the current processing point in the constructed Kd-tree. The search radius is set to the product of a preset radius scaling factor of 0.05 and the diagonal length of the bounding box of the processing point cloud data of the bearing to be detected. This radius scaling factor of 0.05 is set according to the ratio of the typical scale of the surface defects of the micro-bearing to the average spacing of the point cloud, ensuring that the neighborhood range includes sufficient geometric information without excessively introducing far-end noise. Then, the neighborhood point set and the current processing point are normalized, that is, by subtracting the center coordinates of the bounding box and dividing by the diagonal length of the bounding box, the coordinate range is mapped to the interval [-0.5, 0.5], resulting in the normalized current point and the normalized point. The normalized neighborhood point set is then processed to eliminate the impact of point cloud scale differences on the improved deep neural network's inference, enabling the improved deep neural network to adapt to bearings of different sizes. The normalized neighborhood point set is then input into the improved deep neural network for processing. This improved deep neural network consists of an encoder and a decoder. The encoder includes three sequentially connected convolutional layers: a first, a second, and a third. Each convolutional layer undergoes batch normalization and ReLU activation for non-linearity. Local geometric features are extracted progressively through these three convolutional layers, followed by max pooling to obtain the global feature vector. The decoder includes three sequentially connected fully connected layers: a first, a second, and a third. The fully connected layers are connected using an R-multiplexing algorithm. The eLU function performs non-linear activation, ultimately outputting a 3-dimensional displacement of the current point. This improved deep neural network structure learns the local geometric patterns of the neighborhood point set to generate a reasonable spatial displacement for each point, achieving adaptive correction of noise points. Based on this displacement, the normalized current point is displaced to obtain a normalized point, which is then mapped back to the original coordinate space via an inverse transformation. This is achieved by multiplying by the diagonal length of the bounding box and adding the center coordinates of the bounding box, resulting in an updated point. This step effectively transforms the displacement output by the improved deep neural network back to the original coordinate space, ensuring the consistency of the point cloud's geometric position. The improved deep neural network uses a loss function with preset weight coefficients of 0.7. This value balances the spatial distance weighted guiding term and the spatial distance constraint term. The calculation process of the spatial distance weighted guiding term includes calculating the signed distance from the current processing point to the local surface fitted to the corresponding neighborhood point set after displacement processing, and then weighting and summing the distances between each point in the neighborhood and the current point using the inverse of the distances between the current point and the neighborhood point as preset weights. This step guides the displacement points to approach the local geometric surface, maintaining the fit between the point cloud and the potential real surface. The calculation process of the spatial distance constraint term includes calculating the Euclidean distance between the current processing point and each point in the corresponding neighborhood point set, then calculating the difference between this Euclidean distance and the preset target uniform spacing to obtain the distance deviation value, and summing them. The target uniform spacing is set to 1.0 times the average spacing of the original point cloud. This setting ensures that the point cloud after displacement processing maintains a distribution density consistent with the original scan data within a local range, thus avoiding excessive point cloud aggregation that could cause geometric problems. To prevent distortion and excessive sparsity of the point cloud leading to surface information loss, this step maintains the overall uniformity and structural stability of the point cloud while preserving details of minute defects. The constraint point cloud in this step maintains a uniform distribution within a local area, avoiding excessive aggregation or sparsity after displacement processing, thus preserving geometric features while maintaining overall point cloud uniformity. Using the updated point cloud data as input, a Kd-tree is reconstructed based on the updated point cloud data. The noise point displacement processing is repeated n times (n = 3) to finally obtain the fine point cloud data of the bearing to be inspected. The overall design of the above optimization module, through variance-first Kd-tree accelerated neighborhood search, neural network-driven adaptive displacement correction, and the fusion of geometric fit and uniform distribution dual loss constraints, achieves accurate correction of noise points in the processed point cloud and effective preservation of local details, providing high-quality data input for subsequent high-fidelity 3D reconstruction. The variance-first strategy for constructing the Kd-tree significantly improves neighborhood search efficiency, laying a solid foundation for efficient data access in subsequent neural network processing. An improved deep neural network is used to perform adaptive noise displacement correction on each point, combined with a loss function that integrates geometric fit and uniform distribution constraints, achieving accurate removal of noise points and reliable preservation of local details. Through multiple iterative optimizations, the point cloud quality is further converged, ultimately obtaining fine point cloud data that retains the characteristics of minute defects on the surface of the micro-bearing while possessing uniform distribution. This effectively resolves the contradiction between noise removal and detail preservation in traditional filtering methods, significantly improving the geometric accuracy and structural integrity of the point cloud data, and providing high-quality data input for subsequent high-fidelity 3D reconstruction and accurate defect detection.

[0023] 3D reconstruction specifically includes: The displacement output by the improved deep neural network is used as an approximation of the spatial distance field; The bounding box of the fine point cloud data of the bearing to be tested is divided into voxels. For each voxel vertex, if there is fine point cloud data within the preset range of the voxel vertex, the projection value of the displacement corresponding to the fine point cloud data in the direction of the normal vector of the point is used as the signed distance value of the voxel vertex, and the sign of the signed distance value is determined according to the sign of the dot product between the voxel vertex and the local surface normal vector. Otherwise, calculate the Euclidean distance between the voxel vertex and the nearest point in the fine point cloud data of the bearing to be detected, and determine the sign of the distance based on the sign of the dot product of the normal vectors of the voxel vertex and the nearest point, which is used as the signed distance value of the voxel vertex. By traversing the vertices of all voxels, the spatial distance field is obtained; The moving cube algorithm is used to extract isosurfaces from the spatial distance field; Iterate through each voxel and compare the distance values ​​at each vertex of the voxel with a preset extraction threshold. Specifically, this includes: If the distance value is greater than the preset extraction threshold, it is marked as 1; otherwise, it is marked as 0. An 8-bit binary index is constructed based on the labels of the 8 vertices. The edges that intersect with the isosurface within the voxel and the connection method are determined by looking up the table. Interpolation calculations are performed on the edges that intersect the isosurface to obtain the intersection point position. Triangular patches are generated based on the intersection point position. By piecing together all the triangular facets, a continuous three-dimensional mesh model of the bearing to be tested is obtained.

[0024] In one embodiment, to ensure that the reconstruction module can accurately convert fine point cloud data into a high-fidelity 3D mesh model and provide a reliable geometric carrier for subsequent defect detection, the 3D reconstruction specifically includes: using the displacement output by the improved deep neural network as an approximation of the spatial distance field. This step utilizes the local geometric information learned by the neural network during noise point displacement processing and reuses this local geometric information in the reconstruction stage, enabling the spatial distance field to more accurately reflect the real surface position, achieving information integration between the optimization and reconstruction stages, and avoiding error accumulation caused by repeated calculations; dividing the bounding box of the fine point cloud data of the bearing to be detected into a voxel mesh according to a preset voxel size. The voxel size is set to 2.0 times the average spacing of the fine point cloud data. This setting is based on ensuring that the voxel mesh can completely cover the point cloud distribution range while taking into account computational efficiency. For each voxel vertex, the preset range of the voxel vertex, i.e., a radius of 1.5 times the voxel size, is first determined. If fine point cloud data exists within a spherical neighborhood of the voxel size, and if so, the projection of the displacement corresponding to the fine point cloud data within that neighborhood onto the normal vector of that point is used as the signed distance value of that voxel vertex. The sign of the signed distance value is determined based on the sign of the dot product between the voxel vertex and the local surface normal vector. A positive sign indicates that the voxel vertex is outside the surface of the bearing to be detected, while a negative sign indicates that the voxel vertex is inside the surface of the bearing to be detected. This sign determination provides clear inside-outside direction information for the subsequent moving cube algorithm, thereby accurately extracting the zero isosurface as the reconstructed surface. The normal vector of the point is calculated by fitting a plane within the local neighborhood using principal component analysis. The local surface normal vector is taken as the weighted average of the normal vectors of each point in the neighborhood. This step converts the displacement output by the improved deep neural network into the signed distance value of the voxel vertex, enabling the distance field to accurately reflect the surface geometry in dense point cloud regions, thus improving reconstruction accuracy. The preset range is set to 1.A voxel size of 5 times ensures that the voxel vertex fully captures surrounding point cloud data to obtain accurate signed distance values, while avoiding excessively large neighborhoods that introduce distant point clouds and cause distance field estimation distortion. This achieves a smooth transition between projection assignment in dense point cloud regions and nearest-point estimation in sparse regions. If no fine point cloud data exists within a preset range of the voxel vertex, the Euclidean distance between the voxel vertex and the nearest point in the fine point cloud data of the bearing to be inspected is calculated. The sign of the distance is determined by the sign of the dot product of the normal vectors at the voxel vertex and the nearest point. The meaning of the sign is consistent with the previous description: a positive sign indicates that the voxel vertex is outside the surface, and a negative sign indicates that the voxel vertex is inside the surface. This value is used as the signed distance value of the voxel vertex. This step utilizes... The nearest point distance is used to reasonably estimate the surface distance of sparse regions in the point cloud, ensuring complete coverage of the spatial distance field and avoiding holes in the reconstructed surface. The vertices of all voxels are traversed to obtain the complete spatial distance field. This step converts the discrete point cloud geometry into a continuous distance field representation on a regular voxel mesh, providing standardized input data for the moving cubes algorithm. The moving cubes algorithm is then used to extract isosurfaces from the spatial distance field. Specifically, each voxel is traversed, and the distance value at each vertex of the voxel is compared with a preset extraction threshold of 0. Setting the preset extraction threshold to 0 means extracting the zero isosurface from the signed distance field as the reconstructed surface. This accurately separates external regions with distance values ​​greater than 0 from internal regions with distance values ​​less than 0, ensuring the extraction... The isosurface precisely corresponds to the actual geometric boundary of the bearing under test, achieving high-precision reconstruction of the 3D mesh model. If the distance value is greater than 0, it is marked as 1 indicating that it is outside the surface; otherwise, it is marked as 0 indicating that it is inside the surface. An 8-bit binary index is constructed based on the markings of the 8 vertices. The edges intersecting with the isosurface within the voxel and their connection methods are determined by looking up a table. The table lookup is based on a predefined table of 256 cases of the standard moving cube algorithm. The intersection point position is calculated by linear interpolation on the edges where the isosurfaces intersect. Triangular facets are generated based on the intersection point positions. This step uses a standardized isosurface extraction algorithm to convert the voxel distance field into a continuous triangular mesh surface, achieving the generation of a closed and continuous 3D mesh model. All triangular facets are then stitched together to obtain a continuous... The overall design of the reconstruction module for the 3D mesh model of the bearing under inspection achieves accurate conversion from the optimized point cloud to a high-fidelity 3D mesh model by using the displacement of an improved deep neural network as an approximation of the spatial distance field, combined with voxelized signed distance field calculation and the moving cube algorithm. This effectively avoids the surface holes or geometric distortion problems caused by uneven point cloud distribution in traditional methods, providing a high-precision geometric model foundation for subsequent defect detection. This step utilizes the displacement of the improved deep neural network to optimize the accuracy of the distance field calculation. By combining the signed distance field and the moving cube algorithm, a continuous, closed, and high-fidelity 3D mesh model is generated, significantly improving the geometric representation capability of minute defects on the surface of the micro-bearing.

[0025] Registration and defect detection specifically include: The ISS algorithm is used to calculate the eigenvalues ​​of the local neighborhood covariance matrix of each point in the three-dimensional mesh model of the bearing to be inspected, resulting in three eigenvalues. These three eigenvalues ​​are arranged in descending order of size and are denoted as the first eigenvalue, the second eigenvalue, and the third eigenvalue. The ISS algorithm is used to calculate the eigenvalues ​​of the local neighborhood covariance matrix of each point for the three-dimensional mesh model of the standard bearing. Three eigenvalues ​​are obtained and arranged in descending order of size, and are denoted as the fourth eigenvalue, the fifth eigenvalue, and the sixth eigenvalue. Select points from all points in the 3D mesh model of the bearing to be tested that simultaneously satisfy the first point selection condition to obtain the key point set of the bearing to be tested; The first selection condition includes that the ratio of the first feature value to the second feature value is greater than a first preset threshold, and the ratio of the second feature value to the third feature value is greater than a second preset threshold. From all points in the 3D mesh model of the standard bearing, select points that simultaneously satisfy the second point selection condition to obtain the key point set of the standard bearing; The second selection criteria include that the ratio of the fourth feature value to the fifth feature value is greater than the third preset threshold, and the ratio of the fifth feature value to the sixth feature value is greater than the fourth preset threshold. Based on the key point set of the bearing to be tested and the key point set of the standard bearing, generate the feature vector corresponding to the fast point feature histogram descriptor for each key point, and obtain the feature vector of the key point of the bearing to be tested and the feature vector of the key point of the standard bearing. Calculate the Euclidean distance between the feature vectors of the key points of the bearing to be detected and the feature vectors of the key points of the standard bearing. Take the key points corresponding to the feature vector pairs with the smallest Euclidean distance as matching point pairs, and construct a set of matching point pairs based on the matching point pairs.

[0026] Based on the matching point pair set, the random sampling consensus algorithm is used to repeatedly perform the sampling evaluation process until the iteration termination condition is met or the preset number of iterations is reached, and the initial alignment posture is output. The sampling and evaluation process specifically includes: Randomly select at least 3 non-collinear point pairs from the set of matching point pairs, and calculate the candidate rigid body transformation matrix based on the spatial coordinates of the key point of the bearing to be detected and the spatial coordinates of the key point of the standard bearing in the point pair. The candidate rigid body transformation matrix is ​​used to transform the matching point pairs of the bearing key points to be detected, and the transformed bearing key points to be detected are obtained. Calculate the Euclidean distance between the key points of the bearing to be detected after transformation and the corresponding key points of the standard bearing, and calculate the number of matching point pairs whose Euclidean distance is less than the second preset distance threshold as the number of interior points. After each iteration, if the current number of inliers is greater than the maximum number of inliers, then update the maximum number of inliers and save the rigid body transformation matrix of the current candidate. The iteration termination condition includes the current number of inliers being greater than a preset threshold for the number of inliers; After the iteration is complete, the saved rigid body transformation matrix is ​​used as the initial alignment pose.

[0027] Based on the initial alignment posture, the iterative nearest point algorithm is used to iteratively optimize the rotation matrix and translation matrix corresponding to the initial alignment posture until the change in the rotation matrix is ​​less than the preset rotation threshold and the change in the translation matrix is ​​less than the preset translation threshold, thus obtaining the registered three-dimensional mesh model of the bearing to be detected. Calculate the Euclidean distance from each vertex of the registered 3D mesh model of the bearing to be inspected to the nearest vertex of the standard 3D mesh model. Mark vertices with Euclidean distances greater than a preset defect threshold as defect points. The area formed by all marked defect points and connected triangular facets is taken as the defect region, thus obtaining a 3D mesh model of the bearing to be inspected with defect markings.

[0028] Geometric attribute indices are calculated for the defective area to obtain quantitative defect data, specifically including: Calculate the Euclidean distance from all points within the defect area to the nearest vertex of the standard bearing 3D mesh model, take the maximum value of the Euclidean distance as the maximum depth, and calculate the average value of the Euclidean distance as the average depth. The area of ​​all triangular facets within the defective region is summed to obtain the surface area. The defect region is discretized into right prisms with triangular facets as the base and extending along the normal direction, and the volume is accumulated to form the defect volume; The principal axis direction of the defect region is calculated by principal component analysis, and the minimum circumscribed cuboid is constructed to obtain the length, width, and height. The angle between the normal vectors of adjacent facets at the edge of the defect region is calculated as the difference in the direction of the normal vectors; Maximum depth, average depth, surface area, defect volume, length, width, height, and difference in normal vector direction are used as defect quantification data.

[0029] In one embodiment, to ensure that the detection module can achieve high-precision registration between the 3D mesh model of the bearing to be detected and the standard model, and to perform multi-dimensional quantitative analysis of the defect area, the registration and defect detection specifically include: extracting key points from the 3D mesh model of the bearing to be detected using the ISS algorithm; specifically calculating the eigenvalues ​​of the local neighborhood covariance matrix of each point; wherein the search radius of the local neighborhood is set to 5.0 times the average spacing of the point cloud, this setting is based on ensuring that the neighborhood range includes sufficient geometric information to accurately represent surface changes; obtaining three eigenvalues, which are arranged in descending order and denoted as the first eigenvalue, the second eigenvalue, and the third eigenvalue; this step uses the ISS algorithm to select points with significant and stable geometric structures as key points, providing reliable anchor points for subsequent feature matching, and improving registration efficiency and robustness; performing the ISS algorithm with the same parameters on the 3D mesh model of the standard bearing to obtain the fourth, fifth, and sixth eigenvalues ​​arranged in descending order; and extracting the eigenvalues ​​from the 3D mesh model of the bearing to be detected. From all points, points that simultaneously satisfy the first point selection condition are selected, namely, the ratio of the first feature value to the second feature value is greater than the first preset threshold of 12, and the ratio of the second feature value to the third feature value is greater than the second preset threshold of 12, to obtain the key point set of the bearing to be tested. The first and second preset thresholds are both set to 12. Setting it to 12 can filter out points with significant local curvature changes and prominent geometric structures as key points, effectively excluding unstable points located in smooth regions or linear structures, thereby improving the repeatability and matching robustness of key points. This step uses dual ratio thresholds to filter out points with significant curvature changes, ensuring that key points have high repeatability and distinguishability. From all points of the three-dimensional mesh model of the standard bearing, points that simultaneously satisfy the second point selection condition are selected, namely, the ratio of the fourth feature value to the fifth feature value is greater than the third preset threshold of 12, and the ratio of the fifth feature value to the sixth feature value is greater than the fourth preset threshold of 12, to obtain the key point set of the standard bearing. The third and fourth preset thresholds are both set to 12.This process can select points with significant local curvature changes and prominent geometric structures as key points, ensuring the repeatability and robustness of the key point set. Based on the key point set of the bearing to be detected and the key point set of the standard bearing, a feature vector corresponding to a fast point feature histogram descriptor is generated for each key point. Specifically, with each key point as the center, the geometric relationship between each pair of points is calculated within a spherical neighborhood with a radius 10 times the average spacing of the point cloud. A 33-dimensional feature vector is constructed using statistical angle and distance information, resulting in the feature vectors of the key points of the bearing to be detected and the standard bearing. This step encodes the local geometric structure of the key points into rotationally invariant descriptors, providing robust feature representations for subsequent matching. The Euclidean distance between the feature vectors of the key points of the bearing to be detected and the feature vectors of the standard bearing is calculated. The key points corresponding to the feature vector pair with the smallest Euclidean distance are selected as matching point pairs. A matching point pair set is constructed based on these matching point pairs. This step establishes an initial correspondence through feature vector similarity, providing candidate point pairs for subsequent rigid body transformation estimation. Based on the matching point pair set, a random sampling consensus algorithm is used to repeatedly perform sampling evaluation processing until the iteration termination condition is met or the preset iteration number of 500 is reached. The initial alignment posture is then output. The preset iteration number is set to 500. This number of iterations ensures that the algorithm finds the optimal rigid body transformation model with a high probability while taking into account computational efficiency. It avoids non-convergence due to insufficient iterations or unnecessary computational overhead due to excessive iterations. Specifically, the sampling evaluation processing includes randomly selecting three non-collinear point pairs from the matching point pair set. Based on the spatial coordinates of the bearing key point to be detected and the standard bearing key point in the point pair, candidate rigid body transformation matrices are calculated through singular value decomposition. The candidate rigid body transformation matrices are used to transform the bearing key point to be detected in the matching point pair set. The Euclidean distance between the transformed bearing key point to be detected and the corresponding standard bearing key point is calculated. Point pairs with an Euclidean distance less than 0.5 times the average spacing of the point cloud are regarded as inliers and the number of inliers is counted. The second preset distance threshold is set to 0 times the average spacing of the point cloud.The algorithm, with a 5x improvement in accuracy, effectively eliminates erroneous matches while tolerating minor registration errors, ensuring a sufficient number of reliable matching point pairs for rigid body transformation estimation. This enhances the robustness and accuracy of the initial alignment posture. After each iteration, if the current number of inliers exceeds the maximum number of inliers, the current candidate rigid body transformation matrix is ​​updated and saved. The iteration terminates when the current number of inliers exceeds a preset inlier threshold, which is 70% of the total number of matching point pairs. This threshold ensures that the selected rigid body transformation model has a sufficient number of inliers to support it, effectively eliminating erroneous matching interference. While maintaining the reliability of the initial alignment posture, it avoids the algorithm from failing to converge due to an excessively high threshold. This step eliminates erroneous matches through random sampling and inlier evaluation, obtaining a robust initial alignment posture and providing good initial values ​​for subsequent fine registration. Based on the initial alignment posture, an iterative nearest-point algorithm is used to iteratively optimize the rotation and translation matrices corresponding to the initial alignment posture until the change in the rotation matrix is ​​less than a preset threshold. A rotation threshold of 0.001 radians and a change in the translation matrix less than a preset translation threshold of 0.001 millimeters are used to obtain the registered 3D mesh model of the bearing to be inspected. The preset rotation threshold of 0.001 radians ensures that the iterative optimization of the rotation matrix converges to a high-precision state, achieving sub-milliradian-level precise alignment between the model to be inspected and the standard model in the angular direction. The preset translation threshold of 0.001 millimeters ensures that the iterative optimization of the translation matrix converges to a high-precision state, achieving micrometer-level precise alignment between the model to be inspected and the standard model in spatial position. This step uses an iterative nearest-point algorithm to finely adjust the initial alignment posture, achieving high-precision registration between the model to be inspected and the standard model, reaching sub-millimeter-level alignment accuracy. The Euclidean distance from each vertex of the registered 3D mesh model of the bearing to be inspected to the nearest vertex of the standard bearing 3D mesh model is calculated. Vertices whose Euclidean distance is greater than a preset defect threshold, i.e., 2.0 times the average spacing of the point cloud, are marked as defect points. The preset defect threshold is set to 2 times the average spacing of the point cloud.This method, with a 0x multiplier, effectively eliminates registration residual errors and surface micro-fluctuations while accurately identifying defect areas significantly deviating from the standard surface. It achieves reliable defect segmentation and location, using all marked defect points and the area formed by connected triangular facets as the defect region. This yields a 3D mesh model of the bearing to be inspected with defect markings. This step uses distance threshold segmentation to identify surface protrusions or depressions, enabling automatic location and marking of defect regions. Defect quantification provides accurate geometric regions. Geometric attribute indices are calculated to obtain defect quantification data. Specifically, this includes calculating the Euclidean distance from all points within the defect region to the nearest vertex of the standard bearing 3D mesh model, taking the maximum value as the maximum depth and the average value as the average depth. The areas of all triangular facets within the defect region are summed to obtain the surface area. The defect region is discretized into right prisms with triangular facets as bases extending along the normal direction, and their volumes are summed to obtain the defect volume. Principal component analysis is used to calculate the principal axis direction of the defect region, and a minimum circumscribed cuboid is constructed to obtain the length. The detection module calculates the average angle between the normal vectors of adjacent facets at the edge of the defect region, taking the width and height as the difference in normal vector direction. These eight indicators are used as the quantification data for the defect. This step provides a comprehensive quantitative characterization of the defect from multiple dimensions, including depth, area, volume, size, and direction. This results in quantifiable and comparable numerical outputs, meeting the standardization requirements of industrial quality inspection. The overall design of the detection module achieves robust initial alignment through ISS key point extraction and FPFH feature matching. After ICP fine registration, the defect region is segmented using a distance threshold, and the defect attributes are quantified using multi-dimensional geometric indicators. This enables automated detection and comprehensive quantitative characterization of surface defects in miniature bearings, providing accurate and reproducible data support for quality assessment. It achieves high-precision registration between the bearing under test and the standard model, accurately identifies and marks defect regions, and comprehensively quantifies the depth, area, volume, size, and direction features of the defect through multi-dimensional geometric indicators, significantly improving the automation and quantification accuracy of defect detection.

[0030] Visualization processing specifically includes: The 3D model with defect markings is rendered, the 3D mesh model of the standard bearing is displayed in the first preset color, the defect area is highlighted in the second preset color, and the results are displayed through the 3D rendering window to obtain a visualized inspection result.

[0031] The report generation process involves summarizing the various geometric attribute indicators from the defect quantification data into a table to generate a defect detection report.

[0032] In one embodiment, to ensure that the generation module can intuitively present the defect detection results and provide a standardized inspection report, the visualization processing and report generation specifically include: Visualization processing specifically includes rendering the 3D model with defect markers, where the Phong lighting model is used to colorize the model surface to enhance the three-dimensional effect; the 3D mesh model of the standard bearing is displayed in a first preset color, gray, and the defect area is highlighted in a second preset color, red; and interactive operations such as rotation, scaling, and translation are provided through a 3D rendering window to display the results, thus obtaining a visualized inspection result. This step, through color differentiation and interactive 3D display, enables inspectors to intuitively locate the defect area and observe the defect morphology, achieving a visualized presentation of the inspection results and improving the readability of the results. The technical effects on quality and analysis efficiency are significant. Report generation specifically involves summarizing eight geometric attribute indicators from the defect quantification data—maximum depth, average depth, surface area, defect volume, length, width, height, and normal vector direction difference—into a table. Each indicator in the table corresponds to a specific value and unit. An HTML-formatted defect detection report, including 3D model screenshots and the quantification data table, is generated. This step outputs the quantification results in a standardized table format, facilitating recording, archiving, and quality traceability, achieving standardized management of detection data, and meeting the standardization requirements of industrial quality inspection reports. The defect location and shape are intuitively presented through color highlighting and 3D interactive rendering, and the standardized table generates a detection report with complete quantification indicators, significantly improving the visualization level of the detection results and the standardization of report generation.

[0033] This invention constructs a Kd-tree using a variance-first strategy to optimize neighborhood search efficiency and introduces an improved deep neural network to perform noise point displacement processing on each point. The loss function integrates a spatial distance weighted guiding term and a spatial distance constraint term, solving the problem of easy distortion of local geometric structure in existing methods. It achieves accurate correction of noise points and preservation of details. Existing algorithms often lead to mesh holes or distortion due to uneven point cloud distribution. This scheme uses the displacement output by the neural network as an approximation of the spatial distance field. Combined with voxelized signed distance field calculation and moving cube algorithm, it significantly improves the fidelity of 3D reconstruction. Through accurate registration of key points and quantization of multi-dimensional geometric attributes, it overcomes the limitation of traditional manual feature comparison in quantifying small irregular defects, achieving accurate identification and comprehensive characterization of defects, and greatly improving the automation level and quantification accuracy of the detection system.

[0034] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product implemented on one or more computer-usable storage media containing computer-usable program code. The storage medium can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as Static Random Access Memory (SRAM), Electrically Erasable Programmable Read-Only Memory (EEPROM), Erasable Programmable Read Only Memory (EPROM), Programmable Red-Only Memory (PROM), Read-Only Memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk. These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0035] It should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention, and all such modifications or substitutions should be covered within the protection scope of the present invention.

Claims

1. A visual inspection system for surface defects in miniature bearings, characterized in that, It includes a processing module, an optimization module, a reconstruction module, a detection module, and a generation module; The processing module acquires the raw point cloud data of the bearing to be tested, performs filtering on the raw point cloud data, and obtains the processed point cloud data of the bearing to be tested. The optimization module constructs a Kd tree based on a variance-first strategy and uses an improved deep neural network to perform noise point displacement processing on each point in the point cloud data of the bearing to be tested, thereby obtaining updated point cloud data. The updated point cloud data is then iteratively optimized to obtain fine point cloud data of the bearing to be tested. The reconstruction module performs three-dimensional reconstruction based on the fine point cloud data of the bearing to be tested, and obtains a three-dimensional mesh model of the bearing to be tested. The detection module registers the 3D mesh model of the bearing to be tested with the 3D mesh model of the standard bearing and performs defect detection to obtain a 3D mesh model of the bearing to be tested with defect markers and defect quantification data. The generation module performs visualization processing and report generation on the 3D model with defect markers and defect quantification data, resulting in visualized detection results and defect detection reports; Based on the variance-first strategy, a Kd-tree is constructed using the variance-first strategy based on the processed point cloud data of the bearing to be detected; The variance-first strategy includes selecting the dimension with the largest variance in the processing point cloud data of the bearing to be tested as the segmentation dimension for spatial partitioning; Based on an improved deep neural network, noise point displacement processing is performed on each point in the point cloud data of the bearing to be inspected. Noise point displacement processing specifically includes: Using the current processing point as the center, search for the neighborhood point set of the current processing point in the Kd tree. The search radius is the product of the preset radius scaling factor and the diagonal length of the bounding box of the processing point cloud data of the bearing to be detected. The neighborhood point set and the current processing point are normalized to obtain the normalized current point and the normalized neighborhood point set; The improved deep neural network employs an improved loss function, the expression of which is: ; in, Represents the loss function. This indicates a spatial distance-weighted leading term. This represents the spatial distance constraint term. This indicates the preset weighting coefficients; The calculation process of the spatial distance weighted guiding term includes: fitting the current processing point to the corresponding neighborhood point set after displacement processing to obtain the local surface; calculating the signed distance from the current processing point to the local surface; and weighting and summing the signed distances according to preset weights to obtain the spatial distance weighted guiding term. The calculation process of the spatial distance constraint term includes: calculating the Euclidean distance between the current processing point and each point in the corresponding neighborhood point set; calculating the difference between the Euclidean distance and the preset target uniform spacing to obtain the distance deviation value; and summing the distance deviation values ​​to obtain the spatial distance constraint term.

2. The visual inspection system for surface defects of miniature bearings as described in claim 1, characterized in that: Obtain the raw point cloud data of the bearing to be inspected, specifically including: Structured light 3D measurement was used to scan the micro-bearing object to be tested on the stage from multiple perspectives to obtain local point cloud data from multiple perspectives. By stitching together the local point cloud data using preset marker points, the original dense point cloud data is obtained. Filtering specifically includes: The random sampling consensus algorithm is used to remove the planar point cloud data used as the stage from the original dense point cloud data, resulting in point cloud data after background removal. A density-based clustering algorithm is used on the point cloud data after background removal. A preset radius is used as the search neighborhood. Point cloud data with more than a preset threshold of points in the neighborhood are grouped into the same cluster, resulting in multiple clusters. The cluster with the most points in the cluster is selected as the point cloud data of the bearing body, and the point cloud data corresponding to the other clusters are removed to obtain the main point cloud data of the bearing to be detected. The statistical filtering of the main point cloud data includes removing point cloud data with an average distance greater than a first preset distance threshold from the main point cloud data to obtain the processed point cloud data of the bearing to be detected.

3. The visual inspection system for surface defects of miniature bearings as described in claim 2, characterized in that: The normalized neighborhood point set is input into an improved deep neural network for processing, and the output is the shifted normalized points, specifically including: The improved deep neural network consists of an encoder and a decoder; The encoder includes a first convolutional layer, a second convolutional layer, and a third convolutional layer connected in sequence; The first convolutional layer has 3 input channels and 32 output channels. The second convolutional layer has 32 input channels and 64 output channels; The third convolutional layer has 64 input channels and 128 output channels; The normalized neighborhood point set is input into the first convolutional layer, and convolution operation, batch normalization processing and nonlinear activation are performed in sequence to obtain the first activation feature map. The first activation feature map is input into the second convolutional layer, and convolution operation, batch normalization and non-linear activation are performed in sequence to obtain the second activation feature map. The second activation feature map is input into the third convolutional layer, and convolution operation, batch normalization and non-linear activation are performed in sequence to obtain the third activation feature map. The third activation feature map is subjected to max pooling to obtain the global feature vector; The decoder consists of a first fully connected layer, a second fully connected layer, and a third fully connected layer connected in sequence; The first fully connected layer has an input dimension of 128 and an output dimension of 64. The second fully connected layer has an input dimension of 64 and an output dimension of 32. The third fully connected layer has an input dimension of 32 and an output dimension of 3. The global feature vector is input into the first fully connected layer, and the fully connected operation and non-linear activation are performed sequentially to output the first feature vector. The first feature vector is input into the second fully connected layer, and the fully connected operation and non-linear activation are performed in sequence to obtain the second feature vector; The second feature vector is input into the third fully connected layer, and after performing the fully connected operation in sequence, the displacement of the current point is obtained. The normalized current point is displaced according to the displacement amount to obtain the normalized point after displacement; The normalized points after displacement are mapped back to the original coordinate space through inverse transformation to obtain updated points, and the updated point cloud data is constructed based on the updated points. Using the updated point cloud data as input, the Kd tree is reconstructed based on the updated point cloud data, and the noise point displacement processing is repeated n times to obtain the fine point cloud data of the bearing to be detected.

4. The visual inspection system for surface defects of miniature bearings as described in claim 3, characterized in that: 3D reconstruction specifically includes: The displacement output by the improved deep neural network is used as an approximation of the spatial distance field; The bounding box of the fine point cloud data of the bearing to be tested is divided into voxels. For each voxel vertex, if there is fine point cloud data within the preset range of the voxel vertex, the projection value of the displacement corresponding to the fine point cloud data in the direction of the normal vector of the point is used as the signed distance value of the voxel vertex, and the sign of the signed distance value is determined according to the sign of the dot product between the voxel vertex and the local surface normal vector. Otherwise, calculate the Euclidean distance between the voxel vertex and the nearest point in the fine point cloud data of the bearing to be detected, and determine the sign of the distance based on the sign of the dot product of the normal vectors of the voxel vertex and the nearest point, which is used as the signed distance value of the voxel vertex. By traversing the vertices of all voxels, the spatial distance field is obtained; The moving cube algorithm is used to extract isosurfaces from the spatial distance field; Iterate through each voxel and compare the distance values ​​at each vertex of the voxel with a preset extraction threshold. Specifically, this includes: If the distance value is greater than the preset extraction threshold, it is marked as 1; otherwise, it is marked as 0. An 8-bit binary index is constructed based on the labels of the 8 vertices. The edges that intersect with the isosurface within the voxel and the connection method are determined by looking up the table. Interpolation calculations are performed on the edges that intersect the isosurface to obtain the intersection point position. Triangular patches are generated based on the intersection point position. By piecing together all the triangular facets, a continuous three-dimensional mesh model of the bearing to be tested is obtained.

5. The visual inspection system for surface defects of miniature bearings as described in claim 4, characterized in that: Registration and defect detection specifically include: The ISS algorithm is used to calculate the eigenvalues ​​of the local neighborhood covariance matrix of each point in the three-dimensional mesh model of the bearing to be inspected, resulting in three eigenvalues. These three eigenvalues ​​are arranged in descending order of size and are denoted as the first eigenvalue, the second eigenvalue, and the third eigenvalue. The ISS algorithm is used to calculate the eigenvalues ​​of the local neighborhood covariance matrix of each point for the three-dimensional mesh model of the standard bearing. Three eigenvalues ​​are obtained and arranged in descending order of size, and are denoted as the fourth eigenvalue, the fifth eigenvalue, and the sixth eigenvalue. Select points from all points in the 3D mesh model of the bearing to be tested that simultaneously satisfy the first point selection condition to obtain the key point set of the bearing to be tested; The first selection condition includes that the ratio of the first feature value to the second feature value is greater than a first preset threshold, and the ratio of the second feature value to the third feature value is greater than a second preset threshold. From all points in the 3D mesh model of the standard bearing, select points that simultaneously satisfy the second point selection condition to obtain the key point set of the standard bearing; The second selection criteria include that the ratio of the fourth feature value to the fifth feature value is greater than the third preset threshold, and the ratio of the fifth feature value to the sixth feature value is greater than the fourth preset threshold. Based on the key point set of the bearing to be tested and the key point set of the standard bearing, generate the feature vector corresponding to the fast point feature histogram descriptor for each key point, and obtain the feature vector of the key point of the bearing to be tested and the feature vector of the key point of the standard bearing. Calculate the Euclidean distance between the feature vectors of the key points of the bearing to be detected and the feature vectors of the key points of the standard bearing. Take the key points corresponding to the feature vector pairs with the smallest Euclidean distance as matching point pairs, and construct a set of matching point pairs based on the matching point pairs.

6. The visual inspection system for surface defects of miniature bearings as described in claim 5, characterized in that: Based on the matching point pair set, the random sampling consensus algorithm is used to repeatedly perform the sampling evaluation process until the iteration termination condition is met or the preset number of iterations is reached, and the initial alignment posture is output. The sampling and evaluation process specifically includes: Randomly select at least 3 non-collinear point pairs from the set of matching point pairs, and calculate the candidate rigid body transformation matrix based on the spatial coordinates of the key point of the bearing to be detected and the spatial coordinates of the key point of the standard bearing in the point pair. The candidate rigid body transformation matrix is ​​used to transform the matching point pairs of the bearing key points to be detected, and the transformed bearing key points to be detected are obtained. Calculate the Euclidean distance between the key points of the bearing to be detected after transformation and the corresponding key points of the standard bearing, and calculate the number of matching point pairs whose Euclidean distance is less than the second preset distance threshold as the number of interior points. After each iteration, if the current number of inliers is greater than the maximum number of inliers, then update the maximum number of inliers and save the rigid body transformation matrix of the current candidate. The iteration termination condition includes the current number of interior points being greater than a preset threshold for the number of interior points. After the iteration is complete, the saved rigid body transformation matrix is ​​used as the initial alignment pose.

7. The visual inspection system for surface defects of miniature bearings as described in claim 6, characterized in that: Based on the initial alignment posture, the iterative nearest point algorithm is used to iteratively optimize the rotation matrix and translation matrix corresponding to the initial alignment posture until the change in the rotation matrix is ​​less than a preset rotation threshold and the change in the translation matrix is ​​less than a preset translation threshold, thus obtaining the registered three-dimensional mesh model of the bearing to be detected. Calculate the Euclidean distance from each vertex of the registered 3D mesh model of the bearing to be inspected to the nearest vertex of the standard 3D mesh model. Mark vertices with Euclidean distances greater than a preset defect threshold as defect points. The area formed by all marked defect points and connected triangular facets is taken as the defect region, thus obtaining a 3D mesh model of the bearing to be inspected with defect markings.

8. The visual inspection system for surface defects of miniature bearings as described in claim 7, characterized in that: Geometric attribute indices are calculated for the defective area to obtain quantitative defect data, specifically including: Calculate the Euclidean distance from all points within the defect area to the nearest vertex of the standard bearing 3D mesh model, take the maximum value of the Euclidean distance as the maximum depth, and calculate the average value of the Euclidean distance as the average depth. The area of ​​all triangular facets within the defective region is summed to obtain the surface area. The defect region is discretized into right prisms with triangular facets as the base and extending along the normal direction, and the volume is accumulated to form the defect volume; The principal axis direction of the defect region is calculated by principal component analysis, and the minimum circumscribed cuboid is constructed to obtain the length, width, and height. The angle between the normal vectors of adjacent facets at the edge of the defect region is calculated as the difference in the direction of the normal vectors; Maximum depth, average depth, surface area, defect volume, length, width, height, and difference in normal vector direction are used as defect quantification data.

9. The visual inspection system for surface defects of miniature bearings as described in claim 8, characterized in that: Visualization processing specifically includes: The 3D model with defect markings is rendered, the 3D mesh model of the standard bearing is displayed in the first preset color, the defect area is highlighted in the second preset color, and the results are displayed through the 3D rendering window to obtain a visualized inspection result.

10. The visual inspection system for surface defects of a miniature bearing as described in claim 9, characterized in that: The report generation process involves summarizing the various geometric attribute indicators from the defect quantification data into a table to generate a defect detection report.

Citation Information

Patent Citations

  • Engineering structure three-dimensional fine texture appearance model reconstruction method based on improved NeRF

    CN118505879A

  • Rendering-based artificial industrial product defect synthesis method and device

    CN120298303A