JPWO2008075592A1 - Image discrimination method - Google Patents
Image discrimination method Download PDFInfo
- Publication number
- JPWO2008075592A1 JPWO2008075592A1 JP2008550110A JP2008550110A JPWO2008075592A1 JP WO2008075592 A1 JPWO2008075592 A1 JP WO2008075592A1 JP 2008550110 A JP2008550110 A JP 2008550110A JP 2008550110 A JP2008550110 A JP 2008550110A JP WO2008075592 A1 JPWO2008075592 A1 JP WO2008075592A1
- Authority
- JP
- Japan
- Prior art keywords
- image
- sample
- image data
- correlation coefficient
- pixel units
- 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.)
- Withdrawn
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/70—Arrangements for image or video recognition or understanding using pattern recognition or machine learning
- G06V10/74—Image or video pattern matching; Proximity measures in feature spaces
- G06V10/75—Organisation of the matching processes, e.g. simultaneous or sequential comparisons of image or video features; Coarse-fine approaches, e.g. multi-scale approaches; using context analysis; Selection of dictionaries
- G06V10/751—Comparing pixel values or logical combinations thereof, or feature values having positional relevance, e.g. template matching
Landscapes
- Engineering & Computer Science (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Theoretical Computer Science (AREA)
- Medical Informatics (AREA)
- Health & Medical Sciences (AREA)
- Databases & Information Systems (AREA)
- Evolutionary Computation (AREA)
- General Health & Medical Sciences (AREA)
- Artificial Intelligence (AREA)
- Software Systems (AREA)
- Computing Systems (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Multimedia (AREA)
- Image Analysis (AREA)
- Image Processing (AREA)
- Character Discrimination (AREA)
Abstract
【課題】 文字や数字その他の画像が、サンプル画像と同じ範疇のものかを判別する画像判別方法において、例えば一部が欠落した文字や数字を正確に判別できるようにする。【解決手段】 7×7=49の画素単位で数字を表現した場合に、同じ数字を表示した複数のサンプル画像から統計を求め、統計の定数と、判別対象となる画像とから類否を判別する。このとき49個の画素単位の全ての統計で定数を定めるとともに画像を複数の領域に区分して、それぞれの領域での相関係数を求める。このように二段階で定数を決めることにより、例えば文字の一部が欠けているような画像をサンプル画像と同種の画像であると判断できるようになる。【選択図】図4PROBLEM TO BE SOLVED: To accurately determine, for example, a partially missing character or number in an image determining method for determining whether a character, number or other image has the same category as a sample image. When a number is expressed in units of 7 × 7 = 49 pixels, statistics are obtained from a plurality of sample images displaying the same number, and similarity is determined from a statistical constant and an image to be determined. To do. At this time, constants are determined by all the statistics of 49 pixel units, and the image is divided into a plurality of areas, and correlation coefficients in the respective areas are obtained. Thus, by determining the constants in two steps, for example, an image in which a part of a character is missing can be determined as an image of the same type as the sample image. [Selection] Figure 4
Description
本発明は、文字や数字や記号その他の判別すべき対象物を撮像した画像が、サンプル画像と同じ範疇のものであるか否かの判別を可能とした画像判別方法に関する。 The present invention relates to an image discriminating method capable of discriminating whether an image obtained by capturing characters, numbers, symbols, or other objects to be discriminated is of the same category as a sample image.
文字や数字や記号その他の対象物をCCDなどの撮像素子で撮影し、コンピュータのソフトウエア上で、その画像を分析することで、対象物の画像がサンプル画像と同種と判断されるべきものであるかを判別する画像判別方法が実現されつつある。 Images of characters, numbers, symbols, and other objects should be photographed with an image sensor such as a CCD, and the image should be determined to be the same as the sample image by analyzing the image on the computer software. An image discriminating method for discriminating whether or not there is being realized.
以下の特許文献1に記載の画像認識によるパターン検出法は、検出対象物のパターン画像を分割し、分割したパターンごとに基準パターンと対比することで、検出対象物のパターンが基準パターンと同種のものであるかの判別を行っている。この判別方法として正規化相関係数を用いている。
The pattern detection method based on image recognition described in
特許文献2に記載の文字認識方法も、対象物のパターン画像を分割して、分割されたそれぞれの領域の画像と基準画像との空間距離を算出している。この空間距離としてユークリッド距離またはマハラノビス距離を用いている。特許文献2に記載の発明は、パターン画像を分割したそれぞれの領域ごとに所定の係数を乗じて、基準画像との類否判断を行うことにより、例えば文字に潰れやすい部分があったとしても、類否判断ができるようにするというものである。
前記特許文献に記載の発明をはじめとして、従来の画像判別方法は、画像の類否判別を1つ種類の演算に基づいて行っている。しかし、従来知られている正規化相関係数を使用する判別方法や、ユークリッド距離またはマハラノビス距離を使用する判別方法では、必ずしも目的とする画像判別を正確に行えない。 The conventional image discrimination method including the invention described in the above-mentioned patent literature performs image similarity discrimination based on one kind of calculation. However, the conventional discrimination method using the normalized correlation coefficient and the discrimination method using the Euclidean distance or the Mahalanobis distance cannot always accurately perform the target image discrimination.
図3(A)(B)(C)は、それぞれ異なる方法による画像の判別を試みた結果を示している。この試験方法では、図2に示すように、コンピュータ上で7×7個の画素単位を想定して、いずれかの画素単位を黒色に設定して、「0」ないし「9」の数字を表現する。そして、図2に示す「6」の数字表示を基準画像とし、「0」「1」「2」「3」「4」「5」「6」「7」「8」「9」のそれぞれの数字表示を判別対象物とし、それぞれの判別対象物と、基準画像である「6」の数字表示との空間距離を演算する。 FIGS. 3A, 3B, and 3C show results of attempts to discriminate images by different methods. In this test method, as shown in FIG. 2, assuming a 7 × 7 pixel unit on the computer, one of the pixel units is set to black, and the numbers “0” to “9” are expressed. To do. Then, the number display of “6” shown in FIG. 2 is used as a reference image, and each of “0”, “1”, “2”, “3”, “4”, “5”, “6”, “7”, “8”, and “9” is displayed. The numerical display is used as a discrimination target, and the spatial distance between each discrimination target and the numeric display of “6” as the reference image is calculated.
図3(A)は、基準画像と判別対象物との間の正規化相関値を求めたものである。縦軸に1/(正規化相関値)をとり、横軸に判別対象画像である「0」「1」「2」「3」「4」「5」「7」「8」「9」のそれぞれの数字表示を示している。基準画像と判別対象画像が同じ「6」のとき、正規化相関値は1である。 FIG. 3A shows a normalized correlation value between the reference image and the discrimination target. 1 / (normalized correlation value) is taken on the vertical axis, and “0”, “1”, “2”, “3”, “4”, “5”, “7”, “8”, and “9” that are discrimination target images are taken on the horizontal axis. Each numerical display is shown. When the reference image and the discrimination target image are the same “6”, the normalized correlation value is 1.
図3(B)の縦軸は、マハラノビスの距離である。図3(B)でのマハラノビスの距離は、7×7の画素単位のデータの総和と項目数とから算出している。基準画像と判別対象画像が同じ「6」のとき、マハラノビスの距離は0〜1である。 The vertical axis in FIG. 3B represents the Mahalanobis distance. The Mahalanobis distance in FIG. 3B is calculated from the sum of data in 7 × 7 pixel units and the number of items. When the reference image and the discrimination target image are the same “6”, the Mahalanobis distance is 0-1.
図3(C)は、7×7の画素単位のデータから比例定数と標準偏差を算出し、この比例定数と標準偏差の2つの項目を使用してマハラノビスの距離を求めている。この場合、基準画像と判別対象画像が同じ「6」のとき、マハラノビスの距離は1である。 In FIG. 3C, a proportional constant and a standard deviation are calculated from 7 × 7 pixel unit data, and the Mahalanobis distance is obtained using two items of the proportional constant and the standard deviation. In this case, when the reference image and the discrimination target image are the same “6”, the Mahalanobis distance is 1.
図3(A)に示すように、正規化相関値を用いた判別法では、判別の対象物である各数値と、基準画像である「6」の数字との相関値が近く、基準画像と対象物の画像との識別が困難であることを理解できる。これに対し、図3(B)に示すように、画素単位の全ての画像データを用いて算出したマハラノビスの距離は、図3(A)に比べて遠くなり、図3(C)に示すよう、比例定数と標準偏差の2つの項目を用いて算出したマハラノビスの距離は、さらに遠くなる。 As shown in FIG. 3A, in the discrimination method using the normalized correlation value, the correlation value between each numeric value that is a discrimination target and the number “6” that is the reference image is close, and the reference image It can be understood that it is difficult to distinguish the object from the image. On the other hand, as shown in FIG. 3B, the Mahalanobis distance calculated using all image data in pixel units is longer than that in FIG. 3A, and as shown in FIG. The Mahalanobis distance calculated using the two items of the proportionality constant and the standard deviation is further increased.
つまり、判別の対象である画像を、基準画像と比較したときに、図3(A)よりも図3(B)に示す手法の方が混同して判断される確率が低くなり、さらに図3(C)の手法ではさらに混同して判断される確率が低くなる。ただし、一方において、例えば数字の「6」の一部のみが欠落しているもののように人の目で見たときには「6」と判断されるべき画像を前記手法で判別した場合に、図3(B)や図3(C)の手法では、基準画像に対して空間距離が遠いと判断されてしまい、一部のみが欠落している「6」の数字を異なるものであるとして排除する結果となる。 That is, when the image to be discriminated is compared with the reference image, the probability that the method shown in FIG. 3B is confused and determined is lower than that in FIG. In the method (C), the probability of being further confused is determined. However, on the other hand, when an image that should be judged to be “6” when it is viewed with the human eye, for example, only a part of the numeral “6” is missing, In the methods of (B) and FIG. 3 (C), it is determined that the spatial distance is far from the reference image, and the result is that the number “6” in which only a part is missing is excluded as being different. It becomes.
このように、図3(B)(C)に示すように、画像の判別の感度を高くすること、逆に本来は同一または類似と判断すべきものを非同一と判断する不具合がある。 As described above, as shown in FIGS. 3B and 3C, there is a problem that the sensitivity of image discrimination is increased, and conversely, what is originally determined to be the same or similar is determined to be non-identical.
本発明は上記従来の課題を解決するものであり、基準となるサンプル画像と、判別対象物の画像とが相違するものである場合には、空間距離を遠くして、混同する判別が行われ難くし、一方において、欠けが生じているような画像を基準画像と同種のものと判別することができる画像判別方法を提供することを目的としている。 The present invention solves the above-described conventional problems. When the reference sample image is different from the image of the object to be discriminated, confusion discrimination is performed by increasing the spatial distance. On the other hand, an object of the present invention is to provide an image discriminating method capable of discriminating an image having a chipped portion from the same type as a reference image.
第1の本発明は、判別対象である対象画像とサンプル画像との類否を判別する画像判別方法において、
1つのサンプル画像がk個の画素単位の画像データを有し、且つ同種の画像と判断できるサンプル画像をn個用い、それぞれの1つのサンプル画像を、複数個の画素単位ごとに複数の領域に区分し、
n個のサンプル画像の同じ領域に位置する画素単位の画像データから相関係数を計算し、この相関係数を各領域ごとに求め、
全てのサンプル画像のk×n個の各画素単位の画像データの統計として得られる定数およびサンプル画像の各領域ごとの前記相関係数と、前記対象画像のk個の画素単位の画像データと、前記対象画像の各領域の相関係数とから、対象画像とサンプル画像との空間距離を求め、求められた空間距離によって、対象画像とサンプル画像との類比を判別することを特徴とするものである。According to a first aspect of the present invention, there is provided an image determination method for determining similarity between a target image as a determination target and a sample image.
One sample image has image data of k pixel units, and n sample images that can be determined to be the same type of image are used, and each one sample image is divided into a plurality of regions for each of a plurality of pixel units. Segment
A correlation coefficient is calculated from image data in units of pixels located in the same area of n sample images, and the correlation coefficient is obtained for each area.
Constants obtained as statistics of image data of k × n pixel units of all sample images and the correlation coefficient for each region of the sample image, image data of k pixel units of the target image, A spatial distance between the target image and the sample image is obtained from a correlation coefficient of each region of the target image, and an analogy between the target image and the sample image is determined based on the obtained spatial distance. is there.
第1の本発明では、k×n個の画素単位の画像データの統計として得られる定数を次のようにして得ることができる。 In the first aspect of the present invention, constants obtained as statistics of image data of k × n pixel units can be obtained as follows.
n個のサンプル画像のそれぞれ同じ位置にある画素単位のn個の画像データの平均値Mj(j=1,2,3,・・・,k)と、それぞれのサンプル画像ごとに、各画素単位の画像データと前記平均値Mjとの積を加算した線形式Li(i=1,2,3,・・・,n)と、各平均値Mjを加算した有効除数rとを求めて、比例定数であるY1(i)=Li/rを算出するとともに、
n個のサンプル画像のそれぞれ同じ位置にある画素単位の画像データから誤差分散Ve(i)を求めて、この誤差分散Ve(i)と前記有効除数rとから各サンプル画像ごとのSN比η(i)を求め、このSN比η(i)の逆数の平方根を計算して、各サンプル画像ごとの標準偏差であるY2(i)を算出し、
n個の前記Y1(i)の平均値と、n個の前記Y2(i)の平均値の2項目を前記定数とする。An average value M j (j = 1, 2, 3,..., k) of n image data in pixel units at the same position in each of n sample images, and each pixel for each sample image A linear form L i (i = 1, 2, 3,..., N) obtained by adding the product of the unit image data and the average value M j, and an effective divisor r obtained by adding each average value M j. Obtain Y 1 (i) = L i / r which is a proportionality constant,
An error variance Ve (i) is obtained from image data in units of pixels at the same position in each of the n sample images, and the SN ratio η (for each sample image is obtained from the error variance Ve (i) and the effective divisor r. i), and the square root of the reciprocal of this SN ratio η (i) is calculated to calculate Y 2 (i), which is the standard deviation for each sample image,
Two items, an average value of n Y 1 (i) and an average value of n Y 2 (i), are defined as the constants.
また、第1の本発明では、各領域の相関係数は、
サンプル画像の1つの領域内の画素単位の数をpとし、n個のサンプル画像のそれぞれ同じ位置にある画素単位のn個の画像データの平均値Xqバー(q=1,2,3,・・・,p)と、各サンプル画像ごとのp個の画素単位の画像データの平均値Yiバー(i=1,2,3,・・・,n)と、全てのサンプル画像の同じ領域内のn×p個の画素単位の画像データの平均値Xバー、とから求めることができる。In the first aspect of the present invention, the correlation coefficient of each region is
The number of pixel units in one region of the sample image is p, and an average value X q bar (q = 1, 2, 3, 3) of n image data in pixel units at the same position in each of the n sample images. .., P), the average value Y i bar (i = 1, 2, 3,..., N) of the image data of p pixel units for each sample image, and the same for all sample images The average value X bar of image data of n × p pixel units in the region can be obtained.
さらに第1の本発明では、前記空間距離がマハラノビスの距離である。または、前記空間距離がユークリッドの距離である。 In the first aspect of the present invention, the spatial distance is a Mahalanobis distance. Alternatively, the spatial distance is Euclidean distance.
また、第1の発明において、前記定数および各領域の前記相関係数のそれぞれに係数を割り当てて、前記空間距離を算出することも可能である。この場合に、各領域の情報量を比較し、情報量が少ない領域で得られた相関係数に割り当てる係数を、他の領域で得られた相関係数に割り当てる係数よりも小さくすることが好ましい。 In the first invention, the spatial distance can be calculated by assigning a coefficient to each of the constant and the correlation coefficient of each region. In this case, it is preferable that the information amount of each region is compared, and the coefficient assigned to the correlation coefficient obtained in the region where the information amount is small is made smaller than the coefficient assigned to the correlation coefficient obtained in the other region. .
上記のように、サンプル画像内で区分された各領域の情報量に応じて、それぞれの領域から得られた相関係数に対する重み付けを調整することにより、サンプル画像の特徴に応じた、最適な画像判別ができるようになる。 As described above, by adjusting the weighting of the correlation coefficient obtained from each region according to the information amount of each region divided in the sample image, an optimal image corresponding to the characteristics of the sample image Discrimination can be made.
第2の本発明は、判別対象である対象画像とサンプル画像との類否を判別する画像判別方法において、
複数の画素単位ごとの画像データを有し、且つ同種の画像と判断できるサンプル画像をn個用い、それぞれのサンプル画像を、複数個の画素単位ごとに複数の領域に区分し、1つのサンプル画像における画素単位の数および区分した領域の数の合計をkとし、
各画素単位の画像データ、および区分したそれぞれの領域ごとに求めた画像データの相関係数を、共にXij(i=1,2,3,・・・,k)(j=1,2,3,・・・,n)で表し、
それぞれの画素単位の画像データのサンプル画像の数nでの平均値、およびそれぞれの領域の前記相関係数のサンプル画像の数nでの平均値を、共にmi(i=1,2,3,・・・,k)とし、
それぞれの画素単位の画像データのサンプル画像の数nでの標準偏差、およびそれぞれの領域の前記相関係数のサンプル画像の数nでの標準偏差を、共にσi(i=1,2,3,・・・,k)として、
規格化値xij=(Xij−mi)/σiを求め、
前記対象画像の画素単位の画像データおよび前記対象画像の各領域での相関係数と、前記規格化値xijとから、対象画像とサンプル画像との空間距離を求め、求められた空間距離によって、対象画像とサンプル画像との類比を判別することを特徴とするものである。According to a second aspect of the present invention, there is provided an image determination method for determining similarity between a target image that is a determination target and a sample image.
Using n sample images that have image data for each pixel unit and can be determined as the same type of image, each sample image is divided into a plurality of regions for each pixel unit, and one sample image And k is the total number of pixel units and the number of segmented areas in
X ij (i = 1, 2, 3,..., K) (j = 1, 2, k) is used as the correlation coefficient of the image data for each pixel and the image data obtained for each divided area. 3, ..., n)
The average value of the image data of each pixel unit in the number n of sample images and the average value of the correlation coefficient in each region in the number n of sample images are both mi (i = 1, 2, 3). , ..., k),
Σ i (i = 1, 2, 3) is the standard deviation of the image data of each pixel unit in the number n of sample images and the standard deviation of the correlation coefficient in each region in the number n of sample images. , ..., k)
Obtain a normalized value x ij = (X ij −m i ) / σ i ,
The spatial distance between the target image and the sample image is obtained from the image data in pixel units of the target image, the correlation coefficient in each region of the target image, and the normalized value x ij , and is calculated according to the obtained spatial distance. In this case, an analogy between the target image and the sample image is discriminated.
第2の本発明では、各領域の相関係数は、
サンプル画像内の1つの領域の画素単位数をpとし、n個のサンプル画像のそれぞれ同じ位置にある画素単位のn個の画像データの平均値Xqバー(q=1,2,3,・・・,p)と、各サンプル画像ごとのp個の画素単位の画像データの平均値Yiバー(i=1,2,3,・・・,n)と、全てのサンプル画像の同じ領域内のn×p個の画素単位の画像データの平均値Xバー、とから求められる。
さらに、第2の本発明は、前記空間距離がマハラノビスの距離である。In the second invention, the correlation coefficient of each region is
An average value X q bar (q = 1, 2, 3,...) Of n image data in pixel units at the same position in each of n sample images, where p is the number of pixel units in one region in the sample image. .., P), the average value Y i bar (i = 1, 2, 3,..., N) of image data of p pixel units for each sample image, and the same area of all sample images And the average value X bar of the image data of n × p pixel units.
Furthermore, in the second aspect of the present invention, the spatial distance is a Mahalanobis distance.
本発明では、判別対象である対象画像とサンプル画像との空間距離を2種類の演算で求めている。まず、サンプル画像の全体と判別対象物である画像の全体とからマハラノビスの距離などを算出することで、サンプル画像と同種と判断すべきでない画像とサンプル画像との空間距離が遠く算出されるようにし、さらに、サンプル画像と判別対象となる画像を複数の領域に区分し、領域間の空間距離を相関係数などを用いて短い距離で算出できるようにしている。そして、2つの演算結果に所定の重み付けを与えることにより、文字の一部が欠落しているような判断対象物の画像とサンプル画像との空間距離を短くできるようにしている。 In the present invention, the spatial distance between the target image to be discriminated and the sample image is obtained by two types of calculations. First, by calculating the Mahalanobis distance, etc., from the entire sample image and the entire image that is the discrimination target, the spatial distance between the image that should not be determined to be the same type as the sample image and the sample image can be calculated far away. Furthermore, the sample image and the image to be discriminated are divided into a plurality of regions, and the spatial distance between the regions can be calculated with a short distance using a correlation coefficient or the like. Then, by giving predetermined weights to the two calculation results, the spatial distance between the image of the determination object in which a part of the character is missing and the sample image can be shortened.
よって、一部が欠落した文字や、撮像素子によりややぼやけて撮影されたような画像であっても、サンプル画像との類否を高精度に判別できるようになる。 Therefore, it is possible to determine with high accuracy the similarity to the sample image even if a part of the character is missing or an image that is captured slightly blurred by the image sensor.
図1は本発明の実施の形態の画像判別装置を示すブロック図である。
画像判別装置は、カメラ1を有している。カメラ1はCCDやCMOSなどの撮像素子を備えている。カメラ1で撮影された判別対象物10の映像はA/D変換部2でディジタル信号の画像データに変換される。ディジタル信号の画像データは、演算部3で演算され、判別部4に送られる。演算部3および判別部4に接続されているメモリ5には、判断の基準となるべきサンプル画像から算出された各種定数が保持されている。演算部3では、メモリ5に保持されている各定数と、A/D変換部2から得られた画像データとから、サンプル画像と判別対象物の画像との空間距離が求められ、判別部4において求められた空間距離がしきい値よりも小さいか否かが判別される。FIG. 1 is a block diagram showing an image discriminating apparatus according to an embodiment of the present invention.
The image discrimination device has a
図2は、基準画像であるサンプル画像の一例を示している。図2に示すサンプル画像は7×7個の画素単位で構成されており、各画素単位の明暗(濃淡)により「0」から「9」の数字が示されている。ここで、7×7=49のそれぞれの画素単位は、CCDなどの1つセンサーの単位であってもよいし、または複数個のセンサーで撮影された画像をまとめて1つの画素単位として取り扱ってもよい。 FIG. 2 shows an example of a sample image that is a reference image. The sample image shown in FIG. 2 is configured in units of 7 × 7 pixels, and numbers “0” to “9” are indicated by the brightness (darkness) of each pixel unit. Here, each pixel unit of 7 × 7 = 49 may be a unit of one sensor such as a CCD, or images taken by a plurality of sensors are collectively handled as one pixel unit. Also good.
この実施の形態では、図2に示すサンプル画像が数字であり、判別対象となる画像とそれぞれのサンプル画像との空間距離を算出することで、判別対象となる画像が、「0」ないし「9」のどの数字に属するかを判断することができる。よって、図2に示すサンプル画像の各画素単位の画像データを、白か黒かの2進データとして取り扱ってもよいし、あるいは1つの画素単位の明暗の画像データを256階調などの諧調を有するデータとして取り扱い、この諧調も含めて、判別対象となる画像とサンプル画像との空間距離を求めてもよい。 In this embodiment, the sample image shown in FIG. 2 is a number, and by calculating the spatial distance between the image to be determined and each sample image, the image to be determined is “0” to “9”. It is possible to determine which number of "." Therefore, the image data of each pixel unit of the sample image shown in FIG. 2 may be handled as binary data of white or black, or the light and dark image data of one pixel unit has a gradation such as 256 gradations. The spatial distance between the image to be discriminated and the sample image may be obtained including this gradation.
図2に示す同じ数字のサンプル画像を複数個用意し、それぞれのサンプル画像から統計に基づく定数を算出し、この定数をメモリ5に記憶させる。例えば、数字を印刷してこの数字をカメラ1で読取ってA/D変換し、その画像がどの数字に属するかを判断するような場合を想定すると、その数字を印刷する際の外形のばらつきや色彩のばらつき、または撮影するたびに発生するカメラ1での撮影画像にばらつきが想定される。このようにばらつきのある画像データを複数のサンプル画像として使用し、同じ数字を表現する画像におけるデータのばらつきの特性を統計により計算し、統計に基づく定数を算出する。そして、この定数をメモリ5に保持させる。
A plurality of sample images with the same number shown in FIG. 2 are prepared, a constant based on statistics is calculated from each sample image, and the constant is stored in the
この統計に使用するサンプル画像は、実際に印刷された複数の数字をカメラ1で撮影し、A/D変換することで得られる。あるいは、この定数の算出に際し、実際にカメラ1で数字を撮影して求めるのではなく、例えばコンピュータにおいて、図2に示す7×7の画素単位で形成される数字を想定し、白の画素単位を「0」とし、黒の画素単位を「1」とするとともに、前記「0」と「1」に対して乱数を当てはめて、各画素単位の画像データにばらつきを生じさせ、このばらつきを有する画像データを複数のサンプル画像として使用し、統計に基づく定数を算出することもできる。
A sample image used for this statistic is obtained by photographing a plurality of actually printed numbers with the
以下の表1は、複数のサンプル画像の画像データを意味している。表1に示すサンプル画像のデータは、例えば図2に示す数字「6」を複数回撮影したときの複数のサンプル画像の画像データのばらつき、またはコンピュータで人為的に作成した数字「6」を示す画像データのばらつきを意味している。 Table 1 below indicates image data of a plurality of sample images. The sample image data shown in Table 1 shows, for example, variation in image data of a plurality of sample images when the number “6” shown in FIG. 2 is shot a plurality of times, or a number “6” artificially created by a computer. This means variation in image data.
表1の最上欄の最左端の「N」は、サンプル画像の番号を意味しており、サンプル画像の数は「n」個である。最上欄において横に一列に並ぶX1ないしXkは1つのサンプル画像が有する画素単位を意味している。画素単位の数が図2に示すように7×7の場合、表1の「k」は「49」である。“N” at the leftmost end of the uppermost column in Table 1 means the number of sample images, and the number of sample images is “n”. X 1 to X k arranged in a row horizontally in the uppermost column mean pixel units included in one sample image. When the number of pixel units is 7 × 7 as shown in FIG. 2, “k” in Table 1 is “49”.
表1では、サンプル番号が1ないしnの各サンプル画像における個々の画素単位の画像データを「Xij」で示している。「i」は1つのサンプル画像の中でのk個の画素単位の番号を表しており、「i=1,2,3,・・・,k」である。「j」はn個のサンプル画像の番号を表しており、「j=1,2,3,・・・,n」である。例えばX12は、サンプル番号「2」のサンプル画像内の1番目の画素単位での画像データであることを意味している。画像データXijは、実際にカメラで撮影した画像である場合に、例えば256階調のデータであり、サンプル画像をコンピュータ上で作成した場合には、ランダムにばらつきを有するデータである。In Table 1, the image data of each pixel unit in each sample image having
表1に示すそれぞれのサンプル画像の各画素単位の画像データXijを用いて、画像データの統計を計算する。この計算は、図1に示す演算部3や判別部4で行われ、最終的に算出された定数がメモリ5に記憶される。あるいは前記サンプル画像の画像データを用いて、図1に示す画像判別装置とは別のコンピュータで統計に基づく定数を算出し、その定数をメモリ5に記憶させてもよい。Using the image data Xij of each pixel unit of each sample image shown in Table 1, statistics of the image data are calculated. This calculation is performed by the
以下の数1では、平均値M1,M2,・・・,Mkを算出している。この平均値M1,M2,・・・,Mkは、n個の全てのサンプル画像における同じ位置にある画素単位の画像データの平均値である。すなわち、画像データXijのうちの「i」が同じ数値であるn個の画像データの平均値である。よって、算出される平均値の数は、1つのサンプル画像における画素単位の数と同じk個である。In the following
以下の数2では、それぞれのサンプル画像においてその1つの画像サンプルに含まれる画像データの変動ST(1),ST(2),・・・,ST(n)を計算している。この変動は、それぞれのサンプル画像に含まれるk個の画素データのそれぞれを二乗して、1つのサンプル画像内の全ての二乗値を加算したものであり、サンプル画像ごとに特有の値を持つ。よって、算出される変動は、サンプル画像の数と同じn個である。In the
以下の数3では、線形式L1,L2,・・・Lnを算出している。線形式は、1つのサンプル画像内の各画素単位の画像データXijと、その画素単位に基づいて数1で算出された平均値Miとの積を求め、この積を加算したものである。線形式は、それぞれのサンプル画像において特有の値を持ち、線形式の数は、サンプル画像の数と同じn個である。In the following
数4は有効除数rを算出するものであり、数1で得られた平均値M1,M2,・・・,Mkのそれぞれを二乗して加算した値である。
数5は、数3で得られた線形式Ljと数4で得られた前記有効除数rとから、それぞれのサンプル画像の比例項の変動Sβ(1),Sβ(2),・・・,Sβ(n)を求めている。数6は、線形式Ljと有効除数rとから、比例定数β(1),β(2),・・・β(n)を求めている。
数7は、それぞれのサンプル画像における画像データの誤差分散Ve(1),Ve(2),・・・,Ve(n)を求めている。この誤差分散Ve(j)は、数2で求めたそれぞれのサンプル画像内の全ての画像データST(j)から得られた全変動と、数5で得られた、そのサンプル画像の比例項の変動Sβ(j)とから求められる。
以下の数8に示すように、前記誤差分散Ve(j)の逆数と有効除数rとで求められるのがSN比η(1),η(2),・・・,η(n)である。
As shown in
この実施の形態では、k個の画素単位を有するn個のサンプル画像から得られた画像データ、すなわち表1に示すX11,X21,・・・,Xknの画像データの統計として以下の数9と数10に示す2つの項目Y1(j)とY2(j)が算出される。In this embodiment, the image data obtained from n sample images having k pixel units, that is, the statistics of the image data of X 11 , X 21 ,. Two items Y 1 (j) and Y 2 (j) shown in
数9で求められた第1の項目Y1(1),Y1(2),・・・,Y1(n)は、数6で示した比例定数であり、これはそれぞれのサンプル画像で得られた画像データの感度を表している。数10で求められた第2の項目Y2(1),Y2(2),・・・,Y2(n)は、各サンプル画像の画像データの標準偏差である。The first items Y 1 (1), Y 1 (2),..., Y 1 (n) obtained in
以下の表2は、これまでに算出した各定数を示している。
n個のサンプル画像から得られるn×k個の画像データから計算された第1の項目Y1(1),Y1(2),・・・,Y1(n)の平均値I1、および第2の項目Y2(1),Y2(2),・・・,Y2(n)の平均値I2は、表1に示すばらつきを有する画像データ群のゼロ点を意味している(I1、I2は表4参照)。この実施の形態は、判別対象となる画像と前記ゼロ点との空間距離を求めることを基本としている。The average value I 1 of the first items Y 1 (1), Y 1 (2),..., Y 1 (n) calculated from n × k image data obtained from n sample images, The average value I 2 of the second items Y 2 (1), Y 2 (2),..., Y 2 (n) means the zero point of the image data group having variations shown in Table 1. (See Table 4 for I 1 and I 2 ). This embodiment is based on obtaining a spatial distance between an image to be determined and the zero point.
図3(C)は、前記第1の項目Y1(j)の平均値I1および第2の項目Y2(j)の平均I2を定数として使用し、判別対象となる画像とサンプル画像との空間距離であるマハラノビスの距離を求めた結果を示している。平均値I1と平均値I2を使用して空間距離を計算すると、両画像が少し違うだけで空間距離が遠くなる。したがって、図3(C)に示すように、「6」のサンプル画像と「6」以外の数字の画像との空間距離が遠くなり、「6」以外の数字が「6」と同じであると判断される確率をかなり低くできる。ただし、一方において、サンプル画像と判別対象となる画像の文字の形状が少し変わるだけで空間距離が長くなるため、例えば、数字の一部が欠けたような判別対象の画像を、その数字の範疇であると判断できないことが有りえる。FIG. 3 (C), using the average I 2 of the
そこで、この実施の形態の画像判別方法では、前記第1の項目Y1(j)の平均値I1および第2の項目Y2(j)の平均値I2のみに基づいて空間距離を求めるのではなく、さらにサンプル画像と判別対象となる画像を、共に複数の領域に区分し、領域ごとの空間距離を正規化相関係数を用いて求めることにより、例えば、同じ数字や文字でその一部が欠如しただけの画像を、サンプル画像と同一の画像であると判断できるようにしている。Therefore, in the image determination method of this embodiment, obtains the spatial distance on the basis of only the average value I 2 of the first item Y 1 mean I 1 and the second item Y 2 of (j) (j) Instead, the sample image and the image to be discriminated are both divided into a plurality of regions, and the spatial distance for each region is obtained using a normalized correlation coefficient. It is possible to determine that an image with only a missing part is the same image as the sample image.
画像の領域の分割数は任意であるが、この実施の形態では、画像を4つの領域に区分している。図2に示す例では、1つの画像の画素単位の数が7×7=49であるが、1つの画像を4つの領域に分割するときのそれぞれの領域に含まれる画素単位の数を、左上の領域が4×4=16の画素単位、左下の領域が4×4=16の画素単位、右上の領域と右下の領域がそれぞれ4×4=16の画素単位としている。すなわち、4つに分割した領域には領域どうしで互いに重複する画素が存在している。ただし、分割した領域が重ならないようにし、分割された領域の双方に共通の画素が存在しないように区分してもよい。 The number of divisions of the image area is arbitrary, but in this embodiment, the image is divided into four areas. In the example shown in FIG. 2, the number of pixel units of one image is 7 × 7 = 49, but the number of pixel units included in each region when one image is divided into four regions Area is 4 × 4 = 16 pixel units, the lower left area is 4 × 4 = 16 pixel units, and the upper right area and lower right area are 4 × 4 = 16 pixel units. That is, in the area divided into four, there are pixels that overlap each other. However, the divided areas may not be overlapped and may be divided so that no common pixel exists in both of the divided areas.
表1に示したn個のサンプル画像のそれぞれに前記領域を設定し、領域ごとの相関係数を求める。 The region is set for each of the n sample images shown in Table 1, and a correlation coefficient for each region is obtained.
以下の表3の左端の列Nは、サンプル画像の番号1ないしnを示している。それぞれのサンプル画像は7×7=49の画素単位を有しているが、前述のように、それぞれのサンプル画像を4つの領域に区分している。そして表3には、それぞれのサンプル画像1ないしnにおける左上の領域に位置する4×4=16の画素単位の画像データが示されている。1つのサンプル画像の左上の領域に含まれる画像データは16個であり、サンプル画像の数がn個であるため、表3に現れている画像データの数は、16×n個である。
The leftmost column N in Table 3 below shows the
以下の数11は、表3に記載されている画像データXij(i=1,2,3,・・・,16)(j=1,2,3,・・・,n)の全ての平均値をXバーで示している(本明細書では、記号の上端にラインが引かれている記号を「バー」と呼ぶ)。またそれぞれのサンプル画像ごとの16個の画像データの平均値をYjバーで示している(j=1,2,3,・・・,n)。さらに、各サンプル画像の同じ位置にある画素単位のn個の画像データの平均値をXiバーで示している(i=1,2,3,・・・,16)。Equation 11 below represents all of the image data X ij (i = 1, 2, 3,..., 16) (j = 1, 2, 3,..., N) described in Table 3. The average value is indicated by an X bar (in this specification, a symbol having a line drawn at the upper end of the symbol is referred to as a “bar”). The average value of 16 pieces of image data for each sample image is indicated by Y j bar (j = 1, 2, 3,..., N). Furthermore, the mean value of X i is indicated by a bar of n image data in pixel units at the same position of each sample image (i = 1,2,3, ···, 16 ).
数12ないし数15は、表3に示すサンプル番号1(N=1)のサンプル画像の左上に区分された領域内に含まれる16個の画像データの相関係数r1(1)を求めている。表3に示すサンプル番号2(N=2)のサンプル画像のひだ有り上に区分された領域に含まれる16個の画像データの相関係数r1(2)は、数12ないし数15において、Xi,1の代わりにXi,2を使用し、Y1バーの代わりにY2バーを使用して計算すればよい。サンプル番号3(N=3)以下のサンプル画像の左上の区分された領域に含まれる16個の画像データの相関係数r1(3),r1(4),・・・r1(n)の計算も同じである。Equations (12) to (15) are used to obtain the correlation coefficient r 1 (1) of 16 pieces of image data included in the upper left area of the sample image of sample number 1 (N = 1) shown in Table 3. Yes. The correlation coefficient r 1 (2) of the 16 pieces of image data included in the region with the folds of the sample image of sample number 2 (N = 2) shown in Table 3 is expressed by Equations 12 to 15. using the X i, 2 instead of X i, 1, may be calculated using the Y 2 bar instead of Y 1 bar. Correlation coefficients r 1 (3), r 1 (4),... R 1 (n) of 16 pieces of image data included in the upper left segmented area of the sample image of sample number 3 (N = 3) or less ) Is the same.
同様にして、各サンプル画像の左下の領域での画像データの相関係数r2(j)、各サンプル画像の右上の領域での画像データの相関係数r3(j)、および各サンプル画像での右下の領域での画像データの相関係数r4(j)を求めることができる(j=1,2,3,・・・,n)。Similarly, the correlation coefficient r 2 (j) of the image data in the lower left area of each sample image, the correlation coefficient r 3 (j) of the image data in the upper right area of each sample image, and each sample image The correlation coefficient r 4 (j) of the image data in the lower right region at (j = 1, 2, 3,..., N) can be obtained.
以下の表4には、n個のサンプル画像のそれぞれについて、第1の項目Y1(j)、Y2(j)、および左上、左下、右上および右下の各領域の相関係数r1(j),r2(j),r3(j),r4(j)を示している(j=1,2,3,・・・,n)。図1に示すメモリ5には、表4に示す各定数が、判別対象となる画像の判別のためのテンプレートのデータとして記憶されている。Table 4 below shows, for each of the n sample images, the first item Y 1 (j), Y 2 (j), and the correlation coefficient r 1 for each of the upper left, lower left, upper right and lower right regions. (J), r 2 (j), r 3 (j), r 4 (j) are shown (j = 1, 2, 3,..., N). In the
次に、判別対象である画像と前記サンプル画像との空間距離を求めるための計算を説明する。 Next, calculation for obtaining the spatial distance between the image to be discriminated and the sample image will be described.
図1に示すカメラ1で判別対象物10を撮影した映像をA/D変換部でディジタル信号に変換することで画像データを得ることができる。この画像データが演算部3に与えられ、演算部3で次の演算が行われる。
Image data can be obtained by converting an image obtained by photographing the
判別対象である画像は7×7=49個の画素単位の画像データを有している。判別対象となる画像の各画素単位の画像データを、X1,X2,X3,・・・Xkで表す。The image to be discriminated has image data of 7 × 7 = 49 pixel units. Image data of each pixel unit of the image to be discriminated is represented by X 1 , X 2 , X 3 ,... X k .
表1と数1で求められたサンプル画像の画像データの平均値M1,M2,M3,・・・,Mkと、判別対象の画像の各画像データX1,X2,X3,・・・Xkとから、数3と同様の計算を行って、判別対象の画像において特有の値である線形式L0=M1X1+M2X2+・・・+MkXkを求める。この線形式L0と、数4に示すようにサンプル画像から得られた有効除数rとを用い、数6と同様にβ0=L0/rの計算をする。このβ0が判別対象となる画像における第1の項目y1である。The average values M 1 , M 2 , M 3 ,..., M k of the image data of the sample image obtained in Table 1 and
次に、判別対象である画像の線形式L0と数4で得られた前記有効除数rとから、数5と同様にして、判別対象となる画像の比例項Sβ(0)=L0 2/rを算出する。また、判別対象である画像の画像データX1,X2,X3,・・・Xkを用い、数2と同様にして判別対象である画像において特有の全変動ST=X1 2+X2 2+X3 2+・・・+Xk 2を求める。この全変動STと、比例項Sβ(0)と、画素単位の数kを用いて、数7と同様の計算を行って、判別対象となる画像の画像データの誤差分散Ve(0)を求める。さらにこの誤差分散Ve(0)と、数4で得られた有効除数rとから、数8と同様にして、判別対象となる画像の画像データのSN比η(0)が求められ、数10と同様にして、SN比η(0)の逆数の平方根を取ることにより、判別対象となる画像の画像データの感度、すなわち第2の項目y2が求められる。Then, from the linear equation L 0 of the image is determined subject to the effective divisor r obtained by the
さらに、判別対象となる画像をサンプル画像と同様に4つの領域に区分し、判別対象となる画像の左上の領域の16個の画素データの相関係数r1(0)、左下の領域の16個の画素データの相関係数r2(0)、右上の領域の16個の画素データの相関係数r3(0)および右下の領域の16個の画像データの相関係数r4(0)を求める。Further, the image to be discriminated is divided into four areas in the same manner as the sample image, the correlation coefficient r 1 (0) of the 16 pixel data in the upper left area of the image to be discriminated, and 16 in the lower left area. Correlation coefficient r 2 (0) of 16 pieces of pixel data, correlation coefficient r 3 (0) of 16 pieces of pixel data in the upper right area, and correlation coefficient r 4 (16 pieces of image data in the lower right area) 0).
判別対象となる画像の左上の領域の相関係数r1(0)を求める方法は、表3に示すn個のサンプル画像のいずれかひとつに関して相関係数を求めた方法と同じである。まず数11に記載されているY1バーと同様にして、判断対象となる画像の左上の領域の16個の画像データの平均値Y0を求める。
Y0=(1/16)(X1+X2+X3+・・・+X16)The method for obtaining the correlation coefficient r 1 (0) of the upper left region of the image to be determined is the same as the method for obtaining the correlation coefficient for any one of the n sample images shown in Table 3. In the same manner as Y 1 bar that is described in equation 11 First, the average value Y 0 of 16 image data of the upper left area of the image to be determined target.
Y 0 = (1/16) (X 1 + X 2 + X 3 +... + X 16 )
そして、数15においてXi,1の代わりに画像データXiを使用し(i=1,2,3,・・・,k)、数15においてY1バーの代わりに前記Y0の値を使用することにより、判断対象となる画像の左上の領域の相関係数r1(0)を求めることができる。同様にして、左下の領域の相関係数r2(0)、右上の領域の相関係数r3(0)および右下の領域の相関係数r4(0)を求めることができる。Then, the image data X i is used instead of X i, 1 in Equation 15 (i = 1, 2, 3,..., K), and the value of Y 0 is used instead of Y 1 bar in
このように、判別対象となる画像から得られた第1の項目y1、第2の項目y2、および各相関係数r1(0)、r2(0)、r3(0)、r4(0)と、表4の最下段に記載されている6個の各項目の平均値I1、I2、I3、I4、I5、I6とから次の計算を行う。As described above, the first item y1, the second item y2, and the correlation coefficients r 1 (0), r 2 (0), r 3 (0), r 4 obtained from the image to be determined. The following calculation is performed from (0) and the average values I 1 , I 2 , I 3 , I 4 , I 5 , and I 6 of the six items listed in the bottom row of Table 4.
Y1=y1−I1
Y2=y2−I2
Y3=r1(0)−I3
Y4=r2(0)−I4
Y5=r3(0)−I5
Y6=r4(0)−I6 Y 1 = y 1 −I 1
Y 2 = y 2 −I 2
Y 3 = r 1 (0) −I 3
Y 4 = r 2 (0) −I 4
Y 5 = r 3 (0) −I 5
Y 6 = r 4 (0) −I 6
表4に示す1ないし6の各項目の平均値であるI1、I2、I3、I4、I5、I6から数16に示す相関係数行列を求める。この相関係数行列のrxyはIxとIyとの相関係数である。行列中のr11、r22、r33、r44、r55、r66は、I1とI1との相関係数、I2とI2との相関係数などを意味しており、いずれも相関係数は「1」である。数17は、数16に示す相関係数行列の逆行列である。The correlation coefficient matrix shown in
数18に示すように、数17の逆行列と、判別対象の画像から求めた前記Y1ないしY6の6個の項目とからマハラノビスの距離を求める。As shown in Equation 18, the Mahalanobis distance is obtained from the inverse matrix of Equation 17 and the six items Y 1 to Y 6 obtained from the discrimination target image.
図1に示す判別部4では、数18に示すマハラノビスの距離のしきい値を設定し、マハラノビスの距離がしきい値以下であったら、判別対象の画像が、サンプル画像と同じ範疇のものと判断する。例えばサンプル画像が、図2に示される数字の「6」である場合、マハラノビスの距離がしきい値以下であったら、判別対象となる画像が数字の「6」を示していると判断する。
The
上記マハラノビスの距離は、表1に示すように、複数のサンプル画像の全ての画像データの統計と、判別対象である画像データとの全体とを対比し、さらに複数のサンプル画像と判別対象である画像を複数の領域に区分し、各領域ごとの相関係数を判断に加味している。そのため、文字の少しの違い、判別対象となる画像がサンプル画像と同じ数字や文字であり、且つその数字や文字の一部が欠如した場合であったり、画像がぼやけているような場合であっても、サンプル画像のゼロ点と判別対象となる画像の空間距離とが大きく離れないように調整できる。よって、一部が欠けた文字などをサンプル画像と同種のものと判断することが可能である。また、例えば、サンプル画像で数字の「6」であり、判別対象となる画像が「6」以外の数字の画像である場合には、サンプル画像の統計のゼロ点と、判別すべき画像との空間距離を離すことができ、異なる数字が同種の画像であると判断される確率がきわめて低くなる。 As shown in Table 1, the Mahalanobis distance compares the statistics of all the image data of a plurality of sample images with the entire image data to be discriminated, and further determines the plurality of sample images and the discrimination target. The image is divided into a plurality of regions, and the correlation coefficient for each region is taken into consideration. For this reason, there is a slight difference in characters, when the image to be identified is the same number or character as the sample image, and some of the number or character is missing or the image is blurred. However, it is possible to adjust so that the zero point of the sample image and the spatial distance of the image to be discriminated are not greatly separated. Therefore, it is possible to determine that a part of the character or the like is the same type as the sample image. Further, for example, when the sample image has the number “6” and the image to be determined is an image having a number other than “6”, the zero point of the statistical value of the sample image and the image to be determined The spatial distance can be separated, and the probability that different numbers are judged to be the same type of image is extremely low.
図4と図5は、本発明の実施の形態の手法でマハラノビスの距離を演算したときと、図3(C)と同様の比較例の手法でマハラノビスの距離を演算したときとでの、シミュレーションおよびその結果を説明するものである。 4 and 5 are simulations when the Mahalanobis distance is calculated by the method of the embodiment of the present invention and when the Mahalanobis distance is calculated by the method of the comparative example similar to FIG. And the results.
このシミュレーションでは、図4に示すように、コンピュータ上で7×7の画素単位を設定し、各画素単位において黒色であるときの画像データを「1」とし、白色であるときの画像データを「0」として数字を表現する画像を生成した。サンプル画像は、図4(A)に示すように、7×7の画素単位における「1」「0」のデータで数字の「6」を表現したものを使用した。 In this simulation, as shown in FIG. 4, a 7 × 7 pixel unit is set on the computer, the image data when each pixel unit is black is “1”, and the image data when white is “1”. An image expressing a number as “0” was generated. As the sample image, as shown in FIG. 4A, an image in which the number “6” is expressed by “1” “0” data in a 7 × 7 pixel unit is used.
そして、サンプル画像の統計を求めるために、図4(A)に示す7×7の各画素の「1」または「0」のデータに、0〜0.05の範囲の乱数を加算して、ばらつきを有するn個のサンプル画像を擬似的に生成し、このn個サンプル画像を用いて、数1ないし数10により統計に基づく定数Y1(j)とY2(j)を演算した。さらに、それぞれのサンプル画像を、4×4=16個の画素を有する4つの領域に区分し、それぞれの領域に関して、数11ないし数15の演算を行って、4つに区分したそれぞれの領域での相関係数r1(j),r2(j),r3(j),r4(j)を求めた。Then, in order to obtain the statistics of the sample image, a random number in the range of 0 to 0.05 is added to the data “1” or “0” of each pixel of 7 × 7 shown in FIG. N sample images having variations are generated in a pseudo manner, and using these n sample images, constants Y 1 (j) and Y 2 (j) based on statistics are calculated using Equations 1 to 10. Further, each sample image is divided into four regions each having 4 × 4 = 16 pixels, and the operations of Equations 11 to 15 are performed for each region, and the four regions are divided into four regions. Correlation coefficients r 1 (j), r 2 (j), r 3 (j), and r 4 (j) were obtained.
そして、擬似的にばらつきを持たせた数字「6」のサンプル画像に基づいて、表4に示す、6項目の平均値I1、I2、I3、I4、I5、I6を求めた。Then, based on the sample image of the number “6” with pseudo variation, average values I 1 , I 2 , I 3 , I 4 , I 5 , I 6 shown in Table 4 are obtained. It was.
次に、判別対象となる対象画像として、同じくコンピュータ上で7×7の画素単位を設定し、それぞれの画素データを「1」(黒)または「0」(白)として数字を表現したものを用いた。 Next, as a target image to be discriminated, a 7 × 7 pixel unit is set on the same computer, and each pixel data is expressed as a number with “1” (black) or “0” (white). Using.
ここでは、まずマハラノビスの距離の指針となる第1の対象画像として、図2に示す数字「8」を表現したものを1つ用いた。 Here, one image representing the number “8” shown in FIG. 2 is used as a first target image serving as a guideline for Mahalanobis distance.
さらに、文字の識別性の指針となる第2の対象画像として、図4(A)に示すように数字「6」を表現した1つの画像を使用し、さらに図4(B)に示すように、「6」の数字の1つの画素単位の「黒」を「白」にして「欠け」を作った1つの画像と、図4(C)に示すように、「6」の数字の2つの画素単位の「黒」を「白」にして「欠け」を作った1つの画像と、さらに図4(D)に示すように、「6」の数字の3つ画素単位の「黒」を「白」にして「欠け」を作った1つの画像をそれぞれ使用した。 Further, as the second target image serving as a guideline for character discrimination, one image expressing the number “6” as shown in FIG. 4A is used, and as shown in FIG. 4B. , One image unit of “6” with “black” set to “white” to create “missing”, and two numbers of “6” as shown in FIG. One image in which “black” in the pixel unit is set to “white” to create “missing”, and “black” in three pixel units of the number “6” as shown in FIG. Each image used was “white” and “chip” was used.
数字「8」を表している第1の対象画像と、図4(A)(B)(C)(D)に示す第2の対象画像のそれぞれに関して、前記のように定数y1,y2を計算した。さらに、それぞれの対象画像を4×4=16個の画素ごとに4つの領域に区分し、それぞれの領域に対して、相関係数r1(0)、r2(0)、r3(0)、r4(0)を求めた。そして、ばらつきを有する数字「6」のサンプル画像から得られた表4に示す6項目の平均値I1、I2、I3、I4、I5、I6と、それぞれの対象画像から求められた前記定数y1、y2および相関係数r1(0)、r2(0)、r3(0)、r4(0)とから、Y1、Y2、Y3、Y4、Y5、Y6を求めた。
そして、次の(a)(b)の2つの手法でマハラノビスの距離を求めた。For each of the first target image representing the number “8” and the second target images shown in FIGS. 4A, 4B, 4C, and 4D, the constants y1 and y2 are calculated as described above. did. Further, each target image is divided into four regions every 4 × 4 = 16 pixels, and correlation coefficients r 1 (0), r 2 (0), r 3 (0) are assigned to each region. ), R 4 (0). Then, the average values I 1 , I 2 , I 3 , I 4 , I 5 , and I 6 shown in Table 4 obtained from the sample image of the number “6” having variations are obtained from the respective target images. Y 1 , Y 2 , Y 3 , Y 4 , Y from the constants y1, y2 and correlation coefficients r 1 (0), r 2 (0), r 3 (0), r 4 (0) 5 and Y 6 were obtained.
Then, the Mahalanobis distance was obtained by the following two methods (a) and (b).
(a)比較例(Y1、Y2のみを使用した演算)
比較例として、マハラノビスの距離をY1、Y2のみを用いて演算した。すなわち、数9と数10によりサンプル画像から得られた第1の項目Y1(j)と第2の項目Y2(j)、およびそれぞれの対象画像の定数y1,y2から得られたY1、Y2を使用し、画像を4つに区分して計算した相関係数を使用することなく、数16ないし数18に順じて、マハラノビスの距離を算出した。(A) Comparative example (calculation using only Y 1 and Y 2 )
As a comparative example, the Mahalanobis distance was calculated using only Y 1 and Y 2 . That is, the
この演算では、以下の(ア)(イ)(ウ)(エ)(オ)の空間距離を求めた。
(ア)数字「6」のサンプル画像と、数字「8」の第1の対象画像との空間距離、
(イ)数字「6」のサンプル画像と、図4(A)に示す数字「6」の対象画像との空間距離、
(ウ)数字「6」のサンプル画像と、図4(B)に示すように数字「6」から1画素だけ欠けた対象画像との空間距離、
(エ)数字「6」のサンプル画像と、図4(C)に示すように数字「6」から2画素だけ欠けた対象画像との空間距離、
(オ)数字「6」のサンプル画像と、図4(D)に示すように数字「6」から3画素だけ欠けた対象画像との空間距離、
図5の線図(a)は、上記の演算で得られた空間距離の傾向を示しており、横軸の「0」は、前記空間距離の比(イ/ア)、「1」は空間距離の比(ウ/ア)、「2」は空間距離の比(エ/ア)、「3」は空間距離の比(オ/ア)である。図5の縦軸は(%)であり、下から「0%」「5%」「10%」「15%」・・・「40%」である。In this calculation, the following spatial distances (a) (b) (c) (d) (e) were obtained.
(A) Spatial distance between the sample image with the number “6” and the first target image with the number “8”;
(A) Spatial distance between the sample image of the number “6” and the target image of the number “6” shown in FIG.
(C) Spatial distance between the sample image of the number “6” and the target image lacking only one pixel from the number “6” as shown in FIG.
(D) The spatial distance between the sample image of the number “6” and the target image lacking only two pixels from the number “6” as shown in FIG.
(E) the spatial distance between the sample image of the number “6” and the target image lacking only 3 pixels from the number “6” as shown in FIG.
The diagram (a) of FIG. 5 shows the tendency of the spatial distance obtained by the above calculation, where “0” on the horizontal axis is the ratio (i / a) of the spatial distance, and “1” is the space. The distance ratio (U / A), “2” is the spatial distance ratio (E / A), and “3” is the spatial distance ratio (O / A). The vertical axis in FIG. 5 is (%), and “0%”, “5%”, “10%”, “15%”... “40%” from the bottom.
(b)本発明の実施の形態(Y1、Y2、Y3、Y4、Y5、Y6を使用した演算)
次に、Y1、Y2、Y3、Y4、Y5、Y6の全てを用いて、数16ないし数18に順じてマハラノビスの距離を演算した。すなわち、数9と数10に示す第1の項目Y1(j)と第2の項目Y2(j)のみならず、画像を4つに区分して計算した相関係数r1(j)、r2(j)、r3(j)、r4(j)を使用して、前記Y1、Y2、Y3、Y4、Y5、Y6を求めて、マハラノビスの距離を算出した。(B) Embodiment of the present invention (calculation using Y 1 , Y 2 , Y 3 , Y 4 , Y 5 , Y 6 )
Next, using all of Y 1 , Y 2 , Y 3 , Y 4 , Y 5 , and Y 6 , the Mahalanobis distance was calculated in accordance with
この演算でも、以下の(カ)(キ)(ク)(ケ)(コ)の空間距離の比を求めた。
(カ)数字「6」のサンプル画像と、数字「8」の第1の対象画像との空間距離、
(キ)数字「6」のサンプル画像と、図4(A)に示す数字「6」の対象画像との空間距離、
(ク)数字「6」のサンプル画像と、図4(B)に示すように数字「6」から1画素だけ欠けた対象画像との空間距離、
(ケ)数字「6」のサンプル画像と、図4(C)に示すように数字「6」から2画素だけ欠けた対象画像との空間距離、
(コ)数字「6」のサンプル画像と、図4(D)に示すように数字「6」から3画素だけ欠けた対象画像との空間距離、
図5の線図(b)は、上記の演算で得られた空間距離の傾向を示しており、横軸の「0」は、空間距離の比(キ/カ)、「1」は空間距離の比(ク/カ)、「2」は空間距離の比(ケ/カ)、「3」は空間距離の比(コ/カ)である。Also in this calculation, the ratio of the spatial distances of the following (f) (ki) (ku) (ke) (ko) was obtained.
(F) Spatial distance between the sample image with the number “6” and the first target image with the number “8”;
(G) Spatial distance between the sample image of the number “6” and the target image of the number “6” shown in FIG.
(H) The spatial distance between the sample image of the number “6” and the target image lacking only one pixel from the number “6” as shown in FIG.
(K) Spatial distance between the sample image of the number “6” and the target image lacking only two pixels from the number “6” as shown in FIG.
(K) Spatial distance between the sample image of the number “6” and the target image lacking only 3 pixels from the number “6” as shown in FIG.
The diagram (b) in FIG. 5 shows the tendency of the spatial distance obtained by the above calculation, where “0” on the horizontal axis is the spatial distance ratio (ki / ka), and “1” is the spatial distance. The ratio (K / K), “2” is the spatial distance ratio (K / K), and “3” is the spatial distance ratio (K / K).
(c)図5の結果について
図5(a)の線図(a)で示される比較例では、画像を4つに区分して演算する相関係数を利用することなく、マハラノビスの距離を計算している。そのため、図4(B)(C)(D)に示すように、数字「6」の一部に欠けが生じ、しかも欠けの画素単位が多くなるにしたがって、サンプル画像との空間距離が離れ、その空間距離は、サンプル画像と「8」の画像との空間距離に近くなっていく。図5に示すように、線図(a)では、図4(D)に示すように欠けの画素単位が3つになった時点で、サンプル画像との空間距離が、画像「8」とサンプル画像との空間距離に対して35%まで接近している。(C) Results of FIG. 5 In the comparative example shown in the diagram (a) of FIG. 5A, the Mahalanobis distance is calculated without using the correlation coefficient calculated by dividing the image into four. is doing. Therefore, as shown in FIGS. 4B, 4C, and 4D, a part of the number “6” is missing, and as the number of missing pixels increases, the spatial distance from the sample image increases, The spatial distance becomes closer to the spatial distance between the sample image and the image “8”. As shown in FIG. 5, in the diagram (a), when the number of missing pixel units becomes three as shown in FIG. 4 (D), the spatial distance from the sample image is the image “8” and the sample. It is close to 35% of the spatial distance from the image.
つまり、この演算法において、数字「6」と数字「8」を識別するために、0から100%の間のいずれかにしきい値を設定すると、サンプル画像と図4(C)や図4(D)に示す画像との空間距離がしきい値を越えることがあり、一部でも欠けのある「6」の数字を、サンプル画像と異なるものであると判断する確率が高くなる。 In other words, in this calculation method, if a threshold value is set to any value between 0% and 100% in order to identify the numbers “6” and “8”, the sample image and FIGS. The spatial distance with the image shown in D) may exceed the threshold value, and the probability of determining that the number “6”, which is partially missing, is different from the sample image increases.
これに対し、本発明の実施の形態では、第1の項目Y1(j)と第2の項目Y2(j)のみならず、画像を4つに区分して計算した相関係数r1(j)、r2(j)、r3(j)、r4(j)を使用してマハラノビスの距離を算出している。そのため、図5の線図(b)のように、数字「6」に欠けが生じていても、サンプル画像との空間距離が、サンプル画像と数字「8」との空間距離ほどは離れない。例えば、図4(D)に示すように、数字「6」の3つの画素単位に「欠け」が生じていても、その画像とサンプル画像との空間距離は、数字「8」とサンプル画像との空間距離の4%未満である。On the other hand, in the embodiment of the present invention, not only the first item Y 1 (j) and the second item Y 2 (j) but also the correlation coefficient r 1 calculated by dividing the image into four. The Mahalanobis distance is calculated using (j), r 2 (j), r 3 (j), and r 4 (j). Therefore, as shown in the diagram (b) of FIG. 5, even if the number “6” is missing, the spatial distance between the sample image and the sample image is not as large as the spatial distance between the number “8”. For example, as shown in FIG. 4D, even if “missing” occurs in the three pixel units of the number “6”, the spatial distance between the image and the sample image is the number “8” and the sample image. Less than 4% of the spatial distance.
これは、サンプル画像が数字「6」である場合に、実施の形態によりマハラノビスの距離を演算すると、図4(B)(C)(D)に示すような、欠けのある画像の空間距離を短く、しかも数字「8」の空間距離を遠くできることを意味している。図3(C)によれば、サンプル画像が数字「6」であるときに、この「6」と空間距離が最も近いのが数字「8」である。しかし、実施の形態では、サンプル画像とこの数字「8」の画像との空間距離を遠く保つことができ、数字「8」をサンプル画像と違うものと判断できる。しかも、図4(B)(C)(D)のように、欠けのある数字をサンプル画像と同じ数字であると判別できる確率が高くなる。 When the sample image is the number “6” and the Mahalanobis distance is calculated according to the embodiment, the spatial distance of the missing image as shown in FIGS. 4 (B), (C), and (D) is obtained. This means that the distance of the space “8” is short and can be increased. According to FIG. 3C, when the sample image is the number “6”, the number “8” has the closest spatial distance to “6”. However, in the embodiment, the spatial distance between the sample image and the number “8” image can be kept far, and the number “8” can be determined to be different from the sample image. In addition, as shown in FIGS. 4B, 4C, and 4D, the probability that a missing number can be determined to be the same number as the sample image is increased.
よって、図1に示す画像判別装置の判別部4において、空間距離のしきい値を3〜5%の範囲に設定すれば、サンプル画像と同じ数字や文字で一部が欠けているものと同じ数字または文字と判断でき、しかも例えば「6」と「8」の文字とをしっかりと識別できるようになる。
Therefore, if the threshold value of the spatial distance is set in the range of 3 to 5% in the
次に、本発明の画像判別方法の他の実施の形態について説明する。
この実施の形態では、図4(B)(C)(D)のように、数字の「6」の一部を欠落させ、それぞれについてY1,Y2,Y3,Y4,Y5,Y6の5項目の計算値を得た。Next, another embodiment of the image discrimination method of the present invention will be described.
In this embodiment, as shown in FIGS. 4B, 4C, and 4D, a part of the numeral “6” is deleted, and Y 1 , Y 2 , Y 3 , Y 4 , Y 5 , to obtain a calculated value of the five items of Y 6.
以下の数19では、前記のように判別対象となる画像から得られた前記6個の項目の計算値Y1,Y2,Y3,Y4,Y5,Y6を用いてユークリッドの距離を求めている。このユークリッドの距離から、判別対象となる画像が所定のパターンの範疇に入っているかを判別することが可能である。In the following equation 19, the Euclidean distance is calculated using the calculated values Y 1 , Y 2 , Y 3 , Y 4 , Y 5 , Y 6 of the six items obtained from the image to be discriminated as described above. Seeking. From this Euclidean distance, it is possible to determine whether the image to be determined falls within a predetermined pattern category.
また、以下の数20に示すように、判別対象となる画像から得られた前記6個の項目の計算値Y1,Y2,Y3,Y4,Y5,Y6に独自の重み付けの係数a1,a2,a3,a4,a5,a6を付加して、判別対象となる画像が所定のパターンの範疇に入っているかを判別してもよい。a1は、計算値Y1に対する重み付け係数であり、a2は、計算値Y2に対する重み付け係数であり、a3,a4,a5,a6は、それぞれ計算値Y3,Y4,Y5,Y6に対する重み付け係数である。Further, as shown in the following
すなわち、判別対象となる画像を判別する際に、表4に示す第1の項目Y1(j)の平均値と第2の項目Y2(j)の平均値を用いた判別手法の重みと、画像を分割して相関係数を得ることにより判別手法との重みとを、画像の種類などに応じて随時設定することができる。したがって、数20に限られず、Y1とY2とに付加する係数とY3,Y4,Y5,Y6に付加する係数a1,a2,a3,a4,a5,a6を任意に変えて、Y1,Y2,Y3,Y4,Y5,Y6を加算するなどで空間距離を求めてもよい。That is, when discriminating the image to be discriminated, the weight of the discriminating method using the average value of the first item Y 1 (j) and the average value of the second item Y 2 (j) shown in Table 4 By dividing the image and obtaining the correlation coefficient, the weight with the discrimination method can be set as needed according to the type of the image. Accordingly, the coefficient added to Y 1 and Y 2 and the coefficients a 1, a 2, a 3, a 4, a 5 , a 6 added to Y 3 , Y 4 , Y 5 , Y 6 are arbitrarily changed without being limited to
例えば、サンプル画像が図6(A)に示す数字の「6」である場合に、相関係数を求めるために区分する4つの領域(i)(ii)(iii)(iv)の面積を、図6(B)に示すように画素データの多少に対応させて変化させることができる。そして、最も情報量の少ない領域(iii)に対応する重み付け係数a5を他の係数よりも小さくする。例えば、a1=1、a2=1、a3=1、a4=1、a5=0.5、a6=1などとすることが可能である。また、サンプル画像が図9(A)に示す数字の「9」の場合にも、画素単位の情報量の多少に応じて4つの領域(i)(ii)(iii)(iv)の面積を、図7(B)に示すように画素データの多少に対応させて変化させる。そして、情報量の少ない領域(ii)に対応する係数を他よりも小さい数のa4=0.5とし、その他の全ての係数a1,a2,a3,a5,a6を1としてもよい。 For example, when the sample image is the number “6” shown in FIG. 6A, the areas of the four regions (i), (ii), (iii), and (iv) to be divided to obtain the correlation coefficient are As shown in FIG. 6B, the pixel data can be changed according to the amount. Then, the weighting coefficient a5 corresponding to the region (iii) with the smallest amount of information is made smaller than the other coefficients. For example, a1 = 1, a2 = 1, a3 = 1, a4 = 1, a5 = 0.5, a6 = 1, etc. Also, when the sample image is the number “9” shown in FIG. 9A, the areas of the four regions (i), (ii), (iii), and (iv) are reduced according to the amount of information in units of pixels. As shown in FIG. 7B, the pixel data is changed according to the amount of pixel data. Then, the coefficient corresponding to the area (ii) with a small amount of information may be set to a smaller number of a4 = 0.5, and all other coefficients a1, a2, a3, a5, a6 may be set to 1.
このように、サンプル画像の情報の偏りに対応して、相関係数を求めるための区画領域の面積を変え、または相関係数に対応させた重み付け係数を変えることにより、画像の特徴に応じた高精度な文字などの判別が可能になる。 In this way, in accordance with the bias in the information of the sample image, the area of the partition area for obtaining the correlation coefficient is changed, or the weighting coefficient corresponding to the correlation coefficient is changed, so that the characteristics of the image are changed. High-precision characters can be distinguished.
また、次のような計算手法で、判別対象となる画像とサンプル画像のゼロ点との空間距離を求めてもよい。 Further, the spatial distance between the image to be discriminated and the zero point of the sample image may be obtained by the following calculation method.
この実施の形態では、図2に示すような例えば7×7=49の画素単位を有する画像が、サンプル画像と同種のものであるかを判別するものである。以下の表5に示すように、サンプル画像の数はn個である。表5では、1つのサンプル画像の画素単位の数をk−4としている。したがって、n個のサンプル画像の全ての画素単位の数、すなわち画像データの総数はn×(k−4)である。 In this embodiment, it is determined whether or not an image having, for example, 7 × 7 = 49 pixel units as shown in FIG. 2 is the same type as the sample image. As shown in Table 5 below, the number of sample images is n. In Table 5, the number of pixel units of one sample image is k-4. Therefore, the number of all pixel units of n sample images, that is, the total number of image data is n × (k−4).
表5内の「係数1」は、各サンプル画素を4つの領域に区分したときの左上の領域の相関係数である。同様に「係数2」は左下の領域の相関係数であり、「係数3」と「係数4」は、右上の領域の相関係数および右下の領域の相関係数である。すなわち、表5のXk−31は表4のr1(1)と同じであり、表5のXk−21は表4のr2(1)と同じである。表5のXk2は表4のr4(2)と同じである。このように、1つのサンプル画像はk−4個の画像データと、4つの相関係数を有しており、表5では、画像データと相関係数を共にXijで示している(i=1,2,3,・・・,k)(j=1,2,3,・・・,n)。“
表5では、それぞれのサンプル画像の同じ位置の画素単位のn個の画像データの平均値と、サンプル画像の同じ領域のn個の相関係数の平均値を共にmiで示している。また、それぞれのサンプル画像の同じ位置の画素単位のn個の画像データの標準偏差と、サンプル画像の同じ領域のn個の相関係数の標準偏差を共にσiで示している(i=1,2,3,・・・,k)。平均値miと標準偏差σiは、以下の数21の計算で得られる。Table 5 shows the average value of n of the image data in units of pixels of the same position of the respective sample images, the average value of n correlation coefficients of the same region of the sample image together with m i. Also, the standard deviation of n image data in pixel units at the same position in each sample image and the standard deviation of n correlation coefficients in the same region of the sample image are both indicated by σ i (i = 1). , 2, 3, ..., k). The average value m i and the standard deviation σ i can be obtained by the following equation 21.
表5に示す各項目の各データXijを、平均値miと標準偏差σiを用いて数22により基準化する。基準化後のxijを数23に列記する(i=1,2,3,・・・,k)(j=1,2,3,・・・,n)。Each data X ij of each item shown in Table 5 is normalized by Equation 22 using the average value m i and the standard deviation σ i . The normalized x ij is listed in Equation 23 (i = 1, 2, 3,..., K) (j = 1, 2, 3,..., N).
以下の表6には、n個のサンプル画像の各画素単位の画像データおよび各領域の相関係数が基準化されて記載されている。サンプル画像の同じ位置の画素単位のn個の基準化された値の平均値、およびサンプル画像の同じ領域の相関係数の基準化された値の平均値は全て「0」であり、標準偏差は全て「1」である。 In Table 6 below, the image data of each pixel unit of n sample images and the correlation coefficient of each region are standardized and described. The average value of the n normalized values of the pixel unit at the same position of the sample image and the average value of the normalized values of the correlation coefficient of the same region of the sample image are all “0”, and the standard deviation Are all “1”.
次に相関行列Rを数24により求める。
以下の数25は、項目xと項目yの相関係数を求めるための一般式であるが、この実施の携帯では、表6に示すように、平均値=0で、標準偏差=1であるため、相関係数は数26により求められる。
The following
次に以下の数27により相関行列Rの逆行列Aを求める。そして、図1に示すメモリ5に、この逆行列Aと、表5に示す平均値miと標準偏差σiを共にベクトルで記憶させる。Next, an inverse matrix A of the correlation matrix R is obtained by the following equation (27). Then, the inverse matrix A, the average value mi and the standard deviation σ i shown in Table 5 are both stored as vectors in the
表7は、判別対象となる画像の各画素の画像データと、4つに区分された各領域の相関係数がX1,X2,X3,・・・,Xkで示されている。Table 7 shows the image data of each pixel of the image to be discriminated and the correlation coefficient of each of the four areas divided by X 1 , X 2 , X 3 ,..., X k . .
そして、数28により、表7に示される判別対象となる画像のX1,X2,X3,・・・,Xkと、メモリ5に記憶されていた平均値miと標準偏差σiのそれぞれのベクトル値から、Y1,Y2,Y3,・・・Ykを算出する。Then, according to Equation 28, X 1 , X 2 , X 3 ,..., X k of the images to be discriminated shown in Table 7, the average value mi and the standard deviation σ i stored in the
そして、数28の値と、メモリ5に記憶されている逆行列Aと、表5に示す平均値miと標準偏差σiのベクトル値とから数29において、マハラノビスの距離を計算する。このマハラノビスの距離により、判別対象となる画像がサンプル画像の範疇のものかが判別される。Then, the Mahalanobis distance is calculated in Equation 29 from the value of Equation 28, the inverse matrix A stored in the
1 カメラ
2 A/D変換部
3 演算部
4 判別部
5 メモリ
10 判別対象物DESCRIPTION OF
Claims (10)
1つのサンプル画像がk個の画素単位の画像データを有し、且つ同種の画像と判断できるサンプル画像をn個用い、それぞれの1つのサンプル画像を、複数個の画素単位ごとに複数の領域に区分し、
n個のサンプル画像の同じ領域に位置する画素単位の画像データから相関係数を計算し、この相関係数を各領域ごとに求め、
全てのサンプル画像のk×n個の各画素単位の画像データの統計として得られる定数およびサンプル画像の各領域ごとの前記相関係数と、前記対象画像のk個の画素単位の画像データと、前記対象画像の各領域の相関係数とから、対象画像とサンプル画像との空間距離を求め、求められた空間距離によって、対象画像とサンプル画像との類比を判別することを特徴とする画像判別方法。In an image discrimination method for discriminating the similarity between a target image that is a discrimination target and a sample image,
One sample image has image data of k pixel units, and n sample images that can be determined to be the same type of image are used, and each one sample image is divided into a plurality of regions for each of a plurality of pixel units. Segment
A correlation coefficient is calculated from image data in units of pixels located in the same area of n sample images, and the correlation coefficient is obtained for each area.
Constants obtained as statistics of image data of k × n pixel units of all sample images and the correlation coefficient for each region of the sample image, image data of k pixel units of the target image, An image discrimination characterized in that a spatial distance between the target image and the sample image is obtained from a correlation coefficient of each region of the target image, and an analogy between the target image and the sample image is discriminated based on the obtained spatial distance. Method.
n個のサンプル画像のそれぞれ同じ位置にある画素単位のn個の画像データの平均値Mj(j=1,2,3,・・・,k)と、それぞれのサンプル画像ごとに、各画素単位の画像データと前記平均値Mjとの積を加算した線形式Li(i=1,2,3,・・・,n)と、各平均値Mjを加算した有効除数rとを求めて、比例定数であるY1(i)=Li/rを算出するとともに、
n個のサンプル画像のそれぞれ同じ位置にある画素単位の画像データから誤差分散Ve(i)を求めて、この誤差分散Ve(i)と前記有効除数rとから各サンプル画像ごとのSN比η(i)を求め、このSN比η(i)の逆数の平方根を計算して、各サンプル画像ごとの標準偏差であるY2(i)を算出し、
n個の前記Y1(i)の平均値と、n個の前記Y2(i)の平均値の2項目を前記定数とする。2. The image discriminating method according to claim 1, wherein a constant obtained as statistics of image data of k × n pixel units is obtained as follows.
An average value M j (j = 1, 2, 3,..., k) of n image data in pixel units at the same position in each of n sample images, and each pixel for each sample image A linear form L i (i = 1, 2, 3,..., N) obtained by adding the product of the unit image data and the average value M j, and an effective divisor r obtained by adding each average value M j. Obtain Y 1 (i) = L i / r which is a proportionality constant,
An error variance Ve (i) is obtained from image data in units of pixels at the same position in each of the n sample images, and the SN ratio η (for each sample image is obtained from the error variance Ve (i) and the effective divisor r. i), and the square root of the reciprocal of this SN ratio η (i) is calculated to calculate Y 2 (i), which is the standard deviation for each sample image,
Two items, an average value of n Y 1 (i) and an average value of n Y 2 (i), are defined as the constants.
サンプル画像の1つの領域内の画素単位の数をpとし、n個のサンプル画像のそれぞれ同じ位置にある画素単位のn個の画像データの平均値Xqバー(q=1,2,3,・・・,p)と、各サンプル画像ごとのp個の画素単位の画像データの平均値Yiバー(i=1,2,3,・・・,n)と、全てのサンプル画像の同じ領域内のn×p個の画素単位の画像データの平均値Xバー、
とから求められる請求項1または2記載の画像判別方法。The correlation coefficient for each region is
The number of pixel units in one region of the sample image is p, and an average value X q bar (q = 1, 2, 3, 3) of n image data in pixel units at the same position in each of the n sample images. .., P), the average value Y i bar (i = 1, 2, 3,..., N) of the image data of p pixel units for each sample image, and the same for all sample images An average value X bar of image data of n × p pixel units in the region;
The image discrimination method according to claim 1, wherein the image discrimination method is obtained from:
複数の画素単位ごとの画像データを有し、且つ同種の画像と判断できるサンプル画像をn個用い、それぞれのサンプル画像を、複数個の画素単位ごとに複数の領域に区分し、1つのサンプル画像における画素単位の数および区分した領域の数の合計をkとし、
各画素単位の画像データ、および区分したそれぞれの領域ごとに求めた画像データの相関係数を、共にXij(i=1,2,3,・・・,k)(j=1,2,3,・・・,n)で表し、
それぞれの画素単位の画像データのサンプル画像の数nでの平均値、およびそれぞれの領域の前記相関係数のサンプル画像の数nでの平均値を、共にmi(i=1,2,3,・・・,k)とし、
それぞれの画素単位の画像データのサンプル画像の数nでの標準偏差、およびそれぞれの領域の前記相関係数のサンプル画像の数nでの標準偏差を、共にσi(i=1,2,3,・・・,k)として、
規格化値xij=(Xij−mi)/σiを求め、
前記対象画像の画素単位の画像データおよび前記対象画像の各領域での相関係数と、前記規格化値xijとから、対象画像とサンプル画像との空間距離を求め、求められた空間距離によって、対象画像とサンプル画像との類比を判別することを特徴とする画像判別方法。In an image discrimination method for discriminating the similarity between a target image that is a discrimination target and a sample image,
Using n sample images that have image data for each pixel unit and can be determined as the same type of image, each sample image is divided into a plurality of regions for each pixel unit, and one sample image And k is the total number of pixel units and the number of segmented areas in
X ij (i = 1, 2, 3,..., K) (j = 1, 2, k) is used as the correlation coefficient of the image data for each pixel and the image data obtained for each divided area. 3, ..., n)
The average value of the image data of each pixel unit in the number n of sample images and the average value of the correlation coefficient in each region in the number n of sample images are both mi (i = 1, 2, 3). , ..., k),
Σ i (i = 1, 2, 3) is the standard deviation of the image data of each pixel unit in the number n of sample images and the standard deviation of the correlation coefficient in each region in the number n of sample images. , ..., k)
Obtain a normalized value x ij = (X ij −m i ) / σ i ,
The spatial distance between the target image and the sample image is obtained from the image data in pixel units of the target image, the correlation coefficient in each region of the target image, and the normalized value x ij , and is calculated according to the obtained spatial distance. An image discrimination method comprising discriminating an analogy between a target image and a sample image.
サンプル画像内の1つの領域の画素単位数をpとし、n個のサンプル画像のそれぞれ同じ位置にある画素単位のn個の画像データの平均値Xqバー(q=1,2,3,・・・,p)と、各サンプル画像ごとのp個の画素単位の画像データの平均値Yiバー(i=1,2,3,・・・,n)と、全てのサンプル画像の同じ領域内のn×p個の画素単位の画像データの平均値Xバー、
とから求められる請求項8記載の画像判別方法。The correlation coefficient for each region is
An average value X q bar (q = 1, 2, 3,...) Of n image data in pixel units at the same position in each of n sample images, where p is the number of pixel units in one region in the sample image. .., P), the average value Y i bar (i = 1, 2, 3,..., N) of image data of p pixel units for each sample image, and the same area of all sample images An average value X bar of image data of n × p pixel units in
The image discrimination method according to claim 8, which is obtained from:
Applications Claiming Priority (3)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2006341655 | 2006-12-19 | ||
JP2006341655 | 2006-12-19 | ||
PCT/JP2007/073918 WO2008075592A1 (en) | 2006-12-19 | 2007-12-12 | Image discriminating method |
Publications (1)
Publication Number | Publication Date |
---|---|
JPWO2008075592A1 true JPWO2008075592A1 (en) | 2010-04-08 |
Family
ID=39536223
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2008550110A Withdrawn JPWO2008075592A1 (en) | 2006-12-19 | 2007-12-12 | Image discrimination method |
Country Status (2)
Country | Link |
---|---|
JP (1) | JPWO2008075592A1 (en) |
WO (1) | WO2008075592A1 (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP6538487B2 (en) * | 2015-08-28 | 2019-07-03 | 大阪瓦斯株式会社 | Heterogeneous energy consumption estimation device and heterogeneous characteristic estimation device |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH03100956A (en) * | 1989-09-13 | 1991-04-25 | Mitsubishi Electric Corp | Magnetic tape unit |
JP2002366957A (en) * | 2001-04-05 | 2002-12-20 | Fuji Electric Co Ltd | Device and method for collating signature and program for making computer perform the method |
JP2003296735A (en) * | 2002-03-29 | 2003-10-17 | Nec Corp | Method and device for generating face meta-data |
JP2003296734A (en) * | 2002-03-26 | 2003-10-17 | Agilent Technol Inc | System of object classification employing dimension reduction |
JP2004152087A (en) * | 2002-10-31 | 2004-05-27 | Fuji Photo Film Co Ltd | Method and apparatus for extracting feature vector of image |
JP2006177682A (en) * | 2004-12-20 | 2006-07-06 | Ricoh Co Ltd | Tone quality evaluation method for image forming apparatus, manufacturing method for image forming apparatus, modification method for image forming apparatus, and image forming apparatus |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH03100956U (en) * | 1990-01-31 | 1991-10-22 |
-
2007
- 2007-12-12 WO PCT/JP2007/073918 patent/WO2008075592A1/en active Application Filing
- 2007-12-12 JP JP2008550110A patent/JPWO2008075592A1/en not_active Withdrawn
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH03100956A (en) * | 1989-09-13 | 1991-04-25 | Mitsubishi Electric Corp | Magnetic tape unit |
JP2002366957A (en) * | 2001-04-05 | 2002-12-20 | Fuji Electric Co Ltd | Device and method for collating signature and program for making computer perform the method |
JP2003296734A (en) * | 2002-03-26 | 2003-10-17 | Agilent Technol Inc | System of object classification employing dimension reduction |
JP2003296735A (en) * | 2002-03-29 | 2003-10-17 | Nec Corp | Method and device for generating face meta-data |
JP2004152087A (en) * | 2002-10-31 | 2004-05-27 | Fuji Photo Film Co Ltd | Method and apparatus for extracting feature vector of image |
JP2006177682A (en) * | 2004-12-20 | 2006-07-06 | Ricoh Co Ltd | Tone quality evaluation method for image forming apparatus, manufacturing method for image forming apparatus, modification method for image forming apparatus, and image forming apparatus |
Also Published As
Publication number | Publication date |
---|---|
WO2008075592A1 (en) | 2008-06-26 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US12020474B2 (en) | Image processing apparatus, image processing method, and non-transitory computer-readable storage medium | |
US11823429B2 (en) | Method, system and device for difference automatic calibration in cross modal target detection | |
US8488878B2 (en) | Sky detection system used in image extraction device and method using sky detection system | |
CN112036395B (en) | Text classification recognition method and device based on target detection | |
CN108288253B (en) | HDR image generation method and device | |
WO2022237153A1 (en) | Target detection method and model training method therefor, related apparatus, medium, and program product | |
JP2021103555A (en) | Image detection method, device, electronic apparatus, storage medium, and program | |
JP2008046903A (en) | Apparatus and method for detecting number of objects | |
EP3376433A1 (en) | Image processing apparatus, image processing method, and image processing program | |
CN108256588A (en) | A kind of several picture identification feature extracting method and system | |
CN111414931A (en) | Multi-branch multi-scale small target detection method based on image depth | |
EP3410396B1 (en) | Moving object tracking apparatus, moving object tracking method, and computer-readable medium | |
JP2021189527A (en) | Information processing device, information processing method, and program | |
CN114155278A (en) | Target tracking and related model training method, related device, equipment and medium | |
JP5027201B2 (en) | Telop character area detection method, telop character area detection device, and telop character area detection program | |
JP4918615B2 (en) | Object number detection device and object number detection method | |
JPWO2008075592A1 (en) | Image discrimination method | |
US11983242B2 (en) | Learning data generation device, learning data generation method, and learning data generation program | |
JP6855175B2 (en) | Image processing equipment, image processing methods and programs | |
KR102597692B1 (en) | Method, apparatus, and computer program for measuring volume of objects by using image | |
JP4674920B2 (en) | Object number detection device and object number detection method | |
JP7239002B2 (en) | OBJECT NUMBER ESTIMATING DEVICE, CONTROL METHOD, AND PROGRAM | |
CN115439875A (en) | Posture evaluation device, method and system | |
CN111325194B (en) | Character recognition method, device and equipment and storage medium | |
JP6717769B2 (en) | Information processing device and program |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20101116 |
|
A761 | Written withdrawal of application |
Free format text: JAPANESE INTERMEDIATE CODE: A761 Effective date: 20101213 |