Surface particle defect detection method and computer-readable storage medium

By mapping the 3D point cloud data into a 2D depth map and conducting contour analysis, combining Gaussian curve fitting and watershed segmentation, the defects of the surface particle of the cathode copper plate are automatically identified, solving the missed and mis-checking problems of traditional artificial quality inspection methods, and achieving efficient and stable automated inspection.

CN115294083BActive Publication Date: 2025-08-29KEDA INTELLIGENT IOT TECH CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202210984882.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-08-16
Publication Date
2025-08-29
Estimated Expiration
2042-08-16

AI Technical Summary

Technical Problem

Traditional artificial quality inspection methods cannot maintain concentration for a long time, and there are high missed inspection and error inspection rates, and the consistency, reliability and stability of the inspection cannot be guaranteed, which affects the quality of the cathode copper plate and the industry reputation.

Method used

3D point cloud data is used to obtain surface information, map it into a 2D depth map and perform contour analysis, and combine Gaussian curve fitting and watershed segmentation to automatically identify surface particle defects and realize automated detection.

Benefits of technology

It improves the consistency, reliability and stability of the inspection process, reduces labor costs, and improves the accuracy and reliability of the inspection effect.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115294083B_ABST
    Figure CN115294083B_ABST
Patent Text Reader

Abstract

The present invention provides a surface particle defect detection method and a computer-readable storage medium, wherein the surface particle defect detection method includes the steps of obtaining 3D point cloud data of a surface to be tested; mapping the 3D point cloud data into a 2D depth map; performing contour analysis on the 2D depth map to determine effective defect areas, and determining the surface to be tested by the number and / or area of ​​the effective defect areas. The surface particle defect detection method of the present application accurately identifies the location of particle defects on the surface of the surface particle defects by using surface raised features at the surface particle defects. The method can be implemented by a corresponding detection device and detection program to achieve automated detection, which improves the consistency, reliability, and stability of the detection process compared to manual detection.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of defect detection methods, and in particular to a surface particle defect detection method and a computer-readable storage medium. Background Art

[0002] In the production process of cathode copper plates (foils) in the metallurgical industry, due to impurities in the anode copper or electrolyte in the electrolytic cell, impurities will also be adsorbed on the cathode plate during the process of copper ions adsorbing on the starting plate. This will inevitably cause raised particles of varying sizes on the surface of the cathode copper plate after electrolysis. These particles will seriously affect the quality of the cathode copper plate itself. When cathode copper containing particles is mixed with qualified products, it will seriously affect sales and industry reputation.

[0003] Traditional manual quality inspection methods require inspectors to maintain their focus for extended periods, resulting in a certain rate of missed inspections and false positives. In continuous production processes, a single person cannot remain on duty for extended periods, requiring multiple shifts. This not only increases labor costs but also results in fluctuations in quality inspection results, influenced by the inspector's skill level, changing attitudes, and environmental factors. Therefore, manual quality inspection needs to improve its consistency, reliability, and stability. Summary of the Invention

[0004] In order to solve the problem that the inspection effect of existing manual quality inspection methods needs to be improved, the present application provides a surface particle defect detection method.

[0005] The technical solution of the present application provides a surface particle defect detection method, comprising the following steps:

[0006] Obtain 3D point cloud data of the surface to be measured;

[0007] Mapping the 3D point cloud data into a 2D depth map;

[0008] Performing contour analysis on the 2D depth map to determine the effective defect area.

[0009] Specifically, the step of performing contour analysis on the 2D depth map to determine the effective defect area further includes:

[0010] Determine the candidate defect area step, performing contour connected domain extraction on the 2D depth map to obtain the candidate defect area of ​​the surface to be tested;

[0011] a step of determining a preferred defect region, performing Gaussian curve fitting on the candidate defect region based on a Gaussian curve with a translation coefficient to obtain a preferred defect region of the surface to be measured;

[0012] The effective defect area is determined by applying a watershed segmentation and region growing strategy that fuses the sub-regions to the preferred defect area to obtain the effective defect area.

