JPH07220026A - Method and device for picture processing - Google Patents

Method and device for picture processing

Info

Publication number
JPH07220026A
JPH07220026A JP6027525A JP2752594A JPH07220026A JP H07220026 A JPH07220026 A JP H07220026A JP 6027525 A JP6027525 A JP 6027525A JP 2752594 A JP2752594 A JP 2752594A JP H07220026 A JPH07220026 A JP H07220026A
Authority
JP
Japan
Prior art keywords
image data
window
index value
image
affine
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP6027525A
Other languages
Japanese (ja)
Inventor
Masahiro Kawachi
雅弘 河内
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Omron Corp
Original Assignee
Omron Corp
Omron Tateisi Electronics Co
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 Omron Corp, Omron Tateisi Electronics Co filed Critical Omron Corp
Priority to JP6027525A priority Critical patent/JPH07220026A/en
Publication of JPH07220026A publication Critical patent/JPH07220026A/en
Pending legal-status Critical Current

Links

Abstract

PURPOSE:To provide the method and the device for picture processing where the number of classifications of models to be preliminarily registered is small and the size, the angle of inclination, and the position of an object are determined with a small memory capacity. CONSTITUTION:Picked-up image data obtained from a camera 1 is expanded/ reduced or rotated by an affine transformation circuit 4 and is given to a search measuring circuit 7. This circuit 7 calculates the mutual correlation value between partial image data in a window and preliminarily registered model image data while scanning the window on transformed image data. The processing is repeated plural times while changing the value of the transformation parameter. The size, the angle of inclination, and the position of the object are determined based on the position of the window and the transformation parameter which bring about the highest mutual correlation value.

Description

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

【0001】[0001]

【技術分野】この発明は,対象物の画像データをあらか
じめ登録されたモデル画像データと照合することによ
り,対象物の認識,対象物の位置の計測等を行う画像処
理装置および方法に関する。
TECHNICAL FIELD The present invention relates to an image processing apparatus and method for recognizing an object, measuring the position of the object, and the like by collating the image data of the object with pre-registered model image data.

【0002】[0002]

【背景技術】対象物を撮像することによって得られた画
像データ上をウィンドウを走査し,ウィンドウ内の部分
画像データと,あらかじめメモリに記憶されている登録
モデルの画像データとの類似度(たとえば相互相関値)
を算出し,対象物の認識や対象物の位置の計測等を行う
画像処理装置が知られている。類似度が最も高い(相互
相関値が最も高い)部分画像データを検出することによ
り,登録モデルと同一または類似物が存在する位置を認
識することが可能となる。
BACKGROUND ART A window is scanned over image data obtained by picking up an image of an object, and the partial image data in the window is similar to the image data of a registered model stored in a memory in advance (for example, mutual image data). Correlation value)
There is known an image processing device that calculates a value of the object, recognizes the object, measures the position of the object, and the like. By detecting the partial image data with the highest degree of similarity (the highest cross-correlation value), it is possible to recognize the position where the same or similar object as the registered model exists.

【0003】しかしながら,同じ対象物であっても画像
の大きさが異なる場合,たとえば文字サイズが8ポイン
トの文字と12ポイントの文字が混っていたり,対象物と
の距離が変化する場合がある。このような種々の場合に
備えるため,大きさの異なるモデル画像データをあらか
じめ多数個用意しておく必要がある。
However, even if the same target object has different image sizes, for example, characters having a character size of 8 points and characters having a character size of 12 points may be mixed, or the distance to the object may change. . To prepare for such various cases, it is necessary to prepare a large number of model image data having different sizes in advance.

【0004】また,対象物が傾いているまたは回転して
いる場合,たとえば対象文字を印字した紙を斜めに置い
た状態で計測することもある。そのために様々な傾きを
もつモデル画像データを多数個用意しておく必要があ
る。
When the object is tilted or rotated, for example, the measurement may be performed with the paper on which the target character is printed placed obliquely. Therefore, it is necessary to prepare a large number of model image data having various inclinations.

【0005】このように,種々の大きさ,傾きのモデル
画像データをあらかじめ用意しなければならないので,
従来の画像処理装置では大きなメモリ容量を必要として
いた。より高い精度で計測を行なうためには,さらに多
くのモデル画像データを用意しておく必要がある。
As described above, since model image data of various sizes and inclinations must be prepared in advance,
A conventional image processing device requires a large memory capacity. In order to measure with higher accuracy, it is necessary to prepare more model image data.

【0006】さらに,傾いている,または移動している
対象物を認識する場合に,多数の傾き,大きさの異なる
モデル画像データを取替えながら複数回パターン・マッ
チング処理を行なわなくてはならないので,計測処理に
時間がかかるという問題もあった。
Further, when recognizing a tilted or moving object, it is necessary to perform pattern matching processing a plurality of times while exchanging a large number of model image data having different tilts and sizes. There is also a problem that the measurement process takes time.

【0007】[0007]

【発明の開示】この発明は,あらかじめ登録しておくモ
デル画像データの種類数が少なくなり,小さな容量のメ
モリですむようにすることを目的とする。
DISCLOSURE OF THE INVENTION An object of the present invention is to reduce the number of types of model image data to be registered in advance and to use a small capacity memory.

【0008】この発明はまた,より高速に画像処理を行
なうことができるようにするものである。
The present invention also makes it possible to perform image processing at a higher speed.

