JP2001067481A - Device and method for image retrieval, and recording medium - Google Patents

Device and method for image retrieval, and recording medium

Info

Publication number
JP2001067481A
JP2001067481A JP24472799A JP24472799A JP2001067481A JP 2001067481 A JP2001067481 A JP 2001067481A JP 24472799 A JP24472799 A JP 24472799A JP 24472799 A JP24472799 A JP 24472799A JP 2001067481 A JP2001067481 A JP 2001067481A
Authority
JP
Japan
Prior art keywords
data
image
projection data
registered
window
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
JP24472799A
Other languages
Japanese (ja)
Other versions
JP4395933B2 (en
Inventor
Tetsuo Tanaka
哲夫 田中
Yukihiro Nishida
幸宏 西田
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.)
Panasonic Holdings Corp
Original Assignee
Matsushita Electric Industrial Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Matsushita Electric Industrial Co Ltd filed Critical Matsushita Electric Industrial Co Ltd
Priority to JP24472799A priority Critical patent/JP4395933B2/en
Publication of JP2001067481A publication Critical patent/JP2001067481A/en
Application granted granted Critical
Publication of JP4395933B2 publication Critical patent/JP4395933B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Image Analysis (AREA)

Abstract

PROBLEM TO BE SOLVED: To provide an image retrieval device which can retrieve a registered image fast with high precision by detecting the angle of rotation of an input image fast and correcting the angle of rotation of the input image. SOLUTION: The image retrieval device has an image input part 1 which inputs an image, a window data generation part 2 which generates window data by making a window scan of specific size on the input image, a projection data generation part 4 which generates projection data from the generated window data, a projection data comparison part 5 which compares the generated projection data with pieces of previously registered template data, an angle detection part 6 which detects the angle of rotation of the input image according to the comparison result of the projection data comparison part 5, and a matching degree decision part 8 which decides the degrees of matching between the input image and registered images by using the angle of rotation.

Description

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

【0001】[0001]

【発明の属する技術分野】本発明は、予め登録された登
録画像が入力画像中に存在するか否かの検索を行う画像
検索装置および画像検索方法、ならびにその方法を実行
する記録媒体に関するものである。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an image retrieval apparatus and an image retrieval method for retrieving whether or not a pre-registered registered image exists in an input image, and a recording medium for executing the method. is there.

【0002】[0002]

【従来の技術】従来から、予め登録された画像が画像中
に存在するか否かの検索を行うための手法として画像検
索方法が提案されている。一般に画像検索方法は、入力
画像中から登録画像の検索をリアルタイムに処理するこ
とが要求されている。
2. Description of the Related Art Conventionally, an image search method has been proposed as a method for searching for a pre-registered image in an image. Generally, an image search method is required to process a search for a registered image from input images in real time.

【0003】登録画像の検索において、入力画像中の全
画素を注目画素として登録画像のマッチングを行うと、
膨大な処理時間がかかる。そこで、従来から、登録画像
とマッチングさせる画像の中心点を求める方法として、
例えば1文字分の大きさの領域を抽出し、抽出した領域
内の画素が存在する幅及び高さから中心点を求める方
法、また登録画像が円を有し、円の内側のみにさまざま
な模様が描かれている場合は、円周上の複数の点におい
てエッジの有無により円を抽出し、円の中心点を求める
方法など、種々の手法が提案されている。
In searching for a registered image, matching of the registered image is performed by using all pixels in the input image as a pixel of interest.
It takes enormous processing time. Therefore, conventionally, as a method of obtaining the center point of the image to be matched with the registered image,
For example, a method of extracting an area of the size of one character and obtaining the center point from the width and height of the pixels in the extracted area, or a method in which the registered image has a circle and various patterns are only inside the circle Is drawn, various methods have been proposed, such as a method of extracting a circle based on the presence or absence of an edge at a plurality of points on the circumference and obtaining a center point of the circle.

【0004】しかし、入力画像が回転している場合、入
力画像を所定角度毎に回転させ、その度に回転処理され
た画像データと登録画像とのマッチングを行い、全角度
のマッチング率により、登録画像であるか否かの判定を
行うなど、検索処理が複雑となり、高速に登録画像の検
索を行うことが難しくなる。
However, when the input image is rotated, the input image is rotated by a predetermined angle, and each time the rotated image data is matched with the registered image, and the registered image is registered based on the matching ratio of all angles. Retrieval processing becomes complicated, such as determining whether an image is an image, and it becomes difficult to search registered images at high speed.

【0005】[0005]

【発明が解決しようとする課題】このように、上記従来
の画像検索方法では、登録画像の検索に膨大な処理時間
がかかり、リアルタイムに処理を行うことが困難になる
という問題点を有していた。
As described above, the above-described conventional image search method has a problem that it takes an enormous amount of processing time to search for a registered image, making it difficult to perform real-time processing. Was.

【0006】この画像検索装置、画像検索方法および記
録媒体では、同一方向に対して各列毎の画素数をカウン
トし、そのカウント数と予め登録しておいた各角度の列
毎のテンプレートデータとの比較を行うことにより、入
力画像の回転角度を検出し、入力画像の回転角度の補正
を行い、登録画像の検索を高速かつ高精度に行うことが
要求されている。
In this image search apparatus, image search method, and recording medium, the number of pixels in each column is counted in the same direction, and the counted number is compared with template data for each column of each angle registered in advance. It is required that the rotation angle of the input image is detected, the rotation angle of the input image is corrected, and the search for the registered image is performed at high speed and with high accuracy.

【0007】本発明は、入力画像の回転角度を高速に検
出して入力画像の回転角度の補正を行い、登録画像の検
索を高速かつ高精度に行うことができる画像検索装置、
および、入力画像の回転角度を高速に検出して入力画像
の回転角度の補正を行い、登録画像の検索を高速かつ高
精度に行うための画像検索方法、ならびに、その画像検
索方法を実行するための記録媒体を提供することを目的
とする。
According to the present invention, there is provided an image retrieval apparatus capable of detecting a rotation angle of an input image at a high speed, correcting the rotation angle of the input image, and performing a high-speed and high-accuracy search of a registered image.
And an image search method for detecting the rotation angle of the input image at high speed, correcting the rotation angle of the input image, and performing high-speed and high-accuracy search of the registered image, and executing the image search method. The purpose of the present invention is to provide a recording medium.

【0008】[0008]

【課題を解決するための手段】上記課題を解決するため
に本発明の画像検索装置は、予め登録しておいた登録画
像が入力画像中に存在するか否かの検索を行う画像検索
装置であって、画像を入力する画像入力部と、入力画像
に対する所定サイズのウィンドウ走査を行ってウィンド
ウデータを生成するウィンドウデータ生成部と、生成し
たウィンドウデータから射影データを作成する射影デー
タ作成部と、作成した射影データと予め登録しておいた
複数のテンプレートデータとの比較を行う射影データ比
較部と、射影データ比較部における比較結果により入力
画像の回転角度を検出する角度検出部と、回転角度を用
いて入力画像と登録画像との一致度を判定する一致度判
定部と、を有する構成を備えている。
In order to solve the above-mentioned problems, an image search apparatus according to the present invention is an image search apparatus for searching whether a registered image registered in advance exists in an input image. There, an image input unit for inputting an image, a window data generating unit for performing window scanning of a predetermined size on the input image to generate window data, a projection data generating unit for generating projection data from the generated window data, A projection data comparison unit that compares the created projection data with a plurality of template data registered in advance; an angle detection unit that detects a rotation angle of the input image based on a comparison result in the projection data comparison unit; A coincidence determining unit that determines the degree of coincidence between the input image and the registered image using the input image and the registered image.

【0009】これにより、入力画像の回転角度を高速に
検出して入力画像の回転角度の補正を行い、登録画像の
検索を高速かつ高精度に行うことができる画像検索装置
が得られる。
Thus, an image retrieval apparatus capable of detecting the rotation angle of the input image at a high speed, correcting the rotation angle of the input image, and searching for the registered image at a high speed and with a high accuracy can be obtained.

【0010】上記課題を解決するために本発明の画像検
索方法は、予め登録しておいた登録画像が入力画像中に
存在するか否かの検索を行う画像検索方法であって、入
力画像に対する所定サイズのウィンドウ走査を行ってウ
ィンドウデータを生成するウィンドウデータ生成ステッ
プと、生成したウィンドウデータから射影データを作成
する射影データ作成ステップと、作成した射影データと
予め登録しておいた複数のテンプレートデータとの比較
を行う射影データ比較ステップと、射影データ比較ステ
ップにおける比較結果により入力画像の回転角度を検出
する角度検出ステップと、前記回転角度を用いて入力画
像と登録画像との一致度を判定する一致度判定ステップ
と、を有する構成を備えている。
In order to solve the above problem, an image search method according to the present invention is an image search method for searching whether or not a registered image registered in advance exists in an input image. A window data generating step of performing window scanning of a predetermined size to generate window data, a projection data generating step of generating projection data from the generated window data, and a plurality of template data registered in advance with the generated projection data A projection data comparison step of comparing the input image with the registered image; a detection step of detecting a rotation angle of the input image based on a comparison result in the projection data comparison step; and determining a degree of coincidence between the input image and the registered image using the rotation angle. And a matching degree determining step.

【0011】これにより、入力画像の回転角度を高速に
検出して入力画像の回転角度の補正を行い、登録画像の
検索を高速かつ高精度に行うための画像検索方法が得ら
れる。
Thus, an image search method for detecting the rotation angle of the input image at high speed, correcting the rotation angle of the input image, and searching for the registered image at high speed and with high accuracy can be obtained.

【0012】上記課題を解決するために本発明の記録媒
体は、予め登録しておいた登録画像が入力画像中に存在
するか否かの検索を行う画像検索方法であって、入力画
像に対する所定サイズのウィンドウ走査を行ってウィン
ドウデータを生成するウィンドウデータ生成ステップ
と、生成したウィンドウデータから射影データを作成す
る射影データ作成ステップと、作成した射影データと予
め登録しておいた複数のテンプレートデータとの比較を
行う射影データ比較ステップと、射影データ比較ステッ
プにおける比較結果により入力画像の回転角度を検出す
る角度検出ステップと、前記回転角度を用いて入力画像
と登録画像との一致度を判定する一致度判定ステップ
と、を実行させるためのプログラムを記録した構成を備
えている。
In order to solve the above-mentioned problem, a recording medium according to the present invention is an image search method for searching whether a registered image registered in advance exists in an input image. A window data generating step of generating window data by performing window scanning of a size, a projection data generating step of generating projection data from the generated window data, and a plurality of template data registered in advance with the generated projection data. A projection data comparison step for comparing the input image, an angle detection step for detecting a rotation angle of the input image based on the comparison result in the projection data comparison step, and a match for determining the degree of coincidence between the input image and the registered image using the rotation angle. A degree determination step, and a configuration for recording a program for executing the step.

【0013】これにより、上記画像検索方法を実行する
ための記録媒体が得られる。
As a result, a recording medium for executing the above-described image search method is obtained.

【0014】[0014]

【発明の実施の形態】本発明の請求項1に記載の画像検
索装置は、予め登録しておいた登録画像が入力画像中に
存在するか否かの検索を行う画像検索装置であって、画
像を入力する画像入力部と、入力画像に対する所定サイ
ズのウィンドウ走査を行ってウィンドウデータを生成す
るウィンドウデータ生成部と、生成したウィンドウデー
タから射影データを作成する射影データ作成部と、作成
した射影データと予め登録しておいた複数のテンプレー
トデータとの比較を行う射影データ比較部と、射影デー
タ比較部における比較結果により入力画像の回転角度を
検出する角度検出部と、回転角度を用いて入力画像と登
録画像との一致度を判定する一致度判定部と、を有する
こととしたものである。
DETAILED DESCRIPTION OF THE INVENTION An image retrieval apparatus according to a first aspect of the present invention is an image retrieval apparatus for performing a search as to whether or not a registered image registered in advance exists in an input image. An image input unit for inputting an image, a window data generation unit for performing window scanning of a predetermined size on the input image to generate window data, a projection data generation unit for generating projection data from the generated window data, and a generated projection A projection data comparison unit for comparing data with a plurality of template data registered in advance, an angle detection unit for detecting a rotation angle of the input image based on a comparison result in the projection data comparison unit, and an input using the rotation angle And a coincidence determining unit for determining the degree of coincidence between the image and the registered image.

