JPS6210838Y2 - - Google Patents

Info

Publication number
JPS6210838Y2
JPS6210838Y2 JP3313779U JP3313779U JPS6210838Y2 JP S6210838 Y2 JPS6210838 Y2 JP S6210838Y2 JP 3313779 U JP3313779 U JP 3313779U JP 3313779 U JP3313779 U JP 3313779U JP S6210838 Y2 JPS6210838 Y2 JP S6210838Y2
Authority
JP
Japan
Prior art keywords
inspected
pattern
deviation
image
inspection
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.)
Expired
Application number
JP3313779U
Other languages
Japanese (ja)
Other versions
JPS55134661U (en
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 filed Critical
Priority to JP3313779U priority Critical patent/JPS6210838Y2/ja
Publication of JPS55134661U publication Critical patent/JPS55134661U/ja
Application granted granted Critical
Publication of JPS6210838Y2 publication Critical patent/JPS6210838Y2/ja
Expired legal-status Critical Current

Links

Landscapes

  • Image Processing (AREA)

Description

【考案の詳細な説明】 本考案はコンピユータを用いて二次元的なパタ
ーンの自動検査を行なう装置に関するものであ
る。
[Detailed Description of the Invention] The present invention relates to an apparatus for automatically inspecting two-dimensional patterns using a computer.

一般に生産ラインにおいては、製品の外観(形
状、寸法、傷等)や製品に貼られたラベル等の位
置ずれ、或はラベルや包装箱等に印刷された文字
や記号のミス、汚れまたは欠落、更にはラインで
混入した異物等の検査を行なう必要がある。従来
この種の検査を自動的に行なう目的で、1次元イ
メージセンサを内蔵したカメラで基準となる対象
物と被検査対象物とを撮像して基準画像と被検査
画像とを得、これら両画像に含まれるパターンを
比較することにより被検査対象物の良否を判定す
るようにしたパターン自動検査装置が種々提案さ
れている。この種の装置において、基準画像と被
検査画像とを比較するに当つては、多くの場合両
画像をそのまま比較するのではなく、両画像に検
査領域を少なくとも1つ設定して、対応する検査
領域内に含まれる基準パターン及び被検査パター
ンを比較する方法がとられる。この場合基準パタ
ーンと被検査パターンとの比較は各検査領域毎に
行なわれ、偏差が許容値を超えた検査領域が1つ
でもある場合には被検査対象物が不良と判定され
る。このように画像に検査領域を設定すると、必
要な部分のみを詳しく検査できるので、被検査対
象物のパターンの良否をより明確に判定すること
ができる。しかしながら従来の装置では、許容偏
差値を各検査領域毎に設定することが困難であつ
たため、殆んどの場合すべての検査領域に対して
共通の許容偏差を設定していたが、この場合適確
な許容偏差を設定することが難しかつた。また基
準パターンと被検査パターンとの許容偏差はパタ
ーンの如何によつて異なるため、すべての検査領
域に対して共通の許容偏差を設定した場合には、
必要以上に厳しく判定される検査領域と判定が甘
すぎる検査領域とが出る虞れがあり、適確な検査
を行なうことが難しかつた。更に、従来の装置で
は各検査領域毎に偏差を読み出すことができなか
つたため、不良と判定された場合にいずれの検査
領域のパターンが不良であるのかを知ることがで
きず、不良の原因を調べることができなかつた。
In general, on the production line, there may be problems such as product appearance (shape, dimensions, scratches, etc.), misalignment of labels attached to products, mistakes, stains, or omissions of characters or symbols printed on labels or packaging boxes, etc. Furthermore, it is necessary to inspect for foreign substances mixed in on the line. Conventionally, in order to perform this type of inspection automatically, a camera with a built-in one-dimensional image sensor captures images of a reference object and an object to be inspected to obtain a reference image and an image to be inspected. Various automatic pattern inspection apparatuses have been proposed that determine the quality of an object to be inspected by comparing patterns included in the images. In this type of device, when comparing a reference image and an image to be inspected, in many cases, rather than comparing both images as they are, at least one inspection area is set in both images and the corresponding inspection is performed. A method is used to compare the reference pattern and the pattern to be inspected included within the area. In this case, the reference pattern and the pattern to be inspected are compared for each inspection area, and if there is even one inspection area in which the deviation exceeds the allowable value, the object to be inspected is determined to be defective. By setting the inspection area in the image in this way, only the necessary portions can be inspected in detail, so it is possible to more clearly determine whether the pattern of the object to be inspected is good or bad. However, with conventional equipment, it was difficult to set the allowable deviation value for each inspection area, so in most cases a common allowable deviation value was set for all inspection areas, but in this case, it was difficult to set the allowable deviation value for each inspection area. It was difficult to set acceptable tolerances. Also, since the tolerance between the reference pattern and the pattern to be inspected varies depending on the pattern, if a common tolerance is set for all inspection areas,
There is a risk that some inspection areas will be judged more strictly than necessary and some inspection areas will be judged too leniently, making it difficult to perform an appropriate inspection. Furthermore, with conventional equipment, it was not possible to read the deviation for each inspection area, so if a pattern was determined to be defective, it was not possible to know which inspection area's pattern was defective, and it was difficult to investigate the cause of the defect. I couldn't do it.

本考案の目的は、検査領域毎に異なる許容偏差
を設定することができる上に各検査領域の偏差を
読出すことができるようにしたパターン自動検査
装置を提供することにある。
An object of the present invention is to provide an automatic pattern inspection device that can set different allowable deviations for each inspection area and also read out the deviations of each inspection area.

以下図示の実施例により本考案の装置を詳細に
説明する。
The apparatus of the present invention will be explained in detail below with reference to the illustrated embodiments.

第1図は本考案の検査装置の構成を概略的に示
したもので、同図において1はパターン自動検査
装置本体、2は被検査対象物3,3,…を搬送す
るコンベア、4は検査装置本体1内の電源にコー
ドl1を介して接続されて検査位置にある被検査対
象物3を照明する照明装置、5はコードl2を介し
て検査装置本体1に接続された位置検出センサで
ある。位置検出センサ5はコンベア2を間にして
対向配置された投光器5a及び受光器5bからな
り、被検査対象物3が検査位置に来たときにその
端縁を検出して受光器5bが位置検出信号(スタ
ート信号)を発生する。
FIG. 1 schematically shows the configuration of the inspection device of the present invention. In the figure, 1 is the main body of the automatic pattern inspection device, 2 is a conveyor for conveying the objects to be inspected 3, 3, etc., and 4 is the inspection device. A lighting device is connected to the power supply in the apparatus main body 1 via the cord L1 to illuminate the object to be inspected 3 at the inspection position, and 5 is a position detection sensor connected to the inspection apparatus main body 1 via the cord L2 . It is. The position detection sensor 5 consists of a light emitter 5a and a light receiver 5b which are arranged opposite to each other with the conveyor 2 in between. When the object to be inspected 3 comes to the inspection position, the edge of the object to be inspected 3 is detected, and the light receiver 5b detects the position. Generates a signal (start signal).

6は被検査対象物3の被検査パターンを撮影し
て電気的な画像を得るカメラで、このカメラは、
第2図に示したように1次元イメージセンサ7
と、被検査パターン8の像をイメージセンサ7の
受光面7a上に結ばせる集光レンズ9と、イメー
ジセンサ7を駆動する回路10とを備えている。
このようなカメラとしては例えば半導体カメラの
名称で市販されているものを用いることができ
る。1次元イメージセンサ7は、走査に電子ビー
ムを用いない固体撮像素子で、自己走査機能を備
えており、シリコンの単一基板上にフオトダイオ
ードDPのアレイとMOSシフトレジスタの走査回
路とを集積したものである。第3図はこのイメー
ジセンサの等価回路を示したもので、同図におい
てDPは受光面上に一列に並べられたフオトダイ
オード、Cは各フオトダイオードDPに並列接続
されたキヤパシタンス、Dは各フオトダイオード
Pに直列に接続されたダイオード、RLは負荷抵
抗、COは出力キヤパシタンス、VTは直流電源、
SRはシフトレジスタである。このイメージセン
サにおいて、シフトレジスタSRにクロツクパル
スを1個与えると、シフトレジスタSRがフオト
ダイオードDP,DP,…の各回路に順次走査パル
スを与え、フオトダイオードDPのアレイを端か
ら順に自動的に走査する。各フオトダイオードD
Pに直列に接続されているダイオードは、常時逆
バイアス状態にあり、走査パルスで走査を受けた
回路のダイオードDのみがONになつてキヤパシ
タンスCが電源VTの電圧まで充電される。光の
入射によつてフオトダイオードDPの導電率が上
がり、キヤパシタンスCから入射光束量に応じた
電荷が放電してキヤパシタンスCの端子電圧が低
下する。1フレーム時間後に再びクロツクパルス
が与えられ、各フオトダイオードの回路に走査パ
ルスが与えられると、各キヤパシタンスCが再充
電されるが、このときキヤパシタンスCに流れる
充電電流はキヤパシタンスCの端子電圧の低下
分、即ち入射光束量に比例し、この入射光束量に
比例した信号が連続パルス列の形で映像信号出力
Vとして取り出される。フオトダイオードは電
荷蓄積モードで動作するため、映像信号EVは光
の強さと繰り返し走査時間の積に比例した信号と
なる。現実に使用されているイメージセンサの一
例では、受光部の大きさが50μm×50μmのフオ
トダイオードが50μmの間隔で64個直線状に並べ
られ、2MHzまでの高速動作が可能になつてい
る。そして入射光束量に対する電気信号出力は直
線的である。
Reference numeral 6 denotes a camera that photographs the pattern to be inspected of the object to be inspected 3 and obtains an electrical image.
As shown in Fig. 2, the one-dimensional image sensor 7
, a condensing lens 9 that focuses the image of the pattern to be inspected 8 on the light receiving surface 7 a of the image sensor 7 , and a circuit 10 that drives the image sensor 7 .
As such a camera, for example, one commercially available under the name of a semiconductor camera can be used. The one-dimensional image sensor 7 is a solid-state image sensor that does not use an electron beam for scanning, has a self-scanning function, and integrates an array of photodiodes D P and a scanning circuit of a MOS shift register on a single silicon substrate. This is what I did. Figure 3 shows the equivalent circuit of this image sensor. In the figure, D P is the photodiode arranged in a row on the light receiving surface, C is the capacitance connected in parallel to each photodiode D P , and D is the capacitance connected in parallel to each photodiode D P. A diode connected in series with each photodiode D P , R L is the load resistance, C O is the output capacitance, V T is the DC power supply,
SR is a shift register. In this image sensor, when one clock pulse is applied to the shift register SR, the shift register SR sequentially applies a scanning pulse to each circuit of the photodiodes D P , D P , etc., and automatically scans the photodiode D P array sequentially from the end. scan. Each photodiode D
The diode connected in series with P is always in a reverse bias state, and only the diode D of the circuit scanned by the scan pulse is turned on, and the capacitance C is charged to the voltage of the power supply V T . The conductivity of the photodiode D P increases due to the incidence of light, and a charge corresponding to the amount of incident light flux is discharged from the capacitance C, so that the terminal voltage of the capacitance C decreases. When a clock pulse is applied again after one frame time and a scanning pulse is applied to the circuit of each photodiode, each capacitance C is recharged. At this time, the charging current flowing through the capacitance C is equal to the drop in the terminal voltage of the capacitance C. That is, the signal is proportional to the amount of incident light flux, and a signal proportional to the amount of incident light flux is extracted as a video signal output EV in the form of a continuous pulse train. Since the photodiode operates in a charge accumulation mode, the video signal E V is a signal proportional to the product of light intensity and repetitive scanning time. An example of an image sensor that is actually used has 64 photodiodes with a light receiving area of 50 μm x 50 μm arranged in a straight line at 50 μm intervals, enabling high-speed operation up to 2 MHz. The electrical signal output with respect to the amount of incident light flux is linear.

上記のようなイメージセンサ7を内蔵したカメ
ラ6をコンベア2上の被検査対象物に向けて配置
してコンベア2をイメージセンサ7の走査方向Y
と直角な矢印X方向に移動させ、一定周期のクロ
ツクパルスをシフトレジスタSRに与えると、被
検査物の全面の走査をして被検査物の画像を得る
ことができる。この場合画像の分解能はクロツク
パルスの周波数とイメージセンサのフオトダイオ
ードの数とにより定まる。本発明の方法では、例
えば、前述のようにフオトダイオードの数(1フ
レーム)を64とし、256個のクロツクパルスによ
り1フイールドを構成する。この場合1フイール
ドの絵素の総数は256×64個となる。
The camera 6 incorporating the image sensor 7 as described above is placed facing the object to be inspected on the conveyor 2, and the conveyor 2 is moved in the scanning direction Y of the image sensor 7.
If the shift register SR is moved in the direction of the arrow X perpendicular to , and a clock pulse of a constant period is applied to the shift register SR, the entire surface of the object to be inspected can be scanned and an image of the object to be inspected can be obtained. In this case, the resolution of the image is determined by the frequency of the clock pulse and the number of photodiodes in the image sensor. In the method of the present invention, for example, as described above, the number of photodiodes (one frame) is 64, and one field is composed of 256 clock pulses. In this case, the total number of picture elements in one field is 256×64.

第4図を参照すると、本考案のパターン自動検
査装置の電気的な構成がブロツク図で示されてお
り、第5図には検査装置本体1の操作パネル1a
の構成が示されている。イメージセンサ7から得
られる映像信号EVの各パルスの波高値は、各絵
素の明暗に比例している。このイメージセンサ7
から得られる信号は、第4図に示すように、2値
化回路11に入力される。2値化回路11は、映
像信号EVの各パルスをその波高値が一定のスレ
ーシヨールドレベル以下であるか以上であるかに
よつて白または黒のいずれかの信号に変換するも
ので、2値化回路11の出力側に得られる映像信
号EV′が表わす画像は、白または黒からなり灰色
部分のない2値化画像となる。2値化回路11の
出力EV′は検査装置本体1内に収納されたマイク
ロコンピユータ12の入力回路13を通して中央
演算処理装置(CPU)14に入力されている。
マイクロコンピユータ12にはまた、基準画像を
記憶させておく基準画像メモリ(RAM)15
と、被検査画像を記憶させておく被検査画像メモ
リ(RAM)16と、両画像の比較をするための
演算を行なう際に用いられる演算用メモリ
(RAM)17と、プログラムを記憶させておくプ
ログラム用メモリ(ROM)18とが設けられて
おり、基準画像メモリ15及び被検査画像メモリ
16に記憶された基準画像及び被検査画像はビデ
オ信号発生回路19及びブランキング回路(メモ
リの像が入つていないアドレスに相応する部分を
画面から消す回路)20を通して操作パネル1a
に設けられたモニタテレビ受像機21に上下に並
べて表示されるようになつている。
Referring to FIG. 4, the electrical configuration of the automatic pattern inspection apparatus of the present invention is shown in a block diagram, and FIG.
The configuration is shown. The peak value of each pulse of the video signal E V obtained from the image sensor 7 is proportional to the brightness and darkness of each picture element. This image sensor 7
The signal obtained from this is input to the binarization circuit 11, as shown in FIG. The binarization circuit 11 converts each pulse of the video signal EV into a white or black signal depending on whether its peak value is below or above a certain threshhold level. The image represented by the video signal E V ' obtained at the output side of the binarization circuit 11 is a binarized image consisting of white or black and without gray areas. The output E V ' of the binarization circuit 11 is input to a central processing unit (CPU) 14 through an input circuit 13 of a microcomputer 12 housed in the inspection apparatus main body 1.
The microcomputer 12 also includes a reference image memory (RAM) 15 for storing reference images.
, a test image memory (RAM) 16 for storing the test image, a calculation memory (RAM) 17 for use in performing calculations for comparing both images, and a program. A program memory (ROM) 18 is provided, and the reference image and inspected image stored in the reference image memory 15 and inspected image memory 16 are connected to a video signal generation circuit 19 and a blanking circuit (where the image in the memory is input). A circuit for erasing the part corresponding to the unlit address from the screen) 20 through the operation panel 1a
The images are displayed vertically side by side on a monitor television receiver 21 installed in the .