[0013] Specifically, the step of determining the preferred defect area is:

[0014] Traverse all the candidate defect areas and apply at least the following steps to each candidate defect area:

[0015] Determine the fitting center point step, determine the maximum grayscale pixel point (P) of the candidate defect area; determine the row pixel arrangement (RP) and column pixel arrangement (CP) where the maximum grayscale pixel point (P) is located;

[0016] Construct fitting function steps and construct fitting curve Wherein, a, b, c are fitting coefficients, and x0 is the corresponding coordinate value of the maximum grayscale pixel (P);

[0017] In the row fitting step, the least squares fitting is performed on the row pixel arrangement (RP) using the fitting curve, and the obtained fitting coefficients a, b, and c are respectively recorded as a r 、b r 、c r ;

[0018] In the column fitting step, the least squares fitting is performed on the column pixel arrangement (CP) using the fitting curve, and the obtained fitting coefficients a, b, and c are respectively recorded as a c 、b c 、c c ;

[0019] Candidate region determination step, for the preset grayscale threshold A g , if the fitting coefficient satisfies (a r <0 and a c <0) or (b r <0 and b c <0) or (x 0r g And x 0c g ), exclude the candidate defect area;

[0020] Preferably,

[0021] In the row fitting step, the grayscale value of the minimum grayscale pixel in the row pixel arrangement (RP) is used as the fitting coefficient c r , using the fitted curve Perform least squares fitting on the row pixel arrangement (RP) to obtain the fitting coefficient a r 、b r ;

[0022] In the column fitting step, the grayscale value of the minimum grayscale pixel in the column pixel arrangement (CP) is used as the fitting coefficient c​​c , using the fitted curve Perform least squares fitting on the row pixel arrangement (RP) to obtain the fitting coefficient a c 、b c .

[0023] Preferably, the step of determining the effective defect area is:

[0024] Traverse all the preferred defect areas and apply at least the following steps to each preferred defect area:

[0025] The grayscale range determination step is to determine the maximum grayscale value t of the preferred defect area. max With the minimum gray value t min ;

[0026] To determine the grayscale separation point step, press t g =max{(t max +t min ) / 2,t max -t b}Determine the segmentation grayscale preset value t g , where t b is the preset defect grayscale threshold;

[0027] The region growing step is to grow the grayscale value in the preferred defect region greater than t g The pixel point of is used as a seed point for region growing to obtain the effective defect area corresponding to the preferred defect area.

[0028] Preferably, the step of mapping the 3D point cloud data into a 2D depth map further comprises the following steps:

[0029] Performing denoising on the 3D point cloud data to obtain preprocessed point cloud data;

[0030] Interpolating the pre-processed point cloud data to map it into a 2D depth map;

[0031] The step of interpolating the pre-processed point cloud data and mapping it into a 2D depth map comprises:

[0032] A normalization processing step of linearly mapping the three-dimensional coordinate data of the pre-processed point cloud data in space to the length, width, and grayscale depth of the 2D depth map to obtain original mapping data;

[0033] In the interpolation step, the original mapping data is converted into an initial depth map using nearest neighbor interpolation. The pixel points with zero grayscale value in the initial depth map are traversed, and the grayscale value of the pixel with zero grayscale value is overwritten with the grayscale value of the pixel with the maximum grayscale value in the small neighborhood to obtain a 2D depth map.

[0034] Furthermore, the step of performing denoising on the 3D point cloud data to obtain pre-processed point cloud data includes:

[0035] In the plane fitting step, the 3D point cloud data is uniformly downsampled, and then a plane fitting is performed on the uniformly downsampled 3D point cloud data based on the RANSAC algorithm to obtain the plane equation;

[0036] In the distance denoising step, points whose distances to the plane equation are greater than a preset distance threshold in the 3D point cloud data after uniform downsampling are removed to obtain the pre-processed point cloud data.

[0037] Furthermore, the surface particle defect detection method further includes the step of determining the quality grade of the surface to be tested based on the number and / or area of ​​the effective defect regions of the surface to be tested;