【0015】この構成により、射影データと複数のテン
プレートデータとの比較に基づいて入力画像の回転角度
が検出されるので、入力画像の回転角度の検出が高速化
され、その検出回転角度に基づいて入力画像の回転角度
の補正を行うことにより、入力画像中に登録画像がある
か否かの検索を高速かつ高精度に行うことができるとい
う作用を有する。
According to this configuration, since the rotation angle of the input image is detected based on a comparison between the projection data and the plurality of template data, the detection of the rotation angle of the input image is speeded up, and based on the detected rotation angle. By performing the correction of the rotation angle of the input image, it is possible to perform a search for a registered image in the input image at high speed and with high accuracy.

【0016】請求項2に記載の画像検索方法は、予め登
録しておいた登録画像が入力画像中に存在するか否かの
検索を行う画像検索方法であって、入力画像に対する所
定サイズのウィンドウ走査を行ってウィンドウデータを
生成するウィンドウデータ生成ステップと、生成したウ
ィンドウデータから射影データを作成する射影データ作
成ステップと、作成した射影データと予め登録しておい
た複数のテンプレートデータとの比較を行う射影データ
比較ステップと、射影データ比較ステップにおける比較
結果により入力画像の回転角度を検出する角度検出ステ
ップと、前記回転角度を用いて入力画像と登録画像との
一致度を判定する一致度判定ステップと、を有すること
としたものである。
According to a second aspect of the present invention, there is provided an image search method for searching whether a registered image registered in advance exists in an input image. A window data generating step of generating window data by performing scanning, a projection data generating step of generating projection data from the generated window data, and comparing the generated projection data with a plurality of template data registered in advance. Projection data comparison step to be performed, an angle detection step of detecting a rotation angle of the input image based on a comparison result in the projection data comparison step, and a coincidence determination step of determining a coincidence between the input image and the registered image using the rotation angle And

【0017】この構成により、射影データと複数のテン
プレートデータとの比較に基づいて入力画像の回転角度
が検出されるので、入力画像の回転角度の検出が高速化
され、その検出回転角度に基づいて入力画像の回転角度
の補正を行うことにより、入力画像中に登録画像がある
か否かの検索を高速かつ高精度に行うことができるとい
う作用を有する。
With this configuration, since the rotation angle of the input image is detected based on a comparison between the projection data and the plurality of template data, the detection of the rotation angle of the input image is speeded up, and based on the detected rotation angle. By performing the correction of the rotation angle of the input image, it is possible to perform a search for a registered image in the input image at high speed and with high accuracy.

【0018】請求項3に記載の画像検索方法は、予め登
録しておいた登録画像が入力画像中に存在するか否かの
検索を行う画像検索方法であって、入力画像に対する所
定サイズのウィンドウ走査を行ってウィンドウデータを
生成するウィンドウデータ生成ステップと、生成したウ
ィンドウデータに対して2値化を行って2値化ウィンド
ウデータを生成する2値化処理ステップと、生成した2
値化ウィンドウデータから射影データを作成する射影デ
ータ作成ステップと、作成した射影データと予め登録し
ておいた複数のテンプレートデータとの比較を行う射影
データ比較ステップと、射影データ比較ステップにおけ
る比較結果により入力画像の回転角度を検出する角度検
出ステップと、回転角度を用いて入力画像と登録画像と
の一致度を判定する一致度判定ステップと、を有するこ
ととしたものである。
According to a third aspect of the present invention, there is provided an image search method for searching whether or not a registered image registered in advance exists in an input image. A window data generating step of performing scanning to generate window data; a binarizing processing step of performing binarization on the generated window data to generate binarized window data;
A projection data creation step of creating projection data from the quantified window data, a projection data comparison step of comparing the created projection data with a plurality of template data registered in advance, and a comparison result in the projection data comparison step. The method includes an angle detection step of detecting a rotation angle of the input image, and a coincidence determination step of determining a coincidence between the input image and the registered image using the rotation angle.

【0019】この構成により、2値化ウィンドウデータ
から射影データが作成されるので、入力画像の回転角度
の検出が更に高速化されるという作用を有する。
With this configuration, since the projection data is created from the binarized window data, the rotation angle of the input image can be detected at a higher speed.

【0020】請求項4に記載の画像検索方法は、予め登
録しておいた登録画像が入力画像中に存在するか否かの
検索を行う画像検索方法であって、入力画像に対する所
定サイズのウィンドウ走査を行ってウィンドウデータを
生成するウィンドウデータ生成ステップと、生成したウ
ィンドウデータに対して多値化を行って多値化ウィンド
ウデータを生成する多値化処理ステップと、生成した多
値化ウィンドウデータから射影データを作成する射影デ
ータ作成ステップと、作成した射影データと予め登録し
ておいた複数のテンプレートデータとの比較を行う射影
データ比較ステップと、射影データ比較ステップにおけ
る比較結果により入力画像の回転角度を検出する角度検
出ステップと、回転角度を用いて入力画像と登録画像と
の一致度を判定する一致度判定ステップと、を有するこ
ととしたものである。
According to a fourth aspect of the present invention, there is provided an image search method for searching whether or not a registered image registered in advance exists in an input image. A window data generating step of performing scanning to generate window data, a multi-level processing step of performing multi-level processing on the generated window data to generate multi-level window data, and a generated multi-level window data A projection data creation step of creating projection data from the input image, a projection data comparison step of comparing the created projection data with a plurality of template data registered in advance, and a rotation of the input image based on a comparison result in the projection data comparison step. An angle detecting step of detecting an angle; and determining a degree of coincidence between the input image and the registered image using the rotation angle. A coincidence determination step, in which it was decided to have a.

【0021】この構成により、多値化ウィンドウデータ
から射影データが作成されるので、入力画像の回転角度
の検出が更に高精度化されるという作用を有する。
According to this configuration, since projection data is created from the multi-valued window data, there is an effect that the detection of the rotation angle of the input image is further improved in accuracy.

【0022】請求項5に記載の画像検索方法は、請求項
2乃至4のいずれか1に記載の画像検索方法において、
射影データ比較ステップにおいては、テンプレートデー
タの角度は6度よりも小さい角度毎に設定されることと
したものである。
According to a fifth aspect of the present invention, there is provided an image search method according to any one of the second to fourth aspects.
In the projection data comparison step, the angle of the template data is set for each angle smaller than 6 degrees.

【0023】この構成により、テンプレートデータが高
精度化され、入力画像の回転角度の検出が更に高精度化
されるという作用を有する。
According to this configuration, there is an effect that the accuracy of the template data is improved and the detection of the rotation angle of the input image is further improved.

【0024】請求項6に記載の画像検索方法は、請求項
2乃至5のいずれか1に記載の画像検索方法において、
射影データ比較ステップにおいては、作成した射影デー
タとテンプレートデータとの差が所定値以上の場合には
次のテンプレートデータとの比較へ移行することとした
ものである。
According to a sixth aspect of the present invention, there is provided the image search method according to any one of the second to fifth aspects, wherein:
In the projection data comparison step, when the difference between the created projection data and the template data is equal to or larger than a predetermined value, the process shifts to comparison with the next template data.

【0025】この構成により、入力画像と一致する可能
性の無いテンプレートデータとの比較が省略されるの
で、入力画像の回転角度の検出が更にいっそう高速化さ
れるという作用を有する。
With this configuration, the comparison of the input image with template data that is unlikely to be matched is omitted, so that the rotation angle of the input image can be detected at a higher speed.

【0026】請求項7に記載の画像検索方法は、請求項
2乃至6のいずれか1に記載の画像検索方法において、
射影データ作成ステップにおいては、複数方向に対して
画素値を計数することとしたものである。
According to a seventh aspect of the present invention, there is provided the image search method according to any one of the second to sixth aspects, wherein:
In the projection data creation step, pixel values are counted in a plurality of directions.

【0027】この構成により、1方向に対する画素値の
係数のみでは発生する誤りが防止されるので、入力画像
の回転角度を更に正確に検出することができるという作
用を有する。
According to this configuration, an error that occurs only with the coefficient of the pixel value in one direction is prevented, so that the rotation angle of the input image can be detected more accurately.

【0028】請求項8に記載の画像検索方法は、請求項
7に記載の画像検索方法において、射影データ比較ステ
ップにおいては、一つの方向の射影データとテンプレー
トデータとの比較結果により、他方向の射影データとテ
ンプレートデータとの比較結果を制御することとしたも
のである。
According to an eighth aspect of the present invention, in the image search method according to the seventh aspect, in the projection data comparing step, a comparison result between the projection data in one direction and the template data is used in the other direction. This is to control the comparison result between the projection data and the template data.

【0029】この構成により、他方向において検索する
角度を絞り込むことができるので、入力画像の回転角度
を更にいっそう高速に検出することができるという作用
を有する。
With this configuration, it is possible to narrow the search angle in the other direction, so that the rotation angle of the input image can be detected at a higher speed.

【0030】請求項9に記載の画像検索方法は、請求項
2乃至8のいずれか1に記載の画像検索方法において、
射影データ比較ステップにおいては、最大画素数・最小
画素数・標準偏差・平均画素数のいずれかを用いて比較
を行うこととしたものである。
According to a ninth aspect of the present invention, there is provided an image search method according to any one of the second to eighth aspects, wherein
In the projection data comparison step, the comparison is performed using any of the maximum number of pixels, the minimum number of pixels, the standard deviation, and the average number of pixels.

【0031】この構成により、全列の一致度を求めなく
ても高速に非登録画像であることを判定することがで
き、また登録画像の角度を高速に絞り込むことができる
という作用を有する。
According to this configuration, it is possible to quickly determine that the image is a non-registered image without obtaining the degree of coincidence of all columns, and it is possible to narrow down the angle of the registered image at a high speed.

【0032】請求項10に記載の記録媒体は、予め登録
しておいた登録画像が入力画像中に存在するか否かの検
索を行う画像検索方法を実行させる記録媒体であって、
入力画像に対する所定サイズのウィンドウ走査を行って
ウィンドウデータを生成するウィンドウデータ生成ステ
ップと、生成したウィンドウデータから射影データを作
成する射影データ作成ステップと、作成した射影データ
と予め登録しておいた複数のテンプレートデータとの比
較を行う射影データ比較ステップと、射影データ比較ス
テップにおける比較結果により入力画像の回転角度を検
出する角度検出ステップと、回転角度を用いて入力画像
と登録画像との一致度を判定する一致度判定ステップ
と、を実行させるためのプログラムを記録することとし
たものである。
According to a tenth aspect of the present invention, there is provided a recording medium for executing an image search method for searching whether a registered image registered in advance exists in an input image,
A window data generating step of performing window scanning of a predetermined size on an input image to generate window data, a projection data generating step of generating projection data from the generated window data, and a plurality of pre-registered generated projection data. A projection data comparison step of comparing the input image with the template data of the input image, an angle detection step of detecting a rotation angle of the input image based on a comparison result in the projection data comparison step, and a degree of coincidence between the input image and the registered image using the rotation angle. And a program for executing the matching degree determination step to be determined.

【0033】この構成により、入力画像中に登録画像が
あるか否かの検索を高速かつ高精度に行うことができる
画像検索方法を任意の場所・期間に行うことができると
いう作用を有する。
According to this configuration, there is an effect that an image search method capable of performing a high-speed and high-accuracy search for a registered image in an input image can be performed at an arbitrary place and period.

【0034】以下、本発明の実施の形態について図1〜
図15を参照しながら説明する。
Hereinafter, an embodiment of the present invention will be described with reference to FIGS.
This will be described with reference to FIG.

