JPH10123064A - Visual inspection - Google Patents

Visual inspection

Info

Publication number
JPH10123064A
JPH10123064A JP28276296A JP28276296A JPH10123064A JP H10123064 A JPH10123064 A JP H10123064A JP 28276296 A JP28276296 A JP 28276296A JP 28276296 A JP28276296 A JP 28276296A JP H10123064 A JPH10123064 A JP H10123064A
Authority
JP
Japan
Prior art keywords
image
inspection
value
standard
standard deviation
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
JP28276296A
Other languages
Japanese (ja)
Inventor
Nobuo Katsube
展生 勝部
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.)
Proterial Ltd
Original Assignee
Hitachi Metals 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 Hitachi Metals Ltd filed Critical Hitachi Metals Ltd
Priority to JP28276296A priority Critical patent/JPH10123064A/en
Publication of JPH10123064A publication Critical patent/JPH10123064A/en
Pending legal-status Critical Current

Links

Abstract

PROBLEM TO BE SOLVED: To perform visual inspection depending on the size of a defect to be detected or the irregularities by comparing every pixel visually between a product to be inspected and an acceptable work. SOLUTION: At first, many acceptable works of same type as a product to be inspected are collected and the images thereof are picked up individually by means of a CCD camera. Average gray level and standard deviation are then calculated for the image data 1a-1n of many acceptable works subjected to multilevel gray level processing thus determining the standard image 2 and the standard deviation image 3 of the acceptable work. Subsequently, the image of the product to be inspected is picked up to be superposed on the image of the acceptable work by a mechanical method or an image processing method to obtain an inspection image 4. A differential image between the inspection image 4 and the standard image 2 is then obtained for every pixel and the ratio of the differential image to the standard deviation image 3 is also determined thus obtaining an inspection ratio image 5 indicative of distribution of the ratio. Finally, a decision value is determined in units of window defined by sectioning the inspection ratio image 5 into many predetermined number of sections of appropriate size and presence of a defect is determined by comparing the decision value with a standard decision value.

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【発明の属する技術分野】本発明は、画像処理により製
品の外観を検査する方法に係わり、特に鋳物のように表
面が粗い物に対して、欠陥と判定すべき異常凹凸部を検
出するのに有効な外観検査方法に関するものである。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a method for inspecting the appearance of a product by image processing, and more particularly to a method for detecting an abnormal uneven portion to be determined as a defect on a rough surface such as a casting. It relates to an effective appearance inspection method.

【0002】[0002]

【従来の技術】画像処理により製品の表面上の欠陥を検
出する方法は多数開発されている。特開平1−1439
38には、規則的なパターンに対してCCDカメラから
取り込んだ画像より画像処理装置にて画像全体にわたり
濃淡値の統計処理を行い、良品と欠陥品の濃淡値の統計
値の違いから欠陥判別を行う方法が開示されている。さ
らに特公平6−72780に示されているように、多数
の良品をある閾値で2値画像化を行い、その画素数を統
計処理を行い、その統計値の分布よりはずれたものを欠
陥品と判断する方法もある。
2. Description of the Related Art Many methods have been developed for detecting defects on the surface of a product by image processing. JP-A 1-1439
In step 38, the image processing device performs statistical processing of the grayscale value of the entire image from the image captured from the CCD camera for the regular pattern, and determines the defect based on the difference in the statistical value of the grayscale value between the non-defective product and the defective product. A method of doing so is disclosed. Further, as shown in Japanese Patent Publication No. 6-72780, a large number of non-defective products are binarized with a certain threshold value, the number of pixels is subjected to statistical processing, and those out of the distribution of the statistical values are regarded as defective products. There is a way to judge.

【0003】[0003]

【発明が解決しようとする課題】鋳物のような表面が粗
く、かつ製品毎に表面の状態が違うようなものに対して
は、異常凹凸である欠陥の濃淡値の情報は普通の表面荒
さによる濃淡値と混ざってしまい、前記2つの従来例の
ように単なる濃淡値の統計処理や、閾値による2値化画
素数の統計処理では、欠陥を信頼性高く検出することは
困難である。
In the case of a casting having a rough surface and a different surface condition for each product, information on the density value of a defect which is an abnormal unevenness is based on ordinary surface roughness. It is difficult to detect a defect with high reliability by statistical processing of a simple gray value or statistical processing of the number of binarized pixels by a threshold value as in the above two conventional examples.

【0004】[0004]

