Nitride sphere surface defect detection method and system, electronic device and medium

The nitride sphere surface defect detection model established by the YOLOv3 network solves the problems of inefficiency and inaccuracy caused by manual detection of ceramic sphere surface defects, and realizes efficient and accurate automated detection.

CN116739993BActive Publication Date: 2025-11-21SINOMA ADVANCED NITRIDE CERAMICS CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310558397.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-05-16
Publication Date
2025-11-21
Estimated Expiration
2043-05-16

AI Technical Summary

Technical Problem

In existing technologies, the detection of surface defects in ceramic balls mainly relies on manual visual inspection, which is inefficient, inaccurate, and highly dependent on the experience of the inspectors.

Method used

A defect detection model for nitride spheres was established using the YOLOv3 network. By acquiring images, adding anchor boxes, calculating loss values, and determining the defect results, automated detection was performed using deep learning technology.

Benefits of technology

It improves the accuracy of defect identification, realizes automated, rapid and accurate detection of surface defects of ceramic balls, replaces traditional manual inspection, and reduces the possibility of false detection and missed detection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116739993B_ABST
    Figure CN116739993B_ABST
Patent Text Reader

Abstract

The application discloses a nitride sphere surface defect detection method and system, electronic equipment and medium, and relates to the technical field of defect detection. The method comprises the following steps: obtaining a defect area of a ceramic sphere surface to be detected; adding a plurality of anchor boxes to the defect area of the ceramic sphere surface to be detected; calculating a loss value of each anchor box according to a loss function; obtaining a defect result of the ceramic sphere surface to be detected according to the loss value of each anchor box; and the defect detection model is obtained by training a YOLOv3 network with an image of a sample ceramic sphere surface as input and true center coordinate values, a true height, a true width and a true confidence of a candidate box corresponding to a defect area of the sample ceramic sphere surface as output. The application can improve the accuracy of defect recognition.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The application relates to the technical field of defect detection, in particular to a nitride sphere surface defect detection method and system, electronic equipment and a medium. BACKGROUND

[0002] Ceramic ball bearings are a typical example of the wide application of engineering ceramics in the industrial field, and are highly valued. Ceramic ball bearings with nitride ceramic balls as rolling elements can significantly improve bearing life and greatly expand the application field of rolling bearings. Since the formation and expansion of ceramic ball surface defects are related to many factors such as the forming process of the ball blank, the machining process and the use conditions, further research on the formation and expansion mechanism of ceramic ball surface defects should be carried out on the basis of existing research, the factors affecting the surface quality of ceramic balls should be analyzed, the processing quality should be improved, the ceramic ball surface defects should be reasonably classified, and the automatic detection technology of ceramic ball surface defects should be researched.

[0003] At present, the evaluation of the surface quality of ceramic balls is mainly completed by manual visual inspection, which not only has low detection efficiency and high work intensity, but also has the problems of non-uniform evaluation standard and high dependence on the experience of detection personnel, resulting in inaccurate evaluation results. SUMMARY

[0004] The purpose of the application is to provide a nitride sphere surface defect detection method, system, electronic equipment and medium, which can improve the accuracy of defect recognition.

[0005] To achieve the above purpose, the application provides the following scheme:

[0006] A nitride sphere surface defect detection method, comprising:

[0007] obtaining an image of a surface of a ceramic ball to be detected;

[0008] inputting the image of the surface of the ceramic ball to be detected into a defect detection model to obtain a defect area of the surface of the ceramic ball to be detected;

[0009] adding a plurality of anchor boxes to the defect area of the surface of the ceramic ball to be detected;

[0010] calculating a loss value of each anchor box according to a loss function;

[0011] determining a defect result of the surface of the ceramic ball to be detected according to the loss value of each anchor box; the defect result is defective or non-defective; the defect detection model is obtained by training a YOLOv3 network with an image of a surface of a sample ceramic ball as input and true center coordinate values, a true height, a true width and a true confidence of a candidate box corresponding to a defect area of the surface of the sample ceramic ball as output, and the surface of the sample ceramic ball has defects.

