JP3007392B2 - Pattern recognition method and apparatus - Google Patents

Pattern recognition method and apparatus

Info

Publication number
JP3007392B2
JP3007392B2 JP2216559A JP21655990A JP3007392B2 JP 3007392 B2 JP3007392 B2 JP 3007392B2 JP 2216559 A JP2216559 A JP 2216559A JP 21655990 A JP21655990 A JP 21655990A JP 3007392 B2 JP3007392 B2 JP 3007392B2
Authority
JP
Japan
Prior art keywords
image data
horizontal
pattern matching
pattern
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 - Lifetime
Application number
JP2216559A
Other languages
Japanese (ja)
Other versions
JPH0498580A (en
Inventor
素春 本多
Original Assignee
ニチデン機械株式会社
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 ニチデン機械株式会社 filed Critical ニチデン機械株式会社
Priority to JP2216559A priority Critical patent/JP3007392B2/en
Publication of JPH0498580A publication Critical patent/JPH0498580A/en
Application granted granted Critical
Publication of JP3007392B2 publication Critical patent/JP3007392B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Landscapes

  • Image Analysis (AREA)

Description

【発明の詳細な説明】 産業上の利用分野 この発明は撮像装置かれ得られる2値化した被検査画
像を非接触で自動的に検出処理するパターンマッチング
方法とその装置に関し、特に撮像された対象ワークの位
置検出を行なうために被検査画像をテンプレートを用い
てパターン照合する基準画像パターンマッチングによる
パターン認識装置に関する。
Description: BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a pattern matching method for automatically detecting a binarized image to be inspected obtained by an image pickup apparatus in a non-contact manner, and an apparatus therefor. The present invention relates to a pattern recognition apparatus based on reference image pattern matching for performing pattern matching of an image to be inspected using a template to detect a position of a workpiece.

従来の技術 被検査画像内の部分画像と予め設定され比較対象とな
る標準パターンの対応する画素の一致を計数する事によ
って近似度を計算し最もよく似た部分画像を捜す処理を
テンプレートマッチングあるいはパターンマッチング処
理という。第12図はこのパターンマッチング処理の概要
を説明するための原理図であり、本発明の前提となるも
のである。以下、これについて説明する。
2. Description of the Related Art Template matching or pattern matching is performed by calculating the degree of approximation by counting the number of coincidences between corresponding pixels of a standard image to be compared with a partial image in an image to be inspected and searching for the most similar partial image. This is called matching processing. FIG. 12 is a principle diagram for explaining the outline of the pattern matching process, and is a premise of the present invention. Hereinafter, this will be described.

M行×N列の被検査画像5内のm行×n列(m≦M,n
≦N)の部分画像6と同一画素サイズのパターン照合の
ための基準画像7の対応する位置の画素を比較し一致し
た画素数を計数する。ある1座標での部分画像6と基準
画像7との比較計数個数はm×nであり入力データ数は
2×(m×n)個となる。例として、被検査画像5のサ
イズをM=320画素,N=240画素、基準画像7のサイズを
m=n=64画素とした場合入力データ数は8192、m=n
=128画素とした場合入力データ数は32654となり、これ
だけの処理量を1座標における類似度として演算しなけ
ればならない。被検査画像5内で部分画像6は(M−m
+1)×(N−n+1)個だけ存在し、その各々につい
てm×n回の比較を行なわなければならないので総計m
×n×(M−m+1)×(N−n+1)回の比較演算を
必要とする。すなわち、被検査画像5のサイズをM=32
0画素,N=240画素、基準画像7のサイズをm=n=64画
素とした場合、186,322,944回の比較演算を要すという
膨大な計算量となる。
M rows × n columns (m ≦ M, n) in the inspection image 5 of M rows × N columns
≤ N), the pixel at the corresponding position of the reference image 7 for pattern matching of the same pixel size with the partial image 6 of ≤ N) is compared, and the number of matched pixels is counted. The number of comparison counts between the partial image 6 and the reference image 7 at a certain coordinate is m × n, and the number of input data is 2 × (m × n). As an example, when the size of the inspection image 5 is M = 320 pixels, N = 240 pixels, and the size of the reference image 7 is m = n = 64 pixels, the number of input data is 8192, and m = n.
In the case of = 128 pixels, the number of input data is 32654, and this amount of processing must be calculated as the similarity at one coordinate. The partial image 6 in the inspection image 5 is (M-m
+1) × (N−n + 1), and m × n comparisons must be performed for each of them, so that a total of m
× n × (M−m + 1) × (N−n + 1) comparison operations are required. That is, the size of the image 5 to be inspected is M = 32
When 0 pixels, N = 240 pixels, and the size of the reference image 7 is m = n = 64 pixels, an enormous amount of calculation is required, requiring 186,322,944 comparison operations.

このような2次元の被検査画像のパターンを非接触で
自動的に高速検出処理するパターンマッチング処理に対
しては、例えば特公昭60−17152号および特開昭62−210
596号公報に有効なパターンマッチング処理を行なう装
置が記されている。特公昭60−17152号公報によるパタ
ーンマッチング方式は一般には複合形部分パターンマッ
チング方式と呼ばれその原理は、被検査画像の複数の特
徴的な特定部分の2次元パターンをそれぞれ基準画像7
として登録しておき、撮像された被検査画像5の2次元
パターンから部分画像6を逐次切り出し、前記切り出さ
れた部分画像6と上記基準画像7を比較し最もよく一致
する座標位置を検出するとしたものである。部分画像6
の大きさは12×12画素とすることで行なっている。その
パターンマッチング方式の特徴によりリアルタイムにて
認識をするには1座標における類似度としての演算処理
を1画素クロック期間内に終了させなければならないの
で12×12=144画素同時に行なわなければならない。そ
のために12×12=144画素の基準画像データは同時出力
が可能な構成でなければならないし、被検査画像データ
も同様に144画素の同時出力が可能な構成でなければな
らない。また、類似度を比較する比較回路も1画像走査
期間内で処理を終えるには1座標における類似度の演算
処理は1画素クロック期間内に終了させなければならな
いので12×12=144個の排他的論理和回路が必要とな
る。これらの入出力データは1座標における類似度であ
るので同時に演算処理するには、排他的論理和回路にお
いて288個の入力配線と144個の出力配線が必要となって
いる。
For such a pattern matching process for automatically detecting a pattern of a two-dimensional image to be inspected in a non-contact manner at a high speed, for example, Japanese Patent Publication No. Sho 60-17152 and Japanese Patent Laid-Open No. Sho 62-210
No. 596 discloses an apparatus for performing an effective pattern matching process. The pattern matching system disclosed in Japanese Patent Publication No. Sho 60-17152 is generally called a composite partial pattern matching system, and its principle is that a two-dimensional pattern of a plurality of characteristic specific portions of an image to be inspected is used as a reference image 7.
The partial image 6 is sequentially cut out from the two-dimensional pattern of the image 5 to be inspected, and the cut-out partial image 6 is compared with the reference image 7 to detect a coordinate position that best matches the partial image 6. Things. Partial image 6
Is made to be 12 × 12 pixels. In order to perform recognition in real time by the feature of the pattern matching method, the calculation processing as the similarity at one coordinate must be completed within one pixel clock period, so that 12 × 12 = 144 pixels must be simultaneously performed. Therefore, the reference image data of 12 × 12 = 144 pixels must have a configuration capable of simultaneous output, and the inspection image data must also have a configuration capable of simultaneously outputting 144 pixels. Also, in order to complete the processing within one image scanning period, the comparison circuit for comparing the similarity must complete the arithmetic processing of the similarity at one coordinate within one pixel clock period. A logical OR circuit is required. Since these input / output data are similarities in one coordinate, 288 input wirings and 144 output wirings are required in an exclusive OR circuit to perform arithmetic processing at the same time.

また、文献「Coarse−fine template matching」IEEE
Trans.,SMC−7 104−107頁(1977)及び「Sequential
hierarchial scene matching」IEEEETrans.,C−27,4,35
9−366頁(1978)によれば、最も画像分解能の高い画像
(原画像)上でパターン照合を行わず、予め分解能の粗
い画像を用意して順次、画像分解能を上げて行くことで
検出の効率を上げるという階層型パターンマッチング方
法が知られている。従来、画像分解能の粗いパターン照
合と画像分解能の高い画像上でのパターン照合を行う認
識方法である階層型パターンマッチング方法あるいは粗
精検出方法において、粗い分解能における1画素は複数
の画素の輝度データを合計した値を基に粗い画素として
の画素データとし処理する濃淡画像処理について記され
ており、この階層型パターンマッチング方法による検出
処理はソフトウエアにより行われており、リアルタイム
な位置検出を行なうには到っていない。
In addition, the literature "Coarse-fine template matching" IEEE
Trans., SMC-7, pp. 104-107 (1977) and “Sequential
hierarchial scene matching '' IEEEETrans., C-27,4,35
According to page 9-366 (1978), pattern matching is not performed on an image (original image) with the highest image resolution, but an image with a coarser resolution is prepared in advance, and the image resolution is sequentially increased and the detection is performed. Hierarchical pattern matching methods for increasing efficiency are known. Conventionally, in a hierarchical pattern matching method or a coarse / fine detection method, which is a recognition method of performing pattern matching with a coarse image resolution and pattern matching on an image with a high image resolution, one pixel at a coarse resolution represents luminance data of a plurality of pixels. Gray-scale image processing that processes pixel data as coarse pixels based on the total value is described.Detection processing by this hierarchical pattern matching method is performed by software, and in order to perform real-time position detection Not yet.

階層型パターンマッチング方法を用いた別の方法とし
て、特開昭62−55781号公報では、パターン照合を粗い
画素間隔で行うときには画像分解能はそのままにしてお
くが照合の基準パターンの全エリアでは行わず、部分領
域に対してのみパターン照合を行うことによって、処理
の高速化を図っている。階層型パターンマッチング方法
を用いた上記のいずれの方法とも粗い画素は原画像にお
いて登録された基準画像データそのものではなく、原画
像を圧縮あるいは限定することで基準となる画像データ
量を比較処理時に減らし処理の高速化を計っている。
As another method using the hierarchical pattern matching method, Japanese Patent Application Laid-Open No. Sho 62-55781 discloses that when pattern matching is performed at coarse pixel intervals, the image resolution is kept as it is, but the pattern matching is not performed in all areas of the reference pattern. By performing pattern matching only on partial areas, the processing speed is increased. In any of the above methods using the hierarchical pattern matching method, coarse pixels are not the reference image data itself registered in the original image, but the amount of reference image data is reduced during the comparison process by compressing or limiting the original image. We are trying to speed up processing.

任意の形状・大きさの基準パターンを用いてパターン
マッチングを行なうものとして従来の装置は、特開昭62
−210596号公報による方法がある。この方法によれば、
基準パターン(8×12)を任意の位置に配置して、任意
の大きさ及び任意の形状のn×mサイズの基準パターン
を構築する。n×m内の各々の基準パターンについて、
パターンマッチングを実行させ、その結果をn×mの基
準パターンの対象画素座標までシフトする。この様にし
て得られる濃淡画像を毎回シフト後に加算して行くこと
により目的を達成するというものである。
A conventional apparatus for performing pattern matching using a reference pattern having an arbitrary shape and size is disclosed in
There is a method according to -210596. According to this method,
The reference pattern (8 × 12) is arranged at an arbitrary position to construct an n × m size reference pattern having an arbitrary size and an arbitrary shape. For each reference pattern in n × m,
The pattern matching is executed, and the result is shifted to the target pixel coordinates of the n × m reference pattern. The objective is achieved by adding the grayscale images obtained in this way after each shift.

発明が解決しようとする問題点 小さな部分パターンを多数設けることによる複合形部
分パターンマッチング方式は基準画像7のサイズが小さ
いために3点ないし4点の部分パターンを一つの被検査
画像5範囲に対して登録している、そのために以下の問
題点があった。
Problems to be Solved by the Invention In the composite partial pattern matching method by providing a large number of small partial patterns, the size of the reference image 7 is small. Registration, which has the following problems.

1)パターン登録においては基準画像7のサイズが小さ
いために登録を行なうに当たっては特徴的な部分パター
ンを組み合わせて登録すると言う作業が必要となり、作
業者の質を選び登録作業の容易性に問題があった。
1) In the pattern registration, since the size of the reference image 7 is small, it is necessary to perform the operation of registering a combination of characteristic partial patterns in order to perform the registration. there were.

2)部分によるパターンマッチングは基準画像7のサイ
ズが小さいために1点のみの認識では認識率が低いため
に3点ないし4点の部分のパターンを1被検査画像範囲
に対して登録している。このために、相関値の大小のみ
でパターンの位置検出が可能な本来の方法に加え各部分
パターン間の相対位置関係(距離、角度)をチェックし
なければならないため、それだけ処理時間が増し、高速
な位置検出が出来ない。
2) In the pattern matching based on the part, since the size of the reference image 7 is small and the recognition rate is low in recognition of only one point, the pattern of three or four points is registered for one image area to be inspected. . For this reason, the relative position relationship (distance, angle) between each partial pattern must be checked in addition to the original method in which the position of the pattern can be detected only by the magnitude of the correlation value. Position cannot be detected.

3)部分パターン当のサイズが小さいために被検査画像
5のパターン検出範囲に部分パターンのサイズよりも大
きな同一のパターンが複数存在する場合、パターン位置
の検出が不可能である。例えば、パターン検出範囲に3
つの同一パターンが存在する場合、部分パターンとして
登録し最もよく一致する部分パターンの位置はパターン
照合を繰り返し行なうと3つの座標位置のいずれかが候
補点となるが一義的には決まらない。
3) When the same pattern larger than the size of the partial pattern exists in the pattern detection range of the image 5 to be inspected due to the small size of the partial pattern, the pattern position cannot be detected. For example, 3 in the pattern detection range
When there are two identical patterns, the position of the partial pattern which is registered as a partial pattern and matches the best is any one of the three coordinate positions as a candidate point when pattern matching is repeated, but cannot be uniquely determined.

4)部分パターンの大きさを大きくすれば、上記の問題
点は解決するが、ハードウェア規模が著しく増大してし
まうというパターンマッチング本来の問題が発生してし
まう。
4) Increasing the size of the partial pattern solves the above problem, but causes an inherent problem of pattern matching that the hardware scale is significantly increased.

5)部分パターンのサイズが12×12画素程度の大きさで
あるためノイズの影響を受け易く、それだけ位置の検出
精度が良くない。
5) Since the size of the partial pattern is about 12 × 12 pixels, it is easily affected by noise, and the position detection accuracy is not good.

ノイズとは本来ランダム的なものであるため、部分パ
ターンのサイズが小さい場合であろうが大きい場合であ
ろうが画素当りのノイズの発生確率は一般的に一様であ
る。この点からは部分パターンのサイズとは直接的に関
係無いのであるが、実際の被検査画像の濃淡レベルは2
値化が行ない易いようなコントラストのはっきりしたパ
ターンばかりではない。この場合に言うノイズとは2値
化スレッシュレベルと隔たった部分にはそのスレッシュ
レベルを横切る映像信号が発生しにくいのでノイズが乗
りにくいが、2値化スレッシュレベルとほとんど同じよ
うな映像信号レベルを他の場所と比べて比較的に多く持
つパターン部では2値化画像上ではノイズが発生し易く
なる。従って、被検査画像上にはコントラストがはっき
りした部分もあれば、そうでない部分もあり、コントラ
ストがはっきりしていて2値化したときにノイズが乗り
にくいパターン部とパターン形状より特徴的であるパタ
ーン部とは独立したものであるので、コントラストのは
っきりしないパターン部ではあるがパターン形状より特
徴的であるパターン部を部分パターンとして登録した場
合にはノイズの影響を受け易くなり、それだけ位置検出
の精度が悪くなる。部分パターンの個数を増すことでそ
の影響を少なくする事が出来るがそれだけ処理時間が増
すことになる。
Since noise is random in nature, the probability of occurrence of noise per pixel is generally uniform whether the size of the partial pattern is small or large. From this point, it is not directly related to the size of the partial pattern.
It is not only a pattern with a clear contrast that is easy to quantify. In this case, the noise is hard to be applied to a portion separated from the binarized threshold level because a video signal crossing the threshold level is hardly generated. However, a video signal level almost similar to the binarized threshold level is generated. Noise tends to occur on a binarized image in a pattern portion having a relatively large number as compared with other places. Therefore, there is a portion where the contrast is clear on the image to be inspected and a portion where the contrast is not clear. The pattern portion has a clear contrast and is hard to get noise when binarized, and the pattern is more characteristic than the pattern shape. Since the pattern part is independent of the pattern part, if it is registered as a partial pattern, it is easy to be affected by noise if the pattern part that is not clear contrast but is more characteristic than the pattern shape is registered. Gets worse. The effect can be reduced by increasing the number of partial patterns, but the processing time increases accordingly.

階層型パターンマッチング方法である特開昭62−5578
1号は粗検出時においては基準画像7を間引いて限定し
た原画像の一部分を用いた粗い基準パターンを作成しあ
る粗い画素間隔にてパターン照合を行なっているため、
基準画像7によって認識の可否が左右されることとな
る。また、基準画像7の登録に当たっては作業者の質を
選び登録作業の容易性に問題があった。
Japanese Patent Application Laid-Open No. Sho 62-5578, which is a hierarchical pattern matching method
No. 1 performs a pattern matching at a certain coarse pixel interval by creating a coarse reference pattern using a part of the original image limited by thinning out the reference image 7 at the time of coarse detection,
Whether the recognition is possible or not depends on the reference image 7. In addition, when registering the reference image 7, there is a problem in the ease of the registration work by selecting the quality of the worker.

特開昭62−210596号の方法のおいては基準画像7のサ
イズとしては小領域の8×12画素のものを基本としてお
り、大きなサイズのエリアのパターン照合を求めること
は可能であるが、そのためには多数の部分パターンを用
い処理を行なわなければならず、それだけ処理時間を要
すこととなり、検出するパターンにより登録する部分パ
ターンの個数が変化するため、被検査画像により認識時
間が異なり認識装置を搭載した装置の時間管理を煩雑な
ものとしていた。また、それらの多数の部分パターンを
登録するには作業者の操作及び判断を複雑なものとし、
登録作業が容易なものではなかった。
In the method disclosed in Japanese Patent Application Laid-Open No. Sho 62-210596, the size of the reference image 7 is based on a small area of 8 × 12 pixels. For this purpose, processing must be performed using a large number of partial patterns, which requires processing time. Since the number of partial patterns to be registered changes depending on the pattern to be detected, the recognition time differs depending on the image to be inspected. The time management of the device equipped with the device is complicated. In addition, registering a large number of these partial patterns complicates the operation and judgment of the operator,
Registration was not easy.

従って、本発明は上記欠点に鑑み提案されたものであ
り、新規且つ改良されたパターン認識装置の提供を目的
とするものである。
Accordingly, the present invention has been proposed in view of the above-mentioned drawbacks, and has as its object to provide a new and improved pattern recognition device.

問題点を解決するための手段 上記の問題点を解決するために、どのような技術的な
手段を採用したかを以下に記載する。
Means for Solving the Problems The following describes what technical means have been adopted to solve the above problems.

2次元画像の中からある特定パターンを自動抽出する
パターン認識方法において、 撮像手段からの2次元映像信号をデジタル化し、被検
査画像の特徴的なパターンの任意サイズを切り出し基準
画像として予め2値化画像を原画像としてそのまま記憶
し任意の2次元座標位置に記憶した画像データを出力可
能な基準画像記憶手段と、 2次元被検査画像データの任意数のdy水平走査ライン
をマイクロコンピュータから設定された水平走査ライン
分だけ保持可能な(VS−1)個の水平走査ライン保持手
段をk(1≦k≦dy)水平走査ライン間隔(=k画素間
隔)で均等に間を置いたVS行の個々の検査座標位置に対
応した被検査画像データが同時に出力されるようにした
垂直画像データ抽出手段と、 前記垂直画像データ抽出手段からの被検査画像データ
のVS個の同時出力を水平方向の任意のdx画素までをマイ
クロコンピュータから設定された画素分だけ保持可能な
画素シフト手段を(HS−1)個直列につなぐことで、1
水平方向の被検査画像データが同時にある設定されたj
画素(1≦j≦dx)間隔で均等に間を置いたHSヵ所から
同時に出力されるようにしたものを前記垂直抽出手段か
らのVS個の水平走査ラインから同時に出力された被検査
画像データを入力として、前記(HS−1)個直列の画素
シフト手段をVS段設ける事で2次元被検査画像データの
総計VS×HS地点の個々の検査座標位置に対応した被検査
画像データを同時に出力されるようにした水平画像デー
タ抽出手段と、 前記基準画像記憶手段からの基準画像データと前記水
平画像データ抽出手段からの個々の検査座標位置に対応
した被検査画像データを同時にVS×HS個の地点でパター
ン比較し、VS×HSの地点個々の検査座標位置に対応した
パターン照合出力をVS×HS個同時に合致データとして個
々の検査座標位置に対応した部分それぞれより同時にシ
リアル出力することからなる論理演算手段と、 前記論理演算手段からの個々の検査座標位置に対応し
た各合致データ出力を個々に同時カウントすることによ
りVS×HS個とパターン照合を1画像走査で完了し個々の
検査座標位置に対応した部分で独立に相関値として算出
保持する相関値積算手段により構成され、 第1回目の粗検出は水平画像データ抽出手段・垂直画
像データ抽出手段をそれぞれの第1回目のパターン照合
の画素間隔でHS×VS個の被検査画像データが同時に出力
されるよう設定し、被検査画像の検出範囲の中心位置に
VS行×HS列の検査位置の中心部が対応するように配置し
て第1回目の粗検出を行ない、第1回目のパターン照合
を行ったHS×VS個の候補点の相関データの中で最大相関
値を保持する部分を検索し、所定の粗検出スレッシュ値
よりも大きい値であれば前記最大相関値を保持した部分
に対応したパターン照合座標位置をもって、次回のパタ
ーン照合の中心座標位置と決定し、前記第1回目の粗検
出にて求めた最高相関値の座標位置を中心にVS行×HS列
の検査位置の中心部が対応するように配置し、第2回目
の粗検出を水平方向は{第1の画素間隔−第2の画素間
隔×(HS−1)/2}≦0を、垂直方向は{第1の画素間
隔−第2の画素間隔×(VS−1)/2}≦0、満たし最小
の整数値となる第2の画素間隔にてVS行×HS列の中心部
が対応するように配置してパターン照合を行い第2回目
のHS×VS個の候補点の相関データの最高相関値の座標位
置を求め、前記第2回目の粗検出にて求めた最高相関値
の座標位置を中心にVS行×HS列の中心部を配置して第3
回目以降のパターン照合を水平・垂直方向の設定画素間
隔が1画素間隔となるまで水平方向は{第P回目のパタ
ーン照合の画素間隔−第P+1回目のパターン照合の画
素間隔×(HS−1)/2}≦0を、垂直方向は{第P回目
のパターン照合の画素間隔−第P+1回目のパターン照
合の画素間隔×(VS−1)/2}≦0を、満たし最小の整
数値となる第P+1回目のパターン照合の画素間隔にて
VS行×HS列の中心部を第P回目の最高相関値の座標位置
を配置して行い、1画素間隔にて行なったパターン照合
のHS×VS個の候補点の相関データの最大値が所定の検出
スレッシュ値よりも大きい値であれば前記最大相関値を
保持した部分に対応した座標位置を検出位置とすること
を特徴とするパターン認識方法により達成される。
In a pattern recognition method for automatically extracting a specific pattern from a two-dimensional image, a two-dimensional video signal from an imaging unit is digitized, and an arbitrary size of a characteristic pattern of an image to be inspected is cut out and binarized in advance as a reference image. Reference image storage means capable of storing the image as it is as an original image and outputting image data stored at an arbitrary two-dimensional coordinate position, and an arbitrary number of dy horizontal scanning lines of the two-dimensional inspection image data set from a microcomputer. (VS-1) horizontal scanning line holding means capable of holding only the horizontal scanning lines are individually set to VS rows at k (1 ≦ k ≦ dy) horizontal scanning line intervals (= k pixel intervals). Vertical image data extracting means for simultaneously outputting the inspected image data corresponding to the inspection coordinate position; and inspecting image data from the vertical image data extracting means. By connecting the VS pieces simultaneous output of up to any dx pixels in the horizontal direction pixels only capable of holding the pixel shifting means is set from the microcomputer (HS-1) pieces series, 1
Set j with image data to be inspected in the horizontal direction at the same time
The image data to be inspected simultaneously output from the VS horizontal scanning lines from the vertical extraction means are simultaneously output from the HS locations evenly spaced at the pixel (1 ≦ j ≦ dx) interval. By providing the (HS-1) serial pixel shift means in the VS stage as input, the inspected image data corresponding to the individual inspection coordinate positions of the total VS × HS points of the two-dimensional inspected image data is simultaneously output. Horizontal image data extraction means, and the reference image data from the reference image storage means and the inspection image data corresponding to the individual inspection coordinate positions from the horizontal image data extraction means are simultaneously VS × HS points. Pattern comparison output corresponding to each inspection coordinate position of VS × HS point is output serially from each part corresponding to each inspection coordinate position as VS × HS coincidence data at the same time. And a coincidence data output corresponding to each inspection coordinate position from the logic operation means is simultaneously and individually counted to complete the pattern matching with VS × HS by one image scanning, and A portion corresponding to the inspection coordinate position is constituted by a correlation value accumulating means for independently calculating and holding a correlation value, and the first coarse detection is performed by using the horizontal image data extracting means and the vertical image data extracting means in the respective first pattern. Set so that HS × VS image data to be inspected is output at the same time at the pixel interval of collation.
In the correlation data of the HS × VS candidate points that were arranged so that the center of the inspection position of VS rows × HS columns corresponded, performed the first coarse detection, and performed the first pattern matching, Search for the part holding the maximum correlation value, if the value is greater than the predetermined coarse detection threshold value, the pattern matching coordinate position corresponding to the part holding the maximum correlation value, and the center coordinate position of the next pattern matching Is determined and arranged so that the center of the inspection position of VS rows × HS columns corresponds to the coordinate position of the maximum correlation value obtained in the first coarse detection, and the second coarse detection is performed horizontally. The direction is {first pixel interval−second pixel interval × (HS−1) / 2} ≦ 0, and the vertical direction is {first pixel interval−second pixel interval × (VS−1) / 2. } ≦ 0, the pattern is arranged so that the center of the VS row × HS column corresponds to the second pixel interval at which the minimum integer value is satisfied. The second correlation is performed to determine the coordinate position of the highest correlation value of the correlation data of the second HS × VS candidate points, and the VS line is centered on the coordinate position of the highest correlation value obtained in the second coarse detection. × 3rd by arranging the center of the HS row
In the horizontal and vertical directions until the set pixel interval in the horizontal / vertical direction becomes one pixel interval, the horizontal direction is {pixel interval of the Pth pattern collation−pixel interval of the (P + 1) th pattern collation × (HS−1). / 2} ≦ 0, and the vertical direction is the smallest integer value that satisfies {pixel interval of P-th pattern matching−pixel interval of P + 1-th pattern matching × (VS−1) / 2} ≦ 0. At the pixel interval of the (P + 1) th pattern matching
The central portion of the VS row × HS column is arranged at the coordinate position of the Pth highest correlation value, and the maximum value of the correlation data of HS × VS candidate points of pattern matching performed at one pixel interval is predetermined. If the value is larger than the detection threshold value, the coordinate position corresponding to the portion holding the maximum correlation value is set as the detection position.

