CN112070710A - Method for detecting industrial product defect image - Google Patents

Method for detecting industrial product defect image Download PDF

Info

Publication number
CN112070710A
CN112070710A CN201910530470.1A CN201910530470A CN112070710A CN 112070710 A CN112070710 A CN 112070710A CN 201910530470 A CN201910530470 A CN 201910530470A CN 112070710 A CN112070710 A CN 112070710A
Authority
CN
China
Prior art keywords
value
sample
defects
pixel point
image
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201910530470.1A
Other languages
Chinese (zh)
Inventor
不公告发明人
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Pingheng Intelligent Technology Co ltd
Original Assignee
Beijing Pingheng Intelligent Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Pingheng Intelligent Technology Co ltd filed Critical Beijing Pingheng Intelligent Technology Co ltd
Priority to CN201910530470.1A priority Critical patent/CN112070710A/en
Publication of CN112070710A publication Critical patent/CN112070710A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/0002Inspection of images, e.g. flaw detection
    • G06T7/0004Industrial image inspection
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01NINVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
    • G01N21/00Investigating or analysing materials by the use of optical means, i.e. using sub-millimetre waves, infrared, visible or ultraviolet light
    • G01N21/84Systems specially adapted for particular applications
    • G01N21/88Investigating the presence of flaws or contamination
    • G01N21/8851Scan or image signal processing specially adapted therefor, e.g. for scan signal adjustment, for detecting different kinds of defects, for compensating for structures, markings, edges
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01NINVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
    • G01N21/00Investigating or analysing materials by the use of optical means, i.e. using sub-millimetre waves, infrared, visible or ultraviolet light
    • G01N21/84Systems specially adapted for particular applications
    • G01N21/88Investigating the presence of flaws or contamination
    • G01N21/8851Scan or image signal processing specially adapted therefor, e.g. for scan signal adjustment, for detecting different kinds of defects, for compensating for structures, markings, edges
    • G01N2021/8854Grading and classifying of flaws
    • G01N2021/888Marking defects
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10004Still image; Photographic image
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30108Industrial image inspection