[0038] The step of determining the quality grade of the surface to be tested based on the number and / or area of ​​the effective defect regions of the surface to be tested is:

[0039] Determine N defect area levels, defect area level S j Arrange in ascending order according to the proportion of defect area contained therein, where j is the sorting ordinal number;

[0040] Determine N defect quantity levels, defect quantity level M i Arrange them in ascending order according to the number of defects they contain, where i is the sorting ordinal number;

[0041] Counting the sum of the areas of all the effective defect regions on the surface to be measured, and calculating the proportion S of the sum of the areas in the area of ​​the 2D depth map; and counting the number M of the effective defect regions;

[0042] Then the defect area level S of the surface to be measured is j By S∈[S j·min ,S j·max ] Determine the defect quantity level M of the surface to be tested i By M∈[M i·min ,M i·max ] Determine, where S j·min S is the defect area grade j The lower limit of the range, S j·max S is the defect area grade j The upper limit of the range, M i·min is the defect area grade M i The lower limit of the range, M i·max S is the defect area grade j The upper limit of the range;

[0043] The quality level Q of the surface to be measured is Q=max{S j ,M i}.

[0044] In addition, the present application also provides a computer-readable storage medium storing a computer program, characterized in that when the computer program is executed by a processor, the processor executes the steps of the above method.

[0045] The surface particle defect detection method of the present application accurately identifies the location of particle defects by using the surface raised features at the surface particle defects. To identify the surface raised features at the particle defects, the present application utilizes the collected 3D point cloud data of the surface to be tested. By converting the 3D point cloud data into a 2D depth map and performing contour analysis on the 2D depth map, a 2D depth map is obtained based on the surface height information expressed in grayscale. The 2D depth map is the location of the corresponding particle defect. The solution of the present application can be implemented by corresponding detection devices and detection programs to achieve automated detection, which improves the consistency, reliability and stability of the detection process compared to manual detection. BRIEF DESCRIPTION OF THE DRAWINGS

[0046] Figure 1 This is the overall data flow diagram of this application;

[0047] Figure 2 The original image and the processed point cloud data image in the embodiment of this application;

[0048] Figure 3 is the depth map after conversion in the embodiment of the present application;

[0049] Figure 4 The image edge picture obtained by edge detection in the embodiment of the present application;

[0050] Figure 5 A schematic diagram of Gaussian fitting according to an embodiment of the present application.

[0051] P: Maximum grayscale pixel RP: Row pixel arrangement CP: Column pixel arrangement I1: Surface to be measured I2: 3D point cloud data I21: Preprocessed point cloud data I22: Original mapping data I31: Initial depth map I3: 2D depth map I4: Valid defect area I41: Candidate defect area I42: Preferred defect area I5: Quality level DETAILED DESCRIPTION

[0052] The present invention is described in detail below in conjunction with the accompanying drawings and specific embodiments. In this specification, the size ratios in the drawings do not represent the actual size ratios, but are only used to reflect the relative positional relationship and connection relationship between the various components. Components with the same name or the same number represent similar or identical structures and are only for illustrative purposes.

[0053] Cathode copper plates or cathode copper foils and other products are obtained by electrolytically depositing copper ions at the cathode of the electrolytic cell. Usually, due to the particularity of the electrolytic deposition process (the current density decreases in thick areas, slowing down the deposition rate), the deposited surface tends to be flat, so cathode copper products with higher surface flatness can be obtained. However, when the copper raw material used in the anode or the electrolytic solution contains other metal ions that can co-precipitate with copper ions, co-precipitation of impurity ions will occur, so that impurity particles form local protrusions on the surface of the cathode copper product, resulting in surface defects. Therefore, the surface characteristics of the cathode copper product, more specifically, its surface morphology characteristics, can be used to distinguish and identify impurity particle defects.

[0054] The full process data flow diagram of this application is as follows Figure 1 As shown, in order to realize the automatic identification of surface particle defects of existing cathode copper products through surface morphology, the technical solution adopted in this application includes the following steps:

[0055] S1, using the set 3D line laser camera to obtain 3D point cloud data I2 of the surface to be measured I1;