操作パネル1aにはまた、検査領域の設定のし
かたを切換える検査領域設定方法切換スイツチ2
2と、基準画像と被検査画像との比較を行なう際
の処理方法を切換える比較処理方法切換スイツチ
23と、基準パターンと被検査パターンとの偏差
の許容値を設定する許容偏差設定用デジタルスイ
ツチ24と、偏差の書込みを指示する偏差書込み
用押ボタンスイツチ25と、画像に設定する検査
領域の位置や大きさを指定する検査領域設定用デ
ジタルスイツチ26と、偏差の読出を指示する偏
差読出用押ボタンスイツチ27と、押ボタンスイ
ツチ27が押されたときにデジタルスイツチ26
により指定された領域の偏差を表示する発光ダイ
オード(LED)からなるデジタル表示器28と
が設けられ、これらのうち、検査領域設定方法切
換スイツチ22、比較処理方法切換スイツチ2
3、許容偏差設定用デジタルスイツチ24、偏差
書込み用押ボタンスイツチ25及び検査領域設定
用デジタルスイツチ26により与えられる指示の
内容は入力回路29を介して中央演算処理装置1
4に入力されている。また偏差値表示用のデジタ
ル表示器28は、中央処理装置14に出力回路3
0を介して接続され、押ボタンスイツチ27が押
されたときにデジタルスイツチ26で指定された
領域の偏差を%で表示するようになつている。操
作パネル1aには更に、検査した全数量、良品の
数量及び不良品の数量をそれぞれ表示するLED
表示部31及至33を有するカウンタ34が設け
られ、このカウンタは中央演算処理装置14に出
力回路35を介して接続されている。カウンタ3
4の表示部の下方にはカウンタリセツトボタン3
6が設けられ、このボタンの側方には基準画像メ
モリ15及び被検査画像メモリ16の内容等をク
リアをするシステムリセツトボタン37が設けら
れている。またカウンタ34の表示器の上方に
は、被検査対象物が良品であるとき及び不良品で
あるときにそれぞれ点灯する良品表示灯38及び
不良品表示灯39が設けられ、モニタテレビ受像
機21の下方にはコンベア2の起動を行なわせる
押ボタンスイツチ40及びコンベア2を停止させ
る押ボタンスイツチ41が設けられている。また
これらの押ボタンスイツチの下方には電源スイツ
チ42と、電源が投入されているときに点灯する
電源表示灯43とが設けられている。
The operation panel 1a also includes an inspection area setting method changeover switch 2 for changing the inspection area setting method.
2, a comparison processing method switching switch 23 that switches the processing method when comparing the reference image and the inspected image, and an allowable deviation setting digital switch 24 that sets the allowable value of the deviation between the reference pattern and the inspected pattern. , a deviation writing pushbutton switch 25 that instructs to write the deviation, an inspection area setting digital switch 26 that specifies the position and size of the inspection area to be set on the image, and a deviation reading pushbutton switch 26 that instructs the reading of the deviation. button switch 27, and digital switch 26 when push button switch 27 is pressed.
A digital display 28 consisting of a light emitting diode (LED) is provided to display the deviation of the area specified by the inspection area setting method changeover switch 22 and a comparison processing method changeover switch 2.
3. The contents of the instructions given by the digital switch 24 for setting the allowable deviation, the push button switch 25 for writing the deviation, and the digital switch 26 for setting the inspection area are sent to the central processing unit 1 via the input circuit 29.
4 is entered. Further, the digital display 28 for displaying the deviation value is connected to the output circuit 3 in the central processing unit 14.
0, and when the pushbutton switch 27 is pressed, the deviation of the area specified by the digital switch 26 is displayed in %. The operation panel 1a is further equipped with LEDs that display the total quantity inspected, the quantity of non-defective products, and the quantity of defective products.
A counter 34 having displays 31 to 33 is provided, and this counter is connected to the central processing unit 14 via an output circuit 35. counter 3
There is a counter reset button 3 below the display section 4.
6, and a system reset button 37 for clearing the contents of the reference image memory 15 and the image memory 16 to be inspected is provided on the side of this button. Further, above the display of the counter 34, a good product indicator light 38 and a defective product indicator light 39 are provided, which turn on when the object to be inspected is a good product and a defective product, respectively. A push button switch 40 for starting the conveyor 2 and a push button switch 41 for stopping the conveyor 2 are provided below. Further, below these pushbutton switches, a power switch 42 and a power indicator light 43 that lights up when the power is turned on are provided.