Landscapes

  • Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Physics & Mathematics (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Biochemistry (AREA)
  • Signal Processing (AREA)
  • Health & Medical Sciences (AREA)
  • Quality & Reliability (AREA)
  • Chemical & Material Sciences (AREA)
  • Analytical Chemistry (AREA)
  • Theoretical Computer Science (AREA)
  • General Health & Medical Sciences (AREA)
  • Immunology (AREA)
  • Pathology (AREA)
  • Image Analysis (AREA)
  • Image Processing (AREA)
  • Investigating Materials By The Use Of Optical Means Adapted For Particular Applications (AREA)

Abstract

The industrial product defect image detection method is divided into two parts which are sequentially executed: (1) firstly, acquiring a certain number of industrial product images without defects in real time, and carrying out statistical analysis on the industrial product images to obtain an acceptance domain; (2) then analyzing the known sample image (i.e. knowing whether the sample has defects) to obtain the number of pixel points with the gray value of 255, and when the number value is within the range of the acceptance domain, judging the sample as a normal sample without defects by the method; when the magnitude value is outside the range of the acceptance domain, the method judges the sample as a defective sample. The method uses the accuracy as an index to measure the quality of the forecast. The method inhibits the interference of imaging noise caused by various errors in the industrial image acquisition process to industrial detection to a certain extent, and has good detection effect on the film defects with small background and target gray difference.

Description

Method for detecting industrial product defect image
Technical Field
The invention relates to the field of industrial product defect detection, in particular to a method for detecting industrial product defect images.
Background
For industrial product defect image detection, selecting a proper image segmentation threshold value is important. If the threshold value is selected too large, the target defect is misjudged as the background, and the condition of missing detection occurs; on the contrary, if the threshold is too small, the background is erroneously determined as the target defect, and the normal product is erroneously determined as the defect. The film defects (generally including scratches, creases, sharp concave-convex points, bubbles and the like) in industrial products are detected, because the gray difference between a target defect and a background is very small, an image segmentation threshold value is not easy to select, and in addition, the influence of random errors, system errors and large errors caused by human factors in the process of acquiring images in real time in the industry causes difficulty in detecting the defects of the industrial film to a certain extent.
At present, a common image segmentation algorithm is that people like wang jin jiang determine a segmentation threshold value by a bimodal method through smooth filtering and histogram analysis, and the film defect image is simply and effectively segmented. However, this method is only effective when the gray values of the target defect are very different from the background and the histogram shows significant double peaks. The background difference algorithm described by harlefa (a.khalifa) et al has a narrow application range, and the conventional background difference algorithm is effective only when the background is constant, but is not suitable for the situation where the background image changes slowly or violently. The maximum entropy threshold segmentation method is proposed by Kapur and the like, and the entropy relates to logarithm operation, so that the time overhead is large, and the requirement on real-time performance is difficult to meet.
Disclosure of Invention
In order to solve the problems, the invention provides an industrial product defect image detection method based on statistical analysis, which eliminates the influence of various errors in the process of acquiring images in real time in industry to imaging to a certain extent, can provide a better image segmentation threshold value for the defects of the industrial thin film with small difference between the target defects and the background gray level, and realizes the judgment on whether the industrial thin film has defects or not by adjusting parameters and selecting a proper acceptance domain.
The solution of the invention is divided into two parts which are executed in sequence: (1) firstly, acquiring a certain number of industrial product images without defects in real time, and carrying out statistical analysis on the industrial product images to obtain an acceptance domain; (2) then analyzing the known sample image (i.e. whether the known sample has defects) to obtain the number of pixel points with the gray value of 255, and when the numerical value is within the range of the acceptance domain, judging the sample as a normal sample without defects; when the magnitude value is outside the range of the acceptance domain, the sample is determined to be a defective sample.
Drawings
FIG. 1 is a schematic flow chart of a method of industrial defect image detection of the present invention;
FIG. 2 is a captured image of an industrial film without a defect site;
FIG. 3 is an image of an industrial film with scratch defects;
FIG. 4 is a view of the flowchart of FIG. 3, which is compiled after being written in vs2013 by c + +, and the defect portion is white;
FIG. 5 is an image of an industrial film with a crease defect, the crease being located within a red circle;
FIG. 6 is a diagram of an image compiled after being written in vs2013 by c + + according to the flow shown in FIG. 1 and generated by FIG. 5, wherein a defect part is white and is located in a red circle;
FIG. 7 is an image of an industrial film with sharp asperity defects;
FIG. 8 is a view of the flowchart of FIG. 7, which shows the defect portion is white, in a view of the image compiled after being written in vs2013 in c + +, according to the flow shown in FIG. 1;
Detailed Description
The method is further illustrated below with reference to the examples and the description of the figures.
1) Firstly, counting the industrial thin film images of positive samples (samples without defects) with the same size collected in real time, and calculating the average value of the gray value of each pixel point of the images. In the present embodiment, the number of the collected positive sample images is 5, one of which is shown in fig. 2;
2) further calculating the standard deviation of the gray value of each pixel point;
3) multiplying an adjustable parameter by the standard deviation of the gray value of each pixel point to obtain the threshold value of each pixel point;
4) and traversing each pixel point of each image in the positive sample image set, and comparing the separation value (the absolute value of the difference between the gray value and the average value) of the pixel points at the same position with the threshold value. If the dispersion value is larger than the threshold value, setting the gray value of the pixel point to be 255; if the dispersion value is less than or equal to the threshold value, setting the gray value of the pixel point to be 0;
5) counting the number of pixel points with the gray value of 255 of each image in the positive sample image set;
6) in order to improve the prediction accuracy, in this embodiment, corresponding adjustment parameters are finally determined by continuously debugging different types of defects, and of course, the mean value of the adjustment parameters corresponding to different types of defects may also be taken as a uniform adjustment parameter, so as to perform uniform processing on the different types of defects, and the mean value of the number of pixels whose image gray values in the positive sample image set are equal to 255 is obtained on the basis of 5), and the mean value smaller than or equal to the mean value is selected as an acceptance domain, and the mean value larger than the mean value is selected as a rejection domain;
7) finally, in the present embodiment, three industrial thin film defect sample images as shown in fig. 3, 5, and 7 collected under the same condition are tested by the method, the number of pixels with the calculated image gray value equal to 255 falls within the reject region, and the samples determined to have defects are determined to have defects, and the defects are marked with white marks as shown in fig. 4, 6, and 8, respectively.
The final result shows that the method has obvious segmentation effect on the industrial thin film defect image with small difference between the target defect and the background gray value. With the increase of the number of the positive sample images acquired in real time, the segmentation effect is more obvious, and the prediction accuracy is further improved.