【0035】(実施の形態1)図1は本発明の実施の形
態1による画像検索装置を示すブロック図である。
(Embodiment 1) FIG. 1 is a block diagram showing an image retrieval apparatus according to Embodiment 1 of the present invention.

【0036】図1において、1は画像データを入力する
画像入力部、2は画像入力部1により入力された画像デ
ータに対し、或る注目画素を中心としN画素×N画素サ
イズのウィンドウデータを生成するウィンドウデータ生
成部、3はウィンドウデータ生成部2により生成された
ウィンドウデータの2値化処理(例えば、画像データの
明度を求め、その明度と所定の閾値との比較を行うこと
による2値化処理)を行う2値化処理部、4は2値化処
理部3により2値化されたウィンドウデータに対し、同
一方向(例えば垂直方向)の各列毎に画素数をカウント
することにより射影データを作成する射影データ作成
部、5は射影データ作成部4により作成された射影デー
タと予め登録されている各角度のテンプレートデータと
の比較を行う射影データ比較部、6は射影データ比較部
5により比較された結果により角度を検出する角度検出
部、7は角度検出部6により検出された角度に応じて、
2値化処理部3により2値化されたウィンドウデータの
角度の補正を行う角度補正部、8は角度補正部7により
補正された角度補正後のウィンドウデータと予め登録さ
れた登録画像との一致度を判定する一致度判定部であ
る。
In FIG. 1, reference numeral 1 denotes an image input unit for inputting image data, and 2 denotes window data of N pixels × N pixels centering on a certain pixel of interest with respect to the image data input by the image input unit 1. The window data generating unit 3 generates a binarization process of the window data generated by the window data generating unit 2 (for example, a binary value obtained by calculating the brightness of image data and comparing the brightness with a predetermined threshold value). Binarization processing unit 4 which performs binarization processing) projects the window data binarized by the binarization processing unit 3 by counting the number of pixels for each column in the same direction (for example, the vertical direction). A projection data creation unit 5 for creating data is a projection data creation unit for comparing the projection data created by the projection data creation unit 4 with template data of each angle registered in advance. Data comparison unit, 6 the projection angle detecting section for detecting an angle as a result of comparison by the data comparing unit 5, 7 is in accordance with the detected angle by the angle detecting section 6,
An angle correction unit 8 corrects the angle of the window data binarized by the binarization processing unit 3. The angle correction unit 8 matches the window data after the angle correction corrected by the angle correction unit 7 with a registered image registered in advance. It is a coincidence determination unit that determines the degree.

【0037】ここで、図1の構成について図3を用いて
説明する。図3は検出すべき登録画像を示す画像図であ
る。図1において、ウィンドウデータ生成部2と2値化
処理部3を入れ替え、画像入力部1により入力された画
像データに対し、2値化処理部3により2値化処理を行
い、2値化処理部3により2値化処理された画像データ
に対し、ウィンドウデータ生成部2によりある注目画素
を中心としN画素×N画素サイズのウィンドウデータを
生成してもよい。また、2値化処理を行わず、射影デー
タ作成部4は多値のウィンドウデータ(多値化ウィンド
ウデータ)に対し、同一方向の各列毎に画素値の総和を
求めることにより、射影データを作成してもよい。また
上記注目画素は、画像入力部1により入力された画像デ
ータの全画素としてもよいが、ここでは図3に示すよう
な、円を有し円の内側のみに模様が存在する登録画像9
の検索を例に説明を行うものであり、円の中心画素を検
出し、検出した画素を注目画素とする。さらに、角度補
正部7は、登録画像を回転させたり、各角度の登録画像
を登録させ、検出した角度に応じて登録画像を選択させ
ることもできる。また、ここではウィンドウデータと登
録画像との一致度を判定しているが、射影データを作成
した前記ウィンドウデータのサイズとは異なる第2のウ
ィンドウを生成し、登録画像との一致度を判定してもよ
い。
Here, the configuration of FIG. 1 will be described with reference to FIG. FIG. 3 is an image diagram showing a registered image to be detected. In FIG. 1, the window data generation unit 2 and the binarization processing unit 3 are exchanged, and the image data input by the image input unit 1 is binarized by the binarization processing unit 3 to perform binarization processing. With respect to the image data binarized by the unit 3, the window data generation unit 2 may generate window data of N pixels × N pixels around a certain pixel of interest. Further, without performing the binarization processing, the projection data creation unit 4 obtains the projection data by calculating the sum of the pixel values for each column in the same direction with respect to the multivalued window data (multivalued window data). May be created. The target pixel may be all pixels of the image data input by the image input unit 1, but here, as shown in FIG. 3, a registered image 9 having a circle and having a pattern only inside the circle.
In the following description, the center pixel of a circle is detected, and the detected pixel is set as a target pixel. Further, the angle correction unit 7 can rotate the registered image, register a registered image of each angle, and select a registered image according to the detected angle. Although the degree of coincidence between the window data and the registered image is determined here, a second window different from the size of the window data for which the projection data is created is generated, and the degree of coincidence with the registered image is determined. You may.

【0038】次に、以上のように構成された画像検索装
置について、図2、図4〜図7を用いてその動作を説明
する。図2は図1の画像検索装置の動作を示すフローチ
ャートであり、図4は登録画像に対する各角度のテンプ
レートデータを示す角度テンプレート対応図、図5は入
力画像に対する所定サイズのウィンドウ内の画像を示す
画像図、図6は図5の画像に対する射影データを示すデ
ータ図、図7は図5の画像の角度を補正した後の画像を
示す画像図である。
Next, the operation of the image retrieval apparatus configured as described above will be described with reference to FIGS. 2, 4 to 7. FIG. 2 is a flowchart showing the operation of the image search apparatus of FIG. 1, FIG. 4 is an angle template correspondence diagram showing template data of each angle with respect to a registered image, and FIG. 5 shows an image in a window of a predetermined size with respect to an input image. FIG. 6 is a data diagram showing projection data for the image of FIG. 5, and FIG. 7 is an image diagram showing an image after correcting the angle of the image of FIG.

【0039】まず、画像入力部1により画像データを入
力し(S1)、画像入力部1により入力された画像デー
タに対し、円の中心画素を検出することにより注目画素
の抽出を行う。円の中心画素の検出方法については詳細
を後述する。次に、ウィンドウデータ生成部2により前
記抽出した或る注目画素を中心とし所定サイズ(例えば
25画素×25画素)のウィンドウデータを生成し(S
2、ウィンドウデータ生成ステップ)、ウィンドウデー
タ生成部2により生成されたウィンドウデータに対し、
2値化処理部3により2値化処理(例えば、カラー画像
信号の明度を求め、その明度と所定の閾値との比較を行
うことによる2値化処理)を行う(S3、2値化処理ス
テップ)。ここで2値化されたウィンドウデータ(2値
化ウィンドウデータ)11(図5)において、射影デー
タ作成部4により、まず垂直方向の第1列目の画素数を
カウントし、次に垂直方向の第2列目の画素数をカウン
トし、同様にしてウィンドウ内の垂直方向に対し全ての
列の画素数をそれぞれ列毎にカウントする(S4,S
5、射影データ作成ステップ)。以上により求めた垂直
方向の列毎のカウント値を射影データ12(図6)と
し、予め登録しておいた各角度のテンプレートデータ1
0(図4)との比較を行う。テンプレートデータ10の
作成方法および比較方法については詳細を後述する。こ
こで射影データ比較部5により、まず上記求めた射影デ
ータ12と予め登録しておいた角度0度のテンプレート
データ10B−0との比較を行う(S6、射影データ比
較ステップ)。いま、角度0度のテンプレートデータ1
0B−0のみしか比較を行っていないので、入力画像の
回転角度として角度0度を検出する(S7)。同様にし
て全ての角度のテンプレートデータ10B−0〜10B
−350と比較を行う(S8)。角度検出部6は、射影
データ12と角度0度〜角度350度までのテンプレー
トデータ10との比較結果により、比較結果の値が最も
小さい(射影データ12に最も類似した)テンプレート
データの角度(ここでは射影データ12と70度のテン
プレートデータ10B−70とが最も類似している。)
を検出する(S7、角度検出ステップ)。以上のステッ
プS6〜ステップS8によりウィンドウデータ11の傾
いた角度(入力画像の回転角度)を検出する。ここで角
度補正部7によりウィンドウデータ11をステップS7
により検出した角度分(ここでは70度)だけ角度補正
を行う(S9)。角度補正方法については詳細を後述す
る。次に、一致度判定部8により、上記ウィンドウデー
タ11に対し角度補正された角度補正後の画像13(図
7)と予め登録しておいた登録画像9との一致度(例え
ば、黒画素と白画素の一致する割合によるマッチング)
の判定を行い(S10、一致度判定ステップ)、登録画
像9に一致するか否かの判定を行う。ある注目画素に対
し、ステップS2からステップS10までの一連の処理
が終了し、次の注目画素が存在すると(S11)、注目
画素を移動し(S12)、次の注目画素に対し、ステッ
プS2からステップS10までの処理を繰り返す。同様
にして全ての画素に対しステップS2からステップS1
0までの処理を行い、全ての注目画素に対し処理が終了
すると(S11)、検索処理が終了する。
First, image data is input by the image input unit 1 (S1), and a pixel of interest is extracted by detecting the center pixel of a circle in the image data input by the image input unit 1. The method of detecting the center pixel of the circle will be described later in detail. Next, the window data generation unit 2 generates window data of a predetermined size (for example, 25 pixels × 25 pixels) centering on the extracted pixel of interest (S
2. window data generation step), for the window data generated by the window data generation unit 2,
The binarization processing unit 3 performs binarization processing (for example, binarization processing by obtaining the brightness of a color image signal and comparing the brightness with a predetermined threshold) (S3, binarization processing step) ). Here, in the binarized window data (binarized window data) 11 (FIG. 5), first, the number of pixels in the first column in the vertical direction is counted by the projection data creation unit 4, and then the number of pixels in the vertical direction is counted. The number of pixels in the second column is counted, and similarly, the number of pixels in all columns in the vertical direction in the window is counted for each column (S4, S4).
5. Projection data creation step). The count value for each column in the vertical direction obtained as described above is used as projection data 12 (FIG. 6), and template data 1 for each angle registered in advance is used.
0 (FIG. 4). Details of the method of creating the template data 10 and the method of comparison will be described later. Here, the projection data comparison unit 5 compares the obtained projection data 12 with the template data 10B-0 of the angle of 0 degrees registered in advance (S6, projection data comparison step). Now, template data 1 of 0 degree angle
Since only 0B-0 is compared, an angle of 0 degree is detected as the rotation angle of the input image (S7). Similarly, template data 10B-0 to 10B of all angles
Compare with -350 (S8). The angle detection unit 6 determines, based on a comparison result between the projection data 12 and the template data 10 at an angle of 0 ° to 350 °, the angle of the template data having the smallest value of the comparison result (the most similar to the projection data 12). , The projection data 12 and the 70-degree template data 10B-70 are the most similar.)
Is detected (S7, angle detection step). Through the above steps S6 to S8, the inclination angle of the window data 11 (the rotation angle of the input image) is detected. Here, the window data 11 is converted by the angle correction unit 7 into step S7.
The angle is corrected by the angle (70 degrees in this case) detected by (1) (S9). Details of the angle correction method will be described later. Next, the degree of coincidence between the angle-corrected image 13 (FIG. 7) obtained by correcting the angle of the window data 11 and the registered image 9 (for example, the Matching by matching ratio of white pixels)
Is determined (S10, matching degree determination step), and it is determined whether or not the image matches the registered image 9. A series of processes from step S2 to step S10 is completed for a certain target pixel, and if there is a next target pixel (S11), the target pixel is moved (S12). The processing up to step S10 is repeated. Similarly, for all pixels, steps S2 to S1
When the processing up to 0 is performed and the processing is completed for all the target pixels (S11), the search processing ends.