次に上記の装置により行なわれるパターン自動
検査の流れを第6図のフローチヤートに従つて説
明する。尚以下の説明では、イメージセンサの走
査方向(画面の縦方向)をy軸方向とし、コンベ
ア2の移動方向(画面の横方向)をx軸方向とす
る。
Next, the flow of automatic pattern inspection carried out by the above-mentioned apparatus will be explained according to the flowchart of FIG. In the following description, the scanning direction of the image sensor (vertical direction of the screen) is assumed to be the y-axis direction, and the moving direction of the conveyor 2 (horizontal direction of the screen) is assumed to be the x-axis direction.

検査を開始するに当つては先ず、電源スイツチ
42をオンにし、システムリセツトスイツチ37
を押してメモリ15,16等をクリアする。次に
検査する対象物のパターンに応じて検査領域を如
何に定めるかを決定する(第6図のステツプ
a)。
To start the inspection, first turn on the power switch 42 and turn on the system reset switch 37.
Press to clear memory 15, 16, etc. Next, it is determined how to define the inspection area according to the pattern of the object to be inspected (step a in FIG. 6).

即ち、検査精度を向上させるためには、基準画
像と被検査画像とをそのまま比較するのではな
く、両画像に検査領域を設定して各検査領域毎に
パターンを比較する。本実施例では、画像に含ま
れるパターン全体の横方向の両端縁または横方向
の両端縁と縦方向の両端縁の双方を検出し、検出
した端縁を基準にして検査領域を設定する。この
ようにパターン全体の端縁を検出して検出した端
縁を基準に検査領域の位置を定めると、被検査対
象物を撮像する位置が多少ずれても、常に正確に
基準画像の検査領域と被検査画像を検査領域とを
対応させることができるので、検査精度を高める
ことができる。
That is, in order to improve inspection accuracy, instead of comparing the reference image and the image to be inspected as they are, inspection areas are set in both images and patterns are compared for each inspection area. In this embodiment, both horizontal edges or both horizontal edges and vertical edges of the entire pattern included in the image are detected, and an inspection area is set based on the detected edges. By detecting the edge of the entire pattern and determining the position of the inspection area based on the detected edge in this way, even if the position at which the image of the object to be inspected is slightly shifted, the inspection area will always be accurately aligned with the reference image. Since the image to be inspected can be made to correspond to the inspection area, inspection accuracy can be improved.

本実施例では、検査領域設定方法切換スイツチ
22を切換えることにより以下に示す3種類の方
法で検査領域の設定を行なうことができるように
なつている。
In this embodiment, by switching the inspection area setting method changeover switch 22, the inspection area can be set using the following three methods.

(イ) 自動分割法 この方法は、第7図aに示すように、文字
A,B,Cのような個々に独立した単位パター
ンが間隔をおいて配置されているような被検査
パターンを検査する場合に好適な方法で、各単
位パターンの左端L及び右端R(横方向の両
端)をそれぞれ検出して各単位パターンの左端
と右端との間の領域を検査領域とする方法であ
る。図示の例では、この方法でパターン全体の
左端Lと右端Rとの間の領域が5個の領域b1
b5に分割され、文字「A」,「B」及び「C」を
それぞれ含む3個の領域b1,b3及びb5が検査領
域として設定される。尚この方法は、パターン
が連続している場合には、単位パターンの先端
及び後端の検出ができないので適用できない。
(b) Automatic segmentation method This method inspects a pattern to be inspected in which individual unit patterns such as letters A, B, and C are arranged at intervals, as shown in Figure 7a. In this case, the left end L and right end R (horizontal ends) of each unit pattern are respectively detected, and the area between the left end and right end of each unit pattern is set as the inspection area. In the illustrated example, with this method, the area between the left edge L and the right edge R of the entire pattern is divided into five areas b 1 to
Three areas b 1 , b 3 , and b 5 are set as inspection areas. Note that this method cannot be applied when the patterns are continuous because the leading and trailing ends of the unit pattern cannot be detected.

