JPH07333173A - Defective pattern detection method and device therefor - Google Patents

Defective pattern detection method and device therefor

Info

Publication number
JPH07333173A
JPH07333173A JP6126362A JP12636294A JPH07333173A JP H07333173 A JPH07333173 A JP H07333173A JP 6126362 A JP6126362 A JP 6126362A JP 12636294 A JP12636294 A JP 12636294A JP H07333173 A JPH07333173 A JP H07333173A
Authority
JP
Japan
Prior art keywords
image
pixel
value
difference
circuit
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.)
Granted
Application number
JP6126362A
Other languages
Japanese (ja)
Other versions
JP3400859B2 (en
Inventor
Seiji Hata
清治 秦
Hideyuki Hanabusa
秀行 花房
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.)
HEWTEC KK
Kagawa University NUC
Original Assignee
HEWTEC KK
Kagawa University NUC
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 HEWTEC KK, Kagawa University NUC filed Critical HEWTEC KK
Priority to JP12636294A priority Critical patent/JP3400859B2/en
Publication of JPH07333173A publication Critical patent/JPH07333173A/en
Application granted granted Critical
Publication of JP3400859B2 publication Critical patent/JP3400859B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Abstract

PURPOSE:To make a correction for an intermediate picture element value appearing due to the characteristics of a photographing system, as well as a correction for the superposing position of images, depending on the fine expansion, reduction, dislocation or the like of a pattern boundary CONSTITUTION:A hysteresis processing circuit 12 is provided for changing the value of a target picture element, using a value nearer the value of the element among maximum and minimum values within a window around the target picture element. Furthermore, a direction determination circuit 14 is provided to find a variation in X and Y directions for every picture element regarding an image (standard image) from a photographed image and a delay circuit 13, and identifying the dislocation of a photographed position from four types of patterns, together with a window selector circuit 18 for cutting out three types of 3X3 picture element windows from the photographed image, depending on the identified pattern. In addition, comparison circuits 15, 16 and 17 are provided to make a comparison between the cutout windows and images from the circuit 13, and evaluating a resulting difference, thereby selecting the minimum value of evaluation data from each of the circuits 15 to 17.

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【産業上の利用分野】この発明は、撮像対象、例えば印
刷媒体に印刷された模様や文字・記号等のパターンにつ
いて、印刷漏れや異物付着、損傷等の欠陥を検出する欠
陥パターンの検出方法及びその装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a defect pattern detecting method for detecting defects such as print omissions, foreign matter adhesion, and damages on an imaged object, for example, a pattern such as a pattern or characters or symbols printed on a print medium. Regarding the device.

【0002】[0002]

【従来の技術】従来の欠陥パターン検出装置において
は、複数枚の同じ印刷パターンを一定の周期で読取り、
読み取った印刷パターンの入力画像を1周期前に読取っ
た印刷パターン( 標準パターン )の画像と重ね合わせ、
その相違部を抽出する方式が取られていた。
2. Description of the Related Art In a conventional defect pattern detecting apparatus, a plurality of identical print patterns are read at a constant cycle,
Overlay the read print pattern input image with the print pattern (standard pattern) image read one cycle before,
The method of extracting the different part was taken.

【0003】この相違部の抽出方法は、たえず最新の画
像を標準パターンとして使用しているために、照明条件
の変動に対処しやすいとか、画像ずれなどに対しても、
直前の画像に対する相対位置が問題になるだけであるか
ら、それほど大幅なずれが生じるという問題はない、と
いう特徴をもっている。
In this method of extracting the difference portion, since the latest image is always used as the standard pattern, it is easy to deal with the fluctuation of the illumination condition, the image shift, etc.
Since the relative position with respect to the immediately preceding image is only a problem, there is no problem that a large deviation occurs.

【0004】[0004]

【発明が解決しようとする課題】しかし、画像の境界部
では、明るさ変化が模様( パターン )の変化に合わせて
急峻な変動を有するので、これを実際に画像化した場
合、画素値が2つの領域の明るさの中間値を取ることに
なる。
However, in the boundary portion of the image, the brightness change has a sharp change in accordance with the change of the pattern, and therefore, when this is actually imaged, the pixel value is 2 It will take the mean value of the brightness of the two areas.

【0005】この中間値が、撮像系の光学的ボケや撮像
素子への模様パターンの結像位置の微妙なずれのために
標準画像と対象画像とで一定値とならず、比較時のエラ
ーとなってしまい、従来マスク処理等により境界部を比
較しないようにしていたが、これでは画像境界部の精密
な欠陥検出はできないという問題があった。また、印刷
時の模様の位置もインクの量や粘度で微妙に食い違い、
この事も細かい模様や模様の境界部での欠陥検出を困難
なものにしていた。
This intermediate value does not become a constant value between the standard image and the target image due to the optical blur of the image pickup system and the slight shift of the image forming position of the pattern pattern on the image pickup element, which causes an error at the time of comparison. Therefore, the conventional masking process or the like has been made so as not to compare the boundary portions, but this has a problem that it is not possible to accurately detect the defect at the image boundary portion. Also, the position of the pattern during printing is slightly different depending on the amount and viscosity of the ink,
This also makes it difficult to detect defects in fine patterns and pattern boundaries.

【0006】さらに、従来の欠陥パターン検出装置にお
いて、これから欠陥パターンを検査する複数の印刷パタ
ーンを整列配置したシートは、ロール状に巻回されて装
置にセットされるので、ロールから引き出されたシート
は反っており、この反った状態でシート上に配置された
印刷パターンを撮像すると、比較対象となる標準パター
ンと撮像位置のずれが生じ、実際には、この撮像位置の
ずれにより欠陥パターンでないのに欠陥パターンと検出
されてしまうという問題があった。
Further, in the conventional defect pattern detecting apparatus, a sheet on which a plurality of print patterns for inspecting a defect pattern are arranged is wound in a roll shape and set in the apparatus. Therefore, the sheet pulled out from the roll. When the print pattern arranged on the sheet is imaged in this warped state, a deviation occurs in the image pickup position from the standard pattern to be compared. In reality, the image pickup position is not a defective pattern. There was a problem that it was detected as a defective pattern.

【0007】そこでこの発明は、印刷パターンの細かい
模様や模様の境界部で発生する、撮像系の特性のために
生じる各画素の中間的な画素値を補正し、模様の境界部
の微妙な拡大、縮小、ずれなどに応じて画像の重ね合わ
せ位置を補正することができる欠陥パターンの検出方法
及びその装置を提供することを目的とする。
Therefore, the present invention corrects an intermediate pixel value of each pixel, which occurs due to the characteristics of the image pickup system, which occurs at a fine pattern of a print pattern or a boundary portion of the pattern, and makes a delicate enlargement of the boundary portion of the pattern. It is an object of the present invention to provide a defect pattern detection method and apparatus capable of correcting the overlapping position of images in accordance with reduction, deviation, and the like.

【0008】[0008]

【課題を解決するための手段】請求項1対応の発明は、
撮像対象からの光から撮像対象の画像を検出し、予め記
憶された標準画像と比較して、これらの画像間の相違を
検出することにより、撮像画像の欠陥部を判定する欠陥
パターンの検出方法において、撮像対象からの光により
撮像対象の画像を得る撮像工程と、この撮像工程により
得られた撮像画像の各画素について、該当画素から指定
画素数距離内にある周辺画素の値の最大値及び最小値を
求める分布解析工程と、各画素毎に、この分布解析工程
で得られた最大値及び最小値のうち撮像工程で得られた
該当画素の値に近い方の値で該当画素の値を変更する画
素値変更工程とを有するものである。
The invention according to claim 1 is
Detecting an image of an imaged object from light from the imaged object, comparing it with a standard image stored in advance, and detecting a difference between these images to detect a defective portion of the imaged image. In the imaging step of obtaining an image of the imaging target by the light from the imaging object, and for each pixel of the captured image obtained by this imaging step, the maximum value of the values of the peripheral pixels within the designated pixel number distance from the corresponding pixel and The distribution analysis step for obtaining the minimum value, and for each pixel, the value of the corresponding pixel is determined by the value closer to the value of the corresponding pixel obtained in the imaging step out of the maximum value and the minimum value obtained in this distribution analysis step. And a pixel value changing step of changing the pixel value.

【0009】請求項2対応の発明は、撮像対象からの光
を検出する撮像手段及びこの撮像手段からの信号を処理
する処理手段を備え、この処理手段は、撮像手段から得
られた撮像画像と予め設定されている標準画像とを比較
し、これらの画像間の相違を検出することで撮像画像の
欠陥パターンを検出する欠陥パターンの検出装置におい
て、撮像手段により検出された各画素毎に、該当画素か
ら指定画素数距離内にある周辺画素の値の最大値及び最
小値を求める分布解析手段と、各画素毎に、この分布解
析工程でえられた最大値及び最小値のうち撮像手段によ
り検出された該当画素の値に近い方の値で該当画素の値
を変更する画素値変更手段とを設けたものである。
According to a second aspect of the present invention, there is provided an image pickup means for detecting light from an image pickup object and a processing means for processing a signal from the image pickup means. The processing means is a pickup image obtained from the image pickup means. In a defect pattern detection device for detecting a defect pattern of a captured image by comparing a standard image set in advance and detecting a difference between these images, each pixel detected by the image capturing means is applicable. Distribution analysis means for obtaining the maximum and minimum values of the peripheral pixels within a specified number of pixel distances from the pixel, and for each pixel, detection by the imaging means of the maximum and minimum values obtained in this distribution analysis step And a pixel value changing means for changing the value of the corresponding pixel with a value closer to the value of the selected corresponding pixel.