【0040】テンプレートデータ10の作成方法の詳細
を図4を参照し説明する。画像10A−0は、検出すべ
き登録画像9を角度0度に回転させたときの画像(全く
回転させないときの画像)で、画像10A−70は、検
出すべき登録画像9を角度70度に回転させたときの画
像で、同様に画像10A−350は、検出すべき登録画
像9を角度350度に回転させたときの画像である。テ
ンプレートデータ10B−0は、画像10A−0に対し
垂直方向に列毎に画素数をカウントした射影データで、
テンプレートデータ10B−70は、画像10A−70
に対し垂直方向に列毎に画素数をカウントした射影デー
タで、同様にテンプレートデータ10B−350は、画
像10A−350に対し垂直方向に列毎に画素数をカウ
ントした射影データである。テンプレートデータをここ
では角度10度おきで作成しているが、例えば角度1度
おきにテンプレートデータを作成することにより、入力
画像の傾きをより高精度に検出でき、マッチングをより
高精度に行うことができる。
The details of the method of creating the template data 10 will be described with reference to FIG. The image 10A-0 is an image obtained when the registered image 9 to be detected is rotated at an angle of 0 degrees (an image obtained when the registered image 9 is not rotated at all), and the image 10A-70 is an image obtained by rotating the registered image 9 to be detected at an angle of 70 degrees. Similarly, images 10A-350 are images obtained by rotating registered image 9 to be detected by an angle of 350 degrees. The template data 10B-0 is projection data obtained by counting the number of pixels for each column in the vertical direction with respect to the image 10A-0.
The template data 10B-70 includes the image 10A-70
The template data 10B-350 is projection data obtained by counting the number of pixels in each column in the vertical direction with respect to the image 10A-350. Here, the template data is created at an angle of 10 degrees. However, for example, by creating the template data at an angle of 1 degree, the inclination of the input image can be detected with higher accuracy, and matching can be performed with higher accuracy. Can be.

【0041】射影データ12とテンプレートデータ10
との比較方法について図4及び図6を参照し説明する。
射影データ12の第i列目(i=1、2、…、N)の値
をSiとし、角度k度(k=0、10、…、350)の
テンプレートデータ10B−kの第i列目の値をTki
とすると、射影データ12と角度k度のテンプレートデ
ータ10B−kとの比較結果Rkは、(1)式の様に求
められる。同様にして、他の角度のテンプレートデータ
と射影データとの比較結果Rkを求め、比較結果Rkが
最も小さくなるテンプレートデータに対応する角度k度
を求める。
Projection data 12 and template data 10
The method of comparison with will be described with reference to FIGS.
The value of the i-th column (i = 1, 2,..., N) of the projection data 12 is Si, and the i-th column of the template data 10B-k of the angle k degrees (k = 0, 10,..., 350) The value of Tki
Then, a comparison result Rk between the projection data 12 and the template data 10B-k of the angle k is obtained as shown in Expression (1). Similarly, a comparison result Rk between the template data of another angle and the projection data is obtained, and an angle k corresponding to the template data having the smallest comparison result Rk is obtained.

【0042】 Rk=Σ|Si−Tki|・・・・・・(1) 実際、図5の入力画像のウィンドウデータ11に対する
射影データ12と図4の各角度のテンプレートデータと
を(1)式により比較すると、60度のテンプレートデ
ータとの比較結果R60は46、70度のテンプレート
データとの比較結果R70は20、80度のテンプレー
トデータとの比較結果R80は30、その他0度〜35
0度のテンプレートデータとの比較結果は上記70度の
比較結果より大きくなり、(1)式により、70度が求
められる。このように各角度のテンプレートデータと入
力画像との比較において、各角度のテンプレートデータ
間の角度を10度おきに作成しても入力画像の角度に最
も近い角度を検出することができるが、入力画像と登録
画像の相対角度を一致させ、マッチングを精度よく行う
ために、各角度のテンプレートデータ間の最低角度を6
度以下にする。
Rk = Σ | Si−Tki | (1) Actually, the projection data 12 with respect to the window data 11 of the input image in FIG. 5 and the template data of each angle in FIG. The comparison result R60 with the template data of 60 degrees is 46, the comparison result R70 with the template data of 70 degrees is 20, the comparison result R80 with the template data of 80 degrees is 30, and the other 0 to 35 degrees
The result of comparison with the template data of 0 degrees is larger than the result of comparison of 70 degrees, and 70 degrees is obtained by the equation (1). As described above, in the comparison between the template data of each angle and the input image, the angle closest to the angle of the input image can be detected even if the angle between the template data of each angle is created every 10 degrees. In order to match the relative angle between the image and the registered image and perform the matching with high accuracy, the minimum angle between the template data of each angle is 6
Degree or less.

【0043】次に、円の中心画素の検出方法について図
8を参照しながら説明する。図8は円の中心画素の検出
方法の説明図である。図8において、円14は登録画像
の一部であり、注目画素15は円14の中心画素であ
り、円周上の画素16A−0〜16A−11は円14の
円周上に存在する画素であり、円周上の画素16B−0
〜16Bー11は円14の外側で円周上の画素16A−
0〜16A−11に隣接する画素である。円周上の画素
16A−jおよび16B−j(j=0、1、…、11)
において、(2)式を満たすとき円の内部と円の外部と
の境界にエッジが存在するものとする。
Next, a method for detecting the center pixel of a circle will be described with reference to FIG. FIG. 8 is an explanatory diagram of a method for detecting the center pixel of a circle. 8, the circle 14 is a part of the registered image, the target pixel 15 is the center pixel of the circle 14, and the pixels 16A-0 to 16A-11 on the circumference are the pixels existing on the circumference of the circle 14. And the pixel 16B-0 on the circumference
16B-11 are pixels 16A- on the circumference outside the circle 14.
Pixels adjacent to 0-16A-11. Pixels 16A-j and 16B-j on the circumference (j = 0, 1,..., 11)
It is assumed that an edge exists at the boundary between the inside of the circle and the outside of the circle when Expression (2) is satisfied.

【0044】 画素16A−jの値<画素16B−jの値・・・・(2) また、登録画像の特徴色の下限値をC0(例として
0)、上限値をC1(例として50)とすると、円周上
の画素16A−jの値が(3)式を満たすとき、円周上
の画素16A−jは、登録画像と色味が一致しているも
のとする。
The value of the pixel 16A-j <the value of the pixel 16B-j (2) Further, the lower limit value of the characteristic color of the registered image is C0 (0 as an example) and the upper limit value is C1 (50 as an example). Then, when the value of the pixel 16A-j on the circumference satisfies the expression (3), it is assumed that the color of the pixel 16A-j on the circumference matches the registered image.

【0045】 C0(0)≦画素16A−jの値≦C1(50)・・・・・(3) 円周上の複数の位置(ここでは12個所)全てにおい
て、(2)式および(3)式を満たすとき、注目画素1
5を円14の中心画素とする。
C0 (0) ≦ value of pixel 16A-j ≦ C1 (50) (3) In all of a plurality of positions (here, 12 positions) on the circumference, the expression (2) and (3) Satisfies the expression, the target pixel 1
5 is the center pixel of the circle 14.

【0046】入力された画像に対し、画素単位に注目画
素を画像全体に走査し、注目画素毎に周囲画素16A−
jおよび16B−j(j=0、1、…、11)に対して
(2)式および(3)式の処理を行い、注目画素が円の
中心画素であるか否かの判定を行う。
In the input image, the pixel of interest is scanned over the entire image in pixel units, and the surrounding pixels 16A-
The processing of Expressions (2) and (3) is performed on j and 16B-j (j = 0, 1,..., 11), and it is determined whether or not the target pixel is the center pixel of the circle.

【0047】角度補正方法について説明する。上記求め
た注目画素を中心画素とし、2値化されたウィンドウ内
の全黒画素を検出した角度分だけ角度補正を行う。例え
ば検出した角度が70度であれば、−70度だけ中心画
素を中心に全黒画素を回転させる。
The angle correction method will be described. With the pixel of interest determined as the center pixel, angle correction is performed by the angle at which all black pixels in the binarized window are detected. For example, if the detected angle is 70 degrees, all black pixels are rotated around the center pixel by -70 degrees.

【0048】なお、本実施の形態では、射影データ12
は垂直方向の画素数をカウントすることにより求めてい
るが、同一方向であれば水平方向や斜め方向であっても
よい。また複数方向でもよい。これを図9〜図11を用
いて説明する。図9は左右対象の登録画像を示す画像図
であり、図10は角度0度の画像を示す画像図、図11
は図10の画像に対するテンプレートデータを示すデー
タ図、図12は角度180度の画像を示す画像図、図1
3は図12の画像に対するテンプレートデータを示すデ
ータ図である。ここで、例えば一方向のみの射影データ
を用いた場合、図9のような左右対称の画像17を登録
画像として登録した場合には、図10のような角度0度
の画像18に対するテンプレートデータ19と図12の
ような角度180度の画像20に対するテンプレートデ
ータ21は等しくなり、正しく角度を検出することが困
難となる。そこで、複数方向(例えば、水平方向と垂直
方向の両方)に対し各列毎に画素数をカウントすること
により射影データを作成すると、左右対称な画像であっ
ても正確に入力画像の傾きを検出することができる。こ
のとき水平方向の射影データは、入力画像を角度90度
回転させたときの垂直方向の射影データと等しくなるた
め、垂直方向の射影データと角度K度のテンプレートデ
ータとを比較するとき、水平方向の射影データは角度K
+90度のテンプレートデータと比較を行えばよい。
In this embodiment, the projection data 12
Is obtained by counting the number of pixels in the vertical direction, but may be horizontal or oblique as long as they are in the same direction. Also, the directions may be plural. This will be described with reference to FIGS. 9 is an image diagram showing a registered image of right and left targets, FIG. 10 is an image diagram showing an image at an angle of 0 degree, and FIG.
1 is a data diagram showing template data for the image of FIG. 10, FIG. 12 is an image diagram showing an image at an angle of 180 degrees, and FIG.
FIG. 3 is a data diagram showing template data for the image of FIG. Here, for example, when projection data in only one direction is used, and when a symmetric image 17 as shown in FIG. 9 is registered as a registered image, template data 19 for an image 18 having an angle of 0 degrees as shown in FIG. And the template data 21 for the image 20 at an angle of 180 degrees as shown in FIG. 12 becomes equal, making it difficult to detect the angle correctly. Therefore, if projection data is created by counting the number of pixels for each column in a plurality of directions (for example, both the horizontal direction and the vertical direction), even if the image is symmetrical, the inclination of the input image can be accurately detected. can do. At this time, the projection data in the horizontal direction is equal to the projection data in the vertical direction when the input image is rotated by 90 degrees. Therefore, when comparing the projection data in the vertical direction with the template data at the angle K degrees, Projection data is angle K
What is necessary is just to compare with +90 degree template data.

