An automatic defect recognition method for LED circuit boards based on machine learning

By preprocessing and edge detection of the welding surface images of LED circuit boards, evaluating the shape and position of welding points, and building distribution maps and defect prediction models, the problems of low identification accuracy and lack of prediction methods in the existing technology are solved, and high efficiency is achieved defect identification and prediction.

CN118961755BActive Publication Date: 2024-12-20龙南鼎泰电子科技有限公司
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411450769.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-10-17
Publication Date
2024-12-20
Estimated Expiration
2044-10-17

AI Technical Summary

Technical Problem

The prior art has low recognition accuracy in LED circuit board defect recognition, and it is impossible to effectively identify the shape and distance of the welding points, and lacks defect prediction methods that utilize scrapped LED circuit board defect data.

Method used

By collecting the welding surface images of the LED circuit board, performing pre-processing and edge detection, obtaining the center and edge coordinates of the welding point, evaluating the morphology and position information of the welding point, building a welding point distribution map, dividing dense areas, judging the morphology and distance abnormalities, and Build a defect prediction model for failure prediction.

Benefits of technology

Accurate identification of the shape and distance abnormalities of the welding points of LED circuit boards is achieved, an effective defect prediction mechanism is formed, and defect recognition accuracy and prediction accuracy are improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118961755B_ABST
    Figure CN118961755B_ABST
Patent Text Reader

Abstract

A method for automatic defect recognition of an LED circuit board based on machine learning relates to the technical field of defect recognition, and comprises the following steps: obtaining an available welding surface image and obtaining welding point images of each welding point, respectively obtaining welding point center coordinates and welding point edge coordinates and evaluating the welding point morphology of each welding point to determine whether there is a welding point with abnormal morphology, obtaining welding point position information of each welding point, constructing a welding point distribution map and dividing each welding point into different dense areas, respectively obtaining the proximity distance between adjacent welding points and determining whether there is a welding point with abnormal distance; collecting defect data and constructing a defect prediction model, predicting defects of an LED circuit board according to the defect prediction model, generating a defect prediction signal and feeding back the signal; and through the technical solution of the present invention, welding points with abnormal morphology and welding points with abnormal distance can be found in time.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of defect recognition, and in particular to an automatic defect recognition method for LED circuit boards based on machine learning. Background Art

[0002] Defect recognition of LED circuit boards refers to the use of computer vision and machine learning technology to detect various defects that may exist on LED circuit boards, such as short circuits, open circuits, circuit board damage, poor welding, etc. This method combines image processing, feature extraction, and machine learning technology to efficiently and accurately identify defects on LED circuit boards, thereby improving recognition efficiency and product quality.

[0003] In the prior art, defect recognition of LED circuit boards is mostly not precise enough, and the shape and distance of each welding point cannot be effectively identified, resulting in low recognition accuracy. In addition, the prior art also lacks the means to use the defect data of scrapped LED circuit boards to predict defects of current LED circuit boards. In view of the shortcomings of the prior art, the present invention provides an automatic defect recognition method for LED circuit boards based on machine learning. Summary of the invention

[0004] The object of the present invention is to provide a method for automatic defect recognition of LED circuit boards based on machine learning.

[0005] The purpose of the present invention can be achieved by the following technical solution: A method for automatic defect recognition of LED circuit boards based on machine learning, comprising the following steps:

[0006] Step S1: collecting the welding surface image of the LED circuit board, and preprocessing the collected welding surface image to obtain a corresponding usable welding surface image;

[0007] Step S2: obtaining a welding point image of each welding point in the available welding surface image, obtaining the welding point center coordinates and welding point edge coordinates in the obtained welding point image, respectively, evaluating the welding point morphology of each welding point according to the obtained welding point center coordinates and welding point edge coordinates, and determining whether there is an abnormal welding point in morphology;

[0008] Step S3: obtaining welding point location information of each welding point in the available welding surface image, constructing a corresponding welding point distribution map according to the obtained welding point location information, dividing each welding point into different dense areas in the constructed welding point distribution map, respectively obtaining the proximity distances between adjacent welding points in different dense areas, and determining whether there are welding points with abnormal distances;