(ロ) 指定分割法 この方法は、第8図aに示したように、撮像
した画像(モニタテレビに写し出される画像)
から検査すべきパターンの左端Lと、右端Rと
を検出し、左端L及び右端Rの間の領域を、指
定した位置で適宜の数に分割する方法である。
図示の例では、パターンの左端Lと右端Rとの
間の領域を文字AとBとの間の部分でb1及びb2
の領域に分割し、これらの両領域を検査領域と
している。分割位置は、画像に含まれるパター
ン全体の左端を0%、右端を100%としてデジ
タルスイツチ26により指定できるようになつ
ている。第8図aの例では領域b1とb2との間の
分割位置をパターンの左端から30%の位置に指
定している。この分割法は、被検査パターンが
連続した図形や模様等であつて部分的に検査の
重要度が高い場合に好適であり、重要度の高い
領域の面積を小さく設定しておけば、その領域
について特に詳しく検査することができる。第
8図aに示した例では、領域b1を領域b2よりも
詳しく検査することができる。
(b) Specified division method This method uses the captured image (the image displayed on the monitor TV) as shown in Figure 8a.
In this method, the left end L and right end R of the pattern to be inspected are detected, and the area between the left end L and right end R is divided into an appropriate number of parts at specified positions.
In the illustrated example, the area between the left end L and right end R of the pattern is the part between letters A and B, b 1 and b 2
The test area is divided into two areas, and both of these areas are used as inspection areas. The division position can be specified by the digital switch 26, with the left end of the entire pattern included in the image being 0% and the right end being 100%. In the example shown in FIG. 8a, the dividing position between areas b 1 and b 2 is specified at a position 30% from the left end of the pattern. This division method is suitable when the pattern to be inspected is a continuous figure or pattern, and the inspection importance of some parts is high.If the area of the area of high importance is set small, the area can be examined in particular detail. In the example shown in FIG. 8a, region b 1 can be examined more closely than region b 2 .

(ハ) 一定分割法 この分割法は、検査すべきパターン全体の左
端Lと右端Rとの間の領域を予め定められた分
割数に等分する方法で、分割位置はパターンの
左端を0%として分割数に応じて%で指定され
る。第9図aに示した例ではパターンの左端と
右端との間の領域が25%,50%及び75%の位置
でb1〜b4の検査領域に4等分されている。
(c) Constant division method This division method is a method in which the area between the left end L and right end R of the entire pattern to be inspected is equally divided into a predetermined number of divisions, and the division position is 0% from the left end of the pattern. is specified as a percentage according to the number of divisions. In the example shown in FIG. 9a, the area between the left and right ends of the pattern is divided into four inspection areas b 1 to b 4 at 25%, 50%, and 75% positions.

上記のようにして分割方法を設定した後、パタ
ーンの比較処理方法を決定する(第6図のステツ
プb)。本実施例では、各検査領域に含まれる基
準パターンと被検査パターンとを比較するに当
り、1つの軸方向のヒストグラムを比較する方法
(以下1軸法という。)と、2つの異なる軸方向の
ヒストグラムを比較する方法(以下2軸法とい
う。)と、基準画像及び被検査画像にそれぞれ含
まれるパターンの面積を比較する方法(以下面積
比較法という。)とを選択できるようになつてい
る。このパターンの比較方法の設定は、比較処理
方法切換スイツチ23を「1軸法」、「2軸法」ま
たは「面積比較法」に切換えることにより行なわ
れ、このスイツチにより与えられた指令は入力回
路29を通してCPU14に入力される。CPU1
4は後記するように所定のプログラムによつて設
定された方法でパターンの比較処理を行なう。
After setting the division method as described above, the pattern comparison processing method is determined (step b in FIG. 6). In this example, when comparing the reference pattern and the pattern to be inspected included in each inspection area, two methods are used: a method that compares histograms in one axis direction (hereinafter referred to as the one-axis method), and a method that compares histograms in one axis direction (hereinafter referred to as the one-axis method). It is possible to select between a method of comparing histograms (hereinafter referred to as the two-axis method) and a method of comparing the areas of patterns included in the reference image and the image to be inspected (hereinafter referred to as the area comparison method). The pattern comparison method is set by switching the comparison processing method changeover switch 23 to "one-axis method,""two-axismethod," or "area comparison method," and the command given by this switch is applied to the input circuit. The signal is input to the CPU 14 through 29. CPU1
4 performs pattern comparison processing using a method set by a predetermined program as described later.

パターンの比較処理方法を決定した後、コンベ
ア2を起動させて検査の基準とすべき対象物(基
準対象物)を撮像し、基準画像のデータを取り込
む(第6図のステツプc)。このデータの取り込
みは、位置検出センサ5が信号を発生すると同時
に開始され、256回の走査が行なわれた時点で終
了する。カメラ6から得られた像は2値化回路1
1により黒または白の絵素からなる2値化画像に
変換され、この2値化画像Iはモニタテレビ21
の画面の上方に表示される(第6図のステツプ
d)。次にオペレータはこのテレビ画面の像を見
て基準画像として適当か否かを判断し(第6図の
ステツプe)。もし基準画像として不適当な場合
には、基準となるべき対象物の変更や、照明の具
合の調節等の必要な処置を行なつた後再度基準画
像のデータを取込む(第6図のステツプf)。モ
ニタテレビ21上に表示された基準画像が適当な
場合には、被検査物の中から正常と思われるもの
をコンベア2上に配置し、前記と同様にしてその
画像データを取り込む。この正常な被検査物の2
値化画像はモニタテレビ21の画面の下方に表
示される(第6図のステツプg)。尚カメラ6か
ら与えられる画像信号を基準画像とすべきか否か
はオペレータの判断により行ない、画像データの
起動は位置検出センサ5の出力信号により行な
う。即ち、システムリセツトスイツチ37が押さ
れた後最初に発生した位置検出センサの出力によ
り走査を開始して得た画像のみが基準画像として
基準画像メモリ15に記憶され、その後に発生す
る位置検出センサの出力により走査を開始して得
た画像は被検査画像として被検査画像メモリ16
に記憶される。基準画像メモリ15の内容はシス
テムリセツトスイツチ37が再び押されるまで保
持され、従つてモニタテレビ21上の基準画像も
システムリセツトスイツチ37が押されるまで保
持される。被検査画像メモリ16の内容は、位置
検出センサ5の出力が発生して新たな被検査画像
のデータが入力される毎に書き換えられ、モニタ
テレビ21上の被検査画像もその都度新たな被検
査画像を入れ換わる。
After determining the pattern comparison processing method, the conveyor 2 is started to image an object to be used as a reference for inspection (reference object), and data of the reference image is captured (step c in FIG. 6). This data acquisition starts at the same time as the position detection sensor 5 generates a signal, and ends when 256 scans have been performed. The image obtained from the camera 6 is the binarization circuit 1
1 is converted into a binary image consisting of black or white picture elements, and this binary image I is displayed on the monitor television 21.
is displayed at the top of the screen (step d in Figure 6). Next, the operator looks at this image on the television screen and determines whether it is suitable as a reference image (step e in FIG. 6). If the reference image is inappropriate, take necessary measures such as changing the reference object or adjusting the lighting conditions, and then import the reference image data again (steps in Figure 6). f). If the reference image displayed on the monitor television 21 is appropriate, one of the objects to be inspected that appears to be normal is placed on the conveyor 2, and its image data is captured in the same manner as described above. This normal test object 2
The digitized image is displayed at the bottom of the screen of the monitor television 21 (step g in FIG. 6). Note that whether or not the image signal given from the camera 6 should be used as a reference image is determined by the operator, and the image data is activated by the output signal of the position detection sensor 5. That is, only the image obtained by starting scanning based on the output of the position detection sensor that occurs first after the system reset switch 37 is pressed is stored as a reference image in the reference image memory 15, and the image that is obtained by starting scanning based on the output of the position detection sensor that occurs after that is stored as a reference image. The image obtained by starting scanning with the output is stored as the image to be inspected in the image memory 16 to be inspected.
is memorized. The contents of reference image memory 15 are held until system reset switch 37 is pressed again, and therefore the reference image on monitor television 21 is also held until system reset switch 37 is pressed. The contents of the image to be inspected memory 16 are rewritten each time an output from the position detection sensor 5 is generated and data of a new image to be inspected is input, and the image to be inspected on the monitor television 21 is also updated each time. Swap images.