【0049】以上のように本実施の形態によれば、画像
を入力する画像入力部1と、入力画像に対する所定サイ
ズのウィンドウ走査を行ってウィンドウデータを生成す
るウィンドウデータ生成部2と、生成したウィンドウデ
ータを2値化して2値化ウィンドウデータを生成する2
値化処理部3と、生成した2値化ウィンドウデータから
射影データを作成する射影データ作成部4と、作成した
射影データと予め登録しておいた複数のテンプレートデ
ータとの比較を行う射影データ比較部5と、射影データ
比較部5における比較結果により入力画像の回転角度を
検出する角度検出部6と、検出した回転角度を用いて入
力画像の回転角度を補正する角度補正部7と、角度補正
された入力画像と登録画像との一致度を判定する一致度
判定部8とを設けたことにより、射影データ12と複数
のテンプレートデータ10との比較に基づいて入力画像
の回転角度を検出することができるので、入力画像の回
転角度の検出を高速に行うことができ、その検出回転角
度に基づいて角度補正された入力画像中に登録画像があ
るか否かの検索を高速かつ高精度に行うことができる。
また、2値化処理部を多値化処理部とすれば、多値化ウ
ィンドウデータから射影データを作成することができる
ので、入力画像の回転角度の検出を更に高精度に行うこ
とができる。さらに、テンプレートデータの角度を6度
よりも小さい角度毎に設定するようにしたことにより、
テンプレートデータが高精度化されるので、入力画像の
回転角度の検出を更に高精度に行うことができる。さら
に、複数方向に対して画素値を計数するようにしたこと
におり、1方向に対する画素値の係数のみでは発生する
おそれのある誤りを防止することができるので、入力画
像の回転角度を更に正確に検出することができる。さら
に、一つの方向の射影データとテンプレートデータとの
比較結果により、他方向の射影データとテンプレートデ
ータとの比較結果を制御するようにしたことにより、1
方向に対する画素値の係数のみでは発生するおそれのあ
る誤りを防止することができるので、入力画像の回転角
度を更に正確に検出することができる。さらに、最大画
素数・最小画素数・標準偏差・平均画素数のいずれかを
用いて比較を行うようにしたことにより、全列の一致度
を求めなくても高速に非登録画像であることを判定する
ことができ、また登録画像の角度を高速に絞り込むこと
ができる。
As described above, according to the present embodiment, the image input unit 1 for inputting an image, the window data generating unit 2 for performing window scanning of a predetermined size on the input image to generate window data, and Binarize window data to generate binarized window data 2
A value processing unit 3, a projection data creation unit 4 for creating projection data from the generated binarized window data, and a projection data comparison for comparing the created projection data with a plurality of template data registered in advance. Unit 5, an angle detection unit 6 for detecting the rotation angle of the input image based on the comparison result in the projection data comparison unit 5, an angle correction unit 7 for correcting the rotation angle of the input image using the detected rotation angle, and angle correction Providing the coincidence determining unit 8 for determining the degree of coincidence between the input image and the registered image to detect the rotation angle of the input image based on a comparison between the projection data 12 and the plurality of template data 10 The rotation angle of the input image can be detected at a high speed, and a search for a registered image in the input image whose angle has been corrected based on the detected rotation angle can be performed. It can be performed quickly and accurately.
Further, if the binarization processing unit is a multi-level processing unit, projection data can be created from the multi-level window data, so that the rotation angle of the input image can be detected with higher accuracy. Furthermore, by setting the angle of the template data for each angle smaller than 6 degrees,
Since the accuracy of the template data is improved, the rotation angle of the input image can be detected with higher accuracy. Furthermore, since the pixel value is counted in a plurality of directions, it is possible to prevent an error that may occur only with the coefficient of the pixel value in one direction, so that the rotation angle of the input image can be more accurately determined. Can be detected. Further, the comparison result between the projection data in one direction and the template data is controlled based on the comparison result between the projection data in one direction and the template data.
It is possible to prevent an error that may occur only with the coefficient of the pixel value in the direction, so that the rotation angle of the input image can be detected more accurately. Furthermore, the comparison is performed using any of the maximum number of pixels, the minimum number of pixels, the standard deviation, and the average number of pixels. It is possible to make a determination and to narrow down the angle of the registered image at high speed.

【0050】(実施の形態2)以下、本発明の実施の形
態2について図14、図15を参照しながら説明する。
図14、図15は、本発明の実施の形態2による画像検
索方法を示すフローチャートである。なお、本実施の形
態における画像検索装置の構成は図1と同様の構成であ
り、実施の形態1とは動作が異なる。
(Embodiment 2) Hereinafter, Embodiment 2 of the present invention will be described with reference to FIGS.
FIGS. 14 and 15 are flowcharts showing an image search method according to the second embodiment of the present invention. The configuration of the image search device according to the present embodiment is the same as that of FIG. 1, and the operation is different from that of the first embodiment.

【0051】図14、図15において、まず、画像デー
タを入力し(S21)、入力された画像データに対し、
或る注目画素を中心とし所定サイズ(例えば25画素×
25画素)のウィンドウデータを作成し(S11、ウィ
ンドウデータ生成ステップ)、作成されたウィンドウデ
ータに対し、2値化処理(例えば、カラー画像信号の明
度を求め、その明度と所定の閾値との比較を行うことに
よる2値化処理)を行う(S23、2値化処理ステッ
プ)。次に、読み出すテンプレートデータを第1番目の
角度のテンプレートデータへ移動する(S24)。次
に、全てのテンプレートデータを読み出して比較したか
否かを判定する(S25)。最初は全てのテンプレート
データを読み出していないので、上記テンプレートデー
タおよび2値化処理されたウィンドウデータ(2値化ウ
ィンドウデータ)の第1列目を対象の列とし(S2
6)、2値化処理されたウィンドウデータの第1列目の
画素数「S」をカウントする(S27)。このとき上記
テンプレートデータの第1列目の値「T」を読み込む
(S28)。ここで上記ウィンドウデータの第1列目の
画素数「S」と上記テンプレートデータの第1列目の値
「T」とを比較し、差が或るしきい値以内(ここではし
きい値を5とする)であれば(S29)、SとTは類似
したものと判定し、次に全ての列について処理が行われ
たか否かを判定し(S30)、最初はウィンドウデータ
内の全ての列を比較処理していないので、次の列へ移動
する(S31)。同様にして上記ウィンドウデータの第
i列目の画素数「S」をカウントし(S27)、上記テ
ンプレートデータの第i列目の値「T」を読み込み(S
28)、SとTが類似していれば(S29)、更に次の
列の処理を行い、ウィンドウ内の全ての列を比較処理し
(S30)、全ての列においてSとTが類似していれ
ば、そのときの上記テンプレートデータに対応する角度
と全列の比較結果の総和とを抽出する(S32)。ま
た、列毎にSとTとの比較を行い、いずれか1列でもS
とTとの差がしきい値(5)を超すと(S29)、上記
テンプレートデータとウィンドウデータとは全く異なる
ものと判定し、次の角度のテンプレートデータとの比較
を行う(S33)。同様にして、全ての角度のテンプレ
ートデータとウィンドウデータとの比較を列毎の画素数
で比較し、全列で類似したテンプレートデータに対応し
た角度と全列の比較結果の総和とを求める(S32)。
全ての角度のテンプレートデータとウィンドウデータと
の比較が終了すると(S25、射影データ比較ステッ
プ)、上記ステップS32により求めた全比較結果の総
和中で最も値が小さくなる(ウィンドウデータと最も類
似した)テンプレートデータに対応した角度を抽出する
(S34、角度検出ステップ)。前記ステップS34に
より求めた角度に応じてウィンドウデータの角度補正を
行い(S35)、角度補正後のデータと登録画像とのマ
ッチングを行い(S36、一致度判定ステップ)、入力
画像が登録画像と一致しているか否かの判定を行う。あ
る注目画素に対し、ステップS22からステップS36
までの一連の処理が終了し、次の注目画素が存在すると
(S37)、注目画素へ移動し(S38)、次の注目画
素に対し、ステップS22からステップS36までの処
理を繰り返す。同様にして全ての画素に対しステップS
22からステップS36までの処理を行い、全ての注目
画素に対し処理が終了すると(S37)、検索処理が終
了する。なお、ステップS24〜S31は射影データ作
成ステップを構成する。
Referring to FIGS. 14 and 15, first, image data is input (S21).
A predetermined size (for example, 25 pixels ×
Window data (25 pixels) is created (S11, window data generation step), and the created window data is binarized (for example, the brightness of a color image signal is obtained, and the brightness is compared with a predetermined threshold value). (S23, binarization processing step). Next, the template data to be read is moved to the template data of the first angle (S24). Next, it is determined whether all the template data have been read and compared (S25). Since not all the template data has been read out at first, the first column of the template data and the binarized window data (binary window data) is set as a target column (S2
6) The number of pixels "S" in the first column of the binarized window data is counted (S27). At this time, the value "T" in the first column of the template data is read (S28). Here, the number of pixels “S” in the first column of the window data is compared with the value “T” in the first column of the template data, and the difference is within a certain threshold (here, the threshold is 5) (S29), it is determined that S and T are similar, then it is determined whether or not the processing has been performed for all columns (S30), and at first, all the columns in the window data are determined. Since the columns are not compared, the process moves to the next column (S31). Similarly, the number of pixels "S" in the i-th column of the window data is counted (S27), and the value "T" in the i-th column of the template data is read (S27).
28), if S and T are similar (S29), the process for the next column is further performed, all columns in the window are compared (S30), and S and T are similar in all columns. If so, the angle corresponding to the template data at that time and the sum of the comparison results of all the columns are extracted (S32). Further, S and T are compared for each column, and S
When the difference between T and T exceeds the threshold value (5) (S29), it is determined that the template data is completely different from the window data, and the template data at the next angle is compared (S33). Similarly, the comparison between the template data of all angles and the window data is performed by the number of pixels for each column, and the angles corresponding to the template data similar in all columns and the sum of the comparison results of all columns are obtained (S32). ).
When the comparison between the template data of all angles and the window data is completed (S25, projection data comparison step), the value becomes the smallest in the sum of all the comparison results obtained in step S32 (similar to the window data). An angle corresponding to the template data is extracted (S34, angle detection step). The angle of the window data is corrected in accordance with the angle obtained in step S34 (S35), the data after the angle correction is matched with the registered image (S36, matching degree determination step), and the input image is compared with the registered image. A judgment is made as to whether or not they have been performed. Step S22 to step S36 for a certain pixel of interest
When a series of processes up to and including the next pixel of interest is present (S37), the process moves to the pixel of interest (S38), and the processes from step S22 to step S36 are repeated for the next pixel of interest. Step S is performed for all pixels in the same manner.
The processing from 22 to step S36 is performed, and when the processing is completed for all the target pixels (S37), the search processing ends. Steps S24 to S31 constitute a projection data creation step.

【0052】なお、本実施の形態では、射影データは垂
直方向の画素数をカウントすることにより求めている
が、同一方向であれば水平方向や斜め方向であってもよ
い。また複数方向でもよい。例えば一方向のみの射影デ
ータを用いた場合、図9のような左右対称の画像17を
登録画像として登録した場合には、図10の角度0度の
画像18に対するテンプレートデータ19と図12の角
度180度の画像20に対するテンプレートデータ21
は等しくなり、正しく角度を検出することが困難とな
る。そこで、複数方向(例えば、水平方向と垂直方向の
両方)に対し各列毎に画素数をカウントすることにより
射影データを作成すると、左右対称な画像であっても正
確に入力画像の傾きを検出することができる。このとき
水平方向の射影データは、入力画像を角度90度回転さ
せたときの垂直方向の射影データと等しくなるため、垂
直方向の射影データと角度K度のテンプレートデータと
の比較を行うとき、水平方向の射影データは角度K+9
0度のテンプレートデータとの比較を行えばよい。
In the present embodiment, the projection data is obtained by counting the number of pixels in the vertical direction. However, the projection data may be in the horizontal direction or in the oblique direction as long as they are in the same direction. Also, the directions may be plural. For example, when projection data in only one direction is used, and when a symmetric image 17 as shown in FIG. 9 is registered as a registered image, the template data 19 for the image 18 having an angle of 0 degrees in FIG. Template data 21 for 180 degree image 20
Are equal, and it is difficult to detect the angle correctly. Therefore, if projection data is created by counting the number of pixels for each column in a plurality of directions (for example, both the horizontal direction and the vertical direction), even if the image is symmetrical, the inclination of the input image can be accurately detected. can do. At this time, the horizontal projection data is equal to the vertical projection data when the input image is rotated by an angle of 90 degrees. Therefore, when comparing the vertical projection data with the template data at an angle of K degrees, The direction projection data is angle K + 9
What is necessary is just to compare with the template data of 0 degree.