[0056] S2, mapping the 3D point cloud data I2 into a 2D depth map I3 through certain preprocessing and mapping rules;

[0057] S3. Determine the position and number of the effective defect areas I4 of the surface to be measured I1 by analyzing the contour of the 2D depth map I3.

[0058] In the above step S2, the process of mapping the 3D point cloud data I2 into the 2D depth map I3 through certain preprocessing and mapping rules includes:

[0059] S21, denoising the 3D point cloud data to obtain pre-processed point cloud data. Taking a specific embodiment of the present application as an example, Figure 2 (a) is the visible light image of the surface I1 to be measured, Figure 2(b) is the data of the 3D point cloud data I2 corresponding to the surface to be measured I1 obtained in step S1. In addition to the surface to be measured I1, other features can be clearly seen in the figure, such as the supporting surface data in the lower left and lower right of the figure and possible background noise. For this purpose, the 3D point cloud data I2 is subjected to distance denoising. In order to determine the reference plane for distance denoising, the 3D point cloud data I2 is first plane fitted. The point cloud data of the plate surface in the 3D point cloud data I2 is uniformly downsampled, and then the plane fitting is performed on the uniformly downsampled 3D point cloud data based on the RANSAC algorithm to obtain the equation of the plane P. In the embodiment of the present application, the plane fitting equation can be expressed as: Ax+By+Cz=D. Through the RANSAC algorithm, the point cloud within the plate range in the 3D point cloud data I2 is downsampled and plane fitting is performed, and A=-0.0131117, B=-0.00683267, C=-1, and D=279.713 are obtained. Then, distance denoising is performed based on the plane P. First, a reasonable distance threshold H is determined according to the acquisition scene of the 3D point cloud data I2. d , for example, in the embodiment of the present application, H is taken d =13mm. Then traverse all point cloud data in the 3D point cloud data I2, calculate the distance between each point and the above plane P, and take the distance greater than H as the distance. d The data points are removed to obtain the denoised data, such as Figure 2 (c) is shown to correctly reflect the actual range of the surface I1 to be measured. After the above processing, we can get Figure 2 (c) 3D point cloud data I2. It can be seen that the point cloud data outside the outline of the surface I1 that does not belong to the surface I1 has been removed, and finally a relatively clean pre-processed point cloud data I21 is obtained.

[0060] S22, interpolate the pre-processed point cloud data and map it into a 2D depth map. First, normalize the size of the pre-processed point cloud data I21, and map the three-dimensional coordinate data of the pre-processed point cloud data I21 in space to the length, width, and grayscale depth of the 2D depth map I3 to obtain the original mapping data I22. This can generally be achieved through a simple linear transformation. Such an operation is a routine operation in this field and will not be described here. After normalization, the original mapping data has the same scale range as the expected initial depth map I31, that is, assuming that the acquisition accuracy of the 3D camera in the x and y directions is p x 、p y The maximum value of the collected point cloud range in the X and Y directions is X max 、Y max The minimum value of the collected point cloud range in the X and Y directions is X min 、Y min , then the width of the converted depth map can be w=(Y max -Ymin ) / p y , the height of the converted depth map can be h=(X max -X min ) / p x , w, h are rounded. However, each point cloud data in the original mapping data I22 does not have a one-to-one correspondence with the pixel points in . In terms of the embodiment of the present application, the 3D point cloud data (I2) collected by the 3D line laser camera has a maximum value of 527.797mm and a minimum value of -514.208mm in the X direction, a maximum value of 574.517mm and a minimum value of -492.488mm in the Y direction, a maximum value of -258.274mm and a minimum value of -298.729mm in the z direction, and the collection accuracy of the 3D camera in the X and Y directions is 1mm and 1mm respectively. The width of the converted depth map is set to 1067px, the height is 1042px, and the maximum grayscale value is 255.