【課題を解決するための手段】本発明は、複数の良品ワ
ークを撮像して濃淡値を求め、同一箇所を撮像した画素
毎に濃淡値を平均した標準画像と標準偏差を求めた標準
偏差画像を求め、検査対象製品を撮像して濃淡値を求め
て表示した検査画像に対し、前記と同様同一箇所を撮像
した画素毎に標準画像との差を計算した後標準偏差画像
で割って比を求め、この数値分布を表示して検査比画像
とし、検査比画像を複数のウインドウに分割し、ウイン
ドウ内画素の数値の内、設定した閾値を越えるものだけ
を合計して判断値とし、別途良品ワークに対して求めた
判断値と比較して欠陥であるかどうかを判定することを
特徴とする手段を有している。
SUMMARY OF THE INVENTION According to the present invention, there is provided a standard deviation image in which a plurality of non-defective workpieces are imaged to obtain a grayscale value, and a standard image obtained by averaging the grayscale values for each pixel in which the same portion is imaged and a standard deviation are obtained. For the inspection image obtained by imaging the product to be inspected and calculating and displaying the gray value, the difference from the standard image is calculated for each pixel that has imaged the same place as above, and then divided by the standard deviation image to obtain the ratio. Then, this numerical distribution is displayed as an inspection ratio image, the inspection ratio image is divided into a plurality of windows, and only those exceeding the set threshold value among the numerical values of the pixels in the window are summed up as a judgment value. There is provided a means for determining whether a defect is present by comparing the determined value with respect to the work.

【0005】[0005]

【発明の実施の形態】本発明の実施の形態を図1を用い
て説明する。最初に検査対象製品と同一種類の良品ワー
クからデータを収集する。まず良品ワークを多数個集
め、個々にCCDカメラにより撮像を行う。撮像する時
は良品ワークを機械的方法により常に同じ位置になるよ
うに位置決めするか、画像処理的方法により製品の特徴
的外形情報をもとに画像を移動及び回転することで、画
像上で各良品ワークが同じ位置に重なるようにする。撮
像して多値濃淡値化処理をした多数の良品ワークの画像
データ1(1a,1b,…1n)に対し、図1(a)に
示す教示課程のように、同じ画素毎に濃淡値の平均値と
標準偏差値を計算し、良品ワークの標準画像2と標準偏
差画像3を求める。標準画像2は、良品表面の平均的な
荒さを濃淡値として表し、標準偏差画像3は荒さのばら
つきが出やすい箇所を濃淡値をもとにした数値の大きさ
で示すものである。
DESCRIPTION OF THE PREFERRED EMBODIMENTS An embodiment of the present invention will be described with reference to FIG. First, data is collected from non-defective work of the same type as the product to be inspected. First, many non-defective work pieces are collected and individually imaged by a CCD camera. When taking an image, a non-defective work is always positioned at the same position by a mechanical method, or the image is moved and rotated based on the characteristic outer shape information of the product by an image processing method. Make sure that good work overlaps at the same position. The image data 1 (1a, 1b,..., 1n) of many non-defective workpieces that have been imaged and subjected to the multi-value gray-scale processing are subjected to gray-scale values for the same pixel as in the teaching process shown in FIG. The average value and the standard deviation value are calculated, and the standard image 2 and the standard deviation image 3 of the non-defective work are obtained. The standard image 2 represents the average roughness of the surface of a non-defective product as a gray value, and the standard deviation image 3 shows a portion where the variation in roughness is likely to occur with a numerical value based on the gray value.

【0006】次に以上の画像データを基にした検査課程
について説明する。前述したと同様に、検査対象製品を
機械的方法又は画像処理的方法で良品ワークの画像に重
なるように撮像し、検査画像4とする。図1(b)の検
査課程に示すように、各画素毎に検査画像4と標準画像
2との差画像を求め、さらに各画素毎に標準偏差画像3
でその差画像を割ることにより、標準偏差画像との比を
求める。ここでこの比の値の分布を表示した画像を検査
比画像5と呼ぶこととする。この検査比画像5により、
各画素毎の標準偏差を考慮した画像が得られる。これに
より、表面荒さ状態がばらつき易い箇所の影響を補正し
て検査対象製品の荒さ分布を数値(以降補正値と呼ぶ)
として表すことができる。
Next, an inspection process based on the above image data will be described. In the same manner as described above, the inspection target product is imaged by a mechanical method or an image processing method so as to overlap the image of the non-defective work, and the inspection image 4 is obtained. As shown in the inspection process of FIG. 1B, a difference image between the inspection image 4 and the standard image 2 is obtained for each pixel, and a standard deviation image 3 is obtained for each pixel.
By dividing the difference image by, the ratio with the standard deviation image is obtained. Here, an image displaying the distribution of the ratio values is referred to as an inspection ratio image 5. According to the inspection ratio image 5,
An image is obtained in consideration of the standard deviation of each pixel. As a result, the influence of the portion where the surface roughness state tends to vary is corrected, and the roughness distribution of the product to be inspected is represented by a numerical value (hereinafter referred to as a correction value).
Can be expressed as

