[go: up one dir, main page]

JP2005351645A - Surface-damage detecting method, detector therefor and program - Google Patents

Surface-damage detecting method, detector therefor and program Download PDF

Info

Publication number
JP2005351645A
JP2005351645A JP2004169700A JP2004169700A JP2005351645A JP 2005351645 A JP2005351645 A JP 2005351645A JP 2004169700 A JP2004169700 A JP 2004169700A JP 2004169700 A JP2004169700 A JP 2004169700A JP 2005351645 A JP2005351645 A JP 2005351645A
Authority
JP
Japan
Prior art keywords
value
image
pixel
absolute value
flaw
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
Application number
JP2004169700A
Other languages
Japanese (ja)
Inventor
Yasuhiko Kaneko
康彦 金子
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.)
Fujifilm Holdings Corp
Original Assignee
Fuji Photo Film Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Fuji Photo Film Co Ltd filed Critical Fuji Photo Film Co Ltd
Priority to JP2004169700A priority Critical patent/JP2005351645A/en
Publication of JP2005351645A publication Critical patent/JP2005351645A/en
Withdrawn legal-status Critical Current

Links

Images

Landscapes

  • Image Analysis (AREA)
  • Length Measuring Devices By Optical Means (AREA)
  • Investigating Materials By The Use Of Optical Means Adapted For Particular Applications (AREA)
  • Image Processing (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To provide a surface-damage detecting method for effectively extracting the surface damages of an object to be inspected. <P>SOLUTION: A blurred image forming means 10 is constituted so as to form a plurality of blurred images Sm (m=1-n, n≥2) that differ in the frequency response characteristics, on the basis of the original image S0, and a band-restricting image forming means 20 is constituted so as to perform subtraction of images of adjacent frequency bands, using the original image S0 and the respective blurred images Sm to form (n) band restricting images Tm. A damage component extracting means 30 applies nonlinear conversion to the respective band restricting images Tm, to obtain a plurality of converted images and to respectively add the pixel values of the pixels, corresponding to those converted images, to obtain the damage component Q of the original image S0. <P>COPYRIGHT: (C)2006,JPO&NCIPI

Description

本発明は検査対象物の表面傷の検出、具体的には検査対象物を撮像して得た対象物画像を用いて検査対象物の表面の傷を検出する表面傷検出方法および装置並びにそのためのプログラムに関するものである。   The present invention relates to a method and apparatus for detecting a surface flaw on a surface of an inspection object, specifically a surface flaw detection method and apparatus for detecting a flaw on the surface of an inspection object using an object image obtained by imaging the inspection object. It is about the program.

検査対象物の表面傷の検出は、様々な分野で必要とされている。例えば、金属切削加工製品の表面の小さな傷の検出や、自動車などの表面の細かい塗装むらの検出や、農産物例えば柑橘類の表皮損傷の検出などが行われている。また、写真画像の分野においては、顔などの部分にある小さな傷、またはいわゆる傷ではないが、顔などに部分におけるシミ、シワ成分を検出して修復することも行われている。人間の視覚による目視検査が、個人差が生じやすく、また同じ検査員であっても目の疲れ度合いなどによって検査結果に差が生じることが多いなどの理由から、検査対象物を撮像して得た対象物画像に対して画像処理を行って自動的に検査対象物の表面傷を検出する方法が提案されている。   Detection of a surface flaw on an inspection object is required in various fields. For example, detection of small scratches on the surface of metal cutting products, detection of fine paint unevenness on the surface of automobiles, detection of damage to agricultural products such as citrus fruits, and the like are performed. In the field of photographic images, it is not small scratches or so-called scratches on the face or the like, but it is also possible to detect and repair spots and wrinkle components on the face or the like. Visual inspection by human vision is easy to produce individual differences, and even for the same inspector, it can be obtained by imaging the inspection object because the inspection results often vary depending on the degree of eye fatigue. A method has been proposed in which image processing is performed on a target object image to automatically detect a surface flaw on the inspection target object.

特許文献1には、柑橘などの表皮油胞部分の損傷部分に紫外線を照射すると、損傷部分が励起発光することを利用し、柑橘などの農産物の表面に紫外線を照射し、その油胞の損傷部分を励起発光させ、この光をフィルタを通してカメラや光検出センサーで捕捉して得た対象物画像に対して画像処理を施すことによって損傷部分を検出する方法が提案されている。   Patent Document 1 uses the fact that when damaged parts of epidermis oil vesicles such as citrus are irradiated with ultraviolet light, the damaged parts are excited to emit light, and the surface of agricultural products such as citrus is irradiated with ultraviolet light to damage the oil vesicles. A method has been proposed in which a damaged part is detected by performing image processing on an object image obtained by exciting and emitting the part and capturing the light with a camera or a light detection sensor through a filter.

また、検査対象物表面の細かい傷は、対象物画像において、高周波成分における濃淡レベルの小さい信号として現れるため、ノイズ除去の技術を表面傷の検出に適用することが考得られる。例えば、ノイズ除去に従来通常用いられるローパスフィルタ(LPF)を対象物画像に適用し、細かい傷成分や、ノイズを抑制した抑制画像を得、元の対象物画像から抑制画像を減算することによって傷成分を得ることができる。しかし、LPFは、画像から傷成分などを抑制することができる一方、エッジ部分もボケさせてしまうため、元の対象物から抑制画像を減算して得た傷成分にはエッジ成分が残留してしまい、検出精度が良くないという問題がある。   Further, since a fine flaw on the surface of the inspection object appears as a signal with a small gray level in the high-frequency component in the object image, it can be considered that the noise removal technique is applied to the detection of the surface flaw. For example, a low-pass filter (LPF) that is conventionally used for noise removal is applied to an object image to obtain a fine flaw component or a suppressed image with suppressed noise, and a flaw is obtained by subtracting the suppressed image from the original object image. Ingredients can be obtained. However, the LPF can suppress the scratch component from the image, but also blurs the edge portion. Therefore, the edge component remains in the scratch component obtained by subtracting the suppression image from the original object. Therefore, there is a problem that the detection accuracy is not good.

ノイズ成分を除去すると共に、エッジ成分を劣化させないノイズ除去技術としては、ε−フィルタ(非特許文献1参照)を用いた方法を挙げることができる。ε−フィルタは、基本的に、高周波成分における振幅のレベルの変化量に対して非線形関数を適用して得た値を元の画像信号から減算するように作用するものである。この非線形関数は、信号の振幅が所定の閾値(ここでεとする)より大きいとき、出力を0とする関数である。すなわち、ε−フィルタを適用した場合、画像中の、振幅が前述閾値より大きい部位では、非線形関数の出力が0であり、処理後の画像においては、その部位の元の信号が保持される一方、振幅が前述閾値以下の部位では、処理後の画像においては、その部位の信号値が元の信号値から非線形関数の出力(その絶対値が0より大きい)を引いた値になる。このε―フィルタを表面傷の検出に適用すると、エッジ成分が傷成分として残留することを防ぎ、傷成分の検出の精度を上げることができる。
特開平06−129987号公報 原島ほか、「ε−分離非線形デジタルフィルタとその応用」電子通信学会1982.4,J65−A,No.4,pp297−304
A noise removal technique that removes the noise component and does not degrade the edge component includes a method using an ε-filter (see Non-Patent Document 1). The ε-filter basically operates so as to subtract a value obtained by applying a nonlinear function to the amount of change in amplitude level in the high frequency component from the original image signal. This nonlinear function is a function that sets the output to 0 when the amplitude of the signal is larger than a predetermined threshold (here, ε 0 ). That is, when the ε-filter is applied, the output of the non-linear function is 0 in a part of the image where the amplitude is larger than the threshold value, and the original signal of the part is retained in the processed image. In a region where the amplitude is equal to or smaller than the threshold value, in the processed image, the signal value of the region is a value obtained by subtracting the output of the nonlinear function (its absolute value is greater than 0) from the original signal value. When this ε-filter is applied to the detection of surface flaws, it is possible to prevent edge components from remaining as flaw components, and to increase the accuracy of flaw component detection.
Japanese Patent Laid-Open No. 06-129987 Harashima et al., “Ε-Separation Nonlinear Digital Filter and its Applications”, IEICE 1982, J65-A, No. 4, pp 297-304

しかしながら、特許文献1記載の方法は、検査対象物に紫外線を照射する装置や、励起発光の光を捕捉する特殊の撮像装置(カメラや光センサなど)を必要とすると共に、人間の顔など紫外線の照射を避けたい検査対象物の場合には適用することができない。   However, the method described in Patent Document 1 requires a device that irradiates an inspection object with ultraviolet light and a special imaging device (such as a camera or an optical sensor) that captures excitation light, and ultraviolet light such as a human face. It cannot be applied to an inspection object for which it is desired to avoid irradiation.

また、検査対象物表面の細かい傷成分は、高周波数帯域に多く存在するものの、高い周波数帯域から低い周波数帯域までの各々の周波数帯域に亘って存在するものである。上述したε−フィルタを利用した検出方法は、1つの周波数帯域のみにおいて傷成分を抽出しているため、傷成分を完全に検出することができないという問題がある。   Moreover, although many fine scratch components on the surface of the inspection object exist in the high frequency band, they exist over each frequency band from the high frequency band to the low frequency band. The above-described detection method using the ε-filter has a problem in that the flaw component cannot be completely detected because the flaw component is extracted only in one frequency band.

本発明は、上記事情に鑑み、特殊な装置を必要とせずに、検査対象物表面の傷成分を効果的に検出することができる方法および装置並びにそのためのプログラムを提供することを目的とするものである。   The present invention has been made in view of the above circumstances, and an object thereof is to provide a method and apparatus capable of effectively detecting a scratch component on the surface of an inspection object without requiring a special apparatus, and a program therefor. It is.

本発明の表面傷検出方法は、検査対象物を撮像して得た対象物画像に基づいて、該対象物画像の複数の周波数帯域ごとの成分を表す複数の帯域制限画像を作成し、
出力値の絶対値を入力値の絶対値以下にする処理であって、かつ絶対値が所定の閾値以下である入力値に対しては、該入力値の絶対値が大きいほど出力値の絶対値が大きくなる一方、絶対値が前記所定の閾値より大きい入力値に対しては、出力値の絶対値が前記所定の閾値に対応する出力値の絶対値以下となる非線形変換処理を各前記帯域制限画像の夫々の画素値に対して施して複数の変換画像を得、
該複数の変換画像の相対応する画素の画素値を加算して得た加算画素値を前記検査対象物の表面の傷成分を表す傷成分画像の画素の画素値として取得することを特徴とするものである。
The surface flaw detection method of the present invention creates a plurality of band limited images representing components for each of a plurality of frequency bands of the object image based on the object image obtained by imaging the inspection object,
For an input value in which the absolute value of the output value is less than or equal to the absolute value of the input value and the absolute value is less than or equal to a predetermined threshold value, the absolute value of the output value increases as the absolute value of the input value increases. On the other hand, for an input value whose absolute value is larger than the predetermined threshold value, nonlinear conversion processing in which the absolute value of the output value is equal to or smaller than the absolute value of the output value corresponding to the predetermined threshold value is performed for each band limitation. Apply to each pixel value of the image to get multiple converted images,
An added pixel value obtained by adding pixel values of corresponding pixels of the plurality of converted images is acquired as a pixel value of a flaw component image pixel representing a flaw component on the surface of the inspection object. Is.

ここで、「対象物画像」とは、デジタルカメラなどで被写体を撮像した得たデジタル画像は勿論、スキャナなどの読取装置で銀塩写真フィルムや、印刷物(例えばプリント)などにある画像を読み取って得たデジタル画像も含むものである。以下、説明上の便宜のため、単に画像というものも、本発明における対象物画像を意味するものとする。   Here, the “object image” means not only a digital image obtained by imaging a subject with a digital camera, but also an image on a silver halide photographic film or a printed material (for example, a print) by a reading device such as a scanner. The obtained digital image is also included. Hereinafter, for convenience of explanation, an image simply means an object image in the present invention.

また、「複数の変換画像の相対応する画素の画素値を加算して得た加算画素値を前記検査対象物の表面の傷成分画像の画素の画素値として取得すること」とは、結果的に前記加算画素値を前記傷成分画像の画素の画素値として取得することを意味し、前記加算画素値としては、前記複数の変換画像の相対応する画素の画素値を直接加算して得るようにしてもよいし、例えば前記対象物画像の前記傷成分を除去した画像(補修済画像とする)を取得する工程を有するシステムにおいて、対象物画像の画素の画素値から、前記複数の変換画像の対応する画素の画素値を減算することによって得られた補修済み画像の画素の画素値を、対象物画像の画素の画素値から減算することによって得るようにしても勿論よい。   In addition, “acquiring an added pixel value obtained by adding pixel values of corresponding pixels of a plurality of converted images as a pixel value of a flaw component image on the surface of the inspection object” as a result Means to obtain the added pixel value as a pixel value of a pixel of the flaw component image, and the added pixel value is obtained by directly adding pixel values of corresponding pixels of the plurality of converted images. Alternatively, for example, in a system having a step of obtaining an image (repaired image) obtained by removing the scratch component from the object image, the plurality of converted images are obtained from pixel values of pixels of the object image. Of course, the pixel value of the pixel of the repaired image obtained by subtracting the pixel value of the corresponding pixel may be obtained by subtracting the pixel value of the pixel of the object image.

また、本発明の表面傷検出方法は、前記対象物画像の画素の画素値に応じて決められた係数を該画素に対応する前記加算画素値に乗算して得た値を前記傷成分画像の画素の画素値として取得することが好ましく、前記係数の具体的な決め方は、検出する対象物の種類、傷成分の検出程度などに基づいた方法を用いればよい。   In the surface flaw detection method of the present invention, a value obtained by multiplying the addition pixel value corresponding to the pixel by a coefficient determined according to the pixel value of the pixel of the object image is used as the value of the flaw component image. It is preferable to obtain the pixel value of the pixel, and a specific method of determining the coefficient may be a method based on the type of the object to be detected, the degree of detection of the scratch component, and the like.

例えば、画像中の傷成分は、通常、画像中の暗い部分(すなわち輝度値などの画素値が小さい部分)として現れることが多いため、対象物画像の画素値が大きいほど小さい(逆に画像値が小さいほど大きい)係数を用いるようにすれば、エッジ成分を傷成分として検出されることを防ぐことができると共に、より多くの傷成分を検出することができる。   For example, since a flaw component in an image usually appears as a dark portion in an image (that is, a portion with a small pixel value such as a luminance value), the smaller the pixel value of the object image, the smaller the image value (in contrast, the image value). If a coefficient is used as it is smaller, the edge component can be prevented from being detected as a flaw component, and more flaw components can be detected.

また、本発明において、通常意味でのシワ、シミなどの成分も、顔などの肌表面の傷成分として捉え、本発明の表面傷検出方法を顔写真画像などにおけるシワ、シミ成分の検出に適用することができる。写真画像において、シワ、シミ成分は、髪の毛などより明るい肌部分に存在するので、前記係数として、画素値、例えば輝度値が大きいほど大きい(逆に画素値が小さいほど小さい)ものを用いるようにすると、シワ、シミ成分を検出することができると共に、毛髪などをシワ、シミ成分として誤検出してしまうことを防ぐことができる。   Also, in the present invention, components such as wrinkles and spots in the normal sense are also regarded as scratch components on the surface of the skin such as the face, and the surface scratch detection method of the present invention is applied to detection of wrinkles and stain components in facial photographic images and the like. can do. In a photographic image, wrinkles and stain components are present in lighter skin parts such as hair, so that the larger the pixel value, for example, the luminance value (or the smaller the pixel value, the smaller) is used as the coefficient. Then, it is possible to detect wrinkles and stain components, and to prevent erroneous detection of hair and the like as wrinkles and stain components.

また、前記非線形変換処理は、絶対値が前記所定の閾値より大きい入力値に対して、出力値の絶対値がほぼ一定となる処理であることが好ましい。ここで、前記所定の閾値より大きい入力値は、傷成分ではない部位の信号値であると考えることができ、その出力値がほぼ一定となるように前記非線形変換処理を行うようにすると、演算時間を節約することができ、効率良く傷成分の抽出を行うことができる。また、絶対値が前記所定の閾値より大きい入力値の出力値の絶対値はゼロから最大出力値(前記閾値に対応する出力値)までの範囲内の値となり、大きいほど多くの傷成分を抽出することができ、小さいほどエッジ成分の残留を防ぐことができる。   The nonlinear conversion process is preferably a process in which the absolute value of the output value is substantially constant with respect to an input value whose absolute value is greater than the predetermined threshold. Here, an input value larger than the predetermined threshold value can be considered as a signal value of a part that is not a flaw component, and if the nonlinear transformation process is performed so that the output value is substantially constant, the calculation is performed. Time can be saved and scratch components can be extracted efficiently. The absolute value of the output value of the input value whose absolute value is larger than the predetermined threshold value is a value within the range from zero to the maximum output value (output value corresponding to the threshold value), and the larger the value, the more flaw components are extracted. The smaller the value, the more the edge component can be prevented from remaining.

また、前記所定の閾値は、傷成分とエッジ成分とを区別するための閾値の性質を有し、各前記帯域制限画像に対して同じ値を用いてもよいが、処理する前記帯域制限画像の周波数帯域に応じて決められたものであることが好ましい。   Further, the predetermined threshold has a property of a threshold for distinguishing a flaw component from an edge component, and the same value may be used for each of the band limited images. It is preferable that it is determined according to the frequency band.

本発明の表面傷検出方法により得られた傷成分画像の画素の画素値が前記傷成分画像を表すものであり、この傷成分画像には、傷成分以外に、CCDなどの撮像素子に起因するノイズなどが含まれているため、本発明の表面傷成分検出方法としては、前記傷成分画像に対してメディアンフィルタなどの平滑化フィルタをさらに適用することが望ましく、こうすることによって最終的に得られた傷成分画像は、傷成分以外のノイズ成分が除去されたものとなる。   The pixel value of the pixel of the flaw component image obtained by the surface flaw detection method of the present invention represents the flaw component image. In addition to the flaw component, the flaw component image is caused by an image sensor such as a CCD. Since noise and the like are included, it is desirable to further apply a smoothing filter such as a median filter to the flaw component image as the surface flaw component detection method of the present invention. The obtained flaw component image is obtained by removing noise components other than the flaw component.

本発明の表面傷検出装置は、検査対象物を撮像して得た対象物画像に基づいて、該対象物画像の複数の周波数帯域ごとの成分を表す複数の帯域制限画像を作成する帯域制限画像作成手段と、
出力値の絶対値を入力値の絶対値以下にする処理であって、かつ絶対値が所定の閾値以下である入力値に対しては、該入力値の絶対値が大きいほど出力値の絶対値が大きくなる一方、絶対値が前記所定の閾値より大きい入力値に対しては、出力値の絶対値が前記所定の閾値に対応する出力値の絶対値以下となる非線形変換処理を各前記帯域制限画像の夫々の画素値に対して施して複数の変換画像を得る非線形変換手段と、
該複数の変換画像の相対応する画素の画素値を加算して得た加算画素値を前記検査対象物の表面の傷成分を表す傷成分画像の画素の画素値として取得する傷成分取得手段とを有してなることを特徴とするものである。
The surface flaw detection apparatus of the present invention creates a band limited image that creates a plurality of band limited images representing components for a plurality of frequency bands of an object image based on the object image obtained by imaging the inspection object. Creating means;
For an input value in which the absolute value of the output value is less than or equal to the absolute value of the input value and the absolute value is less than or equal to a predetermined threshold value, the absolute value of the output value increases as the absolute value of the input value increases. On the other hand, for an input value whose absolute value is larger than the predetermined threshold value, nonlinear conversion processing in which the absolute value of the output value is equal to or smaller than the absolute value of the output value corresponding to the predetermined threshold value is performed for each band limitation. Non-linear conversion means for applying to each pixel value of the image to obtain a plurality of converted images;
Flaw component acquisition means for acquiring an added pixel value obtained by adding pixel values of corresponding pixels of the plurality of converted images as a pixel value of a flaw component image pixel representing a flaw component on the surface of the inspection object; It is characterized by having.

前記傷成分取得手段は、前記対象物画像の画素の画素値に応じて決められた係数を該画素に対応する前記加算画素値に乗算して得た値を前記傷成分画像の画素の画素値として取得するものであることが好ましい。   The flaw component acquisition means obtains a pixel value of a pixel of the flaw component image by multiplying the addition pixel value corresponding to the pixel by a coefficient determined according to a pixel value of the pixel of the object image. It is preferable to acquire as.

本発明のプログラムは、本発明の表面傷検出方法をコンピュータに実行させるものである。   The program of the present invention causes a computer to execute the surface flaw detection method of the present invention.

本発明の表面傷検出方法および装置並びにそのためのプログラムは、対象物画像に基づいて作成されたこの画像の複数の異なる周波数帯域ごとの成分を表す複数の帯域制限画像に対して非線形変換処理を施して複数の変換画像を得る。この非線形変換処理は、出力値の絶対値を入力値の絶対値以下にする処理であって、かつ絶対値が所定の閾値以下の入力値に対しては、入力値の絶対値が大きいほど出力値の絶対値が大きくなる一方、絶対値が所定の閾値より大きい入力値に対しては、出力値の絶対値がこの所定の閾値に対応する出力値の絶対値以下となる処理である。この非線形変換処理により得られた変換画像が、当該変換画像が対応する周波数帯域における傷乃至ノイズなどの振幅の小さい成分を表すものである。本発明は、この複数の変換画像の相対応する画素の画素値を加算して得た加算画素値を検査対象物の傷成分画像の画素値として取得するようにしているので、対象物画像から複数の周波数帯域における傷成分を効果的に検出することができる。   The surface flaw detection method and apparatus of the present invention and the program therefor perform non-linear transformation processing on a plurality of band limited images representing components of a plurality of different frequency bands of the image created based on the object image. To obtain a plurality of converted images. This non-linear conversion process is a process for setting the absolute value of the output value to be equal to or smaller than the absolute value of the input value. While the absolute value of the value is increased, for an input value whose absolute value is greater than a predetermined threshold, the absolute value of the output value is equal to or less than the absolute value of the output value corresponding to the predetermined threshold. The converted image obtained by this nonlinear conversion processing represents a component having a small amplitude such as a flaw or noise in the frequency band corresponding to the converted image. In the present invention, since the added pixel value obtained by adding the pixel values of the corresponding pixels of the plurality of converted images is acquired as the pixel value of the flaw component image of the inspection object, Scratch components in a plurality of frequency bands can be detected effectively.

また、紫外線の照射や、特殊な撮像装置を必要とせず、あらゆる種類の検査対象物に適用することができる。   Further, it can be applied to all types of inspection objects without requiring ultraviolet irradiation or a special imaging device.

以下、図面を参照して、本発明の実施形態について説明する。   Embodiments of the present invention will be described below with reference to the drawings.

図1は、本発明の実施形態となる画像処理装置の構成を示すブロック図である。なお、本実施形態の画像処理装置は、入力された検査物画像から傷成分を抽出する処理を行うものであり、補助記憶装置に読み込まれた処理プログラムをコンピュータ(たとえばパーソナルコンピュータ等)上で実行することにより実現される。また、この処理プログラムは、CD−ROM等の情報記憶媒体に記憶され、もしくはインターネット等のネットワークを介して配布され、コンピュータにインストールされることになる。   FIG. 1 is a block diagram showing a configuration of an image processing apparatus according to an embodiment of the present invention. Note that the image processing apparatus according to the present embodiment performs a process of extracting a flaw component from an input inspection object image, and executes a processing program read into an auxiliary storage device on a computer (for example, a personal computer). It is realized by doing. Further, this processing program is stored in an information storage medium such as a CD-ROM or distributed via a network such as the Internet and installed in a computer.

また、画像データは画像を表すものであるため、以下、特に画像と画像データの区別をせずに説明を行う。   Further, since the image data represents an image, the following description will be given without particularly distinguishing the image from the image data.

図1に示すように、本実施形態の画像処理装置は、原画像S0の互いに周波数応答特性が異なる複数のボケ画像S1、S2、・・・Sn(n:2以上の整数)を作成するボケ画像作成手段10と、原画像S0およびボケ画像S1、S2、・・・Snを用いて複数の帯域制限画像T1、T2、・・・Tnを作成する帯域制限画像作成手段20と、帯域制限画像T1、T2、・・・Tnを用いて傷成分Qを抽出する傷成分抽出手段30と、原画像S0から傷成分Qを除去して傷補修済み画像S´0(Y1)を得る傷補修手段40と、傷成分Qに対して平滑化処理を行ってノイズ除去された傷成分Q’を得る平滑化手段50と、傷成分Q’を出力する出力手段60とを有し、これらの手段が輝度空間において処理を行うものであり、本実施形態の画像処理装置は、入力された画像D0(R0,G0,B0)に対してYCC変換を行って画像D0の輝度Y0(これらの輝度成分Y0により前述した原画像S0が構成される)、色差Cb0、Cr0を得るYCC変換手段1と、傷補修手段40により得られた傷補修済み画像S´0の画素値Y1、およびYCC変換手段1により得られた色差Cb0、Cr0とを合成して処理済み画像D1(Y1,Cb0,Cr0)を得る合成手段44と、処理済み画像D1を表示する表示手段48とも備える。以下、本実施形態の各構成の詳細について説明する。   As shown in FIG. 1, the image processing apparatus according to the present embodiment creates a plurality of blurred images S1, S2,... Sn (n: integer greater than or equal to 2) with different frequency response characteristics of the original image S0. Image creating means 10, band limited image creating means 20 for creating a plurality of band limited images T1, T2,... Tn using original image S0 and blurred images S1, S2,. The wound component extraction means 30 for extracting the wound component Q using T1, T2,... Tn, and the wound repair means for removing the wound component Q from the original image S0 to obtain the wound repaired image S′0 (Y1) 40, a smoothing means 50 for performing a smoothing process on the scratch component Q to obtain a scratch component Q ′ from which noise has been removed, and an output means 60 for outputting the scratch component Q ′. The processing is performed in the luminance space. The processing device performs YCC conversion on the input image D0 (R0, G0, B0) to obtain the luminance Y0 of the image D0 (the original image S0 is composed of the luminance component Y0), the color difference Cb0, The YCC conversion means 1 for obtaining Cr0, the pixel value Y1 of the wound repaired image S′0 obtained by the wound repair means 40, and the color differences Cb0 and Cr0 obtained by the YCC conversion means 1 are combined and processed. A synthesizing unit 44 for obtaining D1 (Y1, Cb0, Cr0) and a display unit 48 for displaying the processed image D1 are also provided. Hereinafter, details of each component of the present embodiment will be described.

YCC変換手段1は、下記の式(1)に従って、画像データD0のR、G、B値を輝度値Y、色差値Cb、Crに変換する。   The YCC conversion unit 1 converts the R, G, and B values of the image data D0 into the luminance value Y and the color difference values Cb and Cr according to the following equation (1).


Y=0.2990×R+0.5870×G+0.1140×B
Cb=−0.1687×R−0.3313×G+0.5000×B+128 (1)
Cr=0.5000×R−0.4187×G−0.0813×B+128

ボケ画像作成手段10は、YCC変換手段1により得られた輝度値Y0を用いて、複数のボケ画像を作成する。図2は、ボケ画像作成手段10の構成を示すブロック図である。図示のように、ボケ画像作成手段10は、フィルタリング処理を行ってフィルタリング画像B1、B2、・・・Bnを得るフィルタリング手段12と、各フィルタリング画像に対して補間処理を行う補間手段14と、フィルタリング手段12および補間手段14を制御する制御手段16とを有してなるものである。フィルタリング手段12は、ローパスフィルタを用いてフィルタリング処理を行うものであり、このローパスフィルタとしては、例えば図3に示すような5×1のグリッド状の1次元ガウス分布に略対応したフィルタFを用いることができる。このフィルタFは下記の式(2)において、σ=1としたものである。

Figure 2005351645

Y = 0.2990 × R + 0.5870 × G + 0.1140 × B
Cb = −0.1687 × R−0.3313 × G + 0.5000 × B + 128 (1)
Cr = 0.5000 × R−0.4187 × G−0.0813 × B + 128

The blur image creating unit 10 creates a plurality of blur images using the luminance value Y0 obtained by the YCC conversion unit 1. FIG. 2 is a block diagram illustrating a configuration of the blurred image creation unit 10. As shown in the figure, the blurred image creation means 10 includes a filtering means 12 that performs filtering processing to obtain filtered images B1, B2,... Bn, an interpolation means 14 that performs interpolation processing on each filtering image, and filtering. The control means 16 which controls the means 12 and the interpolation means 14 is provided. The filtering means 12 performs a filtering process using a low-pass filter. As the low-pass filter, for example, a filter F substantially corresponding to a 5 × 1 grid-shaped one-dimensional Gaussian distribution as shown in FIG. 3 is used. be able to. This filter F has σ = 1 in the following equation (2).

Figure 2005351645


フィルタリング手段12は、このようなフィルタFを用いて処理対象となる画像に対して画素のx方向およびy方向に対してフィルタリング処理を施すことにより処理対象の画像の全体のフィルタリング処理を行う。

The filtering unit 12 performs a filtering process on the entire image to be processed by performing a filtering process on the image to be processed in the x direction and the y direction of the pixel using such a filter F.

図4は、ボケ画像作成手段10の制御手段16が、フィルタリング手段12と補間手段14に行わせる処理の詳細を示している。図示のように、フィルタリング手段12は、まず、原画像S0(Y0)に対して、図3に示すフィルタFを用いて1画素おきにフィルタリング処理を行う。このフィルタリング処理によってフィルタリング画像B1(Y1)が得られる。フィルタリング画像B1のサイズは、原画像S0のサイズの1/4(x方向、y方向に夫々1/2)となっている。次いで、フィルタリング手段12は、フィルタリング画像B1(Y1)に対しても1画素おきにフィルタFによるフィルタリング処理を施し、フィルタリング画像B2(Y2)を得る。フィルタリング手段12は、このようなフィルタFによるフィルタリング処理を繰り返し、n個のフィルタリング画像Bk(k=1〜n)を得る。フィルタリング画像Bkのサイズは、原画像S0のサイズの1/22Kとなっている。図5は、例としてn=3としたときに、フィルタリング手段12により得られた各フィルタリング画像Bkの周波数特性を示している。図示のように、フィルタリング画像Bkのレスポンスはkが大きいほど高周波成分が除去されたものとなっている。 FIG. 4 shows details of processing that the control unit 16 of the blurred image creation unit 10 causes the filtering unit 12 and the interpolation unit 14 to perform. As shown in the figure, the filtering unit 12 first performs a filtering process on the original image S0 (Y0) every other pixel using the filter F shown in FIG. A filtering image B1 (Y1) is obtained by this filtering process. The size of the filtering image B1 is 1/4 of the size of the original image S0 (1/2 in the x direction and y direction, respectively). Next, the filtering unit 12 performs the filtering process by the filter F every other pixel on the filtering image B1 (Y1) to obtain the filtering image B2 (Y2). The filtering means 12 repeats the filtering process by such a filter F, and obtains n filtered images Bk (k = 1 to n). The size of the filtering image Bk has become a 1/2 2K of the size of the original image S0. FIG. 5 shows frequency characteristics of each filtered image Bk obtained by the filtering unit 12 when n = 3 as an example. As shown in the figure, the response of the filtered image Bk is such that the higher the k, the higher the frequency component is removed.

なお、本実施形態の画像処理装置において、フィルタリング手段12は、図3に示すフィルタFにより画像のx方向およびy方向に対してフィルタリング処理を施すようにしているが、図6に示すような5×5の2次元フィルタにより原画像S0およびフィルタリング画像Bkに対して一度にフィルタリング処理を施すようにしてもよい。   In the image processing apparatus according to the present embodiment, the filtering unit 12 performs the filtering process on the x direction and the y direction of the image by the filter F shown in FIG. A filtering process may be performed on the original image S0 and the filtered image Bk at a time using a × 5 two-dimensional filter.

補間手段14は、フィルタリング手段12により得られた各フィルタリング画像Bkに対して補間処理を行って、夫々のフィルタリング画像Bkのサイズを原画像S0と同じようにする。補間処理の方法は、Bスプラインによる方法など種々挙げられるが、本実施形態においては、フィルタリング手段12は、ローパスフィルタとしてガウス信号に基づくフィルタFを用いているため、補間手段14は、補間処理の補間演算を行うための補間係数としてもガウス信号を用いるものであり、この補間係数は、下記の式(3)において、σ=2K−1と近似したものである。

Figure 2005351645
The interpolation unit 14 performs an interpolation process on each filtering image Bk obtained by the filtering unit 12 so that the size of each filtering image Bk is the same as that of the original image S0. There are various interpolation processing methods such as a B-spline method. In this embodiment, the filtering unit 12 uses a filter F based on a Gaussian signal as a low-pass filter. A Gaussian signal is also used as an interpolation coefficient for performing the interpolation calculation, and this interpolation coefficient is approximated to σ = 2 K−1 in the following equation (3).

Figure 2005351645


フィルタリング画像B1を補間する際に、k=1であるため、σ=1となる。上記式(3)においてσ=1としたときの補間を行うためのフィルタは、図7に示すような5×1の1次元フィルタF1となる。補間手段14は、まず、フィルタリング画像B1に対して1画素おきに値が0の画素を1ずつ補間することによりフィルタリング画像B1を原画像S0と同じサイズに拡大し、次いで拡大された画像に対して図7に示すフィルタF1によりフィルタリング処理を施してボケ画像S1を得る。このボケ画像S1は、原画像S0と同じ画素数、すなわち原画像S0と同じサイズを有する。

When interpolating the filtered image B1, since k = 1, σ = 1. The filter for performing interpolation when σ = 1 in the above equation (3) is a 5 × 1 one-dimensional filter F1 as shown in FIG. The interpolating means 14 first enlarges the filtered image B1 to the same size as the original image S0 by interpolating pixels with a value of 0 every other pixel one by one with respect to the filtered image B1, and then for the enlarged image Then, a filtering process is performed by the filter F1 shown in FIG. 7 to obtain a blurred image S1. The blurred image S1 has the same number of pixels as the original image S0, that is, the same size as the original image S0.

ここで、図7に示すフィルタF1は5×1のフィルタであるが、フィルタF1を適用する前にフィルタリング画像B1に対して1画素おきに値が0である画素を補間しているので、補間手段14による補間処理は、実質的には2×1のフィルタ(0.5,0.5)および3×1のフィルタ(0.1,0.8,0.1)の2種類のフィルタによるフィルタ処理と等価である。   Here, the filter F1 shown in FIG. 7 is a 5 × 1 filter. However, before applying the filter F1, pixels having a value of 0 are interpolated with respect to the filtered image B1 every other pixel. The interpolation processing by the means 14 is substantially performed by two types of filters: a 2 × 1 filter (0.5, 0.5) and a 3 × 1 filter (0.1, 0.8, 0.1). Equivalent to filtering.

補間手段14は、フィルタリング画像B2に対して補間を行う際に、k=2であるため、σ=2である。上記の式(3)において、σ=2に対応するフィルタは、図8に示す11×1の1次元フィルタF2となる。補間手段14は、まず、フィルタリング画像B2に対して1画素おきに値が0である画素を3つずつ補間することによりフィルタリング画像B2を原画像S0と同じサイズに拡大し、次いで拡大された画像に対して図8に示すフィルタF2によりフィルタリング処理を施してボケ画像S2を得る。ボケ画像S2は、原画像S0と同じ画素数、すなわち原画像S0と同じサイズを有する。   When the interpolation means 14 performs interpolation on the filtered image B2, k = 2, so σ = 2. In the above equation (3), the filter corresponding to σ = 2 is an 11 × 1 one-dimensional filter F2 shown in FIG. The interpolation unit 14 first expands the filtering image B2 to the same size as the original image S0 by interpolating three pixels each having a value of 0 every other pixel with respect to the filtering image B2, and then expanding the image Is subjected to a filtering process by a filter F2 shown in FIG. 8 to obtain a blurred image S2. The blurred image S2 has the same number of pixels as the original image S0, that is, the same size as the original image S0.

同じように、図8に示すフィルタF2は11×1のフィルタであるが、フィルタF2を適用する前にフィルタリング画像B2に対して1画素おきに値が0である画素を3つずつ補間しているので、補間手段14による補間処理は、実質的には2×1のフィルタ(0.5,0.5)および3×1のフィルタ(0.3,0.65,0.05)、(0.3,0.74,0.13)、(0.05,0.65,0.3)の4種類のフィルタによるフィルタ処理と等価である。   Similarly, the filter F2 shown in FIG. 8 is an 11 × 1 filter, but before applying the filter F2, three pixels each having a value of 0 are interpolated with respect to the filtered image B2 by three. Therefore, the interpolation processing by the interpolation means 14 is substantially performed by a 2 × 1 filter (0.5, 0.5) and a 3 × 1 filter (0.3, 0.65, 0.05), ( This is equivalent to filter processing using four types of filters (0.3, 0.74, 0.13) and (0.05, 0.65, 0.3).

補間手段14は、このように各フィルタリング画像Bkに対して夫々、1画素おきに値が0である画素を(2−1)個ずつ補間することにより、フィルタリング画像Bkを原画像S0と同じサイズに拡大し、そして値が0である画素が補間されたフィルタリング画像Bkに対して、上記の式(3)に基づいて作成された長さが(3×2−1)であるフィルタによるフィルタリング処理を施してボケ画像Skを得る。 In this way, the interpolation means 14 interpolates (2 K −1) pixels each having a value of 0 every other pixel with respect to each filtering image Bk, so that the filtering image Bk is the same as the original image S0. For a filtered image Bk that is enlarged to size and interpolated with pixels having a value of 0, the length created based on the above equation (3) is (3 × 2 K −1). A blurred image Sk is obtained by performing a filtering process.

図9は、例としてn=3としたときに、ボケ画像作成手段10により得られた各ボケ画像Skの周波数特性を示している。図示のように、ボケ画像Skは、kが大きいほど、原画像S0の高周波成分が除去されたものとなっている。   FIG. 9 shows the frequency characteristics of each blurred image Sk obtained by the blurred image creating means 10 when n = 3 as an example. As shown in the figure, the blurred image Sk is such that the higher the k, the higher frequency components of the original image S0 are removed.

帯域制限画像作成手段20は、ボケ画像作成手段10により得られた各ボケ画像S1,S2,・・・Snを用いて、下記の式(4)に従って原画像S0の複数の周波数帯域毎の成分を表す帯域制限画像T1,T2,・・・Tnを作成する。   The band-limited image creating means 20 uses the blurred images S1, S2,... Sn obtained by the blurred image creating means 10 and components for each of a plurality of frequency bands of the original image S0 according to the following equation (4). .., Tn are generated.


Tm=S(m−1)−Sm (4)
但し,m:1以上n以下の整数

図10は、例としてn=3としたときに、帯域制限画像作成手段20により得られた各帯域制限画像Tmの周波数特性を示している。図示のように、帯域制限画像Tmは、mが大きいほど、原画像S0の低周波数領域における成分を表すものとなっている。

Tm = S (m−1) −Sm (4)
Where m is an integer between 1 and n

FIG. 10 shows the frequency characteristics of each band limited image Tm obtained by the band limited image creating means 20 when n = 3 as an example. As illustrated, the band limited image Tm represents a component in the low frequency region of the original image S0 as m increases.

傷成分抽出手段30は、帯域制限画像作成手段20により得られた各帯域制限画像Tm(m=1〜n)を用いて、傷成分Qを抽出するものであり、図11に示すように、各帯域制限画像Tm(m=1〜n)に対して非線形変換を行って夫々の帯域制限画像Tmの変換画像、すなわち夫々の帯域制限画像Tmが対応する周波数帯域における傷乃至ノイズ成分(以下総して傷成分という)Q1,Q2,・・・,Qnを得る非線形変換手段32と、各周波数帯域の傷成分Q1,Q2,・・・Qnを加算して原画像S0における傷成分Qを得るものである。非線形変換手段32により行われる非線形変換は、出力値を入力値以下にする処理であって、かつ所定の閾値以下の入力値に対しては、該入力値が大きいほど出力値が大きくなる一方、前記所定の閾値より大きい入力値に対しては、出力値が前記所定の閾値に対応する出力値以下となる処理であって、本実施形態においては、図12に示すような関数fにより行われるものである。なお、図中破線は、出力値=入力値、すなわち傾きが1となる関数を示すものである。図示のように、本実施形態の傷成分抽出手段30における非線形変換手段32に用いられる非線形変換の関数fは、入力値の絶対値が第1の閾値Th1より小さいときは傾きが1であり、入力値の絶対値が第1の閾値以上かつ第2の閾値Th2以下であるときは傾きが1より小さくなり、入力値の絶対値が第2の閾値Th2より大きいときは、出力値がその絶対値が入力値の絶対値より小さい一定の値Mとなる関数である。なお、この関数fは、各帯域制限画像に対して同じものであってもよいが、各帯域制限画像に対して異なるものであってもよい。   The wound component extraction means 30 extracts the wound component Q using each band limited image Tm (m = 1 to n) obtained by the band limited image creation means 20, and as shown in FIG. Non-linear transformation is performed on each band limited image Tm (m = 1 to n), and a converted image of each band limited image Tm, that is, a flaw or noise component (hereinafter referred to as total) in a frequency band corresponding to each band limited image Tm. .., Qn and the flaw components Q1, Q2,... Qn in each frequency band are added to obtain the flaw component Q in the original image S0. Is. The non-linear conversion performed by the non-linear conversion means 32 is a process of setting the output value to be equal to or lower than the input value, and for an input value equal to or lower than a predetermined threshold value, the larger the input value, the larger the output value. For an input value larger than the predetermined threshold, the output value is equal to or lower than the output value corresponding to the predetermined threshold. In this embodiment, the process is performed by a function f as shown in FIG. Is. In the figure, the broken line indicates a function in which the output value = the input value, that is, the slope is 1. As illustrated, the nonlinear transformation function f used for the nonlinear transformation means 32 in the flaw component extraction means 30 of the present embodiment has a slope of 1 when the absolute value of the input value is smaller than the first threshold Th1, When the absolute value of the input value is greater than or equal to the first threshold value and less than or equal to the second threshold value Th2, the slope is smaller than 1. When the absolute value of the input value is greater than the second threshold value Th2, the output value is its absolute value. It is a function whose value is a constant value M smaller than the absolute value of the input value. The function f may be the same for each band limited image, but may be different for each band limited image.

非線形変換手段32は、各帯域制限画像の輝度値を入力値とし、図12に示す非線形変換の関数fを用いて各帯域制限画像に対して非線形変換を行って、出力値の輝度値により構成された、各帯域制限画像が対応する周波数帯域における傷成分Qm(m=1〜n)を取得する。   The nonlinear conversion means 32 uses the luminance value of each band limited image as an input value, performs nonlinear conversion on each band limited image using the nonlinear conversion function f shown in FIG. The scratch component Qm (m = 1 to n) in the frequency band to which each band limited image corresponds is acquired.

加算手段34は、下記の式(5)に従って非線形変換手段32により得られた各周波数帯域における傷成分Qm(m=1〜n)を加算して原画像S0の傷成分Qを得る。

Figure 2005351645
The adding means 34 adds the flaw component Qm (m = 1 to n) in each frequency band obtained by the nonlinear conversion means 32 according to the following equation (5) to obtain the flaw component Q of the original image S0.

Figure 2005351645


ここで、係数βは、β(S0)であり、すなわち、原画像S0の画素の輝度値Y0に応じて決められたものである。この係数βは、傷成分を検出しようとする程度、検出対象物の種類などに基づいて、画素値、ここでは輝度値Y0に応じて決められる。例えば、輝度値Y0が大きい画素ほど値が小さい係数βを用いるようにすることによって、傷成分を効果的に検出することができる。また、検査対象物が人物の顔である場合、輝度値が大きい画素ほど、値が大きい係数βを用いるようにすることによって、髪の毛の部分を傷成分として検出することを防ぐことができる。

Here, the coefficient β is β (S0), that is, determined according to the luminance value Y0 of the pixel of the original image S0. This coefficient β is determined according to the pixel value, here the luminance value Y0, based on the degree to detect the flaw component, the type of detection object, and the like. For example, a flaw component can be effectively detected by using a coefficient β having a smaller value for a pixel having a larger luminance value Y0. Further, when the inspection target is a human face, it is possible to prevent a hair part from being detected as a scratch component by using a coefficient β having a larger value for a pixel having a larger luminance value.

平滑化手段50は、傷成分抽出手段30により得られた傷成分Qに対して、例えば積分フィルタや、メディアフィルタなどの平滑化フィルタを適用して平滑化することによってノイズが除去された傷成分Q’を得る。   The smoothing unit 50 applies a smoothing filter such as an integration filter or a media filter to the scratch component Q obtained by the scratch component extraction unit 30 to smooth the scratch component from which noise has been removed. Get Q '.

出力手段60は、傷成分Q’を出力する(データのままの出力や、画像としての表示などを含む)ものである。ここで、出力手段60は、傷成分Q’をそのまま出力するものであってもよいし、抽出された傷成分の用途に基づいて例えば傷成分Q’において、画素値(ここでは輝度値)が0ではない画素の位置を傷の位置として求めて出力したりするなどの処理を行って出力するものであってもよい。   The output means 60 outputs the scratch component Q ′ (including output as data and display as an image). Here, the output means 60 may output the scratch component Q ′ as it is, or the pixel value (in this case, the luminance value) of the scratch component Q ′, for example, based on the use of the extracted scratch component. The output may be performed by performing processing such as obtaining and outputting the position of a pixel other than 0 as the position of a flaw.

傷補修手段40は、傷成分抽出手段30により抽出された傷成分Qを、原画像S0(Y0)から減算して傷補修済み画像S´0(Y1)を得る。   The wound repair means 40 subtracts the wound component Q extracted by the wound component extraction means 30 from the original image S0 (Y0) to obtain a wound repaired image S′0 (Y1).

合成手段44は、傷補修手段40により得られた輝度値Y1と、YCC変換手段1により得られた画像D0の色差値Cb0、Cr0とを合成して処理済み画像D1(Y1,Cr0,Cb0)を得る。   The synthesizing unit 44 synthesizes the luminance value Y1 obtained by the flaw repairing unit 40 and the color difference values Cb0 and Cr0 of the image D0 obtained by the YCC conversion unit 1 to process the processed image D1 (Y1, Cr0, Cb0). Get.

表示手段48は、傷成分を除去して得られた処理済み画像D1を表示して操作者に確認させるものであり、例えばモニタなどを用いることができる。   The display means 48 displays the processed image D1 obtained by removing the scratch component and allows the operator to confirm the display. For example, a monitor or the like can be used.

このように、本実施形態の画像処理装置は、原画像S0(Y0)の複数の異なる周波数帯域ごとの成分を表す複数の帯域制限画像Tm(m=1〜n,n≧2)を作成し、これらの帯域制限画像に対して非線形変換処理を施して複数の変換画像(傷成分)を得る。そして、これらの複数の変換画像の画素値に対して、原画像S0の輝度値に応じて決められた係数βを乗算して加算して原画像S0の傷成分を得るようにすることによって、複数の周波数帯域における傷成分を効果的に抽出することができる。   As described above, the image processing apparatus according to the present embodiment creates a plurality of band limited images Tm (m = 1 to n, n ≧ 2) representing components for a plurality of different frequency bands of the original image S0 (Y0). A non-linear conversion process is performed on these band limited images to obtain a plurality of converted images (scratch components). Then, by multiplying the pixel values of the plurality of converted images by a coefficient β determined according to the luminance value of the original image S0 and adding them, the flaw component of the original image S0 is obtained. Scratch components in a plurality of frequency bands can be extracted effectively.

また、本実施形態の画像処理装置は、例えば図12に示す非線形変換関数fを決める閾値Th1、Th2や、非線形変換関数fの曲線の傾きや、出力値Mの大きさや、式(5)〜式(9)における係数βなどを変えるだけで、傷成分を検出しようとする程度を変えることができると共に、異なる種類の検査対象物にも対応することができ、便利である。   Further, the image processing apparatus of the present embodiment, for example, thresholds Th1 and Th2 for determining the nonlinear transformation function f shown in FIG. 12, the slope of the curve of the nonlinear transformation function f, the magnitude of the output value M, and equations (5) to (5) Conveniently, it is possible to change the degree to detect the scratch component by changing only the coefficient β in the equation (9), and to deal with different types of inspection objects.

以上、本発明の望ましい実施形態について説明したが、本発明の表面傷検出方法および装置並びにそのためのプログラムは、上述した実施形態に限られることがなく、本発明の主旨を逸脱しない限り、様々な増減、変化を加えることができる。  The preferred embodiments of the present invention have been described above. However, the surface flaw detection method and apparatus of the present invention and the program therefor are not limited to the above-described embodiments, and various methods are possible without departing from the gist of the present invention. Increase, decrease, change can be added.

例えば、本実施形態の画像処理装置において、帯域制限画像作成手段20は、原画像S0およびボケ画像Sk(k=1〜n,n≧2)を用いて上記式(4)に従って帯域制限画像を得るようにするものであり、帯域制限画像作成手段20、傷成分抽出手段30において行われる処理を下記の式(6)により表すことができるが、例えば、下記の式(7)または式(8)または式(9)により、帯域制限画像作成手段20および傷成分抽出手段30の処理を行うようにしてもよい。すなわち、式(6)により表される本実施形態の画像処理装置における処理のように、原画像および各ボケ画像を用いて、互いに隣接する周波数帯域の画像(原画像S0はボケ画像S1と周波数帯域が隣接するものとする)の減算を行って帯域制限画像を得るようにしてもよいが、式(7)に示すように、全てのボケ画像と、原画像との減算により帯域制限画像を得るようにしてもよく、または式(8)に示すように、原画像を用いず互いに隣接する周波数帯域のボケ画像の減算を行って帯域制限画像を得るようにしてもよく、または式(9)に示すように、原画像を用いず、ボケ画像S1と、ボケ画像S1を除いた全てのボケ画像Sm(m=2〜n,n≧3)との減算により帯域制限画像を得るようにしてもよい。   For example, in the image processing apparatus of the present embodiment, the band limited image creating unit 20 uses the original image S0 and the blurred image Sk (k = 1 to n, n ≧ 2) to generate the band limited image according to the above equation (4). The processing performed in the band limited image creating means 20 and the flaw component extracting means 30 can be expressed by the following formula (6). For example, the following formula (7) or formula (8) ) Or equation (9), the band-limited image creation means 20 and the flaw component extraction means 30 may be processed. That is, as in the processing in the image processing apparatus of the present embodiment represented by Expression (6), using the original image and each blurred image, the images in the frequency bands adjacent to each other (the original image S0 is the frequency of the blurred image S1 and the frequency The band-limited image may be obtained by subtracting the band-limited images), but as shown in Expression (7), the band-limited image is obtained by subtracting all the blurred images and the original image. Alternatively, as shown in Expression (8), the band-limited image may be obtained by subtracting the blurred images in the frequency bands adjacent to each other without using the original image, or Expression (9). ), The band-limited image is obtained by subtraction of the blurred image S1 and all the blurred images Sm (m = 2 to n, n ≧ 3) excluding the blurred image S1 without using the original image. May be.