[0009] Step S4: Collect defect data of scrapped LED circuit boards, build a corresponding defect prediction model based on the collected defect data, predict defects of the current LED circuit boards based on the built defect prediction model, generate corresponding defect prediction signals and feedback.

[0010] Furthermore, the process of collecting the welding surface image of the LED circuit board and preprocessing the collected welding surface image to obtain the corresponding usable welding surface image includes:

[0011] The welding surface image of the LED circuit board is collected, and the collected welding surface image is preprocessed, wherein the preprocessing includes denoising, graying, and resizing, and the welding surface image after the above preprocessing is marked as a usable welding surface image.

[0012] Furthermore, the process of obtaining welding point images of each welding point in the available welding surface image and respectively obtaining welding point center coordinates and welding point edge coordinates in the obtained welding point images includes:

[0013] An edge detection algorithm is used to identify the welding points in the available welding surface image, a local image of the welding point is intercepted to obtain a welding point image, the welding point center of the welding point is obtained and a welding point coordinate system is constructed to obtain the welding point center coordinates, the welding point edge of the welding point is identified, a number of edge points are obtained on the welding point edge, and the coordinates of each edge point in the welding point coordinate system are used as the welding point edge coordinates.

[0014] Furthermore, the process of evaluating the welding point morphology of each welding point and determining whether there is an abnormal welding point in morphology according to the obtained welding point center coordinates and welding point edge coordinates includes:

[0015] In the welding point coordinate system, the edge distance between the edge coordinates of each welding point and the center coordinates of the welding point is obtained, the edge standard of the welding point is obtained according to the edge distances of the same welding point, the edge distance is compared with the edge standard, and the welding point shape of the welding point is evaluated according to the comparison result to obtain the evaluation coefficient;

[0016] An evaluation standard is set, the evaluation coefficient is compared with the evaluation standard, the abnormal morphology welding points are obtained according to the comparison result, and a morphology abnormality signal is generated and fed back to the relevant personnel.

[0017] Furthermore, the process of obtaining the welding point position information of each welding point in the available welding surface image and constructing the corresponding welding point distribution map according to the obtained welding point position information includes:

[0018] Constructing a welding surface coordinate system in the available welding surface image, and obtaining welding point position information of each welding point in the welding surface coordinate system, wherein the welding point position information refers to the coordinate information of the center of each welding point and the corresponding edge point in the welding surface coordinate system;

[0019] A welding point distribution map of the LED circuit board is constructed according to the welding point position information, and the welding point distribution map is used to reflect the distribution of the center and edge points of each welding point on the LED circuit board.

[0020] Furthermore, the process of dividing each welding point into different dense areas in the constructed welding point distribution map, obtaining the proximity distances between adjacent welding points in different dense areas, and judging whether there are welding points with abnormal distances includes:

[0021] In the welding point distribution map, the center and edge points of each welding point are treated as one point, and the K-Means algorithm is used to cluster the points in the welding point distribution map to divide them into several different dense areas;

[0022] The coordinate information of each point in the dense area of ​​the same density is included in the same dense coordinate set, the shortest distance between each point in the dense coordinate set is obtained, the adjacent welding points of each point are obtained according to the shortest distance, and the shortest distance between adjacent welding points is used as the proximity distance;

[0023] According to all the proximity distances in the dense coordinate set, the proximity coefficient between each adjacent welding point is obtained, the proximity standard is set, the proximity coefficient is compared with the proximity standard, the distance abnormal welding point is obtained according to the comparison result, the distance abnormality signal is generated and fed back to the relevant personnel.

[0024] Furthermore, the defect data of the scrapped LED circuit board is collected, and the process of building a corresponding defect prediction model according to the collected defect data includes:

[0025] Collect defect data of scrapped LED circuit boards, wherein the defect data refers to the defect ratio of abnormal soldering points in shape and abnormal soldering points in distance to all points in the LED circuit board and the working time of the LED circuit board;