[0061] Since the point cloud data represented by floating-point numbers is converted into integer grayscale data after conversion to grayscale data, the algorithm speed can be accelerated, making the algorithm applicable to practical applications. In order to preserve the local features in the original data as much as possible while avoiding the introduction of unnecessary noise in the process of mapping the original mapping data I22 to the initial depth map I31, the original mapping data I22 is first converted into the initial depth map I31 using nearest neighbor interpolation to obtain the basic data of the initial depth map I31. This is equivalent to a scaling process using nearest neighbor interpolation. In order to avoid some pixels not being assigned values ​​in the process, the pixels with zero grayscale value in the initial depth map I31 are traversed again, and the grayscale value of the pixel with the maximum grayscale value in the small neighborhood is used to cover the grayscale value of the pixel with zero grayscale value to obtain the 2D depth map I3. Figure 3 (b) for Figure 3 (a) An example of a 2D depth map obtained by replacing the grayscale value of pixels with a grayscale value of 0 with the maximum grayscale value of a 3x3 neighborhood.

[0062] After converting the surface to be tested I1 into a 2D depth map I3 through the aforementioned processing, the 2D depth map I3 is analyzed to obtain valuable information about the original surface to be tested I1. In the technical solution of this application, abnormal protrusions on the surface of the surface to be tested I1 are identified through the 2D depth map I3 to determine the presence of particle defects on the surface to be tested I1. Specifically, a contour analysis of the 2D depth map I3 based on grayscale differences is performed to determine the effective defect area I4. Because the analysis process uses the lightweight 2D depth map I3 rather than the original 3D point cloud data I2, the analysis speed of this application is improved, making it suitable for use in production.

[0063] The step of performing contour analysis on the 2D depth map I3 to determine the effective defect area I4 in S3 includes:

[0064] S31, step of determining the candidate defect area I41, obtaining the candidate defect area I41 of the surface to be measured I1 by performing contour connected domain extraction on the 2D depth map I3, firstly, using canny edge detection on the 2D depth map to obtain an edge detection image, and removing the portion of the edge detection image outside the effective area of ​​the surface to be measured I1. Specifically, the edge detection image and the plate effective area mask image can be subjected to an "AND" operation to obtain their union as the effective edge image, so as to remove the invalid contour of the plate edge. Figure 4 Figures (a) and (b) are the edge detection image obtained by the canny edge detection algorithm in this embodiment and the effective edge image after removing the invalid contour. In the above embodiment of the present application, the upper and lower thresholds of the canny algorithm are respectively H up =100, H down = 50. Then, based on the effective edge image, contour connected domain extraction is performed to obtain a candidate defect region I41 of the surface to be tested I1. The candidate defect region I41 should be composed of multiple contour connected domains. For each contour, the coordinates of its corresponding circumscribed rectangle are calculated.

[0065] S32, the step of determining the preferred defect area I42, is to perform Gaussian curve fitting on the candidate defect area I41 based on the Gaussian curve with translation coefficient to obtain the preferred defect area I42 of the surface to be tested I1. The specific operation is as follows Figure 5 As shown in the schematic diagram in , all candidate defect areas I41 are traversed, and at least the following steps are applied to each candidate defect area I41:

[0066] S321, determining the fitting center point step, determining the maximum grayscale pixel point P of the candidate defect area I41; determining the row pixel arrangement RP and column pixel arrangement CP where the maximum grayscale pixel point P is located;

[0067] S322, construct fitting function step, construct fitting curve Where a, b, and c are fitting coefficients, and x0 is the corresponding coordinate value of the maximum grayscale pixel (P);

[0068] Then, row fitting and column fitting are performed on the same candidate defect region I41 respectively.

[0069] S323, row fitting step, using the fitting curve to perform least square fitting on the row pixel arrangement (RP), and the obtained fitting coefficients a, b, and c are recorded as a r 、b r 、c r ;

[0070] S324, column fitting step, using the fitting curve to perform least square fitting on the column pixel arrangement (CP), and the obtained fitting coefficients a, b, and c are recorded as a c 、b c 、c c ;