他の解決手段は、2次元画像中の特定パターンを自動
抽出するパターン認識方法において、前記定数をdx=3
2,dy=32,HS=7,VS=7とし、その検出手段は第1回目
の粗検出は水平画像データ抽出手段・垂直画像データ抽
出手段ともに8画素間隔で被検査画像データが出力され
るよう設定し、被検査画像の検出範囲の中心位置に7行
7列の検査位置の中心部(4行4列目)が対応するよう
に配置して第1回目の粗検出を行ない、第1回目の49個
の候補点の座標位置の相関値の中から最大相関値が所定
の粗検出スレッシュ値よりも大きい値であれば前記最大
相関値を保持した部分に対応した座標位置を求め、前記
最大相関値を保持した部分に対応した前記第1回目の粗
検出にて求めた座標位置を中心に第2回目の粗検出を3
画素間隔にて行い第2回目の49個の候補点の座標位置の
相関値の中から最大相関値が所定の粗検出スレッシュ値
よりも大きい値であれば前記最大相関値を保持した部分
に対応した座標位置を求め、前記第2回目の粗検出にて
求めた最大相関値を持つ座標位置を中心に第3回目の検
出を1画素間隔にて行い第3回目の49個の候補点の座標
位置の相関値の中から最大相関値が所定の検出スレッシ
ュ値よりも大きい値であれば前記最大相関値を保持した
部分に対応した座標位置を持って検出位置とすることを
特徴とするパターン認識方法により達成される。
Another solution is a pattern recognition method for automatically extracting a specific pattern in a two-dimensional image, wherein the constant dx = 3
2, dy = 32, HS = 7, VS = 7, and the first coarse detection outputs image data to be inspected at an interval of 8 pixels for both the horizontal image data extraction means and the vertical image data extraction means. The first coarse detection is performed by arranging such that the center of the inspection position in the 7th row and 7th column (4th row and 4th column) corresponds to the center position of the detection range of the image to be inspected. If the maximum correlation value is larger than a predetermined coarse detection threshold value from among the correlation values of the coordinate positions of the 49th candidate point of the fourth round, the coordinate position corresponding to the part holding the maximum correlation value is determined, The second coarse detection is performed three times around the coordinate position obtained in the first coarse detection corresponding to the portion holding the maximum correlation value.
If the maximum correlation value is larger than a predetermined coarse detection threshold value among the correlation values of the coordinate positions of the 49 candidate points in the second time performed at the pixel interval, it corresponds to the portion holding the maximum correlation value The third detection is performed at one-pixel intervals around the coordinate position having the maximum correlation value obtained in the second coarse detection, and the coordinates of the third 49 candidate points are obtained. If the maximum correlation value among the position correlation values is larger than a predetermined detection threshold value, the detected position is a coordinate position corresponding to a portion holding the maximum correlation value, and the pattern is detected. Achieved by the method.

更に他の解決手段は第1項記載の解決手段において、
dx=32,dy=32,HS=7,VS=7とし、その検出手段は第1
回目を16画素間隔で第1回目のパターン照合の画素間隔
で7×7=49個の被検査画像データが同時に出力される
よう設定し、被検査画像の検出範囲の中心位置に7行×
7列の検査位置の中心部(4行4列目)が対応するよう
に配置して第1回目の粗検出を行ない、もし粗検出スレ
ッシュ値より高い相関値となるパターン照合位置が獲得
できなかった場合は第2回目は同じく16画素間隔でパタ
ーン照合を行なうが基準画像パターンの画像データ発生
位置を8画素ずらした位置で認識を行なうことにより照
合位置を算出することとし、第2回目の粗検出スレッシ
ュ値は第1回目の粗検出スレッシュ値と同一値とし第2
回目用の粗検出スレッシュ値より大きくなった候補点が
見つかった場合、マイクロコンピュータより事前に設定
された第2回目用の粗検出スレッシュ値より大きくなっ
た第2回目の49個の候補点の相関データの最高相関値の
座標位置を求め、前記第2回目の粗検出にて求めた最高
相関値の座標位置を中心に第3回目の粗検出を3画素間
隔にて行いマイクロコンピュータより第2回目の粗検出
の後に設定された第3回目用の粗検出スレッシュ値より
大きくなった第3回目の49個の候補点の相関データの最
高相関値の座標位置を求め、前記第3回目の粗検出にて
求めた最高値位置座標を中心に第4回目以降のパターン
照合を1画素間隔にて行い、第4回目の49個の候補点の
相関データの最大値が所定の検出スレッシュ値よりも大
きい値であれば前記最大相関値を保持した部分に対応し
た座標位置を検出位置とすることを特徴とするパターン
認識方法により達成される。
Still another solution is the solution according to item 1,
dx = 32, dy = 32, HS = 7, VS = 7, and the detection means is the first
At the 16th pixel interval, 7 × 7 = 49 pieces of image data to be inspected are set to be simultaneously output at the pixel interval of the first pattern matching, and 7 lines × 7 lines are set at the center position of the detection range of the image to be inspected.
The first coarse detection is performed by arranging the 7-column inspection positions so as to correspond to the center (4th row, 4th column), and a pattern matching position having a correlation value higher than the coarse detection threshold value cannot be obtained. In the second case, the pattern matching is performed at 16 pixel intervals in the same manner, but the matching position is calculated by performing recognition at a position where the image data generation position of the reference image pattern is shifted by 8 pixels. The detection threshold value is the same as the first coarse detection threshold value, and the second
If a candidate point larger than the second coarse detection threshold value is found, the correlation of the 49 second candidate points larger than the second coarse detection threshold value set in advance by the microcomputer. The coordinate position of the highest correlation value of the data is obtained, the third coarse detection is performed at three pixel intervals around the coordinate position of the highest correlation value obtained in the second coarse detection, and the microcomputer performs the second coarse detection. The coordinate position of the highest correlation value of the correlation data of the 49 candidate points for the third time, which has become larger than the third coarse detection threshold value set after the coarse detection, is obtained. The fourth and subsequent pattern matchings are performed at one-pixel intervals centering on the maximum value position coordinates obtained in the above, and the maximum value of the correlation data of the 49th candidate point in the fourth time is larger than a predetermined detection threshold value. If the value is It is achieved by the pattern recognition method which is characterized in that the detected position coordinate position corresponding to the holding portion a large correlation value.

また、別の解決手段は第1項記載の解決手段におい
て、dx=32,dy=32,HS=7,VS=7とし、その検出手段は
第1回目を32画素間隔で第1回目のパターン照合の画素
間隔で7×7=49個の被検査画像データが同時に出力さ
れるよう設定し、被検査画像の検出範囲の中心位置に7
行×7列の検査位置の中心部(4行4列目)が対応する
ように配置して第1回目の粗検出を行ない、第2回目の
パターン照合においても粗検出スレッシュ値より高い相
関値となるパターン照合位置が獲得できなかった場合は
第2回目は同じく32画素間隔で第1回目の粗検出スレッ
シュ値でパターン照合を行なうが基準画像の画像データ
発生位置を16画素ずらした位置で認識を行なうことによ
り照合位置を算出することとし、もし粗検出スレッシュ
値より高い相関値となるパターン照合位置が獲得できな
かった場合は第3回目は同じく32画素間隔でパターン照
合を行なうが基準画像の画像データ発生位置を第2回目
より更に8画素ずらした位置で認識を行なうことにより
照合位置を算出することとし、第3回目の粗検出スレッ
シュ値は第1回目の粗検出スレッシュ値と同一値とし第
1回目用の粗検出スレッシュ値より大きくなった第3回
目の49個の候補点の座標位置の相関値の中から最大の相
関値を持つ座標位置を求め、前記第3回目の粗検出にて
求めた座標位置を中心に第4回目の粗検出を3画素間隔
にて行い第4回目の49個の候補点の座標位置の相関値の
中から最大の相関値を持つ座標位置を求め、前記第4回
目の粗検出にて求めた座標位置を中心に第5回目の検出
を1画素間隔にて行い第5回目の49個の候補点の座標位
置の相関値の中から最大の相関値が所定の検出スレッシ
ュ値よりも大きい値であれば前記最大相関値を保持した
部分に対応した座標位置を持って検出位置とすることを
特徴とするパターン認識方法により達成される。
Another solution is the solution described in item 1, wherein dx = 32, dy = 32, HS = 7, VS = 7, and the detection means performs the first pattern at 32 pixel intervals. 7 × 7 = 49 pieces of inspection image data are set to be output simultaneously at the pixel interval of the collation, and 7
The first coarse detection is performed by arranging the central part (4th row, 4th column) of the inspection position of the row × 7 columns so as to correspond, and the correlation value higher than the coarse detection threshold value also in the second pattern matching If the pattern matching position is not obtained, the pattern matching is performed in the second time using the first coarse detection threshold value at the same 32 pixel interval, but the position where the image data generation position of the reference image is shifted by 16 pixels is recognized. Is performed, the pattern matching position is calculated. If a pattern matching position having a correlation value higher than the coarse detection threshold value cannot be obtained, the pattern matching is performed for the third time at the same 32 pixel interval, but the reference image The recognition position is calculated by recognizing the image data generation position at a position shifted by 8 pixels from the second time, and the third coarse detection threshold value is set to the first time. A coordinate position having the maximum correlation value is obtained from among the correlation values of the coordinate positions of the 49 candidate points of the third time, which is the same value as the detection threshold value and is larger than the coarse detection threshold value for the first time, The fourth coarse detection is performed at three pixel intervals centering on the coordinate position obtained in the third coarse detection, and the maximum correlation value among the correlation values of the coordinate positions of the 49th candidate point in the fourth time The fifth detection is performed at one-pixel intervals centering on the coordinate position obtained by the fourth coarse detection, and the fifth correlation value of the 49 candidate points is obtained. If the maximum correlation value is larger than a predetermined detection threshold value, the detection position is obtained by using a coordinate position corresponding to the portion holding the maximum correlation value. Is done.

更に別の解決手段は第1項記載の解決手段において、
1画素間隔にて行ったHS×VS個のパターン照合の相関デ
ータと検査座標位置を用いた補間演算処理により水平・
垂直方向ともに1画素以下の照合座標位置を算出し検出
位置とすることを特徴とするパターン認識方法により、
また、1画素間隔にて行ったパターン照合の相関データ
を用いてそのパターン照合位置を水平方向は最高相関値
を持つ座標位置を含む左右両隣の座標の相関データの計
3データを、垂直方向は最高相関値を持つ座標位置を含
む上下両隣の座標の相関データのそれぞれ計3データを
用いたスプライン補間演算より水平・垂直方向ともに1
画素以下の照合座標位置を算出し検出位置とすることを
特徴とするパターン認識方法によりそれぞれ達成され
る。
Still another solution is the solution according to item 1, wherein
Interpolation processing using the HS × VS pattern matching correlation data and inspection coordinate positions performed at one pixel intervals makes horizontal and horizontal
According to a pattern recognition method, a collation coordinate position of one pixel or less in both vertical directions is calculated and set as a detection position.
In addition, the pattern matching position is horizontally determined by using the correlation data of the pattern matching performed at one pixel interval. From the spline interpolation calculation using a total of three pieces of correlation data of the upper and lower adjacent coordinates including the coordinate position having the highest correlation value, 1 in both the horizontal and vertical directions
Each is achieved by a pattern recognition method characterized in that a collation coordinate position of a pixel or less is calculated and set as a detection position.

上述する認識方法は更に前記相関値積算手段の相関値
データをマイクロコンピュータより事前に設定されたパ
ターン検出スレッシュ値との大小を同時に比較判定する
ことで候補点におけるパターン照合状態を高速に検出で
きるように、前記相関値積算手段のデータ出力と、保持
した検出スレッシュ値と比較し、個々の検査座標位置に
対応した座標位置との間で大小を同時に比較判定し、そ
の結果を保持する個々の検査座標位置に対応した保持手
段をVS×HS個の個々の検査座標位置に対応した分だけ設
けることとし、マイクロコンピュータには1水平走査ラ
インHSヵ所の比較結果を一まとめにしマイクロコンピュ
ータの1回の読み込みで1水平走査ラインの各パターン
照合位置の状態を把握できるように状態を保持した手段
を垂直パターン照合のVS本だけ設けることで、各1水平
走査ラインの各パターン照合位置の状態の概略を高速に
把握しその演算対応位置の特定を行えるようにした水平
候補点検出手段を追加して構成され、第1回目の粗検出
は水平画像データ抽出手段・垂直画像データ抽出手段を
それぞれの第1回目のパターン照合の画素間隔でHS×VS
個の被検査画像データが同時に出力されるように設定
し、被検査画像の検出範囲の中心位置にVS行×HS列の検
査位置の中心部が対応するように配置して第1回目の粗
検出を行ない、前記水平候補点検出手段により第1回目
の粗検出の後マイクロコンピュータより事前に設定され
た第1回目の粗検出スレッシュ値を越える検出位置の候
補点が存在するかを調べ、存在していた場合に存在を示
している水平比較ラインの前記水平候補点検出手段の情
報を読み込み、前記情報に対応するパターン照合座標位
置における相関値を保持している手段より、第1回目の
パターン照合を行った複数の候補点の相関カウント値の
中で最大相関値を保持する部分に対応したパターン照合
座標位置をもって、次回のパターン照合の中心座標位置
と決定し、前記第1回目の粗検出にて求めた最高相関値
の座標位置を中心にHS行×VS列の検査位置の中心部が対
応するように配置し、第2回目の粗検出を水平方向は
{第1の画素間隔−第2の画素間隔×(HS−1)/2}≦
0を、垂直方向は{第1の画素間隔−第2の画素間隔×
(VS−1)/2}≦0を、満たす第2の画素間隔にてVS行
×HS列の中心部が対応するように配置して行い前記水平
候補点検出手段からマイクロコンピュータより第1回目
の粗検出の後に設定された第2回目用の粗検出スレッシ
ュ値より大きくなった第2回目の複数の候補点の相関デ
ータの最高相関値の座標位置を求め、前記第2回目の粗
検出にて求めた最高値位置座標を中心にVS行×HS列の中
心部を配置して第3回目以降のパターン照合を1画素間
隔にて行うまで水平方向は{第P回目のパターン照合の
画素間隔−第P+1回目のパターン照合の画素間隔×
(HS−1)/2}≦0を、垂直方向は{第P回目のパター
ン照合の画素間隔−第P+1回目のパターン照合の画素
間隔×(VS−1)/2}≦0を、満たす第P+1回目のパ
ターン照合の画素間隔にてVS行≦×HS列の中心部を配置
して行い、前記水平候補点検出手段からマイクロコンピ
ュータよりパターン照合を1画素間隔にて行った第P+
1回目用の検出スレッシュ値より大きくなった第P+1
回目の単一あるいは複数の候補点の相関データの最大値
を持つ座標位置を検出位置とすることを特徴とするパタ
ーン認識方法により達成される。
The above-described recognition method can further detect the pattern matching state at the candidate point at high speed by simultaneously comparing and determining the correlation value data of the correlation value accumulating means with a pattern detection threshold value set in advance by a microcomputer. Then, the data output of the correlation value accumulating means is compared with the held detection threshold value, and the magnitudes are simultaneously compared and determined between the coordinate positions corresponding to the individual inspection coordinate positions, and the individual inspections holding the results are performed. The holding means corresponding to the coordinate position is provided for each of the VS × HS individual inspection coordinate positions, and the microcomputer collects the comparison results of one horizontal scanning line HS and collects the comparison results at one time by the microcomputer. The means that holds the state so that the state of each pattern matching position of one horizontal scanning line can be grasped by reading By providing only the book, a horizontal candidate point detecting means is provided which is capable of quickly grasping the outline of the state of each pattern matching position of each horizontal scanning line and specifying the position corresponding to the calculation, and In the coarse detection of the second time, the horizontal image data extraction means and the vertical image data extraction means are set to HS × VS at the pixel interval of the first pattern matching.
Is set so that the image data to be inspected are output at the same time, and the center of the inspection position of VS rows × HS columns is arranged to correspond to the center position of the detection range of the image to be inspected. After the first coarse detection by the horizontal candidate point detecting means, the microcomputer checks whether or not there is a candidate point at a detection position exceeding the first coarse detection threshold value set in advance by the microcomputer. The information of the horizontal candidate point detection means of the horizontal comparison line indicating the existence of the first comparison pattern is read from the means for holding the correlation value at the pattern matching coordinate position corresponding to the information. The pattern coordinate position corresponding to the part holding the maximum correlation value among the correlation count values of the plurality of candidate points subjected to the collation is determined as the center coordinate position of the next pattern collation. Are arranged so that the center of the inspection position of the HS row × VS column corresponds to the center of the coordinate position of the highest correlation value obtained by the coarse detection, and the second coarse detection is performed in the horizontal direction of the first pixel. Interval−second pixel interval × (HS−1) / 2} ≦
0, the vertical direction is {first pixel interval−second pixel interval ×
The (VS-1) / 2} ≦ 0 is arranged so that the center of the VS row × HS column corresponds at the second pixel interval that satisfies (VS-1) / 2} ≦ 0. The coordinate position of the highest correlation value of the correlation data of the plurality of candidate points for the second time, which is larger than the second coarse detection threshold value set after the coarse detection, is determined. The horizontal direction is the pixel interval of the P-th pattern matching until the third and subsequent pattern matchings are performed at one-pixel intervals by arranging the center of the VS row and HS column with the maximum value position coordinates obtained as the center. -Pixel interval of the (P + 1) th pattern matching x
(HS-1) / 2} ≦ 0, and the vertical direction satisfies {pixel interval of P-th pattern matching−pixel interval of P + 1-th pattern matching × (VS−1) / 2} ≦ 0. The center of the VS row ≦ × HS column is arranged at the pixel interval of the (P + 1) th pattern matching, and the pattern matching is performed at one pixel interval by the microcomputer from the horizontal candidate point detecting means.
P + 1 that has become larger than the detection threshold value for the first time
This is achieved by a pattern recognition method characterized by using the coordinate position having the maximum value of the correlation data of the single or plural candidate points at the time of the detection as the detection position.

更に別の第2の解決手段は、2次元画像の中からある
特定パターンを自動抽出するパターン認識方法におい
て、 撮像手段からの2次元映像信号をデジタル化し、被検
査画像の特徴的なパターンの任意サイズを切り出し基準
画像として予めメモリに記憶した画像データを出力可能
な基準画像パターン記憶手段と、 2次元被検査画像データの任意数の水平走査dyライン
をマイクロコンピュータから設定された分だけ保持可能
な(VS−1)個の水平走査ライン保持手段を(1≦k≦
dy)水平走査ライン間隔(k画素間隔)で均等に間を置
いたVS行の個々の検査座標位置に対応した被検査画像デ
ータが同時に出力されるようにした垂直画像データ抽出
手段と、 前記垂直画像データ抽出手段からの画像データのVS個
の同時出力を水平方向の任意数の画素dxまでをマイクロ
コンピュータから設定された画素分だけ保持可能な画素
シフト手段を(HS−1)個直列につなぐことで、1水平
方向の被検査画像データが同時にある設定された画素
(1≦j≦dx)間隔(j画素間隔)で均等に間を置いた
HSヵ所から同時に出力されるようにしたものを前記垂直
抽出手段からのVS個の水平走査ラインから同時に出力さ
れた被検査画像データを入力として、前記(HS−1)個
直列の画素シフト手段をVS段設ける事で2次元被検査画
像データの総計VS×HS地点の個々の検査座標位置に対応
した被検査画像データを同時に出力されるようにした水
平画像データ抽出手段と、 前記基準画像記憶手段からの画像データと前記水平画
像データ抽出手段からの個々の検査座標位置に対応した
被検査画像データを同時にパターン比較するVS×HS個の
排他的論理和からなる個々の検査座標位置に対応したパ
ターン照合出力をVS×HS個同時に合致パルスとして個々
の検査座標位置に対応した排他的論理和手段より出力す
ることからなる論理演算手段と、 前記論理演算手段からの個々の検査座標位置に対応し
た各合致パルス出力を個々に同時カウントすることによ
りVS×HS個のパターン照合を1画像走査で完了し個々の
検査座標位置に対応した部分で独立に算出保持する相関
値積算手段と、 前記相関値積算手段の相関値データをマイクロコンピ
ュータより事前に設定されたパターン検出スレッシュ値
との大小を同時に比較判定することで候補点におけるパ
ターン照合状態を高速に検出できるように、前記相関値
積算手段のデータ出力と、保持した検出スレッシュ値と
比較し、個々の検査座標位置に対応した座標位置との間
で大小を同時に比較判定し、その結果を保持する個々の
検査座標位置に対応した保持手段をVS×HS個の個々の検
査座標位置に対応した分だけ設けることとし、マイクロ
コンピュータには1垂直走査ラインVSヵ所の比較結果を
一まとめにしマイクロコンピュータの1回の読み込みで
1垂直走査ラインの各パターン照合位置の状態を把握で
きるように状態を保持した手段を水平方向においてパタ
ーン照合を行うHS本だけ設けることで、各1垂直走査ラ
インの状態を把握しその演算対応位置の特定を行えるよ
うにした垂直候補点検出手段により構成され、 第1回目の粗検出は水平画像データ抽出手段・垂直画
像データ抽出手段ともに第1の画素間隔で被検査画像デ
ータが同時に出力されるよう設定し、被検査画像の検出
範囲の中心位置にVS行×HS列の検査位置の中心部が対応
するように配置して第1回目の粗検出を行ない、前記垂
直候補点検出手段により第1回目の粗検出の後マイクロ
コンピュータより事前に設定された第1回目の粗検出ス
レッシュ値を越える検出位置の候補点が存在するかを調
べ、存在していた場合に存在を示している垂直比較ライ
ンの前記垂直候補点検出手段の情報を読み込み、前記情
報に対応するパターン照合座標位置における相関値を保
持している手段より、第1回目のパターン照合を行った
複数の候補点の相関カウント値の中で最大相関値を保持
する部分に対応したパターン照合座標位置をもって、次
回のパターン照合の中心座標位置と決定し、前記第1回
目の粗検出にて求めた最高相関値の座標位置を中心にVS
行×HS列の検査位置の中心部が対応するように配置し、
第2回目の粗検出を水平方向は{第1の画素間隔−第2
の画素間隔×(HS−1)/2}≦0を、垂直方向は{第1
の画素間隔−第2の画素間隔×(VS−1)/2}≦0を、
満たす第2の画素間隔にてVS行≦HS列の中心部が対応す
るように配置して行い前記垂直候補点検出手段からマイ
クロコンピュータより第1回目の粗検出の後に設定され
た第2回目用の粗検出スレッシュ値より大きくなった第
2回目の複数の候補点の相関データの最高相関値の座標
位置を求め、前記第2回目の粗検出にて求めた最高値位
置座標を中心にVS行×HS列の中心部を配置して第3回目
以降のパターン照合を1画素間隔にて行うまで水平方向
は{第P回目のパターン照合の画素間隔−第P+1回目
のパターン照合の画素間隔×(HS−1)/2}≦0を、垂
直方向は{第P回目のパターン照合の画素間隔−第P+
1回目のパターン照合の画素間隔×(VS−1)/2}≦0
を、満たす第P+1回目のパターン照合の画素間隔にて
VS行×HS列の中心部を配置して行い、前記垂直候補点検
出手段からマイクロコンピュータよりパターン照合を1
画素間隔にて行った第P+1回目用の検出スレッシュ値
より大きくなった第P+1回目の単一あるいは複数の候
補点の相関データの最大値を持つ座標位置を検出位置と
することを特徴とするパターン認識方法により達成され
る。
Still another second solution is a pattern recognition method for automatically extracting a specific pattern from a two-dimensional image, comprising: digitizing a two-dimensional video signal from an imaging means; A reference image pattern storage means capable of outputting image data previously stored in a memory as a cut-out reference image, and capable of holding an arbitrary number of horizontal scanning dy lines of the two-dimensional image data to be inspected by an amount set by the microcomputer (VS-1) horizontal scanning line holding means are set to (1 ≦ k ≦
dy) vertical image data extraction means for simultaneously outputting inspection image data corresponding to individual inspection coordinate positions of VS rows evenly spaced at horizontal scanning line intervals (k pixel intervals); (HS-1) serially connected pixel shift means capable of holding VS simultaneous output of image data from the image data extracting means up to an arbitrary number of pixels dx in the horizontal direction by the number of pixels set by the microcomputer. As a result, image data to be inspected in one horizontal direction are evenly spaced at a set pixel (1 ≦ j ≦ dx) interval (j pixel interval) at the same time.
The image data to be simultaneously output from the HS locations is input to the image data to be inspected simultaneously output from the VS horizontal scanning lines from the vertical extracting means, and the (HS-1) serial pixel shifting means is used. A horizontal image data extracting unit configured to simultaneously output the inspection image data corresponding to the individual inspection coordinate positions of the total VS × HS points of the two-dimensional inspection image data by providing a VS stage; and the reference image storage unit. A pattern corresponding to each inspection coordinate position consisting of VS × HS exclusive ORs for simultaneously comparing patterns of image data from the image data to be inspected corresponding to individual inspection coordinate positions from the horizontal image data extracting means. A logical operation means for outputting a collation output as VS × HS simultaneous coincidence pulses from exclusive OR means corresponding to individual inspection coordinate positions; and By simultaneously counting each matched pulse output corresponding to each inspection coordinate position, VS x HS pattern matching is completed in one image scan, and the correlation is calculated and held independently in the portion corresponding to each inspection coordinate position A value accumulating means, and a pattern matching state at a candidate point can be detected at high speed by simultaneously comparing and judging the correlation value data of the correlation value accumulating means with a pattern detection threshold value set in advance by a microcomputer. Comparing the data output of the correlation value accumulating means with the held detection threshold value, and comparing and judging the magnitudes of the coordinate positions corresponding to the individual inspection coordinate positions at the same time; The holding means corresponding to the position is provided for each of the VS × HS individual inspection coordinate positions, and the microcomputer has one vertical scanning line. A means for keeping the state of each pattern matching position of one vertical scan line by one reading of the microcomputer by combining the comparison results of VS locations is provided only for HS lines that perform pattern matching in the horizontal direction. In this way, the first rough detection is made up of horizontal image data extraction means and vertical image data extraction Both means are set so that image data to be inspected are simultaneously output at the first pixel interval, and are arranged such that the center of the inspection position of VS rows × HS columns corresponds to the center position of the detection range of the image to be inspected. The first coarse detection is performed, and the first coarse detection threshold value preset by the microcomputer after the first coarse detection by the vertical candidate point detecting means. A check is made to see if there is a candidate point at the detection position exceeding, and if so, the information of the vertical candidate point detecting means of the vertical comparison line indicating the existence is read and the correlation at the pattern matching coordinate position corresponding to the information is read. The pattern holding coordinate position corresponding to the part holding the maximum correlation value among the correlation count values of the plurality of candidate points for which the first pattern matching has been performed is determined by the means holding the value. The center coordinate position is determined, and the coordinate position of the highest correlation value obtained in the first coarse detection is set to VS.
Arrange so that the center of the inspection position of row x HS column corresponds,
The second coarse detection is performed in the horizontal direction by {1st pixel interval−2nd pixel interval}.
Pixel interval × (HS-1) / 2} ≦ 0, and the vertical direction is {1st
Pixel interval−second pixel interval × (VS−1) / 2} ≦ 0,
At the second pixel interval to be filled, VS rows ≦ HS columns are arranged so as to correspond to each other, and the second candidate set by the microcomputer from the vertical candidate point detecting means after the first coarse detection by the microcomputer. The coordinate position of the highest correlation value of the correlation data of the plurality of candidate points in the second time that has become larger than the coarse detection threshold value of the second detection is calculated, and the VS line is centered on the highest value position coordinates obtained in the second coarse detection. The horizontal direction is ま で the pixel interval of the Pth pattern matching−the pixel interval of the (P + 1) th pattern matching × ( HS-1) / 2} ≦ 0, and the vertical direction is {Pth pixel interval of pattern matching−P +
Pixel interval of first pattern matching × (VS−1) / 2} ≦ 0
At the pixel interval of the (P + 1) th pattern matching that satisfies
The central part of VS rows × HS columns is arranged and the pattern matching is performed by the microcomputer from the vertical candidate point detecting means.
A pattern characterized in that a coordinate position having a maximum value of correlation data of single or plural candidate points of the (P + 1) th time that is larger than a detection threshold value for the (P + 1) th time performed at a pixel interval is set as a detection position. Achieved by recognition methods.