[0026] A machine learning model is selected as the initial defect prediction model, and the initial defect prediction model is trained and evaluated using the defect data to obtain the latest defect prediction model, which is used to predict the working time of the defect according to the input defect data.

[0027] Furthermore, the process of performing defect prediction on the current LED circuit board according to the constructed defect prediction model, generating a corresponding defect prediction signal and feeding back includes:

[0028] Obtain defect data of the current LED circuit board, input the defect data into a defect recognition model, use the defect recognition model to predict the working time of the LED circuit board, obtain the actual working time of the current LED circuit board, compare the actual working time with the working time, obtain the LED circuit board in a potential fault state based on the comparison result, generate a defect prediction signal and feed it back to relevant personnel.

[0029] Compared with the prior art, the present invention has the following beneficial effects:

[0030] 1. The present invention can evaluate the weld point morphology of each weld point by obtaining the weld point center coordinates and weld point edge coordinates of each weld point, which is conducive to discovering weld points with abnormal morphology and timely feedback. By classifying the distribution of weld points, the proximity distances of adjacent weld points in dense areas with different density levels are obtained, and it can judge whether the distance between adjacent weld points is too far or too close, which is conducive to discovering weld points with abnormal distances and timely feedback.

[0031] 2. Obtain the defect ratio and working time of abnormal morphological welding points and abnormal distance welding points in the scrapped LED circuit boards, and build a corresponding defect recognition model according to the corresponding relationship between the obtained defect ratio and the working time. It can be used to determine whether the current LED circuit board has potential faults based on the defect recognition model, which is conducive to forming an effective defect prediction mechanism and can better realize the defect recognition of LED circuit boards. BRIEF DESCRIPTION OF THE DRAWINGS

[0032] Figure 1 It is a flow chart of the present invention. DETAILED DESCRIPTION

[0033] like Figure 1 As shown, a method for automatic defect recognition of LED circuit boards based on machine learning includes the following steps:

[0034] Step S1: collecting the welding surface image of the LED circuit board, and preprocessing the collected welding surface image to obtain a corresponding usable welding surface image;

[0035] Step S2: obtaining a welding point image of each welding point in the available welding surface image, obtaining the welding point center coordinates and welding point edge coordinates in the obtained welding point image, respectively, evaluating the welding point morphology of each welding point according to the obtained welding point center coordinates and welding point edge coordinates, and determining whether there is an abnormal welding point in morphology;

[0036] Step S3: obtaining welding point location information of each welding point in the available welding surface image, constructing a corresponding welding point distribution map according to the obtained welding point location information, dividing each welding point into different dense areas in the constructed welding point distribution map, respectively obtaining the proximity distances between adjacent welding points in different dense areas, and determining whether there are welding points with abnormal distances;

[0037] Step S4: Collect defect data of scrapped LED circuit boards, build a corresponding defect prediction model based on the collected defect data, predict defects of the current LED circuit boards based on the built defect prediction model, generate corresponding defect prediction signals and feedback.

[0038] It should be further explained that, in the specific implementation process, the process of collecting the welding surface image of the LED circuit board and preprocessing the collected welding surface image to obtain the corresponding usable welding surface image includes:

[0039] The welding surface image of the LED circuit board is collected. In the LED circuit board, the welding surface generally refers to the copper foil area used for welding LED components or other electronic components. The welding surface image refers to the original image of the welding surface side of the LED circuit board after welding.

[0040] The collected welding surface image is preprocessed, and the preprocessing is used to optimize the welding surface image for subsequent analysis and processing, including denoising, graying, and resizing. The welding surface image after the above preprocessing is marked as a usable welding surface image.

[0041] It should be further explained that, in a specific implementation process, the welding point image of each welding point is obtained in the available welding surface image, and the process of respectively obtaining the welding point center coordinates and the welding point edge coordinates in the obtained welding point image includes:

[0042] In the embodiment of the present invention, it is necessary to analyze the morphology of the soldering points on the LED circuit board. In the LED circuit board, the soldering points generally refer to the physical connection points between the LED components or other electronic components and the LED circuit board;