【0009】この発明による画像処理装置は,対象物を
撮像し,対象物を表わす画像データを出力する撮像手
段,上記撮像手段から出力される画像データによって表
わされる対象画像の拡大/縮小および回転の少なくとも
いずれか一方のために,所与の変換パラメータにしたが
って上記画像データを変換するアフィン変換手段,上記
アフィン変換手段によって変換された画像データ上をウ
ィンドウを走査しながら,ウィンドウ内の部分画像デー
タとあらかじめメモリに登録されているモデル画像デー
タとの類似度を表わす指標値を算出する類似度演算手
段,変換パラメータの値を変えながら上記アフィン変換
手段による変換処理および上記類似度演算手段による指
標値算出処理を複数回繰返すよう制御する手段,ならび
に算出された複数の指標値のうち最も高い類似度を示す
指標値を検出し,その指標値を生じさせるウィンドウの
位置および変換パラメータに基づいて,対象物の大き
さ,傾き角度および位置を決定する位置決定手段を備え
ている。
An image processing apparatus according to the present invention includes an image pickup means for picking up an image of an object and outputting image data representing the object, and enlargement / reduction and rotation of the object image represented by the image data output from the image pickup means. Affine transforming means for transforming the image data according to a given transformation parameter for at least one of them, and partial image data in the window while scanning the window over the image data transformed by the affine transforming means. Similarity calculation means for calculating an index value representing the similarity with the model image data registered in the memory in advance, conversion processing by the affine conversion means while changing the value of the conversion parameter, and index value calculation by the similarity calculation means A means for controlling the process to be repeated a plurality of times, and a plurality of calculated fingers A position determining means for detecting the index value indicating the highest similarity among the values and determining the size, the tilt angle, and the position of the object based on the position of the window and the conversion parameter that generate the index value are provided. There is.

【0010】この発明による画像処理方法は,対象物を
表わす画像データを受付け,受付けた画像データが表わ
す対象画像の拡大/縮小および回転の少なくともいずれ
か一方のために,所与の変換パラメータにしたがって画
像データをアフィン変換し,アフィン変換された画像デ
ータ上をウィンドウを走査しながら,ウィンドウ内の部
分画像データとあらかじめメモリに登録しているモデル
画像データとの類似度を表わす指標値を算出し,変換パ
ラメータの値を変えながら上記アフィン変換処理および
上記類似度演算処理を複数回繰返し,算出した複数の指
標値のうち最も高い類似度を示す指標値を検出し,その
指標値を生じさせるウィンドウの位置および変換パラメ
ータに基づいて,対象物の大きさ,傾き角度および位置
を決定するものである。
According to the image processing method of the present invention, image data representing an object is received, and at least one of enlargement / reduction and rotation of the object image represented by the received image data is performed in accordance with a given conversion parameter. The image data is affine transformed, the window is scanned over the affine transformed image data, and the index value representing the similarity between the partial image data in the window and the model image data registered in the memory in advance is calculated. The affine transformation process and the similarity calculation process are repeated a plurality of times while changing the value of the conversion parameter, the index value showing the highest similarity among the calculated index values is detected, and the window for generating the index value is detected. It determines the size, tilt angle and position of the object based on the position and the transformation parameters. That.

【0011】この発明によると,入力された画像データ
をアフィン変換により拡大/縮小または回転させ,アフ
ィン変換された画像データから切出された部分画像デー
タとあらかじめ登録されているモデル画像データとの類
似度を表わす指標値を算出している。したがって,登録
しておくモデル画像データは一つのモデルについて一つ
で済み,モデル画像データを格納するために必要なメモ
リ容量を大巾に減少させることができる。これによっ
て,ハード・ウェアの小規模化やコストの低減等を図る
ことができる。
According to the present invention, the input image data is enlarged / reduced or rotated by affine transformation, and the partial image data cut out from the affine transformed image data is similar to the model image data registered in advance. An index value indicating the degree is calculated. Therefore, only one model image data needs to be registered for each model, and the memory capacity required to store the model image data can be greatly reduced. This makes it possible to reduce the size of hardware and reduce costs.

【0012】この発明はもう一つの画像処理装置を提供
している。この画像処理装置は,対象物を撮像し,対象
物を表わす画像データを出力する撮像手段,上記画像デ
ータに基づいて対象物の主軸角を算出する主軸角算出手
段,上記主軸角算出手段によって算出された主軸角にし
たがって上記画像データを回転させるアフィン変換手
段,上記アフィン変換手段によって回転された画像デー
タ上をウィンドウを走査しながら,ウィンドウ内の部分
画像データとあらかじめメモリに登録されているモデル
画像データとの類似度を表わす指標値を算出する類似度
演算手段,および算出された複数の指標値のうち最も高
い類似度を示す指標値を検出し,その指標値を生じさせ
るウィンドウの位置に基づいて対象物の位置を決定する
位置決定手段を備えている。
The present invention provides another image processing apparatus. This image processing apparatus captures an image of an object and outputs image data representing the object, a main axis angle calculating means for calculating a main axis angle of the object based on the image data, and a main axis angle calculating means for calculating the main axis angle. Affine transformation means for rotating the image data in accordance with the determined main axis angle, window scanning over the image data rotated by the affine transformation means, and partial image data in the window and model image registered in advance in the memory Similarity calculating means for calculating an index value indicating the similarity to the data, and an index value showing the highest similarity among the calculated plurality of index values is detected, and based on the position of the window causing the index value. Position determining means for determining the position of the object.

【0013】この発明によるもう一つの画像処理方法
は,対象物を表わす画像データを受付け,受付けた画像
データに基づいて対象物の主軸角を算出し,算出した主
軸角にしたがってアフィン変換することによって回転さ
れた画像データを得,回転された画像データ上をウィン
ドウを走査しながら,ウィンドウ内の部分画像データと
あらかじめメモリに登録しているモデル画像データとの
類似度を表わす指標値を算出し,算出された複数の指標
値のうち最も高い類似度を示す指標値を検出し,その指
標値を生じさせるウィンドウの位置に基づいて対象物の
位置を決定するものである。
Another image processing method according to the present invention is to receive image data representing an object, calculate a principal axis angle of the object based on the received image data, and perform affine transformation according to the calculated principal axis angle. Obtain the rotated image data, scan the window over the rotated image data, and calculate the index value that represents the degree of similarity between the partial image data in the window and the model image data registered in the memory in advance. The index value showing the highest degree of similarity among the calculated index values is detected, and the position of the object is determined based on the position of the window that causes the index value.