【0007】欠陥の有無は、検査比画像を予め決めた多
数の適当な大きさのウインドウに区切り、ウインドウ単
位で判断値を求め、基準の判断値と比較して判定する。
判断値は、ウインドウ中の画素の内、前記補正値が設定
した閾値を越えた画素についての補正値の合計値であ
る。例えば閾値を絶対値1とすれば、画素の補正値の絶
対値が1未満の場合は0とし、1以上の場合はその補正
値をそのまま合計する。
The presence or absence of a defect is determined by dividing the inspection ratio image into a large number of windows of a predetermined appropriate size, obtaining a judgment value for each window, and comparing the judgment value with a reference judgment value.
The judgment value is the total value of the correction values for the pixels in the window whose correction value exceeds the set threshold value. For example, if the absolute value of the threshold value is 1, if the absolute value of the correction value of the pixel is less than 1, it is 0, and if it is 1 or more, the correction values are summed as they are.

【0008】一方、前記で標準画像2と標準偏差画像3
を求めた個々の良品ワーク1に対しても、標準画像2と
標準偏差画像3を用いて検査比画像5を求め、前記と同
様に各ウインドウ毎に判断値を求めておく。この求めた
判断値の中から、適宜基準判定値を選定して用いる。基
準判定値は、上記良品ワークの判定値の内、ウインドウ
毎に一番欠陥品に近い値を示すものを使用すると、きめ
細かく信頼性の高い検査をすることができる。これよ
り、ウインドウ毎に検査製品の判断値が、基準とする良
品ワークの判断値に比べて大きければ、そのウインドウ
内に欠陥が有ると判断する。ウインドウの大きさは、画
素の大きさに対する検査の対象とする欠陥面積の大きさ
で適宜決めればよい。
On the other hand, the standard image 2 and the standard deviation image 3
Is determined using the standard image 2 and the standard deviation image 3 for each of the non-defective work pieces 1 for which is determined, and the judgment value is determined for each window in the same manner as described above. From the obtained judgment values, a reference judgment value is appropriately selected and used. As the reference determination value, a value indicating the value closest to the defective product for each window among the determination values of the non-defective work can be used to perform a detailed and highly reliable inspection. From this, if the judgment value of the inspection product is larger than the judgment value of the reference non-defective work for each window, it is judged that there is a defect in the window. The size of the window may be appropriately determined based on the size of the defect area to be inspected with respect to the size of the pixel.

【0009】[0009]

【実施例】以上の方法を用いて、外観の異常凹凸の欠陥
検出を行った例を示す。本例では、1画素0.2mm、
ウインドウのサイズを64画素×64画素、濃淡は25
6階調とし、標準画像と標準偏差画像は良品ワーク19
個を撮像して求めた。濃淡値は凹部が深いほどプラス数
値が大きく、凸部が高いほどマイナス数値が大きくなっ
た。
EXAMPLE An example in which a defect having abnormal irregularities in appearance is detected using the above method will be described. In this example, one pixel is 0.2 mm,
The size of the window is 64 pixels x 64 pixels, and the shade is 25
The standard image and the standard deviation image are 6 good gradations.
The number was obtained by imaging. As for the shading value, the deeper the concave portion, the larger the positive value, and the higher the convex portion, the larger the negative value.

【0010】図4は検査したワークのある1つのウイン
ドウの判定値をまとめたものである。一番上段のNo1ワ
ークは欠陥を有するもので、No2ワーク以降の19個の
ワークは欠陥を有しない標準画像と標準偏差画像を求め
た良品ワークである。図2及び図3に、図4におけるNo
1ワークとNo2ワークの同一箇所のウインドウの検査比画
像を示す。図2で示すウインドウ内には目視検査で欠陥
として判断された凹部が存する。図3で示すウインドウ
内には目視検査では欠陥面は存しない。図2において左
上中央付近に補正値10以上の画素集団部分があるが、
この部分が目視で異常凹部と判断された部分である。
FIG. 4 summarizes the judgment values of one window of the inspected work. The top No. 1 work has a defect, and the 19 works after the No. 2 work are non-defective work in which a standard image and a standard deviation image having no defect are obtained. FIG. 2 and FIG.
The inspection ratio image of the window of the same part of 1 work and No. 2 work is shown. In the window shown in FIG. 2, there is a concave portion determined as a defect by visual inspection. There is no defective surface in the window shown in FIG. 3 by visual inspection. In FIG. 2, there is a pixel group portion having a correction value of 10 or more near the upper left center,
This portion is a portion visually determined to be an abnormal concave portion.