[0043] In the obtained available welding surface image, each welding point is identified by using an edge detection algorithm, a local image of each welding point and its surrounding area is intercepted to obtain a corresponding welding point image, and each welding point is bound to its corresponding welding point image, wherein the welding point image only includes a single and complete welding point;

[0044] Taking the welding point image of any welding point as an example, the position of the welding hole corresponding to the welding point is marked as the welding point center, and the welding point coordinate system of the welding point is constructed with the welding point center as the coordinate origin. The welding point center coordinate is marked as (0, 0), and the welding point edge of the welding point is identified by the edge detection algorithm. A number of edge points are obtained in sequence at a fixed distance on the obtained welding point edge, and the coordinates of each edge point in the welding point coordinate system are marked as welding point edge coordinates, and are marked as (x i ,y i ), where i=1, 2, …, n, and n represents the number of edge points.

[0045] It should be further explained that, in a specific implementation process, the process of evaluating the welding point morphology of each welding point and judging whether there is an abnormal welding point in morphology according to the obtained welding point center coordinates and welding point edge coordinates includes:

[0046] The welding point shape refers to the shape formed by the welding point edges of each welding point. Under normal circumstances, the welding point shape is mostly approximately circular. Therefore, in the embodiment of the present invention, the welding point shape is assumed to be circular for evaluation. Taking any welding point as an example, in the welding point coordinate system of the welding point, the edge distance between the edge coordinates of each welding point and the center coordinates of the welding point is obtained, and the obtained edge distance is marked as B. i ;

[0047]

[0048] The average of the edge distances of the same welding point is taken as the edge standard of the welding point, denoted as B0, and the obtained edge distance is compared with the edge standard respectively. i ≤B0, it is marked as normal. i > B0, it is marked as abnormal, and the welding point morphology of the welding point is evaluated according to the comparison result, and the ratio of the number of edge distances marked as normal in the welding point to the number of all edge distances is used as the evaluation coefficient of the welding point, and the obtained evaluation coefficient is marked as P i ;

[0049] Set the evaluation standard P0, compare the obtained evaluation coefficient with the evaluation standard, if P i ≥P0, then the welding point is marked as a normal welding point. i <P0, the welding point is marked as a morphologically abnormal welding point, a corresponding morphologically abnormal signal is generated, and the generated morphologically abnormal signal is fed back to relevant personnel.

[0050] It should be further explained that, in a specific implementation process, the process of obtaining the welding point position information of each welding point in the available welding surface image and constructing the corresponding welding point distribution map according to the obtained welding point position information includes:

[0051] In the embodiment of the present invention, it is necessary to analyze the proximity distance between adjacent welding points on the LED circuit board, and to determine whether the proximity distance between adjacent welding points is too far or too close to realize another defect identification method for welding points on the LED circuit board;

[0052] In the obtained available welding surface image, a welding surface coordinate system of the welding surface is constructed with any vertex as the coordinate origin, and welding point position information of each welding point is obtained in the constructed welding surface coordinate system, wherein the welding point position information refers to the coordinate information of the center of each welding point and the corresponding edge point in the welding surface coordinate system;

[0053] A welding point distribution map of the LED circuit board is constructed based on the obtained welding point position information. The constructed welding point distribution map only includes the welding point center and edge points of each welding point, which is used to reflect the distribution of each welding point center and edge point on the LED circuit board.

[0054] It should be further explained that, in a specific implementation process, the process of dividing each welding point into different dense areas in the constructed welding point distribution map, obtaining the proximity distances between adjacent welding points in different dense areas, and judging whether there are welding points with abnormal distances includes:

[0055] In the constructed welding point distribution map, the center and edge points of each welding point are treated as one point, and the K-Means algorithm is used to cluster the points in the welding point distribution map to divide them into several different dense areas. The density of each dense area is different, and the dense areas are sorted from high to low according to their density;

[0056] The coordinate information of each point in the dense area of ​​the same density is included in the same dense coordinate set. Taking any point in any dense coordinate set as an example, the shortest distance between the point and other points in the dense coordinate set is obtained, and the point corresponding to the smallest shortest distance is used as the nearest welding point of the point. The point and its nearest welding point are marked as adjacent welding points, and the shortest distance between adjacent welding points is marked as adjacent distance.