【0014】この発明によると,対象物の主軸角を算出
することにより,アフィン変換のための回転角度を定め
ている。対象物の傾きが分るから,回転角度を変えなが
ら複数回にわたってアフィン変換する必要がなくなり,
1回のアフィン変換で済むので,計測処理に要する時間
の短縮を図ることができる。
According to the present invention, the rotation angle for affine transformation is determined by calculating the principal axis angle of the object. Since the inclination of the object is known, it is not necessary to perform affine transformation multiple times while changing the rotation angle,
Since only one affine transformation is required, the time required for measurement processing can be shortened.

【0015】[0015]

【実施例】【Example】

第1実施例 First embodiment

【0016】図1は,画像処理装置の電気的構成を示す
ブロック図である。
FIG. 1 is a block diagram showing the electrical construction of the image processing apparatus.

【0017】画像処理装置は,カメラ1,A/D変換回
路2,タイミング発生回路3,アフィン変換回路4,メ
モリ・インターフェイス5,画像メモリ6,サーチ計測
回路7,メモリ・インターフェイス8,モデル画像メモ
リ9,中央処理装置(CPU)10,I/O制御回路11,
および記憶装置12(たとえばROMやRAM)を含んで
いる。タイミング発生回路3は,クロック信号,各種同
期信号を発生して上述の各回路の動作の同期をとる。C
PU10は画像処理装置に含まれる各回路の動作を統括す
る。
The image processing apparatus includes a camera 1, an A / D conversion circuit 2, a timing generation circuit 3, an affine conversion circuit 4, a memory interface 5, an image memory 6, a search measurement circuit 7, a memory interface 8, and a model image memory. 9, central processing unit (CPU) 10, I / O control circuit 11,
And a storage device 12 (eg ROM or RAM). The timing generation circuit 3 generates a clock signal and various synchronization signals to synchronize the operation of each circuit described above. C
The PU 10 controls the operation of each circuit included in the image processing apparatus.

【0018】カメラ1によって撮像された対象物を表わ
すアナログ映像信号は,A/D変換回路2に与えられ
る。A/D変換回路2は入力するアナログ映像信号をデ
ィジタル画像データに変換する。このディジタル画像デ
ータはアフィン変換回路4,メモリ・インターフェイス
5を通って画像メモリ6に蓄えられる。
An analog video signal representing an object picked up by the camera 1 is given to the A / D conversion circuit 2. The A / D conversion circuit 2 converts the input analog video signal into digital image data. This digital image data is stored in the image memory 6 through the affine transformation circuit 4 and the memory interface 5.

【0019】アフィン変換回路4は,対象物を表わす画
像データを拡大/縮小しまたは回転させるためのもので
あり,画像メモリ6から読出す画像データのアドレス
を,与えられた変換パラメータにしたがって算出する。
このアドレスにしたがって画像データが画像メモリ6か
ら読出されることにより,読出される画像データは実質
的にアフィン変換される。変換パラメータは,後述する
変換後の座標原点(走査開始座標値)(x0 ,y0 ),
拡大/縮小倍率k,および回転角度θの3つであり,C
PU10から与えられる。
The affine transformation circuit 4 is for enlarging / reducing or rotating the image data representing the object, and calculates the address of the image data read from the image memory 6 according to the given transformation parameter. .
By reading the image data from the image memory 6 according to this address, the read image data is substantially affine-transformed. The conversion parameters are the coordinate origin (scan start coordinate value) (x 0 , y 0 ) after conversion, which will be described later.
There are three enlargement / reduction ratios k and rotation angle θ, and C
Given by PU10.

【0020】モデル画像メモリ9には,標準的な対象物
を表わす画像データ(モデル画像データ)があらかじめ
格納されている。モデル画像データに代えて対象物の標
準的な特徴パラメータを格納してもよい。いずれにして
もモデル画像メモリ9に格納される登録データは,サー
チ計測(パターン・マッチング)処理の種類に応じて定
めればよい。
Image data (model image data) representing a standard object is stored in the model image memory 9 in advance. Standard feature parameters of the object may be stored instead of the model image data. In any case, the registration data stored in the model image memory 9 may be determined according to the type of search measurement (pattern matching) processing.

【0021】サーチ計測回路7は,画像メモリ6から読
出されアフィン変換された画像データ上でウィンドウを
走査し,順次切出されるウィンドウ内の部分画像データ
と,モデル画像メモリ9に格納されているモデル画像デ
ータとの類似性の程度を表す指標値を算出する。この指
標値はたとえば,部分画像データとモデル画像データと
の相互相関値である。この指標値に基づいて対象物の認
識または対象物の位置の計測が行われる。
The search measurement circuit 7 scans a window on the image data read from the image memory 6 and affine-transformed, and the partial image data in the window sequentially cut out and the model stored in the model image memory 9 are scanned. An index value indicating the degree of similarity to the image data is calculated. This index value is, for example, a cross-correlation value between the partial image data and the model image data. The object is recognized or the position of the object is measured based on this index value.

【0022】このサーチ計測処理は,変換パラメータの
値を変えることによって対象画像の大きさおよび傾きを
変化させながら,所定複数回繰返される。計測精度を高
くしたければこの繰返し回数を増やし,より小刻みに大
きさおよび傾きを変化させればよい。算出された複数の
指標値のうち最も高い類似度を示す指標値が検出され,
その指標値を生じさせる変換パラメータおよびウィンド
ウの位置により,対象物の大きさ,傾きおよび位置が決
定される。
This search measurement process is repeated a predetermined number of times while changing the size and inclination of the target image by changing the value of the conversion parameter. To increase the measurement accuracy, the number of repetitions can be increased and the size and slope can be changed in smaller steps. The index value showing the highest similarity among the calculated index values is detected,
The size, tilt and position of the object are determined by the conversion parameter and the position of the window that generate the index value.