更に別の解決手段は、2次元画像の中からある特定パ
ターンを自動抽出するパターン認識方法において、 撮像手段からの2次元映像信号をデジタル化し、 被検査画像の特徴的なパターンの任意サイズを切り出
し基準画像として予めメモリに記憶した画像データを出
力可能な基準画像記憶手段と、 2次元被検査画像データの任意数のdy水平走査ライン
をマイクロコンピュータから設定された分だけ保持可能
な(VS−1)個の水平走査ライン保持手段を(1≦k≦
dy)水平走査ライン間隔(k画素間隔)で均等に間を置
いたVS行の個々の検査座標位置に対応した被検査画像デ
ータが同時に出力されるようにした垂直画像データ抽出
手段と、 前記垂直画像データ抽出手段からの被検査画像データ
のVS個の同時出力を水平方向の任意数のdx画素までをマ
イクロコンピュータから設定された画素分だけ保持可能
な画素シフト手段を(HS−1)個直列につなぐことで、
1水平方向の被検査画像データが同時にある設定された
画素j(1≦j≦dx)間隔で均等に間を置いたHSヵ所か
ら同時に出力されるようにしたものを前記垂直抽出手段
からのVS個の水平走査ラインから同時に出力された被検
査画像データを入力として、前記HS個直列の画素シフト
手段をVS段設ける事で2次元被検査画像データの総計VS
×HS地点の個々の検査座標位置に対応した被検査画像デ
ータを同時に出力されるようにした水平画像データ抽出
手段と、 前記基準画像記憶手段からの画像データと前記水平画
像データ抽出手段からの個々の検査座標位置に対応した
被検査画像パターンデータを同時にパターン比較するVS
×HS個の排他的論理和からなる個々の検査座標位置に対
応したパターン照合出力をVS×HS個同時に合致パルスと
して個々の検査座標位置に対応した排他的論理和手段よ
り出力することからなる論理演算手段と、 前記論理演算手段からの個々の検査座標位置に対応し
た各合致パルス出力を個々に同時カウントすることによ
りVS×HS個のパターン照合を1画像走査で完了し個々の
検査座標位置に対応した部分で独立に相関値を算出保持
する相関値積算手段と、 前記相関値積算手段の相関値データをマイクロコンピ
ュータより事前に設定されたパターン検出スレッシュ値
との大小を同時に比較判定することで候補点におけるパ
ターン照合状態を高速に検出できるように、前記相関値
積算手段のデータ出力と、保持した検出スレッシュ値と
比較し、個々の検査座標位置に対応した座標位置との間
で大小を同時に比較判定し、その結果を保持する個々の
検査座標位置に対応した保持手段をVS×HS個の個々の検
査座標位置に対応した分だけ設けることとし、マイクロ
コンピュータには1水平走査ラインHSヵ所の比較結果を
一まとめにしマイクロコンピュータの1回の読み込みで
1水平走査ラインの各パターン照合位置の状態の概略を
高速に把握できるように状態を保持した手段を垂直パタ
ーン照合のVS本だけ設けることで、各1水平走査ライン
の各パターン照合位置の状態の概略を高速に把握しその
演算対応位置の特定を容易に行えるようにした水平候補
点検出手段と、 前記水平候補点検出手段のVS本の水平相関ラインの各
パターン照合位置の状態の概略を高速に把握できるよう
にするためにマイクロコンピュータによる1回のデータ
入力にて把握できるよう前記水平候補点検出手段のVS本
の個々の検査座標位置に対応した各状態保持手段の出力
を個々の検査座標位置に対応した各状態保持手段におい
て前記粗検出スレッシュ値よりも大きかった状態保持が
1つでもあればその水平相関ラインの状態を保持するこ
とでマイクロコンピュータに粗検出スレッシュ値を越え
る前記水平相関ラインがあったことを知らせる候補点検
出手段により構成され、 第1回目の粗検出は水平画像データ抽出手段・垂直画
像データ抽出手段をそれぞれの第1回目のパターン照合
の画素間隔でHS×VS個の被検査画像データが同時に出力
されるよう設定し、被検査画像の検出範囲の中心位置に
HS行×VS列の検査位置の中心部が対応するように配置し
て第1回目の粗検出を行ない、前記候補点検出手段によ
り第1回目の粗検出の後マイクロコンピュータより事前
に設定された第1回目の粗検出スレッシュ値を越える検
出位置の候補点が存在するかを調べ、存在していた場合
に存在を示している水平比較ラインの前記水平候補点検
出手段の情報を読み込み、前記情報に対応するパターン
照合座標位置における相関値を保持している手段より、
第1回目のパターン照合を行った複数の候補点の相関カ
ウント値の中で最大相関値を保持する部分に対応したパ
ターン照合座標位置をもって、次回のパターン照合の中
心座標位置と決定し、前記第1回目の粗検出にて求めた
最高相関値の座標位置を中心にHS行×VS列の検査位置の
中心部が対応するように配置し、第2回目の粗検出を水
平方向は{第1の画素間隔−第2の画素間隔×(HS−
1)/2}≦0を、垂直方向は{第1の画素間隔−第2の
画素間隔×(VS−1)/2}≦0を、満たす第2の画素間
隔にてHS行×VS列の中心部が対応するように配置して行
い前記候補点検出手段からマイクロコンピュータより第
1回目の粗検出の後に設定された第2回目用の粗検出ス
レッシュ値より大きくなった第2回目の複数の候補点の
相関データの最高相関値の座標位置を求め、前記第2回
目の粗検出にて求めた最高値位置座標を中心にHS行×VS
列の中心部を配置して第3回目以降のパターン照合を1
画素間隔にて行うまで水平方向は{第P回目のパターン
照合の画素間隔−第P+1回目のパターン照合の画素間
隔×(HS−1)/2}≦0を、垂直方向は{第P回目のパ
ターン照合の画素間隔−第P+1回目のパターン照合の
画素間隔×(VS−1)/2}≦0を、満たす第P+1回目
のパターン照合の画素間隔にてHS行×VS列の中心部を配
置して行い、前記水平候補点検出手段からマイクロコン
ピュータよりパターン照合を1画素間隔にて行った第P
+1回目用の検出スレッシュ値より大きくなった第P+
1回目の単一あるいは複数の候補点の相関データの最大
値を持つ座標位置を検出位置とすることを特徴とするパ
ターン認識方法により達成される。
Still another solution is a pattern recognition method for automatically extracting a specific pattern from a two-dimensional image, wherein a two-dimensional video signal from an imaging means is digitized, and an arbitrary size of a characteristic pattern of an image to be inspected is cut out. A reference image storage means capable of outputting image data previously stored in a memory as a reference image; and an arbitrary number of dy horizontal scanning lines of the two-dimensional image data to be inspected, which can be held by an amount set by the microcomputer (VS-1 ) Horizontal scanning line holding means (1 ≦ k ≦
dy) vertical image data extraction means for simultaneously outputting inspection image data corresponding to individual inspection coordinate positions of VS rows evenly spaced at horizontal scanning line intervals (k pixel intervals); A series of (HS-1) pixel shift means capable of holding VS simultaneous output of the image data to be inspected from the image data extracting means up to an arbitrary number of dx pixels in the horizontal direction by the number of pixels set by the microcomputer. By connecting to
The image data to be inspected in one horizontal direction is simultaneously output from the HS points evenly spaced at a set pixel j (1 ≦ j ≦ dx) interval at the same time. With the image data to be inspected simultaneously output from the plurality of horizontal scanning lines as inputs, the total number VS of the two-dimensional image data to be inspected can be obtained by providing the HS serial pixel shift means in the VS stage.
A horizontal image data extracting means for simultaneously outputting the inspected image data corresponding to each of the inspection coordinate positions of the × HS point, and image data from the reference image storing means and individual horizontal image data from the horizontal image data extracting means. VS for pattern comparison of inspected image pattern data corresponding to the inspection coordinate position
A logic consisting of outputting pattern matching outputs corresponding to individual inspection coordinate positions consisting of × HS exclusive ORs from the exclusive OR means corresponding to individual inspection coordinate positions as VS × HS simultaneous coincidence pulses The calculating means and the coincidence pulse output corresponding to each inspection coordinate position from the logical operation means are individually and simultaneously counted, whereby VS × HS pattern matching is completed in one image scan, and each inspection coordinate position is obtained. Correlation value integrating means for independently calculating and holding correlation values in corresponding portions, and simultaneously comparing and determining the correlation value data of the correlation value integrating means with a pattern detection threshold value preset by a microcomputer. The data output of the correlation value accumulating means is compared with the stored detection threshold value so that the pattern matching state at the candidate point can be detected at a high speed, and the individual At the same time, the magnitude is compared and determined between the coordinate position corresponding to the inspection coordinate position and the holding means corresponding to each inspection coordinate position holding the result is provided by the amount corresponding to VS × HS individual inspection coordinate positions. The microcomputer is designed to collect the comparison results of one horizontal scanning line HS and collect the comparison results of one horizontal scanning line at a time so that the outline of the state of each pattern matching position of one horizontal scanning line can be quickly grasped by one reading of the microcomputer. By providing only VS means for vertical pattern matching, a horizontal candidate that can quickly grasp the outline of the state of each pattern matching position of each horizontal scanning line and easily specify the position corresponding to the calculation. A point detection means, and a microcontroller for enabling a quick overview of the state of each pattern matching position of the VS horizontal correlation lines of the horizontal candidate point detection means. The output of each state holding means corresponding to each of the VS individual inspection coordinate positions of the horizontal candidate point detection means in each state holding means corresponding to each inspection coordinate position so that the data can be grasped by one data input by the computer. If at least one state is held larger than the coarse detection threshold value, the state of the horizontal correlation line is held to notify the microcomputer that there is a horizontal correlation line exceeding the coarse detection threshold value. In the first coarse detection, the horizontal image data extracting means and the vertical image data extracting means simultaneously output HS × VS inspection image data at the pixel interval of the first pattern matching. To the center of the detection range of the image to be inspected.
The first coarse detection is performed by arranging the inspection positions of the HS rows × VS columns so as to correspond to each other, and is set in advance by the microcomputer after the first coarse detection by the candidate point detecting means. It checks whether there is a candidate point at the detection position exceeding the first coarse detection threshold value, and if so, reads the information of the horizontal candidate point detecting means of the horizontal comparison line indicating the existence, and reads the information. By means of holding the correlation value at the pattern matching coordinate position corresponding to
A pattern coordinate position corresponding to a portion holding the maximum correlation value among the correlation count values of a plurality of candidate points subjected to the first pattern matching is determined as a center coordinate position for the next pattern matching, and The inspection is arranged so that the center of the inspection position of HS rows × VS columns corresponds to the center of the coordinate position of the highest correlation value obtained in the first coarse detection, Pixel interval−second pixel interval × (HS−
1) / 2} ≦ 0, and HS rows × VS columns at a second pixel interval that satisfies {first pixel interval−second pixel interval × (VS−1) / 2} ≦ 0 in the vertical direction. Are arranged so that the central portions thereof correspond to each other, and the candidate point detecting means sets a second plurality of second detection values larger than a second detection threshold value set by the microcomputer after the first detection. The coordinate position of the highest correlation value of the correlation data of the candidate points is determined, and HS rows × VS are centered on the highest value position coordinates obtained in the second coarse detection.
Arrange the center of the column to perform pattern matching for the third and subsequent
In the horizontal direction, the pixel interval of the P-th pattern matching−the pixel interval of the (P + 1) -th pattern matching × (HS−1) / 2} ≦ 0 in the horizontal direction and the {P-th The center of HS rows × VS columns is arranged at the pixel interval of the (P + 1) th pattern matching that satisfies the pixel interval of the pattern matching−the pixel interval of the (P + 1) th pattern matching × (VS−1) / 2} ≦ 0. And the microcomputer performs pattern matching at one pixel interval from the horizontal candidate point detection means.
The (P +) th that has become larger than the detection threshold value for the + 1st time
This is achieved by a pattern recognition method characterized in that a coordinate position having the maximum value of correlation data of single or multiple candidate points for the first time is set as a detection position.

更に別の第4の解決手段は、2次元画像の中からある
特定パターンを自動抽出するパターン認識方法におい
て、 撮像手段からの2次元映像信号をデジタル化し、 被検査画像の特徴的なパターンの任意サイズを切り出
し基準画像パターンとして予めメモリに記憶した画像デ
ータを出力可能な基準画像パターン記憶手段と、 2次元被検査画像データの任意数の水平走査ラインdy
をマイクロコンピュータから設定された分だけ保持可能
な(VS−1)個の水平走査ライン保持手段を(1≦k≦
dy)水平走査ライン間隔(k画素間隔)で均等に間を置
いたVS行の個々の検査座標位置に対応した被検査画像デ
ータが同時に出力されるようにした垂直画像データ抽出
手段と、 前記垂直画像データ抽出手段からの被検査画像データ
のVS個の同時出力を水平方向の任意数のdx画素までをマ
イクロコンピュータから設定された画素分だけ保持可能
な画素シフト手段を(HS−1)個直列につなぐことで、
1水平方向の被検査画像データが同時にある設定された
画素j(1≦j≦dx)間隔(j画素間隔)で均等に間を
置いたHSヵ所から同時に出力されるようにしたものを前
記垂直抽出手段からのVS個の水平走査ラインから同時に
出力された被検査画像データを入力として、前記(HS−
1)直列の画素シフト手段をVS段設ける事で2次元被検
査画像データの総計VS×HS地点の個々の検査座標位置に
対応した被検査画像データを同時に出力されるようにし
た水平画像データ抽出手段と、 前記基準画像記憶手段からの画像データと前記水平画
像データ抽出手段からの個々の検査座標位置に対応した
被検査画像パターンデータを同時にパターン比較するVS
×HS個の排他的論理和からなる個々の検査座標位置に対
応したパターン照合出力をVS×HS個同時に合致パルスと
して個々の検査座標位置に対応した排他的論理和手段よ
り出力することからなる論理演算手段と、 前記論理演算手段からの個々の検査座標位置に対応し
た各合致パルス出力を個々に同時カウントすることによ
りVS×HS個のパターン照合を1画像走査で完了し個々の
検査座標位置に対応した部分で独立に算出保持する相関
値積算手段と、 前記相関値積算手段の相関値データをマイクロコンピ
ュータより事前に設定されたパターン検出スレッシュ値
との大小を同時に比較判定することで候補点におけるパ
ターン照合状態を高速に検出できるように、前記相関値
積算手段のデータ出力と、保持した検出スレッシュ値と
比較し、個々の検査座標位置に対応した座標位置との間
で大小を同時に比較判定し、その結果を保持する個々の
検査座標位置に対応した保持手段をVS×HS個の個々の検
査座標位置に対応した分だけ設けることとし、マイクロ
コンピュータには1垂直走査ラインVSカ所の比較結果を
一まとめにしマイクロコンピュータの1回の読み込みで
1垂直走査ラインの各パターン照合位置の状態の概略を
高速に把握できるように状態を保持した手段を水平方向
においてパターン照合を行うHS本だけ設けることで、各
1垂直走査ラインの状態の概略を高速に把握しその演算
対応位置の特定を容易に行えるようにした垂直候補点検
出手段と、 前記垂直候補点検出手段のHS本の垂直相関ラインの各
パターン照合位置の状態の概略を高速に把握できるよう
にするためにマイクロコンピュータによる1回のデータ
入力にて把握できるよう前記垂直候補点検出手段のHS本
の個々の検査座標位置に対応した各状態保持手段の出力
を個々の検査座標位置に対応した各状態保持手段におい
て前記粗検出スレッシュ値よりも大きかった状態保持が
1つでもあればその垂直相関ラインの状態を保持するこ
とでマイクロコンピュータに粗検出スレッシュ値を越え
る前記垂直相関ラインがあったことを知らせる候補点検
出手段により構成され、 第1回目の粗検出は水平画像データ抽出手段・垂直画
像データ抽出手段をそれぞれの第1回目のパターン照合
の画素間隔でHS×VS個の被検査画像データが同時に出力
されるよう設定し、被検査画像の検出範囲の中心位置に
HS行×VS列の検査位置の中心部が対応するように配置し
て第1回目の粗検出を行ない、前記垂直候補点検出手段
により第1回目の粗検出の後マイクロコンピュータより
事前に設定された第1回目の粗検出スレッシュ値を越え
る検出位置の候補点が存在するかを調べ、存在していた
場合に存在を示している垂直比較ラインの前記垂直候補
点検出手段の情報を読み込み、前記情報に対応するパタ
ーン照合座標位置における相関値を保持している手段よ
り、第1回目のパターン照合を行った複数の候補点の相
関カウント値の中で最大相関値を保持する部分に対応し
たパターン照合座標位置をもって、次回のパターン照合
の中心座標位置と決定し、前記第1回目の粗検出にて求
めた最高相関値の座標位置を中心にHS行×VS列の検査位
置の中心部が対応するように配置し、第2回目の粗検出
を水平方向は{第1の画素間隔−第2の画素間隔×(HS
−1)/2}≦0を、垂直方向は{第1の画素間隔−第2
の画素間隔×(VS−1)/2}≦0を、満たす第2の画素
間隔にてHS行×VS列の中心部が対応するように配置して
行い前記候補点検出手段からマイクロコンピュータより
第1回目の粗検出の後に設定された第2回目用の粗検出
スレッシュ値より大きくなった第2回目の複数の候補点
の相関データの最高相関値の座標位置を求め、前記第2
回目の粗検出にて求めた最高値位置座標を中心にVS行×
HS列の中心部を配置して第3回目以降のパターン照合を
1画素間隔にて行うまで水平方向は{第P回目のパター
ン照合の画素間隔−第P+1回目のパターン照合の画素
間隔×(HS−1)/2}≦0を、垂直方向は{第P回目の
パターン照合の画素間隔−第P+1回目のパターン照合
の画素間隔×(VS−1)/2}≦0を、満たす第P+1回
目のパターン照合の画素間隔にてVS行×HS列の中心部を
配置して行い、前記垂直候補点検出手段からマイクロコ
ンピュータよりパターン照合を1画素間隔にて行った第
P+1回目用の検出スレッシュ値より大きくなった第P
+1回目の単一あるいは複数の候補点の相関データの最
大値を持つ座標位置を検出位置とすることを特徴とする
パターン認識方法により達成される。
Still another fourth solution is a pattern recognition method for automatically extracting a specific pattern from a two-dimensional image, comprising: digitizing a two-dimensional video signal from an imaging device; A reference image pattern storage means capable of outputting image data previously stored in a memory as a cut-out reference image pattern; and an arbitrary number of horizontal scanning lines dy of two-dimensional inspection image data
(VS-1) horizontal scan line holding means (1 ≦ k ≦
dy) vertical image data extraction means for simultaneously outputting inspection image data corresponding to individual inspection coordinate positions of VS rows evenly spaced at horizontal scanning line intervals (k pixel intervals); A series of (HS-1) pixel shift means capable of holding VS simultaneous output of the image data to be inspected from the image data extracting means up to an arbitrary number of dx pixels in the horizontal direction by the number of pixels set by the microcomputer. By connecting to
The image data to be inspected in one horizontal direction are simultaneously output from HS locations evenly spaced at a set pixel j (1 ≦ j ≦ dx) interval (j pixel interval) at the same time. The image data to be inspected simultaneously output from the VS horizontal scanning lines from the extraction means is input to the (HS-
1) Horizontal image data extraction in which the inspection image data corresponding to each inspection coordinate position of the total VS × HS point of the two-dimensional inspection image data is simultaneously output by providing the series pixel shift means in the VS stage. Means for simultaneously comparing the image data from the reference image storage means and the inspected image pattern data corresponding to the individual inspection coordinate positions from the horizontal image data extraction means.
A logic consisting of outputting pattern matching outputs corresponding to individual inspection coordinate positions consisting of × HS exclusive ORs from the exclusive OR means corresponding to individual inspection coordinate positions as VS × HS simultaneous coincidence pulses The calculating means and the coincidence pulse output corresponding to each inspection coordinate position from the logical operation means are individually and simultaneously counted, whereby VS × HS pattern matching is completed in one image scan, and each inspection coordinate position is obtained. Correlation value accumulating means for independently calculating and holding in the corresponding portion, and simultaneously comparing and judging the correlation value data of the correlation value accumulating means with a pattern detection threshold value set in advance by a microcomputer at a candidate point. In order to detect the pattern matching state at a high speed, the data output of the correlation value integrating means is compared with the held detection threshold value, and each inspection coordinate is compared. The size is compared and judged simultaneously with the coordinate position corresponding to the position, and the holding means corresponding to the individual inspection coordinate position to hold the result is provided only for VS × HS individual inspection coordinate positions. The microcomputer collects the comparison results of one vertical scanning line VS location and keeps the state so that the outline of the state of each pattern matching position of one vertical scanning line can be quickly grasped by one reading of the microcomputer. By providing only the HS lines that perform pattern matching in the horizontal direction, the above-mentioned means can be used to quickly grasp the outline of the state of each one vertical scanning line and to easily specify the position corresponding to the operation, and a vertical candidate point detecting means. In order to grasp at a high speed an outline of the state of each pattern matching position of the HS vertical correlation lines of the vertical candidate point detecting means, The outputs of the state holding means corresponding to the individual inspection coordinate positions of the HS lines of the vertical candidate point detection means can be grasped by a single data input. Candidate point detection means for notifying the microcomputer that there is a vertical correlation line exceeding the coarse detection threshold value by holding the state of the vertical correlation line if at least one state is held larger than the coarse detection threshold value. In the first coarse detection, the horizontal image data extraction unit and the vertical image data extraction unit are configured to simultaneously output HS × VS image data to be inspected at the pixel interval of the first pattern matching. To the center of the detection range of the inspection image.
The first coarse detection is performed by arranging the inspection positions of the HS rows × VS columns so as to correspond to each other, and is set in advance by the microcomputer after the first coarse detection by the vertical candidate point detecting means. It checks whether there is a candidate point at the detection position exceeding the first coarse detection threshold value, and reads the information of the vertical candidate point detection means of the vertical comparison line indicating the existence when the existence exists. The means for holding the correlation value at the pattern matching coordinate position corresponding to the information is the pattern corresponding to the part holding the maximum correlation value among the correlation count values of the plurality of candidate points for which the first pattern matching has been performed. The collation coordinate position is determined as the central coordinate position of the next pattern collation, and the center of the inspection position of the HS row x VS column corresponds to the coordinate position of the highest correlation value obtained in the first coarse detection. Do Uni arranged, the horizontal direction of the second round of coarse detection {first pixel interval - the second pixel interval × (HS
-1) / 2} ≦ 0, and the vertical direction is {first pixel interval−second
Pixel spacing × (VS−1) / 2} ≦ 0, and the second pixel spacing is satisfied so that the center of the HS row × VS column corresponds to each other. The coordinate position of the highest correlation value of the correlation data of the second plurality of candidate points that has become larger than the second coarse detection threshold value set after the first coarse detection is obtained.
VS line x centering on the highest position coordinate obtained in the second coarse detection
Until the third and subsequent pattern matchings are performed at one-pixel intervals with the center portion of the HS row being arranged, the horizontal direction is {pixel interval of the P-th pattern matching−pixel interval of the (P + 1) -th pattern matching × (HS -1) / 2} ≦ 0, and in the vertical direction, the (P + 1) th time that satisfies {P-th pixel interval of pattern matching−P + 1-th pixel interval of pattern matching × (VS−1) / 2} ≦ 0. The detection threshold value for the (P + 1) th time, in which the center of VS rows × HS columns is arranged at the pixel interval of the pattern matching, and the pattern matching is performed at one pixel interval by the microcomputer from the vertical candidate point detecting means. No. P which became bigger
This is achieved by a pattern recognition method characterized in that a coordinate position having the maximum value of correlation data of a single or a plurality of candidate points at the (+1) th time is set as a detection position.

更に、上述のの第1の解決手段を持つパターン認識方
法において、第1回目の粗検出は水平画像データ抽出手
段・垂直画像データ抽出手段ともに第1の画素間隔で被
検査画像データが出力されるよう設定し、被検査画像の
検出範囲の中心位置にVS行×HS列の検査位置の中心部が
対応するように配置して第1回目の粗検出を行ない、前
記水平候補点高速検出手段からの出力がマイクロコンピ
ュータより事前に設定された第1回目用の粗検出スレッ
シュ値より大きくなった候補点が見つかった場合、前記
水平候補点検出手段からマイクロコンピュータより事前
に設定された第1回目用の粗検出スレッシュ値より大き
くなった第1回目の単一あるいは複数のパターン照合候
補点の有無を示すXY座標位置データより重心位置を求
め、前記第1回目の粗検出にて求めた重心位置を中心に
第2回目の粗検出を{第1の画素間隔−第2の画素間隔
×(HS−1)/2}≦0を満たす第2の画素間隔にて行い
前記候補点検出手段からマイクロコンピュータより第1
回目の粗検出の後に設定された第2回目用の粗検出スレ
ッシュ値より大きくなった第2回目の単一あるいは複数
の候補点の位置データの重心位置を求め、前記第2回目
の粗検出にて求めた重心位置を中心に第3回目以降のパ
ターン照合を1画素間隔にて行うまで{第P回目のパタ
ーン照合の画素間隔−第P+1回目のパターン照合の画
素間隔×(HS−1)/2}≦0を満たす第P+1回目のパ
ターン照合の画素間隔にて行い、前記候補点検出手段か
らマイクロコンピュータより第2回目の粗検出の後に設
定された第P+1回目用の検出スレッシュ値より大きく
なった第P+1回目の単一あるいは複数の候補点の位置
データの最大値を持って検出位置とすることを特徴とす
るパターン認識方法により達成される。
Further, in the above-described pattern recognition method having the first solving means, in the first coarse detection, the image data to be inspected is output at the first pixel interval in both the horizontal image data extracting means and the vertical image data extracting means. The first coarse detection is performed by arranging such that the center of the inspection position of VS rows × HS columns corresponds to the center position of the detection range of the inspection image, and performs the first coarse detection. When a candidate point whose output is larger than the coarse detection threshold value for the first time preset by the microcomputer is found, the horizontal candidate point detecting means detects the candidate point for the first time by the microcomputer. The position of the center of gravity is determined from the XY coordinate position data indicating the presence or absence of the single or plural pattern matching candidate points that have become larger than the coarse detection threshold value of the first time. The second coarse detection is performed at the second pixel interval that satisfies {first pixel interval−second pixel interval × (HS−1) / 2} ≦ 0 centering on the center of gravity obtained in the above. First from the microcomputer from the candidate point detection means
The position of the center of gravity of the position data of a single or a plurality of candidate points for the second time, which is larger than the second coarse detection threshold value set after the second coarse detection, is determined. Until the third and subsequent pattern matchings are performed at one pixel intervals centering on the position of the center of gravity obtained as described above, {the pixel interval of the Pth pattern matching−the pixel interval of the (P + 1) th pattern matching × (HS−1) / It is performed at the pixel interval of the (P + 1) -th pattern matching that satisfies 2} ≦ 0, and is larger than the (P + 1) -th detection threshold value set after the second coarse detection by the microcomputer from the candidate point detecting means. This is achieved by a pattern recognition method characterized in that the detected position has the maximum value of the position data of the (P + 1) th single or multiple candidate points.