[0057] The same method is used to obtain all the neighboring distances in the dense coordinate set, and the obtained neighboring distances are numbered and recorded as L j, where j = 1, 2, ..., m, where m represents the number of neighboring distances in the dense coordinate set, and the proximity coefficient of each adjacent welding point is obtained according to the obtained proximity distance, which is recorded as R j ;

[0058]

[0059] Set the proximity standard R0, compare the obtained proximity coefficient with the proximity standard, if R j ≤R0, it is marked as the distance from the normal welding point. j >R0, it is marked as a distance abnormal welding point, a corresponding distance abnormal signal is generated, and the generated distance abnormal signal is fed back to relevant personnel.

[0060] It should be further explained that, in the specific implementation process, the defect data of the scrapped LED circuit board is collected, and the process of building a corresponding defect prediction model based on the collected defect data includes:

[0061] Defect data of scrapped LED circuit boards are collected, wherein the defect data refers to the proportion of abnormal soldering points in shape and distance to all soldering points in the LED circuit board, and the defect data is marked as defect proportion. The defect data also includes the working time of the LED circuit board, that is, the time interval from the LED circuit board leaving the factory to being scrapped;

[0062] Select a machine learning model as the initial defect prediction model, divide the obtained defect data into a training set and a test set, use the training set to train the initial defect prediction model, and obtain the trained defect prediction model by learning the corresponding relationship between the defect ratio and the working time;

[0063] The trained defect prediction model is evaluated using a test set, and the trained defect prediction model is tuned according to the evaluation result to obtain a tuned defect prediction model. The most recently tuned defect prediction model is used as the latest defect prediction model, and the defect prediction model is used to predict the working time of the input defect data according to the input defect data.

[0064] It should be further explained that, in the specific implementation process, the process of performing defect prediction on the current LED circuit board according to the constructed defect prediction model, generating corresponding defect prediction signals and feeding back includes:

[0065] Obtain defect data of the current LED circuit board, input the obtained defect data into the constructed defect recognition model, and use the defect recognition model to predict the working time of the LED circuit board according to the input defect data;

[0066] Obtain the working time of the current LED circuit board, compare the obtained working time with its corresponding possible working time, if the working time is less than or equal to the possible working time, do not perform any other operations on it, if the working time is greater than the possible working time, mark it as a potential fault state, generate a corresponding defect prediction signal, and feed it back to the relevant personnel.

[0067] The above embodiments are only used to illustrate the technical method of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the preferred embodiments, those skilled in the art should understand that the technical method of the present invention may be modified or replaced by equivalents without departing from the spirit and scope of the technical method of the present invention.

Claims

1. A method for automatic defect recognition of LED circuit boards based on machine learning, It is characterized in that The following steps are involved: Step S1: collecting the welding surface image of the LED circuit board, and preprocessing the collected welding surface image to obtain a corresponding usable welding surface image; Step S2: obtaining a welding point image of each welding point in the available welding surface image, obtaining the welding point center coordinates and welding point edge coordinates in the obtained welding point image, respectively, evaluating the welding point morphology of each welding point according to the obtained welding point center coordinates and welding point edge coordinates, and determining whether there is an abnormal welding point in morphology; Step S3: obtaining welding point location information of each welding point in the available welding surface image, constructing a corresponding welding point distribution map according to the obtained welding point location information, dividing each welding point into different dense areas in the constructed welding point distribution map, respectively obtaining the proximity distances between adjacent welding points in different dense areas, and determining whether there are welding points with abnormal distances; Step S4: collecting defect data of scrapped LED circuit boards, building a corresponding defect prediction model based on the collected defect data, predicting defects of the current LED circuit boards based on the built defect prediction model, generating corresponding defect prediction signals and feeding back; The defect data refers to the defect ratio of abnormal soldering points in shape and abnormal soldering points in distance to all the points in the LED circuit board and the working time of the LED circuit board; Selecting a machine learning model as an initial defect prediction model, using defect data to train and evaluate the initial defect prediction model to obtain an updated defect prediction model, wherein the defect prediction model is used to predict the working time of the defect according to the input defect data; Obtain defect data of the current LED circuit board, input the defect data into a defect recognition model, use the defect recognition model to predict the working time of the LED circuit board, obtain the actual working time of the current LED circuit board, compare the actual working time with the working time, obtain the LED circuit board in a potential fault state based on the comparison result, generate a defect prediction signal and feed it back to relevant personnel.