Claims (3)

1. The method for detecting the industrial product defect image is characterized by being divided into two parts which are sequentially executed:
1) firstly, acquiring a certain number of industrial product images without defects in real time, and carrying out statistical analysis on the industrial product images to obtain an acceptance domain;
2) analyzing a known sample image (namely whether a known sample has defects) to obtain the number of pixel points with the gray value of 255, and judging the sample as a normal sample without defects when the numerical value is within the range of an acceptance domain; when the magnitude value is outside the range of the acceptance domain, the method judges the sample as a defective sample.
2. The industrial product defect image detection method according to claim 1, characterized in that:
1) counting positive sample (sample without defects) images which are collected in real time and have the same size, and calculating the average value of the gray value of each pixel point of the images;
2) further calculating the standard deviation of the gray value of each pixel point;
3) multiplying an adjustable parameter by the standard deviation of the gray value of each pixel point to obtain the threshold value of each pixel point;
4) traversing each pixel point of each image in the positive sample image set, comparing the deviation value (the absolute value of the difference between the gray value and the average value) of the pixel point at the same position with the threshold value, and if the deviation value is greater than the threshold value, setting the gray value of the pixel point to be 255; if the dispersion value is less than or equal to the threshold value, setting the gray value of the pixel point to be 0;
5) and counting the number of pixels with the gray value of 255 in each image in the positive sample image set so as to determine a proper receiving domain.
3. The method as claimed in claim 1, wherein the accuracy index is used to measure how well the method predicts, and in order to improve the prediction accuracy, different adjustment parameters and acceptance domains need to be tested until the result is satisfactory.
CN201910530470.1A 2019-06-10 2019-06-10 Method for detecting industrial product defect image Pending CN112070710A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910530470.1A CN112070710A (en) 2019-06-10 2019-06-10 Method for detecting industrial product defect image

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910530470.1A CN112070710A (en) 2019-06-10 2019-06-10 Method for detecting industrial product defect image

Publications (1)

Publication Number Publication Date
CN112070710A true CN112070710A (en) 2020-12-11

Family

ID=73658617

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910530470.1A Pending CN112070710A (en) 2019-06-10 2019-06-10 Method for detecting industrial product defect image

Country Status (1)

Country Link
CN (1) CN112070710A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115684176A (en) * 2022-10-24 2023-02-03 浙江荣图智能科技有限公司 Online visual inspection system for film surface defects

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1285910A (en) * 1997-11-14 2001-02-28 韦斯利-杰森公司 Automatic lens inspection system
US20060144335A1 (en) * 2004-12-30 2006-07-06 Research Electro-Optics, Inc. Methods and devices for monitoring and controlling thin film processing
US20060250129A1 (en) * 2005-04-07 2006-11-09 National Yunlin University Of Science And Technology Method of measuring sub-micrometer hysteresis loops of magnetic films
CN101236914A (en) * 2007-01-29 2008-08-06 精工电子有限公司 Wafer appearance detection device
CN103413288A (en) * 2013-08-27 2013-11-27 南京大学 LCD general defect detecting method
CN104792794A (en) * 2015-04-28 2015-07-22 武汉工程大学 Machine vision based optical film surface defect detecting method
CN107657606A (en) * 2017-09-18 2018-02-02 深圳市华星光电半导体显示技术有限公司 The luminance defects detection method and device of a kind of display device
CN107993225A (en) * 2017-11-28 2018-05-04 电子科技大学 A kind of recognition methods of the defects of magneto-optic vortex imaging detection
CN109377485A (en) * 2018-10-12 2019-02-22 龙口味美思环保科技有限公司 A kind of instant noodles packaging defect machine vision detection method

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1285910A (en) * 1997-11-14 2001-02-28 韦斯利-杰森公司 Automatic lens inspection system
US20060144335A1 (en) * 2004-12-30 2006-07-06 Research Electro-Optics, Inc. Methods and devices for monitoring and controlling thin film processing
US20060250129A1 (en) * 2005-04-07 2006-11-09 National Yunlin University Of Science And Technology Method of measuring sub-micrometer hysteresis loops of magnetic films
CN101236914A (en) * 2007-01-29 2008-08-06 精工电子有限公司 Wafer appearance detection device
CN103413288A (en) * 2013-08-27 2013-11-27 南京大学 LCD general defect detecting method
CN104792794A (en) * 2015-04-28 2015-07-22 武汉工程大学 Machine vision based optical film surface defect detecting method
CN107657606A (en) * 2017-09-18 2018-02-02 深圳市华星光电半导体显示技术有限公司 The luminance defects detection method and device of a kind of display device
CN107993225A (en) * 2017-11-28 2018-05-04 电子科技大学 A kind of recognition methods of the defects of magneto-optic vortex imaging detection
CN109377485A (en) * 2018-10-12 2019-02-22 龙口味美思环保科技有限公司 A kind of instant noodles packaging defect machine vision detection method