Figure 2005351645
Figure 2005351645
Figure 2005351645
Figure 2005351645
Figure 2005351645
Figure 2005351645
Figure 2005351645
Figure 2005351645


また、帯域制限画像を作成する方法も、上述した式(4)、式(6)〜(9)により表される方法のように、原画像のボケ画像を作成し、原画像および/またはボケ画像を用いて作成する方法に限らず、原画像の複数の異なる周波数帯域の成分を表す画像を作成することができれば、いかなる方法を用いてもよい。

Also, the method for creating the band limited image is to create a blurred image of the original image, and to create the blurred image of the original image and / or the blurred image as in the methods represented by the above-described equations (4) and (6) to (9). The method is not limited to the method of creating using an image, and any method may be used as long as an image representing a plurality of different frequency band components of the original image can be created.

また、本実施形態の画像処理装置において、各周波数帯域における傷成分Qmを直接加算して傷成分Qを得ると共に、原画像S0(Y0)から傷成分Qを減算して傷補修済み画像S’0(Y1)を得るようにしているが、原画像S0から各周波数帯域における傷成分Qmを逐一減算して傷補修済み画像S’0を得た後、原画像S0から傷補修済み画像S’0を減算するようにして傷成分Qを得るようにしてもよい。   In the image processing apparatus of this embodiment, the scratch component Qm in each frequency band is directly added to obtain the scratch component Q, and the scratch component Q is subtracted from the original image S0 (Y0) to repair the scratched image S ′. 0 (Y1) is obtained, but after the wound component Qm in each frequency band is subtracted from the original image S0 one by one to obtain the wound repaired image S′0, the wound repaired image S ′ is obtained from the original image S0. The scratch component Q may be obtained by subtracting 0.