次にCPU14は、2値化された基準画像及び
被検査画像のそれぞれから検査すべきパターン
(例えばABCの3つの文字)の左端と右端とを検
出し、指定された方法で検査領域を指定する(第
6図のステツプh)。この検査領域の設定を行な
う場合、パターンの左端と右端との検出は、2値
化画像のx軸方向に対して作成したパターンの面
積のヒストグラムを用いて行なう。例えば自動分
割を行なう場合には第7図aに示すような2値化
画像に対して同図bに示すように各単位パターン
の面積のx軸方向ヒストグラムHx1,Hx2及びHx
を作成する。この場合、パターンの面積のとり
方としては白の部分の面積をとる方法と黒の部分
の面積をとる方法とが考えられるが、黒地に白抜
き文字のパターンが現われるような特別な場合を
除いて黒の面積をとるのが好ましい。第7図bに
示すようなヒストグラムを作成した後、ヒストグ
ラムHx1,Hx2及びHx3のそれぞれの先端Lと後
端Rとを検出して検査すべき領域を検査領域b1
b3及びb5に分割する。また指定分割の場合には、
第8図bに示すようにヒストグラムHx1の左端L
とヒストグラムHx3の右端Rとを検出して、左端
Lを基準に指定された位置で左端Lと右端Rとの
間の領域を検査領域b1とb2とに分割する。同様
に、一定分割の場合には、第9図bに示すように
ヒストグラムHx1の左端LとヒストグラムHx3
右端Rとを検出して左端Lと右端Rとの間の領域
を4等分する。
Next, the CPU 14 detects the left and right edges of the pattern to be inspected (for example, three letters of ABC) from each of the binarized reference image and the image to be inspected, and specifies the inspection area using the specified method. (Step h in Figure 6). When setting this inspection area, the left end and right end of the pattern are detected using a histogram of the area of the pattern created in the x-axis direction of the binarized image. For example, when performing automatic division, for a binarized image as shown in FIG. 7a, x-axis direction histograms of the area of each unit pattern H x1 , H x2 and H x as shown in FIG.
Create 3 . In this case, the area of the pattern can be calculated by taking the area of the white part or by taking the area of the black part, but except for special cases where a pattern of white characters appears on a black background. It is preferable to take the black area. After creating a histogram as shown in FIG. 7b, the leading edge L and trailing edge R of the histograms H x1 , H x2 and H x3 are detected, and the area to be inspected is determined as the inspection area b 1 ,
Divide into b 3 and b 5 . In addition, in the case of specified division,
As shown in Figure 8b, the left end L of the histogram H x1
and the right edge R of the histogram H x3 , and divides the area between the left edge L and the right edge R into inspection areas b 1 and b 2 at a specified position with the left edge L as a reference. Similarly, in the case of fixed division, the left end L of the histogram H x1 and the right end R of the histogram H x3 are detected and the area between the left end L and the right end R is divided into four equal parts, as shown in FIG. do.

上記のようなヒストグラムは、2値化回路の出
力から黒のパルス数を計数するか、或は基準画像
メモリ及び被検査画像メモリの内容から黒の絵素
を記憶しているアドレスを計数することにより作
成できる。
The above histogram can be created by counting the number of black pulses from the output of the binarization circuit, or by counting the addresses storing black picture elements from the contents of the reference image memory and the image memory to be inspected. It can be created by

検査領域を設定した後、CPU14は所定のプ
ログラムに従つて1軸法、2軸法または面積比較
法により各検査領域毎に基準パターンと被検査パ
ターンとの比較を行なう(第6図のステツプ
i)。次にこの比較処理方法について第11図乃
至第13図を参照して説明する。
After setting the inspection area, the CPU 14 compares the reference pattern and the pattern to be inspected for each inspection area using the 1-axis method, 2-axis method, or area comparison method according to a predetermined program (step i in FIG. 6). ). Next, this comparison processing method will be explained with reference to FIGS. 11 to 13.

先ず1軸法で比較処理する場合には、基準画像
及び被検査画像の各検査領域に含まれるパターン
の面積の1つの軸方向のヒストグラムを比較す
る。本実施例では画像を分割するために既にx軸
方向ヒストグラムが作成されているので、このx
軸方向ヒストグラムを各検査領域毎に比較する。
また2軸法による場合には、y軸方向のヒストグ
ラムも作成して、x軸方向とy軸方向の両ヒスト
グラムを比較する。第10図は、検査領域に文字
Aが含まれている場合を例にとつてx軸方向及び
y軸方向のヒストグラムHx及びHyを示したもの
である。
First, when performing comparison processing using the uniaxial method, histograms of the areas of patterns included in each inspection area of the reference image and the image to be inspected in one axis direction are compared. In this example, an x-axis direction histogram has already been created in order to divide the image.
Compare the axial histograms for each inspection area.
In addition, when using the two-axis method, a histogram in the y-axis direction is also created, and both the histograms in the x-axis direction and the y-axis direction are compared. FIG. 10 shows histograms H x and H y in the x-axis direction and y-axis direction, taking as an example the case where the inspection area includes the character A.

基準画像及び被検査画像の各検査領域のヒスト
グラムの比較を行なうに当つては、比較すべき2
つのヒストグラムの中心を合せて両ヒストグラム
を重ね合せ、両ヒストグラムの一致していない部
分の間の面積を算出する。例えば、基準画像の或
検査領域に含まれる基準パターンのx軸方向ヒス
トグラムHxsが第11図aに示す通りである場合
において、被検査画像の対応する検査領域に含ま
れる被検査パターンのx軸方向ヒストグラムHx
が同図bに示す通りであつたとした場合、これら
のヒストグラムを比較するには、同図cに示すよ
うに両ヒストグラムの中心位置x0を重ね合せて両
ヒストグラムの一致していない部分の間の面積
(第11図cに斜線を施して示した部分の面積、
以下不一致部分間面積という。)sxを算出する。
本考案ではこの面積sxを両ヒストグラムHxs
びHxの相違度(即ち基準パターンと被検査パタ
ーンとの相違度)として良否の判定資料とする。
1軸法により良否の判定を行なうには、例えばこ
の面積sxを基準パターンのx軸方向ヒストグラ
ムHxsの全面積Sで除して、偏差dx=(sx
S)×100(%)を求め、その偏差dxを予め設定
しておいて許容偏差d0と比較すればよい。
When comparing the histograms of each inspection area of the reference image and the image to be inspected, two
The two histograms are overlapped by aligning their centers, and the area between the areas where the two histograms do not match is calculated. For example, when the x-axis direction histogram Hxs of the reference pattern included in a certain inspection area of the reference image is as shown in FIG. Directional histogram H x
If the histograms are as shown in figure b, then to compare these histograms, superimpose the center position x 0 of both histograms as shown in figure c, and then compare (area of the shaded part in Figure 11c,
Hereinafter, it will be referred to as the area between the mismatched parts. ) Calculate s x .
In the present invention, this area s x is used as the degree of difference between the two histograms H xs and H x (that is, the degree of difference between the reference pattern and the pattern to be inspected) and is used as data for determining pass/fail.
To make a pass/fail judgment using the uniaxial method, for example, divide this area s x by the total area S of the x-axis direction histogram H xs of the reference pattern, and calculate the deviation d x = (s x /
S)×100(%), set the deviation d x in advance, and compare it with the allowable deviation d 0 .