【0053】また、本実施の形態では、射影データとテ
ンプレートデータとの比較において、列毎に比較を行っ
ているが、複数の列毎に比較し、射影データに最も類似
したテンプレートデータを求めてもよい。また複数方向
の画素値をカウントすることにより射影データを作成し
ている場合、角度毎に比較を行うことにより、ある方向
での射影データとテンプレートデータとの比較結果によ
り、他の方向の射影データとテンプレートデータとの比
較を制御することができる。例えば、垂直方向の射影デ
ータを用いて比較結果が小さくなる上位5個のテンプレ
ートデータを抽出することにより角度の絞り込みを行
い、次に、水平方向の射影データを用いて、前記求めた
上位5個の角度に対し比較処理を行うことにより処理の
高速化を図ることができる。
Further, in the present embodiment, the comparison between the projection data and the template data is performed for each column. However, the comparison is performed for each of a plurality of columns, and the template data most similar to the projection data is obtained. Is also good. If projection data is created by counting pixel values in a plurality of directions, the projection data in one direction is compared with the projection data in a certain direction by comparing the projection data in one direction with the template data by performing a comparison for each angle. And the template data can be controlled. For example, the angle is narrowed down by extracting the top five template data with a smaller comparison result using the vertical projection data, and then using the horizontal projection data, By performing the comparison processing for the angle of, the processing can be sped up.

【0054】また、ウィンドウデータ内の標準偏差や全
画素数、列毎の平均画素数(=全画素数÷N列)は、回
転角度に依存しないことから、2値化されたウィンドウ
データから全画素数を求め、登録画像の全画素数と比較
し、(4)式を満たすとき、ウィンドウデータが登録画
像の全画素数と一致しているものとし、射影データ比較
部5・角度検出部6・角度補正部7・一致度判定部8の
各処理を行い、登録画像と一致しているか否かの判定を
行う。
The standard deviation, the total number of pixels, and the average number of pixels per column (= the total number of pixels / N columns) in the window data do not depend on the rotation angle. The number of pixels is obtained and compared with the total number of pixels of the registered image. When Expression (4) is satisfied, it is assumed that the window data matches the total number of pixels of the registered image, and the projection data comparing unit 5 and the angle detecting unit 6 The respective processes of the angle correction unit 7 and the coincidence determination unit 8 are performed to determine whether or not they match the registered image.

【0055】H−TH<U<H+TH・・・・・(4) (4)式において、Hは登録画像の全画素数であり、U
はウィンドウデータ内の全画素数、THはしきい値(こ
こでは50)である。上記画素数の比較が(4)式を満
たさないとき、射影データ比較部5・角度検出部6・角
度補正部7・一致度判定部8の各処理を行わず、登録画
像と一致しないものと判定する。
H-TH <U <H + TH (4) In the equation (4), H is the total number of pixels of the registered image.
Is the total number of pixels in the window data, and TH is a threshold value (here, 50). When the comparison of the number of pixels does not satisfy the expression (4), the processing of the projection data comparison unit 5, the angle detection unit 6, the angle correction unit 7, and the coincidence determination unit 8 is not performed, and it is determined that the image does not match the registered image. judge.

【0056】上記(4)式の比較は全画素数を用いてい
るが、先に説明したように、標準偏差や平均画素数のい
ずれかを用いてもよい。以上により、登録画像とは異な
る画像が入力されたとき、角度補正やマッチングを行う
ことがなく、処理の高速化を図ることができる。
Although the comparison of the above equation (4) uses the total number of pixels, any of the standard deviation and the average number of pixels may be used as described above. As described above, when an image different from the registered image is input, the processing can be speeded up without performing angle correction or matching.

【0057】また、射影データ比較部において、2値化
されたウィンドウデータの最大画素数(または最小画素
数)が存在する列を求め、各角度のテンプレートデータ
の中から上記求めた列に最大画素数(または最小画素
数)が存在するテンプレートデータを抽出し、上記抽出
したテンプレートデータに対してのみ、射影データの全
列とテンプレートデータとの比較を行うことにより、テ
ンプレートデータの比較処理の高速化を図ることができ
る。
Further, in the projection data comparing section, a column in which the maximum number of pixels (or the minimum number of pixels) of the binarized window data exists is determined. Speeding up the template data comparison process by extracting template data having a number (or the minimum number of pixels) and comparing only the extracted template data with all the columns of projection data and the template data; Can be achieved.

【0058】以上のように本実施の形態では、最大画素
数(または最小画素数)を用いることにより、全角度の
テンプレートデータとの比較を行うことがなく、高速に
角度の検出が可能となる。
As described above, in the present embodiment, by using the maximum number of pixels (or the minimum number of pixels), the angle can be detected at high speed without comparison with the template data of all angles. .

【0059】(実施の形態3)図16は本発明の実施の
形態3による画像検索装置を示すブロック図である。図
16において、31はCPU、32はディスプレイ、3
3はメモリ、34はスキャナ、35はハードディスク、
36はフロッピーディスクドライブ、37はMOディス
クドライブ、38はCD−ROMディスクドライブであ
る。
(Embodiment 3) FIG. 16 is a block diagram showing an image retrieval apparatus according to Embodiment 3 of the present invention. In FIG. 16, 31 is a CPU, 32 is a display, 3
3 is a memory, 34 is a scanner, 35 is a hard disk,
36 is a floppy disk drive, 37 is an MO disk drive, and 38 is a CD-ROM disk drive.

【0060】フロッピーディスクドライブ36、MOデ
ィスクドライブ37またはCD−ROMディスクドライ
ブ38などのコンピュータ読み取り可能な記録媒体に
は、実施の形態1、2で記載した射影データを用いた画
像検索方法を実現するプログラムが記録されており、こ
のプログラムをCPU31が実行することにより図1の
各構成1〜8が実現される。すなわち、スキャナ34な
どから画像が入力され、ハードディスク35などに一時
的に格納される。ここで、上記プログラムが実行される
と、格納された画像データが読み込まれ、射影データを
用いた画像検索処理が実行され、その結果がディスプレ
イ32などに出力される。
The computer-readable recording medium such as the floppy disk drive 36, MO disk drive 37 or CD-ROM disk drive 38 realizes the image search method using the projection data described in the first and second embodiments. A program is recorded, and each configuration 1 to 8 in FIG. 1 is realized by the CPU 31 executing the program. That is, an image is input from the scanner 34 or the like, and is temporarily stored in the hard disk 35 or the like. Here, when the program is executed, the stored image data is read, an image search process using the projection data is executed, and the result is output to the display 32 or the like.

【0061】以上のように本実施の形態によれば、入力
画像に対する所定サイズのウィンドウ走査を行ってウィ
ンドウデータを生成するウィンドウデータ生成ステップ
と、生成したウィンドウデータから射影データを作成す
る射影データ作成ステップと、作成した射影データと予
め登録しておいた複数のテンプレートデータとの比較を
行う射影データ比較ステップと、射影データ比較ステッ
プにおける比較結果により入力画像の回転角度を検出す
る角度検出ステップと、回転角度を用いて入力画像と登
録画像との一致度を判定する一致度判定ステップと、を
実行させるためのプログラムを記録したことにより、入
力画像中に登録画像があるか否かの検索を高速かつ高精
度に行うことができる画像検索方法を任意の場所・期間
に行うことができる。
As described above, according to the present embodiment, a window data generating step of performing window scanning of a predetermined size on an input image to generate window data, and a projection data generating step of generating projection data from the generated window data Step, a projection data comparison step of comparing the created projection data with a plurality of template data registered in advance, and an angle detection step of detecting the rotation angle of the input image based on the comparison result in the projection data comparison step, A degree of coincidence determining step of determining a degree of coincidence between the input image and the registered image using the rotation angle; and a program for executing the same. It is possible to perform an image search method that can be performed with high accuracy at any place and period. .

【0062】[0062]

【発明の効果】以上説明したように本発明の請求項1に
記載の画像検索装置によれば、予め登録しておいた登録
画像が入力画像中に存在するか否かの検索を行う画像検
索装置であって、画像を入力する画像入力部と、入力画
像に対する所定サイズのウィンドウ走査を行ってウィン
ドウデータを生成するウィンドウデータ生成部と、生成
したウィンドウデータから射影データを作成する射影デ
ータ作成部と、作成した射影データと予め登録しておい
た複数のテンプレートデータとの比較を行う射影データ
比較部と、射影データ比較部における比較結果により入
力画像の回転角度を検出する角度検出部と、回転角度を
用いて入力画像と登録画像との一致度を判定する一致度
判定部と、を有することにより、射影データと複数のテ
ンプレートデータとの比較に基づいて入力画像の回転角
度を検出するので、入力画像の回転角度の検出を高速化
することができ、その検出回転角度に基づいて回転角度
が補正された入力画像中に登録画像があるか否かの検索
を高速かつ高精度に行うことができるという有利な効果
が得られる。
As described above, according to the image search apparatus of the first aspect of the present invention, an image search for searching whether or not a registered image registered in advance exists in an input image. An image input unit for inputting an image, a window data generating unit for performing window scanning of a predetermined size on the input image to generate window data, and a projection data generating unit for generating projection data from the generated window data A projection data comparison unit that compares the created projection data with a plurality of template data registered in advance; an angle detection unit that detects a rotation angle of the input image based on a comparison result in the projection data comparison unit; A coincidence determination unit that determines the degree of coincidence between the input image and the registered image using the angle, and the projection data and the plurality of template data Since the rotation angle of the input image is detected based on the comparison of the input image, the rotation angle of the input image can be detected at a high speed, and the registered image is included in the input image whose rotation angle is corrected based on the detected rotation angle. An advantageous effect is obtained that the search for presence or absence can be performed at high speed and with high accuracy.

【0063】請求項2に記載の画像検索方法によれば、
予め登録しておいた登録画像が入力画像中に存在するか
否かの検索を行う画像検索方法であって、入力画像に対
する所定サイズのウィンドウ走査を行ってウィンドウデ
ータを生成するウィンドウデータ生成ステップと、生成
したウィンドウデータから射影データを作成する射影デ
ータ作成ステップと、作成した射影データと予め登録し
ておいた複数のテンプレートデータとの比較を行う射影
データ比較ステップと、射影データ比較ステップにおけ
る比較結果により入力画像の回転角度を検出する角度検
出ステップと、前記回転角度を用いて入力画像と登録画
像との一致度を判定する一致度判定ステップと、を有す
ることにより、射影データと複数のテンプレートデータ
との比較に基づいて入力画像の回転角度を検出するの
で、入力画像の回転角度の検出を高速化することがで
き、その検出回転角度に基づいて回転角度が補正された
入力画像中に登録画像があるか否かの検索を高速かつ高
精度に行うことができるという有利な効果が得られる。
According to the image search method of the second aspect,
An image search method for searching whether a registered image registered in advance exists in an input image, wherein a window data generating step of performing window scanning of a predetermined size on the input image to generate window data. A projection data creation step of creating projection data from the generated window data, a projection data comparison step of comparing the created projection data with a plurality of template data registered in advance, and a comparison result in the projection data comparison step An angle detection step of detecting a rotation angle of the input image, and a coincidence degree determination step of determining a degree of coincidence between the input image and the registered image using the rotation angle. The rotation angle of the input image is detected based on the comparison with It is advantageous that the speed of the degree detection can be increased, and the search for the registered image in the input image whose rotation angle has been corrected based on the detected rotation angle can be performed at high speed and with high accuracy. The effect is obtained.

【0064】請求項3に記載の画像検索方法によれば、
予め登録しておいた登録画像が入力画像中に存在するか
否かの検索を行う画像検索方法であって、入力画像に対
する所定サイズのウィンドウ走査を行ってウィンドウデ
ータを生成するウィンドウデータ生成ステップと、生成
したウィンドウデータに対して2値化を行って2値化ウ
ィンドウデータを生成する2値化処理ステップと、生成
した2値化ウィンドウデータから射影データを作成する
射影データ作成ステップと、作成した射影データと予め
登録しておいた複数のテンプレートデータとの比較を行
う射影データ比較ステップと、射影データ比較ステップ
における比較結果により入力画像の回転角度を検出する
角度検出ステップと、回転角度を用いて入力画像と登録
画像との一致度を判定する一致度判定ステップと、を有
することにより、2値化ウィンドウデータから射影デー
タを作成するので、入力画像の回転角度の検出を更に高
速に行うことができるという有利な効果が得られる。
According to the image search method of the third aspect,
An image search method for searching whether a registered image registered in advance exists in an input image, wherein a window data generating step of performing window scanning of a predetermined size on the input image to generate window data. A binarization processing step of performing binarization on the generated window data to generate binarized window data; a projection data generating step of generating projection data from the generated binarized window data; A projection data comparison step of comparing the projection data with a plurality of template data registered in advance, an angle detection step of detecting a rotation angle of the input image based on a comparison result in the projection data comparison step, and using the rotation angle. A matching degree determining step of determining a matching degree between the input image and the registered image, Since creating a projection data from the binarized window data, is advantageous effect that the detection of the rotation angle of the input image can be further performed at a high speed is obtained.