【0010】請求項3対応の発明は、撮像対象からの光
から撮像対象の画像を検出し、予め記憶された標準画像
と比較して、これらの画像間の相違を検出することによ
り、撮像画像の欠陥部を判定する欠陥パターンの検出方
法において、撮像対象からの光により撮像対象の画像を
得る撮像工程と、この撮像工程により得られた撮像画像
の各画素について、該当画素の値とこの該当画素の近傍
画素の値との間の変化量及びその方向を求める撮像変化
量解析工程と、標準画像の各画素について、該当画素の
値とこの該当画素の近傍画素の値との間の変化量及びそ
の方向を求める標準変化量解析工程と、撮像変化量解析
工程で求められた変化量及びその方向と標準変化量解析
工程で求められた変化量及びその方向とを比較して、撮
像画像と標準画像との相違を検出する相違検出工程とを
有するものである。
According to a third aspect of the present invention, an image of the imaged object is detected from the light from the imaged object, compared with a standard image stored in advance, and a difference between these images is detected to detect the imaged image. In the method of detecting a defect pattern for determining a defective portion, the imaging step of obtaining an image of the imaging target by light from the imaging target, and the value of the corresponding pixel and the corresponding value for each pixel of the captured image obtained by this imaging step. An image-capturing change amount analysis step of obtaining a change amount between a pixel and a value of a neighboring pixel and its direction, and a change amount between a value of a corresponding pixel and a value of a neighboring pixel of the corresponding pixel for each pixel of the standard image. And a standard change amount analysis step of obtaining the direction thereof, a change amount and its direction obtained in the imaging change amount analysis step, and a change amount and its direction obtained in the standard change amount analysis step are compared to obtain a captured image. Standard image Those having a difference detection step of detecting a difference.

【0011】請求項4対応の発明は、撮像対象からの光
を検出する撮像手段及びこの撮像手段からの信号を処理
する処理手段を備え、この処理手段は、撮像手段から得
られた撮像画像と予め設定されている標準画像とを比較
し、これらの画像間の相違を検出することで撮像画像の
欠陥パターンを検出する欠陥パターンの検出装置におい
て、撮像手段により検出された各画素毎に、該当画素の
値とこの該当画素の近傍画素の値との間の変化量及びそ
の方向を求める撮像変化量解析手段と、標準画像の各画
素について、該当画素の値とこの該当画素の近傍画素の
値との間の変化量及びその方向を解析する標準変化量解
析手段と、撮像変化量解析手段で求められた変化量及び
その方向と標準変化量解析手段で求められた変化量及び
その方向とを比較して、撮像画像と標準画像との相違を
検出する相違検出手段とを設けたものである。
The invention according to claim 4 is provided with an image pickup means for detecting light from an image pickup object and a processing means for processing a signal from the image pickup means, and the processing means is a picked-up image obtained from the image pickup means. In a defect pattern detection device for detecting a defect pattern of a captured image by comparing a standard image set in advance and detecting a difference between these images, each pixel detected by the image capturing means is applicable. An image pickup change amount analyzing means for obtaining a change amount and a direction between a pixel value and a value of a neighboring pixel of the corresponding pixel, and a value of the corresponding pixel and a value of a neighboring pixel of the corresponding pixel for each pixel of the standard image Between the change amount and its direction, the change amount and its direction obtained by the imaging change amount analyzing means, and the change amount and its direction obtained by the standard change amount analyzing means. Comparison Te is obtained by providing a difference detecting means for detecting a difference between the captured image and the standard image.

【0012】請求項5対応の発明は、撮像対象からの光
を検出する撮像手段及びこの撮像手段からの信号を処理
する処理手段を備え、この処理手段は、撮像手段から得
られた撮像画像と予め設定されている標準画像とを比較
し、これらの画像間の相違を検出することで撮像画像の
欠陥パターンを検出する欠陥パターンの検出装置におい
て、撮像画素と標準画像との相対位置をずらした複数の
場合について、それぞれ撮像画像と標準画像との相違量
を求める相違量解析手段と、この相違量解析手段により
求められた複数の相違量のうちその相違量が最も小さい
と評価されたものを選択する最小相違量選択手段とを設
け、この最小相違量選択手段により選択された最小の相
違量に基づいて、撮像画像の欠陥部を検出するものであ
る。
The invention according to claim 5 is provided with an image pickup means for detecting light from an image pickup object and a processing means for processing a signal from the image pickup means, and the processing means is a pickup image obtained from the image pickup means. In a defect pattern detection device that detects a defect pattern of a captured image by comparing a preset standard image and detecting a difference between these images, the relative position of the captured pixel and the standard image is shifted. For a plurality of cases, the difference amount analysis means for obtaining the difference amount between the captured image and the standard image, and the difference amount evaluated by the difference amount analysis means that the difference amount is evaluated to be the smallest, A minimum difference amount selecting means for selecting is provided, and the defective portion of the captured image is detected based on the minimum difference amount selected by the minimum difference amount selecting means.

【0013】[0013]

【作用】このような構成の本発明においては、撮像対象
の光により撮像対象の画像が得られる。この画像を構成
する各画素毎に、その該当画素から指定画素数距離内に
ある周辺画素の値の最大値及び最小値が求められ、この
求めた最大値及び最小値のうち該当画素の値に近い方の
値で、該当画素の値が変更される。
In the present invention having such a structure, the image of the image pickup target is obtained by the light of the image pickup target. For each pixel forming this image, the maximum value and the minimum value of the values of the peripheral pixels within the specified number of pixel distances from the corresponding pixel are obtained, and the value of the corresponding pixel among the obtained maximum value and minimum value is determined. The value of the corresponding pixel is changed by the closer value.

【0014】従って、中間的な値が排除され、印刷パタ
ーンの境界部が明瞭になる。また、各画素毎に、該当画
素の値とこの該当画素の近傍画素の値の変化量及びその
方向が求められる。また、標準画像の各画素毎に、該当
画素の値に対するこの該当画素の近傍画素の値の変化量
及びその方向が求められる。
Therefore, the intermediate value is eliminated, and the boundary portion of the print pattern becomes clear. Further, for each pixel, the change amount of the value of the corresponding pixel and the value of the neighboring pixel of the corresponding pixel and the direction thereof are obtained. Further, for each pixel of the standard image, the amount of change in the value of the pixel adjacent to the pixel of interest and the direction thereof are obtained.

【0015】撮像画像について求められた各画素の近傍
画素に対する変化量及びその方向と標準画像について求
めた各画素の近傍画素に対する変化量及びその方向とを
比較して、撮像画像と標準画像との相違が検出される。
The amount of change and the direction of each pixel obtained in the captured image with respect to the neighboring pixels are compared with the amount of change and the direction of each pixel obtained in the standard image with respect to the neighboring pixels. Differences are detected.

【0016】従ってこの相違( この相違を解析すること
)により、印刷パターンの撮像位置のずれを認識するこ
とができ、撮像位置のずれを考慮して印刷パターンの欠
陥パターンが検出される。
Therefore, this difference (analyzing this difference
), The shift of the image pickup position of the print pattern can be recognized, and the defect pattern of the print pattern is detected in consideration of the shift of the image pickup position.

【0017】さらに、撮像画像と標準画像との相対位置
をずらした複数の場合について、それぞれ撮像画像と標
準画像との相違量が求められ、この求められた相違量の
うちの相違量が最も小さいと評価されたものが選択さ
れ、この選択された相違量に基づいて撮像画像の欠陥部
が検出される。
Further, in a plurality of cases in which the relative positions of the captured image and the standard image are shifted, the difference amount between the captured image and the standard image is obtained, and the difference amount is the smallest among the obtained difference amounts. Those evaluated as are selected, and the defective portion of the captured image is detected based on the selected difference amount.

【0018】すなわち、撮像画像と標準画像との相対位
置をずらして、印刷パターンの撮像位置ずれを相殺する
ことにより、撮像位置のずれを修正して印刷パターンの
欠陥パターンが検出される。
That is, by shifting the relative positions of the picked-up image and the standard image to cancel the shift of the picked-up position of the print pattern, the shift of the picked-up position is corrected and the defective pattern of the print pattern is detected.

【0019】[0019]

【実施例】以下、この発明の一実施例を図面を参照して
説明する。図1は、この発明を適用した欠陥パターン検
出装置の概略の構成を示す図である。
DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS An embodiment of the present invention will be described below with reference to the drawings. FIG. 1 is a diagram showing a schematic configuration of a defect pattern detection device to which the present invention is applied.