【0023】サーチ計測処理の結果は,I/O制御回路
11を介してディスプレイやプリンタなどの外部装置へ出
力される。
The result of the search measurement process is the I / O control circuit.
It is output to an external device such as a display or a printer via 11.

【0024】図2は,アフィン変換によって拡大/縮小
した対象画像データを登録モデルとパターン・マッチン
グしている様子を,図3は,アフィン変換によって回転
した対象画像データを登録モデルとパターン・マッチン
グしている様子をそれぞれ示している。
FIG. 2 shows how the target image data enlarged / reduced by the affine transformation is pattern-matched with the registration model, and FIG. 3 is the target image data rotated by the affine transformation being pattern-matched with the registration model. It shows how each is doing.

【0025】大きさが異なったり変化する対象物や,傾
いているまたは回転している対象物を計測する場合,同
一の対象物であっても,大きさや傾きにあわせて登録モ
デル画像を複数個用意しなくてはならない。ここでは,
図2,図3に示すように,アフィン変換により対象画像
を拡大/縮小または回転させ,パターン・マッチング処
理が行われているので,登録すべきモデル画像は一つで
済む。
When measuring an object whose size is different or changing, or an object which is tilted or rotated, a plurality of registered model images are registered according to the size and the tilt even if the object is the same. I have to prepare. here,
As shown in FIGS. 2 and 3, since the target image is enlarged / reduced or rotated by the affine transformation and the pattern matching process is performed, only one model image needs to be registered.

【0026】図2において,入力対象画像を拡大したも
の,そのままのもの,および縮小したもののうち,縮小
したものが登録モデル画像に最も類似している。また図
3では,入力対象画像を右回転したもの,そのままのも
の,および左回転したもののうち,右回転したものが登
録モデル画像と最も類似している。
In FIG. 2, among the enlarged, unaltered, and reduced input target images, the reduced one is the most similar to the registered model image. Further, in FIG. 3, among the input target images rotated to the right, those that have been rotated, and those that have been rotated to the left, those rotated to the right are the most similar to the registered model image.

【0027】対象画像データのアフィン変換処理につい
て,図4を用いて説明する。
The affine transformation process of the target image data will be described with reference to FIG.

【0028】画像メモリ6に格納されている画像データ
を読出すアドレスを荒くすれば,読出される対象画像は
縮小され,細かくすれば拡大され,斜め方向に進ませれ
ば対象画像は傾くことになる。画像データのアフィン変
換はこの原理を応用したものである。
If the address for reading the image data stored in the image memory 6 is roughened, the target image to be read is reduced, if the address is read finely, the target image is enlarged, and if it is advanced diagonally, the target image is inclined. Become. Affine transformation of image data is an application of this principle.

【0029】図4に示すように,変換前の座標系をΑ
(アルファ)−Β(ベータ)直交座標系,変換後の座標
系をX−Y直交座標系とする。変換前の画像の画素の座
標を(α,β),変換後の画像の画素の座標を(x,
y),画像の回転の中心の座標を(αc ,βc )とする
と,行列式
As shown in FIG. 4, the coordinate system before conversion is
The (alpha) -B (beta) Cartesian coordinate system and the coordinate system after conversion are referred to as XY Cartesian coordinate systems. The pixel coordinates of the image before conversion are (α, β), and the pixel coordinates of the image after conversion are (x,
y) and the coordinates of the center of rotation of the image are (α c , β c ), the determinant

【数1】 で表現される点(α,β)から点(x,y)への変換を
アフィン変換という。ここで,kは拡大/縮小倍率,θ
は回転角度であり,画像データを拡大/縮小および回転
するための変換パラメータである。θ=0,すなわち-s
inθ=sin θ=0ならば回転はなく,画像は単に拡大/
縮小される。
[Equation 1] The transformation from the point (α, β) represented by the above to the point (x, y) is called affine transformation. Where k is the enlargement / reduction ratio, θ
Is a rotation angle, which is a conversion parameter for enlarging / reducing and rotating the image data. θ = 0, that is -s
If in θ = sin θ = 0, there is no rotation and the image is simply enlarged /
It is reduced.

【0030】座標原点の移動,すなわち変換後の座標原
点(x0 ,y0 )は,式
The movement of the coordinate origin, that is, the coordinate origin (x 0 , y 0 ) after conversion is expressed by

【数2】 で表現される。図4に示すように,変換後の座標原点
(x0 ,y0 )はウィンドウの走査開始位置を示す。
[Equation 2] It is expressed by. As shown in FIG. 4, the coordinate origin (x 0 , y 0 ) after conversion indicates the scanning start position of the window.

【0031】アフィン変換回路4は,拡大/縮小倍率
k,回転角度θ,および変換後の座標原点(走査開始座
標値)(x0 ,y0 )の3つの変換パラメータにしたが
って,画像メモリ6から読出すべき画像データのアドレ
ス,すなわち変換後の座標値(走査座標値)(x,y)
を自動的に順次算出するものである。算出されたアドレ
スにしたがって画像データが画像メモリ6から読出され
ることにより,読出される画像データは実質的に拡大/
縮小または回転されることになる。
The affine transformation circuit 4 reads from the image memory 6 in accordance with three transformation parameters of the enlargement / reduction scale factor k, the rotation angle θ, and the coordinate origin (scan start coordinate value) (x 0 , y 0 ) after transformation. Address of image data to be read, that is, coordinate value after conversion (scan coordinate value) (x, y)
Is automatically and sequentially calculated. By reading the image data from the image memory 6 in accordance with the calculated address, the read image data is substantially expanded / enlarged.
It will be reduced or rotated.

