JP2005043260A - Visual inspection device of grain of rice - Google Patents

Visual inspection device of grain of rice Download PDF

Info

Publication number
JP2005043260A
JP2005043260A JP2003278595A JP2003278595A JP2005043260A JP 2005043260 A JP2005043260 A JP 2005043260A JP 2003278595 A JP2003278595 A JP 2003278595A JP 2003278595 A JP2003278595 A JP 2003278595A JP 2005043260 A JP2005043260 A JP 2005043260A
Authority
JP
Japan
Prior art keywords
density distribution
distribution histogram
value
density
rice
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2003278595A
Other languages
Japanese (ja)
Inventor
Akimori Iwase
晃盛 岩瀬
Hiroyuki Maehara
裕之 前原
Hideto Oda
英人 小田
Michiko Matsuda
美智子 松田
Naoya Uemukai
直哉 植向
Yuuki Kawasaki
勇樹 川崎
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.)
Satake Engineering Co Ltd
Satake Corp
Original Assignee
Satake Engineering Co Ltd
Satake Corp
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 Satake Engineering Co Ltd, Satake Corp filed Critical Satake Engineering Co Ltd
Priority to JP2003278595A priority Critical patent/JP2005043260A/en
Publication of JP2005043260A publication Critical patent/JP2005043260A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Investigating Materials By The Use Of Optical Means Adapted For Particular Applications (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To provide a visual inspection device of a grain of rice capable of specifying a trace of rice bran adhering to the grain of rice by setting a threshold highly accurately. <P>SOLUTION: This device has an illumination means 2 for illuminating the grain of rice, an imaging means 4 for imaging the grain of rice 1 illuminated by the illumination means 2 by an imaging camera 3 to acquire an analog image signal, and an image conversion means 5 for performing binarization processing of the acquired analog image signal and converting it into a digital signal showing density. In the device, image processing of a digital image signal acquired by the image conversion means 5 is performed, and a density distribution histogram on the image density is produced, and the density distribution acquired from the density distribution histogram is accumulated to thereby produce an accumulative density distribution histogram, and the threshold T is determined from the accumulative density distribution histogram, and binarization determination relative to the grain of rice and the adhering rice bran is performed. <P>COPYRIGHT: (C)2005,JPO&NCIPI

Description

本発明は、米粒の外観検査装置に関する。 The present invention relates to a rice grain appearance inspection apparatus.

従来、米などの穀粒をその表面に照射した光の反射率や透過率によって選別する穀粒選別機が提案されている。この穀粒選別機としては、連続状に流れる粒状物に光を照射して粒状物の外観を撮像し、得られた画像信号を処理して濃度分布を求め、所定のしきい値を基準として二値化した二値化画像を作成し、この二値化画像に基づいて不良粒か否かを判定するものがある(例えば、特許文献1参照)。   Conventionally, a grain sorter has been proposed that sorts grains such as rice according to the reflectance and transmittance of light irradiated on the surface thereof. As this grain sorter, light is irradiated to the granular material flowing continuously, the appearance of the granular material is imaged, the obtained image signal is processed to obtain the concentration distribution, and a predetermined threshold is used as a reference There is one that creates a binarized image and determines whether or not it is a defective particle based on the binarized image (see, for example, Patent Document 1).

しかしながら、粒状物を照明光の下で撮像素子により撮像して画像処理する際に、光源の電圧変動等に起因して照度が変化し、光量のばらつき(シェーディング)や、画像信号の直流成分のドリフト現象が生じることがある。そこで、これらの変化に対して、画像信号を二値化するためのしきい値を最適値に設定する必要があるが、これを自動的に最適値に設定することは困難であった。   However, when a granular object is imaged with an imaging device under illumination light and image processing is performed, the illuminance changes due to voltage fluctuations of the light source, etc. A drift phenomenon may occur. Therefore, it is necessary to set the threshold value for binarizing the image signal to the optimum value for these changes, but it is difficult to automatically set the threshold value to the optimum value.

また、米粒に付着した糠を特定する際は、撮像した米粒の画像面積に対して付着した糠の画像面積の占める割合が1〜2%程度にしかならないから、ピンホールのような微細な面積の場合、従来の穀粒選別機では精度の高いしきい値を設定することができず、糠付着の識別が困難であった。   In addition, when identifying wrinkles attached to rice grains, the proportion of the image area of the attached wrinkles to the image area of the captured rice grains is only about 1 to 2%, so a fine area such as a pinhole In this case, the conventional grain sorter cannot set a high-accuracy threshold, and it is difficult to identify wrinkle adhesion.

特開2001−145855JP2001-145855

本発明は上記問題点にかんがみ、しきい値を高精度に設定して、米粒に付着した微量の糠を特定することが可能な米粒の外観検査装置を提供することを技術的課題とする。   In view of the above problems, an object of the present invention is to provide a rice grain appearance inspection apparatus capable of setting a threshold value with high accuracy and identifying a small amount of rice cake attached to rice grains.

上記課題を解決するため請求項1の発明は、米粒を照明する照明手段と、該照明手段により照明された米粒を撮像カメラにより撮像し、アナログ画像信号を得る撮像手段と、得られたアナログ画像信号を二値化処理して濃淡を表すデジタル信号に変換する画像変換手段と、該画像変換手段により得られたデジタル画像信号の画像処理を行い、画像の濃度に関する濃度分布ヒストグラムを作成する濃度分布ヒストグラム作成手段と、該濃度分布ヒストグラム作成手段により求められた濃度分布を累積し、累積濃度分布ヒストグラムを作成する累積濃度分布ヒストグラム作成手段と、該累積濃度分布ヒストグラム作成手段により求められた累積濃度分布ヒストグラムから、しきい値Tを決定して米粒と付着糠とを2値化判別する2値化判別手段と、を備えた米粒の外観検査装置であって、該2値化判別手段は、前記累積濃度分布ヒストグラム上で少なくとも2箇所の総画素数に対する適宜割合の累積画素数を求めるとともに、各累積画素数に対応する濃度値を算出する濃度値算出手段と、該濃度値算出手段で算出された累積画素数に対応する濃度値をプロットするとともに、該プロットした2点間を通る直線の式を作成する一次関数作成手段と、該一次関数作成手段で求めた直線の式に総画素数を代入して、そのときの濃度値を仮の真値とする仮の真値作成手段と、該仮の真値作成手段により求めた仮の真値と、あらかじめサンプルの計測などにより設定された基準値とを比較して、その偏差を求める偏差算出手段と、該偏差算出手段により求めた偏差と仮の真値とを加算してしきい値Tを決定するしきい値決定手段と、を備える、という技術的手段を講じた。 In order to solve the above-mentioned problems, the invention of claim 1 is directed to an illuminating means for illuminating rice grains, an imaging means for taking an image of the rice grains illuminated by the illuminating means and obtaining an analog image signal, and an obtained analog image Image conversion means for binarizing the signal to convert it into a digital signal representing light and shade, and density distribution for performing image processing of the digital image signal obtained by the image conversion means and creating a density distribution histogram relating to the density of the image Histogram creation means, cumulative density distribution histogram creation means for accumulating the density distribution obtained by the density distribution histogram creation means to create a cumulative density distribution histogram, and cumulative density distribution obtained by the cumulative density distribution histogram creation means Binarization discriminating means for determining a threshold value T from the histogram to binarize rice grains and adhered wrinkles; The binarization discriminating means calculates the cumulative number of pixels in an appropriate ratio with respect to the total number of pixels in at least two locations on the cumulative density distribution histogram, and determines each cumulative pixel number. A density value calculating means for calculating a corresponding density value, a density value corresponding to the cumulative number of pixels calculated by the density value calculating means, and a linear expression that passes between the two plotted points is created. A function creating means, a provisional true value creating means for substituting the total number of pixels into the linear formula obtained by the linear function creating means, and setting the density value at that time as a provisional true value; and the provisional true value Deviation calculating means for comparing the provisional true value obtained by the preparation means with a reference value set in advance by measurement of a sample, for obtaining the deviation, and the deviation obtained by the deviation calculating means and the provisional true value And the threshold T The technical means of providing a threshold value determining means for determining was provided.

これにより、米粒に占める糠の画素割合があらかじめ所定値(例えば、25%)を超えることがないと分かっている場合は、累積濃度分布ヒストグラム上で累積画素数を50%と75%を指定し、それぞれの濃度値を算出して一次関数を作成する。この一次関数からしきい値Tが高精度に算出され、このしきい値Tを累積濃度分布ヒストグラム上に設定すると、米粒に付着した微量の糠を特定することが可能となる。また、微小な糠の画像割合があらかじめ10%を超えることはないと分かっている場合は、累積画素数を50%と90%を指定し、それぞれの濃度値を算出して一次関数を作成し、しきい値Tを算出するとよい。   As a result, if it is known that the pixel ratio of rice bran in rice grains does not exceed a predetermined value (for example, 25%) in advance, the cumulative pixel number is designated as 50% and 75% on the cumulative density distribution histogram. Each density value is calculated and a linear function is created. When the threshold value T is calculated with high accuracy from this linear function and this threshold value T is set on the cumulative density distribution histogram, it is possible to identify a small amount of cocoons attached to the rice grains. If it is known that the image ratio of minute wrinkles will not exceed 10% in advance, specify the cumulative number of pixels as 50% and 90%, calculate the respective density values, and create a linear function. The threshold value T may be calculated.

また、前記濃度分布ヒストグラム作成手段の後工程には、得られた濃度分布ヒストグラムから、判別分析法によるしきい値Tを決定して米粒と背景とを二値化判別し、背景のみを除去する背景除去手段を備えるとよい。 Further, in the subsequent process of the density distribution histogram creating means, the threshold value T is determined by the discriminant analysis method from the obtained density distribution histogram to binarize and discriminate the rice grain and the background, and only the background is removed. A background removing means may be provided.

以上のように本発明によれば、米粒を照明する照明手段と、該照明手段により照明された米粒を撮像カメラにより撮像し、アナログ画像信号を得る撮像手段と、得られたアナログ画像信号を二値化処理して濃淡を表すデジタル信号に変換する画像変換手段と、該画像変換手段により得られたデジタル画像信号の画像処理を行い、画像の濃度に関する濃度分布ヒストグラムを作成する濃度分布ヒストグラム作成手段と、該濃度分布ヒストグラム作成手段により求められた濃度分布を累積し、累積濃度分布ヒストグラムを作成する累積濃度分布ヒストグラム作成手段と、該累積濃度分布ヒストグラム作成手段により求められた累積濃度分布ヒストグラムから、しきい値Tを決定して米粒と付着糠とを2値化判別する2値化判別手段と、を備えた米粒の外観検査装置であって、該2値化判別手段は、前記累積濃度分布ヒストグラム上で少なくとも2箇所の総画素数に対する適宜割合の累積画素数を求めるとともに、各累積画素数に対応する濃度値を算出する濃度値算出手段と、該濃度値算出手段で算出された累積画素数に対応する濃度値をプロットするとともに、該プロットした2点間を通る直線の式を作成する一次関数作成手段と、該一次関数作成手段で求めた直線の式に総画素数を代入して、そのときの濃度値を仮の真値とする仮の真値作成手段と、該仮の真値作成手段により求めた仮の真値と、あらかじめサンプルの計測などにより設定された基準値とを比較して、その偏差を求める偏差算出手段と、該偏差算出手段により求めた偏差と仮の真値とを加算してしきい値Tを決定するしきい値決定手段と、を備えたので、しきい値Tを高精度に設定して、米粒に付着した微量の糠を特定することが可能な米粒の外観検査装置を提供することができる。 As described above, according to the present invention, the illuminating unit that illuminates the rice grains, the imaging unit that captures the rice grains illuminated by the illuminating unit with the imaging camera, and obtains an analog image signal, and the obtained analog image signal Image conversion means for converting to a digital signal representing density by performing a digitization process, and density distribution histogram creation means for performing image processing of the digital image signal obtained by the image conversion means and creating a density distribution histogram relating to the density of the image And cumulative density distribution histogram creation means for accumulating the density distribution obtained by the density distribution histogram creation means and creating a cumulative density distribution histogram, and cumulative density distribution histogram obtained by the cumulative density distribution histogram creation means, Rice grain comprising: binarization discriminating means for binarizing and discriminating rice grain and adhered wrinkles by determining threshold T The binarization discriminating means obtains a cumulative number of pixels in an appropriate ratio with respect to the total number of pixels in at least two locations on the cumulative density distribution histogram and density values corresponding to the respective cumulative pixel numbers. A density value calculating unit that calculates the density value, a linear function generating unit that plots a density value corresponding to the cumulative number of pixels calculated by the density value calculating unit, and generates a linear equation that passes between the two plotted points; Substituting the total number of pixels into the linear equation obtained by the linear function creating means, and obtaining a temporary true value creating means for setting the density value at that time as a temporary true value, and the temporary true value creating means The provisional true value is compared with a reference value set in advance by measurement of a sample and the deviation is calculated, and the deviation obtained by the deviation calculation means is added to the provisional true value. Threshold to determine threshold T Therefore, it is possible to provide a rice grain appearance inspection apparatus that can set the threshold value T with high accuracy and identify a small amount of rice cake adhering to the rice grain.

また、前記濃度分布ヒストグラム作成手段の後工程には、得られた濃度分布ヒストグラムから、判別分析法によるしきい値Tを決定して米粒と背景とを二値化判別し、背景のみを除去する背景除去手段を備えたので、濃度分布ヒストグラム上で撮像画像中の背景を特定してこれを除去することができる。 Further, in the subsequent process of the density distribution histogram creating means, the threshold value T is determined by the discriminant analysis method from the obtained density distribution histogram to binarize and discriminate the rice grain and the background, and only the background is removed. Since the background removing means is provided, the background in the captured image can be identified and removed from the density distribution histogram.

以下、図面を参照して本発明を実施するための最良の形態を説明する。図1は米粒の外観検査装置で使用する米粒の外観検査装置の一例を示すブロック図である。 The best mode for carrying out the present invention will be described below with reference to the drawings. FIG. 1 is a block diagram showing an example of a rice grain appearance inspection apparatus used in a rice grain appearance inspection apparatus.

符号1は検査対象となる米粒であり、符号2は米粒を斜め上方から照明するための照明手段となる光源であり、符号3は前記照明手段により照明された米粒を撮像する撮像カメラ(例えば、固体カメラ;CCDカメラ)であり、RGBなどのアナログ画像信号が得られる。符号4は前記撮像カメラ3を制御するためのカメラ制御装置である。符号5は前記撮像カメラ3により撮像して得られたアナログ画像信号をデジタル信号に変換して画像メモリに記憶し、この記憶データに対して処理を行うための画像処理装置である。符号6は前記撮像カメラ3により撮像して得られた画像をモニタするための画像モニタ装置である。 Reference numeral 1 is a rice grain to be inspected, reference numeral 2 is a light source serving as an illuminating means for illuminating the rice grain obliquely from above, and reference numeral 3 is an imaging camera for imaging the rice grain illuminated by the illuminating means (for example, A solid-state camera (CCD camera), which can obtain analog image signals such as RGB. Reference numeral 4 denotes a camera control device for controlling the imaging camera 3. Reference numeral 5 denotes an image processing apparatus for converting an analog image signal obtained by imaging with the imaging camera 3 into a digital signal, storing it in an image memory, and processing the stored data. Reference numeral 6 denotes an image monitoring device for monitoring an image obtained by imaging with the imaging camera 3.

前記画像処理装置5は、コンピュータシステムを有し、以下の処理手段を有する。すなわち、米粒を撮像カメラ3により撮像し、得られたアナログ画像信号を二値化処理して濃淡を表すデジタル信号に変換する画像変換手段と、該画像変換手段により得られたデジタル画像信号の画像処理を行い、画像の濃度に関する濃度分布ヒストグラムを作成する濃度分布ヒストグラム作成手段と、該濃度分布ヒストグラム作成手段により求められた濃度分布を累積し、累積濃度分布ヒストグラムを作成する累積濃度分布ヒストグラム作成手段と、該累積濃度分布ヒストグラム作成手段により求められた累積濃度分布ヒストグラムから、しきい値Tを決定して米粒と付着糠とを2値化判別する2値化判別手段と、を備えている。 The image processing apparatus 5 has a computer system and has the following processing means. That is, the rice grain is imaged by the imaging camera 3, the obtained analog image signal is binarized and converted into a digital signal representing light and shade, and the image of the digital image signal obtained by the image conversion unit A density distribution histogram creating means for performing processing to create a density distribution histogram relating to the density of the image, and a cumulative density distribution histogram creating means for creating a cumulative density distribution histogram by accumulating the density distribution obtained by the density distribution histogram creating means And binarization discriminating means for binarizing discriminating rice grains and attached wrinkles by determining a threshold value T from the cumulative density distribution histogram obtained by the cumulative density distribution histogram creating means.

図2は、本発明の米粒の外観検査装置の一実施形態における処理の流れを示すフローチャートである。これを参照して外観検査装置について説明する。 FIG. 2 is a flowchart showing the flow of processing in an embodiment of the rice grain appearance inspection apparatus of the present invention. The appearance inspection apparatus will be described with reference to this.

ステップ1では、米粒を斜光照明の下でCCD撮像カメラ3により撮像して得られた画像のアナログ信号を二値化処理して濃淡を表すデジタル信号に変換し、このデジタル信号を画像メモリに格納する。このステップ1で得られる米粒の画像は背景画像を含んでおり、その一例を図3に示す。 In step 1, an analog signal of an image obtained by imaging rice grains with a CCD imaging camera 3 under oblique illumination is binarized to convert it into a digital signal representing light and dark, and this digital signal is stored in an image memory. To do. The rice grain image obtained in step 1 includes a background image, an example of which is shown in FIG.

ステップ2では、ステップ1により得られた画像(図3参照)において、その領域内の各画素点の濃度を解析する。本実施形態の場合、濃度は8ビットの信号により0(黒)〜255(白)の256段階で表される。 In step 2, the density of each pixel point in the region in the image obtained in step 1 (see FIG. 3) is analyzed. In the case of the present embodiment, the density is expressed in 256 levels from 0 (black) to 255 (white) by an 8-bit signal.

ステップ3では、ステップ2により求められた各画素点の濃度を横軸にとり、画素数を縦軸にとり、濃度分布ヒストグラムを作成する。この濃度分布ヒストグラムの一例を図4に示す。 In step 3, a density distribution histogram is created by taking the density of each pixel point obtained in step 2 on the horizontal axis and the number of pixels on the vertical axis. An example of this density distribution histogram is shown in FIG.

ステップ4及びステップ5は、米粒と背景とを二値化判別し、背景のみを除去する背景除去手段を示す。ステップ4では、ステップ3により求められた濃度分布ヒストグラムから背景画像を除去するため、判別分析法によるしきい値Tが決定される。この判別分析法は、背景画像と米粒画像の2つのグループがあり、この2つのグループに関するクラス内分散とクラス間分散の分散比が最大となるようにしきい値Tが決定される。いま、背景画像グループ内の画素数がn、濃度値平均がμ、分散がσ とし、米粒画像グループ内の画素数がn、濃度値平均がμ、分散がσ とし、全画素数の濃度平均値をμで表すと、クラス内分散σ は式(1)のようになる。

Figure 2005043260
また、クラス間分散σ は式(2)のようになる。
Figure 2005043260
そして分散比ηは式(3)のようになる。
Figure 2005043260
このηが最大となるTをしきい値Tとして決定すると、2値化判別することができる。図4の例では、しきい値Tは濃度値50となり、濃度値50未満の領域が背景画像として決定される。 Steps 4 and 5 show background removal means for binarizing and discriminating rice grains and the background and removing only the background. In step 4, in order to remove the background image from the density distribution histogram obtained in step 3, a threshold value T by the discriminant analysis method is determined. In this discriminant analysis method, there are two groups of a background image and a rice grain image, and the threshold value T is determined so that the variance ratio of intra-class variance and inter-class variance relating to these two groups is maximized. Now, the number of pixels n 1 in the background image group 1 concentration values mean mu, variance and sigma 1 2, rice grain number of pixels n 2 in the image group, 2 concentration values mean mu, variance sigma 2 2 and then, to represent the average density of the total number of pixels in the mu T, within-class variance sigma w 2 is as equation (1).
Figure 2005043260
Further, the interclass variance σ B 2 is as shown in the equation (2).
Figure 2005043260
The dispersion ratio η is as shown in the equation (3).
Figure 2005043260
If T at which η is maximum is determined as the threshold value T, binarization can be determined. In the example of FIG. 4, the threshold value T has a density value 50, and an area less than the density value 50 is determined as a background image.

ステップ5では、ステップ4により求められたしきい値Tに基づいて、濃度値50未満の背景画像の除去を行い、米粒画像の濃度分布ヒストグラムを作成する。この一例を図5に示す。   In step 5, the background image having a density value less than 50 is removed based on the threshold value T obtained in step 4, and a density distribution histogram of the rice grain image is created. An example of this is shown in FIG.

ステップ6乃至ステップ13は、累積濃度分布ヒストグラムからしきい値Tを決定し、米粒と付着糠とを2値化判別する2値化判別手段を示す。ステップ6では、ステップ5により求められた濃度分布を累積し、濃度値を横軸にとり、累積画素数を縦軸にとり、累積濃度分布ヒストグラムを作成する。この一例を図6に示す。   Steps 6 to 13 show binarization determination means for determining the threshold value T from the cumulative density distribution histogram and binarizing the rice grains and the attached wrinkles. In step 6, the density distribution obtained in step 5 is accumulated, the density value is taken on the horizontal axis, and the cumulative number of pixels is taken on the vertical axis to create a cumulative density distribution histogram. An example of this is shown in FIG.

ステップ7では、ステップ6により求められた累積濃度分布ヒストグラムから総画素数の50%の累積画素数及び総画素数の75%の累積画素数を求めるとともに、累積画素数50%の濃度値及び累積画素数75%の濃度値を算出する。累積画素数50%の濃度値は累積画素の中央の値となり、累積画素数75%の濃度値は累積画素の4分の3の値となり、これらの累積画素を指定することは画素割合が微小な糠を特定するためには有効である。つまり、微小な糠の画素割合が25%より大きくなることがないという前提条件から決めたものである。したがって、微小な糠の画像割合があらかじめ10%を超えることはないと分かっていれば、累積画素数50%の濃度値と、累積画素数90%の濃度値を算出すればよい。 In step 7, the cumulative number of pixels of 50% of the total number of pixels and the cumulative number of pixels of 75% of the total number of pixels are obtained from the cumulative density distribution histogram obtained in step 6, and the density value and cumulative number of the cumulative number of pixels are 50%. A density value of 75% of pixels is calculated. A density value of 50% cumulative pixels is the central value of the cumulative pixels, a density value of 75% cumulative pixels is three-quarters of the cumulative pixels, and specifying these cumulative pixels has a small pixel ratio. It is effective to identify nasty traps. That is, it is determined from the precondition that the pixel ratio of minute wrinkles does not become larger than 25%. Therefore, if it is known that the image ratio of minute wrinkles does not exceed 10% in advance, a density value with a cumulative pixel number of 50% and a density value with a cumulative pixel number of 90% may be calculated.

ステップ8では、2点間(累積画素数50%,その濃度値)、(累積画素数75%,その濃度値)を通る直線の式を作成する。これは図6に示すようにy=mx+bとして直線の方程式で表される。 In step 8, a straight line formula is created that passes between two points (cumulative pixel number 50%, its density value) and (cumulative pixel number 75%, its density value). This is represented by a linear equation as y = mx + b as shown in FIG.

ステップ9では、ステップ8で求めた直線の式のyに総画素数(累積画素数100%)を代入してそのときの濃度値xを求め、これを仮の真値とする。 In step 9, the total number of pixels (accumulated pixel number 100%) is substituted into y in the straight line expression obtained in step 8, and the density value x at that time is obtained, which is set as a temporary true value.

ステップ10では、予めサンプルの計測などにより設定された値を基準値とし、ステップ9で求めた仮の真値との差をδとしておく。 In step 10, a value set in advance by measurement of a sample or the like is set as a reference value, and a difference from the provisional true value obtained in step 9 is set as δ.

ステップ11では、ステップ10で設定した基準値と仮の真値との差δを算出する。すなわち、図7に示すように空間における基準値と仮の真値との差δと、ステップ8で求めた傾きmと、累積画素数75%の濃度値C75とは、互いに関連性があることが分かる。平面の方程式はaX+bY+cZ+d=0の式で表すことができるので、δ=αm+βC75+γと表現し、この平面の方程式を解くと、δを求めることができる。なお、なお、α、β、γの値は重回帰分析で算出したものを使用するとよい。 In step 11, a difference δ between the reference value set in step 10 and the provisional true value is calculated. That is, as shown in FIG. 7, the difference δ between the reference value in the space and the provisional true value, the slope m obtained in step 8, and the density value C75 with the cumulative number of pixels of 75% are mutually related. I understand. Since the plane equation can be expressed by the equation aX + bY + cZ + d = 0, it is expressed as δ = αm + βC75 + γ, and δ can be obtained by solving this plane equation. Note that the values of α, β, and γ may be those calculated by multiple regression analysis.

ステップ12では、ステップ11で求めたδと仮の真値とを加算した真値によりしきい値Tを決定する。   In step 12, the threshold value T is determined based on the true value obtained by adding δ obtained in step 11 and the provisional true value.

ステップ13では、ステップ12により求めたしきい値Tに基づいて、累積濃度分布ヒストグラム上で米粒と付着糠とを2値化判別する。例えば、しきい値Tとして濃度値121.5が算出されると、これを図6に示す累積濃度分布ヒストグラムのx軸上にプロットするとともに、y軸と平行な線を引くと、累積画素数が98.2%の点で境界ができる。つまり、米粒全体の画素数のうち、98.2%は米粒の画素数であり、1.8%は付着糠の画素数となることが分かる。   In step 13, based on the threshold value T obtained in step 12, the rice grains and the adhered wrinkles are binarized on the cumulative density distribution histogram. For example, when the density value 121.5 is calculated as the threshold value T, this is plotted on the x-axis of the cumulative density distribution histogram shown in FIG. 6 and when a line parallel to the y-axis is drawn, the cumulative pixel count A boundary is formed at a point of 98.2%. That is, it can be seen that 98.2% of the total number of pixels of rice grains is the number of pixels of rice grains, and 1.8% is the number of pixels of attached wrinkles.

A社製の無洗米を10サンプル抽出し、これに低照度の光で画像撮影したものと、A社製の無洗米を10サンプル抽出し、これに高照度の光で画像撮影したものと、精白米を10サンプル抽出し、これに普通の照度で画像撮影したものとを、背景画像を除去し、得られた濃度分布ヒストグラムについて濃度分布を累積し、濃度値を横軸にとり、累積画素数を縦軸にとり、累積濃度分布ヒストグラムを作成する(図8、図9及び図10参照)。 10 samples of non-washed rice made by A company were extracted and imaged with low illuminance light, and 10 samples of non-washed rice made by A company were extracted and imaged with high illuminance light. 10 samples of polished rice were extracted and imaged at normal illuminance, the background image was removed, the density distribution was accumulated for the obtained density distribution histogram, the density value was plotted on the horizontal axis, and the number of accumulated pixels Is a vertical axis, and a cumulative density distribution histogram is created (see FIGS. 8, 9 and 10).

このようにして得られた各累積濃度分布ヒストグラムにおいて、基準値と仮の真値との差δと、2点間を通る直線の傾きmとの相関関係を図11に示す。また、各累積濃度分布ヒストグラムにおいて、2点間を通る直線の傾きmと、累積画素数75%の濃度値C75との相関関係を図12に示す。図11及び図12に示すように、2次元ではいずれのパラメータも相関性がないことが分かるが、図7に示すように、3次元の空間であるとδとmとC75とは、互いに相関性があることが分かる。 FIG. 11 shows the correlation between the difference δ between the reference value and the provisional true value and the slope m of the straight line passing between the two points in each cumulative density distribution histogram thus obtained. Further, in each cumulative density distribution histogram, the correlation between the slope m of the straight line passing between two points and the density value C75 of the cumulative number of pixels 75% is shown in FIG. As shown in FIGS. 11 and 12, it can be seen that none of the parameters are correlated in two dimensions. However, as shown in FIG. 7, in a three-dimensional space, δ, m, and C75 are correlated with each other. You can see that there is sex.

そして、上述のステップ10からステップ11を実行してしきい値Tを算出する。このしきい値Tをキャリブレーション値(cal値)とし、あらかじめ計測したサンプルの実測値(真値)とをプロットすると、図13乃至図15のような関係が得られた。 Then, the threshold value T is calculated by executing steps 10 to 11 described above. When this threshold value T is used as a calibration value (cal value) and the measured values (true values) of samples measured in advance are plotted, the relationships shown in FIGS. 13 to 15 are obtained.

図13は無洗米を低照度の光で画像撮影したもののcal値と真値との関係を示すが、相関係数は0.907であり、本実施例で算出したcal値が真値と極めて相関が強いことが分かる。図14は無洗米を高照度の光で画像撮影したもののcal値と真値との関係を示すが、相関係数は0.995であり、本実施例で算出したcal値が真値と極めて相関が強いことが分かる。図15は精白米を普通の照度で画像撮影したもののcal値と真値との関係を示すが、相関係数は0.977であり、本実施例で算出したcal値が真値と極めて相関が強いことが分かる。 FIG. 13 shows the relationship between the cal value and the true value of a non-washed rice image photographed with light of low illuminance, but the correlation coefficient is 0.907, and the cal value calculated in this example is extremely different from the true value. It can be seen that the correlation is strong. FIG. 14 shows the relationship between the cal value and the true value of the unwashed rice imaged with high-illuminance light, but the correlation coefficient is 0.995, and the cal value calculated in this example is extremely true. It can be seen that the correlation is strong. FIG. 15 shows the relationship between the cal value and true value of an image of polished white rice taken at normal illuminance. The correlation coefficient is 0.977, and the cal value calculated in this example is highly correlated with the true value. Is strong.

米粒の外観検査装置の一例を示すブロック図である。It is a block diagram which shows an example of the external appearance inspection apparatus of a rice grain. 米粒の外観検査装置の一実施形態における処理の流れを示すフローチャートである。It is a flowchart which shows the flow of the process in one Embodiment of the external appearance inspection apparatus of a rice grain. 撮像カメラにより撮像して得られた背景画像を含む米粒の画像である。It is an image of the rice grain containing the background image obtained by imaging with an imaging camera. 背景を含む画像の濃度分布ヒストグラムである。It is a density distribution histogram of the image containing a background. 背景を含まない米粒画像の濃度分布ヒストグラムである。It is a density distribution histogram of the rice grain image which does not include a background. 濃度値と累積画素数からなる累積濃度分布ヒストグラムである。It is a cumulative density distribution histogram composed of density values and cumulative number of pixels. 空間における偏差δと、傾きmと、濃度値C75との関係を示す図である。It is a figure which shows the relationship between deviation (delta) in space, inclination m, and density | concentration value C75. A社製の無洗米を10サンプル抽出し、これに低照度の光で画像撮影し、背景画像を除去し、得られた濃度分布ヒストグラムについて濃度分布を累積し、得られた累積濃度分布ヒストグラムである。10 samples of non-washed rice made by company A are extracted, images are taken with light of low illuminance, background images are removed, the density distribution is accumulated with respect to the obtained density distribution histogram, and the obtained cumulative density distribution histogram is obtained. is there. A社製の無洗米を10サンプル抽出し、これに高照度の光で画像撮影し、背景画像を除去し、得られた濃度分布ヒストグラムについて濃度分布を累積し、得られた累積濃度分布ヒストグラムである。10 samples of non-washed rice made by company A are extracted, images are taken with light of high illuminance, background images are removed, the density distribution is accumulated with respect to the obtained density distribution histogram, and the obtained cumulative density distribution histogram is obtained. is there. 精白米を10サンプル抽出し、これに普通の照度の光で画像撮影し、背景画像を除去し、得られた濃度分布ヒストグラムについて濃度分布を累積し、得られた累積濃度分布ヒストグラムである。This is a cumulative density distribution histogram obtained by extracting 10 samples of polished rice, photographing an image with light of ordinary illuminance, removing a background image, and accumulating the density distribution for the obtained density distribution histogram. 偏差δと、2点間を通る直線の傾きmとの相関関係を示す図である。It is a figure which shows correlation with deviation (delta) and the inclination m of the straight line which passes between 2 points | pieces. 2点間を通る直線の傾きmと、累積画素数75%の濃度値C75との相関関係を示す図である。It is a figure which shows the correlation with the inclination m of the straight line which passes between 2 points | pieces, and the density value C75 of the accumulation pixel number 75%. A社製の無洗米の高照度画像撮影時のキャリブレーション値(cal値)と、あらかじめ計測したサンプルの実測値(真値)との関係を示す図である。It is a figure which shows the relationship between the calibration value (cal value) at the time of high illuminance image photography of the non-washing rice made from A company, and the measured value (true value) of the sample measured beforehand. A社製の無洗米の低照度画像撮影時のキャリブレーション値(cal値)と、あらかじめ計測したサンプルの実測値(真値)との関係を示す図である。It is a figure which shows the relationship between the calibration value (cal value) at the time of low illuminance image photography of the non-washing rice made from A company, and the measured value (true value) of the sample measured beforehand. 精白米の普通照度画像撮影時のキャリブレーション値(cal値)と、あらかじめ計測したサンプルの実測値(真値)との関係を示す図である。It is a figure which shows the relationship between the calibration value (cal value) at the time of normal illuminance image photography of polished rice, and the measured value (true value) of the sample measured beforehand.

符号の説明Explanation of symbols

1 米粒
2 光源
3 撮像カメラ
4 カメラ制御装置
5 画像処理装置
6 画像モニタ装置
DESCRIPTION OF SYMBOLS 1 Rice grain 2 Light source 3 Imaging camera 4 Camera control apparatus 5 Image processing apparatus 6 Image monitor apparatus

Claims (2)

米粒を照明する照明手段と、
該照明手段により照明された米粒を撮像カメラにより撮像し、アナログ画像信号を得る撮像手段と、
得られたアナログ画像信号を二値化処理して濃淡を表すデジタル信号に変換する画像変換手段と、
該画像変換手段により得られたデジタル画像信号の画像処理を行い、画像の濃度に関する濃度分布ヒストグラムを作成する濃度分布ヒストグラム作成手段と、
該濃度分布ヒストグラム作成手段により求められた濃度分布を累積し、累積濃度分布ヒストグラムを作成する累積濃度分布ヒストグラム作成手段と、
該累積濃度分布ヒストグラム作成手段により求められた累積濃度分布ヒストグラムから、しきい値Tを決定して米粒と付着糠とを2値化判別する2値化判別手段と、を備えた米粒の外観検査装置であって、
該2値化判別手段は、前記累積濃度分布ヒストグラム上で少なくとも2箇所の総画素数に対する適宜割合の累積画素数を求めるとともに、各累積画素数に対応する濃度値を算出する濃度値算出手段と、
該濃度値算出手段で算出された累積画素数に対応する濃度値をプロットするとともに、該プロットした2点間を通る直線の式を作成する一次関数作成手段と、
該一次関数作成手段で求めた直線の式に総画素数を代入して、そのときの濃度値を仮の真値とする仮の真値作成手段と、
該仮の真値作成手段により求めた仮の真値と、あらかじめサンプルの計測などにより設定された基準値とを比較して、その偏差を求める偏差算出手段と、
該偏差算出手段により求めた偏差と仮の真値とを加算してしきい値Tを決定するしきい値決定手段と、
を備えたことを特徴とする米粒の外観検査装置。
Lighting means for illuminating the rice grains;
Imaging means for capturing rice grains illuminated by the illumination means with an imaging camera to obtain an analog image signal;
Image conversion means for binarizing the obtained analog image signal and converting it into a digital signal representing light and shade,
A density distribution histogram creating means for performing image processing of the digital image signal obtained by the image converting means and creating a density distribution histogram relating to the density of the image;
Cumulative density distribution histogram creating means for accumulating the density distribution obtained by the density distribution histogram creating means and creating a cumulative density distribution histogram;
A rice grain appearance inspection comprising: binarization discriminating means for binarizing discriminating rice grains and attached wrinkles by determining a threshold value T from the cumulative density distribution histogram obtained by the cumulative density distribution histogram creating means A device,
The binarization determining means obtains a cumulative pixel number in an appropriate ratio with respect to the total number of pixels in at least two locations on the cumulative density distribution histogram, and calculates a density value corresponding to each cumulative pixel number; ,
Plot density values corresponding to the cumulative number of pixels calculated by the density value calculation means, and a linear function creation means for creating an equation of a straight line passing between the plotted two points;
Substituting the total number of pixels into the linear equation obtained by the linear function creating means, and a provisional true value creating means for setting the density value at that time as a provisional true value;
Deviation calculation means for comparing the provisional true value obtained by the provisional true value creation means with a reference value set in advance by measurement of a sample and for obtaining the deviation;
Threshold value determining means for determining the threshold value T by adding the deviation obtained by the deviation calculating means and the provisional true value;
An apparatus for inspecting the appearance of rice grains.
前記濃度分布ヒストグラム作成手段の後工程には、得られた濃度分布ヒストグラムから、判別分析法によるしきい値Tを決定して米粒と背景とを二値化判別し、背景のみを除去する背景除去手段を備えてなる請求項1記載の米粒の外観検査装置。 In the subsequent step of the density distribution histogram creating means, the threshold value T is determined by a discriminant analysis method from the obtained density distribution histogram to binarize and discriminate the rice grain and background, and background removal for removing only the background. The rice grain appearance inspection apparatus according to claim 1, further comprising means.
JP2003278595A 2003-07-23 2003-07-23 Visual inspection device of grain of rice Pending JP2005043260A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2003278595A JP2005043260A (en) 2003-07-23 2003-07-23 Visual inspection device of grain of rice

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2003278595A JP2005043260A (en) 2003-07-23 2003-07-23 Visual inspection device of grain of rice

Publications (1)

Publication Number Publication Date
JP2005043260A true JP2005043260A (en) 2005-02-17

Family

ID=34264956

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2003278595A Pending JP2005043260A (en) 2003-07-23 2003-07-23 Visual inspection device of grain of rice

Country Status (1)

Country Link
JP (1) JP2005043260A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105547919A (en) * 2015-12-09 2016-05-04 中国水稻研究所 Image measuring method of gel consistency of rice
WO2017169758A1 (en) * 2016-03-31 2017-10-05 株式会社サタケ Method and device for evaluating degree of grain milling

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105547919A (en) * 2015-12-09 2016-05-04 中国水稻研究所 Image measuring method of gel consistency of rice
CN105547919B (en) * 2015-12-09 2018-05-25 中国水稻研究所 The image measuring method of Rice gel consistency
WO2017169758A1 (en) * 2016-03-31 2017-10-05 株式会社サタケ Method and device for evaluating degree of grain milling
CN108885169A (en) * 2016-03-31 2018-11-23 株式会社佐竹 The fine grinding degree evaluation method and its device of cereal
JPWO2017169758A1 (en) * 2016-03-31 2019-02-07 株式会社サタケ Grain cocoon accuracy evaluation method and apparatus
CN108885169B (en) * 2016-03-31 2021-03-02 株式会社佐竹 Method and device for evaluating grain fineness

Similar Documents

Publication Publication Date Title
KR100903704B1 (en) The White and Brown Rice Appearance Characteristics Measurement System and the Same Method
JP5043755B2 (en) Resin material inspection device and program
JP4150390B2 (en) Appearance inspection method and appearance inspection apparatus
JP5298969B2 (en) Dust measuring device and generation source estimation method
JPH07231883A (en) Skin surface analyzing system, and skin surface analyzing method
JP2011180120A (en) Method and device for diagnosis of waterproof sheet
JP2005069725A (en) Particle diameter measuring device
JP2001184510A (en) Defect detecting method
KR20210018672A (en) Apparatus and method for providing predictive value for measurement of particulate matter concentration using a camera
JP2002257736A (en) Method and device for inspecting end face of honeycomb structure
JP3333568B2 (en) Surface defect inspection equipment
JP2007155405A (en) Visual inspection method and visual inspection device
JP4038210B2 (en) Particle extraction for automatic flow microscopy
JP2005218379A5 (en)
JP2005043260A (en) Visual inspection device of grain of rice
US6845178B1 (en) Automatic separation of subject pixels using segmentation based on multiple planes of measurement data
JP2001004536A (en) Method for inspecting quality of dried laver
WO2004047609A2 (en) A method and a system for establishing a quantity measure for joint destruction
JP3047168B2 (en) Inspection method of chicken eggs
JP2008014907A (en) Surface evaluation device and painting sample
JP2711649B2 (en) Surface scratch detection method for inspection object
JPH0337564A (en) Automatic magnetic-particle examination apparatus
JP2007139431A (en) Inspection method of color irregularity flaw and inspection device therefor
JP2004317431A (en) Foreign matter inspection method and device
JP6948032B2 (en) Image analyzer and inspection system