IP Library › Granted Patent US 12,632,951
Granted Patent B2
US 12,632,951 · App. 17/764,707 · Granted May 19, 2026

Method for detecting defect and method for training model

Inventors: Yaoping Wang (Beijing, CN); Zhaoyue Li (Beijing, CN); Haodong Yang (Beijing, CN); Meijuan Zhang (Beijing, CN); Dong Chai (Beijing, CN); Hong Wang (Beijing, CN)
Assignees: Beijing Zhongxiangying Technology Co., Ltd.; BOE TECHNOLOGY GROUP CO., LTD.
G06T7/001G06T2207/20081G06T2207/20084
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 12,632,951
App. No.
17/764,707
Granted
May 19, 2026
Kind
B2
Abstract

A method and device for detecting a defect and method for training a model are provided. The method for detecting the defect includes: acquiring a sample data set and identifying feature information of the sample data set; acquiring an initial model; configuring a training parameter based on the feature information; obtaining a target model by training, according to the training parameter, the initial model with the sample data set; and obtaining defect information of a product by inputting real data of the product into the target model. The training parameter includes at least one of a learning rate descent strategy, a total number of training rounds and a test strategy, the learning rate descent strategy includes a number of learning rate descents and a round number when a learning rate descends, and the test strategy includes a number of tests and a round number when testing.

Claims (78)

1 . A method for detecting a defect, comprising:

acquiring, by a terminal device, a sample data set comprising defective product data, and identifying feature information of the sample data set, the feature information comprising a number of samples in the sample data set;

transmitting, by the terminal device, the sample data set and the feature information to a server;

acquiring, by the server, an initial model, the initial model being a neural network model;

setting, by the server, a learning rate descent strategy, a total number of training rounds and a test strategy in a training parameter for the initial model based on the number of samples in the feature information;

obtaining, by the server, a target model by inputting the sample data set into the initial model and training, according to the training parameter, the initial model with the sample data set; and

obtaining, by the server, defect information of a product corresponding to the sample data set by inputting real data of the product into the target model,

wherein the learning rate descent strategy comprises a number of learning rate descents and a round number when a learning rate descends, and the test strategy comprises a number of tests and a round number at which a test is performed on a trained model,

wherein the server configures the total number of training rounds according to the number of samples under a preset rule, comprising:

configuring, in response to the number of samples being less than or equal to 10000, the total number of training rounds to 300000; and

configuring, in response to the number of samples being greater than 10000, the total number of training rounds with a formula of:

Y= 300000+INT( X/ 10000)× b

where Y represents the total number of training rounds, X represents the number of samples and is greater than or equal to 10000, INT is a rounding function, and b represents a growth factor having a fixed value and is greater than or equal to 30000 and less than or equal to 70000,

wherein the server configures the round number when the learning rate descends to be proportional to the total number of training rounds, and the round number at which the test is performed on the trained model to be greater than or equal to the round number when the learning rate descends for a first time and less than or equal to the total number of training rounds,

wherein the method further comprises:

generating, by the server, and displaying a training parameter display interface, wherein the training parameter display interface displays the learning rate descent strategy, the total number of training rounds and the test strategy set by the server.

2 . The method according to claim 1 , wherein the learning rate descends a plurality of times, and at least two tests are performed within a preset number of rounds around the round number when the learning rate descends for a second time.

3 . The method according to claim 2 , wherein the learning rate descends three times, and at least three tests are performed within the preset number of rounds around the round number when the learning rate descends for the second time.

4 . The method according to claim 1 , wherein the learning rate descent strategy comprises a learning rate descent manner and a learning rate descent magnitude.

5 . The method according to claim 1 , wherein the defective product data comprises a defective product image, and the feature information comprises a size and a type of the defective product image in the sample data set, and

wherein the method further comprises:

adjusting a size of an input image input into the initial model according to the size and the type of the defective product image.

6 . The method according to claim 5 , wherein adjusting the size of the input image input into the initial model according to the size and the type of the defective product image comprises:

adjusting the size of the input image to be a first preset multiple of the size of the defective product image in response to that the type of the defective product image indicates an AOI color image or a DM image; and

adjusting the size of the input image to be a second preset multiple of the size of the defective product image in response to that the type of the defective product image indicates a TDI image,

wherein the first preset multiple is less than or equal to 1, and the second preset multiple is greater than or equal to 1.

7 . The method according to claim 6 , wherein the input image comprises images with a plurality of sizes corresponding to a same defective product image.

8 . The method according to claim 5 , wherein the feature information further comprises a defect level of the defective product, and wherein the method further comprises:

configuring a confidence level in a training process according to defect levels corresponding to respective defects.

9 . The method according to claim 8 , wherein the defect level comprises a first defect level and a second defect level, and configuring the confidence level in the training process according to the defect levels corresponding to the respective defects comprises:

configuring the confidence level as a first confidence level in response to the defect level being the first defect level; and

configuring the confidence level as a second confidence level in response to the defect level being the second defect level,

wherein the second confidence level is greater than the first confidence level.

10 . The method according to claim 1 , further comprising acquiring the initial model according to a type of a defective product image.

11 . The method according to claim 1 ,

wherein the training parameter display interface comprises a parameter modification identifier; and

wherein the method further comprises:

updating the training parameter in response to a triggering operation of a user on the parameter modification identifier.

12 . The method according to claim 1 , further comprising:

acquiring a loss curve in a training process; and

updating the training parameter according to the loss curve.

13 . The method according to claim 1 , wherein obtaining, by the server, the target model by inputting the sample data set into the initial model and training, according to the training parameter, the initial model comprises:

acquiring a plurality of reference models according to the test strategy, and acquiring an accuracy rate and a recall rate of each of the reference models; and

determining the target model from the reference models according to the accuracy rate and the recall rate of each of the reference models.

14 . The method according to claim 1 , wherein obtaining, by the server, the target model by inputting the sample data set into the initial model and training, according to the training parameter, the initial model comprises:

acquiring a plurality of reference models according to the test strategy, and determining a confusion matrix of each of the reference models; and

determining the target model from the reference models according to the confusion matrix.

15 . The method according to claim 14 , further comprising: updating a confidence level according to the confusion matrix.

16 . A method for training a model, comprising:

acquiring, by a terminal device, a sample data set comprising defective product data, and identifying feature information of the sample data set, the feature information comprising a number of samples in the sample data set;

transmitting, by the terminal device, the sample data set and the feature information to a server;

acquiring, by the server, an initial model, the initial model being a neural network model;

setting, by the server, a learning rate descent strategy, a total number of training rounds and a test strategy in a training parameter for the initial model based on the number of samples in the feature information; and

obtaining, by the server, a target model by inputting the sample data set into the initial model and training, according to the training parameter, the initial model with the sample data set, the target model being configured to perform a defect detection on real data of a product corresponding to the sample data set,

wherein the learning rate descent strategy comprises a number of learning rate descents and a round number when a learning rate descends, and the test strategy comprises a number of tests and a round number at which a test is performed on a trained model,

wherein the server configures the total number of training rounds according to the number of samples under a preset rule, comprising:

configuring, in response to the number of samples being less than or equal to 10000, the total number of training rounds to 300000; and

configuring, in response to the number of samples being greater than 10000, the total number of training rounds with a formula of:

Y= 300000+INT( X/ 10000)× b

where Y represents the total number of training rounds, X represents the number of samples and is greater than or equal to 10000, INT is a rounding function, and b represents a growth factor having a fixed value and is greater than or equal to 30000 and less than or equal to 70000,

wherein the server configures the round number when the learning rate descends to be proportional to the total number of training rounds, and the round number at which the test is performed on the trained model to be greater than or equal to the round number when the learning rate descends for a first time and less than or equal to the total number of training rounds,

wherein the method further comprises:

generating, by the server, and displaying a training parameter display interface, wherein the training parameter display interface displays the learning rate descent strategy, the total number of training rounds and the test strategy set by the server.

17 . A method for training a model, comprising:

acquiring, by a terminal device, a sample data set comprising defective product data in response to a configuration operation of a user on a parameter of the sample data set, and identifying feature information of the sample data set, the feature information comprising a number of samples in the sample data set;

transmitting, by the terminal device, the sample data set and the feature information to a server;

acquiring, by the server, an initial model, the initial model being a neural network model;

setting, by the server, a learning rate descent strategy, a total number of training rounds and a test strategy in a training parameter for the initial model based on the number of samples in the feature information; and

obtaining, by the server, a target model by inputting the sample data set into the initial model and training, according to the training parameter, the initial model with the sample data set, the target model being configured to perform a defect detection on real data of a product corresponding to the sample data set,

wherein the learning rate descent strategy comprises a number of learning rate descents and a round number when a learning rate descends, and the test strategy comprises a number of tests and a round number at which a test is performed on a trained model,

wherein the server configures the total number of training rounds according to the number of samples under a preset rule, comprising:

configuring, in response to the number of samples being less than or equal to 10000, the total number of training rounds to 300000; and

configuring, in response to the number of samples being greater than 10000, the total number of training rounds with a formula of:

Y= 300000+INT( X/ 10000)× b

where Y represents the total number of training rounds, X represents the number of samples and is greater than or equal to 10000, INT is a rounding function, and b represents a growth factor having a fixed value and is greater than or equal to 30000 and less than or equal to 70000,

wherein the server configures the round number when the learning rate descends to be proportional to the total number of training rounds, and the round number at which the test is performed on the trained model to be greater than or equal to the round number when the learning rate descends for a first time and less than or equal to the total number of training rounds,

wherein the method further comprises:

generating, by the server, and displaying a training parameter display interface, wherein the training parameter display interface displays the learning rate descent strategy, the total number of training rounds and the test strategy set by the server.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Apr 4, 2023
From: WANG, YAOPING; LI, ZHAOYUE; YANG, HAODONG; ZHANG, MEIJUAN; CHAI, DONG; WANG, HONG
To: BEIJING ZHONGXIANGYING TECHNOLOGY CO., LTD.; BOE TECHNOLOGY GROUP CO., LTD.
Reel/Frame 063217/0376 →
Continuity (1)
Related Publication 20230206420A1 · Jun 29, 2023
References Cited (37)
US 10607331B1 · Tandia et al. · 2020 [cited by applicant]
US 20190065979A1 · Shao et al. · 2019 [cited by applicant]
US 20190164055A1 · Ljung Larhed · 2019 [cited by examiner]
US 20190318240A1 · Kulkarni · 2019 [cited by examiner]
US 20200027009A1 · Khan et al. · 2020 [cited by applicant]
US 20200349875A1 · Wen et al. · 2020 [cited by applicant]
US 20200380301A1 · Siracusa et al. · 2020 [cited by applicant]
US 20210192714A1 · Bhatt · 2021 [cited by examiner]
US 20230048386A1 · Wang · 2023 [cited by examiner]
CN 106645180A · 2017 [cited by applicant]
CN 108352339A · 2018 [cited by examiner]
CN 108802041A · 2018 [cited by applicant]
CN 108961238A · 2018 [cited by applicant]
CN 109143199A · 2019 [cited by applicant]
CN 109146873A · 2019 [cited by applicant]
CN 109559298A · 2019 [cited by examiner]
CN 109683360A · 2019 [cited by applicant]
CN 110020691A · 2019 [cited by applicant]
CN 110378887A · 2019 [cited by applicant]
CN 110675789A · 2020 [cited by applicant]
CN 111080633A · 2020 [cited by applicant]
CN 111160432A · 2020 [cited by applicant]
CN 111325744A · 2020 [cited by applicant]
CN 111340233A · 2020 [cited by applicant]
CN 111951212A · 2020 [cited by examiner]
CN 112990035A · 2021 [cited by applicant]
WO WO2017096758A1 · 2017 [cited by examiner]
WO 2018090355A1 · 2018 [cited by applicant]
Diaz et al., An effective algorithm for hyperparameter optimization of neural networks, 2017 (Year: 2017). [cited by examiner]
International Search Report and Written Opinion for International Application No. PCT/CN2021/074263 mailed Oct. 27, 2021. [cited by applicant]
“Mobile Phone Screen Defect Detection Based on Deep Convolutional Neural Network,” University of Electronic Science and Technology of China (Alleged Publication: Jan. 15, 2020). [cited by applicant]
Extended European Search Report for EP Patent Application No. 21921830.2 of Jul. 11, 2023. [cited by applicant]
Jiang J, Cao P, Lu Z, Lou W, Yang Y. Surface Defect Detection for Mobile Phone Back Glass Based on Symmetric Convolutional Neural Network Deep Learning. Applied Sciences. 2020; 10(10):3621. https://doi.org/10.3390/app10… [cited by applicant]
First Office Action for JP Patent Application No. 2022-571810 of Dec. 16, 2024. [cited by applicant]
Machine Learning Practice (Hyperparameter Tuning), Kikagaku (Alleged Publication: Aug. 5, 2021). [cited by applicant]
Non-Final Office Action for U.S. Appl. No. 17/978,384 of Apr. 23, 2025. [cited by applicant]
Z. C. Lipton, C. Elkan, and B. Narayanaswamy, “Thresholding Classifiers to Maximize F1 Score,” arXiv preprint arXiv:1402.1892, May 2014. [Online]. Available: https://doi.org/10.48550/arXiv.1402.1892. [cited by applicant]