[0012] Optionally, the determination process of the defect detection model comprises:

[0013] acquiring images of surfaces of a plurality of sample ceramic balls;

[0014] processing the images of the surfaces of the sample ceramic balls using a noise reduction filtering algorithm to obtain processed images;

[0015] performing threshold segmentation on the processed images to obtain a ceramic image sample set;

[0016] labeling real center coordinate values, real heights, real widths, and real confidence of candidate boxes corresponding to defect regions of each image in the ceramic image sample set to obtain a defect feature dataset;

[0017] training a YOLOv3 network using the defect feature dataset with a loss function minimization objective to obtain a defect detection model.

[0018] Optionally, the processing of the images of the surfaces of the sample ceramic balls using a noise reduction filtering algorithm to obtain processed images specifically comprises:

[0019] processing the images of the surfaces of the sample ceramic balls using a noise reduction filtering algorithm based on frequency domain filtering to obtain processed images.

[0020] A nitride sphere surface defect detection system comprises:

[0021] a first acquisition module configured to acquire an image of a surface of a ceramic ball to be detected;

[0022] a defect region determination module configured to input the image of the surface of the ceramic ball to be detected into a defect detection model to obtain a defect region of the surface of the ceramic ball to be detected;

[0023] an anchor box addition module configured to add a plurality of anchor boxes to the defect region of the surface of the ceramic ball to be detected;

[0024] an anchor box loss value calculation module configured to calculate a loss value of each anchor box according to a loss function;

[0025] a defect detection module configured to determine a defect result of the surface of the ceramic ball to be detected according to the loss value of each anchor box; the defect result is either defective or not defective; the defect detection model is obtained by training a YOLOv3 network using images of surfaces of sample ceramic balls as input and real center coordinate values, real heights, real widths, and real confidence of candidate boxes corresponding to defect regions of the surfaces of the sample ceramic balls as output, wherein the surfaces of the sample ceramic balls have defects.

[0026] Optionally, the nitride sphere surface defect detection system further comprises:

[0027] a second acquisition module, configured to acquire images of surfaces of a plurality of sample ceramic balls;

[0028] a noise reduction module, configured to process the images of the surfaces of the sample ceramic balls by using a noise reduction filtering algorithm to obtain processed images;

[0029] a segmentation module, configured to perform threshold segmentation on the processed images to obtain a ceramic image sample set;

[0030] a labeling module, configured to label real center coordinate values, real heights, real widths and real confidence levels of candidate boxes corresponding to defect areas of images in the ceramic image sample set to obtain a defect feature data set;

[0031] a training module, configured to train a YOLOv3 network by using the defect feature data set to obtain a defect detection model, with a loss function minimum as a target.

[0032] Optionally, the noise reduction module specifically comprises:

[0033] a noise reduction unit, configured to process the images of the surfaces of the sample ceramic balls by using a noise reduction filtering algorithm based on frequency domain filtering to obtain the processed images.

[0034] An electronic device comprises:

[0035] a memory and a processor, the memory being configured to store a computer program, and the processor being configured to run the computer program to enable the electronic device to perform the nitride ball surface defect detection method.

[0036] A computer readable storage medium stores a computer program, and the computer program is executed by a processor to implement the nitride ball surface defect detection method.

[0037] According to the embodiments of the present application, the following technical effects are achieved: the defect detection model is used to detect whether the ceramic ball surface has defects, and human detection is not required, and the accuracy of defect recognition can be improved. BRIEF DESCRIPTION OF DRAWINGS

[0038] In order to more clearly illustrate the technical solutions of the embodiments of the present application or the prior art, the drawings needed in the embodiments will be briefly introduced. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor.

[0039] Figure 1A nitride sphere surface defect detection method flowchart provided for an embodiment of the present application is shown in the figure;