また、本実施形態の画像処理装置において、抽出された傷成分Qに基づいて画像を補修した結果を表示することによって操作者に確認させるようにしているが、目的が傷成分の抽出のみである場合においては、画像を補修する処理を行わなくてもよい。   Further, in the image processing apparatus of the present embodiment, the operator is confirmed by displaying the result of repairing the image based on the extracted wound component Q, but the purpose is only the extraction of the wound component. In some cases, it is not necessary to perform the process of repairing the image.

また、本実施形態の画像処理装置は、輝度空間において傷成分の抽出を行うようにしているが、例えば、R、G、B成分の全てに対して行うようにしてよい。   Further, the image processing apparatus according to the present embodiment extracts the scratch component in the luminance space. However, for example, it may be performed for all of the R, G, and B components.

本発明の実施形態となる画像処理装置の構成を示すブロック図1 is a block diagram showing a configuration of an image processing apparatus according to an embodiment of the present invention. 図1に示す画像処理装置におけるボケ画像作成手段10の構成を示すブロック図1 is a block diagram showing the configuration of a blurred image creation unit 10 in the image processing apparatus shown in FIG. 図2に示すボケ画像作成手段10におけるフィルタリング手段12が用いる1次元フィルタFの例を示す図The figure which shows the example of the one-dimensional filter F which the filtering means 12 in the blur image creation means 10 shown in FIG. 2 uses 図2に示すボケ画像作成手段10において行われる処理を示す図The figure which shows the process performed in the blurred image preparation means 10 shown in FIG. 図2に示すボケ画像作成手段10におけるフィルタリング手段12により作成されたフィルタリング画像Bkの周波数特性を示す図The figure which shows the frequency characteristic of the filtering image Bk produced by the filtering means 12 in the blur image creation means 10 shown in FIG. 図2に示すボケ画像作成手段10におけるフィルタリング手段12が用いる2次元フィルタの例を示す図The figure which shows the example of the two-dimensional filter which the filtering means 12 in the blur image creation means 10 shown in FIG. 2 uses 図2に示すボケ画像作成手段10における補間手段14がフィルタリング画像B1の補間に用いるフィルタF1の例を示す図The figure which shows the example of the filter F1 which the interpolation means 14 in the blur image creation means 10 shown in FIG. 2 uses for interpolation of the filtering image B1 図2に示すボケ画像作成手段10における補間手段14がフィルタリング画像B2の補間に用いるフィルタF2の例を示す図The figure which shows the example of the filter F2 which the interpolation means 14 in the blur image creation means 10 shown in FIG. 2 uses for interpolation of filtering image B2 図2に示すボケ画像作成手段10により作成されたボケ画像Skの周波数特性を示す図The figure which shows the frequency characteristic of the blur image Sk created by the blur image creation means 10 shown in FIG. 図1に示す本発明の実施形態の画像処理装置における帯域制限画像作成手段20により作成された帯域制限画像Tkの周波数特性を示す図The figure which shows the frequency characteristic of the band limited image Tk produced by the band limited image preparation means 20 in the image processing apparatus of embodiment of this invention shown in FIG. 図1に示す本発明の実施形態の画像処理装置における傷成分抽出手段30の構成を示すブロック図The block diagram which shows the structure of the flaw component extraction means 30 in the image processing apparatus of embodiment of this invention shown in FIG. 図11に示す傷成分抽出手段30における非線形変換手段32が用いる非線形関数fの例を示す図The figure which shows the example of the nonlinear function f which the nonlinear transformation means 32 in the flaw component extraction means 30 shown in FIG. 11 uses