Non-Patent Citations (6)

* Cited by examiner, † Cited by third party
Title
XIAOLONG BAI 等: "Saliency-Based Defect Detection in Industrial Images by Using Phase Spectrum", 《IEEE TRANSACTIONS ON INDUSTRIAL INFORMATICS》, vol. 10, no. 04, 30 November 2014 (2014-11-30), pages 2135 - 2145, XP011563681, DOI: 10.1109/TII.2014.2359416 *
卢伟康: "薄膜的瑕疵检测与下料分切研究", 《中国优秀硕士学位论文全文数据库信息科技辑》, no. 2015, 15 January 2015 (2015-01-15), pages 138 - 1371 *
宋斌: "基于平均中值离差的二维最小误差分割算法研究", 《中国优秀硕士学位论文全文数据库信息科技辑》, no. 2016, 15 April 2016 (2016-04-15), pages 138 - 1333 *
李俊峰: "灰色系统理论及其在铁谱磨粒图像处理中的应用研究", 《中国博士学位论文全文数据库工程科技Ⅱ辑》, no. 2010, 15 August 2010 (2010-08-15), pages 029 - 1 *
肖朋: "半导体晶圆匀胶系统在线缺陷检测方法研究", 《中国优秀硕士学位论文全文数据库信息科技辑》, no. 2017, 15 May 2017 (2017-05-15), pages 135 - 77 *
郭轩: "彩色印刷品视觉检测相关算法研究", 《中国博士学位论文全文数据库信息科技辑》, no. 2010, 15 November 2010 (2010-11-15), pages 138 - 64 *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115684176A (en) * 2022-10-24 2023-02-03 浙江荣图智能科技有限公司 Online visual inspection system for film surface defects

Similar Documents

Publication Publication Date Title
CN114549522B (en) Textile quality detection method based on target detection
CN109410230B (en) Improved Canny image edge detection method capable of resisting noise
CN115018844B (en) Plastic film quality evaluation method based on artificial intelligence
CN114170208A (en) Paper product defect detection method based on artificial intelligence
CN104101600B (en) Cross Section of CC Billet testing of small cracks method
CN115100206B (en) Printing defect identification method for textile with periodic pattern
CN116843678A (en) Hard carbon electrode production quality detection method
CN115684176B (en) Online visual detection system for film surface defects
CN114549441B (en) Straw defect detection method based on image processing
CN114723704A (en) Textile quality evaluation method based on image processing
CN109239073A (en) A kind of detection method of surface flaw for body of a motor car
CN108399614B (en) Fabric defect detection method based on non-sampling wavelet and Gumbel distribution
CN116612112B (en) Visual inspection method for surface defects of bucket
CN113155839A (en) Steel plate outer surface defect online detection method based on machine vision
CN112862744A (en) Intelligent detection method for internal defects of capacitor based on ultrasonic image
Yao et al. Inspection of rice appearance quality using machine vision
CN113435460A (en) Method for identifying brilliant particle limestone image
CN117237747B (en) Hardware defect classification and identification method based on artificial intelligence
CN116993742A (en) Nickel alloy rolling defect detection method based on machine vision
CN115018790A (en) Workpiece surface defect detection method based on anomaly detection
CN114155226A (en) Micro defect edge calculation method
CN112070710A (en) Method for detecting industrial product defect image
CN117036259A (en) Metal plate surface defect detection method based on deep learning
CN114820611B (en) Artificial intelligence-based mechanical part quality evaluation method and system
CN114998346B (en) Waterproof cloth quality data processing and identifying method

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
DD01 Delivery of document by public notice
DD01 Delivery of document by public notice

Addressee: Fan Fenghua

Document name: Notice of First Examination Opinion