[0040] Figure 2 A structural schematic diagram of a machine vision hardware platform provided for an embodiment of the present application is shown in the figure;

[0041] Figure 3 A ceramic sphere surface image is shown in the figure.

[0042] Figure 4 A feature map obtained by inputting the ceramic sphere surface image into a YOLOv3 network is shown in the figure.

[0043] Symbol explanation:

[0044] Area array camera - 1, lens - 2, optical illumination system - 3, fixed support - 4, measured object - 5. DETAILED DESCRIPTION

[0045] The technical solutions in the embodiments of the present application will be described clearly and completely below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative labor fall within the scope of protection of the present application.

[0046] In order to make the above-mentioned purposes, features and advantages of the present application more obvious and easy to understand, the present application will be further described in detail below with reference to the drawings and specific embodiments.

[0047] In view of the fact that traditional manual visual inspection and previous automatic detection equipment are not suitable for ceramic material spheres, the present embodiment provides a surface defect detection method for nitride spheres based on a YOLOv3 network. The present application adopts a machine vision detection method, establishes a silicon nitride ceramic sphere surface defect detection model based on deep learning target detection network technology, designs an automatic real-time detection technology for ceramic sphere surface defects, has the characteristics of real-time detection of surface defects, high recognition accuracy, and rapid detection and accurate positioning of surface defects, can replace traditional manual detection methods, and meets the demand for automatic detection of ceramic sphere defects.

[0048] As shown in the figure, Figure 1 The present application provides a nitride sphere surface defect detection method, which comprises:

[0049] An image of a ceramic sphere surface to be detected is obtained.

[0050] The image of the ceramic sphere surface to be detected is input into a defect detection model to obtain a defect area of the ceramic sphere surface to be detected.

[0051] A plurality of anchor boxes are added to the defect area of the ceramic sphere surface to be detected.

[0052] According to the loss function, the loss value of each anchor frame is calculated.

[0053] According to the loss value of each anchor frame, a defect result of the ceramic ball surface to be detected is determined; the defect result is defective or non-defective; the defect detection model is obtained by training a YOLOv3 network with an image of a sample ceramic ball surface as input and real center coordinate values, real heights, real widths and real confidence of a candidate frame corresponding to a defect area of the sample ceramic ball surface as output, and the sample ceramic ball surface has defects.

[0054] In actual application, the determination process of the defect detection model comprises:

[0055] Obtain images of a plurality of sample ceramic ball surfaces.

[0056] Process the images of each sample ceramic ball surface using a noise reduction filtering algorithm to obtain processed images.

[0057] Perform threshold segmentation on each processed image to obtain a ceramic image sample set.

[0058] Label real center coordinate values, real heights, real widths and real confidence of a candidate frame corresponding to a defect area of each image in the ceramic image sample set to obtain a defect feature data set.

[0059] Train the YOLOv3 network using the defect feature data set to obtain the defect detection model, with the minimum loss function as the target.

[0060] In actual application, the specific operation of obtaining an image is based on a machine vision hardware platform to collect an image, as shown in Figure 2 The machine vision hardware platform comprises a plane array camera 1, a lens 2, an optical illumination system 3 and a fixed support 4, wherein the plane array camera 1 is connected with the lens 2 and is installed vertically above a measured object 5, the optical illumination system 3 is placed between the measured object 5 and the lens 2, the central axes of the plane array camera 1, the lens 2 and the optical illumination system 3 substantially coincide with the central axis of the measured object 5, and a ceramic ball surface image is collected by the plane array camera 1 to obtain a spherical image.

[0061] In actual application, the processing of the images of each sample ceramic ball surface using a noise reduction filtering algorithm to obtain processed images specifically comprises:

[0062] The images of each sample ceramic ball surface are processed using a noise reduction filtering algorithm based on frequency domain filtering to obtain processed images.

[0063] The embodiment of the application provides a more specific surface defect detection method for a nitride ball:

[0064] 1、based on Figure 2 The machine vision hardware platform shown in the middle collects the defect sample image of the ceramic ball, and the obtained result is shown in Figure 3 The main concern is the image of the defect area on the surface of the sample ceramic ball.

[0065] 2、The ceramic ball image is preprocessed. The defect sample image is processed by using a noise reduction filtering algorithm based on frequency domain filtering to reduce the interference of noise points on defect detection. Then the image sample is grayed, a threshold segmentation algorithm is used, and a suitable gray threshold is selected to segment and extract the detection area from the image background. The segmented detection area image is scaled and saved as an image sample to establish a ceramic ball image sample set.

[0066] 3、The defect area in the ceramic ball image in the ceramic ball image sample set is manually labeled by using LabelImg software, and the position area and defect label of the defect are marked. The labeling adopts a rectangular frame mode, and the coordinates of the four corners of the rectangular frame represent the position of the defect area. A defect feature data set is established, and the coordinates are represented as a ij , b ij , c ij , d ij , i=1,2,3…n represents the serial number of the image sample, and j=1,2,3…n represents the serial number of the labeled frame in the same image sample.

[0067] 4、Based on the defect feature data set, the sample image with defect labeling information is input into the convolutional neural network for feature extraction. Here, Darknet53 network of YOLOv3 is used to extract the ceramic ball defect feature map. Part of the feature map is shown in Figure 4 After the image is processed by the convolutional network of different layers, feature maps of different sizes can be obtained, as shown in Figure 4 (a)、 Figure 4 (b)、 Figure 4 (c) and Figure 4 (d). After the input image is processed by the convolution of the main network Darknet53 network of YOLOv3, multiple size feature maps can be obtained, and then a specific size feature map is output according to the detection requirement. A single pixel in the image represents a size of 16 μm, and the size of the main defect is about 200-1000 μm. Moreover, the size of the feature map is generally 2 n pixels, so according to the size of the input image and the size characteristics of the main defect type, the present application finally selects three sizes of feature map shapes, which are 16*16, 32*32 and 64*64. The image is divided into 16*16, 8*8 and 4*4 grids, so that each image sample contains a total of 336 prediction anchor frames, and the center coordinate value, width, height and confidence of each prediction anchor frame are obtained.

[0068] 5、Based on the above selected prediction anchor frame, the loss function of YOLOv3 network is calculated, and the gradient descent method is used for loss function calculation, as shown in formula (1), and the learning rate is set to iterate and optimize, when the optimal solution of the loss function reaches the set range, it represents that the network has converged, the training process is stopped, the ceramic ball surface defect detection model weight is obtained, and the defect detection model construction process based on YOLOv3 network is completed;

[0069]

[0070] Formula (1) is the loss function of YOLOv3 network, wherein λ coord is the bias coefficient, wherein S is the grid size, B represents the prediction candidate frame contained in each grid, i represents the i-th grid on the image, j represents the j-th candidate frame on the grid, indicates whether the candidate frame is responsible for predicting the target, responsible If not responsible, then represent the center coordinate value of each prediction candidate frame, indicates the real center coordinate value of the candidate frame, and represent the width and height of the prediction candidate frame, and represent the real width and real height of the candidate frame, represent the confidence of the prediction candidate frame, represent the real confidence of the candidate frame.

[0071] 6、Based on the machine vision hardware platform, the ceramic ball surface image to be detected is collected, and the same preprocessing algorithm as used in step 2 is used for the training image to perform noise reduction, scaling and detection area demarcation and other preprocessing operations on the sample image to be detected.

[0072] 7、16*16、32*32 and 64*64 three kinds of anchor frame size, the detection area image is divided into 336 prediction anchor frames, a certain number of candidate frames are selected in each anchor frame, based on the defect detection model weight value obtained by training, the loss value of all selected candidate frames in each anchor frame is calculated by using formula (1) loss function, each candidate frame can obtain five values of x, y, w, h and C at the minimum loss value, wherein x, y, w and h are the center coordinates, width and height of the candidate frame, the four corner coordinates of the candidate frame can be converted, and C is the prediction confidence, that is, the probability value of the candidate frame area being a defect, the greater the probability value represents the greater the possibility of the target found by the network being a defect.