また、上記第2の解決手段を持つパターン認識方法に
おいて、第1回目の粗検出は水平画像データ抽出手段・
垂直画像データ抽出手段ともに第1の画素間隔で被検査
画像データが出力されるよう設定し、被検査画像の検出
範囲の中心位置にHS行×VS列の検査位置の中心部が対応
するように配置して第1回目の粗検出を行ない、前記垂
直候補点高速検出手段からの出力がマイクロコンピュー
タより事前に設定された第1回目用の粗検出スレッシュ
値より大きくなった候補点が見つかった場合、前記垂直
候補点検出手段からマイクロコンピュータより事前に設
定された第1回目用の粗検出スレッシュ値より大きくな
った第1回目の単一あるいは複数のパターン照合候補点
の有無を示すXY座標位置データより重心位置を求め、前
記第1回目の粗検出にて求めた重心位置を中心に第2回
目の粗検出を{第1の画素間隔−第2の画素間隔×(HS
−1)/2}≦0を満たす第2の画素間隔にて行い前記候
補点検出手段からマイクロコンピュータより第1回目の
粗検出の後に設定された第2回目用の粗検出スレッシュ
値より大きくなった第2回目の単一あるいは複数の候補
点の位置データの重心位置を求め、前記第2回目の粗検
出にて求めた重心位置を中心に第3回目以降のパターン
照合を1画素間隔にて行うまで{第P回目のパターン照
合の画素間隔−第P+1回目のパターン照合の画素間隔
×(HS−1)/2}≦0を満たす第P+1回目のパターン
照合の画素間隔にて行い、前記候補点検出手段からマイ
クロコンピュータより第2回目の粗検出の後に設定され
た第P+1回目用の検出スレッシュ値より大きくなった
第P+1回目の単一あるいは複数の候補点の位置データ
の最大値を持って検出位置とすることを特徴とするパタ
ーン認識方法により達成される。
In the above-described pattern recognition method having the second solving means, the first coarse detection is performed by the horizontal image data extracting means.
Both the vertical image data extracting means are set so that the image data to be inspected is output at the first pixel interval, and the center of the inspection position of HS rows × VS columns corresponds to the center position of the detection range of the image to be inspected. When the first coarse detection is performed by arranging, and a candidate point whose output from the vertical candidate point high-speed detecting means is larger than a coarse detection threshold value for the first time preset by a microcomputer is found. XY coordinate position data indicating the presence or absence of a first or a plurality of pattern matching candidate points larger than a first coarse detection threshold value set in advance by the microcomputer from the vertical candidate point detecting means. The position of the center of gravity is further determined, and the second coarse detection is performed based on the position of the center of gravity determined in the first coarse detection, which is {(first pixel interval−second pixel interval × (HS
-1) Performed at a second pixel interval that satisfies / 2} ≦ 0, and becomes larger than the second coarse detection threshold value set after the first coarse detection by the microcomputer from the candidate point detecting means. The second time the center of gravity of the position data of single or multiple candidate points is obtained, and the third and subsequent pattern matchings are performed at one pixel intervals with the center of gravity obtained by the second coarse detection as the center. Until this is done, the pixel interval of the (P + 1) th pattern matching that satisfies {P pixel interval of the Pth pattern matching−pixel interval of the (P + 1) th pattern matching × (HS−1) / 2} ≦ 0 is satisfied. The point detecting means has the maximum value of the position data of the (P + 1) th single or plural candidate points which is larger than the (P + 1) th detection threshold value set after the second coarse detection by the microcomputer. Inspection It is achieved by the pattern recognition method which is characterized in that the position.

ここで第1の解決手段において、dx=32,dy=32,HS=
7,VS=7とし、その検出手段は第1回目の粗検出は水平
画像データ抽出手段・垂直画像データ抽出手段ともに8
画素間隔で被検査画像データが出力されるように設定
し、被検査画像の検出範囲の中心位置に7行7列の検査
位置の中心部が対応するように配置して第1回目の粗検
出を行ない、前記水平候補点高速検出手段からの出力が
マイクロコンピュータより事前に設定された第1回目用
の粗検出スレッシュ値より大きくなった候補点が見つか
った場合、前記水平候補点高速検出手段からマイクロコ
ンピュータより事前に設定された第1回目用の粗検出ス
レッシュ値より大きくなった第1回目の単一あるいは複
数の候補点の位置データの相関値をもとに重心位置を求
め、前記第1回目の粗検出にて求めた重心位置を中心に
第2回目の粗検出を3画素間隔にて行い前記候補点高速
検出手段からマイクロコンピュータより第1回目の粗検
出の後に設定された第2回目用の粗検出スレッシュ値よ
り大きくなった第2回目の単一あるいは複数の候補点の
位置データの重心位置を求め、前記第2回目の粗検出に
て求めた重心位置を中心に第3回目の検出を1画素間隔
にて行い前記候補点高速検出手段からマイクロコンピュ
ータより第2回目の粗検出の後に設定された第3回目用
の粗検出スレッシュ値より大きくなった第3回目の単一
あるいは複数の候補点の位置データの最大値を持って検
出位置とすることを特徴とするパターン認識方法により
達成される。
Here, in the first solution, dx = 32, dy = 32, HS =
7, VS = 7, and the detection means is the first coarse detection of 8 for both the horizontal image data extraction means and the vertical image data extraction means.
The first coarse detection is performed by setting the image data to be inspected so as to be output at pixel intervals, and arranging the central position of the inspection position in 7 rows and 7 columns corresponding to the central position of the detection range of the image to be inspected. When a candidate point whose output from the horizontal candidate point high-speed detection means is larger than a first coarse detection threshold value set in advance by a microcomputer is found, the horizontal candidate point high-speed detection means The position of the center of gravity is determined based on the correlation value of the position data of the single or multiple candidate points of the first time which is larger than the first coarse detection threshold value for the first time set by the microcomputer. The second coarse detection is performed at three pixel intervals centering on the center of gravity determined in the second coarse detection, and is set by the microcomputer from the candidate point high-speed detection means after the first coarse detection. The barycentric position of the position data of the second or single candidate point which has become larger than the second coarse detection threshold value is determined, and the third barycenter position is determined based on the barycentric position obtained in the second coarse detection. The third detection is performed at one pixel interval from the candidate point high-speed detection means and becomes larger than the third coarse detection threshold value set after the second coarse detection by the microcomputer from the microcomputer. Alternatively, this is achieved by a pattern recognition method characterized in that the detected position has the maximum value of the position data of a plurality of candidate points.

加えて被検査画像範囲内に、所定のパターン照合の相
関値に達する座標位置が無いときには、対象の位置検出
を不可とすることを特徴とするパターン認識方法により
達成される。
In addition, the present invention is achieved by a pattern recognition method characterized in that when there is no coordinate position in a range of an image to be inspected that reaches a predetermined pattern matching correlation value, detection of a target position is disabled.

更に別の解決手段は、撮像装置からの2次元映像信号
をデジタル化する2値化回路と、被検査画像の特徴的な
パターンをメモリの記憶容量範囲内の任意サイズとして
切り出し基準画像として予めメモリに記憶した画像デー
タを出力可能な基準画像記憶回路と、 前記2値化回路からの2値化された被検査画像データ
を1水平走査ラインからdx水平走査ラインまでをマイク
ロコンピュータからの指示で任意に設定された分だけ保
持可能な水平走査ライン・シフトレジスタ(VS−1)個
で構成され前記(VS−1)個の水平走査ライン・シフト
レジスタと前記2値化回路とからで2値化画像の垂直方
向に設定されたk水平走査ライン(1≦k≦dx)間隔
(=k画素間隔)で均等に間を置いたVS行の個々の検査
座標位置に対応した被検査画像データが同時に出力され
るようにした垂直画像データ抽出回路と、 前記垂直画像データ抽出回路からの2値化された被検
査画像データのVS個の同時出力を水平方向の1画素から
d画素までをマイクロコンピュータからの指示で任意に
設定された画素分だけ保持可能な可変長画素・シフトレ
ジスタをHS個直列につなぐことで1水平方向の2値化さ
れた被検査画像データが同時にある設定されたj画素
(1≦j≦dy)間隔で均等に開いているHSカ所から同時
に出力されるようにしたものを前記垂直抽出回路からの
VS個の水平走査ラインから同時に出力された2値化被検
査画像データを入力として前記HS個直列の可変長画素・
シフトレジスタをVS段設ける事で前記2値化画像の総計
VSxHS地点の個々の検査座標位置に対応した2値化被検
査画像データを同時に出力されるようにした水平画像デ
ータ抽出回路と、 前記基準画像記憶回路からの基準画像データと前記水
平画像データ抽出回路からの個々の検査座標位置に対応
した被検査画像データを同時にパターン比較するVS×HS
個の排他的論理和回路からなる個々の検査座標位置に対
応したパターン照合出力をVS×HS個同時に合致パルスと
して個々の検査座標位置に対応した排他的論理和部より
出力することからなる論理演算回路と、 前記論理演算回路からの個々の検査座標位置に対応し
た各合致パルス出力を個々に同時カウントすることによ
りVS×HS個のパターン照合を1画像走査期間で完了し個
々の検査座標位置に対応した部分で独立に算出保持する
相関値積算回路を具備し、 第1回目の粗検出は水平画像データ抽出部・垂直画像
データ抽出部ともに第1の画素間隔で被検査画像データ
が同時に出力されるよう設定し、被検査画像の検出範囲
の中心位置にVS行×HS列の検査位置の中心部が対応する
ように配置して第1回目の粗検出を行ない、第1回目の
VS×HS個の候補点の相関データの最高相関値の座標位置
を求め、前記第1回目の粗検出にて求めた最高相関値の
座標位置を中心に第2回目の粗検出を水平方向は{第1
の画素間隔−第2の画素間隔×(HS−1)/2}≦0を、
垂直方向は{第1の画素間隔−第2の画素間隔×(VS−
1)/2}≦0を、満たし最小の整数値となる第2の画素
間隔にて行い第2回目のVS×HS個の候補点の相関データ
の最高相関値の座標位置を求め、前記第2回目の粗検出
にて求めた最高相関値を持つ位置座標を中心に第3回目
以降のパターン照合を水平・垂直方向の設定画素間隔が
1画素間隔となるまで水平方向は{第P回目のパターン
照合の画素間隔−第P+1回目のパターン照合の画素間
隔×(HS−1)/2}≦0を、垂直方向は{第P回目のパ
ターン照合の画素間隔−第P+1回目のパターン照合の
画素間隔×(VS−1)/2}≦0を、満たし最小の整数値
となる第P+1回目のパターン照合の画素間隔にて行
い、1画素間隔にて行なったパターン照合のHS×VS個の
候補点の相関データの最大値が所定の検出スレッシュ値
よりも大きい値であれば前記最大相関値を保持した部分
に対応した座標位置を検出位置とすることを特徴とする
パターン認識装置により達成される。
Still another solution is to provide a binarization circuit for digitizing a two-dimensional video signal from the imaging device, and a memory in which a characteristic pattern of an image to be inspected is cut out as an arbitrary size within a storage capacity range of the memory and a reference image is previously stored A reference image storage circuit capable of outputting the image data stored in the storage unit; and optionally converting the binarized inspection image data from the binarization circuit from one horizontal scanning line to a dx horizontal scanning line according to an instruction from the microcomputer. VS-1 horizontal scanning line shift registers (VS-1) capable of holding only the amount set in (1), and binarized by the (VS-1) horizontal scanning line shift registers and the binarizing circuit. Inspection image data corresponding to individual inspection coordinate positions of VS rows evenly spaced at k horizontal scanning lines (1 ≦ k ≦ dx) intervals (= k pixel intervals) set in the vertical direction of the image are simultaneously displayed. A vertical image data extraction circuit that is to be output; and VS simultaneous outputs of the binarized image data to be inspected from the vertical image data extraction circuit, which are output from one pixel to d pixels in the horizontal direction from a microcomputer. By connecting HS variable-length pixels and shift registers that can hold the pixels arbitrarily set by the instruction of 直列 in series, the set j pixel (1) in which binary image data to be inspected in one horizontal direction is simultaneously present 1 ≦ j ≦ dy) are simultaneously output from the HS locations evenly opened at intervals, and
The binary serial inspection image data output simultaneously from the VS horizontal scanning lines is input to the HS serial variable length pixels.
By providing a shift register in the VS stage, the total of the binary image can be calculated.
A horizontal image data extraction circuit configured to simultaneously output binarized image data to be inspected corresponding to each inspection coordinate position of a VSxHS point; reference image data from the reference image storage circuit; and the horizontal image data extraction circuit VS × HS for pattern comparison of inspected image data corresponding to each inspection coordinate position from
A logical operation consisting of outputting pattern matching outputs corresponding to individual inspection coordinate positions composed of exclusive OR circuits as VS × HS coincident pulses from the exclusive OR unit corresponding to individual inspection coordinate positions at the same time The circuit and the coincidence pulse output corresponding to each inspection coordinate position from the logical operation circuit are individually and simultaneously counted, whereby VS × HS pattern matching is completed in one image scanning period and each inspection coordinate position is obtained. Correlation value accumulating circuits that calculate and hold the corresponding parts independently are provided. In the first coarse detection, the image data to be inspected is simultaneously output at the first pixel interval in both the horizontal image data extraction unit and the vertical image data extraction unit. The first coarse detection is performed by arranging such that the center of the inspection position of VS row × HS column corresponds to the center position of the detection range of the inspection image, and the first coarse detection is performed.
The coordinate position of the highest correlation value of the correlation data of the VS × HS candidate points is obtained, and the second coarse detection is performed in the horizontal direction around the coordinate position of the highest correlation value obtained in the first coarse detection. {First
Pixel interval−second pixel interval × (HS−1) / 2} ≦ 0,
The vertical direction is {first pixel interval−second pixel interval × (VS−
1) / 2} ≦ 0 at the second pixel interval that satisfies the minimum integer value, and obtains the coordinate position of the highest correlation value of the correlation data of the second VS × HS candidate points, The third and subsequent pattern collations are performed in the horizontal direction until the set pixel interval in the horizontal and vertical directions becomes one pixel interval with the position coordinate having the highest correlation value obtained in the second coarse detection as the center. The pixel interval of the pattern matching−the pixel interval of the (P + 1) th pattern matching × (HS−1) / 2} ≦ 0, and the vertical direction is {the pixel interval of the Pth pattern matching—the pixel of the (P + 1) th pattern matching The interval × (VS−1) / 2} ≦ 0 is satisfied at the pixel interval of the (P + 1) th pattern matching that satisfies the minimum integer value, and HS × VS candidates for pattern matching performed at one pixel interval If the maximum value of the correlation data at the point is a value larger than a predetermined detection threshold value, It is achieved by a pattern recognition device which is characterized in that the detected position coordinate position corresponding to the holding portion a large correlation value.

一方、2次元画像の中からある特定パターンを自動抽
出するパターン認識装置において、 撮像装置からの2次元映像信号をデジタル化する2値
化回路と、 被検査画像の特徴的なパターンをメモリの記憶容量範
囲内の任意サイズとして切り出し基準画像として予め記
憶し任意の2次元座標位置に記憶した画像データを出力
可能な基準画像記憶回路と、 前記2値化回路からの2値化された被検査画像データ
を1水平走査ラインからdx水平走査ラインまでをマイク
ロコンピュータからの指示で任意に設定された分だけ保
持可能な水平走査ライン・シフトレジスタ(VS−1)個
で構成され前記(VS−1)個の水平走査ライン・シフト
レジスタと前記2値化回路とからで2値化画像の垂直方
向に設定されたk水平走査ライン(1≦k≦dx)間隔
(=k画素間隔)で均等に開いているVS行の個々の検査
座標位置に対応した被検査画像データが同時に出力され
るようにした垂直画像データ抽出回路と、 前記垂直画像データ抽出回路からの2値化された被検
査画像データのVS個の同時出力を水平方向の1画素から
d画素までをマイクロコンピュータからの指示で任意に
設定された画素分だけ保持可能な可変長画素・シフトレ
ジスタをHS個直列につなぐことで1水平方向の2値化さ
れた被検査画像データが同時にある設定された画素(1
≦j≦dy)間隔(j画素間隔)で均等に間を置いたHSカ
所から同時に出力されるようにしたものを前記垂直抽出
回路からのVS個の水平走査ラインから同時に出力された
2値化被検査画像データを入力として前記HS個直列の可
変長画素・シフトレジスタをVS段設ける事で前記2値化
画像の総計VSxHS地点の個々の検査座標位置に対応した
2値化被検査画像データを同時に出力されるようにした
水平画像データ抽出回路と、 前記基準画像記憶回路からの画像データと前記水平画
像データ抽出回路からの個々の検査座標位置に対応した
被検査画像パターンデータを同時にパターン比較するVS
×HS個の排他的論理和回路からなる個々の検査座標位置
に対応したパターン照合出力をVS×HS個同時に合致パル
スとして個々の検査座標位置に対応した排他的論理和部
より出力することからなる論理演算回路と、 前記論理演算回路からの個々の検査座標位置に対応し
た各合致パルス出力を個々に同時カウントすることによ
りVS×HS個のパターン照合を1フィールドで完了し個々
の検査座標位置に対応した部分で独立に算出保持する相
関値積算回路と、 前記相関値積算回路の相関値データをマイクロコンピ
ュータより事前に設定されたパターン検出スレッシュ値
との大小を同時に比較判定することで候補点におけるパ
ターン照合状態を高速に検出できるように前記相関値積
算回路の出力を個々の検査座標位置に対応したコンパレ
ータを設け検出スレッシュ値を保持し個々の検査座標位
置に対応したラッチとの間で大小を同時に比較判定しそ
の結果を保持する個々の検査座標位置に対応したラッチ
をVSxHS個の個々の検査座標位置に対応した分だけ設け
ることとしマイクロコンピュータには1水平走査ライン
HSカ所の比較結果を一まとめにしマイクロコンピュータ
の1回の読み込みで1水平走査ラインの各パターン照合
位置の状態を把握できるようにしたラッチ部を垂直パタ
ーン照合のVS本だけ設けることで各1水平走査ラインの
各パターン照合位置の状態を把握しその演算対応位置の
特定を行えるようにした水平候補点検出回路と、 前記水平候補点検出回路のVS本の水平走査ラインの各
パターン照合位置の状態を把握できるようにするために
マイクロコンピュータによる1回のデータ入力にて把握
できるよう前記水平候補点検出回路のVS本の個々の検査
座標位置に対応した各ラッチ部の出力を個々の検査座標
位置に対応した各ラッチ部においてスレッシュ値よりも
大きかったラッチが1つでもあればその水平走査ライン
の状態を保持することでマイクロコンピュータに相関ス
レッシュ値を越える水平相関ラインがあったことを知ら
せる候補点検出回路を具備し、 第1回目の粗検出は水平画像データ抽出部・垂直画像
データ抽出部ともに第1の画素間隔で被検査画像データ
が同時に出力されるよう設定し、被検査画像の検出範囲
の中心位置にVS行×HS列の検査位置の中心部が対応する
ように配置して第1回目の粗検出を行ない、前記候補点
検出回路からの出力がマイクロコンピュータより事前に
設定された第1回目用の粗検出スレッシュ値より大きく
なった候補点が見つかった場合、前記水平候補点検出回
路からマイクロコンピュータより事前に設定された第1
回目用の粗検出スレッシュ値より大きくなった第1回目
の複数の候補点の相関データの最高相関値の座標位置を
求め、前記第1回目の粗検出にて求めた最高相関値の座
標位置を中心に第2回目の粗検出を水平方向は{第1の
画素間隔−第2の画素間隔×(HS−1)/2}≦0を、垂
直方向は{第1の画素間隔−第2の画素間隔×(VS−
1)/2}≦0を、満たす第2の画素間隔にて行い前記候
補点検出回路からマイクロコンピュータより第1回目の
粗検出の後に設定された第2回目用の粗検出スレッシュ
値より大きくなった第2回目の複数の候補点の相関デー
タの最高相関値の座標位置を求め、前記第2回目の粗検
出にて求めた最高値位置座標を中心に第3回目以降のパ
ターン照合を1画素間隔にて行うまで水平方向は{第P
回目のパターン照合の画素間隔−第P+1回目のパター
ン照合の画素間隔×(HS−1)/2}≦0を、垂直方向は
{第P回目のパターン照合の画素間隔−第P+1回目の
パターン照合の画素間隔×(VS−1)/2}≦0を、満た
す第P+1回目のパターン照合の画素間隔にて行い、前
記水平候補点検出回路からマイクロコンピュータよりパ
ターン照合を1画素間隔にて行ったされた第P+1回目
用の検出スレッシュ値より大きくなった第P+1回目の
単一あるいは複数の候補点の相関データの最大値を持つ
座標位置を検出位置とすることを特徴とするパターン認
識装置により達成される。
On the other hand, in a pattern recognition device for automatically extracting a specific pattern from a two-dimensional image, a binarizing circuit for digitizing a two-dimensional video signal from an imaging device, and storing a characteristic pattern of an image to be inspected in a memory. A reference image storage circuit capable of outputting image data stored in an arbitrary two-dimensional coordinate position in advance as a clipped reference image as an arbitrary size within a capacity range, and a binarized inspection image from the binarization circuit It is composed of horizontal scanning line shift registers (VS-1) capable of holding data from one horizontal scanning line to dx horizontal scanning lines arbitrarily set by an instruction from the microcomputer. K horizontal scanning lines (1 ≦ k ≦ dx) intervals (= k pixels) set in the vertical direction of the binarized image by the horizontal scanning line shift registers and the binarizing circuit. A vertical image data extraction circuit configured to simultaneously output inspection image data corresponding to individual inspection coordinate positions of a VS row that is evenly opened at intervals, and a binarized image from the vertical image data extraction circuit. HS variable-length pixels and shift registers that can hold the VS simultaneous output of the inspected image data from 1 pixel to d pixel in the horizontal direction by the number of pixels set arbitrarily by the instruction from the microcomputer are connected in series. By connecting the pixels, the image data to be inspected which has been binarized in one horizontal direction is simultaneously set at a certain pixel (1
.Ltoreq.j.ltoreq.dy, which are simultaneously output from HS locations evenly spaced at intervals (j pixel intervals), and are binarized simultaneously output from VS horizontal scanning lines from the vertical extraction circuit. By providing the VS stages of the HS serial variable length pixels and shift registers with the image data to be inspected as input, the binarized image data to be inspected corresponding to each inspection coordinate position of the total VSxHS point of the binarized image can be obtained. A horizontal image data extraction circuit that is simultaneously output; and image data from the reference image storage circuit and pattern image data to be inspected corresponding to each inspection coordinate position from the horizontal image data extraction circuit are simultaneously subjected to pattern comparison. VS
The pattern matching output corresponding to each inspection coordinate position consisting of × HS exclusive OR circuits is simultaneously output as VS × HS matching pulses from the exclusive OR unit corresponding to each inspection coordinate position. A logic operation circuit, VS × HS pattern matching is completed in one field by simultaneously counting each coincidence pulse output corresponding to each inspection coordinate position from the logical operation circuit, and the individual inspection coordinate positions are obtained. Correlation value integration circuits that independently calculate and hold in the corresponding portions, and simultaneously compare and determine the correlation value data of the correlation value integration circuit with a pattern detection threshold value set in advance by a microcomputer at candidate points. The output of the correlation value integrating circuit is provided with a comparator corresponding to each inspection coordinate position so that a pattern matching state can be detected at high speed. The latches corresponding to the individual inspection coordinate positions that hold and hold the results are compared and judged simultaneously with the latches corresponding to the individual inspection coordinate positions, and the results are retained. One horizontal scanning line is provided for the microcomputer.
By providing only VS latches for vertical pattern collation, the comparison results of HS locations are combined and the state of each pattern collation position of one horizontal scan line can be grasped by one reading of the microcomputer. A horizontal candidate point detection circuit capable of grasping the state of each pattern matching position of the scanning line and specifying the position corresponding to the operation, and the state of each pattern matching position of VS horizontal scanning lines of the horizontal candidate point detection circuit The output of each latch unit corresponding to each of the VS individual inspection coordinate positions of the horizontal candidate point detection circuit is converted into individual inspection coordinate positions so that the data can be ascertained by a single data input by the microcomputer in order to be able to ascertain. If there is at least one latch that is larger than the threshold value in each latch unit corresponding to the A candidate point detection circuit that informs the computer that there is a horizontal correlation line exceeding the correlation threshold value. The first coarse detection is performed at the first pixel interval for both the horizontal image data extraction unit and the vertical image data extraction unit. The first coarse detection is performed by setting the image data to be inspected to be output simultaneously and arranging the central position of the inspection position of VS rows × HS columns to correspond to the center position of the detection range of the image to be inspected. If a candidate point whose output from the candidate point detection circuit is larger than the first coarse detection threshold value set in advance by the microcomputer is found, the horizontal candidate point detection circuit sends the candidate point in advance by the microcomputer. First set
The coordinate position of the highest correlation value of the correlation data of the first plurality of candidate points that has become larger than the coarse detection threshold value for the first time is obtained, and the coordinate position of the highest correlation value obtained in the first coarse detection is obtained. At the center, the second coarse detection is {first pixel interval−second pixel interval × (HS−1) / 2} ≦ 0 in the horizontal direction, and {first pixel interval−second Pixel interval × (VS−
1) / 2} ≦ 0 is satisfied at the second pixel interval that satisfies the condition. The candidate point detection circuit makes the microcomputer larger than the second coarse detection threshold value set after the first coarse detection by the microcomputer. The coordinate position of the highest correlation value of the correlation data of the plurality of candidate points in the second time is calculated, and the pattern matching in the third time and thereafter is performed by one pixel with the highest value position coordinate obtained in the second coarse detection as the center. Until performed at intervals, the horizontal direction is
Pixel interval of the first pattern collation−pixel interval of the (P + 1) th pattern collation × (HS−1) / 2} ≦ 0, and in the vertical direction, {pixel interval of the Pth pattern collation−P + 1th pattern collation Pixel spacing × (VS-1) / 2} ≦ 0 is satisfied at the pixel interval of the (P + 1) th pattern matching that satisfies the condition, and pattern matching is performed at one pixel interval by the microcomputer from the horizontal candidate point detection circuit. The coordinate position having the maximum value of the correlation data of the (P + 1) th single or plural candidate points, which is larger than the detected threshold value for the (P + 1) th time, is set as the detection position. Is done.

作用 本発明によれば、被検査画像における画像のパターン
形状が単調で同じ様なパターンが繰り返し続くような場
合でも撮像装置からの2次元被検査画像データは連続し
たシリアルデータとして出力されていることを利用して
いるため、2次元画像の基準画像エリアを大きく取らな
ければ位置検出による位置の特定が困難であるため多量
の画素を同時に処理しなければある座標位置における相
関値が算出されない場合も、1座標位置に注目すればそ
の位置における相関値は基準となるシリアルデータ(=
基準画像データ)とともに比較されるシリアルデータ
(=被検査画像データ)を1走査期間内に同時に出力さ
せ、それぞれの対応する位置の被検査画像データを映像
信号の走査期間の同期させて1画素ずつ相関演算処理す
ることで、2次元エリアデータであっても時間的にシリ
アルデータとして処理を行い、2次元データの相関演算
を1次元相関演算による処理のごとくそれぞれの座標位
置における相関値の算出の簡素化を計っているのであ
る。すなわち、各座標位置における相関値を1画素クロ
ック期間内に完了させるのではなく、1走査期間内にシ
リアルデータとして演算しその結果をシリアルデータと
して積算する部分を水平垂直方向に多数設けることで多
数の座標位置における相関処理を同時に行なうというも
のである。そのため、基準画像のサイズの大小は処理手
段の物理的な規模には影響しないので原画像を圧縮ある
いは限定することで基準となる画像データ量を比較処理
時に減らし処理する必要がなく基準画像のサイズを大き
く出来るために、単純で特徴的なパターン形状の登録が
困難な場合でも原画像の画像データをそのまま処理する
ことにより登録にともなうノウハウの蓄積なくパターン
の位置検出が可能となる。
According to the present invention, even when the pattern shape of the image in the image to be inspected is monotonous and a similar pattern repeats continuously, the two-dimensional image data to be inspected from the imaging device is output as continuous serial data. Since it is difficult to specify a position by position detection unless a large reference image area of a two-dimensional image is taken, a correlation value at a certain coordinate position may not be calculated unless a large number of pixels are simultaneously processed. Paying attention to one coordinate position, the correlation value at that position is the serial data (=
The serial data (= inspection image data) to be compared with the reference image data) is output simultaneously within one scanning period, and the inspection image data at each corresponding position is synchronized with the video signal scanning period one pixel at a time. By performing the correlation calculation processing, even if it is two-dimensional area data, it is processed as serial data in time, and the correlation calculation of the two-dimensional data is performed by calculating the correlation value at each coordinate position like the processing by one-dimensional correlation calculation. We are simplifying it. That is, instead of completing the correlation value at each coordinate position within one pixel clock period, a large number of portions are calculated in the horizontal and vertical directions to calculate serial data within one scanning period and integrate the result as serial data. At the same time. For this reason, since the size of the reference image does not affect the physical scale of the processing means, it is not necessary to reduce the amount of reference image data during the comparison process by compressing or limiting the original image, and it is not necessary to perform the process. Therefore, even when it is difficult to register a simple and characteristic pattern shape, the position of the pattern can be detected by processing the image data of the original image as it is without accumulating know-how associated with the registration.