[0071] After completing the above operations, a determination is made as to whether the candidate defect region I41 belongs to a defect region according to the fitting result, that is, for the preset grayscale threshold A g , if the fitting coefficient satisfies (a r <0 and a c <0) or (b r <0 and b c <0) or (x 0r g And x 0c g ), the candidate defect area I41 is excluded; the candidate defect area I41 that is not excluded is retained as the preferred defect area I42. In the embodiment of the present application, according to the production process, A g =15.

[0072] In fact, in the above process, due to the existence of the fitting pseudo-number c, the complexity of the Gaussian fitting process is greatly increased, resulting in low execution efficiency of the algorithm. In order to solve the above problem, it can be considered that the fitted curve is obtained by translating c units up and down on the reference axis. At the same time, it can be assumed a priori that the original data also follows the above characteristics, and in the final result, the exact value of the coefficient has almost no effect on the judgment result. What is important is the approximate range of the coefficient. Therefore, in the row fitting step, the grayscale value of the minimum grayscale pixel in the row pixel arrangement (RP) is used as the fitting coefficient c. r In the column fitting step, the grayscale value of the minimum grayscale pixel in the column pixel arrangement (CP) is used as the fitting coefficient c c .

[0073] Furthermore, based on the preferred defect region I42, the data set range of the final result can be narrowed down, that is, the effective defect region I4 can be further determined. Specifically, the effective defect region I4 is obtained by applying the watershed segmentation and region growing strategy that integrates the sub-regions to the preferred defect region I42. The detailed process is to traverse all the preferred defect regions I42 and apply at least the following steps to each preferred defect region I42:

[0074] The grayscale range determination step is to determine the maximum grayscale value t of the preferred defect area I42. max With the minimum gray value t min ;

[0075] To determine the grayscale separation point step, press t g ​​=max{(t max +t min ) / 2,t max -t b}Determine the segmentation grayscale threshold t g , where t b is a preset defect grayscale threshold, which is determined according to the actual production situation. For example, in the above embodiment, t b =9.

[0076] In the region growing step, the gray value of the preferred defect region I42 is greater than t g Pixels are used as seed points for region growing. The growth threshold is set at 10 to 20 based on the characteristics of the particle defect to accurately capture particle edges. Region growing stops when all seed pixels are traversed and no new seed points are found. Selecting multiple seed points allows for more accurate capture of particle edges. If the growing regions overlap during this process, the union of these regions is sufficient and does not affect the final result.

[0077] Each of the above traversals obtains the effective area of ​​a corresponding particle, and the set of effective defect areas I4 constitutes the effective defect area.

[0078] The quality of the surface I1 to be tested can be determined based on the obtained effective defect areas I4 by corresponding program settings or manual visual inspection. The present application also develops a subsequent step of determining the quality grade I5 of the surface I1 to be tested based on the number and / or area of ​​the effective defect areas I4 on the surface I1 to be tested.

[0079] According to the actual production situation, this application provides a method for determining the quality of the surface I1 to be measured. First, N defect area levels are determined, and the defect area level S j Arrange them in ascending order according to the proportion of defect area they contain, where j is the sorting ordinal number; at the same time, determine N defect quantity levels, defect quantity level M i Arrange them in ascending order according to the number of defects they contain, where i is the sorting number; then, count the area sum of all effective defect areas I4 on the surface to be tested I1, and calculate the proportion S of the area sum in the area of ​​the 2D depth map I3; the statistical area is greater than the area threshold t s The number of effective defect areas I4 is M; then the defect area level S of the surface to be tested I1 is j By S∈[S j·min ,S j·max ] Determine the defect quantity level M of the surface I1 to be tested i By M∈[M i·min ,M i·max ] Determine, where S j·min S is the defect area gradej The lower limit of the range, S j·max S is the defect area grade j The upper limit of the range, M i·min is the defect area grade M i The lower limit of the range, M i·max S is the defect area grade j The upper limit of the range; the quality level Q of the surface I1 to be measured is Q=max{S j ,M i}.