2軸法により比較を行なう場合には、上記と全
く同様にして基準パターンと被検査パターンのy
軸方向ヒストグラムを重ね合せて比較し、両パタ
ーンのヒストグラムの不一致部分間面積syを相
違度として算出してこの面積syをも判定の資料
とする。この場合の判定のしかたとしては例え
ば、x軸方向ヒストグラムの相違度を示す面積s
xとy軸方向ヒストグラムの相違度を示す面積sy
とを比較して大きい方、即ちmax(sx,sy)を
ヒストグラムの全面積S(x軸方向ヒストグラム
とy軸方向ヒストグラムの全面積は等しい。)で
除して偏差d={max(sx,sy/S}×100
(%)を求め、この偏差dを許容偏差d0と比較す
る方法をとればよい。
When comparing using the two-axis method, the y of the reference pattern and the pattern to be inspected is determined in exactly the same way as above.
The axial histograms are superimposed and compared, and the area s y between the mismatched portions of the histograms of both patterns is calculated as the degree of difference, and this area s y is also used as data for determination. In this case, for example, the area s indicating the degree of difference in the histograms in the x-axis direction is
Area s y showing the degree of difference between the histograms in the x and y axis directions
The deviation d= { max( s x , s y /S}×100
(%) and compare this deviation d with the allowable deviation d 0 .

上記の説明では、基準パターン及び被検査パタ
ーンのヒストグラムの不一致部分間面積を基準パ
ターンのヒストグラムの全面積で除して偏差を百
分率で表わすようにしたが、基準パターン及び被
検査パターンのヒストグラムの不一致部分間面積
x,syそのものを偏差として扱うようにしても
よく、このような場合も本考案に包含される。尚
上記実施例のように、不一致部分間面積、sx
yを基準パターンの全面積Sで除したものを偏
差として扱う場合には、2軸法による場合にx軸
方向及びy軸方向の両方向のヒストグラムに対し
て共通の許容偏差を設定しておけばよいが、不一
致部分間面積そのものを偏差とする場合には、x
軸方向及びy軸方向の各方向に対してそれぞれ許
容偏差を設定しておく必要がある。
In the above explanation, the deviation is expressed as a percentage by dividing the area between the mismatched portions of the histograms of the reference pattern and the test pattern by the total area of the histogram of the reference pattern, but the mismatch between the histograms of the reference pattern and the test pattern The inter-part areas s x and s y themselves may be treated as deviations, and such cases are also included in the present invention. Incidentally, as in the above embodiment, the area between the mismatched portions, s x ,
When treating s y divided by the total area S of the reference pattern as a deviation, when using the two-axis method, set a common tolerance for histograms in both the x-axis and y-axis directions. However, if the area between the mismatched parts itself is used as the deviation, x
It is necessary to set allowable deviations in each of the axial and y-axis directions.

2軸法により基準パターンと被検査パターンと
を比較処理を行なうと、1軸法では判定できない
被検査パターンの良否をも判定できる。例えば基
準パターンのPsが第12図aに示すような場合
に被検査パターンPiが同図bに示す通りであつ
たとすると、両パターンのx軸方向ヒストグラム
xs及びHxには差が現われないが、y軸方向ヒ
ストグラムHys及びHyには明瞭な差が現われ
る。
By comparing the reference pattern and the pattern to be inspected using the two-axis method, it is possible to determine the quality of the pattern to be inspected, which cannot be determined using the one-axis method. For example, if the reference pattern P s is as shown in Figure 12a, and the inspected pattern P i is as shown in Figure 12b, there is a difference between the x-axis direction histograms H xs and H x of the two patterns. Although not shown, a clear difference appears in the y-axis direction histograms H ys and H y .

面積比較法によりパターンの比較を行なう場合
には、基準パターン及び被検査パターンの黒また
は白の絵素の数を計数して両パターンの黒または
白の面積を算出し、算出した両パターンの面積の
差をパターンの相違度とする。そしてこの相違度
を基準パターンの黒または白の面積で除して偏差
を計算し、この偏差を許容偏差と比較する。尚こ
の場合も両パターンの面積の差そのものを偏差と
して扱うようにしてもよい。
When comparing patterns using the area comparison method, count the number of black or white picture elements in the reference pattern and the pattern to be inspected, calculate the black or white area of both patterns, and calculate the calculated area of both patterns. Let the difference be the pattern dissimilarity. Then, a deviation is calculated by dividing this degree of difference by the black or white area of the reference pattern, and this deviation is compared with an allowable deviation. In this case as well, the difference in area between the two patterns itself may be treated as a deviation.

上記のようなパターンの比較処理は、各検査領
域ごとに行なわれ、各検査領域ごとに基準パター
ンと被検査パターンとの偏差が算出される(第6
図のステツプj)。
The pattern comparison process described above is performed for each inspection area, and the deviation between the reference pattern and the inspected pattern is calculated for each inspection area (6th
Step j) in the figure.

全ての検査領域の偏差が算出された後、許容偏
差が既に設定されているか否かの判定が行なわれ
る(第6図のステツプk)。最初はこの許容偏差
の設定が行なわれないので、次に第6図lのステ
ツプに進み、ステツプjで算出された各検査領域
毎の偏差を読み出す。オペレータはこの読み出さ
れたデータに基いて良品のバラツキによる偏差の
バラツキの範囲を示すデータをとる(第6図のス
テツプm)。良品の偏差のバラツキ範囲を知るた
めに十分なデータが得られていないと判断された
場合(第6図のステツプn)には再びステツプf
に戻り、正常な被検査物の画像データを取り込
む。以下ステツプg〜nを繰り出し、良品の偏差
のバラツキ範囲を示すのに十分なデータが得られ
たときに、得られたデータに基いて各検査領域ご
とに許容偏差を設定する(第6図のステツプ
o)。この許容偏差の設定を行なう際には、操作
表示パネル1aの検査領域設定用デジタルスイツ
チ26により検査領域を指定し、その検査領域の
許容偏差を許容偏差値設定用デジタルスイツチ2
4により設定する。次いで偏差書込み用押ボタン
スイツチ25を押してデジタルスイツチ26及び
24に設定したデータをコンピユータ12に入力
し、コンピユータのメモリに許容偏差値を記憶さ
せる。同じ操作を各検査領域毎に行ない、各検査
領域の許容偏差を記憶させる。
After the deviations of all inspection areas have been calculated, it is determined whether the allowable deviation has already been set (step k in FIG. 6). Since this permissible deviation is not set at first, the process then proceeds to step 1 in FIG. 6 and reads out the deviation for each inspection area calculated in step j. Based on the read data, the operator obtains data indicating the range of variation in deviation due to variation in non-defective products (step m in FIG. 6). If it is determined that sufficient data has not been obtained to know the range of deviation of non-defective products (step n in Fig. 6), step f is performed again.
Return to , and import the image data of the normal inspected object. The following steps g to n are carried out, and when enough data is obtained to show the range of deviation of non-defective products, the allowable deviation is set for each inspection area based on the obtained data (see Figure 6). Step o). When setting the allowable deviation, specify the test area using the test area setting digital switch 26 on the operation display panel 1a, and set the allowable deviation of the test area using the allowable deviation value setting digital switch 26.
Set by 4. Next, the deviation writing pushbutton switch 25 is pressed to input the data set in the digital switches 26 and 24 to the computer 12, and the allowable deviation value is stored in the computer's memory. The same operation is performed for each inspection area, and the allowable deviation of each inspection area is memorized.

許容偏差の設定を行つた後、被検査対象物の画
像データを取り込み(第6図ステツプp)、第6
図のステツプgに戻る。以下ステツプh〜kを順
次行ない、ステツプkでは既に許容偏差が設定さ
れているのでステツプqへと進む。ステツプqで
はすべての検査領域について基準パターンと被検
査パターンの偏差を許容偏差と比較し、すべての
検査領域で偏差が許容偏差以下の場合にその被検
査対象物が良品であることを示す良品信号を出力
する(第6図のステツプr)。この良品信号が出
力されると操作表示パネルの良品表示灯38が点
灯し、またカウンタ34の良品数量表示部32に
表示される計数値が1つ増加する(第6図のステ
ツプs)。またステツプqにおいていずれかの検
査領域で偏差が許容偏差より大きい場合には被検
査物が不良品であることを示す不良品信号を出力
する(第6図のステツプt)。この不良品信号が
出力されると、不良品表示灯39が点灯するとと
もに、カウンタ34の不良品数量表示部33の計
数値が1つ増加する(第6図のステツプu)。カ
ウンタの全数量表示部31の計数値は、良品信号
または不良品信号が出力されるごとに1つ増加
し、検査を行なつた被検査物の全数量を表示する
(第6図のステツプv)。また不良品信号が出力さ
れたときには不良品をコンベアから除去するため
の信号が出力される(第6図のステツプw)。
After setting the allowable deviation, import the image data of the object to be inspected (Step P in Figure 6), and
Return to step g in the figure. Thereafter, steps h to k are performed in sequence, and since the allowable deviation has already been set in step k, the process proceeds to step q. In step q, the deviation between the reference pattern and the pattern to be inspected is compared with the allowable deviation for all inspection areas, and if the deviation is less than the allowable deviation in all the inspection areas, a non-defective signal indicating that the inspected object is a good product is issued. is output (step r in FIG. 6). When this non-defective product signal is output, the non-defective product indicator light 38 on the operation display panel lights up, and the count displayed on the non-defective product quantity display section 32 of the counter 34 increases by one (step s in FIG. 6). If the deviation in any of the inspection areas is larger than the allowable deviation in step q, a defect signal indicating that the object to be inspected is defective is output (step t in FIG. 6). When this defective product signal is output, the defective product indicator lamp 39 lights up and the count value of the defective product quantity display section 33 of the counter 34 increases by one (step u in FIG. 6). The count value of the total quantity display section 31 of the counter increases by one each time a non-defective product signal or a defective product signal is output, and displays the total quantity of the inspected objects (step v in FIG. 6). ). Further, when a defective product signal is output, a signal for removing the defective product from the conveyor is output (step w in FIG. 6).