【0032】走査されるウィンドウの位置は,たとえば
ウィンドウの左上の角の点(「走査点」という)で表わ
される。ウィンドウは走査点(x0 ,y0 )の示す位置
から,拡大/縮小倍率kで,回転角度θの方向へ走査さ
れる。一般にウィンドウはラスタ方向へ,すなわち左上
から始まり,左から右へ,上から下へと走査される。ウ
ィンドウ内の部分画像データ(斜線に示す部分画像デー
タ)が順次切出される。切出された部分画像データは,
メモリ9にあらかじめ登録されている標準的なモデル
(モデル画像データ)と比較され,各走査点における類
似度を表わす指標値が算出される。
The position of the window to be scanned is represented, for example, by the point at the upper left corner of the window (referred to as "scan point"). The window is scanned from the position indicated by the scanning point (x 0 , y 0 ) at the enlargement / reduction ratio k in the direction of the rotation angle θ. In general, windows are scanned in the raster direction, that is, starting from the top left, from left to right, top to bottom. The partial image data in the window (partial image data indicated by diagonal lines) are sequentially cut out. The cut out partial image data is
It is compared with a standard model (model image data) registered in advance in the memory 9 to calculate an index value representing the degree of similarity at each scanning point.

【0033】図5は,一連の計測処理の流れを示すフロ
ー・チャートである。
FIG. 5 is a flow chart showing the flow of a series of measurement processing.

【0034】カメラ1によって対象物が撮像され,対象
物を表す画像データが画像メモリ6に格納される(ステ
ップ21)。アフィン変換のための3つのパラメータ,す
なわち走査開始座標値(x0 ,y0 ),拡大/縮小倍率
k,および回転角度θの初期値がCPU10によって設定
される(ステップ22)。一般的には,x0 =0,y0
0,k=1,θ=0,すなわちアフィン変換をしない条
件が設定されよう。
The object is imaged by the camera 1, and the image data representing the object is stored in the image memory 6 (step 21). Three parameters for the affine transformation, that is, the scanning start coordinate values (x 0 , y 0 ), the enlargement / reduction scale factor k, and the initial value of the rotation angle θ are set by the CPU 10 (step 22). Generally, x 0 = 0, y 0 =
0, k = 1, θ = 0, that is, the condition that affine transformation is not performed may be set.

【0035】サーチ計測処理回数をカウントするカウン
タi(最大回数N)が1に設定される(ステップ23)。
計測精度を上げるには,この最大回数Nを大きく設定す
ればよい。画像メモリ6から画像データが読出される過
程で設定された変換パラメータに基づくアフィン変換が
行なわれ(アフィン変換なしも含まれる)(アフィン変
換回路4),アフィン変換された画像データ上をウィン
ドウが走査されながら,ウィンドウが切出す部分画像デ
ータとモデル画像データとの相互相関値が算出される
(サーチ計測回路7)。最大の相互相関値と,その最大
相互相関関係を与えるウィンドウ位置とが記憶装置12に
記憶される(ステップ24)。
A counter i (maximum number N) for counting the number of times of search measurement processing is set to 1 (step 23).
In order to improve the measurement accuracy, this maximum number N should be set large. Affine transformation is performed based on the transformation parameters set in the process of reading the image data from the image memory 6 (including the case without affine transformation) (affine transformation circuit 4), and the window is scanned over the affine transformed image data. While doing so, the cross-correlation value between the partial image data cut out from the window and the model image data is calculated (search measurement circuit 7). The maximum cross-correlation value and the window position that gives the maximum cross-correlation are stored in the storage device 12 (step 24).

【0036】CPU10によって,カウンタiの値が最大
回数Nを超えたかどうかが判定され(ステップ25),超
えていない場合には,変換パラメータの値が変更される
(ステップ26)とともにカウンタiがインクリメントさ
れる(ステップ27)。対象画像の大きさや角度を変えな
がら,サーチ処理が繰返される(ステップ24,25,26,
27の繰返し)。
The CPU 10 determines whether or not the value of the counter i exceeds the maximum number N (step 25). If not, the value of the conversion parameter is changed (step 26) and the counter i is incremented. (Step 27). The search process is repeated while changing the size and angle of the target image (steps 24, 25, 26,
27 repetitions).

【0037】カウンタiの値が最大回数Nを超えると
(ステップ25),各サーチ処理で得られた最大相互相関
値のうちの最も大きい相互相関値が選ばれる(ステップ
28)。最大相互相関値の最大値が得られたときのウィン
ドウ位置,アフィン変換パラメータに基づいて,対象物
の大きさ,角度,位置が決定される(ステップ29)。
When the value of the counter i exceeds the maximum number N (step 25), the largest cross-correlation value among the maximum cross-correlation values obtained by each search process is selected (step 25).
28). The size, angle, and position of the object are determined based on the window position and the affine transformation parameter when the maximum cross-correlation value is obtained (step 29).

【0038】第2実施例Second embodiment

【0039】第2実施例は,カメラ1から入力された画
像データを2値化し,得られた2値画像データに基づい
て対象物の主軸角を算出し,求まった主軸角に応じてア
フィン変換のための回転角度θを定めるものである。
In the second embodiment, the image data input from the camera 1 is binarized, the principal axis angle of the object is calculated based on the obtained binary image data, and the affine transformation is performed according to the obtained principal axis angle. For determining the rotation angle θ.

【0040】図6は,第2実施例による画像処理装置の
電気的構成を示す。図1に示すものと同一物については
同一符号を付し,重複説明を避ける。
FIG. 6 shows the electrical construction of the image processing apparatus according to the second embodiment. The same parts as those shown in FIG. 1 are designated by the same reference numerals to avoid redundant description.