[0080] For example, the plan is to categorize plate quality into three levels: normal, slightly defective, and severely defective. The ratio of plate particle area to total plate area is divided into three ascending levels: [0, d2), [d2, d1), and [d1, 1]. The number of defective particles is divided into three ascending levels: [0, n2), [n2, n1), and [n1, +∞). The actual plate quality is determined by the larger of the ratio of plate particle area to total plate area and the number of defective particles, whichever is greater, as the final plate quality grade, Q.

[0081] For example, in actual production, d1=2.5, d2=1.2, n1=200, n2=80, t s =9. For area greater than the threshold t s =9, we get 366 valid defect areas I4 that meet the conditions, which means that the number of defective particles on the plate surface that meet the requirements is 366, which is in the range of [200, +∞). Therefore, no matter in which area interval the ratio of the plate particle area to the total plate area is, the plate is severely defective.

[0082] The present invention also discloses a computer-readable storage medium storing a computer program. When the computer program is executed by a processor, the processor executes the steps of the above method.

[0083] It is understandable that the system provided by the embodiment of the present invention corresponds to the method provided by the embodiment of the present invention, and the explanation, examples and beneficial effects of the relevant contents can refer to the corresponding parts of the above method.

[0084] Those skilled in the art will appreciate that the embodiments of the present application can be provided as methods, systems, or computer program products. Therefore, the present application can adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application can adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) that contain computer-usable program code.

[0085] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the steps in the process. Figure 1 a process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0086] These computer program instructions may also be stored in a computer readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 a process or multiple processes and / or boxes Figure 1 The function specified in one or more boxes.

[0087] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operational steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing the instructions executed on the computer or other programmable device for implementing the process. Figure 1 a process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.

[0088] The above content only describes the preferred embodiments of the present invention and does not limit the scope of the present invention. Without departing from the design spirit of the present invention, various modifications and improvements made to the technical solution of the present invention by ordinary technicians in this field should fall within the scope of protection determined by the claims of the present invention.

Claims

1. A surface particle defect detection method, characterized in that: The following steps are involved: Obtain 3D point cloud data of the surface to be measured; Mapping the 3D point cloud data into a 2D depth map; Performing contour analysis on the 2D depth map to determine a valid defect area; The step of performing contour analysis on the 2D depth map to determine the effective defect area further includes: Determine the candidate defect area step, performing contour connected domain extraction on the 2D depth map to obtain the candidate defect area of ​​the surface to be tested; a step of determining a preferred defect region, performing Gaussian curve fitting on the candidate defect region based on a Gaussian curve with a translation coefficient to obtain a preferred defect region of the surface to be measured; The effective defect area is determined by applying a watershed segmentation and region growing strategy that fuses the sub-regions to the preferred defect area to obtain the effective defect area.

2. The surface particle defect detection method according to claim 1, wherein: The step of determining the preferred defect area is: Traverse all the candidate defect areas and apply at least the following steps to each candidate defect area: Determine the fitting center point step, determine the maximum grayscale pixel point P of the candidate defect area; determine the row pixel arrangement RP and column pixel arrangement CP where the maximum grayscale pixel point P is located; Construct fitting function steps and construct fitting curve Wherein, a, b, c are fitting coefficients, and x0 is the corresponding coordinate value of the maximum grayscale pixel point P; In the row fitting step, the least squares fitting is performed on the row pixel arrangement RP using the fitting curve, and the obtained fitting coefficients a, b, and c are respectively recorded as a r 、b r 、c r ; In the column fitting step, the least squares fitting is performed on the column pixel arrangement CP using the fitting curve, and the obtained fitting coefficients a, b, and c are respectively recorded as a c 、b c 、c c ; Candidate region determination step, for the preset grayscale threshold A g , if the fitting coefficient satisfies (a r <0 and a c <0) or (b r <0 and b c <0), the candidate defect area is excluded.

3. The surface particle defect detection method according to claim 2, wherein: In the row fitting step, the grayscale value of the minimum grayscale pixel in the row pixel arrangement RP is used as the fitting coefficient c r , using the fitted curve Perform least square fitting on the row pixel arrangement RP to obtain the fitting coefficient a r 、b r ; In the column fitting step, the grayscale value of the minimum grayscale pixel in the column pixel arrangement CP is used as the fitting coefficient c c , using the fitted curve Perform least square fitting on the column pixel arrangement CP to obtain the fitting coefficient a c 、b c .