良品信号または不良品信号を除去するための信
号が出力された後再びステツプpに戻り、次の被
検査物の画像データを取り込んで上記と同様の検
査を繰り返す。
After the signal for removing the non-defective product signal or the defective product signal is output, the process returns to step p again, and image data of the next object to be inspected is taken in, and the same inspection as above is repeated.

許容偏差を決定するためのデータをとる際や、
不良品信号が出力された際には、各検査領域の基
準パターンと被検査パターンとの偏差を知りたい
場合がある。このような場合本考案の装置におい
ては、検査領域設定用デジタルスイツチ26で偏
差を知る必要のある検査領域を指定して偏差読出
用押ボタンスイツチ27を押すことにより、デジ
タル表示器28にその検査領域の偏差を表示させ
ることができる。
When collecting data to determine permissible deviations,
When a defective product signal is output, it may be necessary to know the deviation between the reference pattern and the pattern to be inspected in each inspection area. In such a case, in the apparatus of the present invention, by specifying the inspection area whose deviation is required to be known using the inspection area setting digital switch 26 and pressing the deviation reading pushbutton switch 27, the digital display 28 displays the inspection area. The deviation of the area can be displayed.

上記の説明ではモニタテレビ受像機21に基準
画像と被検査画像とを上下に並べて表示する
ようにしたが、更にこれらの画像に重ねて各検査
領域を示す表示を写し出すようにすることもでき
る。
In the above description, the reference image and the image to be inspected are displayed vertically on the monitor television receiver 21, but it is also possible to display a display indicating each inspection area superimposed on these images.

上記実施例の装置においては、2値化された後
の基準画像と被検査画像とをモニタテレビ受像機
21に並べて表示するので、実際にコンピユータ
で処理されている画像を見ることができ、検査が
適確に行なわれているか否かをモニタすることが
できる。
In the apparatus of the above embodiment, the reference image and the image to be inspected after being binarized are displayed side by side on the monitor television receiver 21, so that it is possible to see the image actually being processed by the computer, and the image to be inspected can be inspected. It is possible to monitor whether or not this is being done appropriately.

上記実施例では、検査領域の位置や大きさを設
定するスイツチとしてデジタルスイツチ26が用
いられ、また許容偏差値を設定するスイツチとし
てデジタルスイツチ24が用いられているが、こ
れらのデジタルスイツチは、各桁毎にスイツチダ
イアルを備えて各桁の数0〜9を個別に設定でき
るスイツチであり、デジタル量で条件を設定する
機器に広く用いられているものである。しかし本
考案で操作表示パネル1aに設ける検査領域設定
用スイツチ及び許容偏差設定用スイツチはこのよ
うなデジタルスイツチに限られるものではなく、
0〜9の各数字に対応した押ボタンを備えて各桁
の数字の押ボタンを高位の桁から順次押していく
ことによりデジタル量を設定するスイツチを用い
ることもできる。この場合は設定したデジタル量
を表示する表示器を設けておく必要がある。また
偏差書込み用スイツチ及び偏差読出用スイツチも
上記実施例で示した押ボタンスイツチ25及び2
7に限られるものではなく、キースイツチ(鍵盤
形スイツチ)等を用いることもできる。
In the above embodiment, the digital switch 26 is used as a switch to set the position and size of the inspection area, and the digital switch 24 is used as a switch to set the allowable deviation value. This switch is equipped with a switch dial for each digit and allows the number 0 to 9 of each digit to be set individually, and is widely used in devices that set conditions in digital quantities. However, in the present invention, the inspection area setting switch and the tolerance deviation setting switch provided on the operation display panel 1a are not limited to such digital switches.
It is also possible to use a switch that is provided with pushbuttons corresponding to each number from 0 to 9 and sets the digital amount by sequentially pushing the pushbuttons corresponding to the numbers of each digit, starting from the highest digit. In this case, it is necessary to provide a display to display the set digital quantity. Also, the deviation writing switch and the deviation reading switch are the push button switches 25 and 2 shown in the above embodiment.
7, and a key switch (keyboard type switch) or the like may also be used.

次に第14図を参照すると、本考案の装置の応
用例を種々示してある。同図aは被検査対象物の
印刷もれや汚れを検査する場合であり、同図bは
ラインに異物(図示の例では印刷された文字が異
なる箱)が混入しているのを検査する場合であ
る。また同図cは錠剤等のパツクの検査(錠剤の
不足、錠剤の欠け等)を行なう場合であり、同図
dはカメラを水平方向に配置して製品に印刷され
た文字や汚れを検査する場合である。更に、同図
eは被検査物をターンテーブルTに載せて検査す
る場合で、びんや円筒体のような断面が円形な対
象物を検査する場合である。また同図fはびんに
貼られたラベルの位置ずれを検査する場合であ
る。
Referring now to FIG. 14, various examples of applications of the apparatus of the present invention are shown. Figure a shows the case of inspecting the object to be inspected for printing leakage or stains, and figure b shows the case of inspecting the line for foreign matter (in the illustrated example, a box with different printed characters). This is the case. Figure c shows a case where a pack of tablets, etc. is inspected (for missing tablets, missing tablets, etc.), and figure d shows a case where the camera is placed horizontally to inspect characters and dirt printed on the product. This is the case. Furthermore, FIG. 5e shows a case where an object to be inspected is placed on a turntable T and is inspected, and an object having a circular cross section, such as a bottle or a cylinder, is inspected. Further, Fig. 5(f) shows a case where the positional shift of a label affixed to a bottle is inspected.

以上のように本考案によれば、基準画像及び被
検査画像に複数の検査領域を設定する場合に各検
査領域毎に許容偏差を設定できるので適確な検査
を行なわせることができる。また各検査領域毎に
偏差を読出して表示させることができるので、各
検査領域の許容偏差の設定を適確に行なうことが
でき、不良品がでた場合には被検査対象物のいず
れの部分が不良であるかを調べて品質管理の参考
に供することができる。
As described above, according to the present invention, when a plurality of inspection areas are set in the reference image and the image to be inspected, a permissible deviation can be set for each inspection area, so that accurate inspection can be performed. In addition, since the deviation can be read out and displayed for each inspection area, it is possible to accurately set the allowable deviation for each inspection area. It can be used as a reference for quality control by checking whether the product is defective or not.

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