実施例 以下、本発明に係るパターン認識装置の実施例につい
て図面を参照しながら説明する。第1図はパターン認識
装置のブロック回路を示すブロック図である。図示する
ように、パターン認識装置は撮像装置11からの映像信号
をデジタル化する2値化回路12と、2値化回路12からの
2値化被検査画像を予め記憶させた特徴的なパターンの
基準画像とパターン照合するための基準画像記憶回路16
と、2値化被検査画像データを水平方向の1行から16行
までをマイクロコンピュータ13からの指示で任意に設定
された分だけ保持可能な可変長水平走査ライン・シフト
レジスタを有し2値化回路12とで2値化画像の垂直方向
にある設定された間隔で均等に間を置いた7行の被検査
画像データが同時に出力されるようにした垂直画像デー
タ抽出回路14と、2値化被検査画像データを水平方向の
1画素から16画素までをマイクロコンピュータ13からの
指示で任意に設定された分だけ保持可能な可変長画素・
シフトレジスタを6個直列につなぐことで1水平方向の
2値化画像が同時にある設定された間隔で均等に間を置
いた7カ所から出力されるようにして垂直画像データ抽
出回路14からの7行出力の2値化被検査画像データをつ
なぎ2値化画像の49(7×7)の地点のデータを同時出
力得するようにした水平画像データ抽出回路15と、基準
画像記憶回路16からの画像データと水平画像データ抽出
回路15からの被検査画像データをパターン比較する49個
の排他的論理和手段のパターン照合出力と画素周波数の
クロックパルスを論理積しパターン照合の結果パターン
が合致していれば合致していることを各画素それぞれに
対応したパルスを発生することで検知し画素周波数の合
致パルスを出力することからなる論理演算回路17と、 論理演算回路17からの各合致パルス出力を個々にカウ
ントすることにより49個それぞれのパターン照合を行な
って各座標位置での相関値を個々に積算保持する相関値
積算回路18とにより構成される。
Embodiment Hereinafter, an embodiment of a pattern recognition device according to the present invention will be described with reference to the drawings. FIG. 1 is a block diagram showing a block circuit of the pattern recognition device. As shown in the figure, a pattern recognition device includes a binarization circuit 12 for digitizing a video signal from an imaging device 11, and a binarized inspection image from the binarization circuit 12 for storing a characteristic pattern stored in advance. Reference image storage circuit 16 for pattern matching with reference image
And a variable-length horizontal scanning line shift register capable of holding the binarized image data to be inspected from 1 to 16 lines in the horizontal direction arbitrarily set by an instruction from the microcomputer 13. A vertical image data extraction circuit 14 for simultaneously outputting seven lines of inspected image data evenly spaced at a set interval in the vertical direction of the binarized image with the binarization circuit 12; Variable-length pixels capable of holding the image data to be inspected from 1 pixel to 16 pixels in the horizontal direction by an amount set arbitrarily by an instruction from the microcomputer 13.
By connecting six shift registers in series, the binary image in one horizontal direction is simultaneously output from seven places evenly spaced at a set interval so that the output from the vertical image data extraction circuit 14 is A horizontal image data extraction circuit 15 which connects the binarized image data to be inspected in a row output and simultaneously outputs data at 49 (7 × 7) points of the binarized image, and an image from a reference image storage circuit 16 The pattern matching output of the 49 exclusive OR means for comparing the pattern of the data with the image data to be inspected from the horizontal image data extraction circuit 15 is ANDed with the clock pulse of the pixel frequency. A logic operation circuit 17 that detects the match by generating a pulse corresponding to each pixel and outputs a match pulse of the pixel frequency. It comprises a correlation value accumulating circuit 18 which counts 49 individual pulse outputs, performs pattern matching for each of 49 patterns, and individually accumulates and holds correlation values at each coordinate position.

次に、各構成回路部についてその動作を詳しく説明す
る。実際の設計例では撮像装置11の視野を横320画素,
縦240画素の格子状に量子化するものとし、基準画像の
大きさを128×128画素以内の任意の長方形範囲が可能な
ものとする。基準画像記憶回路16の構成は動作開始およ
び完了のタイミングを発生させるカウンタを水平・垂直
方向それぞれの計4つのカウンタを設け、基準画像の読
み出しあるいは書き込み用タイミング信号を作り、読み
出しタイミング信号により基準画像の読み出しあるいは
書き込みを有効とする期間に画素に対応したクロックを
カウントするカウンタを動作させ記憶回路内の画像デー
タを入出力させるものである。これにより、基準画像記
憶回路16の動作開始および完了のタイミング信号の発生
をそれぞれ行なうカウンタへの設定値を変えることによ
って基準画像のパターンサイズを任意に変更させること
が可能となる。
Next, the operation of each constituent circuit unit will be described in detail. In the actual design example, the field of view of the imaging device 11 is 320 pixels wide,
It is assumed that quantization is performed in a grid of 240 pixels vertically, and that the size of the reference image can be any rectangular range within 128 × 128 pixels. The configuration of the reference image storage circuit 16 is such that a counter for generating operation start and completion timings is provided with a total of four counters in each of the horizontal and vertical directions, and a timing signal for reading or writing the reference image is generated. During the period in which reading or writing of data is valid, a counter that counts a clock corresponding to a pixel is operated to input and output image data in the storage circuit. This makes it possible to arbitrarily change the pattern size of the reference image by changing the set values to the counters that respectively generate the timing signals for starting and completing the operation of the reference image storage circuit 16.

本実施例においては、基準画像の大きさを128×128画
素以内の長方形範囲としたが、メモリの記憶容量が許す
範囲内であれば、より大きな基準画像をもってパターン
照合を行うことも可能であるのはもちろんであり、任意
に設計できる。しかも、記憶容量の大きなメモリさえ用
いれば、回路規模は増すことなく一つの基準画像当りの
登録可能サイズを変更することも可能であるし、メモリ
を多数用いるような設計を行ったとしても回路規模の増
加は大幅に増すものではない。
In this embodiment, the size of the reference image is set to a rectangular range of 128 × 128 pixels or less. However, if the storage capacity of the memory is within the range allowed, pattern matching can be performed using a larger reference image. Of course, it can be designed arbitrarily. Moreover, if a memory having a large storage capacity is used, the registrable size per one reference image can be changed without increasing the circuit scale. The increase does not increase significantly.

基準画像記憶回路16のメモリを256kbit等の1画素1
アドレスとなるRAMを使用した場合、パターン照合を行
なう長方形範囲の大きさは1画素単位でパターンの水平
・垂直方向サイズを設定することが出来る。更に、1パ
ターン当りの記憶容量を16kbitとしているので、基準画
像のパターン設定は128×128画素以内のパターン範囲と
してではなく、1パターン当りの記憶容量の16kbit容量
以内としての使用が可能である。例えば、200×80画素
や、100×150画素のパターン範囲など、水平・垂直方向
のいずれかが128画素の長さを越えるような長方形の基
準画像記憶容量が許す範囲内で必要に応じて可能であ
る。
The memory of the reference image storage circuit 16 is one pixel of 256 kbit etc.
When a RAM serving as an address is used, the horizontal and vertical sizes of the pattern can be set in units of one pixel for the size of the rectangular range for pattern matching. Furthermore, since the storage capacity per pattern is 16 kbits, the pattern setting of the reference image can be used not as a pattern range of 128 × 128 pixels but as a storage capacity of 16 kbits per pattern. For example, a pattern area of 200 x 80 pixels or 100 x 150 pixels, as required, as long as the reference image storage capacity of a rectangle that allows either the horizontal or vertical direction to exceed the length of 128 pixels is allowed It is.

基準画像記憶回路16のメモリを1画素1アドレスでは
ない×4bitや×8bitのRAMにより構成した場合、例え
ば、32k×8bitのRAMとすると8画素の並列入出力とな
り、水平方向のパターン設定は8画素単位となる。水平
・垂直方向のいずれかが128画素の長さを越えるような
長方形の基準画像の設定も必要に応じて可能であるのは
256k×1bit等の1画素1アドレスとなるRAMを用いて設
計して場合と同様である。
When the memory of the reference image storage circuit 16 is constituted by a × 4 bit or × 8 bit RAM which is not one address per pixel, for example, if a 32k × 8 bit RAM is used, 8 pixels are parallel input / output, and the horizontal pattern setting is 8 bits. It is a pixel unit. It is also possible to set a rectangular reference image so that either the horizontal or vertical direction exceeds the length of 128 pixels if necessary
This is the same as the case where the design is performed using a RAM having one address per pixel such as 256 k × 1 bit.

また、基準画像記憶回路16の動作開始および完了のタ
イミング信号の発生をそれぞれ行なうカウンタへの設定
値を変えることによって基準画像のパターン発生を任意
の座標位置に移動させることが可能となる。これは、パ
ターンを記憶した座標位置を水平方向の100画素目から2
00画素目までとすると、開始カウンタ=100,完了カウン
タ=200を設定し画像データをメモリに書き込めばよ
い。そして、開始カウンタ値と完了カウンタ値の差をそ
のままにして設定する値を変更し読み出してやればよ
い。すなわち、開始カウンタ=50、完了カウンタ=150
を設定すれば水平方向の左側に50画素ずれた位置に画像
データが出力され、開始カウンタ=160、完了カウンタ
=260を設定すれば水平方向の右側に60画素ずれた位置
に基準画像データが出力され任意の座標位置に記憶した
基準画像データが出力される。これにより、被検査画像
データの入力はリアルタイムな入力とすることができ、
このリアルタイム入力に基準画像データの出力タイミン
グの方を合わせてパターン照合を行うものである。以上
のように、基準画像のパターン発生を任意の座標位置に
移動させる機能は、被検査画像の任意の検査画像範囲に
おいてパターン照合を行うという目的を達成するために
使用されるものである。
Further, it is possible to move the generation of the pattern of the reference image to an arbitrary coordinate position by changing the set value in the counter for generating the timing signals for starting and completing the operation of the reference image storage circuit 16, respectively. This means that the coordinate position where the pattern is stored is 2 pixels from the 100th pixel in the horizontal direction.
If it is up to the 00th pixel, the start counter = 100 and the completion counter = 200 may be set and the image data may be written to the memory. Then, the value to be set may be changed and read out while the difference between the start counter value and the completion counter value remains unchanged. That is, start counter = 50, completion counter = 150
If set to, the image data is output at the position shifted by 50 pixels to the left in the horizontal direction. If the start counter is set to 160 and the completion counter is set to 260, the reference image data is output to the position shifted by 60 pixels to the right in the horizontal direction. Then, the reference image data stored at an arbitrary coordinate position is output. Thereby, the input of the inspection image data can be a real-time input,
The pattern matching is performed by matching the output timing of the reference image data with the real-time input. As described above, the function of moving the pattern generation of the reference image to an arbitrary coordinate position is used to achieve the purpose of performing pattern matching in an arbitrary inspection image range of the inspection image.

次に、本発明に係る別の実施例について図面を参照し
ながら説明する。第2図は本発明の第2の実施例として
のパターン認識装置のブロック回路を示すブロック図で
ある。このブロック図は第1図のように、撮像装置11か
らの映像信号をデジタル化する2値化回路12と、2値化
回路12からの2値化画像の特徴的なパターンを基準画像
として予め記憶し被検査画像とパターン照合するための
基準画像記憶回路16と、2値化回路12からの2値化被検
査画像データを水平方向の1行から16行までをマイクロ
コンピュータ13からの指示で任意に設定された分だけ保
持可能な可変長水平走査ライン・シフトレジスタ6個で
構成され6個の可変長水平走査ライン・シフトレジスタ
20と2値化回路12とで2値化画像の垂直方向にある設定
された間隔で均等に間を置いた7行の被検査画像データ
が同時に出力されるようにした垂直画像データ抽出回路
14と、2値化回路12からの2値化被検査画像データを水
平方向の1画素から16画素までをマイクロィンピュータ
13からの指示で任意に設定された分だけ保持可能な可変
長画素シフトレジスタを6個直列につなぐことで1水平
方向の2値化画像が同時にある設定された間隔で均等に
間を置いた7カ所から出力されるようにしたものを垂直
画像データ抽出回路14からの行出力の2値化被検査画像
データをつなぐために7段設ける事で前記2値化画像の
総計7×7(=49)地点の2値化被検査画像データを同
時に出力されるようにした水平画像データ抽出回路15
と、基準画像記憶回路16からの画像データと水平画像デ
ータ抽出回路15からの被検査画像パターンデータをパタ
ーン比較する49個の排他的論理和手段からのパターン照
合出力と画素と同一周波数のクロックパルスを論理積し
パターン照合の結果パターンが合致していれば合致して
いることを各画素それぞれに対応したパルスを発生する
ことで知らせることとし画素と同一周波数の合致パルス
を出力することからなる論理演算回路17と、論理演算回
路17からの各合致パルス出力を個々にカウントする事に
より49個それぞれのパターン照合を行なった各座標位置
での相関値を個々に積算保持する相関値積算回路18と、
更に相関値積算回路18の相関値データをマイクロコンピ
ュータ13より事前に設定された検出スレッシュ値との大
小を比較判定することで候補点を高速に検出できるよう
に相関値積算回路18の出力を個々に対応したコンパレー
タを設け検出スレッシュ値を保持するラッチとの間で大
小を比較判定しその結果を保持するラッチを49個の個々
に対応した分だけ設けることとし、マイクロコンピュー
タ13には1水平走査ラインの比較結果を一まとめにし1
回の読み込みで把握できるようにしたラッチ部を垂直パ
ターン照合の7本だけ設けることでその演算対応位置の
特定を行いや好くする水平候補点検出回路19より構成さ
れる。
Next, another embodiment according to the present invention will be described with reference to the drawings. FIG. 2 is a block diagram showing a block circuit of a pattern recognition apparatus according to a second embodiment of the present invention. As shown in FIG. 1, the block diagram includes a binarization circuit 12 for digitizing a video signal from an imaging device 11, and a characteristic pattern of a binarized image from the binarization circuit 12 as a reference image. A reference image storage circuit 16 for storing and pattern matching with the image to be inspected, and the binary image data to be inspected from the binarization circuit 12 from the first row to the 16th row in the horizontal direction are instructed by the microcomputer 13. Six variable-length horizontal scanning line shift registers composed of six variable-length horizontal scanning line shift registers capable of holding an arbitrarily set amount
A vertical image data extraction circuit for outputting seven lines of inspected image data evenly spaced at a set interval in the vertical direction of the binary image by the binarization circuit 20 and the binarization circuit 12 at the same time
14 and the binarized image data to be inspected from the binarization circuit 12 are micro-computered from 1 pixel to 16 pixels in the horizontal direction.
By connecting six variable-length pixel shift registers that can be held arbitrarily set by the instruction from 13 in series, binary images in one horizontal direction are evenly spaced at a set interval at the same time. By providing seven stages to be output from seven places to connect the binarized image data to be inspected of the row output from the vertical image data extraction circuit 14, a total of 7 × 7 (= 49) Horizontal image data extraction circuit 15 that outputs the binarized inspection image data at the point simultaneously
And pattern matching outputs from 49 exclusive OR means for comparing the pattern of the image data from the reference image storage circuit 16 with the image pattern data to be inspected from the horizontal image data extraction circuit 15 and a clock pulse having the same frequency as the pixel. If the pattern matches as a result of the pattern matching, the matching is notified by generating a pulse corresponding to each pixel, and a matching pulse having the same frequency as the pixel is output. An arithmetic circuit 17 and a correlation value integrating circuit 18 that individually integrates and holds the correlation values at each coordinate position where each of the 49 matched patterns has been subjected to pattern matching by individually counting each matched pulse output from the logical arithmetic circuit 17; ,
Further, by comparing and determining the correlation value data of the correlation value accumulating circuit 18 with a detection threshold value set in advance by the microcomputer 13, the outputs of the correlation value accumulating circuit 18 are individually determined so that candidate points can be detected at high speed. The microcomputer 13 is provided with only 49 latches each corresponding to 49 different latches for comparing and judging the magnitude of the detection threshold value and the latch for holding the result. Put together the line comparison results 1
A horizontal candidate point detection circuit 19 is provided, which is provided with only seven latches for vertical pattern matching, which can be grasped by the number of readings.

このように構成された各回路部についてその動作を詳
しく説明する。実際の設計例では撮像装置11の視野を横
320画素,縦240画素の格子状に量子化するものとし、基
準画像の大きさを128×128画素以内の任意の長方形範囲
が可能なものとする。基準画像記憶回路16の構成は動作
開始および完了のタイミングを発生させるカウンタを水
平・垂直方向それぞれの計4つのカウンタを設け、基準
画像の読み出しあるいは書き込み用タイミング信号を作
り、前記読み出しタイミング信号により基準画像の読み
出しあるいは書き込みを有効とする期間に画素に対応し
たクロックをカウントするカウンタを動作させること
で、基準画像記憶回路内の画像データを入出力させるも
のである。これにより、基準画像記憶回路16の動作開始
および完了のタイミング信号の発生をそれぞれ行なうカ
ウンタへの設定値を変えることによって基準画像のパタ
ーンサイズを任意に変更させることが可能となる。
The operation of each circuit unit thus configured will be described in detail. In the actual design example, the field of view of
It is assumed that quantization is performed into a lattice shape of 320 pixels and 240 pixels vertically, and the size of the reference image can be any rectangular range within 128 × 128 pixels. The configuration of the reference image storage circuit 16 is such that a counter for generating operation start and completion timings is provided with a total of four counters in each of the horizontal and vertical directions, a timing signal for reading or writing the reference image is generated, and the reference timing signal is used for the reference image. By operating a counter that counts a clock corresponding to a pixel during a period in which image reading or writing is valid, image data in the reference image storage circuit is input / output. This makes it possible to arbitrarily change the pattern size of the reference image by changing the set values to the counters that respectively generate the timing signals for starting and completing the operation of the reference image storage circuit 16.

この実施例においても基準画像の大きさは128×128画
素以内の長方形範囲としたが、任意に設計できる。
Also in this embodiment, the size of the reference image is a rectangular range of 128 × 128 pixels or less, but can be arbitrarily designed.

ここで、垂直画像データ抽出回路14は被検査画像を撮
像装置11より映像信号として出力されたものを2値化回
路12により2値化された複数走査ラインの被検査画像デ
ータを同時に出力するための部分である。この垂直画像
データ抽出回路14の説明を第3図に示すブロック回路図
で行う。1走査期間にパターン照合を行なう座標を水平
方向7ポイント、垂直7ポイントとすると1水平走査ラ
イン単位で設定可能とした16水平走査ラインまでの被検
査画像データ保持が可能な可変長水平走査ライン・シフ
トレジスタ20は6本が必要となる。6本の可変長水平走
査ライン・シフトレジスタ20は第3図に示すように直列
に接続され、各可変長水平走査ライン・シフトレジスタ
20からはそれぞれ被検査画像データが出力される。1水
平走査ラインから16水平走査ラインまでの任意長の画像
データをマイクロコンピュータ13からの指示で任意に設
定された水平走査ライン分だけ保持可能な1本のシフト
レジスタとして構成するにはその記憶容量は1水平走査
ラインにおいて320画素の場合、320×16=5120画素(=
5kbit)必要となるので、一般には8kbit容量以上のRAM
を用いればよい。任意長の水平走査ラインの被検査画像
データ保持を行なうにはRAMアドレスの下位9bitは画素
の基本クロックを単にカウントするカウンタを直接RAM
に接続し、残りの上位アドレスは垂直走査ラインをカウ
ントするカウンタに、任意の設定回数(1≦k≦16)に
てカウント値をクリアし最初からカウントをやり直す巡
回カウンタとすればよい。この様にして2次元被検査画
像データの7つの地点V1DT,V2DT,V3DT,V4DT,V5DT,V6DT,
V7DTより被検査画像データが同時に出力されるようにな
る。
Here, the vertical image data extraction circuit 14 outputs the image to be inspected as a video signal from the imaging device 11 and simultaneously outputs the image data to be inspected of a plurality of scanning lines binarized by the binarization circuit 12. Part. This vertical image data extraction circuit 14 will be described with reference to a block circuit diagram shown in FIG. Assuming that the coordinates for pattern matching in one scanning period are 7 points in the horizontal direction and 7 points in the vertical direction, variable-length horizontal scanning lines capable of holding image data to be inspected up to 16 horizontal scanning lines that can be set in units of one horizontal scanning line Six shift registers 20 are required. The six variable-length horizontal scanning line shift registers 20 are connected in series as shown in FIG.
Inspection image data is output from the reference numeral 20. The storage capacity of a single shift register capable of holding image data of an arbitrary length from one horizontal scanning line to 16 horizontal scanning lines for a horizontal scanning line arbitrarily set by an instruction from the microcomputer 13 Is 320 × 16 = 5120 pixels (= 320 pixels in one horizontal scanning line)
5kbit) RAM is required, so generally more than 8kbit RAM
May be used. In order to hold the image data to be inspected for an arbitrary length horizontal scanning line, the lower 9 bits of the RAM address are directly stored in the counter that simply counts the basic clock of the pixel.
And the remaining upper address may be a cyclic counter that clears the count value at an arbitrary set number of times (1 ≦ k ≦ 16) and restarts counting from the beginning. In this way, the seven points V1DT, V2DT, V3DT, V4DT, V5DT, V6DT,
Inspection image data is simultaneously output from V7DT.

次に、7地点V1DT,V2DT,V3DT,V4DT,V5DT,V6DT,V7DTか
らの被検査画像データは水平画像データ抽出回路15へ入
力される。第4図は水平画像データ抽出回路15の構成を
示したブロック図である。水平走査ラインの16画素まで
の任意長の被検査画素データをマイクロコンピュータ13
からの指示で任意に設定された画素データ分(1≦j≦
16)だけ保持可能な可変長画素・シフトレジスタ21を1
水平方向の被検査画像データの入力に対して直列に6本
接続する。可変長画素・シフトレジスタ21は6本である
ためその出力は6本であるが、入力の画像データV1DT〜
V7DTも出力として使うことが出来るのでこの画像データ
も合わせて、1水平ラインからの出力は7出力V1DT,V1H
1,V1H2,V1H3,V1H4,V1H5,V1H6となる。被検査画像データ
の垂直方向の7地点V1DT,V2DT,V3DT,V4DT,V5DT,V6DT,V7
DTの入力それぞれに対してこの6本の可変長画素・シフ
トレジスタ21が7本それぞれ独立に必要となるため、合
計42個の可変長画素・シフトレジスタ21を用いる。可変
長画素・シフトレジスタ21としてはNPC社のSM5828を用
いる。このICにより8本までの垂直画像データ抽出回路
14からの被検査画像データの入力が可能となるため、6
個を直列接続したSM5828からの出力を外部に出すこと
で、水平方向にj画素ずつずれ、垂直方向にk画素ずつ
ずれた49点の被検査画像データが同時に出力されること
となる。
Next, the inspection image data from the seven points V1DT, V2DT, V3DT, V4DT, V5DT, V6DT, and V7DT is input to the horizontal image data extraction circuit 15. FIG. 4 is a block diagram showing the configuration of the horizontal image data extraction circuit 15. The pixel data to be inspected having an arbitrary length of up to 16 pixels on the horizontal scanning line is
For the pixel data arbitrarily set by the instruction from (1 ≦ j ≦
16) One variable-length pixel / shift register 21 that can hold only
Six lines are connected in series to the input of the image data to be inspected in the horizontal direction. Since the number of variable-length pixel / shift registers 21 is six, the output is six, but the input image data V1DT to
Since V7DT can also be used as an output, the output from one horizontal line together with this image data is 7 outputs V1DT, V1H
1, V1H2, V1H3, V1H4, V1H5, V1H6. V1DT, V2DT, V3DT, V4DT, V5DT, V6DT, V7 in the vertical direction of the inspected image data
Since each of the six variable-length pixel / shift registers 21 is required independently for each of the DT inputs, a total of 42 variable-length pixel / shift registers 21 are used. As the variable length pixel / shift register 21, SM5828 manufactured by NPC is used. With this IC, up to eight vertical image data extraction circuits
Since image data to be inspected from 14 can be input, 6
By outputting the output from the SM5828 connected in series to the outside, 49 points of image data to be inspected shifted by j pixels in the horizontal direction and by k pixels in the vertical direction are output simultaneously.

論理演算回路17は基準画像記憶回路16内の基準画像デ
ータと水平画像データ抽出回路15からの各座標位置にお
ける49個の被検査画像データV1DT,V1H1,V1H2,V1H3・・V
1H6,V2DT,V2H1・・・・V7H6の1データづつの2入力を
同時に排他的論理和演算を行ないその結果を合致パルス
としてパルス出力する部分である。第5図に示す構成ブ
ロック図のような論理演算回路17は排他的論理和演算を
同時に独立して49種類のシリアル入力される個々の画像
データV1DT,V1H1,V1H2,V1H3・・V1H6,V2DT,V2H1・・・
・V7H6と基準画像データの比較演算を行ない、更にその
比較の結果をそれぞれの2入力画像データが一致してい
ればそれをパルス出力として外部に出力する合致パルス
P11,P12,P13・・P17,P21,P22・・P27・・P37・・P77を
シリアル入力される画像データごとに演算しシリアル出
力する49個の論理演算ユニット22より構成される。
The logical operation circuit 17 has 49 reference image data V1DT, V1H1, V1H2, V1H3,... V at each coordinate position from the reference image data in the reference image storage circuit 16 and the horizontal image data extraction circuit 15.
1H6, V2DT, V2H1,..., V7H6 This is a portion for performing an exclusive OR operation on two inputs of one data at a time and outputting the result as a coincidence pulse. The logical operation circuit 17 as shown in the block diagram of FIG. 5 performs exclusive-OR operation simultaneously and independently and independently of 49 types of image data V1DT, V1H1, V1H2, V1H3,. V2H1 ・ ・ ・
A comparison pulse between V7H6 and the reference image data, and the result of the comparison is output as a pulse output to the outside if the two input image data match each other.
P17, P13,... P17, P21, P22,..., P27,..., P37...

個々の論理演算ユニット22の構成を第6図のブロック
図を用いて説明する。論理演算ユニット22は被検査画像
データと基準画像データの2入力の排他的論理和演算を
行なう排他的論理和ユニット23と排他的論理和ユニット
23からの一致不一致出力を画像データの1画素1画素に
対応した画素クロック論理積し入力画像データが一致し
ていた場合に合致パルスとしてシリアル信号出力するこ
とで外部に知らせる論理積ユニット24より構成されてい
る。
The configuration of each logical operation unit 22 will be described with reference to the block diagram of FIG. The logical operation unit 22 is an exclusive OR unit 23 and an exclusive OR unit for performing an exclusive OR operation of two inputs of the image data to be inspected and the reference image data.
A logical AND unit 24 that ANDs the match / mismatch output from 23 with a pixel clock corresponding to one pixel of image data and notifies the outside by outputting a serial signal as a match pulse when the input image data matches. Have been.