4. The surface particle defect detection method according to claim 1, wherein: The step of determining the effective defect area is to traverse all the preferred defect areas and apply at least the following steps to each preferred defect area: The grayscale range determination step is to determine the maximum grayscale value t of the preferred defect area. max With the minimum gray value t min ; To determine the grayscale separation point step, press t g =max{(t max +t min ) / 2,t max -t b }Determine the segmentation grayscale preset value t g , where t b is the preset defect grayscale threshold; The region growing step is to grow the grayscale value in the preferred defect region greater than t g The pixel point of is used as a seed point for region growing to obtain the effective defect area corresponding to the preferred defect area.

5. The surface particle defect detection method according to claim 1, wherein: The step of mapping the 3D point cloud data into a 2D depth map further includes the following steps: Performing denoising on the 3D point cloud data to obtain preprocessed point cloud data; Interpolating the pre-processed point cloud data to map it into a 2D depth map; The step of interpolating the pre-processed point cloud data and mapping it into a 2D depth map comprises: A normalization processing step of linearly mapping the three-dimensional coordinate data of the pre-processed point cloud data in space to the length, width, and grayscale depth of the 2D depth map to obtain original mapping data; In the interpolation step, the original mapping data is converted into an initial depth map using nearest neighbor interpolation. The pixel points with zero grayscale value in the initial depth map are traversed, and the grayscale value of the pixel with zero grayscale value is overwritten with the grayscale value of the pixel with the maximum grayscale value in the small neighborhood to obtain a 2D depth map.

6. The surface particle defect detection method according to claim 5, wherein: The step of performing denoising on the 3D point cloud data to obtain pre-processed point cloud data comprises: In the plane fitting step, the 3D point cloud data is uniformly downsampled, and then a plane fitting is performed on the uniformly downsampled 3D point cloud data based on the RANSAC algorithm to obtain the plane equation; In the distance denoising step, points whose distances to the plane equation are greater than a preset distance threshold in the 3D point cloud data after uniform downsampling are removed to obtain the pre-processed point cloud data.

7. The surface particle defect detection method according to any one of claims 1 to 6, characterized in that: The surface particle defect detection method further comprises the step of determining the quality grade of the surface to be tested based on the number and / or area of ​​the effective defect regions of the surface to be tested; The step of determining the quality grade of the surface to be tested based on the number and / or area of ​​the effective defect regions of the surface to be tested is: Determine N defect area levels, defect area level S j Arrange in ascending order according to the proportion of defect area contained therein, where j is the sorting ordinal number; Determine N defect quantity levels, defect quantity level M i Arrange them in ascending order according to the number of defects they contain, where i is the sorting ordinal number; Counting the sum of the areas of all the effective defect regions on the surface to be measured, and calculating the proportion S of the sum of the areas in the area of ​​the 2D depth map; and counting the number M of the effective defect regions; Then the defect area level S of the surface to be measured is j By S∈[S j·min ,S j·max ] Determine the defect quantity level M of the surface to be tested i By M∈[M i·min ,M i·max ] Determine, where S j·min S is the defect area grade j The lower limit of the range, S j·max S is the defect area grade j The upper limit of the range, M i·min is the defect quantity level M i The lower limit of the range, M i·max is the defect quantity level S j The upper limit of the range; The quality level Q of the surface to be measured is Q=max{S j ,M i }.

8. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the processor is caused to perform the steps of the method according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • Method and device for detecting surface of weld joint of nuclear fuel rod

    CN109978865A

  • Method and device used for surface detection of cladding of nuclear rod

    CN110132975A

  • Semiconductor bump defect detection method, electronic equipment and storage medium

    CN112734760A

  • Online detection method and system for surface defects of additive manufacturing part

    CN113781585A

  • Concrete surface defect detection method and device, electronic equipment and storage medium

    CN113888531A