【0011】図4中横列は、閾値を変えた時の判定値の
変化を示すものである。記号sigの後に記す数値が閾
値を示している。例えば左端のsig0は閾値は0、即
ちウインドウ内の検査比画像の値をすべて加えたもので
あり、sig1とは検査比画像の絶対値が1未満を0と
し、1以上の画素は絶対値を加えて判断値とした場合で
ある。また、sig1−3は、検査比画像値が−1〜3
の場合は0とし、それ以外の場合は、絶対値を加えて判
断値とした場合である。最下段のSN比は欠陥の検出の
しやすさを示しており、この値が高ければ、良品製品と
欠陥製品との差が大きく検出が容易であることを示し、
下式で表す。 20×log(欠陥製品の判断値/良品中最大の判断
値) 図4の結果より、sig3、sig4又はsig2−3
として決めた閾値を用いると、欠陥有無判断が信頼性高
くできることがわかった。
The rows in FIG. 4 show changes in the judgment value when the threshold value is changed. The numerical value described after the symbol sig indicates the threshold. For example, sig0 at the left end is a threshold value of 0, that is, a value obtained by adding all the values of the inspection ratio image in the window, and sig1 is 0 when the absolute value of the inspection ratio image is less than 1 and the pixel of 1 or more has the absolute value. In addition, this is a case where a judgment value is used. In addition, sig1-3 has an inspection ratio image value of -1 to 3
Is 0, and in other cases, the judgment value is obtained by adding the absolute value. The S / N ratio at the bottom indicates the ease of detecting a defect. If this value is high, the difference between a good product and a defective product is large, indicating that detection is easy,
It is represented by the following equation. 20 × log (judgment value of defective product / maximum judgment value of non-defective products) From the results of FIG. 4, sig3, sig4, or sig2-3
It was found that the use of the threshold value determined as described above makes it possible to determine the presence or absence of a defect with high reliability.

【0012】[0012]

【発明の効果】本発明は上述したような手段を用いてい
るため次のような効果を有している。検査対象製品と良
品ワークの外観を画素毎に比較処理するので、外観細部
の情報を収集することができる。さらに、この情報をあ
るエリア毎に再処理して欠陥の有無として判断するの
で、前記細部の情報を平均化して判定することができ、
ノイズを欠陥と判定する恐れが少ない。また、エリアの
大きさは適宜設定することができるし、欠陥判定のため
の再処理判定基準もエリア毎に設定できるので、検出す
べき欠陥の大小又は凹凸程度に合わせて検出することが
できる。
The present invention has the following effects because it uses the means described above. Since the appearance of the inspection target product and the appearance of the non-defective work are compared for each pixel, information on the appearance details can be collected. Further, since this information is reprocessed for each certain area to determine the presence or absence of a defect, the information of the details can be averaged and determined.
There is little risk of determining noise as a defect. In addition, the size of the area can be set as appropriate, and the reprocessing judgment criterion for defect judgment can be set for each area, so that the defect can be detected in accordance with the size of the defect to be detected or the degree of irregularity.

【図面の簡単な説明】[Brief description of the drawings]

【図1】検査方法を示すアルゴリズム図FIG. 1 is an algorithm diagram showing an inspection method.

【図2】欠陥部を有する検査比画像例FIG. 2 is an example of an inspection ratio image having a defective portion.

【図3】欠陥部を有しない検査比画像例FIG. 3 is an example of an inspection ratio image having no defect portion.

【図4】閾値を変えたときの判断値を示す測定結果例FIG. 4 is a measurement result example showing a judgment value when a threshold value is changed.

【符号の説明】[Explanation of symbols]

1 良品ワークの濃淡表示画像 2 標準画像 3 標準偏差画像 4 検査画像 5 検査比画像 1 Contrast display image of good work 2 Standard image 3 Standard deviation image 4 Inspection image 5 Inspection ratio image

Claims (1)