符号の説明Explanation of symbols

1 YCC変換手段
10 ボケ画像作成手段
12 フィルタリング手段
14 補間手段
16 制御手段
20 帯域制限画像作成手段
30 傷成分成分抽出手段
32 非線形変換手段
34 加算手段
40 傷補修手段
44 合成手段
48 表示手段
50 平滑化手段
60 出力手段
Y 輝度値
Cb,Cr 色差値
DESCRIPTION OF SYMBOLS 1 YCC conversion means 10 Blurred image creation means 12 Filtering means 14 Interpolation means 16 Control means 20 Band-limited image creation means 30 Wound component extraction means 32 Non-linear conversion means 34 Addition means 40 Wound repair means 44 Composition means 48 Display means 50 Smoothing Means 60 Output means Y Luminance value Cb, Cr Color difference value

Claims (5)

検査対象物を撮像して得た対象物画像に基づいて、該対象物画像の複数の周波数帯域ごとの成分を表す複数の帯域制限画像を作成し、
出力値の絶対値を入力値の絶対値以下にする処理であって、かつ絶対値が所定の閾値以下である入力値に対しては、該入力値の絶対値が大きいほど出力値の絶対値が大きくなる一方、絶対値が前記所定の閾値より大きい入力値に対しては、出力値の絶対値が前記所定の閾値に対応する出力値の絶対値以下となる非線形変換処理を各前記帯域制限画像の夫々の画素値に対して施して複数の変換画像を得、
該複数の変換画像の相対応する画素の画素値を加算して得た加算画素値を前記検査対象物の表面の傷成分を表す傷成分画像の画素の画素値として取得することを特徴とする表面傷検出方法。
Based on the object image obtained by imaging the inspection object, create a plurality of band limited images representing components for each of a plurality of frequency bands of the object image,
For an input value in which the absolute value of the output value is less than or equal to the absolute value of the input value and the absolute value is less than or equal to a predetermined threshold value, the absolute value of the output value increases as the absolute value of the input value increases. On the other hand, for an input value whose absolute value is larger than the predetermined threshold value, nonlinear conversion processing in which the absolute value of the output value is equal to or smaller than the absolute value of the output value corresponding to the predetermined threshold value is performed for each band limitation. Apply to each pixel value of the image to get multiple converted images,
An added pixel value obtained by adding pixel values of corresponding pixels of the plurality of converted images is acquired as a pixel value of a flaw component image pixel representing a flaw component on the surface of the inspection object. Surface scratch detection method.
前記対象物画像の画素の画素値に応じて決められた係数を該画素に対応する前記加算画素値に乗算して得た値を前記傷成分画像の画素の画素値として取得することを特徴とする請求項1記載の表面傷検出方法。   A value obtained by multiplying the addition pixel value corresponding to the pixel by a coefficient determined according to a pixel value of the pixel of the object image is acquired as a pixel value of the pixel of the flaw component image. The surface flaw detection method according to claim 1. 検査対象物を撮像して得た対象物画像に基づいて、該対象物画像の複数の周波数帯域ごとの成分を表す複数の帯域制限画像を作成する帯域制限画像作成手段と、
出力値の絶対値を入力値の絶対値以下にする処理であって、かつ絶対値が所定の閾値以下である入力値に対しては、該入力値の絶対値が大きいほど出力値の絶対値が大きくなる一方、絶対値が前記所定の閾値より大きい入力値に対しては、出力値の絶対値が前記所定の閾値に対応する出力値の絶対値以下となる非線形変換処理を各前記帯域制限画像の夫々の画素値に対して施して複数の変換画像を得る非線形変換手段と、
該複数の変換画像の相対応する画素の画素値を加算して得た加算画素値を前記検査対象物の表面の傷成分を表す傷成分画像の画素の画素値として取得する傷成分取得手段とを有してなることを特徴とする表面傷検出装置。
Band-limited image creating means for creating a plurality of band-limited images representing components for each of a plurality of frequency bands of the object image based on the object image obtained by imaging the inspection object;
For an input value in which the absolute value of the output value is less than or equal to the absolute value of the input value and the absolute value is less than or equal to a predetermined threshold value, the absolute value of the output value increases as the absolute value of the input value increases. On the other hand, for an input value whose absolute value is larger than the predetermined threshold value, nonlinear conversion processing in which the absolute value of the output value is equal to or smaller than the absolute value of the output value corresponding to the predetermined threshold value is performed for each band limitation. Non-linear conversion means for applying to each pixel value of the image to obtain a plurality of converted images;
Flaw component acquisition means for acquiring an added pixel value obtained by adding pixel values of corresponding pixels of the plurality of converted images as a pixel value of a flaw component image pixel representing a flaw component on the surface of the inspection object; A surface flaw detection device comprising:
前記傷成分取得手段が、前記対象物画像の画素の画素値に応じて決められた係数を該画素に対応する前記加算画素値に乗算して得た値を前記傷成分画像の画素の画素値として取得するものであることを特徴とする請求項3記載の表面傷検出装置。   The flaw component acquisition means multiplies the addition pixel value corresponding to the pixel by a coefficient determined according to the pixel value of the pixel of the object image, and obtains a pixel value of the pixel of the flaw component image The surface flaw detection device according to claim 3, wherein the surface flaw detection device is acquired as: 検査対象物を撮像して得た対象物画像に基づいて、該対象物画像の複数の周波数帯域ごとの成分を表す複数の帯域制限画像を作成する処理と、
出力値の絶対値を入力値の絶対値以下にする処理であって、かつ絶対値が所定の閾値以下である入力値に対しては、該入力値の絶対値が大きいほど出力値の絶対値が大きくなる一方、絶対値が前記所定の閾値より大きい入力値に対しては、出力値の絶対値が前記所定の閾値に対応する出力値の絶対値以下となる非線形変換処理を各前記帯域制限画像の夫々の画素値に対して施して複数の変換画像を得る処理と、
該複数の変換画像の相対応する画素の画素値を加算して得た加算画素値を前記検査対象物の表面の傷成分を表す傷成分画像の画素の画素値として取得する処理とをコンピュータに実行させることを特徴とするプログラム。
Based on the object image obtained by imaging the inspection object, a process of creating a plurality of band limited images representing components for each of a plurality of frequency bands of the object image;
For an input value in which the absolute value of the output value is less than or equal to the absolute value of the input value and the absolute value is less than or equal to a predetermined threshold value, the absolute value of the output value increases as the absolute value of the input value increases. On the other hand, for an input value whose absolute value is larger than the predetermined threshold value, nonlinear conversion processing in which the absolute value of the output value is less than or equal to the absolute value of the output value corresponding to the predetermined threshold value is performed for each band limitation. Processing to obtain a plurality of converted images by applying to each pixel value of the image;
A process of acquiring an added pixel value obtained by adding pixel values of corresponding pixels of the plurality of converted images as a pixel value of a flaw component image pixel representing a flaw component on the surface of the inspection object; A program characterized by being executed.
JP2004169700A 2004-06-08 2004-06-08 Surface-damage detecting method, detector therefor and program Withdrawn JP2005351645A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2004169700A JP2005351645A (en) 2004-06-08 2004-06-08 Surface-damage detecting method, detector therefor and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2004169700A JP2005351645A (en) 2004-06-08 2004-06-08 Surface-damage detecting method, detector therefor and program