2. According to claim 1, a method for automatic defect recognition of LED circuit boards based on machine learning, It is characterized in that The process of collecting the welding surface image of the LED circuit board and preprocessing the collected welding surface image to obtain the corresponding usable welding surface image includes: The welding surface image of the LED circuit board is collected, and the collected welding surface image is preprocessed, wherein the preprocessing includes denoising, graying, and resizing, and the welding surface image after the above preprocessing is marked as a usable welding surface image.

3. According to claim 2, a method for automatic defect recognition of LED circuit boards based on machine learning, It is characterized in that The process of obtaining welding point images of each welding point in the available welding surface image and respectively obtaining welding point center coordinates and welding point edge coordinates in the obtained welding point images includes: An edge detection algorithm is used to identify the welding points in the available welding surface image, a local image of the welding point is intercepted to obtain a welding point image, the welding point center of the welding point is obtained and a welding point coordinate system is constructed to obtain the welding point center coordinates, the welding point edge of the welding point is identified, a number of edge points are obtained on the welding point edge, and the coordinates of each edge point in the welding point coordinate system are used as the welding point edge coordinates.

4. According to claim 3, a method for automatic defect recognition of LED circuit boards based on machine learning, It is characterized in that The process of evaluating the weld point morphology of each weld point and judging whether there is an abnormal weld point in morphology according to the obtained weld point center coordinates and weld point edge coordinates includes: In the welding point coordinate system, the edge distance between the edge coordinates of each welding point and the center coordinates of the welding point is obtained, the edge standard of the welding point is obtained according to the edge distances of the same welding point, the edge distance is compared with the edge standard, and the welding point shape of the welding point is evaluated according to the comparison result to obtain the evaluation coefficient; An evaluation standard is set, the evaluation coefficient is compared with the evaluation standard, the abnormal morphology welding points are obtained according to the comparison result, and a morphology abnormality signal is generated and fed back to the relevant personnel.

5. According to claim 4, a method for automatic defect recognition of LED circuit boards based on machine learning, It is characterized in that The process of obtaining the welding point position information of each welding point in the available welding surface image and constructing the corresponding welding point distribution map according to the obtained welding point position information includes: Constructing a welding surface coordinate system in the available welding surface image, and obtaining welding point position information of each welding point in the welding surface coordinate system, wherein the welding point position information refers to the coordinate information of the center of each welding point and the corresponding edge point in the welding surface coordinate system; A welding point distribution map of the LED circuit board is constructed according to the welding point position information, and the welding point distribution map is used to reflect the distribution of the center and edge points of each welding point on the LED circuit board.

6. According to claim 5, a method for automatic defect recognition of LED circuit boards based on machine learning, It is characterized in that The process of dividing each welding point into different dense areas in the constructed welding point distribution map, obtaining the proximity distances between adjacent welding points in different dense areas, and judging whether there are welding points with abnormal distances includes: In the welding point distribution map, the center and edge points of each welding point are treated as one point, and the K-Means algorithm is used to cluster the points in the welding point distribution map to divide them into several different dense areas; The coordinate information of each point in the dense area of ​​the same density is included in the same dense coordinate set, the shortest distance between each point in the dense coordinate set is obtained, the adjacent welding points of each point are obtained according to the shortest distance, and the shortest distance between adjacent welding points is used as the proximity distance; According to all the proximity distances in the dense coordinate set, the proximity coefficient between each adjacent welding point is obtained, the proximity standard is set, the proximity coefficient is compared with the proximity standard, the distance abnormal welding point is obtained according to the comparison result, the distance abnormality signal is generated and fed back to the relevant personnel.