【特許請求の範囲】[Claims] 【請求項1】 複数の良品ワークを撮像して濃淡値を求
め、同一箇所を撮像した画素毎に濃淡値を平均した標準
画像と標準偏差を求めた標準偏差画像を求め、検査対象
製品を撮像して濃淡値を求めて表示した検査画像に対
し、前記と同様同一箇所を撮像した画素毎に標準画像と
の差を計算した後標準偏差画像で割って比を求め、この
数値分布を表示して検査比画像とし、検査比画像を複数
のウインドウに分割し、ウインドウ内画素の数値の内、
設定した閾値を越えるものだけを合計して判断値とし、
別途良品ワークに対して求めた判断値と比較して欠陥で
あるかどうかを判定することを特徴とする外観検査方
法。
An image of a plurality of non-defective products is obtained to obtain a gray value, a standard image obtained by averaging the gray values for each pixel of the same portion, and a standard deviation image obtained by obtaining a standard deviation, and an image of a product to be inspected is obtained. For the inspection image displayed by calculating and displaying the gray value, the difference from the standard image is calculated for each pixel that has captured the same location as described above, then divided by the standard deviation image to obtain the ratio, and this numerical distribution is displayed. The inspection ratio image is divided into a plurality of windows, and among the numerical values of the pixels in the window,
Only those exceeding the set threshold are summed up as a judgment value,
An appearance inspection method characterized in that it is determined whether or not there is a defect by comparing with a judgment value separately obtained for a non-defective work.
JP28276296A 1996-10-24 1996-10-24 Visual inspection Pending JPH10123064A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP28276296A JPH10123064A (en) 1996-10-24 1996-10-24 Visual inspection

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP28276296A JPH10123064A (en) 1996-10-24 1996-10-24 Visual inspection

Publications (1)

Publication Number Publication Date
JPH10123064A true JPH10123064A (en) 1998-05-15

Family

ID=17656747

Family Applications (1)

Application Number Title Priority Date Filing Date
JP28276296A Pending JPH10123064A (en) 1996-10-24 1996-10-24 Visual inspection

Country Status (1)

Country Link
JP (1) JPH10123064A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2004185259A (en) * 2002-12-03 2004-07-02 Renesas Technology Corp Storage image managing device and program
JPWO2004036198A1 (en) * 2002-10-18 2006-02-16 株式会社キリンテクノシステム Method and apparatus for creating reference image in glass bottle inspection apparatus
KR100855100B1 (en) 2005-04-01 2008-08-29 도쿄 세이미츄 코퍼레이션 리미티드 Appearance inspection apparatus and appearance inspection method
KR20180118754A (en) 2016-03-07 2018-10-31 토레이 엔지니어링 컴퍼니, 리미티드 Defect inspection apparatus

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPWO2004036198A1 (en) * 2002-10-18 2006-02-16 株式会社キリンテクノシステム Method and apparatus for creating reference image in glass bottle inspection apparatus
JP2004185259A (en) * 2002-12-03 2004-07-02 Renesas Technology Corp Storage image managing device and program
KR100855100B1 (en) 2005-04-01 2008-08-29 도쿄 세이미츄 코퍼레이션 리미티드 Appearance inspection apparatus and appearance inspection method
KR20180118754A (en) 2016-03-07 2018-10-31 토레이 엔지니어링 컴퍼니, 리미티드 Defect inspection apparatus

Similar Documents

Publication Publication Date Title
JP2001264257A (en) Image defect detecting device and method, and storage medium storing procedure for image defect detecting method
JP2003083907A (en) Defect inspecting method and its apparatus
JP4244046B2 (en) Image processing method and image processing apparatus
JP4318776B2 (en) Nonuniformity inspection method and apparatus
JPH10123064A (en) Visual inspection
JP5498109B2 (en) Defect detection apparatus and defect detection method
JP4293653B2 (en) Appearance inspection method
JP4403036B2 (en) Soot detection method and apparatus
JP2006170635A (en) Detector of flaw by image processing and flaw detecting method using it
JPH08145907A (en) Inspection equipment of defect
JP2010071980A (en) Fin extraction inspection method of heat exchanger
JP3127598B2 (en) Method for extracting density-varying constituent pixels in image and method for determining density-fluctuation block
JP2000329699A (en) Method and apparatus for inspection of defect
US6335982B1 (en) Method and apparatus for inspecting streak
JP2001028059A (en) Method and device for color unevenness inspection
JP2007081513A (en) Blot defect detecting method for solid-state imaging element
JP3015325B2 (en) Streak inspection method and device
JP2004170374A (en) Apparatus and method for detecting surface defect
KR20110020437A (en) Inspection method of patterned wafer for detecting defects
JP5666894B2 (en) Appearance inspection apparatus and appearance inspection method
JPH10160684A (en) Appearance inspection method
JP2004053477A (en) Color irregularity inspecting method and apparatus
JP2004286708A (en) Defect detection apparatus, method, and program
JPH05203584A (en) Device for detecting characteristic amount on work surface
JP2988059B2 (en) Circular container inner surface inspection device