【0065】請求項4に記載の画像検索方法によれば、
予め登録しておいた登録画像が入力画像中に存在するか
否かの検索を行う画像検索方法であって、入力画像に対
する所定サイズのウィンドウ走査を行ってウィンドウデ
ータを生成するウィンドウデータ生成ステップと、生成
したウィンドウデータに対して多値化を行って多値化ウ
ィンドウデータを生成する多値化処理ステップと、生成
した多値化ウィンドウデータから射影データを作成する
射影データ作成ステップと、作成した射影データと予め
登録しておいた複数のテンプレートデータとの比較を行
う射影データ比較ステップと、射影データ比較ステップ
における比較結果により入力画像の回転角度を検出する
角度検出ステップと、回転角度を用いて入力画像と登録
画像との一致度を判定する一致度判定ステップと、を有
することにより、多値化ウィンドウデータから射影デー
タを作成するので、入力画像の回転角度の検出を更に高
精度に行うことができるという有利な効果が得られる。
According to the image search method of the fourth aspect,
An image search method for searching whether a registered image registered in advance exists in an input image, wherein a window data generating step of performing window scanning of a predetermined size on the input image to generate window data. A multi-level processing step of performing multi-level processing on the generated window data to generate multi-level window data; a projection data generating step of generating projection data from the generated multi-level window data; A projection data comparison step of comparing the projection data with a plurality of template data registered in advance, an angle detection step of detecting a rotation angle of the input image based on a comparison result in the projection data comparison step, and using the rotation angle. A matching degree determining step of determining a matching degree between the input image and the registered image, Since creating a projection data from the binarized window data, is advantageous effect that it is possible to perform more accurate detection of the rotational angle of the input image is obtained.

【0066】請求項5に記載の画像検索方法によれば、
請求項2乃至4のいずれか1に記載の画像検索方法にお
いて、射影データ比較ステップにおいては、テンプレー
トデータの角度は6度よりも小さい角度毎に設定される
ことにより、テンプレートデータが高精度化されるの
で、入力画像の回転角度の検出を更に高精度に行うこと
ができるという有利な効果が得られる。
According to the image search method of the fifth aspect,
In the image search method according to any one of claims 2 to 4, in the projection data comparison step, the template data is set at an angle smaller than 6 degrees, thereby improving the accuracy of the template data. Therefore, an advantageous effect that the rotation angle of the input image can be detected with higher accuracy can be obtained.

【0067】請求項6に記載の画像検索方法によれば、
請求項2乃至5のいずれか1に記載の画像検索方法にお
いて、射影データ比較ステップにおいては、作成した射
影データとテンプレートデータとの差が所定値以上の場
合には次のテンプレートデータとの比較へ移行すること
により、入力画像と一致する可能性の無いテンプレート
データとの比較が省略されるので、入力画像の回転角度
の検出を更にいっそう高速化することができるという有
利な効果が得られる。
According to the image search method of the sixth aspect,
In the image search method according to any one of claims 2 to 5, in the projection data comparison step, when a difference between the created projection data and the template data is equal to or larger than a predetermined value, the comparison with the next template data is performed. By shifting, the comparison with the template data that is unlikely to match the input image is omitted, and the advantageous effect that the detection of the rotation angle of the input image can be further accelerated is obtained.

【0068】請求項7に記載の画像検索方法によれば、
請求項2乃至6のいずれか1に記載の画像検索方法にお
いて、射影データ作成ステップにおいては、複数方向に
対して画素値を計数することにより、1方向に対する画
素値の係数のみでは発生するおそれのある誤りが防止さ
れるので、入力画像の回転角度を更に正確に検出するこ
とができるという有利な効果が得られる。
According to the image search method of the present invention,
In the image search method according to any one of claims 2 to 6, in the projection data creation step, by counting pixel values in a plurality of directions, there is a possibility that only the coefficient of the pixel value in one direction will occur. Since a certain error is prevented, the advantageous effect that the rotation angle of the input image can be detected more accurately is obtained.

【0069】請求項8に記載の画像検索方法によれば、
請求項7に記載の画像検索方法において、射影データ比
較ステップにおいては、一つの方向の射影データとテン
プレートデータとの比較結果により、他方向の射影デー
タとテンプレートデータとの比較結果を制御することに
より、他方向における検索角度を絞り込むことができる
ので、入力画像の回転角度を更にいっそう高速に検索す
ることができるという有利な効果が得られる。
According to the image search method of the eighth aspect,
8. The image search method according to claim 7, wherein in the projection data comparison step, the comparison result between the projection data in one direction and the template data is controlled based on the comparison result between the projection data in one direction and the template data. Since the search angle in the other direction can be narrowed down, an advantageous effect that the rotation angle of the input image can be searched at higher speed can be obtained.

【0070】請求項9に記載の画像検索方法によれば、
請求項2乃至8のいずれか1に記載の画像検索方法にお
いて、射影データ比較ステップにおいては、最大画素数
・最小画素数・標準偏差・平均画素数のいずれかを用い
て比較を行うことにより、全列の一致度を求めなくても
高速に非登録画像であることを判定することができ、ま
た登録画像の角度を高速に絞り込むことができるという
有利な効果が得られる。
According to the image search method of the ninth aspect,
In the image search method according to any one of claims 2 to 8, in the projection data comparison step, the comparison is performed by using any of the maximum number of pixels, the minimum number of pixels, the standard deviation, and the average number of pixels. It is possible to determine the non-registered image at high speed without obtaining the degree of coincidence of all columns, and it is possible to obtain an advantageous effect that the angle of the registered image can be narrowed down at high speed.

【0071】請求項10に記載の記録媒体によれば、予
め登録しておいた登録画像が入力画像中に存在するか否
かの検索を行う画像検索方法を実行させる記録媒体であ
って、入力画像に対する所定サイズのウィンドウ走査を
行ってウィンドウデータを生成するウィンドウデータ生
成ステップと、生成したウィンドウデータから射影デー
タを作成する射影データ作成ステップと、作成した射影
データと予め登録しておいた複数のテンプレートデータ
との比較を行う射影データ比較ステップと、射影データ
比較ステップにおける比較結果により入力画像の回転角
度を検出する角度検出ステップと、回転角度を用いて入
力画像と登録画像との一致度を判定する一致度判定ステ
ップと、を実行させるためのプログラムを記録したこと
により、入力画像中に登録画像があるか否かの検索を高
速かつ高精度に行うことができる画像検索方法を任意の
場所・期間に行うことができるという有利な効果が得ら
れる。
According to the recording medium of the tenth aspect, there is provided a recording medium for executing an image search method for searching whether or not a registered image registered in advance exists in an input image. A window data generating step of performing window scanning of a predetermined size on an image to generate window data; a projection data generating step of generating projection data from the generated window data; and a plurality of pre-registered projection data and the generated projection data. A projection data comparison step for comparing with the template data; an angle detection step for detecting a rotation angle of the input image based on a comparison result in the projection data comparison step; and determining a degree of coincidence between the input image and the registered image using the rotation angle And a program for executing the matching degree determination step. Advantageous effect that the search of whether there is a registration image can perform image retrieval method capable of performing fast and accurate anywhere-periods are obtained.

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

【図1】本発明の実施の形態1による画像検索装置を示
すブロック図
FIG. 1 is a block diagram showing an image search device according to a first embodiment of the present invention.

【図2】図1の画像検索装置の動作を示すフローチャー
FIG. 2 is a flowchart showing the operation of the image search device in FIG. 1;

【図3】検出すべき登録画像を示す画像図FIG. 3 is an image diagram showing a registered image to be detected.

【図4】登録画像に対する各角度のテンプレートデータ
を示す角度テンプレート対応図
FIG. 4 is an angle template correspondence diagram showing template data of each angle with respect to a registered image.

【図5】入力画像に対する所定サイズのウィンドウ内の
画像を示す画像図
FIG. 5 is an image diagram showing an image in a window of a predetermined size with respect to the input image.

【図6】図5の画像に対する射影データを示すデータ図FIG. 6 is a data diagram showing projection data for the image of FIG. 5;

【図7】図5の画像の角度を補正した後の画像を示す画
像図
FIG. 7 is an image diagram showing an image after correcting the angle of the image in FIG. 5;

【図8】円の中心画素の検出方法の説明図FIG. 8 is an explanatory diagram of a method of detecting a center pixel of a circle.

【図9】左右対象の登録画像を示す画像図FIG. 9 is an image diagram showing a registered image of right and left targets.

【図10】角度0度の画像を示す画像図FIG. 10 is an image diagram showing an image at an angle of 0 degree.

【図11】図10の画像に対するテンプレートデータを
示すデータ図
FIG. 11 is a data diagram showing template data for the image of FIG. 10;

【図12】角度180度の画像を示す画像図FIG. 12 is an image diagram showing an image at an angle of 180 degrees.

【図13】図12の画像に対するテンプレートデータを
示すデータ図
FIG. 13 is a data diagram showing template data for the image of FIG. 12;

【図14】本発明の実施の形態2による画像検索方法を
示すフローチャート
FIG. 14 is a flowchart showing an image search method according to the second embodiment of the present invention.

【図15】本発明の実施の形態2による画像検索方法を
示すフローチャート
FIG. 15 is a flowchart showing an image search method according to the second embodiment of the present invention.

【図16】本発明の実施の形態3による画像検索装置を
示すブロック図
FIG. 16 is a block diagram showing an image search device according to a third embodiment of the present invention.

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

1 画像入力部 2 ウィンドウデータ生成部 3 2値化処理部 4 射影データ作成部 5 射影データ比較部 6 角度検出部 7 角度補正部 8 一致度判定部 31 CPU 32 ディスプレイ 33 メモリ 34 スキャナ 35 ハードディスク 36 フロッピーディスクドライブ 37 MOディスクドライブ 38 CD−ROMディスクドライブ DESCRIPTION OF SYMBOLS 1 Image input part 2 Window data generation part 3 Binarization processing part 4 Projection data creation part 5 Projection data comparison part 6 Angle detection part 7 Angle correction part 8 Matching degree judgment part 31 CPU 32 Display 33 Memory 34 Scanner 35 Hard disk 36 Floppy Disk drive 37 MO disk drive 38 CD-ROM disk drive

Claims (10)