Publications (1)

Publication Number Publication Date
JP2005351645A true JP2005351645A (en) 2005-12-22

Family

ID=35586266

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2004169700A Withdrawn JP2005351645A (en) 2004-06-08 2004-06-08 Surface-damage detecting method, detector therefor and program

Country Status (1)

Country Link
JP (1) JP2005351645A (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2010239610A (en) * 2009-03-13 2010-10-21 Omron Corp Image processing device and image processing method
KR101293728B1 (en) 2012-12-07 2013-08-07 대한민국 Detecting method of wounded portion of skin and the recorded medium thereof
JP2016015118A (en) * 2014-06-09 2016-01-28 パナソニックIpマネジメント株式会社 Wrinkle detection device and wrinkle detection method
KR101661853B1 (en) * 2015-05-07 2016-09-30 이화여자대학교 산학협력단 Method and apparatus for processing image
US10379035B2 (en) 2016-03-28 2019-08-13 Panasonic Intellectual Property Management Co., Ltd. Appearance inspection apparatus and appearance inspection method
WO2020121594A1 (en) * 2018-12-14 2020-06-18 株式会社堀場製作所 Surface characteristics inspection device and machine learning device for surface characteristics inspection

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2010239610A (en) * 2009-03-13 2010-10-21 Omron Corp Image processing device and image processing method
KR101293728B1 (en) 2012-12-07 2013-08-07 대한민국 Detecting method of wounded portion of skin and the recorded medium thereof
JP2016015118A (en) * 2014-06-09 2016-01-28 パナソニックIpマネジメント株式会社 Wrinkle detection device and wrinkle detection method
KR101661853B1 (en) * 2015-05-07 2016-09-30 이화여자대학교 산학협력단 Method and apparatus for processing image
US10379035B2 (en) 2016-03-28 2019-08-13 Panasonic Intellectual Property Management Co., Ltd. Appearance inspection apparatus and appearance inspection method
WO2020121594A1 (en) * 2018-12-14 2020-06-18 株式会社堀場製作所 Surface characteristics inspection device and machine learning device for surface characteristics inspection
JPWO2020121594A1 (en) * 2018-12-14 2021-10-21 株式会社堀場製作所 Surface property inspection device and machine learning device for surface property inspection

Similar Documents

Publication Publication Date Title
JP4455897B2 (en) Image processing method, apparatus, and program
Hosseini et al. Encoding visual sensitivity by maxpol convolution filters for image sharpness assessment
US8411979B2 (en) Digital image processing and enhancing system and method with function of removing noise
JP4792109B2 (en) Image defect removal considering image features
Julliand et al. Image noise and digital image forensics
JP2006180268A (en) Image processing apparatus, image processing method, program, and recording medium
JP2005351645A (en) Surface-damage detecting method, detector therefor and program
Narasimharao et al. Advanced Techniques for Color Image Blind Deconvolution to Restore Blurred Images
Russo New method for performance evaluation of grayscale image denoising filters
WO2014002811A1 (en) Image-processing device, image-processing method, and image-processing program
Du et al. Retrospective shading correction of confocal laser scanning microscopy beef images for three-dimensional visualization
Staroverov et al. New Methods for Digital Processing of Microfocus X-Ray Images.
JP4274426B2 (en) Image processing method, apparatus, and program
JP2006053859A (en) Image processor, method and program
Oladi et al. Photographic application of the Coral Health Chart in turbid environments: The efficiency of image enhancement and restoration methods
JP4456096B2 (en) Noise removing method, apparatus, and program
Arora et al. Digital restoration of old paintings
Samadani et al. Image thumbnails that represent blur and noise
Napoli Spatafora et al. Benchmarking of blind video deblurring methods on long exposure and resource poor settings
JP3937022B2 (en) Image processing apparatus and imaging device
JP4851196B2 (en) Image processing method and apparatus, and image processing program
Valdes et al. Multidimensional filtering approaches for pre-processing thermal images
EP2869260A1 (en) Method and apparatus for generating from a quantised image having a first bit depth a corresponding image having a second bit depth
Salah et al. A Fractional-Order Derivative Variational Framework for Blind Image Deconvolution via Nash Game Strategy
Kobra et al. Advanced underwater image restoration: A comparative study of white balance, dehazing, and contrast enhancement techniques

Legal Events

Date Code Title Description
A711 Notification of change in applicant

Free format text: JAPANESE INTERMEDIATE CODE: A712

Effective date: 20061207

A300 Withdrawal of application because of no request for examination

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 20070904