第1図は本考案の一実施例の外観を示す斜視
図、第2図は本考案の装置においてカメラで被検
査対象物を撮像している状態を示す説明図、第3
図は本考案の装置で用いるイメージセンサの構成
を示す回路図、第4図は本考案の一実施例の概略
構成を示すブロツク図、第5図は本考案の一実施
例における操作表示パネルの構成を示す正面図、
第6図は本考案の装置による検査の流れを示すフ
ローチヤート、第7図a,bは自動分割法による
画像の分割のしかたを説明する説明図、第8図
a,bは指定分割法による画像の分割のしかたを
説明する説明図、第9図a,bは一定分割法によ
る画像の分割のしかたを説明する説明図、第10
図は被検査パターンのx軸方向及びy軸方向ヒス
トグラムを示す説明図、第11図a乃至cはヒス
トグラムの比較法を説明する線図、第12図a,
bは2軸法によりのみ検査できる基準パターンと
被検査パターンとをヒストグラムとともに示した
説明図、第13図a乃至fは本考案の種々の適用
例を示す斜視図である。 1……パターン自動検査装置本体、2……コン
ベア、3……被検査対象物、4……照明装置、5
……位置検出センサ、6……カメラ、7……イメ
ージセンサ、12……コンピユータ、21……モ
ニタテレビ受像機、24……許容偏差設定用デジ
タルスイツチ、25……偏差書込用押ボタンスイ
ツチ、26……検査領域設定用デジタルスイツ
チ、27……偏差読出用押ボタンスイツチ、28
……デジタル表示器、……基準画像、……被
検査画像。
FIG. 1 is a perspective view showing the appearance of an embodiment of the present invention, FIG. 2 is an explanatory diagram showing a state in which an object to be inspected is imaged by a camera in the apparatus of the present invention, and FIG.
The figure is a circuit diagram showing the configuration of an image sensor used in the device of the present invention, FIG. 4 is a block diagram showing the schematic configuration of an embodiment of the present invention, and FIG. Front view showing the configuration,
Figure 6 is a flowchart showing the flow of inspection using the device of the present invention, Figures 7a and b are explanatory diagrams explaining how to divide an image by the automatic division method, and Figures 8a and b are by the specified division method. An explanatory diagram explaining how to divide an image, Figures 9a and b are explanatory diagrams explaining how to divide an image by the constant division method, and Figure 10
The figure is an explanatory diagram showing the histogram in the x-axis direction and the y-axis direction of the pattern to be inspected, Figures 11a to 11c are diagrams explaining the method of comparing histograms, and Figures 12a,
13b is an explanatory diagram showing a reference pattern and a pattern to be inspected that can be inspected only by the two-axis method together with a histogram, and FIGS. 13a to 13f are perspective views showing various application examples of the present invention. 1... Main body of automatic pattern inspection device, 2... Conveyor, 3... Object to be inspected, 4... Lighting device, 5
... Position detection sensor, 6 ... Camera, 7 ... Image sensor, 12 ... Computer, 21 ... Monitor TV receiver, 24 ... Digital switch for setting tolerance deviation, 25 ... Push button switch for writing deviation , 26...Digital switch for setting inspection area, 27...Push button switch for reading deviation, 28
...digital display, ...reference image, ...test image.

Claims (1)

【実用新案登録請求の範囲】[Scope of utility model registration request] 基準となる対象物及び被検査対象物を撮像する
カメラと、前記カメラにより基準対象物及び被検
査対象物をそれぞれ撮像して得た基準画像及び被
検査画像にそれぞれ設定された少なくとも1つの
検査領域に含まれる基準パターン及び被検査パタ
ーンを比較して両パターンの間の偏差を算出する
コンピユータと、前記コンピユータに指令を与え
るスイツチ類を有する操作パネルとを備えてなる
パターン自動検査装置において、前記操作パネル
には前記検査領域をデジタル的に設定する検査領
域設定用スイツチと、前記検査領域設定用スイツ
チで設定されている検査領域の基準パターンと被
検査パターンとの許容偏差をデジタル量で設定す
る許容偏差設定用スイツチと、デジタル表示器
と、前記許容偏差設定用スイツチで設定された許
容偏差を前記コンピユータに入力することを指示
する偏差書込みスイツチと、前記検査領域設定用
スイツチで設定されている検査領域の基準パター
ンと被検査パターンとの偏差を前記デジタル表示
器に表示させることを前記コンピユータに指示す
る偏差読出スイツチとが設けられていることを特
徴とするパターン自動検査装置。
A camera that images a reference object and an object to be inspected, and at least one inspection area set in the reference image and the image to be inspected, respectively, obtained by imaging the reference object and the object to be inspected by the camera, respectively. An automatic pattern inspection device comprising: a computer that compares a reference pattern and a pattern to be inspected included in the pattern to calculate a deviation between the two patterns; and an operation panel having switches for giving commands to the computer. The panel includes an inspection area setting switch that digitally sets the inspection area, and a tolerance that digitally sets the allowable deviation between the reference pattern of the inspection area set by the inspection area setting switch and the pattern to be inspected. A deviation setting switch, a digital display, a deviation writing switch for instructing input of the allowable deviation set by the allowable deviation setting switch into the computer, and an inspection set by the inspection area setting switch. An automatic pattern inspection apparatus comprising: a deviation readout switch for instructing the computer to display the deviation between the reference pattern of the area and the pattern to be inspected on the digital display.
JP3313779U 1979-03-16 1979-03-16 Expired JPS6210838Y2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP3313779U JPS6210838Y2 (en) 1979-03-16 1979-03-16

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP3313779U JPS6210838Y2 (en) 1979-03-16 1979-03-16

Publications (2)

Publication Number Publication Date
JPS55134661U JPS55134661U (en) 1980-09-25
JPS6210838Y2 true JPS6210838Y2 (en) 1987-03-14

Family

ID=28888019

Family Applications (1)

Application Number Title Priority Date Filing Date
JP3313779U Expired JPS6210838Y2 (en) 1979-03-16 1979-03-16

Country Status (1)

Country Link
JP (1) JPS6210838Y2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0782542B2 (en) * 1988-01-29 1995-09-06 株式会社スキャンテクノロジー Print inspection method, print inspection device, and automatic printed matter distribution system

Also Published As

Publication number Publication date
JPS55134661U (en) 1980-09-25

Similar Documents

Publication Publication Date Title
US5305391A (en) Method of and apparatus for inspecting bottle or the like
US5943551A (en) Apparatus and method for detecting defects on silicon dies on a silicon wafer
JP2004226319A (en) Visual inspection apparatus and image acquisition method
JPS627588B2 (en)
KR20010098460A (en) Appearance inspection method and appearance inspection apparatus having high inspection processing speed
JPS6210838Y2 (en)
JPS627589B2 (en)
US5416335A (en) Automated visual inspection system for determining the set positions of a row of dip switches
JP2969011B2 (en) Appearance inspection device for soldering condition
JP2001004339A (en) Illumination non-uniformity measuring method for picture recognition inspecting system and picture recognition inspecting method
JPH07121721A (en) Printed character inspecting method
JPS6315380A (en) Method and device for inspecting article having repeated pattern
JPH11175727A (en) Inspection method and device therefor
JPH0731131B2 (en) Method for spotting periodic pattern
JPH0666528A (en) Visual inspecting method and apparatus
KR910007348B1 (en) Machine vision process and apparatus for reading a plurality of separated figures
JP2970860B2 (en) Soldering condition inspection equipment
JPH0631721Y2 (en) Wafer number reading device
JP4045819B2 (en) Illumination optical element inspection apparatus and illumination optical element inspection method
Asundi et al. Automated visual inspection of moving objects
JPH01150987A (en) Method for recognizing shape
JP2660560B2 (en) Defect inspection method
JPH06243235A (en) Checking device for mounted board
JPS6027064B2 (en) Label front and back inspection device
JP2023024148A (en) Image processing apparatus, image processing method, and image processing program