【0041】第2実施例では,2値化回路13,2値主軸
角計測回路14,メモリ・インターフェイス15,およびウ
ィンドウ・メモリ16が追加して設けられている。
In the second embodiment, a binarizing circuit 13, a binary spindle angle measuring circuit 14, a memory interface 15, and a window memory 16 are additionally provided.

【0042】2値化回路13は,A/D変換回路2から与
えられたディジタル画像データを2値化するものであ
る。
The binarization circuit 13 binarizes the digital image data supplied from the A / D conversion circuit 2.

【0043】2値主軸角計測回路14は,2値化された画
像データと,ウィンドウ・メモリ16に格納されているウ
ィンドウとを重合わせ,ウィンドウ内の主軸角を算出す
る。算出された主軸角に基づいて中央処理装置(CP
U)10がアフィン変換のための回転角度θを決定し,こ
の回転角度θがアフィン変換回路4に与えられる。主軸
角計測回路そのものは既に知られている。
The binary spindle angle measuring circuit 14 superimposes the binarized image data and the window stored in the window memory 16 and calculates the spindle angle in the window. Based on the calculated spindle angle, the central processing unit (CP
U) 10 determines the rotation angle θ for affine transformation, and this rotation angle θ is given to the affine transformation circuit 4. The spindle angle measuring circuit itself is already known.

【0044】図7は,第2実施例による計測処理の流れ
を示す。図5に示すものと同一の処理には同一の符号を
付してある。
FIG. 7 shows the flow of measurement processing according to the second embodiment. The same processes as those shown in FIG. 5 are designated by the same reference numerals.

【0045】対象物を表す画像データは画像メモリ6に
格納される(ステップ21)とともに,2値化回路13にお
いて2値化される(ステップ30)。2値化された画像デ
ータに基づいて対象物の主軸角が算出され(ステップ3
1),算出された主軸角に基づいてアフィン変換のため
の回転角度θが決定される(ステップ32)。画像メモリ
6内の画像データが,決定された回転角度θに基づいて
アフィン変換回路4から出力されるアドレスにしたがっ
て,斜めに読出され,サーチ計測回路7に与えられる。
サーチ計測回路7は上述のようにウィンドウを走査しな
がら相互相関値が最大となるウィンドウ位置を決定する
(ステップ24,33)。
The image data representing the object is stored in the image memory 6 (step 21) and binarized by the binarizing circuit 13 (step 30). The principal axis angle of the object is calculated based on the binarized image data (step 3
1) The rotation angle θ for affine transformation is determined based on the calculated principal axis angle (step 32). The image data in the image memory 6 is read obliquely according to the address output from the affine transformation circuit 4 based on the determined rotation angle θ, and given to the search measurement circuit 7.
The search measurement circuit 7 determines the window position where the cross-correlation value becomes maximum while scanning the window as described above (steps 24 and 33).

【0046】第2実施例は,主軸角に基づいてアフィン
変換のための回転角度θを決定しているので,1回のア
フィン変換で済み,計測処理を高速化することができ
る。必要ならば,第2実施例でも対象画像の拡大,縮小
処理を拡大/縮小倍率kを変えながら複数回行ってもよ
い。
In the second embodiment, since the rotation angle θ for affine transformation is determined based on the principal axis angle, only one affine transformation is required and the measurement processing can be speeded up. If necessary, also in the second embodiment, the enlargement / reduction processing of the target image may be performed plural times while changing the enlargement / reduction magnification k.

【0047】上記第1,第2実施例では,アフィン変
換,サーチ処理等を専用のハードウェア回路で実施して
いるが,ソフトウェアで実施できるのはいうまでもな
い。
In the first and second embodiments, the affine transformation, the search process and the like are carried out by a dedicated hardware circuit, but it goes without saying that they can be carried out by software.

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

【図1】画像処理装置の電気的構成を示すブロック図で
ある。
FIG. 1 is a block diagram showing an electrical configuration of an image processing apparatus.

【図2】アフィン変換によって拡大,縮小された対象画
像データを登録モデルとパターン・マッチングしている
様子を示すものである。
FIG. 2 shows a state in which target image data enlarged or reduced by affine transformation is pattern-matched with a registered model.

【図3】アフィン変換によって回転された対象画像デー
タを登録モデルとパターン・マッチングしている様子を
示すものである。
FIG. 3 shows a state in which target image data rotated by affine transformation is pattern-matched with a registered model.

【図4】対象画像データのアフィン変換処理について説
明する図である。
FIG. 4 is a diagram illustrating affine transformation processing of target image data.

【図5】一連の計測処理の流れを示すフロー・チャート
である。
FIG. 5 is a flow chart showing a flow of a series of measurement processing.

【図6】第2実施例による画像処理装置の電気的構成を
示すブロック図である。
FIG. 6 is a block diagram showing an electrical configuration of an image processing apparatus according to a second embodiment.

【図7】第2実施例による画像処理の流れを示すフロー
・チャートである。
FIG. 7 is a flow chart showing the flow of image processing according to the second embodiment.

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

1 カメラ 4 アフィン変換回路 6 画像メモリ 7 サーチ計測回路 9 モデル画像メモリ 10 中央処理装置(CPU) 13 2値化回路 14 2値主軸角計測回路 16 ウィンドウ・メモリ 1 camera 4 affine transformation circuit 6 image memory 7 search measurement circuit 9 model image memory 10 central processing unit (CPU) 13 binarization circuit 14 binary spindle angle measurement circuit 16 window memory