本発明の実施例においては論理演算ユニット22の動作
を2入力画像データが一致していればそれをパルス出力
として外部に出力する合致パルスを出力するような構成
としたが、不一致であるときにパルス出力として外部に
出力する不一致パルスを出力するような構成としパルス
数が少ない位置を検索することによるパターン照合を行
なうことも可能であるのはもちろんである。
In the embodiment of the present invention, the operation of the logical operation unit 22 is configured to output a coincidence pulse which is output to the outside as a pulse output if the two input image data coincide with each other. As a matter of course, it is also possible to perform a pattern matching by searching for a position having a small number of pulses by using a configuration in which an unmatched pulse output to the outside is output as a pulse output.

相関値積算回路18は、第7図に示すブロック図により
構成され、論理演算回路17からの各座標位置におけるパ
ターン照合の結果である49カ所の個々の検査座標位置に
対応した49本の独立したシリアル信号出力である合致パ
ルスP11,P12,P13・・P17,P21,P22・・P27・・P37・・P7
7を相関値として積算する部分で49個の独立したカウン
タ25を具備する。基準画像のサイズは128×128画素以内
としているので、この場合、相関値の最大値は16384と
なるため14bit以上のバイナリカウンタを49本用いれば
よい。
The correlation value accumulating circuit 18 is constituted by a block diagram shown in FIG. 7, and has 49 independent inspection coordinate positions corresponding to 49 individual inspection coordinate positions which are the result of pattern matching at each coordinate position from the logical operation circuit 17. Matching pulses P11, P12, P13, P17, P21, P22, P27, P37, P7, which are serial signal outputs
It has 49 independent counters 25 for integrating 7 as a correlation value. Since the size of the reference image is within 128 × 128 pixels, in this case, the maximum value of the correlation value is 16384, so that 49 binary counters of 14 bits or more may be used.

また、第2の実施例における水平候補点検出回路19は
相関値積算回路18の個々の相関値がマイクロコンピュー
タにて事前に設定された検出スレッシュ値との大小を同
時に比較判定することで1水平走査ラインの7座標位置
における相関値の状態を1回のマイクロコンピュータ13
による状態の読み込みで完了させるために設けられたも
のである。水平候補点検出回路19の構成を示したのが第
9図のブロック図である。以下、第9図を用いて水平候
補点検出回路19について説明する。水平候補点検出回路
19は相関値積算回路18の個々の相関値を保持しその相関
値をデータ出力する各カウンタ25..25の値がある相関値
よりも大きいのかどうか基準となる比較値をマイクロコ
ンピュータ13からのデータ書き込みにより比較値を保持
する検出スレッシュ保持ラッチ26と、相関値積算回路18
の49個の相関値の出力D11,D12,D13・・D17,D21,D22・・
D27・・D37・・D77が検出スレッシュ保持ラッチ26に保
持されている検出スレッシュ値との大小をそれぞれ独立
して比較し、その結果を保持してマイクロコンピュータ
13にてその状態を把握することが可能な49個の検出回路
27より構成される。49個の検出回路27は7本の水平比較
ラインごとにまとめると、1本の比較ライン内には7地
点のパターン照合の結果の状態を保持していることとな
る。この7地点の結果の1つ1つは検出スレッシュ値と
の大小を比べた結果であるので、それぞれの結果を1bit
の情報と見なし1水平比較ラインで7bitの情報量とする
ことが出来る。この7bit情報を1つのI/Oアドレスとし
て割り付けることにより1回のマイクロコンピュータ13
のI/Oの読み込みで7地点におけるパターン照合の状態
を把握することが可能となる。個々の検出回路27の構成
を第10図のブロック図を用いて説明する。検出回路27は
検出スレッシュ値と相関値の2入力のデータ比較を行な
うデジタルコンパレータ28と、デジタルコンパレータ28
から出力される大小比較の結果を保持する結果保持ラッ
チ29より構成される。水平候補点検出回路19を内蔵して
いない場合には7座標位置の相関値の状態の把握に7回
の相関値データの読み込みと、7回のマイクロコンピュ
ータ13による粗検出スレッシュ値との大小比較を行わな
ければならないが、水平候補点検出回路19を内蔵するこ
とにより1回のI/Oデータの読み込みで、上記の処理内
容を行なったことに相当するためその分処理時間を短縮
することが出来る。7つの水平走査ラインのそれぞれに
この水平候補点検出の手段を設けるため、7回の水平候
補点検出回路19の状態の読み込みで49回の相関値データ
の読み込みと、49回のマイクロコンピュータ13により粗
検出スレッシュ値との大小比較を代行することとなり、
検出スレッシュ値との大小比較を行うことによるパター
ン照合位置の特定はそれだけ高速に処理を行うことが可
能となる。マイクロコンピュータ13による状態の読み込
みは1回の読み込みで1水平走査ラインの7座標位置に
おける相関値の状態を行うことが可能であると、先に述
べたが、16bitのマイクロコンピュータ13を用いた場合
は1回のデータ読み込みで2水平走査ラインの7座標位
置における相関値の状態の把握が、32bitのマイクロコ
ンピュータ13を用いた場合は1回のデータ読み込みで4
水平走査ラインの7座標位置における相関値の状態の把
握が可能である。この様に制御に使用するマイクロコン
ピュータ13及びその接続構成の設計方法により、1回の
データ読み込みで行える相関値の状態の把握数が複数の
水平走査ラインとなるのはもちろんである。また、1水
平走査ラインのパターン照合ポイントの個数を増やした
とした場合、16bitのマイクロコンピュータ13を用いた
場合は1回のデータ読み込みで16座標位置までの相関値
の状態の把握が、32bitのマイクロコンピュータ13を用
いた場合は1回のデータ読み込みで32座標位置までの相
関値の状態の把握が可能である。そして、16bitや32bit
のマイクロコンピュータ13を用いた場合は、パターン照
合のポイント総数より水平・垂直方向のパターン照合の
個数を上記の点も考慮した設計を目的とする認識対象の
認識精度・検査範囲等の諸条件に合わせて行うことも可
能である。
Further, the horizontal candidate point detection circuit 19 in the second embodiment compares one correlation value of the correlation value integration circuit 18 with a detection threshold value set in advance by a microcomputer at the same time to determine one horizontal position. The state of the correlation value at seven coordinate positions of the scanning line is determined by one microcomputer 13
This is provided to complete the reading of the state by. FIG. 9 is a block diagram showing the configuration of the horizontal candidate point detection circuit 19. As shown in FIG. Hereinafter, the horizontal candidate point detection circuit 19 will be described with reference to FIG. Horizontal candidate point detection circuit
A counter 19 holds the individual correlation values of the correlation value accumulating circuit 18 and outputs the correlation values as data. A detection threshold holding latch 26 for holding a comparison value by writing data, and a correlation value accumulating circuit 18
Output D11, D12, D13 ... D17, D21, D22 ...
The D27,..., D37,..., D77 independently compare the magnitude of the detection threshold value held in the detection threshold holding latch 26 with the detection threshold value, and hold the result.
49 detection circuits whose status can be grasped at 13.
Consists of 27. When the 49 detection circuits 27 are put together for each of the seven horizontal comparison lines, one comparison line holds the state of the result of pattern matching at seven points. Since each of the results at these seven points is a result of comparing the magnitude with the detection threshold value, each result is represented by 1 bit.
And the amount of information can be 7 bits per horizontal comparison line. By assigning this 7-bit information as one I / O address, one microcomputer 13
By reading I / O, it is possible to grasp the state of pattern matching at seven points. The configuration of each detection circuit 27 will be described with reference to the block diagram of FIG. The detection circuit 27 includes a digital comparator 28 for comparing two-input data of a detection threshold value and a correlation value, and a digital comparator 28
And a result holding latch 29 for holding the result of the magnitude comparison output from. When the horizontal candidate point detection circuit 19 is not built-in, the correlation value data is read seven times to grasp the state of the correlation value at the seven coordinate positions, and the magnitude is compared with the coarse detection threshold value by the microcomputer 13 seven times. However, by incorporating the horizontal candidate point detection circuit 19, one reading of I / O data is equivalent to performing the above processing contents, so that the processing time can be shortened accordingly. I can do it. In order to provide the means for detecting horizontal candidate points in each of the seven horizontal scanning lines, the state of the horizontal candidate point detection circuit 19 is read seven times and the correlation value data is read 49 times, and the microcomputer 13 performs 49 times. The size comparison with the coarse detection threshold value will be performed on behalf of
The specification of the pattern collation position by comparing the magnitude with the detection threshold value can be performed at a higher speed. As described above, it is possible to read the state by the microcomputer 13 at one time to read the state of the correlation value at seven coordinate positions of one horizontal scanning line. Is that the state of the correlation value at 7 coordinate positions of two horizontal scanning lines can be grasped by one data reading.
It is possible to grasp the state of the correlation value at the seven coordinate positions of the horizontal scanning line. In this way, the number of grasps of the state of the correlation value that can be obtained by one data reading is, of course, a plurality of horizontal scanning lines by the microcomputer 13 used for control and the design method of the connection configuration thereof. When the number of pattern matching points in one horizontal scanning line is increased, when a 16-bit microcomputer 13 is used, the state of the correlation value up to 16 coordinate positions can be grasped by a single data read by using a 32-bit microcomputer. When the computer 13 is used, the state of the correlation value up to 32 coordinate positions can be grasped by one data reading. And 16bit and 32bit
When the microcomputer 13 is used, the number of pattern matchings in the horizontal and vertical directions from the total number of pattern matching points is set to various conditions such as the recognition accuracy and inspection range of the recognition target for the purpose of designing in consideration of the above points. It is also possible to perform it together.

これら本実施例による装置においては、水平・垂直の
パターン照合の総数を7×7=49ポイントとしたが、5
×5,9×9,11×7,5×15等の任意の設計値とすることが可
能であるのはもちろんであり、1回の画像走査期間内で
より高速に被検査画像5内のパターン照合処理を完了さ
せるにはより多数のパターン照合ポイントを設ければ良
いのは明かである。パターン照合ポイントを増すこと
は、照合の画素間隔を狭くすることが可能となりより少
ないパターン照合回数でパターンの照合を完了する確率
が増すために有利となる。
In the apparatus according to the present embodiment, the total number of horizontal / vertical pattern matching is set to 7 × 7 = 49 points.
It is of course possible to set an arbitrary design value such as × 5,9 × 9,11 × 7,5 × 15, etc. Obviously, more pattern matching points should be provided to complete the pattern matching process. Increasing the number of pattern matching points is advantageous because the pixel interval for matching can be narrowed and the probability of completing pattern matching with a smaller number of pattern matches is advantageous.

本発明の認識装置は粗精検出方法の一つであり、以下
どのようにして粗い検出より精密な検出に移行して行く
のか粗い検出を行なうときの画素間隔の決定の方法につ
いて説明する。第1回目の粗検出は水平画像データ抽出
回路15・垂直画像データ抽出回路14ともに8画素間隔で
被検査画像データV1DT,V1H1,V1H2,V1H3・・V1H6,V2DT,V
2H1・・・・V7H6が出力されるよう設定し、被検査画像
の検出範囲の中心位置に7行7列の各検査位置の中心位
置(4行4列目の位置)が対応するように配置して第1
回目の粗検出を行ない、第1回目の49個の候補点の位置
データの相関値をもとに相関カウント値の中で最大相関
値を保持する部分に対応する座標位置をもって第2回目
の検出を行う座標位置とする。第2回目以降のパターン
照合を行うための照合画素間隔は、水平・垂直方向とも
に先に行う粗検出の画素間隔を次回の検査画像範囲が含
むように次回の検出画素間隔を選択すると、パターン照
合の検査範囲を徐々に狭くしていく仮定で、相関値の最
大となる座標位置を検査画像範囲に含んでいたにもかか
わらずに見逃してしまうことはない。
The recognition apparatus of the present invention is one of the coarse and fine detection methods, and a method of determining a pixel interval when performing coarse detection will be described below as to how to shift from coarse detection to precise detection. In the first coarse detection, the horizontal image data extraction circuit 15 and the vertical image data extraction circuit 14 are both inspected image data V1DT, V1H1, V1H2, V1H3,... V1H6, V2DT, V
·································································································································································· First
The second coarse detection is performed, and the second detection is performed using the coordinate position corresponding to the portion holding the maximum correlation value in the correlation count value based on the correlation values of the position data of the first 49 candidate points. Is a coordinate position where When the next detected pixel interval is selected so that the next inspection image range includes the pixel interval of the coarse detection performed first in both the horizontal and vertical directions, the pattern matching for the second and subsequent pattern matchings is performed. It is assumed that the coordinate position where the correlation value becomes the maximum is included in the inspection image range and is not overlooked on the assumption that the inspection range is gradually narrowed.

従って、一般には水平方向におけるp回目のパターン
照合の画素間隔をdkp,p+1回目のパターン照合の画素
間隔をdk(p+1)、1水平走査ラインにおけるパター
ン照合のポイント数を奇数の値HSとすると、p+1回目
のパターン照合の画素間隔dk(p+1)は、 dkp−dk(p+1)×(HS−1)/2≦0 ……(1) を満たすような値の中で、最も小さな値を選ぶことが粗
検出の処理回数をより少ない回数にて、検査画像範囲を
収束するため効率的な選択の方法である。垂直方向のパ
ターン照合の画素間隔の効率的な選択の仕方も同様であ
る。
Therefore, in general, the pixel interval of the p-th pattern matching in the horizontal direction is dkp, the pixel interval of the p + 1-th pattern matching is dk (p + 1), and the number of points of the pattern matching in one horizontal scanning line is an odd value HS. For the pixel interval dk (p + 1) of the (p + 1) -th pattern matching, select the smallest value among values satisfying dkp−dk (p + 1) × (HS−1) / 2 ≦ 0 (1) Is an efficient selection method for converging the inspection image range with a smaller number of coarse detection processes. The same applies to the method of efficiently selecting the pixel interval for pattern matching in the vertical direction.

よって、本実施例の場合は、dk1=8,HS=7であるの
で、第2回目のパターン照合を行うための照合画素間隔
dk2は式(1)より、 8−dk2×(7−1)/2≦0 ……(2) これをdk2について変形し、 dk2≧8×2/(7−1)=16/6=2.7 ……(3) よって、上記の式(3)を満たす最小の整数値より、dk
2=3を得る。第3回目のパターン照合を行うための照
合画素間隔dk3は、dk2=3,HS=7であるので、式(1)
に代入することにより同様にdk3=1を得る。垂直方向
の第2回目のパターン照合画素間隔dj2は、dj1=8,VS=
7で水平方向の場合と同様なのでdj2=3を、第3回目
のパターン照合を行うための照合画素間隔dj3は、dj2=
3,VS=7であるので、式(1)より同様にdj3=1を得
る 以下、検出の動作について説明する。
Therefore, in the case of the present embodiment, since dk1 = 8 and HS = 7, the matching pixel interval for performing the second pattern matching is obtained.
From equation (1), dk2 is calculated as follows: 8-dk2 × (7-1) / 2 ≦ 0 (2) (3) Therefore, from the minimum integer value satisfying the above expression (3), dk
2 = 3 is obtained. Since the matching pixel interval dk3 for performing the third pattern matching is dk2 = 3 and HS = 7, the expression (1)
And dk3 = 1 is obtained in the same manner. The second pattern matching pixel interval dj2 in the vertical direction is dj1 = 8, VS =
7 is the same as that in the horizontal direction, dj2 = 3, and the matching pixel interval dj3 for performing the third pattern matching is dj2 =
3. Since VS = 7, dj3 = 1 is similarly obtained from equation (1). The detection operation will be described below.

第1回目の粗検出のために水平画像データ抽出回路15
及び垂直画像データ抽出回路14へマイクロコンピュータ
13より水平・垂直方向ともに8画素間隔にて被検査画像
データが出力されるようにデータ設定する。また、被検
査画像の検査範囲の中心位置に7行7列のパターン照合
の各検査位置の中心位置(4行4列目)が配置されるよ
うに基準画像データの出力位置をマイクロコンピュータ
13により制御する。パターン照合の各検査位置の中心位
置(4行4列目)が配置されるように基準画像データの
出力位置を制御するとは、具体的には第3図に示す4行
4列目の可変長画素・シフトレジスタ21から出力される
被検査画像データにおいて、第7図に示した部分画像6
を検査したい中心位置に配置したとして、その配置した
m行n列の部分画像6の第1行第1列目の画像データが
出力される走査タイミングに合わせて基準画像7の第1
行第1列目の画像データを出力するということである。
従って、配置した部分画像6の上下左右には同じm行n
列の部分画像6がそれぞれ8画素間隔で配置されている
ことになる。
Horizontal image data extraction circuit 15 for the first coarse detection
Microcomputer to the vertical and vertical image data extraction circuit 14
From 13, data is set so that the inspection image data is output at an interval of 8 pixels in both the horizontal and vertical directions. Also, the output position of the reference image data is set to the microcomputer so that the center position (4th row, 4th column) of each inspection position for pattern matching of 7 rows and 7 columns is arranged at the center position of the inspection range of the image to be inspected.
Controlled by 13. Controlling the output position of the reference image data so that the center position (4th row and 4th column) of each inspection position of pattern matching is arranged is, specifically, the variable length of 4th row and 4th column shown in FIG. In the inspection image data output from the pixel / shift register 21, the partial image 6 shown in FIG.
Is located at the center position to be inspected, and the first image of the reference image 7 is synchronized with the scanning timing at which the image data of the first row and first column of the arranged partial image 6 of m rows and n columns is output.
That is, the image data in the first column of the row is output.
Therefore, the same m rows n
This means that the partial images 6 in the column are arranged at intervals of 8 pixels.

次に、49個の相関値積算回路18のカウント値をすべて
クリアしパターン照合を開始する。第1回目のパターン
照合の後、相関値積算回路18内の各カウンタ25の相関デ
ータを読み込みその中で最大値となる相関データを検索
すると共にその最大相関値を保持していたパターン照合
座標位置を算出し、8画素間隔での粗検出スレッシュ値
よりも大きい値であれば前記最大相関値を保持していた
パターン照合座標位置を第2回目の検出を行なう座標位
置とする。次に、第2回目のパターン照合の準備とし
て、水平画像データ抽出回路15及び垂直画像データ抽出
回路14へマイクロコンピュータ13より水平・垂直方向と
もに3画素間隔にて被検査画像データが出力されるよう
にデータ設定し、第1回目のパターン照合処理にて算出
された座標位置を中心にパターン照合が行われるよう
に、基準画像データの出力位置を各検査位置の中心位置
(4行4列目)が配置されるように制御し、検出スレッ
シュ値を設定し、49個の相関値積算回路18のカウント値
をすべてクリアし第2回目のパターン照合を開始する。
Next, all the count values of the 49 correlation value accumulating circuits 18 are cleared and pattern matching is started. After the first pattern matching, the correlation data of each counter 25 in the correlation value accumulating circuit 18 is read, the correlation data having the maximum value is searched, and the pattern matching coordinate position where the maximum correlation value is held. Is calculated, and if the value is larger than the coarse detection threshold value at an interval of 8 pixels, the pattern matching coordinate position holding the maximum correlation value is set as the coordinate position for performing the second detection. Next, as preparation for the second pattern matching, the microcomputer 13 outputs image data to be inspected to the horizontal image data extraction circuit 15 and the vertical image data extraction circuit 14 at three pixel intervals in both the horizontal and vertical directions. And the output position of the reference image data is set to the center position of each inspection position (4th row, 4th column) so that pattern matching is performed centering on the coordinate position calculated in the first pattern matching processing. Are set so as to be arranged, the detection threshold value is set, the count values of the 49 correlation value integrating circuits 18 are all cleared, and the second pattern matching is started.

第2回目のパターン照合の後、相関データを読み込み
その中で最大値となるデータを検索すると共にその最大
相関値を保持していたパターン照合座標位置を算出す
る。次に、第3回目のパターン照合の準備として、水平
画像データ抽出回路15及び垂直画像データ抽出回路14へ
マイクロコンピュータ13より水平・垂直方向ともに1画
素間隔にて被検査画像データが出力されるようにデータ
設定し、第2回目のパターン照合処理にて算出された座
標位置を中心にパターン照合が行われるように、基準画
像データの出力位置を各検査位置の中心位置(4行4列
目)が配置されるように制御し、検出スレッシュ値を設
定し、49個の相関値積算回路18のカウント値をすべてク
リアし第3回目のパターン照合を開始する。
After the second pattern matching, the correlation data is read, the data having the maximum value is searched for, and the pattern matching coordinate position holding the maximum correlation value is calculated. Next, as preparation for the third pattern matching, the microcomputer 13 outputs image data to be inspected to the horizontal image data extraction circuit 15 and the vertical image data extraction circuit 14 at one pixel intervals in both the horizontal and vertical directions. The output position of the reference image data is set to the center position of each inspection position (4th row, 4th column) so that pattern matching is performed centering on the coordinate position calculated in the second pattern matching processing. Are set, the detection threshold value is set, the count values of the 49 correlation value integrating circuits 18 are all cleared, and the third pattern matching is started.

第3回目のパターン照合後、相関値積算回路18内のデ
ータをマイクロコンピュータ13により読み込み、データ
の中で最大値となるデータを検索すると共にその最大相
関値が所定の検出スレッシュ値よりも大きい値であれば
前記最大相関値を保持した部分に対応したパターン照合
座標位置を算出し、その座標位置を検出位置とする。
After the third pattern matching, the data in the correlation value accumulating circuit 18 is read by the microcomputer 13 to search for the data having the maximum value among the data, and the maximum correlation value is larger than a predetermined detection threshold value. If so, the pattern matching coordinate position corresponding to the portion holding the maximum correlation value is calculated, and the coordinate position is set as the detection position.

また、第2の実施例において49個の相関値積算回路18
のカウント値をすべてクリアして水平候補点検出回路19
の検出スレッシュ保持ラッチ26に8画素間隔での粗検出
用スレッシュ値をセットし49個全ての結果保持ラッチ29
をクリアして、パターン照合を開始する。
In the second embodiment, 49 correlation value integrating circuits 18
Clear all the count values of the horizontal candidate point detection circuit 19
The threshold value for coarse detection at an interval of 8 pixels is set in the detection threshold holding latch 26 of FIG.
Is cleared and pattern matching starts.

第1回目のパターン照合の後、水平候補点検出回路19
の7本の結果保持ラッチ29の内容を読み込み8画素間隔
での粗検出用スレッシュ値よりも大きな相関値を保持し
ている相関値積算回路18内のカウンタ25を特定し複数存
在すればそれらのカウンタ25の相関データを読み込みそ
の中で最大値となる相関データを検索すると共にその最
大相関値を保持していたパターン照合座標位置に対応す
る座標位置を算出し、第2回目の検出を行なう座標位置
とする。次に、第2回目のパターン照合の準備として、
水平画像データ抽出回路15及び垂直画像データ抽出回路
14へマイクロコンピュータ13より前記画素間隔の決定方
法に従い水平・垂直方向ともに3画素間隔にて被検査画
像データが出力されるようにデータ設定し、第1回目の
パターン照合処理にて算出された座標位置を中心に7行
7列のパターン照合が行われるように、基準画像データ
の出力位置を各検査位置の中心位置(4行4列目)が配
置されるように制御し、49個の相関値積算回路18のカウ
ント値をすべてクリアして水平候補点検出回路19の検出
スレッシュ保持ラッチ26に3画素間隔での粗検出用スレ
ッシュ値をセットし49個全ての結果保持ラッチ29をクリ
アして、第2回目のパターン照合を開始する。
After the first pattern matching, the horizontal candidate point detection circuit 19
The contents of the seven result holding latches 29 are read and the counters 25 in the correlation value accumulating circuit 18 which hold the correlation values larger than the coarse detection threshold value at the interval of 8 pixels are specified. The correlation data of the counter 25 is read, the correlation data having the maximum value is searched for, the coordinate position corresponding to the pattern collation coordinate position holding the maximum correlation value is calculated, and the coordinates for performing the second detection are obtained. Position. Next, in preparation for the second pattern matching,
Horizontal image data extraction circuit 15 and vertical image data extraction circuit
The microcomputer 13 sets data so that the image data to be inspected is output at three pixel intervals in both the horizontal and vertical directions in accordance with the above-described pixel interval determination method, and the coordinates calculated in the first pattern matching process. The output position of the reference image data is controlled so that the center position (4th row, 4th column) of each inspection position is arranged so that pattern matching of 7 rows and 7 columns is performed centering on the position, and 49 correlations are obtained. All the count values of the value accumulating circuit 18 are cleared, the threshold value for coarse detection at three pixel intervals is set in the detection threshold holding latch 26 of the horizontal candidate point detection circuit 19, and the result holding latch 29 for all 49 is cleared. , The second pattern matching is started.

第2回目のパターン照合の後、水平候補点検出回路19
の7本の結果保持ラッチ29の内容を読み込み3画素間隔
での粗検出用スレッシュ値よりも大きな相関値を保持し
ている相関値積算回路18内のカウンタ25を特定し複数存
在すればそれらのカウンタ25の相関データを読み込みそ
の中で最大値となるデータを検索すると共にその最大相
関値を保持していたパターン照合座標位置に対応する座
標位置を算出し、第3回目の検出を行なう座標位置とす
る。次に、第3回目のパターン照合の準備として、水平
画像データ抽出回路15及び垂直画像データ抽出回路14へ
マイクロコンピュータ13より水平・垂直方向ともに1画
素間隔にて被検査画像データが出力されるようにデータ
設定し、第2回目のパターン照合処理にて算出された座
標位置を中心に7行7列のパターン照合が行われるよう
に、基準画像データの出力位置を各検査位置の中心位置
(4行4列目)が配置されるように制御し、水平候補点
検出回路19の検出スレッシュ保持ラッチ26に3画素間隔
での検出スレッシュ値を設定し、49個の相関値積算回路
18のカウント値をすべてクリアし第3回目のパターン照
合を開始する。
After the second pattern matching, the horizontal candidate point detection circuit 19
The contents of the seven result holding latches 29 are read and the counters 25 in the correlation value accumulating circuit 18 which hold the correlation values larger than the coarse detection threshold value at three pixel intervals are specified. The correlation data of the counter 25 is read, the data having the maximum value is searched for, the coordinate position corresponding to the pattern collation coordinate position holding the maximum correlation value is calculated, and the coordinate position for performing the third detection is obtained. And Next, as preparation for the third pattern matching, the microcomputer 13 outputs the image data to be inspected to the horizontal image data extraction circuit 15 and the vertical image data extraction circuit 14 at one pixel intervals in both the horizontal and vertical directions. And the output position of the reference image data is set at the center position (4) of each inspection position so that pattern matching of 7 rows and 7 columns is performed centering on the coordinate position calculated in the second pattern matching process. (4th row and 4th column) are arranged, and the detection threshold value at three pixel intervals is set in the detection threshold holding latch 26 of the horizontal candidate point detection circuit 19, and 49 correlation value integration circuits are set.
Clear all 18 count values and start the third pattern matching.

第3回目のパターン照合の後、水平候補点検出回路19
の7本の結果保持ラッチ29の内容を読み込み3画素間隔
での粗検出用スレッシュ値よりも大きな相関値を保持し
ている相関値積算回路18内のカウンタ25を特定し複数存
在すればそれらのカウンタ25の相関データを読み込みそ
の中で最大値となるデータを検索すると共にその最大相
関値を保持していたパターン照合座標位置に対応する座
標位置を算出し、その座標位置を検出位置とする。
After the third pattern matching, the horizontal candidate point detection circuit 19
The contents of the seven result holding latches 29 are read and the counters 25 in the correlation value accumulating circuit 18 which hold the correlation values larger than the coarse detection threshold value at three pixel intervals are specified. The correlation data of the counter 25 is read, the data having the maximum value is searched for, the coordinate position corresponding to the pattern matching coordinate position holding the maximum correlation value is calculated, and the coordinate position is set as the detection position.