【特許請求の範囲】[Claims] 【請求項1】予め登録しておいた登録画像が入力画像中
に存在するか否かの検索を行う画像検索装置であって、
画像を入力する画像入力部と、前記入力画像に対する所
定サイズのウィンドウ走査を行ってウィンドウデータを
生成するウィンドウデータ生成部と、前記生成したウィ
ンドウデータから射影データを作成する射影データ作成
部と、前記作成した射影データと予め登録しておいた複
数のテンプレートデータとの比較を行う射影データ比較
部と、前記射影データ比較部における比較結果により前
記入力画像の回転角度を検出する角度検出部と、前記回
転角度を用いて前記入力画像と前記登録画像との一致度
を判定する一致度判定部と、を有することを特徴とする
画像検索装置。
1. An image search apparatus for searching whether a registered image registered in advance exists in an input image,
An image input unit that inputs an image, a window data generation unit that performs window scanning of a predetermined size on the input image to generate window data, a projection data creation unit that creates projection data from the generated window data, A projection data comparison unit that compares the created projection data with a plurality of template data registered in advance, an angle detection unit that detects a rotation angle of the input image based on a comparison result in the projection data comparison unit, An image search device, comprising: a coincidence determining unit that determines a degree of coincidence between the input image and the registered image using a rotation angle.
【請求項2】予め登録しておいた登録画像が入力画像中
に存在するか否かの検索を行う画像検索方法であって、
前記入力画像に対する所定サイズのウィンドウ走査を行
ってウィンドウデータを生成するウィンドウデータ生成
ステップと、前記生成したウィンドウデータから射影デ
ータを作成する射影データ作成ステップと、前記作成し
た射影データと予め登録しておいた複数のテンプレート
データとの比較を行う射影データ比較ステップと、前記
射影データ比較ステップにおける比較結果により前記入
力画像の回転角度を検出する角度検出ステップと、前記
回転角度を用いて前記入力画像と前記登録画像との一致
度を判定する一致度判定ステップと、を有することを特
徴とする画像検索方法。
2. An image search method for searching whether a registered image registered in advance exists in an input image,
A window data generating step of performing window scanning of a predetermined size on the input image to generate window data, a projection data generating step of generating projection data from the generated window data, and registering the generated projection data in advance. A projection data comparison step of comparing the input image with a plurality of template data, an angle detection step of detecting a rotation angle of the input image based on a comparison result in the projection data comparison step, and the input image using the rotation angle. A matching degree determining step of determining a matching degree with the registered image.
【請求項3】予め登録しておいた登録画像が入力画像中
に存在するか否かの検索を行う画像検索方法であって、
前記入力画像に対する所定サイズのウィンドウ走査を行
ってウィンドウデータを生成するウィンドウデータ生成
ステップと、前記生成したウィンドウデータに対して2
値化を行って2値化ウィンドウデータを生成する2値化
処理ステップと、前記生成した2値化ウィンドウデータ
から射影データを作成する射影データ作成ステップと、
前記作成した射影データと予め登録しておいた複数のテ
ンプレートデータとの比較を行う射影データ比較ステッ
プと、前記射影データ比較ステップにおける比較結果に
より前記入力画像の回転角度を検出する角度検出ステッ
プと、前記回転角度を用いて前記入力画像と前記登録画
像との一致度を判定する一致度判定ステップと、を有す
ることを特徴とする画像検索方法。
3. An image search method for searching whether a registered image registered in advance exists in an input image,
A window data generating step of performing window scanning of a predetermined size on the input image to generate window data;
A binarization processing step of performing binarization to generate binarized window data; a projection data creating step of creating projection data from the generated binarized window data;
A projection data comparison step of comparing the created projection data with a plurality of template data registered in advance, and an angle detection step of detecting a rotation angle of the input image based on a comparison result in the projection data comparison step, A matching degree determining step of determining a matching degree between the input image and the registered image using the rotation angle.
【請求項4】予め登録しておいた登録画像が入力画像中
に存在するか否かの検索を行う画像検索方法であって、
前記入力画像に対する所定サイズのウィンドウ走査を行
ってウィンドウデータを生成するウィンドウデータ生成
ステップと、前記生成したウィンドウデータに対して多
値化を行って多値化ウィンドウデータを生成する多値化
処理ステップと、前記生成した多値化ウィンドウデータ
から射影データを作成する射影データ作成ステップと、
前記作成した射影データと予め登録しておいた複数のテ
ンプレートデータとの比較を行う射影データ比較ステッ
プと、前記射影データ比較ステップにおける比較結果に
より前記入力画像の回転角度を検出する角度検出ステッ
プと、前記回転角度を用いて前記入力画像と前記登録画
像との一致度を判定する一致度判定ステップと、を有す
ることを特徴とする画像検索方法。
4. An image search method for searching whether a registered image registered in advance exists in an input image,
A window data generating step of performing window scanning of a predetermined size on the input image to generate window data; and a multi-level processing step of performing multi-level processing on the generated window data to generate multi-level window data Projecting data creating step of creating projection data from the generated multi-valued window data,
A projection data comparison step of comparing the created projection data with a plurality of template data registered in advance, and an angle detection step of detecting a rotation angle of the input image based on a comparison result in the projection data comparison step, A matching degree determining step of determining a matching degree between the input image and the registered image using the rotation angle.
【請求項5】前記射影データ比較ステップにおいて、テ
ンプレートデータの角度は6度よりも小さい角度毎に設
定されることを特徴とする請求項2乃至4のいずれか1
に記載の画像検索方法。
5. The projection data comparing step, wherein an angle of the template data is set for each angle smaller than 6 degrees.
Image search method described in.
【請求項6】前記射影データ比較ステップにおいて、前
記作成した射影データとテンプレートデータとの差が所
定値以上の場合には次のテンプレートデータとの比較へ
移行することを特徴とする請求項2乃至5のいずれか1
に記載の画像検索方法。
6. In the projection data comparison step, if the difference between the created projection data and the template data is equal to or greater than a predetermined value, the processing shifts to comparison with the next template data. Any one of 5
Image search method described in.
【請求項7】前記射影データ作成ステップにおいて、複
数方向に対して画素値を計数することを特徴とする請求
項2乃至6のいずれか1に記載の画像検索方法。
7. The image search method according to claim 2, wherein pixel values are counted in a plurality of directions in the projection data creation step.
【請求項8】前記射影データ比較ステップにおいて、一
つの方向の射影データとテンプレートデータとの比較結
果により、他方向の射影データとテンプレートデータと
の比較結果を制御することを特徴とする請求項7に記載
の画像検索方法。
8. The comparison of the projection data in one direction with the template data based on the comparison result of the projection data in one direction with the template data in the projection data comparison step. Image search method described in.
【請求項9】前記射影データ比較ステップにおいて、最
大画素数・最小画素数・標準偏差・平均画素数のいずれ
かを用いて比較を行うことを特徴とする請求項2乃至8
のいずれか1に記載の画像検索方法。
9. The method according to claim 2, wherein in the projection data comparison step, the comparison is performed using any one of a maximum number of pixels, a minimum number of pixels, a standard deviation, and an average number of pixels.
The image search method according to any one of the above.
【請求項10】予め登録しておいた登録画像が入力画像
中に存在するか否かの検索を行う画像検索方法を実行さ
せる記録媒体であって、前記入力画像に対する所定サイ
ズのウィンドウ走査を行ってウィンドウデータを生成す
るウィンドウデータ生成ステップと、前記生成したウィ
ンドウデータから射影データを作成する射影データ作成
ステップと、前記作成した射影データと予め登録してお
いた複数のテンプレートデータとの比較を行う射影デー
タ比較ステップと、前記射影データ比較ステップにおけ
る比較結果により前記入力画像の回転角度を検出する角
度検出ステップと、前記回転角度を用いて前記入力画像
と前記登録画像との一致度を判定する一致度判定ステッ
プと、を実行させるためのプログラムを記録したことを
特徴とする記録媒体。
10. A recording medium for executing an image search method for searching whether or not a registered image registered in advance exists in an input image, wherein a window scan of a predetermined size is performed on the input image. Window data generating step of generating window data by using the above-mentioned generated window data, and projecting data generating step of generating projection data from the generated window data, and comparing the generated projection data with a plurality of template data registered in advance. A projection data comparison step, an angle detection step of detecting a rotation angle of the input image based on a comparison result in the projection data comparison step, and a match for determining a degree of coincidence between the input image and the registered image using the rotation angle Recording step, wherein a program for executing the degree determination step is recorded. .
JP24472799A 1999-08-31 1999-08-31 Image search apparatus, image search method, and recording medium Expired - Fee Related JP4395933B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP24472799A JP4395933B2 (en) 1999-08-31 1999-08-31 Image search apparatus, image search method, and recording medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP24472799A JP4395933B2 (en) 1999-08-31 1999-08-31 Image search apparatus, image search method, and recording medium

Publications (2)

Publication Number Publication Date
JP2001067481A true JP2001067481A (en) 2001-03-16
JP4395933B2 JP4395933B2 (en) 2010-01-13

Family

ID=17123008

Family Applications (1)

Application Number Title Priority Date Filing Date
JP24472799A Expired - Fee Related JP4395933B2 (en) 1999-08-31 1999-08-31 Image search apparatus, image search method, and recording medium

Country Status (1)

Country Link
JP (1) JP4395933B2 (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2003004967A1 (en) * 2001-07-01 2003-01-16 Advantest Corporation Position detection apparatus, position detection method, and electr5onic part convey apparatus
JP2010182048A (en) * 2009-02-04 2010-08-19 Sony Corp Vein authentication apparatus and template registration method
JP2014225275A (en) * 2008-08-08 2014-12-04 株式会社ニコン Retrieval support system, retrieval support method, and program
JP2018049568A (en) * 2016-09-23 2018-03-29 株式会社デンソーテン Water droplet detection device, water droplet detection method and water droplet detection program
JP2021532496A (en) * 2018-08-06 2021-11-25 ネイバーウェブトゥーン リミテッド Marker detection method using image matching, its device and its program

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2003004967A1 (en) * 2001-07-01 2003-01-16 Advantest Corporation Position detection apparatus, position detection method, and electr5onic part convey apparatus
JP2003017510A (en) * 2001-07-01 2003-01-17 Advantest Corp Apparatus for detecting position, method for detecting position, and apparatus for conveying electronic component
JP2014225275A (en) * 2008-08-08 2014-12-04 株式会社ニコン Retrieval support system, retrieval support method, and program
JP2010182048A (en) * 2009-02-04 2010-08-19 Sony Corp Vein authentication apparatus and template registration method
US8320997B2 (en) 2009-02-04 2012-11-27 Sony Corporation Vein authentication apparatus and template registration method
JP2018049568A (en) * 2016-09-23 2018-03-29 株式会社デンソーテン Water droplet detection device, water droplet detection method and water droplet detection program
JP2021532496A (en) * 2018-08-06 2021-11-25 ネイバーウェブトゥーン リミテッド Marker detection method using image matching, its device and its program
JP7277562B2 (en) 2018-08-06 2023-05-19 ネイバーウェブトゥーン リミテッド Marker detection method using image matching, its device and its program

Also Published As

Publication number Publication date
JP4395933B2 (en) 2010-01-13

Similar Documents

Publication Publication Date Title
JP4928310B2 (en) License plate recognition device, control method thereof, computer program
JP5188334B2 (en) Image processing apparatus, image processing method, and program
CN104867137B (en) A kind of method for registering images based on improvement RANSAC algorithms
EP1091320A2 (en) Processing multiple digital images
US20080273761A1 (en) Image Recognition Device, Image Recognition Method, and Program for Causing Computer to Execute the Method
RU2641225C2 (en) Method of detecting necessity of standard learning for verification of recognized text
CN110598581B (en) Optical music score recognition method based on convolutional neural network
CN102831578B (en) Image processing method and image processing device
JP2001067481A (en) Device and method for image retrieval, and recording medium
US7155051B2 (en) Image recognition apparatus, image recognition method and image recognition program for specific pattern
CN111445540B (en) Automatic registration method for RGB colored three-dimensional point cloud
JP3571128B2 (en) Method and apparatus for recognizing dimensions of drawings
JP3718967B2 (en) Image feature amount extraction apparatus and method, and recording medium on which image feature amount extraction program is recorded
CN1228733C (en) Finding objects in image
CN113989823B (en) Image table restoration method and system based on OCR coordinates
CN113096099B (en) Color channel combination-based permeable asphalt mixture communication gap identification method
CN102682308B (en) Imaging processing method and device
JP2003022446A (en) Device and method for signature collation, and program making computer implement the same method
JP3074691B2 (en) Character recognition device
JPH09330404A (en) Object detector
JP4027689B2 (en) Image rotation angle detection method, apparatus and recording medium
JP4406974B2 (en) Image detection apparatus, image detection method, and recording medium
JP5636691B2 (en) Image processing apparatus and image processing program
JPH07230549A (en) Image processor and its method
JP4395932B2 (en) Image detection apparatus, image detection method, and recording medium

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20060825

RD01 Notification of change of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7421

Effective date: 20060913

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20090608

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20090616

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20090817

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20090929

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20091012

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20121030

Year of fee payment: 3

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20131030

Year of fee payment: 4

LAPS Cancellation because of no payment of annual fees