───────────────────────────────────────────────────── フロントページの続き (51)Int.Cl.6 識別記号 庁内整理番号 FI 技術表示箇所 G06T 7/60 G06K 9/62 C 9289−5L 9061−5L G06F 15/70 350 H 9061−5L 350 B ─────────────────────────────────────────────────── ─── Continuation of the front page (51) Int.Cl. 6 Identification code Internal reference number FI Technical display location G06T 7/60 G06K 9/62 C 9289-5L 9061-5L G06F 15/70 350 H 9061-5L 350 B

Claims (4)

【特許請求の範囲】[Claims] 【請求項1】 対象物を撮像し,対象物を表わす画像デ
ータを出力する撮像手段,上記撮像手段から出力される
画像データによって表わされる対象画像の拡大/縮小お
よび回転の少なくともいずれか一方のために,所与の変
換パラメータにしたがって上記画像データを変換するア
フィン変換手段,上記アフィン変換手段によって変換さ
れた画像データ上をウィンドウを走査しながら,ウィン
ドウ内の部分画像データとあらかじめメモリに登録され
ているモデル画像データとの類似度を表わす指標値を算
出する類似度演算手段,変換パラメータの値を変えなが
ら上記アフィン変換手段による変換処理および上記類似
度演算手段による指標値算出処理を複数回繰返すよう制
御する手段,ならびに算出された複数の指標値のうち最
も高い類似度を示す指標値を検出し,その指標値を生じ
させるウィンドウの位置および変換パラメータに基づい
て,対象物の大きさ,傾き角度および位置を決定する位
置決定手段,を備えた画像処理装置。
1. An image pickup means for picking up an image of an object and outputting image data representing the object, and at least one of enlargement / reduction and rotation of an object image represented by the image data output from the image pickup means. In addition, while scanning the window over the affine transformation means for transforming the image data according to a given transformation parameter and the image data transformed by the affine transformation means, the partial image data in the window and the image data registered in the memory in advance are registered. Similarity calculation means for calculating an index value representing the similarity with the existing model image data, while changing the value of the conversion parameter, the conversion processing by the affine conversion means and the index value calculation processing by the similarity calculation means are repeated a plurality of times. Shows the highest similarity among the control means and the calculated index values An image processing apparatus comprising: a position determining unit that detects an index value and determines a size, an inclination angle, and a position of an object based on a position of a window that generates the index value and a conversion parameter.
【請求項2】 対象物を撮像し,対象物を表わす画像デ
ータを出力する撮像手段,上記画像データに基づいて対
象物の主軸角を算出する主軸角算出手段,上記主軸角算
出手段によって算出された主軸角にしたがって上記画像
データを回転させるアフィン変換手段,上記アフィン変
換手段によって回転された画像データ上をウィンドウを
走査しながら,ウィンドウ内の部分画像データとあらか
じめメモリに登録されているモデル画像データとの類似
度を表わす指標値を算出する類似度演算手段,および算
出された複数の指標値のうち最も高い類似度を示す指標
値を検出し,その指標値を生じさせるウィンドウの位置
に基づいて対象物の位置を決定する位置決定手段,を備
えた画像処理装置。
2. An image pickup means for picking up an image of an object and outputting image data representing the object, a spindle angle calculation means for calculating a spindle angle of the object based on the image data, and a spindle angle calculation means for calculating the spindle angle. Affine transforming means for rotating the image data according to the main axis angle, partial image data in the window and model image data registered in advance in memory while scanning the window on the image data rotated by the affine transforming means. Based on the position of the window that produces the index value by detecting the index value showing the highest similarity among the calculated index values An image processing apparatus comprising: a position determining unit that determines the position of an object.
【請求項3】 対象物を表わす画像データを受付け,受
付けた画像データが表わす対象画像の拡大/縮小および
回転の少なくともいずれか一方のために,所与の変換パ
ラメータにしたがって画像データをアフィン変換し,ア
フィン変換された画像データ上をウィンドウを走査しな
がら,ウィンドウ内の部分画像データとあらかじめメモ
リに登録しているモデル画像データとの類似度を表わす
指標値を算出し,変換パラメータの値を変えながら上記
アフィン変換処理および上記類似度演算処理を複数回繰
返し,算出した複数の指標値のうち最も高い類似度を示
す指標値を検出し,その指標値を生じさせるウィンドウ
の位置および変換パラメータに基づいて,対象物の大き
さ,傾き角度および位置を決定する,画像処理方法。
3. Accepting image data representing an object, and affine-transforming the image data according to a given conversion parameter for at least one of enlarging / reducing and / or rotating the object image represented by the received image data. , While scanning the window over the affine-transformed image data, calculate the index value indicating the similarity between the partial image data in the window and the model image data registered in the memory in advance, and change the value of the conversion parameter. However, the affine transformation process and the similarity calculation process are repeated a plurality of times to detect the index value showing the highest similarity among the calculated index values, and based on the position of the window and the conversion parameter that generate the index value. An image processing method for determining the size, tilt angle and position of an object.
【請求項4】 対象物を表わす画像データを受付け,受
付けた画像データに基づいて対象物の主軸角を算出し,
算出した主軸角にしたがってアフィン変換することによ
って回転された画像データを得,回転された画像データ
上をウィンドウを走査しながら,ウィンドウ内の部分画
像データとあらかじめメモリに登録しているモデル画像
データとの類似度を表わす指標値を算出し,算出された
複数の指標値のうち最も高い類似度を示す指標値を検出
し,その指標値を生じさせるウィンドウの位置に基づい
て対象物の位置を決定する,画像処理方法。
4. Accepting image data representing an object, calculating a principal axis angle of the object based on the received image data,
The rotated image data is obtained by affine transformation according to the calculated principal axis angle, and while scanning the window over the rotated image data, the partial image data in the window and the model image data registered in advance in the memory Calculates the index value indicating the degree of similarity, detects the index value showing the highest similarity among the calculated index values, and determines the position of the object based on the position of the window that causes the index value. Yes, the image processing method.
JP6027525A 1994-01-31 1994-01-31 Method and device for picture processing Pending JPH07220026A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP6027525A JPH07220026A (en) 1994-01-31 1994-01-31 Method and device for picture processing

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP6027525A JPH07220026A (en) 1994-01-31 1994-01-31 Method and device for picture processing