次に本発明の第3の実施例については第8図を用いて
説明する。
Next, a third embodiment of the present invention will be described with reference to FIG.

第1の実施例では水平候補点検出回路19のデータをマ
イクロコンピュータ13にて読み込むことによりパターン
照合位置における状態を把握し相関値の最大値を検索し
た。第8図には本実施例における認識装置のブロック図
が示されている。第2の実施例においては第1の実施例
の第1図の装置と比べて、候補点検出回路10が更に加え
られたことが異なっているのみで、他の構成部について
は同一である。よって、本実施例の装置を構成する2値
化回路12,垂直画像データ抽出回路14,水平画像データ抽
出回路15,基準画像パターン記憶回路16,論理演算回路1
7,相関値積算回路18についての説明は第1の実施例にお
いての説明と重複するので省略する。
In the first embodiment, the data at the horizontal candidate point detection circuit 19 is read by the microcomputer 13 to ascertain the state at the pattern matching position, and the maximum value of the correlation value is searched. FIG. 8 shows a block diagram of the recognition device in this embodiment. The second embodiment differs from the first embodiment shown in FIG. 1 only in that a candidate point detection circuit 10 is additionally provided, and the other components are the same. Therefore, the binarization circuit 12, the vertical image data extraction circuit 14, the horizontal image data extraction circuit 15, the reference image pattern storage circuit 16, the logical operation circuit 1
7. The description of the correlation value accumulating circuit 18 is omitted because it is the same as that of the first embodiment.

候補点検出回路10は水平候補点検出回路19の複数位置
に於ける相関値データの状態を1回のデータ入力にて把
握できるよう水平候補点検出回路19の7本の各水平比較
ラインごとにまとめた結果保持ラッチ29の出力において
検出スレッシュ保持ラッチ26に設定した値よりも大きか
った値を持つ結果保持ラッチ29が7本の各水平比較ライ
ンの中で1つでもあればその状態を各水平比較ラインに
おける情報として保持することでマイクロコンピュータ
13に検出スレッシュ値を越えるパターン照合座標位置が
49地点の中にあったことをより少ないマイクロコンピュ
ータ13によるデータ読み込み動作にてパターン照合を行
なった座標位置全体の状態をより集約された情報として
把握するために設けたものである。候補点検出回路10の
構成を示したのが第11図のブロック図である。7本の各
水平比較ラインからの結果保持ラッチ29の出力Q11,Q12,
Q13・・Q17,Q21,Q22・・Q27・・Q37・・Q77は各水平比
較ライン内の7bitを1まとまりとして論理和することで
各水平比較ライン内に検出スレッシュ値を越える相関値
を保持したものがあるのか無いのか、その存在の有無を
1水平比較ラインにおける情報を1bitの情報として7水
平比較ラインの状態を7つのライン検出回路30に保持さ
せる。すなわち、第11図に示すように(Q11,Q12,Q13..Q
17),(Q21,Q22,Q23..Q27),(Q31,Q32,Q33..Q3
7)...(Q71,Q72,Q73..Q77)の各7bit入力をそれぞれに
論理和し、更にその結果を7つのライン検出回路30で1
水平比較ラインの情報を1bitの情報として保持させる。
本実施例においては7水平比較ライン設けているので各
水平比較ラインの情報を7bitとすることができ、1回の
マイクロコンピュータ13によるI/Oのデータ7読み込み
にて全パターン照合位置においての検出スレッシュ値を
越える座標位置の有無を把握することが可能となる。
The candidate point detection circuit 10 is provided for each of the seven horizontal comparison lines of the horizontal candidate point detection circuit 19 so that the state of the correlation value data at a plurality of positions of the horizontal candidate point detection circuit 19 can be grasped by one data input. If at least one of the seven result comparison latches 29 has a value larger than the value set in the detection threshold value holding latch 26 in the output of the result holding latch 29, the state of each of the result comparison latches 29 is determined. Microcomputer by holding as information in comparison line
The pattern matching coordinate position exceeding the detection threshold
This is provided in order to grasp the state of the entire coordinate position where pattern matching has been performed by the microcomputer 13 with less data having been in 49 points as a more aggregated information. FIG. 11 is a block diagram showing the configuration of the candidate point detection circuit 10. As shown in FIG. The outputs Q11 and Q12 of the result holding latch 29 from each of the seven horizontal comparison lines
Q13, Q17, Q21, Q22, Q27, Q37, Q77 hold a correlation value exceeding the detection threshold value in each horizontal comparison line by ORing 7 bits in each horizontal comparison line as a unit. The presence / absence of the presence / absence is determined by using the information on one horizontal comparison line as 1-bit information and holding the states of the seven horizontal comparison lines in the seven line detection circuits 30. That is, as shown in FIG. 11, (Q11, Q12, Q13..Q
17), (Q21, Q22, Q23..Q27), (Q31, Q32, Q33..Q3
7) The 7-bit inputs of (Q71, Q72, Q73..Q77) are logically ORed respectively, and the result is further divided by seven line detection circuits 30 into 1
The information of the horizontal comparison line is held as 1-bit information.
In the present embodiment, since seven horizontal comparison lines are provided, the information of each horizontal comparison line can be 7 bits, and detection of all pattern collation positions by one reading of the I / O data 7 by the microcomputer 13 is performed. It is possible to grasp the presence or absence of a coordinate position exceeding the threshold value.

候補点検出回路10は水平候補点検出回路19からの49ポ
イントの座標位置における相関値の状態の把握を更に集
約して、パターン照合を行っている検査範囲の49個全体
の相関値の状態を1回のマイクロコンピュータ13による
データ読み込みで把握し、マイクロコンピュータ13によ
るソフトウエアで行っても差し支えない比較判定処理を
高速に処理するために設けたものである。に述べたが、
16bitのマイクロコンピュータ13を用いた場合は1回の
データ読み込みで2水平走査ラインの7座標位置におけ
る相関値の状態の把握が、32bitのマイクロコンピュー
タ13を用いた場合は1回のデータ読み込みで4水平走査
ラインの7座標位置における相関値の状態の把握が可能
である。この様に制御に使用するマイクロコンピュータ
13及びその接続構成の設計により、1回のデータ読み込
みで行える相関値の状態の把握数が複数の水平走査ライ
ンとなるのはもちろんである。
The candidate point detection circuit 10 further summarizes the state of the correlation value at the 49-point coordinate position from the horizontal candidate point detection circuit 19, and displays the state of the correlation values of all 49 inspection ranges in the pattern matching. This is provided to perform high-speed comparison and judgment processing which can be grasped by one data read by the microcomputer 13 and performed by software by the microcomputer 13. As stated in
When the 16-bit microcomputer 13 is used, the state of the correlation value at seven coordinate positions of two horizontal scanning lines can be grasped by one data reading, and when the 32-bit microcomputer 13 is used, four times can be obtained by one data reading. It is possible to grasp the state of the correlation value at the seven coordinate positions of the horizontal scanning line. The microcomputer used for control in this way
According to the design of 13 and its connection configuration, the number of correlation value states that can be obtained by one data reading is of course a plurality of horizontal scanning lines.

本実施例による装置においては水平・垂直のパターン
照合の総数を7×7=49ポイントとしたが、9×9,11×
7,5×15等の任意の設計値とすることが可能であるのは
もちろんであり、1回の画像走査期間内でより高速に被
検査画像内のパターン照合処理を完了させるにはより多
数のパターン照合ポイントを設ければ良いのは明かであ
る。パターン照合ポイントを増すことは、より少ないパ
ターン照合回数でパターンの照合を完了する確率が増す
ために有利となる。
In the apparatus according to the present embodiment, the total number of horizontal / vertical pattern matching is set to 7 × 7 = 49 points, but 9 × 9,11 ×
Of course, it is possible to set an arbitrary design value such as 7,5 × 15, etc. It is clear that the pattern matching point should be provided. Increasing the number of pattern matching points is advantageous because the probability of completing pattern matching with a smaller number of pattern matchings is increased.

本発明において、どのようにして粗い検出より精密な
検出に移行して行くのか、粗い検出を行なうときの画素
間隔の決定方法は第1の実施例と同様であるので本件に
ついての説明は省略する。
In the present invention, how to shift from coarse detection to more precise detection, and the method of determining the pixel interval when performing coarse detection is the same as in the first embodiment, so that the description of this case is omitted. .

以下、検出の動作について説明する。第1回目の粗検
出のために水平画像データ抽出回路15及び垂直画像デー
タ抽出回路14へマイクロコンピュータ13より水平・垂直
方向ともに8画素間隔にて被検査画像データが出力され
るようにデータ設定する。また、被検査画像5の検査範
囲の中心位置に7行7列のパターン照合の各検査位置の
中心位置(4行4列目)が配置されるように基準画像デ
ータの出力位置をマイクロコンピュータ13により制御す
る。パターン照合の各検査位置の中心位置(4行4列
目)が配置されるように基準画像データの出力位置を制
御するとは、具体的には第4図に示す4行4列目の可変
長画素シフトレジスタ21から出力される被検査画像デー
タにおいて、第2図の部分画像6を検査したい中心位置
に配置したとして、その配置した128行×128列の部分画
像6の第1行第1列目の画像データが出力される走査タ
イミングに合わせて基準画像データ7の第1行第1列目
の画像データを出力するということである。従って、配
置した部分画像6の上下左右には同じ128行×128列の部
分画像6がそれぞれ8画素間隔で配置されていることに
なる。次に、49個の相関値積算回路18のカウント値をす
べてクリアして水平候補点検出回路19の検出スレッシュ
保持ラッチ26に8画素間隔での粗検出用スレッシュ値を
セットし49個全ての結果保持ラッチ29をクリアし候補点
検出回路10と7bit全てのライン検出回路30をクリアし
て、パターン照合を開始する。
Hereinafter, the detection operation will be described. For the first coarse detection, the microcomputer 13 sets data to the horizontal image data extraction circuit 15 and the vertical image data extraction circuit 14 so that the image data to be inspected is output at eight pixel intervals in both the horizontal and vertical directions. . Also, the output position of the reference image data is set to the microcomputer 13 so that the center position (4th row, 4th column) of each inspection position for pattern matching of 7 rows and 7 columns is arranged at the center position of the inspection range of the image 5 to be inspected. Is controlled by Controlling the output position of the reference image data so that the center position (4th row and 4th column) of each inspection position for pattern matching is arranged specifically means the variable length of 4th row and 4th column shown in FIG. In the image data to be inspected output from the pixel shift register 21, it is assumed that the partial image 6 in FIG. 2 is arranged at the center position to be inspected, and the first row and first column of the arranged 128-row × 128-column partial image 6 That is, the image data of the first row and the first column of the reference image data 7 is output in synchronization with the scanning timing at which the image data of the eye is output. Accordingly, the same partial image 6 of 128 rows × 128 columns is disposed at an interval of 8 pixels on the upper, lower, left and right sides of the disposed partial image 6. Next, the count values of the 49 correlation value accumulating circuits 18 are all cleared, and the detection threshold holding latch 26 of the horizontal candidate point detection circuit 19 is set with the coarse detection threshold value at 8-pixel intervals. The holding latch 29 is cleared, the candidate point detection circuit 10 and all the 7-bit line detection circuits 30 are cleared, and pattern matching is started.

第1回目のパターン照合の後、候補点検出回路10内の
ライン検出回路30の内容をマイクロコンピュータ13が読
み込み事前に設定された第1回目の粗検出スレッシュ値
を越える検出位置の候補点が存在するかを調べ、存在し
ていた場合に存在を示している水平比較ラインの水平候
補点検出回路19内の対応する結果保持ラッチ29の情報を
読み込み、その情報に対応するパターン照合座標位置に
おける相関値を保持しているカウンタ25より、第1回目
のパターン照合を行なった複数の補填の相関値の中で粗
検出スレッシュ値よりも大きな相関値を保持している相
関値カウンタ25の中で最大相関値を保持する部分に対応
したパターン照合座標位置をもって、次回のパターン照
合の中心位置とする。次に、第2回目のパターン照合の
準備として水平画像データ抽出回路15及び垂直画像デー
タ抽出回路14へマイクロコンピュータ13より水平・垂直
方向ともに3画素間隔にて被検査画像データが出力され
るようにデータ設定し、第1回目のパターン照合処理に
て算出された座標位置を中心にパターン照合が行なわれ
るように、基準画像データの出力位置を各検査位置の中
心位置(4行4列目)が配置されるように制御し、検出
スレッシュ値を設定し49個の相関値積算回路18のカウン
ト値をすべてクリアして水平候補点検出回路19の検出ス
レッシュ保持ラッチ26に3画素間隔での粗検出用スレッ
シュ値をセットし49個全ての結果保持ラッチ29をクリア
し候補点検出回路10の7bit全てのライン検出回路30をク
リアして、第2回目のパターン照合を開始する。
After the first pattern matching, the microcomputer 13 reads the contents of the line detection circuit 30 in the candidate point detection circuit 10 and there is a candidate point at a detection position exceeding the first coarse detection threshold value set in advance. The information of the corresponding result holding latch 29 in the horizontal candidate point detection circuit 19 of the horizontal comparison line indicating the existence of the horizontal comparison line is read if it exists, and the correlation at the pattern matching coordinate position corresponding to the information is read. From the counter 25 holding the value, the largest correlation value counter 25 holding the correlation value larger than the coarse detection threshold value among the correlation values of the plurality of corrections performed in the first pattern matching. The pattern matching coordinate position corresponding to the part holding the correlation value is set as the center position of the next pattern matching. Next, as preparation for the second pattern matching, the microcomputer 13 outputs image data to be inspected to the horizontal image data extraction circuit 15 and the vertical image data extraction circuit 14 at three pixel intervals in both the horizontal and vertical directions. The data is set, and the output position of the reference image data is set to the center position (4th row, 4th column) of each inspection position so that pattern matching is performed centering on the coordinate position calculated in the first pattern matching processing. Control so that they are arranged, set the detection threshold value, clear all count values of the 49 correlation value accumulating circuits 18, and coarsely detect the detection threshold holding latch 26 of the horizontal candidate point detection circuit 19 at three pixel intervals. A threshold value is set, all 49 result holding latches 29 are cleared, all 7-bit line detection circuits 30 of the candidate point detection circuit 10 are cleared, and the second pattern matching is started.

第2回目のパターン照合の後、候補点検出回路10の内
容をマイクロコンピュータ13が読み込み事前に設定され
た第1回目の粗検出スレッシュ値を越える検出位置の候
補点が存在するかを調べ、存在していた場合に存在を示
している水平比較ラインの水平候補点検出回路19内の対
応する結果保持ラッチ29の情報を読み込み、その情報に
対応するパターン照合座標位置における相関値を保持し
ているカウンタ25より、第2回目のパターン照合を行な
った複数の候補点の相関値の中で粗検出スレッシュ値よ
りも大きな相関値を保持している相関値カウンタ25の中
で最大相関値を保持する部分に対応したパターン照合座
標位置をもって、次回のパターン照合の中心位置とす
る。次に、第3回目のパターン照合の準備として水平画
像データ抽出回路15及び垂直画像データ抽出回路14へマ
イクロコンピュータ13より水平・垂直方向ともに3画素
間隔にて被検査画像データが出力されるようにデータ設
定し、第1回目のパターン照合処理にて算出された座標
位置を中心にパターン照合が行なわれるように、基準画
像データの出力位置を各検査位置の中心位置(4行4列
目)が配置されるように制御し、検出スレッシュ値を設
定し49個の相関値積算回路18のカウント値をすべてクリ
アして水平候補点検出回路19の検出スレッシュ保持ラッ
チ26に1画素間隔での粗検出用スレッシュ値をセットし
49個全ての結果保持ラッチ29をクリアし候補点検出回路
10の7bit全てのライン検出回路30をクリアして、第3回
目のパターン照合を開始する。
After the second pattern matching, the microcomputer 13 reads the contents of the candidate point detection circuit 10 and checks whether there is a candidate point at a detection position exceeding the first coarse detection threshold value set in advance. The information of the corresponding result holding latch 29 in the horizontal candidate point detection circuit 19 of the horizontal comparison line indicating the presence is read in the case where it is present, and the correlation value at the pattern matching coordinate position corresponding to the information is held. From the counter 25, the maximum correlation value is held in the correlation value counter 25 holding the correlation value larger than the coarse detection threshold value among the correlation values of the plurality of candidate points subjected to the second pattern matching. The pattern matching coordinate position corresponding to the portion is set as the center position of the next pattern matching. Next, as preparation for the third pattern matching, the microcomputer 13 outputs image data to be inspected to the horizontal image data extraction circuit 15 and the vertical image data extraction circuit 14 at three pixel intervals in both the horizontal and vertical directions. Data is set, and the output position of the reference image data is set to the center position (4th row, 4th column) of each inspection position so that pattern matching is performed around the coordinate position calculated in the first pattern matching processing. Control so that they are arranged, set the detection threshold value, clear all count values of the 49 correlation value accumulating circuits 18, and coarsely detect the detection threshold holding latch 26 of the horizontal candidate point detection circuit 19 at one pixel intervals. Set the threshold value for
Candidate point detection circuit by clearing all 49 result holding latches 29
The 10th 7-bit line detection circuit 30 is all cleared, and the third pattern matching is started.

第3回目のパターン照合の後、候補点検出回路10の内
容をマイクロコンピュータ13が読み込み事前に設定され
た第1回目の粗検出スレッシュ値を越える検出位置の候
補点が存在するかを調べ、存在していた場合に存在を示
している水平比較ラインの水平候補点検出回路19内の対
応する結果保持ラッチ29の情報を読み込み、その情報に
対応するパターン照合座標位置における相関値を保持し
ているカウンタ25より、第3回目のパターン照合を行な
った複数の候補点の相関値の中で粗検出スレッシュ値よ
りも大きな相関値を保持している相関値カウンタ25の中
で最大相関値を保持していたパターン照合座標位置に対
応する座標位置を算出しその座標位置を検出位置とす
る。
After the third pattern matching, the microcomputer 13 reads the contents of the candidate point detection circuit 10 and checks whether there is a candidate point at a detection position exceeding the first coarse detection threshold value set in advance. The information of the corresponding result holding latch 29 in the horizontal candidate point detection circuit 19 of the horizontal comparison line indicating the presence is read in the case where it is present, and the correlation value at the pattern matching coordinate position corresponding to the information is held. The counter 25 holds the maximum correlation value in the correlation value counter 25 that holds a correlation value larger than the coarse detection threshold value among the correlation values of a plurality of candidate points subjected to the third pattern matching. A coordinate position corresponding to the pattern matching coordinate position is calculated, and the coordinate position is set as a detection position.

発明の効果 以上、説明したように本発明のパターン認識方法ある
いはその装置によれば、基準画像のサイズを任意に設定
が可能となり従来不可能に近かった認識対象の位置検出
が可能となった。更に、任意サイズの基準画像パターン
を設定することが可能となったために、登録における作
業を容易とするとともに、大きな被検査画像エリアにお
いてパターンマッチングを行なっても処理時間を増すこ
となく高速に位置検出が可能となった。
Effect of the Invention As described above, according to the pattern recognition method or apparatus of the present invention, the size of the reference image can be arbitrarily set, and the position of the recognition target, which has been almost impossible in the past, can be detected. Furthermore, since it is possible to set a reference image pattern of an arbitrary size, the work of registration is facilitated, and even if pattern matching is performed on a large image area to be inspected, position detection can be performed quickly without increasing processing time. Became possible.

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

第1図は本発明に係るパターン認識装置の第1の実施例
の構成を示したブロック図、第2図は同じく第2の実施
例の構成を示したブロック図、第3図は本発明の実施例
における垂直画像データ抽出回路の構成を説明したブロ
ック図、第4図は同じく水平画像データ抽出回路の構成
を説明したブロック図、第5図は同じく論理演算回路の
構成を説明したブロック図、第6図は同じく論理演算回
路の各論理演算ユニットの構成を説明したブロック図、
第7図は同じく相関値積算回路の構成を説明したブロッ
ク図、第8図は本発明の第3の実施例の構成を示したブ
ロック図、第9図は第8図の実施例における水平候補点
検出回路の構成を説明したブロック図、第10図は同じく
水平候補点検出回路の各検出回路の構成を説明したブロ
ック図、第11図は同じく候補点検出回路の構成を説明し
たブロック図、及び、第12図は本発明の前提となるパタ
ーンマッチング処理の概略図である。 10……候補点検出回路、 11……撮像装置、 12……2値化回路、 13……マイクロコンピュータ、 14……垂直画像データ抽出回路、 15……水平画像データ抽出回路、 16……基準画像記憶回路、 17……論理演算回路、 18……相関値積算回路、 19……水平候補点検出回路。
FIG. 1 is a block diagram showing the configuration of a first embodiment of a pattern recognition apparatus according to the present invention, FIG. 2 is a block diagram showing the configuration of the second embodiment, and FIG. FIG. 4 is a block diagram illustrating a configuration of a vertical image data extraction circuit according to the embodiment; FIG. 4 is a block diagram illustrating a configuration of a horizontal image data extraction circuit; FIG. FIG. 6 is a block diagram illustrating the configuration of each logical operation unit of the logical operation circuit,
FIG. 7 is a block diagram illustrating the configuration of the correlation value integrating circuit, FIG. 8 is a block diagram illustrating the configuration of the third embodiment of the present invention, and FIG. 9 is a horizontal candidate in the embodiment of FIG. Block diagram illustrating the configuration of the point detection circuit, FIG. 10 is a block diagram similarly illustrating the configuration of each detection circuit of the horizontal candidate point detection circuit, FIG. 11 is a block diagram similarly illustrating the configuration of the candidate point detection circuit, FIG. 12 is a schematic diagram of a pattern matching process which is a premise of the present invention. 10: Candidate point detection circuit, 11: Image pickup device, 12: Binarization circuit, 13: Microcomputer, 14: Vertical image data extraction circuit, 15: Horizontal image data extraction circuit, 16: Reference Image storage circuit, 17 ... Logic operation circuit, 18 ... Correlation value integration circuit, 19 ... Horizontal candidate point detection circuit.

