Component defect detection method and device, electronic equipment and storage medium
By extracting and fitting curve analysis of the measured blurred images of components, combined with standard clear images, the problem of low accuracy and efficiency of component defect detection in the prior art is solved, and higher detection accuracy and efficiency are achieved .
Patent Information
- Application Number
- CN202411003120.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-25
- Publication Date
- 2024-11-29
AI Technical Summary
In the prior art, the accuracy of component defect detection is poor and the efficiency is low. It is easy to cause the normal product to be misjudged as a defect due to misjudgment of blurred images, which increases the workload of manual re-judgment.
By obtaining the measured blurred image of the component to be detected, performing feature extraction to generate a thermal image, determining the sampling line of the thermal image, using a skewed distribution function to fit the average pixel value, and combining the fitting curve of the standard clear image to judge the defects of the component Test results.
It improves the accuracy of component defect detection, reduces the workload of manual re-judgement, and improves detection efficiency.
Smart Images

Figure CN119048431A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer vision technology, and in particular to a method, device, electronic device and storage medium for component defect detection. Background Art
[0002] In a highly automated production line, if there are defective components in the PCB board, it may become the fuse of product failure, trigger a chain reaction, and produce more serious quality problems, which in turn will cause consumer dissatisfaction and complaints, seriously damaging the company's reputation and brand image. Therefore, it is very important to accurately detect defects in components in PCB boards.
[0003] In the prior art, the image of the component to be inspected is generally compared with the image of the normal component based on the dimensions of the image such as color, gradient and contour, and an empirical threshold is set to determine whether the component has a defect. If there is a defect, manual re-judgment is performed. This strategy is often relatively simple, and the high threshold set to reduce the missed detection rate may cause normal products to be misjudged. Due to reasons such as high object occlusion and camera focusing, the imaging of some component images will be blurred. In the prior art, the components in the blurred image will be directly judged as defective components, and subsequent re-judgment will be performed. There are cases where normal components are misjudged as defective components, which makes the accuracy of component defect detection poor, and increases the workload of manual re-judgment. Manual re-judgment takes a long time, which reduces the efficiency of component defect detection. Summary of the invention
[0004] The present application provides a method, device, electronic device and storage medium for detecting component defects, so as to solve the problems of poor accuracy and low efficiency in detecting component defects in the prior art.
[0005] In a first aspect, the present application provides a method for detecting component defects, the method comprising:
[0006] Acquire a measured fuzzy image of the component to be inspected, perform feature extraction on the measured fuzzy image, and obtain an eigenvalue matrix corresponding to the measured fuzzy image; generate a thermal image corresponding to the measured fuzzy image according to the eigenvalue matrix;
[0007] Determine each sampling line of the thermal image; for each sampling line, determine the average pixel value of the sampling line according to the pixel value of each pixel point on the sampling line;
[0008] Using a skewed distribution function to fit the average pixel value of each sampling line, to obtain a first fitting curve corresponding to the measured blurred image;
[0009] Acquire a standard clear image corresponding to the measured blurred image, and determine a second fitting curve corresponding to the standard clear image by using the same processing rule;
[0010] The defect detection result of the component to be detected is determined according to the positional relationship between the first fitting curve and the second fitting curve.
[0011] In a second aspect, the present application provides a device for detecting component defects, the device comprising:
[0012] A first determination module is used to obtain a measured fuzzy image of the component to be detected, perform feature extraction on the measured fuzzy image, and obtain an eigenvalue matrix corresponding to the measured fuzzy image; and generate a thermal image corresponding to the measured fuzzy image according to the eigenvalue matrix;
[0013] A second determination module is used to determine each sampling line of the thermal image; for each sampling line, according to the pixel value of each pixel point on the sampling line, determine the average pixel value of the sampling line;
[0014] A third determination module is used to fit the average pixel value of each sampling line by using a skewed distribution function to obtain a first fitting curve corresponding to the measured blurred image;
[0015] A fourth determination module is used to obtain a standard clear image corresponding to the measured blurred image, and determine a second fitting curve corresponding to the standard clear image by using the same processing rule;
[0016] The detection module is used to determine the defect detection result of the component to be detected according to the positional relationship between the first fitting curve and the second fitting curve.
[0017] In a third aspect, the present application provides an electronic device, including a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other via the communication bus;
[0018] Memory, used to store computer programs;
[0019] The processor is used to implement the method steps when executing the program stored in the memory.
[0020] In a fourth aspect, the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method steps described are implemented.
[0021] The above technical solution has the following advantages or beneficial effects:
[0022] The present application provides a solution for component defect detection based on a measured fuzzy image of a component to be detected. First, feature extraction is performed on the measured fuzzy image to obtain an eigenvalue matrix corresponding to the measured fuzzy image, and then a thermal image is generated according to the eigenvalue matrix; each sampling line of the thermal image is determined; and the average pixel value of each sampling line is fitted using a skewed distribution function to obtain a first fitting curve. A standard clear image of a defect-free component corresponding to the measured fuzzy image is obtained, and a second fitting curve corresponding to the standard clear image is determined using the same processing rule. The positional relationship between the first fitting curve and the second fitting curve can reflect the consistency of the high-dimensional data distribution of the measured fuzzy image and the standard clear image. If the consistency of the high-dimensional data distribution of the measured fuzzy image and the standard clear image is high, it can be determined that the component in the measured fuzzy image is defect-free, otherwise it is determined that there is a defect. Therefore, the present application determines the defect detection result of the component to be detected according to the positional relationship between the first fitting curve and the second fitting curve. Compared with the solution of directly determining that the component in the fuzzy image is a defective component in the prior art, the accuracy of component defect detection is improved, the workload of manual re-judgment is reduced, and the efficiency of component defect detection is improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0023] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0024] Figure 1 A schematic diagram of the first component defect detection process provided by this application;
[0025] Figure 2 A schematic diagram of the second component defect detection process provided by this application;
[0026] Figure 3 A schematic diagram of the feature extraction network model structure provided for this application;
[0027] Figure 4 A schematic diagram of the third component defect detection process provided by this application;
[0028] Figure 5 A schematic diagram of the fourth component defect detection process provided by this application;
[0029] Figure 6 A schematic diagram of the fifth component defect detection process provided by this application;
[0030] Figure 7A schematic diagram of the sixth component defect detection process provided by this application;
[0031] Figure 8 It is a flow chart of component defect detection in the prior art;
[0032] Fig. 9 Component defect detection flow chart provided for this application;
[0033] Fig.10 Schematic diagram of blurred image and clear image provided for this application;
[0034] Fig.11 Schematic diagram of thermal image visualization provided for this application;
[0035] Fig.12 A schematic diagram of sampling lines in the horizontal and vertical directions in the thermal image provided by this application;
[0036] Fig.13 A schematic diagram of a measured lateral fitting curve obtained by fitting the lateral group data of the measured blurred image provided in the present application;
[0037] Fig.14 A schematic diagram of the positional relationship between the measured lateral fitting curve and the standard lateral fitting curve provided in this application;
[0038] Fig.15 A schematic diagram of the structure of the device for component defect detection provided in this application;
[0039] Fig.16 This is a schematic diagram of the electronic device structure provided in this application. DETAILED DESCRIPTION
[0040] In order to make the purpose and implementation method of the present application clearer, the exemplary implementation method of the present application will be clearly and completely described below in conjunction with the drawings in the exemplary embodiments of the present application. Obviously, the described exemplary embodiments are only part of the embodiments of the present application, rather than all the embodiments.
[0041] It should be noted that the brief description of terms in this application is only for the convenience of understanding the embodiments described below, and is not intended to limit the embodiments of this application. Unless otherwise specified, these terms should be understood according to their common and usual meanings.
[0042] The terms "first", "second", "third", etc. in the specification and claims of this application and the above drawings are used to distinguish similar or similar objects or entities, and do not necessarily mean to limit a specific order or sequence, unless otherwise noted. It should be understood that the terms used in this way can be interchangeable under appropriate circumstances.
[0043] The terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover but not exclude inclusion, for example, a product or device comprising a list of components is not necessarily limited to all the components expressly listed but may include other components not expressly listed or inherent to such product or device.
[0044] The term "module" refers to any known or later developed hardware, software, firmware, artificial intelligence, fuzzy logic, or combination of hardware and / or software code that is capable of performing the functions associated with that element.
[0045] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit it. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein with equivalents. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present application.
[0046] For the convenience of explanation, the above description has been made in conjunction with specific embodiments. However, the above exemplary discussion is not intended to be exhaustive or limit the embodiments to the specific forms disclosed above. Based on the above teachings, various modifications and variations can be obtained. The selection and description of the above embodiments are to better explain the principles and practical applications, so that those skilled in the art can better use the embodiments and various different variations of the embodiments suitable for specific use considerations.
[0047] Figure 1 A schematic diagram of the first component defect detection process provided in this application, the process includes the following steps:
[0048] S101: Acquire a measured fuzzy image of a component to be inspected, perform feature extraction on the measured fuzzy image, and obtain an eigenvalue matrix corresponding to the measured fuzzy image; and generate a thermal image corresponding to the measured fuzzy image according to the eigenvalue matrix;
[0049] S102: Determine each sampling line of the thermal image; for each sampling line, determine the average pixel value of the sampling line according to the pixel value of each pixel point on the sampling line;
[0050] S103: fitting the average pixel value of each sampling line using a skewed distribution function to obtain a first fitting curve corresponding to the measured blurred image;
[0051] S104: Acquire a standard clear image corresponding to the measured blurred image, and determine a second fitting curve corresponding to the standard clear image using the same processing rule;
[0052] S105: Determine a defect detection result of the component to be detected according to the positional relationship between the first fitting curve and the second fitting curve.
[0053] The component defect detection method provided in the present application is applied to electronic equipment, which may be a terminal device such as a PC or a computer, or a server.
[0054] In the present application, the electronic device first obtains the measured fuzzy image of the components to be detected. Among them, for each type of components, the image of the type of components collected in real time by the camera arranged in the working scene is called the measured image, and there is a pre-saved standard clear image of the type of components, which is a pre-collected clear image of the defect-free type of components. For the measured images of the components collected by the camera in real time, the blurred measured images can be manually screened out as the measured fuzzy images, and the measured fuzzy images are sent to the electronic device. Optionally, the camera can send the measured images of the components collected in real time to the electronic device, and the electronic device calculates the clarity of the measured image for each measured image, and determines whether the measured image is a measured fuzzy image according to the clarity. Among them, the clarity of the measured image can be calculated by the Tenengrad gradient method, the Laplacian gradient method, the variance method, etc., and the clarity of the measured image can also be calculated by other clarity evaluation algorithms.
[0055] After the electronic device obtains the measured fuzzy image of the component to be tested, it extracts features from the measured fuzzy image to obtain an eigenvalue matrix corresponding to the measured fuzzy image. Optionally, the electronic device can extract features from the measured fuzzy image through algorithms such as the LBP algorithm (Local Binary Patterns), the HOG feature extraction algorithm (Histogram of Oriented Gradient), and the SIFT operator (Scale-invariant feature transform) to obtain an eigenvalue matrix corresponding to the measured fuzzy image. A thermal image corresponding to the measured fuzzy image is generated based on the eigenvalue matrix. Optionally, the eigenvalue matrix can be used as a pixel value matrix of the thermal image, thereby mapping the measured fuzzy image to a corresponding visualized thermal image.
[0056] Determine each sampling line of the thermal image. Optionally, the direction and number of the sampling lines can be preset. The direction of the sampling lines is, for example, horizontal, vertical, or oblique at any angle of the thermal image. The number of sampling lines is, for example, 100, 200, etc. According to the preset direction and number of sampling lines, each sampling line of the thermal image is determined in a uniform or non-uniform manner.
[0057] For each sampling line, the pixel value of each pixel point on the sampling line in the thermal image is obtained, and then the average value of the pixel values of each pixel point on the sampling line is calculated as the average pixel value of the sampling line. In this way, the average pixel value of each sampling line can be obtained. The skewed distribution function is used to fit the average pixel value of each sampling line to obtain the first fitting curve corresponding to the measured blurred image.
[0058] The electronic device obtains a standard clear image corresponding to the measured blurred image. Specifically, according to the category of the component to be detected, a pre-saved standard clear image of the category is obtained, and the standard clear image is used as the standard clear image corresponding to the measured blurred image. Then the same processing rule is used to determine the second fitting curve corresponding to the standard clear image. The same processing rule refers to the same rule as the rule for determining the eigenvalue matrix corresponding to the measured blurred image to determine the eigenvalue matrix corresponding to the standard clear image; the same rule as the rule for generating the thermal image corresponding to the measured blurred image to generate the thermal image corresponding to the standard clear image; the same rule as the rule for determining the sampling lines of the thermal image corresponding to the measured blurred image to determine the sampling lines of the thermal image corresponding to the standard clear image; and then the same rule as the rule for obtaining the first fitting curve corresponding to the measured blurred image to obtain the second fitting curve corresponding to the standard clear image.
[0059] In the same coordinate system, the positional relationship between the first fitting curve and the second fitting curve is determined. The defect detection result of the component to be detected is determined according to the positional relationship between the first fitting curve and the second fitting curve. Optionally, the overlap between the first fitting curve and the second fitting curve can be determined according to the positional relationship between the first fitting curve and the second fitting curve. If the overlap is greater than a set overlap threshold, the defect detection result of the component to be detected is determined to be non-defective, otherwise, the defect detection result of the component to be detected is determined to be defective.
[0060] The present application provides a solution for component defect detection based on a measured fuzzy image of a component to be detected. First, feature extraction is performed on the measured fuzzy image to obtain an eigenvalue matrix corresponding to the measured fuzzy image, and then a thermal image is generated according to the eigenvalue matrix; each sampling line of the thermal image is determined; and the average pixel value of each sampling line is fitted using a skewed distribution function to obtain a first fitting curve. A standard clear image of a defect-free component corresponding to the measured fuzzy image is obtained, and a second fitting curve corresponding to the standard clear image is determined using the same processing rule. The positional relationship between the first fitting curve and the second fitting curve can reflect the consistency of the high-dimensional data distribution of the measured fuzzy image and the standard clear image. If the consistency of the high-dimensional data distribution of the measured fuzzy image and the standard clear image is high, it can be determined that the component in the measured fuzzy image is defect-free, otherwise it is determined that there is a defect. Therefore, the present application determines the defect detection result of the component to be detected according to the positional relationship between the first fitting curve and the second fitting curve. Compared with the solution of directly determining that the component in the fuzzy image is a defective component in the prior art, the accuracy of component defect detection is improved, the workload of manual re-judgment is reduced, and the efficiency of component defect detection is improved.
[0061] In order to improve the intelligence and accuracy of obtaining the measured fuzzy image of the component to be detected, in the present application, the method of obtaining the measured fuzzy image of the component to be detected includes:
[0062] Acquire the measured image of the component to be detected and the description parameter information of the component to be detected;
[0063] If the clarity of the measured image is less than a preset clarity threshold, and it is determined according to the description parameter information that the component to be detected is a component without pins and silk screen information, the measured image is used as the measured blurred image.
[0064] The electronic device first obtains the measured image of the component to be detected, and saves the description parameter information of the component to be detected in advance, including the name, type, whether it contains pins, whether it contains silk screen information, etc. of the component to be detected. Silk screen information includes information such as numbers, letters, and characters. The electronic device obtains the description parameter information of the component to be detected.
[0065] The electronic device calculates the clarity of the measured image by using the Tenengrad gradient method, Laplacian gradient method, variance method, other clarity evaluation algorithms, etc. It is determined whether the clarity of the measured image is less than a preset clarity threshold. If not, it is determined that the measured image is not a measured blurred image. If yes, it is determined whether the component to be detected is a component without pins and silk screen information according to the description parameter information. If not, it is determined that the measured image is not a measured blurred image. If yes, it is determined that the measured image is a measured blurred image.
[0066] The present application uses the measured images of components whose clarity is less than a preset clarity threshold and which do not contain pins or silk-screen information as measured blurred images. On the one hand, this improves the intelligence and accuracy of obtaining the measured blurred images of the components to be inspected. On the other hand, the present application uses a skewed distribution function to perform component defect detection. The accuracy of the measured blurred images that do not contain pins or silk-screen information is higher and the effect is better, thereby improving the accuracy of component defect detection.
[0067] Figure 2 A schematic diagram of the second component defect detection process provided in this application, the process includes the following steps:
[0068] S201: Acquire a measured image of a component to be detected and description parameter information of the component to be detected; if the clarity of the measured image is less than a preset clarity threshold, and it is determined according to the description parameter information that the component to be detected is a component without pins and silk screen information, use the measured image as the measured fuzzy image, perform feature extraction on the measured fuzzy image, and obtain an eigenvalue matrix corresponding to the measured fuzzy image; generate a thermal image corresponding to the measured fuzzy image according to the eigenvalue matrix;
[0069] S202: Determine each sampling line of the thermal image; for each sampling line, determine the average pixel value of the sampling line according to the pixel value of each pixel point on the sampling line;
[0070] S203: fitting the average pixel value of each of the sampling lines using a skewed distribution function to obtain a first fitting curve corresponding to the measured blurred image;
[0071] S204: Acquire a standard clear image corresponding to the measured blurred image, and determine a second fitting curve corresponding to the standard clear image using the same processing rule;
[0072] S205: Determine a defect detection result of the component to be detected according to the positional relationship between the first fitting curve and the second fitting curve.
[0073] In the present application, in order to determine the eigenvalue matrix corresponding to the measured blurred image more accurately, feature extraction is performed on the measured blurred image, and the eigenvalue matrix corresponding to the measured blurred image is obtained, which includes:
[0074] The measured blurred image is input into a feature extraction network model, and features of the measured blurred image are extracted in sequence based on a first convolution module, a residual module, a pooling module, and a second convolution module in the feature extraction network model to obtain an eigenvalue matrix corresponding to the measured blurred image.
[0075] In the present application, the feature extraction network model can be pre-trained. When training the feature extraction network model, the component images in the training set and the corresponding eigenvalue matrix labels are input into the feature extraction network model to be trained, and the loss value is determined based on the predicted eigenvalue matrix and the eigenvalue matrix labels determined by the feature extraction network model to be trained. The model parameters of the feature extraction network model to be trained are trained according to the loss value, and finally the trained feature extraction network model is obtained. Figure 3 The schematic diagram of the feature extraction network model structure provided for this application is as follows: Figure 3 As shown, the feature extraction network model includes a first convolution module, a residual module, a pooling module and a second convolution module. The parameters of the first convolution module, the residual module, the pooling module and the second convolution module in the feature extraction network model to be trained are trained according to the loss value, and finally the trained feature extraction network model is obtained. Optionally, the first convolution module may include three convolution modules connected in series, the second convolution module includes two convolution modules connected in series, and the residual module is 6 residual modules connected in series. The convolution module includes: a convolution layer, a normalization layer, and a Silu activation function layer. The residual module includes: a convolution module, a convolution layer, a Concat connection layer, a normalization layer, and a Silu activation function layer. The pooling module includes: three parallel maximum pooling layers, a Concat connection layer, and a convolution layer.
[0076] It should be noted that the present application can also train a component category detection model based on the component images in the training set and the corresponding component category labels. The component category detection model includes an image feature extraction network and a classifier. The image feature extraction network is used to extract image features, and the classifier is used to predict categories based on image features. After the component category detection model training is completed, the present application can use the image feature extraction network in the component category detection model as a feature extraction network model. The measured fuzzy image is input into the feature extraction network model, and features are extracted from the measured fuzzy image based on the feature extraction network model to obtain the eigenvalue matrix corresponding to the measured fuzzy image.
[0077] It should be noted that the present application can also train a component defect detection model based on the component images in the training set and the corresponding component defect labels. The component defect detection model includes an image feature extraction network and a classifier. The image feature extraction network is used to extract image features, and the classifier is used to predict defects based on image features. After the component defect detection model is trained, the present application can use the image feature extraction network in the component defect detection model as a feature extraction network model. The measured fuzzy image is input into the feature extraction network model, and features are extracted from the measured fuzzy image based on the feature extraction network model to obtain the eigenvalue matrix corresponding to the measured fuzzy image.
[0078] Figure 4 A schematic diagram of the third component defect detection process provided by the present application, the process includes the following steps:
[0079] S301: Acquire a measured image of a component to be detected and description parameter information of the component to be detected; if the clarity of the measured image is less than a preset clarity threshold, and it is determined according to the description parameter information that the component to be detected is a component without pins and silk screen information, then use the measured image as the measured blurred image;
[0080] S302: Input the measured blurred image into a feature extraction network model, extract features of the measured blurred image in sequence based on a first convolution module, a residual module, a pooling module, and a second convolution module in the feature extraction network model, obtain an eigenvalue matrix corresponding to the measured blurred image, and generate a thermal image corresponding to the measured blurred image according to the eigenvalue matrix;
[0081] S303: Determine each sampling line of the thermal image; for each sampling line, determine the average pixel value of the sampling line according to the pixel value of each pixel point on the sampling line;
[0082] S304: fitting the average pixel value of each sampling line using a skewed distribution function to obtain a first fitting curve corresponding to the measured blurred image;
[0083] S305: Acquire a standard clear image corresponding to the measured blurred image, and determine a second fitting curve corresponding to the standard clear image using the same processing rule;
[0084] S306: Determine a defect detection result of the component to be detected according to the positional relationship between the first fitting curve and the second fitting curve.
[0085] In the present application, in order to determine each sampling line of the thermal image more accurately, determining each sampling line of the thermal image includes:
[0086] According to the transverse direction of the thermal image and the preset number of first sampling lines, the uniformly distributed sampling lines of the thermal image are determined; and / or according to the longitudinal direction of the thermal image and the preset number of second sampling lines, the uniformly distributed sampling lines of the thermal image are determined.
[0087] The present application adopts three methods to determine each sampling line of the thermal image. Method 1: According to the horizontal direction of the thermal image and the preset number of first sampling lines, the uniformly distributed sampling lines of the thermal image are determined. In this method, the X-axis coordinates of the thermal image are evenly divided according to the preset number of first sampling lines, and the preset first sampling line number of sampling lines perpendicular to the X-axis in the thermal image is obtained. Method 2: According to the longitudinal direction of the thermal image and the preset number of second sampling lines, the uniformly distributed sampling lines of the thermal image are determined. In this method, the Y-axis coordinates of the thermal image are evenly divided according to the preset number of second sampling lines, and the preset second sampling line number of sampling lines perpendicular to the Y-axis in the thermal image is obtained. The preset number of first sampling lines and the preset number of second sampling lines may be the same or different. For example, the preset number of first sampling lines is 180, the preset number of second sampling lines is 200, and so on. Method 3: Combine the above methods 1 and 2, that is, obtain the preset first sampling line number of sampling lines perpendicular to the X-axis in the thermal image, and also obtain the preset second sampling line number of sampling lines perpendicular to the Y-axis in the thermal image.
[0088] For the above-mentioned method 1, the first fitting curve corresponding to the measured blurred image and the second fitting curve corresponding to the quasi-clear image are determined by method 1, and the defect detection results of the components to be inspected are determined according to the positional relationship between the first fitting curve and the second fitting curve.
[0089] For the above-mentioned method 2, the first fitting curve corresponding to the measured blurred image and the second fitting curve corresponding to the quasi-clear image are determined by method 2, and the defect detection results of the components to be inspected are determined according to the positional relationship between the first fitting curve and the second fitting curve.
[0090] For the above-mentioned method three, that is, a combination of the above-mentioned methods one and two. If the defect detection result of the component to be detected is determined to be non-defective according to the positional relationship between the first fitting curve and the second fitting curve determined by the method one, and the defect detection result of the component to be detected is determined to be non-defective according to the positional relationship between the first fitting curve and the second fitting curve determined by the method two, then the defect detection result of the component to be detected is determined to be non-defective. When the defect detection result of the component to be detected is determined to be defective according to the positional relationship between the first fitting curve and the second fitting curve determined by the method one or the method two, then the defect detection result of the component to be detected is determined to be defective.
[0091] Figure 5 A schematic diagram of a fourth component defect detection process provided in this application, the process comprising the following steps:
[0092] S401: Acquire a measured image of a component to be detected and description parameter information of the component to be detected; if the clarity of the measured image is less than a preset clarity threshold, and it is determined according to the description parameter information that the component to be detected is a component without pins and silk screen information, then use the measured image as the measured blurred image;
[0093] S402: Input the measured blurred image into a feature extraction network model, extract features of the measured blurred image in sequence based on a first convolution module, a residual module, a pooling module, and a second convolution module in the feature extraction network model, obtain an eigenvalue matrix corresponding to the measured blurred image, and generate a thermal image corresponding to the measured blurred image according to the eigenvalue matrix;
[0094] S403: determining uniformly distributed sampling lines of the thermal image according to the horizontal direction of the thermal image and a preset number of first sampling lines; and / or determining uniformly distributed sampling lines of the thermal image according to the longitudinal direction of the thermal image and a preset number of second sampling lines; for each sampling line, determining an average pixel value of the sampling line according to the pixel values of each pixel point on the sampling line;
[0095] S404: fitting the average pixel value of each sampling line using a skewed distribution function to obtain a first fitting curve corresponding to the measured blurred image;
[0096] S405: Acquire a standard clear image corresponding to the measured blurred image, and determine a second fitting curve corresponding to the standard clear image using the same processing rule;
[0097] S406: Determine a defect detection result of the component to be detected according to the positional relationship between the first fitting curve and the second fitting curve.
[0098] In order to make the defect detection result of the component to be detected more accurate, in the present application, according to the positional relationship between the first fitting curve and the second fitting curve, determining the defect detection result of the component to be detected includes:
[0099] According to the positional relationship between the first fitting curve and the second fitting curve, the mean difference, standard deviation difference and intersection area of the first fitting curve and the second fitting curve are determined; according to the relationship between the mean difference, standard deviation difference and intersection area and their respective corresponding threshold ranges, the defect detection result of the component to be detected is determined.
[0100] In the present application, the difference between the means and the intersection area of the first fitting curve and the second fitting curve can be determined according to the positional relationship between the first fitting curve and the second fitting curve. The difference between the means of the first fitting curve and the second fitting curve is the difference between the means of the horizontal coordinates of the sampling points on the first fitting curve and the second fitting curve, which is reflected in the fitting curve as the difference in the horizontal coordinates of the peak points of the first fitting curve and the second fitting curve. The horizontal axis of the coordinate system where the first fitting curve and the second fitting curve are located represents the X-axis coordinate or the Y-axis coordinate in the corresponding image coordinate system, and the vertical axis represents the pixel value. For the above-mentioned method 1, the horizontal axis of the coordinate system where the first fitting curve and the second fitting curve are located is the X-axis coordinate in the corresponding image coordinate system; for the above-mentioned method 2, the horizontal axis of the coordinate system where the first fitting curve and the second fitting curve are located is the Y-axis coordinate in the corresponding image coordinate system.
[0101] The intersection area of the first fitting curve and the second fitting curve refers to the overlap area of the first region enclosed by the first fitting curve and the abscissa axis and the second region enclosed by the second fitting curve and the abscissa axis. After determining the first fitting curve and the second fitting curve, the intersection area of the first fitting curve and the second fitting curve can be calculated by a calculus algorithm.
[0102] The difference between the standard deviations of the first fitting curve and the second fitting curve refers to the difference between the standard deviations of the horizontal coordinates of the sampling points on the first fitting curve and the second fitting curve. Optionally, the sampling points on the first fitting curve and the second fitting curve are determined respectively according to the same rule, and then the standard deviation of the sampling points on the first fitting curve is calculated, and the standard deviation of the sampling points on the second fitting curve is calculated, and the difference between the two standard deviations is calculated to obtain the difference between the standard deviations of the first fitting curve and the second fitting curve.
[0103] The electronic device pre-stores the threshold ranges corresponding to the mean difference, standard deviation difference and intersection area, and determines the defect detection result of the component to be detected according to the relationship between the mean difference, standard deviation difference and intersection area and the corresponding threshold ranges. Optionally, if the mean difference, standard deviation difference and intersection area are all within the corresponding threshold ranges, the defect detection result of the component to be detected is determined to be non-defective; if any of the mean difference, standard deviation difference and intersection area does not belong to the corresponding threshold range, the defect detection result of the component to be detected is determined to be defective.
[0104] Figure 6 A schematic diagram of a fifth component defect detection process provided in this application, the process comprising the following steps:
[0105] S501: Acquire a measured image of a component to be detected and description parameter information of the component to be detected; if the clarity of the measured image is less than a preset clarity threshold, and it is determined according to the description parameter information that the component to be detected is a component without pins and silk screen information, then use the measured image as the measured blurred image;
[0106] S502: Input the measured blurred image into a feature extraction network model, extract features of the measured blurred image in sequence based on a first convolution module, a residual module, a pooling module, and a second convolution module in the feature extraction network model, obtain an eigenvalue matrix corresponding to the measured blurred image, and generate a thermal image corresponding to the measured blurred image according to the eigenvalue matrix;
[0107] S503: determining uniformly distributed sampling lines of the thermal image according to the horizontal direction of the thermal image and a preset number of first sampling lines; and / or determining uniformly distributed sampling lines of the thermal image according to the longitudinal direction of the thermal image and a preset number of second sampling lines; for each sampling line, determining an average pixel value of the sampling line according to the pixel values of each pixel point on the sampling line;
[0108] S504: fitting the average pixel value of each sampling line using a skewed distribution function to obtain a first fitting curve corresponding to the measured blurred image;
[0109] S505: Acquire a standard clear image corresponding to the measured blurred image, and determine a second fitting curve corresponding to the standard clear image using the same processing rule;
[0110] S506: Determine the mean difference, standard deviation difference and intersection area of the first fitting curve and the second fitting curve according to the positional relationship between the first fitting curve and the second fitting curve; determine the defect detection result of the component to be detected according to the relationship between the mean difference, standard deviation difference and intersection area and their corresponding threshold ranges.
[0111] In order to further determine the defect detection results of the components to be detected more accurately, in the present application, according to the relationship between the mean difference, the standard deviation difference and the intersection area and the corresponding threshold ranges, determining the defect detection results of the components to be detected includes:
[0112] Determine, according to the positional relationship between the first fitting curve and the second fitting curve, an area ratio of an intersection area of the first fitting curve and the second fitting curve to an area of a union;
[0113] If the mean difference, standard deviation difference and area ratio all fall within their respective corresponding threshold ranges, the defect detection result of the component to be detected is determined to be non-defective; otherwise, the defect detection result of the component to be detected is determined to be defective.
[0114] In the present application, a first region enclosed by the first fitting curve and the horizontal axis and a second region enclosed by the second fitting curve and the horizontal axis are determined, and the overlapping area of the first region and the second region is calculated as the intersection area by a calculus algorithm, and the union area of the first region and the second region can be calculated by a calculus algorithm. Then, the area ratio of the intersection area to the union area is calculated.
[0115] The electronic device pre-stores the threshold ranges corresponding to the mean difference, standard deviation difference and area ratio, and determines the defect detection result of the component to be detected according to the relationship between the mean difference, standard deviation difference and area ratio and the corresponding threshold ranges. Optionally, if the mean difference, standard deviation difference and area ratio are all within the corresponding threshold ranges, the defect detection result of the component to be detected is determined to be non-defective; if any of the mean difference, standard deviation difference and area ratio does not belong to the corresponding threshold range, the defect detection result of the component to be detected is determined to be defective.
[0116] Figure 7 A schematic diagram of the sixth component defect detection process provided by the present application, the process comprising the following steps:
[0117] S601: Acquire a measured image of the component to be detected and description parameter information of the component to be detected; if the clarity of the measured image is less than a preset clarity threshold, and it is determined according to the description parameter information that the component to be detected is a component without pins and silk screen information, then use the measured image as the measured blurred image;
[0118] S602: Input the measured blurred image into a feature extraction network model, extract features of the measured blurred image in sequence based on a first convolution module, a residual module, a pooling module, and a second convolution module in the feature extraction network model, obtain an eigenvalue matrix corresponding to the measured blurred image, and generate a thermal image corresponding to the measured blurred image according to the eigenvalue matrix;
[0119] S603: determining uniformly distributed sampling lines of the thermal image according to the horizontal direction of the thermal image and a preset first sampling line number; and / or determining uniformly distributed sampling lines of the thermal image according to the longitudinal direction of the thermal image and a preset second sampling line number; for each sampling line, determining an average pixel value of the sampling line according to the pixel values of each pixel point on the sampling line;
[0120] S604: fitting the average pixel value of each sampling line using a skewed distribution function to obtain a first fitting curve corresponding to the measured blurred image;
[0121] S605: Acquire a standard clear image corresponding to the measured blurred image, and determine a second fitting curve corresponding to the standard clear image using the same processing rule;
[0122] S606: Determine an area ratio of an intersection area of the first fitting curve and a union area of the second fitting curve according to a positional relationship between the first fitting curve and the second fitting curve; if the mean difference, the standard deviation difference and the area ratio all fall within their respective corresponding threshold ranges, determine that a defect detection result of the component to be detected is non-defective; otherwise, determine that a defect detection result of the component to be detected is defective.
[0123] In this application, in order to remind the staff that there are defects in the components so as to carry out the subsequent manual defect re-judgment process, in this application, the method also includes:
[0124] If it is determined that the defect detection result of the component to be detected is defective, prompt information for indicating that the component to be detected is manually re-determined is output.
[0125] Among them, voice prompt information representing the artificial defect re-judgment of the components to be inspected can be output through a speaker; or light prompt information representing the artificial defect re-judgment of the components to be inspected can be output through an indicator light; or text prompt information representing the artificial defect re-judgment of the components to be inspected can be output through a display screen, etc.
[0126] The present application provides a component defect detection method, which introduces a thermal image method to extract high-dimensional features of a measured blurred image, maps the high-dimensional features into the form of a thermal image, collects and calculates a set of values of horizontal and vertical key sampling lines, and fits the above values with a skewed distribution function, calculates the peak value, area and other data between the fitting curves of the two sets of skewed distribution functions of the standard clear image and the measured blurred image, compares them with a threshold, and then determines whether the high-dimensional feature distribution of the measured blurred image is consistent with the high-dimensional feature data distribution of the standard clear image.
[0127] Trustworthy features:
[0128] Real-time: This application makes subsequent logical judgments based on the inference results of the deep learning model. Each model can process the images to be inferred from the electronic equipment (defect detection AOI equipment) to the algorithm within a given time period, which meets the real-time characteristics of the trustworthy characteristics.
[0129] Reproducibility: The same image can be transmitted to the same batch of models for inference multiple times. The same results can be obtained by inference multiple times in different operating environments (different platforms, different inference times, and different times), which meets the reproducibility feature of the trustworthiness feature.
[0130] Controllability: This application can be turned on or off by the user at any time during use. The importance of the inference results and the degree of adoption can be intervened by the user, which conforms to the controllability feature of the trustworthy characteristic.
[0131] The component defect detection process provided by the present application is described below with reference to the accompanying drawings.
[0132] Figure 8 It is a flow chart of component defect detection in the prior art, such as Figure 8 As shown, the defect detection AOI equipment detects the presence of defects in components based on the measured images of the components and performs manual re-judgment; it detects the absence of defects in components based on the measured images of the components and the components flow to the next process. In the prior art, the image of the component to be detected is generally compared with the image of the normal component based on the dimensions of the image such as color, gradient and contour, and the empirical threshold is set to determine whether the component is defective. If there is a defect, manual re-judgment is performed. This strategy is often relatively simple, and the high threshold set to reduce the missed detection rate may cause normal products to be misjudged. Due to reasons such as high object occlusion and camera focusing, the imaging of some component images will be blurred. In the prior art, the components in the blurred image will be directly judged as defective components, and subsequent re-judgment will be performed.
[0133] Fig. 9 The component defect detection flow chart provided for this application is as follows: Fig. 9 As shown, the defect detection AOI equipment detects that there are no defects in the components based on the measured images of the components, and the components flow to the next process; it detects that there are defects in the components based on the measured images of the components. If the measured image is a measured fuzzy image, a secondary inspection is performed on the measured fuzzy image based on the AI algorithm. If defects are found in the secondary inspection, manual re-judgment is performed; if there are no defects in the secondary inspection, the components flow to the next process.
[0134] The AI algorithm is as follows: obtain a measured fuzzy image of the component to be inspected, perform feature extraction on the measured fuzzy image, and obtain an eigenvalue matrix corresponding to the measured fuzzy image; generate a thermal image corresponding to the measured fuzzy image according to the eigenvalue matrix; determine each sampling line of the thermal image; for each sampling line, determine the average pixel value of the sampling line according to the pixel values of each pixel point on the sampling line; use a skewed distribution function to fit the average pixel value of each sampling line to obtain a first fitting curve corresponding to the measured fuzzy image; obtain a standard clear image corresponding to the measured fuzzy image, and use the same processing rules to determine the second fitting curve corresponding to the standard clear image; determine the defect detection result of the component to be inspected according to the positional relationship between the first fitting curve and the second fitting curve.
[0135] This application proposes an innovative secondary re-judgment method. Based on the original image comparison strategy of the AOI equipment, this method incorporates advanced AI detection technology to perform efficient and accurate secondary analysis of the measured fuzzy image pair, thereby optimizing the defect detection effect, reducing misjudgment, and improving production efficiency. Specifically, when the AOI equipment completes the preliminary detection of the measured image, it will automatically export the image pair currently being detected (including the standard image and the measured image). Subsequently, the AI detection technology of this application is used to conduct a secondary re-judgment of the measured fuzzy image that is initially detected as defective. The application of AI detection technology can intelligently identify and adapt to the changes in substitute materials on the production line, effectively avoiding the misjudgment problem caused by the difference in substitute materials in the traditional image matching method. In the secondary re-judgment process, AI detection technology will conduct a detailed analysis and comparison of the standard clear image and the measured fuzzy image. For components judged to be defect-free, they will be directly transferred to the next process, thereby realizing the rapid and continuous production of the production line. For components judged to be defective, they will enter the next stage of manual re-judgment.
[0136] Fig.10 The blurred image and clear image schematic diagram provided for this application, due to high object occlusion, camera focus and other reasons, some images may be blurred, such as Fig.10 As shown in the left figure, Fig.10 Standard definition image is on the right.
[0137] Fig.10The two images are schematic diagrams of the measured fuzzy image and the standard clear image of the same component. C38_1_SolderLight_402262A10374501ZTP245SCA3J_L_ng in the figure is the relevant description information of the component. The initials C represent that the component is a capacitor. In the prior art, in order to reduce the missed detection rate of AOI equipment, the fuzzy image will be directly judged as having defects. Although the image of this part of the fuzzy image is fuzzy, it is possible to obtain the category and position information of the component from the description parameter information of the component to be detected. For chip components that do not contain silk screen or pins on the surface, the method provided by this application can be used to determine whether there are defects on the component corresponding to the measured fuzzy image. Based on the above background, this application proposes a defect detection algorithm for chip components that do not contain silk screen based on fuzzy images.
[0138] In this application, the measured fuzzy images need to be screened first, with the following requirements: the clarity is less than the preset clarity threshold, and the measured images corresponding to small and medium-sized components without pins, silk screen information, and cracks are measured fuzzy images. Components that meet the above conditions include small and medium-sized components such as chip resistors, capacitors, and inductors.
[0139] For the measured blurred image that meets the conditions, it is sent to the feature extraction network model to extract the high-dimensional features of the measured blurred image. The structure of the feature extraction network is as follows: Figure 3 As shown, but not limited to Figure 3 After feature extraction, the eigenvalue matrix can be presented as follows Fig.11 The form of the thermal image shown. Fig.11 Schematic diagram of thermal image visualization provided for this application.
[0140] Then, the pixel values on the sampling lines are uniformly collected from the thermal image in the horizontal and vertical directions respectively. For each sampling line, the average pixel value of the sampling line is calculated to obtain the horizontal group data and the vertical group data, and the data is normalized. Fig.12 Schematic diagram of horizontal and vertical sampling lines in the thermal image provided by this application.
[0141] The skewed distribution function is used to fit the horizontal group data of the measured blurred image to obtain the measured horizontal fitting curve, and the skewed distribution function is used to fit the horizontal group data of the standard clear image to obtain the standard horizontal fitting curve; the skewed distribution function is used to fit the vertical group data of the measured blurred image to obtain the measured vertical fitting curve, and the skewed distribution function is used to fit the vertical group data of the standard clear image to obtain the standard vertical fitting curve. Then, according to the positional relationship between the measured horizontal fitting curve and the standard horizontal fitting curve, as well as the positional relationship between the measured vertical fitting curve and the standard vertical fitting curve, the defect detection results of the components to be detected are determined.
[0142] Fig.13 The present application provides a schematic diagram of a measured lateral fitting curve obtained by fitting the lateral group data of the measured blurred image. Fig.14 Schematic diagram of the positional relationship between the measured lateral fitting curve and the standard lateral fitting curve provided in this application. For the horizontal group data, the skewed distribution function of the standard clear image and the measured blurred image fitting is calculated respectively, and the difference between the means of the two groups of data, the difference in standard deviation, the area under the intersection of the two curves, and the proportion of the area under the compared part to the sum of the calculus of the two groups of functions are calculated, and compared with the corresponding preset threshold ranges. If it exceeds the preset threshold range, it means that the measured blurred image is a defective component image; if the above indicators are all within the threshold range, it means that the measured blurred image is a non-defective component image.
[0143] Fig.15 The schematic diagram of the device structure for component defect detection provided in this application includes:
[0144] The first determination module 151 is used to obtain a measured fuzzy image of the component to be detected, perform feature extraction on the measured fuzzy image, and obtain an eigenvalue matrix corresponding to the measured fuzzy image; and generate a thermal image corresponding to the measured fuzzy image according to the eigenvalue matrix;
[0145] The second determination module 152 is used to determine each sampling line of the thermal image; for each sampling line, according to the pixel value of each pixel point on the sampling line, determine the average pixel value of the sampling line;
[0146] A third determination module 153 is used to fit the average pixel value of each sampling line by using a skewed distribution function to obtain a first fitting curve corresponding to the measured blurred image;
[0147] A fourth determination module 154 is used to obtain a standard clear image corresponding to the measured blurred image, and determine a second fitting curve corresponding to the standard clear image using the same processing rule;
[0148] The detection module 155 is used to determine the defect detection result of the component to be detected according to the positional relationship between the first fitting curve and the second fitting curve.
[0149] The first determination module 151 is specifically used to obtain the measured image of the component to be detected and the description parameter information of the component to be detected; if the clarity of the measured image is less than a preset clarity threshold, and it is determined according to the description parameter information that the component to be detected is a component without pins and without silk screen information, then the measured image is used as the measured blurred image.
[0150] The first determination module 151 is specifically used to input the measured blurred image into a feature extraction network model, and extract features of the measured blurred image in sequence based on the first convolution module, the residual module, the pooling module and the second convolution module in the feature extraction network model to obtain an eigenvalue matrix corresponding to the measured blurred image.
[0151] The second determination module 152 is specifically used to determine the uniformly distributed sampling lines of the thermal image according to the horizontal direction of the thermal image and the preset number of first sampling lines; and / or to determine the uniformly distributed sampling lines of the thermal image according to the longitudinal direction of the thermal image and the preset number of second sampling lines.
[0152] The detection module 155 is specifically used to determine the difference in means, the difference in standard deviations and the intersection area between the first fitting curve and the second fitting curve according to the positional relationship between the first fitting curve and the second fitting curve; and determine the defect detection result of the component to be detected according to the relationship between the difference in means, the difference in standard deviations and the intersection area and their respective corresponding threshold ranges.
[0153] The detection module 155 is specifically used to determine the area ratio of the intersection area of the first fitting curve and the second fitting curve to the union area according to the positional relationship between the first fitting curve and the second fitting curve; if the difference in means, the difference in standard deviations and the area ratio all fall within their respective corresponding threshold ranges, it is determined that the defect detection result of the component to be detected is non-defective; otherwise, it is determined that the defect detection result of the component to be detected is defective.
[0154] The device also includes:
[0155] The prompt module 156 is used to output prompt information for indicating that the component to be inspected has been manually re-determined if the defect detection result of the component to be inspected is determined to be defective.
[0156] The present application also provides an electronic device, such as Fig.16As shown, it includes: a processor 161, a communication interface 162, a memory 163 and a communication bus 164, wherein the processor 161, the communication interface 162, and the memory 163 communicate with each other through the communication bus 164;
[0157] The memory 163 stores a computer program, and when the program is executed by the processor 161, the processor 161 executes any of the above method steps.
[0158] The communication bus mentioned in the above electronic device can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The communication bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, only one thick line is used in the figure, but it does not mean that there is only one bus or one type of bus.
[0159] The communication interface 162 is used for communication between the above electronic device and other devices.
[0160] The memory may include a random access memory (RAM) or a non-volatile memory (NVM), such as at least one disk memory. Optionally, the memory may also be at least one storage device located away from the aforementioned processor.
[0161] The above-mentioned processor can be a general-purpose processor, including a central processing unit, a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application-specific integrated circuit, a field programmable gate array or other programmable logic device, a discrete gate or transistor logic device, a discrete hardware component, etc.
[0162] The present application also provides a computer storage readable storage medium, wherein the computer readable storage medium stores a computer program executable by an electronic device, and when the program runs on the electronic device, the electronic device implements any of the above method steps when executing.
[0163] Although the preferred embodiments of the present application have been described, those skilled in the art may make other changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications falling within the scope of the present application.
[0164] Obviously, those skilled in the art can make various changes and modifications to the present application without departing from the spirit and scope of the present application. Thus, if these modifications and variations of the present application fall within the scope of the claims of the present application and their equivalents, the present application is also intended to include these modifications and variations.
Claims
1. A method for detecting component defects, It is characterized in that The method comprises: Acquire a measured fuzzy image of the component to be inspected, perform feature extraction on the measured fuzzy image, and obtain an eigenvalue matrix corresponding to the measured fuzzy image; generate a thermal image corresponding to the measured fuzzy image according to the eigenvalue matrix; Determine each sampling line of the thermal image; for each sampling line, determine the average pixel value of the sampling line according to the pixel value of each pixel point on the sampling line; Using a skewed distribution function to fit the average pixel value of each sampling line, to obtain a first fitting curve corresponding to the measured blurred image; Acquire a standard clear image corresponding to the measured blurred image, and determine a second fitting curve corresponding to the standard clear image by using the same processing rule; The defect detection result of the component to be detected is determined according to the positional relationship between the first fitting curve and the second fitting curve.
2. The method according to claim 1, It is characterized in that The step of obtaining a measured fuzzy image of a component to be detected comprises: Acquire the measured image of the component to be detected and the description parameter information of the component to be detected; If the clarity of the measured image is less than a preset clarity threshold, and it is determined according to the description parameter information that the component to be detected is a component without pins and silk screen information, the measured image is used as the measured blurred image.
3. The method according to claim 1, It is characterized in that Performing feature extraction on the measured blurred image to obtain an eigenvalue matrix corresponding to the measured blurred image includes: The measured blurred image is input into a feature extraction network model, and features of the measured blurred image are extracted in sequence based on a first convolution module, a residual module, a pooling module, and a second convolution module in the feature extraction network model to obtain an eigenvalue matrix corresponding to the measured blurred image.
4. The method according to claim 1, It is characterized in that Determining each sampling line of the thermal image includes: According to the transverse direction of the thermal image and the preset number of first sampling lines, the uniformly distributed sampling lines of the thermal image are determined; and / or according to the longitudinal direction of the thermal image and the preset number of second sampling lines, the uniformly distributed sampling lines of the thermal image are determined.
5. The method according to claim 1, It is characterized in that Determining the defect detection result of the component to be detected according to the positional relationship between the first fitting curve and the second fitting curve includes: According to the positional relationship between the first fitting curve and the second fitting curve, the mean difference, standard deviation difference and intersection area of the first fitting curve and the second fitting curve are determined; according to the relationship between the mean difference, standard deviation difference and intersection area and their respective corresponding threshold ranges, the defect detection result of the component to be detected is determined.
6. The method according to claim 5, It is characterized in that Determining the defect detection result of the component to be detected according to the relationship between the mean difference, the standard deviation difference and the intersection area and the corresponding threshold ranges includes: Determine, according to the positional relationship between the first fitting curve and the second fitting curve, an area ratio of an intersection area of the first fitting curve and the second fitting curve to an area of a union; If the mean difference, standard deviation difference and area ratio all fall within their respective corresponding threshold ranges, the defect detection result of the component to be detected is determined to be non-defective; otherwise, the defect detection result of the component to be detected is determined to be defective.
7. The method according to any one of claims 1 to 6, It is characterized in that The method further comprises: If it is determined that the defect detection result of the component to be detected is defective, prompt information for indicating that the component to be detected is manually re-determined is output.
8. A device for detecting component defects, It is characterized in that The device comprises: A first determination module is used to obtain a measured fuzzy image of the component to be detected, perform feature extraction on the measured fuzzy image, and obtain an eigenvalue matrix corresponding to the measured fuzzy image; and generate a thermal image corresponding to the measured fuzzy image according to the eigenvalue matrix; A second determination module is used to determine each sampling line of the thermal image; for each sampling line, according to the pixel value of each pixel point on the sampling line, determine the average pixel value of the sampling line; A third determination module is used to fit the average pixel value of each sampling line by using a skewed distribution function to obtain a first fitting curve corresponding to the measured blurred image; A fourth determination module is used to obtain a standard clear image corresponding to the measured blurred image, and determine a second fitting curve corresponding to the standard clear image by using the same processing rule; The detection module is used to determine the defect detection result of the component to be detected according to the positional relationship between the first fitting curve and the second fitting curve.
9. An electronic device, It is characterized in that It includes a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other through the communication bus; Memory, used to store computer programs; A processor, for implementing the method steps described in any one of claims 1 to 7 when executing a program stored in a memory.
10. A computer-readable storage medium, It is characterized in that The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method steps described in any one of claims 1 to 7 are implemented.
Citation Information
Cited By
Electrical component identification method and device, storage medium and electronic equipment
CN120689898A