【0020】供給側ローラ1には、ロール状に巻回され
た印刷物2がセットされる。この印刷物は、検査対象の
同一の印刷パターンが複数個、一定の間隔で整列配置さ
れて印刷されている。あるいは印刷物2は、複数枚の同
一印刷パターンがシート上に一定間隔で整列配置されて
構成されている。
The printed material 2 wound in a roll is set on the supply side roller 1. In this printed matter, a plurality of identical print patterns to be inspected are arranged and printed at regular intervals. Alternatively, the printed matter 2 is configured by arranging a plurality of identical print patterns on a sheet at regular intervals.

【0021】前記供給側ローラ1から所定距離離れた位
置に巻取側ローラ2が設けられ、前記供給側ローラにセ
ットされた前記印刷物2は、前記巻取側ローラ3へ張架
され、この巻取ローラ3により巻取られるようになって
いる。
A take-up side roller 2 is provided at a position separated from the supply-side roller 1 by a predetermined distance, and the printed matter 2 set on the supply-side roller is stretched around the take-up side roller 3 and the winding is performed. It is adapted to be wound by the take-up roller 3.

【0022】前記供給側ローラ1と前記巻取側ローラ3
との間に張架された前記印刷物2上には撮像手段として
のラインセンサ4が設置され、前記印刷物2からの反射
光が前記ラインセンサ4に入射されるように前記供給側
ローラ3の上方に照明部5が設置されている。この照明
部5は、照明駆動部6により電力が供給制御されて、前
記印刷物2の表面に光を照射する。前記ラインセンサ
は、複数の光電変換素子( 例えばCCD( charge coupl
ed device)素子 )を1列( ライン状 )に配列して構成さ
れている。
The supply side roller 1 and the winding side roller 3
A line sensor 4 as an image pickup means is installed on the printed material 2 stretched between the printed material 2 and an upper part of the supply side roller 3 so that the reflected light from the printed material 2 is incident on the line sensor 4. The illumination unit 5 is installed in the. The illumination driving unit 6 controls the supply of electric power to the illumination unit 5 to irradiate the surface of the printed material 2 with light. The line sensor includes a plurality of photoelectric conversion elements (for example, CCD (charge coupl
ed device) elements are arranged in one line (in a line).

【0023】処理部7は、前記ラインセンサ4から出力
される信号( 撮像信号 )を処理して、前記印刷物の各印
刷パターンの欠陥部を抽出し、この処理部7に接続され
た表示器8にその処理結果に基づいて欠陥部を表示させ
る。
The processing unit 7 processes the signal (imaging signal) output from the line sensor 4 to extract the defective portion of each print pattern of the printed matter, and the display unit 8 connected to this processing unit 7 The defective portion is displayed based on the processing result.

【0024】図2は、前記処理部7の要部回路構成を示
すブロック図である。前記ラインセンサ4から出力され
る撮像信号は、A/D( analogue/digital )変換器11
に入力され、前記ラインセンサ4の各画素毎にデジタル
データに変換され、ヒステリシス処理回路12へ出力さ
れる。
FIG. 2 is a block diagram showing a circuit configuration of essential parts of the processing section 7. The image pickup signal output from the line sensor 4 is an A / D (analog / digital) converter 11
Is input to the line sensor 4, converted into digital data for each pixel of the line sensor 4, and output to the hysteresis processing circuit 12.

【0025】このヒステリシス処理回路12は、後述す
るように、入力されたデジタルデータについて、最適な
レベル補正が行われる。このヒステリシス処理回路12
からの出力データ( 画像データ )は、遅延回路13に入
力されると共に方向決定回路14に入力される。前記遅
延回路13からは1周期遅延されたヒステリシス処理回
路12からの画像データが、前記方向決定回路14及び
第1比較回路15、第2比較回路16、第3比較回路1
7に入力されるようになっている。
As will be described later, the hysteresis processing circuit 12 performs optimum level correction on the input digital data. This hysteresis processing circuit 12
The output data (image data) is input to the delay circuit 13 and the direction determining circuit 14. The image data from the hysteresis processing circuit 12 delayed by one cycle from the delay circuit 13 is used as the direction determining circuit 14, the first comparison circuit 15, the second comparison circuit 16, and the third comparison circuit 1.
It is designed to be input to 7.

【0026】前記方向決定回路14は、後述するよう
に、前記ヒステリシス処理回路12から直接入力された
画像データについて、比較方向を指定し、各比較方向に
ついて前記遅延回路13から入力された画像データと重
ね合わせを行い、重ね合わせの結果を比較して方向タイ
プを決定する。
As will be described later, the direction determining circuit 14 specifies a comparison direction for the image data directly input from the hysteresis processing circuit 12, and the image data input from the delay circuit 13 for each comparison direction. Overlay is performed and the result of the overlay is compared to determine the direction type.

【0027】ウィンドウ切替回路18は、後述するよう
に、前記方向決定回路14で決定された方向タイプに合
わせて、3種類のウィンドウの切り出しが行われる。こ
のウィンドウ切替回路18で切り出された3種類の各ウ
ィンドウについて、それぞれ前記第1比較回路15、前
記第2比較回路16、前記第3比較回路17により前記
遅延回路13から入力された1周期前の画像データとの
重ね合わせを行って相違量を求め、その相違量を評価し
て評価値データに変換する。すなわち、評価値データ
は、画像データの欠陥部分を示すデータである。
As will be described later, the window switching circuit 18 cuts out three types of windows according to the direction type determined by the direction determining circuit 14. For each of the three types of windows cut out by the window switching circuit 18, one cycle before input from the delay circuit 13 by the first comparison circuit 15, the second comparison circuit 16, and the third comparison circuit 17, respectively. The amount of difference is obtained by superimposing it on the image data, and the amount of difference is evaluated and converted into evaluation value data. That is, the evaluation value data is data indicating a defective portion of the image data.

【0028】前記比較回路15,16,17で得られた
評価値データは、最小相違量選択手段としての最小値選
択回路19へ出力される。この最小値選択回路は、各評
価値データを比較して評価値が最小のデータを選択し
て、2値化回路20へ出力する。
The evaluation value data obtained by the comparison circuits 15, 16 and 17 are output to the minimum value selection circuit 19 as the minimum difference amount selection means. This minimum value selection circuit compares each evaluation value data, selects the data having the smallest evaluation value, and outputs it to the binarization circuit 20.

【0029】この2値化回路20では、評価値データを
所定のしきい値により2値化してノイズ除去回路21へ
出力する。このノイズ除去回路21では、2値化された
データを縮小/拡大でその1画素程度のノイズ部分を除
去する回路である。
The binarization circuit 20 binarizes the evaluation value data with a predetermined threshold value and outputs it to the noise removal circuit 21. The noise removing circuit 21 is a circuit for reducing / enlarging the binarized data to remove the noise portion of about one pixel.

【0030】このノイズ除去回路21でノイズ部分が除
去された2値化データが、最終的な欠陥部分を抽出した
データであり、このデータに基づいて例えば表示器8に
欠陥部を表示させる。
The binarized data from which the noise portion is removed by the noise removing circuit 21 is the data obtained by extracting the final defective portion, and the defective portion is displayed on the display 8 based on this data.

【0031】図3は、前記ヒステリシス処理回路12の
要部回路構成を示すブロック図である。前記A/D変換
器11から出力されたデジタルデータは、ウィンドウ切
出回路31に入力される。
FIG. 3 is a block diagram showing a circuit configuration of a main part of the hysteresis processing circuit 12. The digital data output from the A / D converter 11 is input to the window cutout circuit 31.

【0032】このウィンドウ切出回路31では、後述す
るように、各デジタルデータ( 画素データ、それぞれ注
目画素データと称する。 )に対して、3×3画素( 注目
画素を含む近傍9個のデータ )又は5×5画素( 注目画
素を含む近傍25個のデータ)のウィンドウ切り出しを
行う。なお、ここでは3×3画素又は5×5画素により
実際上十分な効果が得られるので記載したが、この発明
はこれに限定されるものではなく、例えば7×7画素等
の他のウィンドウ切り出しの方法もある。以下、簡単の
ために3×3画素のウィンドウ切り出しの例で説明す
る。
In the window cutout circuit 31, as will be described later, for each digital data (pixel data, respectively referred to as target pixel data), 3 × 3 pixels (nine neighboring data including the target pixel) Alternatively, window cutout of 5 × 5 pixels (25 neighboring data including the target pixel) is performed. It should be noted that although the description has been given here because a practically sufficient effect can be obtained with 3 × 3 pixels or 5 × 5 pixels, the present invention is not limited to this, and other window cutouts of, for example, 7 × 7 pixels are provided. There is also a method. Hereinafter, for simplification, an example of cutting out a window of 3 × 3 pixels will be described.

【0033】この各デジタルデータに対して切り出され
た3×3画素のデータは、最大値抽出回路32、最小値
抽出回路33へ出力され、最大/最小選択回路34へは
デジタルデータが初期値のデータとして出力される。
The data of 3 × 3 pixels cut out for each digital data is output to the maximum value extraction circuit 32 and the minimum value extraction circuit 33, and the digital data of the initial value is input to the maximum / minimum selection circuit 34. It is output as data.

【0034】前記最大値抽出回路32は、各デジタルデ
ータに対して切り出された各3×3画素のデータ( それ
ぞれ9個ずつの )のうちの最大値のデータを抽出し、前
記最大/最小選択回路34へ出力する。また、前記最小
抽出回路33は、各デジタルデータに対して切り出され
た各3×3画素のデータのうちの最小値のデータを抽出
し、前記最大/最小選択回路34へ出力する。
The maximum value extraction circuit 32 extracts the maximum value data from the 3 × 3 pixel data (nine pieces each) cut out for each digital data, and performs the maximum / minimum selection. Output to the circuit 34. The minimum extraction circuit 33 also extracts the minimum value data from the 3 × 3 pixel data cut out for each digital data and outputs it to the maximum / minimum selection circuit 34.

【0035】前記最大/最小選択回路34は、最大値の
データと最小値のデータのうち初期値のデータとの差が
小さい方のデータを選択し、この選択したデータを該当
する画素のデジタルデータとして出力する。
The maximum / minimum selection circuit 34 selects the data having the smaller difference between the maximum value data and the minimum value data from the initial value data, and selects the selected data as digital data of the corresponding pixel. Output as.

【0036】前記最大値抽出回路32及び前記最小値抽
出回路33は、分布解析手段を構成し、前記最大/最小
選択回路34は、画素値変更手段を構成している。図4
は、前記ウィンドウ切出回路31の要部回路構成を示す
ブロック図である。
The maximum value extraction circuit 32 and the minimum value extraction circuit 33 constitute distribution analysis means, and the maximum / minimum selection circuit 34 constitutes pixel value changing means. Figure 4
FIG. 3 is a block diagram showing a circuit configuration of a main part of the window cutout circuit 31.

【0037】前記A/D変換器11から出力されたデジ
タルデータは、デジタルデータを格納するレジスタを前
記ラインセンサ4から出力されるデジタルデータの個数
分シリアルに接続した第1シフトレジスタ41へ入力さ
れると共に、順次デジタルデータを格納するレジスタを
3個シリアルに接続した第1の3連結シフトレジスタ4
2へ入力される。
The digital data output from the A / D converter 11 is input to the first shift register 41 in which registers for storing digital data are serially connected by the number of digital data output from the line sensor 4. And a first 3-connected shift register 4 in which three registers for sequentially storing digital data are serially connected.
Input to 2.

【0038】また、第1シフトレジスタ41には、デジ
タルデータを格納するレジスタを前記ラインセンサ4か
ら出力されるデジタルデータの個数分シリアルに接続し
た第2シフトレジスタ43が、シリアルに接続されてい
ると共に、デジタルデータを格納するレジスタを3個シ
リアルに接続した第2の3連結シフトレジスタ44もシ
リアルに接続されている。
Further, the first shift register 41 is serially connected with a second shift register 43 in which registers for storing digital data are serially connected by the number of digital data output from the line sensor 4. At the same time, the second 3-connected shift register 44, in which three registers for storing digital data are serially connected, is also serially connected.

【0039】さらに、第2シフトレジスタ43には、デ
ジタルデータを格納するレジスタを3個シリアルに接続
した第3の3連結シフトレジスタ45がシリアルに接続
されている。
Further, the second shift register 43 is serially connected with a third 3-connected shift register 45 in which three registers for storing digital data are serially connected.

【0040】前記各3連結シフトレジスタ42,44,
45の各レジスタからは、格納したデジタルデータを出
力するようになっている。前記第1の3連結シフトレジ
スタ42の前記A/D変換器11から最初にデジタルデ
ータが格納されるレジスタからのデジタルデータをG1
とし、順次シフトされて格納されるレジスタからのデジ
タルデータをG2、G3とする。また、前記第2の3連
結シフトレジスタ44の前記第1シフトレジスタ41か
ら最初にデジタルデータが格納されるレジスタからのデ
ジタルデータをG4とし、順次シフトされて格納される
レジスタからのデジタルデータをG5、G6とする。さ
らに、前記第3の3連結シフトレジスタ45の前記第2
シフトレジスタ43から最初にデジタルデータが格納さ
れるレジスタからのデジタルデータをG7とし、順次シ
フトされて格納されるレジスタからのデジタルデータを
G8、G9とする。
Each of the three-connected shift registers 42, 44,
The stored digital data is output from each of the registers 45. The digital data from the register in which digital data is first stored from the A / D converter 11 of the first 3-connected shift register 42 is G1.
And digital data from the registers that are sequentially shifted and stored are G2 and G3. Also, the digital data from the register in which the digital data is first stored from the first shift register 41 of the second 3-connected shift register 44 is set to G4, and the digital data from the register sequentially shifted and stored is G5. , G6. Further, the second of the third 3-connected shift register 45 is
The digital data from the register in which the digital data is first stored from the shift register 43 is designated as G7, and the digital data from the registers which are sequentially shifted and stored are designated as G8 and G9.

【0041】すると、図5に示すように、画像データの
3×3画素のウィンドウ( 画像データ )が切り出され
る。従って、G1〜G9のデジタルデータが前記最大値
抽出回路32及び前記最小値抽出回路33へ出力され、
画像データの3×3画素のウィンドウの中心のデジタル
データ( 注目画素データ )となるG5のデジタルデータ
が前記最大/最小選択回路34へ初期値のデータとして
出力される。
Then, as shown in FIG. 5, a 3 × 3 pixel window (image data) of the image data is cut out. Therefore, the digital data of G1 to G9 is output to the maximum value extraction circuit 32 and the minimum value extraction circuit 33,
Digital data of G5 which is digital data (pixel data of interest) at the center of a 3 × 3 pixel window of image data is output to the maximum / minimum selection circuit 34 as initial value data.

【0042】図6は、前記最大/最小選択回路34の要
部回路構成を示すブロック図である。前記ウィンドウ切
出回路31から出力された初期値のデータ( G5 )及び
前記最大値抽出回路32から出力された最大値のデータ
は、最大値差算出回路51に入力され、この最大値差算
出回路51でそのデータ差が算出される。
FIG. 6 is a block diagram showing a circuit configuration of a main part of the maximum / minimum selection circuit 34. The initial value data (G5) output from the window cutout circuit 31 and the maximum value data output from the maximum value extraction circuit 32 are input to a maximum value difference calculation circuit 51, and this maximum value difference calculation circuit The data difference is calculated at 51.

【0043】また、前記ウィンドウ切出回路31からの
初期値データ及び最小値抽出回路33から出力された最
小値のデータは、最小値差算出回路52へ入力され、こ
の最小値算出回路52でそのデータ差が算出される。
The initial value data from the window cutout circuit 31 and the minimum value data output from the minimum value extraction circuit 33 are input to the minimum value difference calculation circuit 52, and the minimum value calculation circuit 52 outputs the data. The data difference is calculated.

【0044】前記最大値差算出回路51及び前記最小値
差算出回路52からそれぞれ算出されたデータ差が比較
回路53に入力され、この比較回路53は、2つのデー
タ差を比較して、その小さい方を選択回路54に指定す
る。この選択回路54には、前記最大値抽出回路32及
び前記最小値抽出回路33からそれぞれ最大値のデータ
及び最小値のデータが入力されるようになっており、前
記比較回路53による指定により、最大値のデータ又は
最小値のデータのうちの一方を選択して、該当する画素
のデジタルデータとして出力するようになっている。
The data differences calculated from the maximum value difference calculation circuit 51 and the minimum value difference calculation circuit 52 are input to the comparison circuit 53, and the comparison circuit 53 compares the two data differences and outputs the smaller data difference. One is designated to the selection circuit 54. The maximum value data and the minimum value data are input to the selection circuit 54 from the maximum value extraction circuit 32 and the minimum value extraction circuit 33, respectively. One of the value data and the minimum value data is selected and output as digital data of the corresponding pixel.

【0045】すなわち、簡単のため1次元的な例で説明
すれば、同一の印刷パターンを撮像したにもかかわら
ず、図7( a )と図7( b )とで示すように、印刷パタ
ーンの撮像位置にずれが生じると、中間的なデジタルデ
ータ( 画素データ )の値がずれてしまうという問題があ
る。図7( a )の撮像に対してその撮像位置が( i−
1)番目の画素の方向にずれたとすると、図7( b )に
示すようにデジタルデータが得られる。ここではi番目
の画素及び( i+1 )番目の画素のデジタルデータの値
が、d1及びd2だけ変化してしまう。この問題を解決
するため、上述したように構成されたヒステリシス回路
12は、中間的なデジタルデータをその値が近い近傍の
デジタルデータの値に置き換えて排除する。
That is, for simplification, a one-dimensional example will be described. Even though the same print pattern is imaged, as shown in FIG. 7A and FIG. 7B, the print pattern When the image pickup position shifts, there is a problem that the value of intermediate digital data (pixel data) shifts. The image pickup position is (i-
If it is shifted in the direction of the 1) th pixel, digital data can be obtained as shown in FIG. 7B. Here, the digital data values of the i-th pixel and the (i + 1) -th pixel change by d1 and d2. In order to solve this problem, the hysteresis circuit 12 configured as described above replaces the intermediate digital data with the value of the digital data in the vicinity, and eliminates the value.

【0046】図8( a )に示すように、デジタルデータ
が得られたとすると、まず、注目画素を含めて前後3個
の画素データによるウィンドウを切り出す。i番目の画
素のウィンドウについて、( i−1 )番目の画素のデジ
タルデータの値L1と、i番目の画素のデジタルデータ
の値( 初期値 )L2、( i+1 )番目の画素のデジタル
データの値L3とすると、このウィンドウの最大値はL
3、最小値L1、初期値L2となる。そこで、L3−L
2、L2−L1が算出され、L3−L2>L2−L1と
なるので、注目画素であるi番目の画素のデジタルデー
タの値は、L1に変更される。
As shown in FIG. 8 (a), if digital data is obtained, first, a window is cut out from the three pixel data before and after, including the pixel of interest. Regarding the window of the i-th pixel, the digital data value L1 of the (i-1) -th pixel, the digital data value (initial value) L2 of the i-th pixel, and the digital data value of the (i + 1) -th pixel If L3, the maximum value of this window is L
3, the minimum value L1, and the initial value L2. So L3-L
2, L2-L1 is calculated and L3-L2> L2-L1 is established, so the value of the digital data of the i-th pixel, which is the target pixel, is changed to L1.

【0047】また、( i+1 )番目の画素のウィンドウ
について、i番目の画素のデジタルデータの値L2、(
i+1 )番目の画素のデジタルデータの値( 初期値 )L
3、( i+2 )番目の画素のデジタルデータの値L4と
すると、このウィンドウの最大値はL4、最小値L2、
初期値L3となる。そこで、L4−L3、L3−L2が
算出され、L4−L3<L3−L2となるので、注目画
素である( i+1 )番目の画素のデジタルデータの値は
L4に変更される。
Further, for the window of the (i + 1) th pixel, the digital data value L2 of the ith pixel, (
i + 1) Digital pixel value of pixel (initial value) L
Assuming that the value of the digital data of the 3rd (i + 2) th pixel is L4, the maximum value of this window is L4, the minimum value is L2,
The initial value is L3. Therefore, L4-L3 and L3-L2 are calculated, and L4-L3 <L3-L2, so the value of the digital data of the (i + 1) th pixel, which is the pixel of interest, is changed to L4.

【0048】その結果、図8( b )に示すように、中間
的なデジタルデータのない画像データ変えられる。すな
わち、印刷パターン中の模様等の境界部が明確になる。
ここでは簡単のため1次元的な例で説明したが、例えば
図5に示すような2次元的にも同様に処理され、印刷パ
ターン中の模様等の境界部が明確になる。
As a result, as shown in FIG. 8B, the image data without intermediate digital data can be changed. That is, the boundary portion such as the pattern in the print pattern becomes clear.
Although a one-dimensional example has been described here for simplification, the same processing is performed in a two-dimensional manner as shown in FIG. 5, for example, so that a boundary portion such as a pattern in a print pattern becomes clear.

【0049】図9は、前記方向決定回路14の要部回路
構成を示すブロック図である。前記ヒステリシス処理回
路12からの出力データ( 画像データ )は、X方向変化
量dxr抽出回路61及びY方向変化量dyr抽出回路62
に入力される。また、前記遅延回路13からの1周期遅
延された出力データ( 画像データ )は、X方向変化量d
xs抽出回路63及びY方向変化量dys抽出回路64に入
力される。
FIG. 9 is a block diagram showing a circuit configuration of a main part of the direction determining circuit 14. The output data (image data) from the hysteresis processing circuit 12 includes an X-direction change amount dxr extraction circuit 61 and a Y-direction change amount dyr extraction circuit 62.
Entered in. Further, the output data (image data) delayed by one cycle from the delay circuit 13 is the change amount d in the X direction.
It is input to the xs extraction circuit 63 and the Y-direction change amount dys extraction circuit 64.

【0050】前記抽出回路61,62,63,64に
は、前記ヒステリシス処理回路12の前記ウィンドウ切
出回路31に相当する回路が組み込まれており、それぞ
れ以下に示す( 1 )式及び( 2 )式により、それぞれ変
化量dxr,dxs及びdyr,dysが算出される。
Circuits corresponding to the window cutout circuit 31 of the hysteresis processing circuit 12 are incorporated in the extraction circuits 61, 62, 63 and 64, and the following equations (1) and (2) are respectively provided. The amounts of change dxr, dxs and dyr, dys are calculated by the equations.

【0051】 dxr( dxs )=( G3+G6+G9 )−( G1+G4+G7 )…( 1 ) dyr( dys )=( G1+G2+G3 )−( G7+G8+G9 )…( 2 ) X方向加算回路65は、前記X方向変化量dxr抽出回路
61及び前記X方向変化量dxs抽出回路63から出力さ
れた変化量dxr,dxsを加算し、その加算結果dx=d
xr+dxsを方向判定回路67へ出力する。
Dxr (dxs) = (G3 + G6 + G9) − (G1 + G4 + G7) ... (1) dyr (dys) = (G1 + G2 + G3) − (G7 + G8 + G9) ... (2) The X direction addition circuit 65 is the x direction change circuit 65, and the x direction addition circuit 65 is the x direction change circuit 65. 61 and the change amounts dxr and dxs output from the X-direction change amount dxs extraction circuit 63 are added, and the addition result dx = d
It outputs xr + dxs to the direction determination circuit 67.

【0052】また、Y方向加算回路66は、前記Y方向
変化量dyr抽出回路62及び前記Y方向変化量dys抽出
回路64から出力されたdyr,dysを加算し、その加算
結果dy=dyr+dysを前記方向判定回路67へ出力す
る。
The Y-direction addition circuit 66 adds the dy and dys output from the Y-direction change amount dyr extraction circuit 62 and the Y-direction change amount dys extraction circuit 64, and outputs the addition result dy = dyr + dys. Output to the direction determination circuit 67.

【0053】X方向変化量dxr抽出回路61及びY方向
変化量dyr抽出回路62は、撮像変化量解析手段を構成
し、X方向変化量dxs抽出回路63及びY方向変化量d
ys抽出回路64は、標準変化量解析手段を構成してい
る。
The X-direction change amount dxr extraction circuit 61 and the Y-direction change amount dyr extraction circuit 62 constitute an imaging change amount analysis means, and the X-direction change amount dxs extraction circuit 63 and the Y-direction change amount d.
The ys extraction circuit 64 constitutes a standard change amount analysis means.

【0054】この方向判定回路67は、前記X方向加算
回路65及び前記Y方向加算回路66から出力されたd
xとdyに基づいて、画像ずれのタイプを以下に示す4
種類のタイプのうちから決定する。
The direction judging circuit 67 outputs d output from the X-direction adding circuit 65 and the Y-direction adding circuit 66.
The types of image shift based on x and dy are shown below.
Determine from the types of types.

【0055】( タイプ0 )は、dx、dyの各絶対値が
相手のα倍以内で、dx×dyの符号が負のとき。( タ
イプ1 )は、dyの絶対値がdxの絶対値のα倍以上の
とき。
(Type 0) is when the absolute values of dx and dy are within α times that of the other party, and the sign of dx × dy is negative. (Type 1) is when the absolute value of dy is α times or more the absolute value of dx.

【0056】( タイプ2 )は、dx、dyの各絶対値が
相手のα倍以内で、dx×dyの符号が正のとき。( タ
イプ3 )は、dxの絶対値がdyの絶対値のα倍以上の
とき。
(Type 2) is when the absolute values of dx and dy are within α times that of the other party, and the sign of dx × dy is positive. (Type 3) When the absolute value of dx is α times or more the absolute value of dy.

【0057】ここで、αは2〜3程度の最適な値をと
る。この4種類のタイプ0〜3は、図10に示すような
画像ずれに対応する。すなわち、図10( a ),図10
( b ),図10( c ),図10( d )において縦方向を
y軸、横方向をx軸とすると、タイプ0は図10( a )
に対応し、タイプ1は図10( b )に対応し、タイプ2
は図10( c )に対応し、タイプ3は図10( d )に対
応する。
Here, α has an optimum value of about 2 to 3. These four types 0 to 3 correspond to image shifts as shown in FIG. That is, FIG. 10 (a), FIG.
(b), FIG. 10 (c), and FIG. 10 (d), assuming that the vertical direction is the y-axis and the horizontal direction is the x-axis, the type 0 is shown in FIG. 10 (a).
, Type 1 corresponds to FIG. 10 (b), and type 2
Corresponds to FIG. 10 (c), and type 3 corresponds to FIG. 10 (d).

【0058】つまり、この方向決定回路14は、図11
( a )に示すように、印刷パターン( 印刷パターンの模
様の境界部、実線で示す )が1周期前に撮像した画像デ
ータ( 破線で示す )と位置ずれがある場合、印刷パター
ンの模様の明るさの変化方向に位置を1画素又は図示し
ないが( 例えば7×7画素のウィンドウを切出しておく
ことにより2画素ずらせられる )数画素ずらせながら重
ね合わせを行って相違量の一番小さいものを検出するた
めに行われる。その結果、撮像したばかりの画像データ
は、図11( b )に示すように、撮像された印刷パター
ンは破線から実線へと移動する。この図11( b )中の
Δf及びθは、( 3 )式及び( 4 )式により算出され
る。
That is, the direction determining circuit 14 is shown in FIG.
As shown in (a), if the print pattern (the boundary of the print pattern, indicated by the solid line) is misaligned with the image data captured one cycle before (shown by the broken line), the pattern brightness of the print pattern Although the position is one pixel or not shown (for example, it can be shifted by 2 pixels by cutting out a window of 7 × 7 pixels) in the direction of change in height, overlapping is performed while shifting several pixels and the one with the smallest difference is detected. Is done to As a result, in the image data just captured, the captured print pattern moves from the broken line to the solid line, as shown in FIG. 11 (b). Δf and θ in FIG. 11 (b) are calculated by the equations (3) and (4).

【0059】[0059]

【数1】 [Equation 1]

【0060】前記ウィンドウ切替回路18は、5×5画
素のウィンドウを切り出しておき、前記方向決定回路1
4により決定されたタイプに応じて、5×5画素のウィ
ンドウにおけるA、B、Cのそれぞれの位置で3×3画
素のウィンドウを3種類切出す。
The window switching circuit 18 cuts out a window of 5 × 5 pixels, and the direction determining circuit 1
According to the type determined by 4, three types of 3 × 3 pixel windows are cut out at respective positions of A, B, and C in the 5 × 5 pixel window.

【0061】この3種類の切出された3×3画素のウィ
ンドウA、B及びCは、それぞれ前記第1比較回路1
5、前記第2比較回路16及び前記第3比較回路17に
供給される。一方、遅延回路13から各比較回路15、
16及び17に1周期前の画像データが供給され、この
各比較回路15、16及び17では、それぞれウィンド
ウA、B及びCと1周期前の画像データとの重ね合わせ
が行われ、その相違量が評価される。
The three types of cut-out 3 × 3 pixel windows A, B, and C are the first comparison circuit 1 respectively.
5, supplied to the second comparison circuit 16 and the third comparison circuit 17. On the other hand, from the delay circuit 13 to each comparison circuit 15,
Image data of one cycle before is supplied to 16 and 17, and in each of the comparison circuits 15, 16 and 17, the windows A, B and C and the image data of one cycle before are overlapped with each other, and the difference amount thereof is calculated. Is evaluated.

【0062】前記各比較回路15、16及び17は、そ
れぞれ評価値データを前記最小値選択回路19へ出力す
る。相違量の評価方法については、以下に説明するよう
にして算出される。
Each of the comparison circuits 15, 16 and 17 outputs the evaluation value data to the minimum value selection circuit 19, respectively. The method of evaluating the difference amount is calculated as described below.

【0063】前記遅延回路13から出力される1周期前
の画像データの3×3画素のウィンドウの各( 明るさの
)データをG1〜G9とし、ウィンドウ切替回路18か
ら出力される3×3画素のウィンドウの各( 明るさの )
データをg1〜g9とすると、単純な明るさ評価として
の評価値P0は( 5 )式により算出される。
Each window of the 3 × 3 pixel window of the image data of one cycle before output from the delay circuit 13 (
) Assume that the data is G1 to G9, and each of the 3 × 3 pixel windows (of brightness) output from the window switching circuit 18
When the data are g1 to g9, the evaluation value P0 as a simple brightness evaluation is calculated by the equation (5).

【0064】[0064]

【数2】 さらに、方向を含めて厳密に印刷パターンの相違量を評
価したときの評価値P1は、dxs、dys、dxr、dyrを
使用して( 6 )式により算出される。
[Equation 2] Further, the evaluation value P1 when the difference amount of the print pattern including the direction is strictly evaluated is calculated by the equation (6) using dxs, dys, dxr, and dyr.

【0065】[0065]

【数3】 [Equation 3]

【0066】なお、dxs、dys、dxr、dyrの添数字i
は、3×3画素のウィンドウの位置を示すものである。
また、( 7 )式により算出される判定式Dが0に近い場
合には、( 5 )式による評価値P0を使用し、それ以外
の場合には( 6 )式による評価値P1を使用する混合形
式を取ることもできる。
The subscript i of dxs, dys, dxr, and dyr
Indicates the position of a 3 × 3 pixel window.
When the judgment formula D calculated by the formula (7) is close to 0, the evaluation value P0 according to the formula (5) is used, and in other cases, the evaluation value P1 according to the formula (6) is used. It can also take a mixed form.

【0067】前記各比較回路15、16及び17が( 6
)式により評価値データを求めると、この前記各比較回
路15、16及び17は、相違検出手段を構成する。こ
のような構成の本実施例においては、ラインセンサ4に
より撮像された画像データは、A/D変換器11を介し
てヒステリシス処理回路12に入力され、このヒステリ
シス処理回路12において、3×3画素のウィンドウが
切出され、注目画素について、この注目画素を含む周辺
の9個の画素の最大値と最小値を求め、この最大値と最
小値のうち注目画素の値に近い方を選択し、この選択し
た値を注目画素の値とする。
Each of the comparison circuits 15, 16 and 17 has (6
When the evaluation value data is obtained by the equation), each of the comparison circuits 15, 16 and 17 constitutes a difference detecting means. In the present embodiment having such a configuration, the image data captured by the line sensor 4 is input to the hysteresis processing circuit 12 via the A / D converter 11, and in the hysteresis processing circuit 12, 3 × 3 pixels are displayed. The window of is cut out, the maximum value and the minimum value of the nine pixels around the target pixel including the target pixel are obtained, and the one of the maximum value and the minimum value that is closer to the value of the target pixel is selected, The selected value is set as the value of the pixel of interest.

【0068】これにより、印刷パターンの境界部におけ
る中間的なデータを除去して、境界部が明瞭に補正され
る。このように境界部が明瞭に補正された画像データ
は、方向決定回路14により1周期前に撮像された画素
データとの比較により、画像ずれの方向が図10に示す
4種類のタイプのうちから決定される。
As a result, the intermediate data at the boundary of the print pattern is removed, and the boundary is clearly corrected. The image data whose boundary is clearly corrected in this way is compared with the pixel data imaged one cycle before by the direction determination circuit 14, and the direction of the image shift is determined from among the four types shown in FIG. It is determined.

【0069】方向決定回路14により決定されたタイプ
に応じて、ウィンドウ切替回路18は、3種類の切出さ
れた3×3画素のウィンドウA、B及びCが切出され、
これらのウィンドウA、B及びCは、それぞれ第1比較
回路15、第2比較回路16及び第3比較回路17によ
り、遅延回路13から出力された1周期前の画像データ
と比較され、その相違量が評価される。
According to the type determined by the direction determining circuit 14, the window switching circuit 18 extracts three types of 3 × 3 pixel windows A, B and C,
The windows A, B, and C are compared with the image data of one cycle before output from the delay circuit 13 by the first comparison circuit 15, the second comparison circuit 16, and the third comparison circuit 17, respectively, and the difference amount thereof. Is evaluated.

【0070】最小値選択回路19は、各比較回路15,
16及び17から出力される3種類の評価データのう
ち、評価値の最小のデータを選択して、2値化回路20
に出力する。
The minimum value selection circuit 19 includes the comparison circuits 15,
Of the three types of evaluation data output from 16 and 17, the data having the smallest evaluation value is selected to select the binarization circuit 20.
Output to.

【0071】この2値化回路20で2値化された評価デ
ータは、ノイズ除去回路21に出力され、このノイズ除
去回路21でノイズが除去される。このノイズ除去回路
21でノイズが除去された評価データにより欠陥パター
ンが抽出される。
The evaluation data binarized by the binarization circuit 20 is output to the noise removal circuit 21, and the noise removal circuit 21 removes noise. A defect pattern is extracted from the evaluation data from which noise has been removed by the noise removal circuit 21.

【0072】このように本実施例によれば、注目画素と
その周辺の画素とにより構成されたウィンドウ内の最大
値と最小値を求め、その最大値と最小値のうち注目画素
の値に近い方の値で注目画素の値を変更するヒステリシ
ス処理回路12と、撮像画像の各画素毎にX方向変化量
及びY方向変化量を求めると共に遅延回路13からの1
周期前の画像( 標準画像 )の各画素毎にX方向変化量及
びY方向変化量を求め、これらの変化量に基づいて、印
刷パターンの撮像位置のずれを4種類のパターンのうち
から決定する方向決定回路14と、この決定されたパタ
ーンに応じて撮像画像から3種類の3×3画素のウィン
ドウを切出すウィンドウ切替回路18と、この3種類の
3×3画素のウィンドウについてそれぞれ遅延回路13
からの画像と比較して、その相違量を評価する比較回路
15,16,17と、各比較回路15,16,17から
出力される評価データのうちの最小値を選択する最小値
選択回路19を設けたことにより、ヒステリシス処理回
路12で中間的なデータを補正することができ、方向決
定回路14により撮像画像の各画素毎のX方向及びY方
向の変化量と遅延回路13からの画像の各画素後とのX
方向及びY方向の変化量とを比較して位置ずれのパター
ンを決定することができる。
As described above, according to the present embodiment, the maximum value and the minimum value in the window constituted by the pixel of interest and the peripheral pixels are obtained, and the maximum value and the minimum value are close to the value of the pixel of interest. The hysteresis processing circuit 12 that changes the value of the pixel of interest with the other value, the X direction change amount and the Y direction change amount for each pixel of the captured image, and 1 from the delay circuit 13.
The amount of change in the X direction and the amount of change in the Y direction are obtained for each pixel of the image before the cycle (standard image), and the shift in the image pickup position of the print pattern is determined from the four types of patterns based on these amounts of change. The direction determining circuit 14, the window switching circuit 18 that cuts out three types of 3 × 3 pixel windows from the captured image according to the determined pattern, and the delay circuit 13 for each of the three types of 3 × 3 pixel windows.
Comparing circuits 15 and 16 and 17 for evaluating the difference amount, and a minimum value selecting circuit 19 for selecting the minimum value of the evaluation data output from the comparing circuits 15, 16 and 17. By providing the above, the hysteresis processing circuit 12 can correct the intermediate data, and the direction determining circuit 14 changes the amount of change in the X direction and the Y direction for each pixel of the captured image and the image from the delay circuit 13. X after each pixel
The positional deviation pattern can be determined by comparing the amounts of change in the direction and the Y direction.

【0073】従って、ヒステリシス処理回路12によ
り、不明瞭な画素の値を排除して、画像のパターンを明
瞭にすることができる。また、方向決定回路14により
印刷パターンの位置ずれの方向を決定する事ができる。
その結果、従来印刷パターンについて8方向のずれにつ
いて考慮しなければならなかったのに対して、本実施例
では1方向のみについて考慮すれば良い。すなわち、1
方向のみの比較回路で済むため、回路構成が簡略するこ
とができ、印刷パターンの撮像時の位置ずれを正確に補
正することができる。
Therefore, the hysteresis processing circuit 12 can eliminate the unclear pixel value and make the image pattern clear. Further, the direction determining circuit 14 can determine the direction of the positional deviation of the print pattern.
As a result, it has been necessary to consider shifts in eight directions in the conventional print pattern, whereas in this embodiment, it is sufficient to consider only one direction. Ie 1
Since only the comparison circuit in the direction is required, the circuit configuration can be simplified and the positional deviation at the time of capturing the print pattern can be accurately corrected.

【0074】以上により、本実施例によれば高精度に欠
陥パターンを検出することができる。なおこの実施例で
は、印刷パターンからの反射光を検出して、欠陥パター
ンを検出するものについて説明したが、本発明はこれに
限定されるものではなく、例えば、印刷パターンからの
透過光を検出するものについても適用できるものであ
る。
As described above, according to this embodiment, the defect pattern can be detected with high accuracy. In addition, in this embodiment, the reflected light from the print pattern is detected, and the defect pattern is detected. However, the present invention is not limited to this. For example, transmitted light from the print pattern is detected. It can also be applied to what is done.

【0075】[0075]

【発明の効果】以上詳述したようにこの発明によれば、
印刷パターンの細かい模様や模様の境界部で発生する、
撮像系の特性のために生じる各画素の中間的な画素値を
補正し、模様の境界部の微妙な拡大、縮小、ずれなどに
応じて画像の重ね合わせ位置を補正することができる欠
陥パターンの検出方法及びその装置を提供できる。
As described above in detail, according to the present invention,
Occurs at the fine pattern of the print pattern or at the boundary of the pattern,
It is possible to correct the intermediate pixel value of each pixel that occurs due to the characteristics of the imaging system, and to correct the overlapping position of images according to subtle enlargement, reduction, misalignment of the pattern boundary. A detection method and an apparatus therefor can be provided.

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

【図1】この発明の一実施例の欠陥パターン検出装置の
概略の構成を示す図。
FIG. 1 is a diagram showing a schematic configuration of a defect pattern detection device according to an embodiment of the present invention.

【図2】同実施例の欠陥パターン検出装置の処理部の要
部回路構成を示すブロック図。
FIG. 2 is a block diagram showing a circuit configuration of a main part of a processing unit of the defect pattern detection apparatus of the embodiment.

【図3】同実施例の欠陥パターン検出装置のヒステリシ
ス処理回路の要部回路構成を示すブロック図。
FIG. 3 is a block diagram showing a circuit configuration of a main part of a hysteresis processing circuit of the defect pattern detection apparatus according to the embodiment.

【図4】同実施例の欠陥パターン検出装置のウィンドウ
切出回路の要部回路構成を示すブロック図。
FIG. 4 is a block diagram showing a circuit configuration of a main part of a window cutout circuit of the defect pattern detection apparatus of the embodiment.

【図5】同実施例の欠陥パターン検出装置のウィンドウ
切出回路により切出された3×3画素のウィンドウを示
す図。
FIG. 5 is a view showing a window of 3 × 3 pixels cut out by a window cutting circuit of the defect pattern detection apparatus of the embodiment.

【図6】同実施例の欠陥パターン検出装置の最大/最小
選択回路の要部回路構成を示すブロック図。
FIG. 6 is a block diagram showing a circuit configuration of essential parts of a maximum / minimum selection circuit of the defect pattern detection apparatus of the embodiment.

【図7】同実施例の撮像した画素データの1次元的な分
布を示す図。
FIG. 7 is a diagram showing a one-dimensional distribution of imaged pixel data of the embodiment.

【図8】同実施例の欠陥パターン検出装置のヒステリシ
ス処理回路により画素データの1次元的な分布に対する
処理前と処理後を示す図。
FIG. 8 is a diagram showing a one-dimensional distribution of pixel data before and after processing by the hysteresis processing circuit of the defect pattern detection apparatus of the embodiment.

【図9】同実施例の欠陥パターン検出装置の方向決定回
路の要部回路構成を示すブロック図。
FIG. 9 is a block diagram showing a circuit configuration of a main part of a direction determining circuit of the defect pattern detecting apparatus of the embodiment.

【図10】同実施例の欠陥パターン検出装置の方向決定
回路により決定される4種類のパターンを示す図。
FIG. 10 is a diagram showing four types of patterns determined by a direction determining circuit of the defect pattern detecting apparatus of the same embodiment.

【図11】同実施例の欠陥パターン検出装置の方向決定
回路及び回路による画像ずれの処理前と処理後を示す
図。
FIG. 11 is a diagram showing a direction determining circuit of the defect pattern detecting apparatus of the embodiment and a diagram showing before and after image shift processing by the circuit.

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

4…ラインセンサ、 7…処理部、 12…ヒステリシス処理回路、 13…遅延回路、 14…方向決定回路、 15,16,17…比較回路、 18…ウィンドウ切替回路、 19…最小値選択回路、 31…ウィンドウ切出回路。 4 ... Line sensor, 7 ... Processing part, 12 ... Hysteresis processing circuit, 13 ... Delay circuit, 14 ... Direction determination circuit, 15, 16, 17 ... Comparison circuit, 18 ... Window switching circuit, 19 ... Minimum value selection circuit, 31 … Window cutting circuit.

───────────────────────────────────────────────────── フロントページの続き (51)Int.Cl.6 識別記号 庁内整理番号 FI 技術表示箇所 G06T 5/00 // B41J 29/46 C 0834−5H G06F 15/70 330 N ─────────────────────────────────────────────────── ─── Continuation of the front page (51) Int.Cl. 6 Identification code Internal reference number FI Technical display location G06T 5/00 // B41J 29/46 C 0834-5H G06F 15/70 330 N

Claims (5)

【特許請求の範囲】[Claims] 【請求項1】 撮像対象からの光から撮像対象の画像を
検出し、予め記憶された標準画像と比較して、これらの
画像間との相違を検出することにより、前記撮像画像の
欠陥部を判定する欠陥パターンの検出方法において、前
記撮像対象からの光により前記撮像対象の画像を得る撮
像工程と、この撮像工程により得られた撮像画像の各画
素について、該当画素から指定画素数距離内にある周辺
画素の値の最大値及び最小値を求める分布解析工程と、
各画素毎に、この分布解析工程で得られた最大値及び最
小値のうち前記撮像工程で得られた前記該当画素の値に
近い方の値で前記該当画素の値を変更する画素値変更工
程とを有することを特徴とする欠陥パターンの検出方
法。
1. A defective portion of the captured image is detected by detecting an image of the captured object from light from the captured object, comparing it with a standard image stored in advance, and detecting a difference between these images. In the method of detecting a defect pattern to be determined, an image capturing step of obtaining an image of the image capturing target by light from the image capturing target, and each pixel of the captured image obtained by this image capturing step within a designated pixel number distance from the corresponding pixel. A distribution analysis step of obtaining the maximum value and the minimum value of the values of a certain peripheral pixel,
For each pixel, a pixel value changing step of changing the value of the corresponding pixel with a value closer to the value of the corresponding pixel obtained in the imaging step out of the maximum value and the minimum value obtained in the distribution analysis step. A method for detecting a defect pattern, comprising:
【請求項2】 撮像対象からの光を検出する撮像手段及
びこの撮像手段からの信号を処理する処理手段を備え、
この処理手段は、撮像手段から得られた撮像画像と予め
設定されている標準画像とを比較し、これらの画像間の
相違を検出することで前記撮像画像の欠陥パターンを検
出する欠陥パターンの検出装置において、前記撮像手段
により検出された各画素毎に、該当画素から指定画素数
距離内にある周辺画素の値の最大値及び最小値を求める
分布解析手段と、各画素毎に、この分布解析工程でえら
れた最大値及び最小値のうち前記撮像手段により検出さ
れた前記該当画素の値に近い方の値で前記該当画素の値
を変更する画素値変更手段とを設けたことを特徴とする
欠陥パターンの検出装置。
2. An image pickup means for detecting light from an image pickup target, and a processing means for processing a signal from the image pickup means,
The processing means compares a captured image obtained from the image capturing means with a preset standard image and detects a difference between these images to detect a defect pattern of the captured image. In the apparatus, for each pixel detected by the image pickup means, a distribution analysis means for obtaining the maximum value and the minimum value of the values of peripheral pixels within a designated pixel number distance from the corresponding pixel, and this distribution analysis for each pixel And a pixel value changing means for changing the value of the corresponding pixel with a value closer to the value of the corresponding pixel detected by the image pickup means out of the maximum value and the minimum value obtained in the step. Device for detecting defective patterns.
【請求項3】 撮像対象からの光から撮像対象の画像を
検出し、予め記憶された標準画像と比較して、これらの
画像間の相違を検出することにより、前記撮像画像の欠
陥部を判定する欠陥パターンの検出方法において、前記
撮像対象からの光により前記撮像対象の画像を得る撮像
工程と、この撮像工程により得られた撮像画像の各画素
について、該当画素の値とこの該当画素の近傍画素の値
との間の変化量及びその方向を求める撮像変化量解析工
程と、前記標準画像の各画素について、該当画素の値と
この該当画素の近傍画素の値との間の変化量及びその方
向を求める標準変化量解析工程と、前記撮像変化量解析
工程で求められた変化量及びその方向と前記標準変化量
解析工程で求められた変化量及びその方向とを比較し
て、前記撮像画像と前記標準画像との相違を検出する相
違検出工程とを有することを特徴とする欠陥パターンの
検出方法。
3. A defective portion of the picked-up image is determined by detecting an image of the picked-up object from light from the picked-up object, comparing it with a standard image stored in advance, and detecting a difference between these images. In the method of detecting a defect pattern, the image pickup step of obtaining an image of the image pickup object by the light from the image pickup object, and for each pixel of the image pickup image obtained by this image pickup step, the value of the corresponding pixel and the vicinity of the corresponding pixel An image pickup change amount analysis step of obtaining a change amount between the pixel value and the direction thereof, and a change amount between the value of the corresponding pixel and a value of a neighboring pixel of the corresponding pixel for each pixel of the standard image and its The standard change amount analysis step of obtaining a direction, the change amount and its direction obtained in the imaging change amount analysis step are compared with the change amount and its direction obtained in the standard change amount analysis step, and the captured image is obtained. And before And a difference detecting step of detecting a difference from the standard image.
【請求項4】 撮像対象からの光を検出する撮像手段及
びこの撮像手段からの信号を処理する処理手段を備え、
この処理手段は、撮像手段から得られた撮像画像と予め
設定されている標準画像とを比較し、これらの画像間の
相違を検出することで前記撮像画像の欠陥パターンを検
出する欠陥パターンの検出装置において、前記撮像手段
により検出された各画素毎に、該当画素の値とこの該当
画素の近傍画素の値との間の変化量及びその方向を求め
る撮像変化量解析手段と、前記標準画像の各画素につい
て、該当画素の値とこの該当画素の近傍画素の値との間
の変化量及びその方向を解析する標準変化量解析手段
と、前記撮像変化量解析手段で求められた変化量及びそ
の方向と前記標準変化量解析手段で求められた変化量及
びその方向とを比較して、前記撮像画像と前記標準画像
との相違を検出する相違検出手段とを設けたことを特徴
とする欠陥パターンの検出装置。
4. An image pickup unit for detecting light from an image pickup target and a processing unit for processing a signal from the image pickup unit,
The processing means compares a captured image obtained from the image capturing means with a preset standard image and detects a difference between these images to detect a defect pattern of the captured image. In the device, for each pixel detected by the image pickup means, an image pickup change amount analysis means for obtaining a change amount and a direction between a value of a corresponding pixel and a value of a neighboring pixel of the corresponding pixel, and the standard image For each pixel, standard change amount analysis means for analyzing the change amount and the direction between the value of the corresponding pixel and the value of the neighboring pixel of the corresponding pixel, and the change amount obtained by the imaging change amount analyzing means and its A defect pattern characterized by providing a difference detecting means for comparing a direction with a change amount obtained by the standard change amount analyzing means and its direction to detect a difference between the captured image and the standard image. Detection device.
【請求項5】 撮像対象からの光を検出する撮像手段及
びこの撮像手段からの信号を処理する処理手段を備え、
この処理手段は、撮像手段から得られた撮像画像と予め
設定されている標準画像とを比較し、これらの画像間の
相違を検出することで前記撮像画像の欠陥パターンを検
出する欠陥パターンの検出装置において、前記撮像画素
と前記標準画像との相対位置をずらした複数の場合につ
いて、それぞれ前記撮像画像と前記標準画像との相違量
を求める相違量解析手段と、この相違量解析手段により
求められた複数の相違量のうちその相違量が最も小さい
と評価されたものを選択する最小相違量選択手段とを設
け、この最小相違量選択手段により選択された最小の相
違量に基づいて、前記撮像画像の欠陥部を検出すること
を特徴とする欠陥パターンの検出装置。
5. An image pickup unit for detecting light from an image pickup target, and a processing unit for processing a signal from the image pickup unit,
The processing means compares a captured image obtained from the image capturing means with a preset standard image and detects a difference between these images to detect a defect pattern of the captured image. In the apparatus, for a plurality of cases in which the relative positions of the image pickup pixel and the standard image are shifted, a difference amount analysis unit that obtains the difference amount between the captured image and the standard image, and the difference amount analysis unit are obtained. And a minimum difference amount selecting means for selecting a difference amount evaluated to be the smallest among the plurality of difference amounts, and based on the minimum difference amount selected by the minimum difference amount selecting means, the imaging is performed. A defect pattern detection device characterized by detecting a defective portion of an image.
JP12636294A 1994-06-08 1994-06-08 Defect pattern detection method and device Expired - Lifetime JP3400859B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP12636294A JP3400859B2 (en) 1994-06-08 1994-06-08 Defect pattern detection method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP12636294A JP3400859B2 (en) 1994-06-08 1994-06-08 Defect pattern detection method and device

Publications (2)

Publication Number Publication Date
JPH07333173A true JPH07333173A (en) 1995-12-22
JP3400859B2 JP3400859B2 (en) 2003-04-28

Family

ID=14933314

Family Applications (1)

Application Number Title Priority Date Filing Date
JP12636294A Expired - Lifetime JP3400859B2 (en) 1994-06-08 1994-06-08 Defect pattern detection method and device

Country Status (1)

Country Link
JP (1) JP3400859B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2012048484A (en) * 2010-08-26 2012-03-08 Canon Inc Image processing apparatus, image processing method, and program

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5616100B2 (en) * 2010-04-02 2014-10-29 株式会社ブリヂストン Manufacturing method of long article

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2012048484A (en) * 2010-08-26 2012-03-08 Canon Inc Image processing apparatus, image processing method, and program
US8942511B2 (en) 2010-08-26 2015-01-27 Canon Kabushiki Kaisha Apparatus and method for detecting object from image, and program

Also Published As

Publication number Publication date
JP3400859B2 (en) 2003-04-28

Similar Documents

Publication Publication Date Title
EP1400922A1 (en) Print inspection method and apparatus
JP3333686B2 (en) Display screen inspection method
JP6250793B2 (en) Method and apparatus for removing character background from color image
JP2011076204A (en) Method and apparatus for inspecting printed matter
JP2010078485A (en) Method for inspecting printed matter
EP0443062B1 (en) Device for inspecting quality of printed matter and method thereof
JP3400859B2 (en) Defect pattern detection method and device
JP3204876B2 (en) Print inspection equipment
JP2002008029A (en) Image inspection device
JP3584507B2 (en) Pattern unevenness inspection equipment
JPH07249122A (en) Method and device for inspecting picture
JP2876999B2 (en) Printing defect inspection equipment
JP4074146B2 (en) Print stain inspection method and apparatus
JP4220061B2 (en) Periodic pattern defect inspection method and apparatus
JPH0735699A (en) Method and apparatus for detecting surface defect
JP3177945B2 (en) Surface defect inspection equipment
JP2004117150A (en) Pattern defect inspection device and pattern defect inspection method
JPH04339653A (en) Apparatus for inspecting printing fault
JPH04294260A (en) Inspecting apparatus for printed pattern quality
JP2003094595A (en) Printing plate inspecting apparatus
JP2701872B2 (en) Surface inspection system
JP3267372B2 (en) Method and apparatus for generating matching pattern signal in pattern matching inspection
JP3314251B2 (en) Defect inspection method
CN101661006A (en) Image dust-particle detecting system and detecting method thereof
JPH0520459A (en) Method and device for recognizing pattern

Legal Events

Date Code Title Description
S111 Request for change of ownership or part of ownership

Free format text: JAPANESE INTERMEDIATE CODE: R313115

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

S111 Request for change of ownership or part of ownership

Free format text: JAPANESE INTERMEDIATE CODE: R313117

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

EXPY Cancellation because of completion of term