Claims (4)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】被検査画像を撮像する撮像手段の映像信号
をデジタル化し、 特徴的パターンを任意サイズで切り出し基準画像として
予めメモリに記憶した画像データを出力できるようにし
た基準画像記憶手段と、 2次元被検査画像データの任意数dyの水平走査ラインを
マイクロコンピュータから設定された水平走査ライン分
だけ保持可能な個数(VS−1)の水平走査ライン保持手
段を水平走査ライン間隔k(1≦k≦dy)で均等に間を
置いた複数行VSの検査座標に対応した被検査画像データ
が同時に出力されるようにした垂直画像データ抽出手段
と、 前記垂直画像データ抽出手段からの被検査画像データの
同時出力を水平方向の任意数の画素dxまでをマイクロコ
ンピュータから設定された画素分だけ保持可能な画素シ
フト手段を(HS−1)個直列につなぐことで、1水平方
向の被検査画像データが同時にある設定された画素j
(1≦j≦dx)間隔で均等に間を置いたHSヵ所から同時
に出力されるようにしたものを前記垂直抽出手段からの
VS個の水平走査ラインから同時に出力された被検査画像
データを入力として、前記(HS−1)個直列の画素シフ
ト手段をVS段設ける事で2次元被検査画像データの総計
VS×HS地点の個々の検査座標位置に対応した被検査画像
データを同時に出力されるようにした水平画像データ抽
出手段と、 前記基準画像記憶手段からの基準画像データと前記水平
画像データ抽出手段からの個々の検査座標位置に対応し
た被検査画像データを同時にVS×HS個の地点でパターン
比較し、VS×HS個の地点個々の検査座標位置に対応した
パターン照合出力をVS×HS個同時に合致データとして個
々の検査座標位置に対応した部分それぞれより同時にシ
リアル出力することからなる論理演算手段と、 前記論理演算手段からの個々の検査座標位置に対応した
各合致データ出力を個々に同時カウントすることにより
VS×HS個のパターン照合を1画像走査で完了し個々の検
査座標位置に対応した部分で独立に相関値として算出保
持する相関値積算手段により構成され、 第1回目の粗検出は水平画像データ抽出手段・垂直画像
データ抽出手段をそれぞれの第1回目のパターン照合の
画素間隔でHS×VS個の被検査画像データが同時に出力さ
れるように設定し、被検査画像の中心位置にHS行×VS列
の検査位置の中心部が対応するように配置して第1回目
の粗検出を行い、第1回目のパターン照合を行ったHS×
VS個の候補点の相関データの中で最大相関値を保持する
部分を検索し、所定の粗検出スレッシュ値よりも大きい
値であれば前記最大相関値を保持した部分に対応したパ
ターン照合座標位置をもって、次回のパターン照合の中
心座標位置と決定し、前記第1回目の粗検出にて求めた
最高相関値の座標位置を中心にHS行×VS列の検査位置の
中心部が対応するように配置し、第2回目の粗検出を水
平方向は{第1の画素間隔−第2の画素間隔×(HS−
1)/2}≦0を、垂直方向は{第1の画素間隔−第2の
画素間隔×(VS−1)/2}≦0を、満たし最小の整数値
となる第2の画素間隔にてHS行×VS列の中心部が対応す
るように配置してパターン照合を行い第2回目のHS×VS
個の候補点の相関データの最高相関値の座標位置を求
め、前記第2回目の粗検出にて求めた最高相関値の座標
位置を中心にHS行×VS列の中心部を配置して第3回目以
降のパターン照合を水平・垂直方向の設定画素間隔が1
画素間隔となるまで水平方向は{第P回目のパターン照
合画素間隔−第P+1回目のパターン照合画素間隔×
(HS−1)/2}≦0を、垂直方向は{第Pの回目のパタ
ーン照合画素間隔−第P+1回目のパターン照合画素間
隔×(VS−1)/2}≦0を満たし、最小の整数値となる
第P+1回目のパターン照合の画素間隔にてHS行×VS列
の中心部を第P回目の最高相関値の座標位置を配置して
行い、1画素間隔にて行ったパターン照合のHS×VS個の
候補点の相関データの最大値が所定の検出スレッシュ値
よりも大きい値であれば前記最大相関値を保持した部分
に対応した座標位置を検出位置とするパターン認識方
法。
1. Reference image storage means for digitizing a video signal of an image pickup means for picking up an image to be inspected, extracting a characteristic pattern at an arbitrary size, and outputting image data previously stored in a memory as a reference image; The number (VS-1) of horizontal scanning line holding means capable of holding an arbitrary number dy of horizontal scanning lines of the two-dimensional inspection image data by the number of horizontal scanning lines set by the microcomputer is set to a horizontal scanning line interval k (1 ≦ 1). k ≦ dy) vertical image data extracting means for simultaneously outputting inspected image data corresponding to the inspection coordinates of a plurality of rows VS evenly spaced, and an inspected image from the vertical image data extracting means A series of (HS-1) pixel shift means capable of holding the simultaneous output of data up to an arbitrary number of pixels dx in the horizontal direction by the number of pixels set by the microcomputer. It is to connect, the pixel j of inspection image data of one horizontal direction is a certain set time
(1.ltoreq.j.ltoreq.dx) The ones that are simultaneously output from the HS locations evenly spaced at intervals are output from the vertical extraction means.
By inputting the image data to be inspected simultaneously output from the VS horizontal scanning lines as inputs, and providing the (HS-1) serial pixel shift means in the VS stage, the total of the two-dimensional image data to be inspected can be obtained.
Horizontal image data extracting means for simultaneously outputting the inspected image data corresponding to the individual inspection coordinate positions of the VS × HS points; and from the reference image data and the horizontal image data extracting means from the reference image storage means. Inspection image data corresponding to each inspection coordinate position is compared at VS x HS points at the same time, and the pattern matching output corresponding to each inspection coordinate position at VS x HS points matches VS x HS at the same time A logical operation means for simultaneously outputting serial data from each part corresponding to each inspection coordinate position as data, and simultaneously counting each matched data output corresponding to each inspection coordinate position from the logical operation means. By
VS × HS pattern matching is completed by one image scan, and is constituted by correlation value accumulating means for independently calculating and holding as a correlation value in a portion corresponding to each inspection coordinate position. The first coarse detection is performed on horizontal image data. The extraction means and the vertical image data extraction means are set so that HS × VS inspection image data are simultaneously output at the pixel interval of the first pattern matching, and the HS row × HS × which is arranged so that the center of the inspection position of the VS row corresponds to the first coarse detection and the first pattern matching is performed
Search for the part holding the maximum correlation value in the correlation data of the VS candidate points, and if the value is larger than a predetermined coarse detection threshold value, the pattern matching coordinate position corresponding to the part holding the maximum correlation value Is determined as the center coordinate position of the next pattern matching, and the center of the inspection position of HS rows × VS columns is centered on the coordinate position of the highest correlation value obtained in the first coarse detection. In the horizontal direction, the second coarse detection is performed by dividing the first pixel interval−the second pixel interval × (HS−
1) / 2} ≦ 0, and in the vertical direction, a second pixel interval that satisfies {first pixel interval−second pixel interval × (VS−1) / 2} ≦ 0 and is a minimum integer value. 2nd HS × VS
The coordinate position of the highest correlation value of the correlation data of the candidate points is obtained, and the center of the HS row × VS column is arranged around the coordinate position of the highest correlation value obtained in the second coarse detection. For the third and subsequent pattern comparisons, the set pixel interval in the horizontal and vertical directions is 1
Until the pixel interval is reached, the horizontal direction is {P-th pattern matching pixel interval−P + 1-th pattern matching pixel interval ×
(HS-1) / 2} ≦ 0, and the vertical direction satisfies {P-th pattern matching pixel interval−P + 1-th pattern matching pixel interval × (VS−1) / 2} ≦ 0. At the pixel interval of the (P + 1) -th pattern matching, which is an integer, the center of the HS row × VS column is arranged at the coordinate position of the P-th highest correlation value, and the pattern matching performed at the 1-pixel interval is performed. If the maximum value of the correlation data of the HS × VS candidate points is larger than a predetermined detection threshold value, the pattern recognition method uses the coordinate position corresponding to the portion holding the maximum correlation value as the detection position.
【請求項2】撮像手段からの2次元映像信号をディジタ
ル化し、 被検査画像の特徴的なパターンの任意サイズを切り出し
基準画像として予めメモリに記憶した画像データを出力
可能な基準画像記憶手段と、 2次元被検査画像データの任意数dyの水平走査ラインを
マイクロコンピュータから設定された分だけ保持可能な
(VS−1)個数の水平走査ライン保持手段を水平走査ラ
イン間隔k(1≦k≦dy)で均等に間を置いたVS行の個
々の検査画像位置に対応した被検査画像データが同時に
出力されるようにした垂直画像データ抽出手段と、 前記垂直画像データ抽出手段からの被検査画像データの
VS個の同時出力を水平方向の任意の画素dxまでをマイク
ロコンピュータから設定された画素分だけ保持可能な画
素シフト手段を(HS−1)個直列につなぐことで、1水
平方向の被検査画像データが同時にある設定された画素
j(1≦j≦dx)間隔で均等に間を置いたHSヵ所から同
時に出力されるようにしたものを前記垂直画像データ抽
出手段からVS個の水平走査ラインから同時に出力された
被検査画像データを入力として、前記(HS−1)個直列
画素シフト手段をVS段設ける事で2次元被検査画像デー
タの統計VS×HS地点の個々の検査座標位置に対応した被
検査画像データを同時に出力されるようにした水平画像
データ抽出手段と、 前記基準画像記憶手段からの画像データと前記水平画像
データ抽出手段からの個々の検査座標位置に対応した被
検査画像パターンデータを同時にパターン比較するVS×
HS個の排他的論理和からなる個々の検査座標位置に対応
したパターン照合出力をVS×HS個同時に合致パルスとし
て個々の検査座標位置に対応した排他的論理和手段より
出力することからなる論理演算手段と、 前記論理演算手段からの個々の検査座標位置に対応し
た各合致パルス出力を個々に同時カウントすることによ
りVS×HS個のパターン照合を1画像走査で完了し個々の
検査座標位置に対応した部分で独立に算出保持する相関
値積算手段と、 前記相関値積算手段の相関値データをマイクロコンピュ
ータより事前に設定されたパターン検出スレッシュ値と
の大小を同時に比較判定することで候補点におけるパタ
ーン照合状態を検出できるように、前記相関値積算手段
のデータ出力と、保持した検出スレッシュ値とを比較
し、個々の検査座標位置に対応した座標位置との間で大
小を同時に比較判定し、その結果を保持する個々の検査
座標位置に対応した保持手段をVS×HS個の個々の検査座
標位置に対応した分だけ設けることとし、マイクロコン
ピュータには1水平走査ラインHSヵ所の比較結果を一ま
とめにしマイクロコンピュータ1回の読み込みで1水平
走査ラインの各パターン照合位置の状態を把握できるよ
うに状態を保持した手段を垂直パターン照合のVS本だけ
設けることで、各1水平走査ラインの各パターン照合位
置の状態を把握しその演算対応位置の特定を行えるよう
にした水平候補点検出手段により構成され、 第1回目の粗検出は水平画像データ抽出手段・垂直画像
データ抽出手段をそれぞれの第1回目のパターン照合の
画素間隔でVS×HS個の被検査画像データが同時に出力さ
れるように設定し、被検査画像の検出範囲の中心位置に
VS行×HS列の検査位置の中心部が対応するように配置し
て第1回目の粗検出を行い、前記水平候補点検出手段に
より第1回目の粗検出の後マイクロコンピュータより事
前に設定された第1回目の粗検出スレッシュ値を超える
検出位置の候補点が存在するかを調べ、存在していた場
合に存在を示している水平比較ラインの前記水平候補点
検出手段の情報を読みこみ、前記情報に対応するパター
ン照合座標位置における相関値を保持している手段よ
り、第1回目のパターン照合を行った複数の候補点の相
関カウント値の中で最大相関値を保持する部分に対応し
たパターン照合座標位置をもって、次回のパターン照合
座標の中心座標位置と決定し、前回第1回目の粗検出に
て求めた最高相関値の座標位置を中心にVS行×HS列の検
査位置の中心部が対応するように配置し、第2目の粗検
出を水平方向は{第1の画素間隔−第2の画素間隔×
(HS−1)/2}≦0を、垂直方向は{第1の画素間隔−
第2の画素間隔×(VS−1)/2}≦0を、満たす第2画
素間隔にてVS行×HS列の中心部が対応するように配置し
て行い前記水平候補点検出手段からマイクロコンピュー
タより第1回目の粗検出の後に設定された第2回目用の
粗検出スレッシュ値より大きくなった第2回目の複数の
候補点の相関データの最高相関値の座標位置を求め、前
記第2回目の粗検出にて求めた最高値位置座標を中心に
VS行×HS列の中心部を配置して第3回目以降のパターン
照合を1画素間隔にて行うまで水平方向は{第P回目の
パターン照合の画素間隔−第P+1回目のパターン照合
の画素間隔×(HS−1)/2}≦0を、垂直方向は{第P
回目のパターン照合の画素間隔−第P+1回目のパター
ン照合の画素間隔×(VS−1)/2}≦0を、満たす第P
+1回目のパターン照合の画素間隔にてVS行×HS列の中
心部を配置して行い、前記水平候補点検出手段からマイ
クロコンピュータよりパターン照合を1画素間隔にて行
った第P+1回目用の検出スレッシュ値より大きくなっ
た第P+1回目の単一あるいは複数の候補点の相関デー
タの最大値を持つ座標位置を検出位置とすることを特徴
とするパターン認識方法。
2. A reference image storage means for digitizing a two-dimensional video signal from an imaging means, extracting an arbitrary size of a characteristic pattern of an image to be inspected, and outputting image data previously stored in a memory as a reference image, A (VS-1) number of horizontal scanning line holding means capable of holding an arbitrary number dy of horizontal scanning lines of the two-dimensional inspection image data by an amount set by the microcomputer has a horizontal scanning line interval k (1 ≦ k ≦ dy). Vertical image data extracting means for simultaneously outputting the inspected image data corresponding to the individual inspected image positions of the VS rows evenly spaced by the above); and the inspected image data from the vertical image data extracting means. of
By connecting in series (HS-1) pixel shift means capable of holding VS simultaneous outputs up to an arbitrary pixel dx in the horizontal direction by the number of pixels set by the microcomputer, an image to be inspected in one horizontal direction is obtained. Data obtained by simultaneously outputting data from HS locations evenly spaced at a set pixel j (1 ≦ j ≦ dx) interval from the vertical image data extraction means from VS horizontal scanning lines With the image data to be inspected output at the same time as input, by providing the (HS-1) serial pixel shift means in the VS stage, it is possible to correspond to each inspection coordinate position of the statistical VS × HS point of the two-dimensional image data to be inspected. Horizontal image data extracting means for simultaneously outputting image data to be inspected, image data from the reference image storing means, and inspected parts corresponding to individual inspection coordinate positions from the horizontal image data extracting means. VS × for pattern comparison image pattern data at the same time
A logical operation consisting of outputting pattern matching output corresponding to each inspection coordinate position composed of HS exclusive ORs as VS × HS simultaneous coincidence pulses from the exclusive OR means corresponding to each inspection coordinate position. VS × HS pattern matching is completed in one image scan by simultaneously counting each coincident pulse output corresponding to each inspection coordinate position from the logical operation means and corresponding to each inspection coordinate position. A correlation value integrating means for independently calculating and holding the calculated value, and a pattern at a candidate point by simultaneously comparing and determining the correlation value data of the correlation value integrating means with a pattern detection threshold value set in advance by a microcomputer. The data output of the correlation value accumulating means is compared with the held detection threshold value so that a matching state can be detected. At the same time, the magnitude is compared and determined between the corresponding coordinate positions, and the holding means corresponding to each inspection coordinate position for holding the result is provided only for the number corresponding to VS × HS individual inspection coordinate positions, The microcomputer uses the means for compiling the comparison results of one horizontal scanning line HS at a time to maintain the state so that the state of each pattern matching position of one horizontal scanning line can be grasped by one reading of the microcomputer. By providing only VS lines, it is constituted by horizontal candidate point detecting means capable of grasping the state of each pattern matching position of each horizontal scanning line and specifying the position corresponding to the calculation, and the first coarse detection The image data extraction means / vertical image data extraction means simultaneously output VS × HS inspection image data at the pixel interval of the first pattern matching. And sea urchin set, the center position of the detection range of the inspection image
The first coarse detection is performed by arranging the inspection positions of VS rows × HS columns so as to correspond to each other, and is set in advance by the microcomputer after the first coarse detection by the horizontal candidate point detecting means. It checks whether there is a candidate point at the detection position exceeding the first coarse detection threshold value, and reads the information of the horizontal candidate point detection means of the horizontal comparison line indicating the existence if it exists, The means for holding the correlation value at the pattern matching coordinate position corresponding to the information corresponds to the part holding the maximum correlation value among the correlation count values of the plurality of candidate points for which the first pattern matching was performed. The pattern matching coordinate position is determined as the center coordinate position of the next pattern matching coordinate, and the center of the inspection position of VS rows × HS columns centering on the coordinate position of the highest correlation value obtained in the previous first coarse detection. Corresponds Place manner, the horizontal direction of the second grain roughness detection {first pixel interval - the second pixel interval ×
(HS-1) / 2} ≦ 0, and the vertical direction is {first pixel interval−
The second pixel interval × (VS−1) / 2} ≦ 0 is arranged such that the center of the VS row × HS column corresponds to the second pixel interval satisfying the second pixel interval × (VS−1) / 2} ≦ 0. The computer obtains the coordinate position of the highest correlation value of the correlation data of a plurality of second candidate points that has become larger than the second coarse detection threshold value set after the first coarse detection and obtains the second coordinate value. Centering on the highest value position coordinates obtained in the second coarse detection
The horizontal direction is the pixel interval of the P-th pattern matching minus the pixel interval of the P + 1-th pattern matching until the center part of the VS row × HS column is arranged and the third and subsequent pattern matchings are performed at one-pixel intervals. × (HS-1) / 2} ≦ 0, the vertical direction is {Pth
The pixel interval of the first pattern matching−the pixel interval of the (P + 1) th pattern matching × (VS−1) / 2} ≦ 0.
The center of VS rows × HS columns is arranged at the pixel interval of the + 1st pattern matching, and the microcomputer performs pattern matching at the 1st pixel interval from the horizontal candidate point detecting means by the microcomputer. A pattern recognition method characterized by using, as a detection position, a coordinate position having a maximum value of correlation data of a (P + 1) th single or a plurality of candidate points that has become larger than a threshold value.
【請求項3】被検査画像を撮像する撮像装置の2次元映
像信号をディジタル化する2値化回路と、 特徴的パターンをメモリ記憶容量範囲内の任意サイズで
切り出し基準画像として予めメモリに記憶した画像デー
タを出力する基準画像記憶回路と、 前記2値化回路からの2値化被検査画像データを任意の
水平走査ラインをマイクロコンピュータからの指示で任
意に設定された分だけ保持可能な水平走査ライン・シフ
トレジスタで構成され前記2値化回路とで2値化画像の
垂直方向に設定された任意の水平走査ライン間隔で均等
に間を置いた検査座標位置に対応した被検査画像データ
を同時に出力する垂直画像データ抽出回路と、 前記垂直画像データ抽出回路からの2値化被検査画像デ
ータの出力を水平方向の任意画素をマイクロコンピュー
タからの指示で任意に設定された画素分だけ保持可能な
可変長画素・シフトレジスタを複数個直列につなぐこと
で1水平方向の2値化被検査画像データが同時にある設
定された画素間隔で均等に間を置いた複数ヵ所から同時
に出力されるように前記垂直抽出回路からの水平走査ラ
インから同時に出力された2値化被検査画像データを入
力として前記直列の可変長画素・シフトレジスタを設け
前記2値化画像の各地点の検査座標位置に対応した2値
化被検査画像データを同時に出力されるようにした水平
画像データ抽出回路と、 前記基準画像記憶回路からの基準画像データと前記水平
画像データ抽出回路からの個々の検査座標位置に対応し
た被検査画像パターンデータを同時にパターン比較する
排他的論理和回路からなる個々の検査座標位置に対応し
たパターン照合出力を同時に合致パルスとして各検査座
標位置に対応した排他的論理和部より出力することから
なる論理演算回路と、及び前記論理演算回路からの個々
の検査座標位置に対応した各合致パルス出力を個々に同
時カウントすることにより複数個のパターン照合を1フ
ィールドで完了し個々の検査座標位置に対応した部分で
独立に算出保持する相関値積算回路を具備し、2次元画
像中の特定パターンを自動抽出して座標位置を検出位置
とすることを特徴とするパターン認識装置。
3. A binarizing circuit for digitizing a two-dimensional video signal of an image pickup apparatus for picking up an image to be inspected, and a characteristic pattern cut out in an arbitrary size within a memory storage capacity range and previously stored in a memory as a reference image. A reference image storage circuit for outputting image data; and a horizontal scan capable of holding an arbitrary number of horizontal scan lines of the binarized image data to be inspected from the binarization circuit, arbitrarily set by an instruction from the microcomputer. The image data to be inspected corresponding to the inspection coordinate positions evenly spaced at an arbitrary horizontal scanning line interval set in the vertical direction of the binarized image by the binarization circuit, which is constituted by a line shift register, simultaneously with the binarization circuit. A vertical image data extraction circuit for outputting, and a microcomputer for outputting an arbitrary pixel in the horizontal direction from the output of the binary image data to be inspected from the vertical image data extraction circuit. By connecting a plurality of variable-length pixels and shift registers that can hold only the pixels set arbitrarily according to these instructions in series, one horizontal binarized image data to be inspected is simultaneously distributed at a set pixel interval. The serial variable-length pixel shift register is provided with the binary inspected image data simultaneously output from the horizontal scanning line from the vertical extraction circuit as an input so as to be simultaneously output from a plurality of locations spaced apart from each other. A horizontal image data extraction circuit configured to simultaneously output binarized image data to be inspected corresponding to an inspection coordinate position at each point of the binarized image; reference image data from the reference image storage circuit and the horizontal image Each of the inspection coordinate positions formed by an exclusive OR circuit for simultaneously performing pattern comparison of the inspected image pattern data corresponding to the individual inspection coordinate positions from the data extraction circuit. A logical operation circuit for simultaneously outputting the matched pattern matching output as a coincidence pulse from the exclusive OR unit corresponding to each inspection coordinate position, and each coincidence pulse corresponding to each inspection coordinate position from the logical operation circuit A correlation value integration circuit that completes a plurality of pattern comparisons in one field by simultaneously counting the outputs individually, and independently calculates and holds a portion corresponding to each inspection coordinate position, includes a specific pattern in a two-dimensional image. A pattern recognition device characterized by automatically extracting a coordinate position and using a coordinate position as a detection position.
【請求項4】撮像装置からの2次元映像信号をディジタ
ル化する2値化回路と、 被検査画像の特徴的なパターンをメモリの記憶容量範囲
内の任意サイズとして切り出し基準画像として予めメモ
リに記憶した画像データを出力可能な基準画像記憶回路
と、 前記2値化回路からの2値化された被検査画像データを
任意水平走査ラインまでをマイクロコンピュータからの
指示で任意に設定された分だけ保持可能な水平走査ライ
ン・シフトレジスタ(VS−1)個で構成され前記(VS−
1)個の水平走査ライン・シフトレジスタと前記第2値
化回路とで2値化画像の垂直方向に設定された水平走査
ライン(1≦k≦dx)間隔(但しkは画素間隔)で均等
に間を置いた複数行VSの個々の検査座標位置に対応した
被検査画像データが同時に出力されるようにした垂直画
像データ抽出回路と、 前記垂直画像データ抽出回路からの2値化された被検査
画像データのVS個の同時出力を水平方向の任意の画素ま
でをマイクロコンピュータからの指示で任意に設定され
た画素分だけ保持可能な可変長画像シフトレジスタを
(HS−1)個直列につなぐことで1水平方向の2値化さ
れた被検査画像データが同時にある設定された画素(1
≦j≦dy)間隔(但しjは画素間隔)で均等に間を置い
たHSヵ所から同時に出力されるようにしたものを前記垂
直画像データ抽出回路からのVS個の水平走査ラインから
同時に出力された2値化被検査画像データを入力として
前記(HS−1)個直列の可変長画像シフトレジスタをVS
段設ける事で前記2値化画像の総計VS×HS地点の個々の
検査座標位置に対応した2値化被検査画像データを同時
に出力されるようにした水平画像データ抽出回路と、 前記基準画像記憶回路からの画像データと前記水平画像
データ抽出回路からの個々の検査座標位置に対応した被
検査画像データを同時にパターン比較するVS×HS個の排
他的論理和回路からなる個々の検査座標位置に対応した
パターン照合出力をVS×HS個同時に合致パルスとして個
々の検査座標位置に対応した排他的論理和部より出力す
ることからなる論理演算回路と、 前記論理演算回路からの個々の検査座標位置に対応した
各合致パルス出力を個々に同時カウントすることにより
VS×HS個のパターン照合を1フィールドで完了し個々の
検査座標位置に対応した部分で独立に算出保持する相関
値積算回路と、 前記相関値積算回路の相関値データをマイクロコンピュ
ータより事前に設定されたパターン検出スレッシュ値と
の大小を比較判定することで候補点におけるパターン照
合状態を検出できるように前記相関値積算回路の出力を
個々の検査座標位置に対応したコンパレータを設け検出
スレッシュ値を保持し個々の検査座標位置に対応したラ
ッチとの間で大小を同時に比較判定し、その結果を保持
する個々の検査座標位置に対応したラッチをVS×HS個の
検査座標位置に対応した分だけ設けることとしマイクロ
コンピュータには1水平走査ラインHSヵ所の比較結果を
一まとめにしマイクロコンピュータの1回の読み込みで
1水平走査ラインの各パターン照合状態を把握できるよ
うにしたラッチ部を垂直パターン照合のVS本だけ設ける
ことで各1水平走査ラインの各パターン照合状態を把握
できるようにしその演算対応位置の特定を行えるように
した水平候補点検出回路と、 前記水平候補点検出回路のVS本の水平走査ラインの各パ
ターン照合位置の状態を把握できるようにするためにマ
イクロコンピュータによる1回のデータ入力にて把握で
きるよう前記水平候補点検出回路のVS本の個々の検査座
標位置に対応した各ラッチ部の出力を個々の検査座標位
置に対応した各ラッチ部においてスレッシュ値よりも大
きかったラッチが1つでもあればその水平走査ラインの
状態を保持することでマイクロコンピュータに相関スレ
ッシュ値を超える水平相関ラインがあったことを知らせ
る候補点検出回路を具備し、単一あるいは複数の候補点
の相関データの最大値を持つ座標位置を検出位置とする
ことを特徴とするパターン認識装置。
4. A binarizing circuit for digitizing a two-dimensional video signal from an imaging device, and a characteristic pattern of an image to be inspected is arbitrarily sized within a storage capacity range of the memory and cut out and stored in a memory in advance as a reference image. A reference image storage circuit capable of outputting the converted image data, and holding the binarized image data to be inspected from the binarization circuit up to an arbitrary horizontal scanning line by an amount arbitrarily set according to an instruction from the microcomputer. (VS-1), which is composed of possible horizontal scanning line shift registers (VS-1).
1) The horizontal scanning line shift register (1 ≦ k ≦ dx) interval (where k is a pixel interval) set in the vertical direction of the binarized image by the horizontal scanning line shift registers and the second binarization circuit are equal. A vertical image data extraction circuit configured to simultaneously output inspected image data corresponding to individual inspection coordinate positions of a plurality of rows VS, and a binarized image data from the vertical image data extraction circuit. (HS-1) serially connected variable-length image shift registers capable of holding VS simultaneous output of inspection image data up to an arbitrary pixel in the horizontal direction by an arbitrary number of pixels set by an instruction from a microcomputer As a result, the image data to be inspected which has been binarized in one horizontal direction is simultaneously present in a set pixel (1
.Ltoreq.j.ltoreq.dy, which are simultaneously output from the HS locations evenly spaced at intervals (where j is the pixel interval) are simultaneously output from the VS horizontal scanning lines from the vertical image data extraction circuit. The (HS-1) serial variable-length image shift registers are connected to the VS
A horizontal image data extraction circuit for simultaneously outputting binarized image data to be inspected corresponding to individual inspection coordinate positions of a total VS × HS point of the binary image by providing a stage; and storing the reference image. The image data from the circuit and the image data to be inspected corresponding to the individual inspection coordinate positions from the horizontal image data extraction circuit are simultaneously subjected to pattern comparison. A logical operation circuit that outputs the VS × HS matched pattern outputs as simultaneous coincidence pulses from an exclusive OR unit corresponding to each inspection coordinate position, and corresponds to each inspection coordinate position from the logical operation circuit. By simultaneously counting each matched pulse output individually,
A correlation value integrating circuit that completes VS × HS pattern matching in one field and independently calculates and holds the portion corresponding to each inspection coordinate position, and sets in advance the correlation value data of the correlation value integrating circuit from a microcomputer. The output of the correlation value integration circuit is provided with a comparator corresponding to each inspection coordinate position so that a pattern matching state at a candidate point can be detected by comparing and judging the magnitude of the detected pattern detection threshold value and holding the detection threshold value. At the same time, the magnitudes are compared and determined with the latches corresponding to the individual inspection coordinate positions, and the latches corresponding to the individual inspection coordinate positions that hold the results are provided in an amount corresponding to the VS × HS inspection coordinate positions. The microcomputer collects the comparison results of one horizontal scanning line HS location and collects one horizontal scanning line by one reading of the microcomputer. By providing only VS latches for vertical pattern matching, which are capable of ascertaining the pattern matching state of each scanning line, it is possible to ascertain the pattern matching state of each horizontal scanning line and to specify the position corresponding to the operation. A horizontal candidate point detection circuit, and a single data input by a microcomputer so that the state of each pattern matching position of VS horizontal scanning lines of the horizontal candidate point detection circuit can be ascertained. If the output of each latch unit corresponding to the VS individual inspection coordinate positions of the horizontal candidate point detection circuit is larger than the threshold value in any one of the latch units corresponding to the individual inspection coordinate positions, if there is at least one latch, By maintaining the state of the horizontal scan line, the microcomputer is notified that there is a horizontal correlation line exceeding the correlation threshold value. That includes the candidate point detecting circuit, a pattern recognition device which is characterized in that the detected position coordinate position having the maximum value of the correlation data for a single or a plurality of candidate points.
JP2216559A 1990-08-16 1990-08-16 Pattern recognition method and apparatus Expired - Lifetime JP3007392B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2216559A JP3007392B2 (en) 1990-08-16 1990-08-16 Pattern recognition method and apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2216559A JP3007392B2 (en) 1990-08-16 1990-08-16 Pattern recognition method and apparatus

Publications (2)

Publication Number Publication Date
JPH0498580A JPH0498580A (en) 1992-03-31
JP3007392B2 true JP3007392B2 (en) 2000-02-07

Family

ID=16690333

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2216559A Expired - Lifetime JP3007392B2 (en) 1990-08-16 1990-08-16 Pattern recognition method and apparatus

Country Status (1)

Country Link
JP (1) JP3007392B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005227931A (en) * 2004-02-12 2005-08-25 Keyence Corp Image processing apparatus

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH064672A (en) * 1992-05-08 1994-01-14 Sanyo Electric Co Ltd Pattern matching circuit
JPH0668264A (en) * 1992-08-21 1994-03-11 Takayama:Kk Pattern matching circuit
JP2013218476A (en) * 2012-04-06 2013-10-24 Denso Corp Image recognition device

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005227931A (en) * 2004-02-12 2005-08-25 Keyence Corp Image processing apparatus
US7982779B2 (en) 2004-02-12 2011-07-19 Keyence Corporation Image processing device and image processing method

Also Published As

Publication number Publication date
JPH0498580A (en) 1992-03-31

Similar Documents

Publication Publication Date Title
EP0145725B1 (en) Method of and apparatus for real-time high-speed inspection of objects for identifying or recognizing known and unknown portions thereof, including defects and the like
US5796868A (en) Object edge point filtering system for machine vision
US4545067A (en) Process for automatic image recognition
US8363983B2 (en) Real-time face detection apparatus
JPS5839357B2 (en) Pattern position detection method
JPS5916081A (en) Method and apparatus for processing visible video and regulating corner points in visible video processing system
JPH1166325A (en) Method and device for determining boundary of object and recording medium recording boundary determination program for object
JP3007392B2 (en) Pattern recognition method and apparatus
US5321772A (en) Digital image processor
JP2720590B2 (en) Pattern recognition device
JPH0754549B2 (en) How to create a standard pattern for pattern matching
JPH08101893A (en) Model image data registering device for image processor
JPS6341107B2 (en)
JP3016687B2 (en) Image processing device
EP0380090A2 (en) Image processing system
JPS623475B2 (en)
JP2709301B2 (en) Striation light extraction circuit
KR100295245B1 (en) A parallel thinning method using weighted value
JP2000231640A (en) Method and device for deciding boundary of article
EP0428624A1 (en) Intelligent scan image processor
JP2846173B2 (en) Image processing device
EP0635803A2 (en) A method and an apparatus for image processing
JPS63282889A (en) Image processing method
JPH0798763A (en) Method and device for processing image
JP2690936B2 (en) Digital image analyzer