[0073] 8. Statistics of all anchor frame prediction results, calculate the size relationship between each anchor frame defect probability value and the set probability threshold parameter, if there is an anchor frame higher than the threshold value, it represents that the ceramic ball to be detected contains surface defects, output the value "1", which represents the defective ball; otherwise, there is no surface defect, output the value "0", which represents the normal ball without damage, output and store the detection results of the ball.

[0074] The application provides a nitride ball surface defect detection system for the above-mentioned embodiment, comprising:

[0075] The first acquisition module is configured to acquire an image of a ceramic ball to be detected.

[0076] The defect area determination module is configured to input the image of the ceramic ball to be detected into a defect detection model to obtain a defect area of the ceramic ball to be detected.

[0077] The anchor frame addition module is configured to add a plurality of anchor frames to the defect area of the ceramic ball to be detected.

[0078] The anchor frame loss value calculation module is configured to calculate a loss value of each anchor frame according to a loss function.

[0079] The defect detection module is configured to determine a defect result of the ceramic ball to be detected according to the loss value of each anchor frame; the defect result is defective or not defective; the defect detection model is obtained by training a YOLOv3 network with an image of a sample ceramic ball surface as input and real center coordinate values, real heights, real widths and real confidence of a candidate frame corresponding to a defect area of the sample ceramic ball surface as output, and the sample ceramic ball surface has defects.

[0080] As an optional implementation, the nitride ball surface defect detection system further comprises:

[0081] The second acquisition module is configured to acquire images of a plurality of sample ceramic ball surfaces.

[0082] The noise reduction module is configured to process the images of the sample ceramic ball surfaces to obtain processed images by using a noise reduction filtering algorithm.

[0083] The segmentation module is configured to perform threshold segmentation on the processed images to obtain a ceramic image sample set.

[0084] The labeling module is configured to label real center coordinate values, real heights, real widths and real confidence of a candidate frame corresponding to a defect area of each image in the ceramic image sample set to obtain a defect feature data set.

[0085] The training module is configured to train the YOLOv3 network by using the defect feature dataset to obtain a defect detection model.

[0086] As an optional implementation, the noise reduction module specifically comprises:

[0087] The noise reduction unit is configured to process the image of the surface of each sample ceramic ball by using a noise reduction filtering algorithm based on frequency domain filtering to obtain a processed image.

[0088] The embodiment of the present application further provides an electronic device, comprising:

[0089] The memory is configured to store a computer program, and the processor is configured to execute the computer program to enable the electronic device to perform the nitride ball surface defect detection method according to the above-mentioned embodiments.

[0090] The embodiment of the present application further provides a computer readable storage medium, which stores a computer program, and the computer program is executed by a processor to implement the nitride ball surface defect detection method according to the above-mentioned embodiments.

[0091] The present application replaces the traditional manual method for detecting defects on the surface of nitride ceramic balls, has high detection efficiency and strong stability, effectively eliminates the defect omission and misjudgment caused by factors such as working environment, experience deviation and fatigue state of the detection personnel, and improves the accuracy of the detection result.

[0092] The embodiments in the specification are described in a progressive manner, and each embodiment focuses on the difference from other embodiments, and the same or similar parts of each embodiment can be referred to each other.

[0093] The principles and implementation modes of the present application are described by using specific examples in this paper, and the above embodiment description is only used to help understand the method of the present application and its core idea; meanwhile, for those skilled in the art, according to the idea of the present application, the specific implementation mode and application range will be changed. In conclusion, the content of the specification should not be understood as a limitation of the present application.

Claims