Publications (1)

Publication Number Publication Date
JPH07220026A true JPH07220026A (en) 1995-08-18

Family

ID=12223544

Family Applications (1)

Application Number Title Priority Date Filing Date
JP6027525A Pending JPH07220026A (en) 1994-01-31 1994-01-31 Method and device for picture processing

Country Status (1)

Country Link
JP (1) JPH07220026A (en)

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH10206134A (en) * 1997-01-17 1998-08-07 Matsushita Electric Works Ltd Position detecting method by image processing
US6850644B1 (en) 1999-10-01 2005-02-01 Samsung Electronics Co., Ltd. Method for analyzing texture of digital image
JP2005156294A (en) * 2003-11-25 2005-06-16 Toko Electric Corp Inspection apparatus
GB2411532A (en) * 2004-02-11 2005-08-31 British Broadcasting Corp Camera position determination
CN1331098C (en) * 1999-10-01 2007-08-08 三星电子株式会社 Digital video texture analytic method
JP2007333647A (en) * 2006-06-16 2007-12-27 Toyama Univ Image processing method, device, and program
JP2010182167A (en) * 2009-02-06 2010-08-19 Toshiba Corp Image processor and image processing method
JP2010182166A (en) * 2009-02-06 2010-08-19 Toshiba Corp Image processor and image processing method
JP2011112379A (en) * 2009-11-24 2011-06-09 Omron Corp Image processing device and image processing program
WO2011067881A1 (en) * 2009-12-03 2011-06-09 株式会社ソニー・コンピュータエンタテインメント Image processing device and image processing method
JP2017049676A (en) * 2015-08-31 2017-03-09 セコム株式会社 Posture discrimination device and object detection device
JP2017068315A (en) * 2015-09-28 2017-04-06 株式会社メガチップス Image processing circuit and image processing apparatus
CN111028145A (en) * 2019-12-10 2020-04-17 成都品果科技有限公司 Figure image processing method for preventing background deformation

Cited By (17)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH10206134A (en) * 1997-01-17 1998-08-07 Matsushita Electric Works Ltd Position detecting method by image processing
US6850644B1 (en) 1999-10-01 2005-02-01 Samsung Electronics Co., Ltd. Method for analyzing texture of digital image
CN1331098C (en) * 1999-10-01 2007-08-08 三星电子株式会社 Digital video texture analytic method
CN100334599C (en) * 1999-10-01 2007-08-29 三星电子株式会社 Digital image look-up method
JP2005156294A (en) * 2003-11-25 2005-06-16 Toko Electric Corp Inspection apparatus
GB2411532A (en) * 2004-02-11 2005-08-31 British Broadcasting Corp Camera position determination
GB2411532B (en) * 2004-02-11 2010-04-28 British Broadcasting Corp Position determination
JP2007333647A (en) * 2006-06-16 2007-12-27 Toyama Univ Image processing method, device, and program
JP2010182167A (en) * 2009-02-06 2010-08-19 Toshiba Corp Image processor and image processing method
JP2010182166A (en) * 2009-02-06 2010-08-19 Toshiba Corp Image processor and image processing method
JP2011112379A (en) * 2009-11-24 2011-06-09 Omron Corp Image processing device and image processing program
WO2011067881A1 (en) * 2009-12-03 2011-06-09 株式会社ソニー・コンピュータエンタテインメント Image processing device and image processing method
US9049397B2 (en) 2009-12-03 2015-06-02 Sony Corporation Image processing device and image processing method
JP2017049676A (en) * 2015-08-31 2017-03-09 セコム株式会社 Posture discrimination device and object detection device
JP2017068315A (en) * 2015-09-28 2017-04-06 株式会社メガチップス Image processing circuit and image processing apparatus
CN111028145A (en) * 2019-12-10 2020-04-17 成都品果科技有限公司 Figure image processing method for preventing background deformation
CN111028145B (en) * 2019-12-10 2023-07-07 成都品果科技有限公司 Character image processing method for preventing background deformation

Similar Documents

Publication Publication Date Title
US5077811A (en) Character and picture image data processing system
JPH0215102B2 (en)
JPH07220026A (en) Method and device for picture processing
JP2002142084A (en) Image reader
US6771842B1 (en) Document image skew detection method
US7155051B2 (en) Image recognition apparatus, image recognition method and image recognition program for specific pattern
JP2864735B2 (en) Object identification method and apparatus, and image processing method and apparatus for object identification
JP2637591B2 (en) Position recognition apparatus and method
JP3303246B2 (en) Image processing device
JP3698867B2 (en) Circular pattern determination method, apparatus and recording medium
AU2020273367A1 (en) Photographic document imaging system
JP2984267B1 (en) Object processing method
JP2004192506A (en) Pattern matching device, pattern matching method, and program
JP3095470B2 (en) Character recognition device
JP3041056B2 (en) Semiconductor pellet detection method
JPH09179982A (en) Specific pattern detecting method
JP3316551B2 (en) Image recognition device
JP2000285237A (en) Method and device for picture processing and recording medium with picture processing program recorded
JPH08194825A (en) Outline information extracting device
JP2003208611A (en) Image processing device, method therefor, and program
JP2882056B2 (en) How to identify specific patterns
JP2959017B2 (en) Circular image discrimination method
JPH0496878A (en) Picture inclination detecting system
JPH07230549A (en) Image processor and its method
JPH05216996A (en) Linear width recognizing device