1. A method for detecting surface defects of nitride spheres, characterized in that, include: Acquire an image of the surface of the ceramic sphere to be inspected; The image of the surface of the ceramic ball to be detected is input into the defect detection model to obtain the defect area on the surface of the ceramic ball to be detected; Multiple anchor frames are added to the defect area on the surface of the ceramic ball to be tested; Calculate the loss value for each anchor frame based on the loss function; The defect results on the surface of the ceramic ball to be tested are determined based on the loss value of each anchor frame; The defect result is either that there is a defect or that there is no defect; The defect detection model is obtained by training a YOLOv3 network with an image of the sample ceramic ball surface as input and the true center coordinates, true height, true width, and true confidence of the candidate boxes corresponding to the defect areas on the sample ceramic ball surface as output. The sample ceramic ball surface has defects. The process of determining the defect detection model includes: Acquire images of the surfaces of multiple sample ceramic spheres; The images of the surface of each of the sample ceramic spheres were processed using a noise reduction filtering algorithm to obtain the processed images; The processed images are subjected to threshold segmentation to obtain a ceramic image sample set; The defect feature dataset is obtained by annotating the true center coordinates, true height, true width, and true confidence of the candidate boxes corresponding to the defect regions of each image in the ceramic image sample set. A defect detection model is obtained by training the YOLOv3 network with a defect feature dataset to minimize the loss function.

2. The method for detecting surface defects of nitride spheres according to claim 1, characterized in that, The process of using a noise reduction filtering algorithm to process the images of the surface of each of the sample ceramic spheres to obtain the processed images specifically includes: A noise reduction filtering algorithm based on frequency domain filtering is used to process the images of the surface of each sample ceramic ball to obtain the processed image.

3. A nitride sphere surface defect detection system, characterized in that, include: The second acquisition module is used to acquire images of the surface of multiple sample ceramic spheres; The noise reduction module is used to process the images of the surface of each of the sample ceramic spheres using a noise reduction filtering algorithm to obtain the processed images; The segmentation module is used to perform threshold segmentation on each of the processed images to obtain a ceramic image sample set; The annotation module is used to annotate the true center coordinates, true height, true width, and true confidence of the candidate boxes corresponding to the defect regions of each image in the ceramic image sample set to obtain a defect feature dataset; The training module is used to train the YOLOv3 network with the defect feature dataset to obtain a defect detection model with the goal of minimizing the loss function. The first acquisition module is used to acquire an image of the surface of the ceramic ball to be detected; The defect region determination module is used to input the image of the surface of the ceramic ball to be detected into the defect detection model to obtain the defect region of the surface of the ceramic ball to be detected; An anchor frame adding module is used to add multiple anchor frames to the defect area on the surface of the ceramic ball to be inspected; The anchor frame loss value calculation module is used to calculate the loss value of each anchor frame according to the loss function; The defect detection module is used to determine the defect result on the surface of the ceramic ball to be detected based on the loss value of each anchor frame; The defect result is either that there is a defect or that there is no defect; The defect detection model is obtained by training a YOLOv3 network with an image of the sample ceramic ball surface as input and the true center coordinates, true height, true width, and true confidence of the candidate boxes corresponding to the defect areas on the sample ceramic ball surface as output. The sample ceramic ball surface has defects.

4. The nitride sphere surface defect detection system according to claim 3, characterized in that, The noise reduction module specifically includes: The noise reduction unit is used to process the image of the surface of each of the sample ceramic balls using a noise reduction filtering algorithm based on frequency domain filtering to obtain the processed image.

5. An electronic device, characterized in that, include: A memory and a processor, the memory being used to store a computer program, the processor running the computer program to cause the electronic device to perform the nitride sphere surface defect detection method according to any one of claims 1 to 2.

6. A computer-readable storage medium, characterized in that, It stores a computer program that, when executed by a processor, implements the method for detecting defects on the surface of nitride spheres as described in any one of claims 1 to 2.

Citation Information

Patent Citations

  • Photovoltaic panel defect detection method based on deep neural network

    CN110517224A

  • Bathroom ceramic surface defect detection method and device based on deep learning

    CN110826416A