JP6834126B2 - Information processing equipment, defect detection methods and programs - Google Patents

Information processing equipment, defect detection methods and programs Download PDF

Info

Publication number
JP6834126B2
JP6834126B2 JP2015231096A JP2015231096A JP6834126B2 JP 6834126 B2 JP6834126 B2 JP 6834126B2 JP 2015231096 A JP2015231096 A JP 2015231096A JP 2015231096 A JP2015231096 A JP 2015231096A JP 6834126 B2 JP6834126 B2 JP 6834126B2
Authority
JP
Japan
Prior art keywords
image
component
information processing
extracted
clusters
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.)
Active
Application number
JP2015231096A
Other languages
Japanese (ja)
Other versions
JP2017096853A (en
Inventor
亮介 笠原
亮介 笠原
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.)
Ricoh Co Ltd
Original Assignee
Ricoh 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 Ricoh Co Ltd filed Critical Ricoh Co Ltd
Priority to JP2015231096A priority Critical patent/JP6834126B2/en
Publication of JP2017096853A publication Critical patent/JP2017096853A/en
Application granted granted Critical
Publication of JP6834126B2 publication Critical patent/JP6834126B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

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

Description

本発明は、情報処理装置、欠陥検出方法およびプログラムに関する。 The present invention relates to information processing devices, defect detection methods and programs.

近年、FA(Factory Automation)での用途等を中心に、画像を用いた欠陥検出技術が一般的に使用されている。このような欠陥検出技術においては、事前知識として使用できるサンプル画像数が少ない場合や、照度変化などの外乱がある場合でも、高精度に欠陥検出を行うこと、また未知の欠陥モードへの対応が大きな課題となっている。ここで、外乱に強く、未知の欠陥モードへの対応が可能な欠陥検出アルゴリズムとして、正常画像のみを機械学習により学習させることにより、そこから外れた画像を検出する半教師あり異常検知を用いた技術が従来から知られている。 In recent years, defect detection technology using images has been generally used mainly for applications in FA (Factory Automation). In such a defect detection technology, even when the number of sample images that can be used as prior knowledge is small or there is a disturbance such as an illuminance change, it is possible to perform defect detection with high accuracy and to deal with an unknown defect mode. It has become a big issue. Here, as a defect detection algorithm that is resistant to disturbance and can deal with unknown defect modes, we used semi-supervised anomaly detection that detects images that deviate from the normal image by learning only normal images by machine learning. The technology has been known for some time.

また、例えば、特許文献1に示すように、検査対象物の画像情報に対して2値化処理を行い、欠陥候補の領域情報を取得し、その領域の特徴より欠陥かどうかを識別することで、欠陥検出を行う技術が知られている。 Further, for example, as shown in Patent Document 1, by performing binarization processing on the image information of the inspection target object, acquiring the region information of the defect candidate, and identifying whether or not the defect is a defect from the characteristics of the region. , A technique for detecting defects is known.

しかしながら、従来の技術では、正常サンプルの数は外乱も含めて一定数以上の数が必要となり、例えば正常サンプルが数枚しか準備出来ない場合に、外乱がある状況では良好な性能で欠陥検出を行うことが困難であるという問題がある。 However, in the conventional technology, the number of normal samples, including disturbances, needs to be a certain number or more. For example, when only a few normal samples can be prepared, defect detection can be performed with good performance in a situation with disturbances. There is the problem that it is difficult to do.

また、特許文献1の技術では、単純な二値化を用いているため、照明状態の変化などにより、誤検出が発生する可能性がある。また、特許文献1の技術でも、外乱に弱く、外乱がある条件下では良好な性能で欠陥検出を行うことが困難である。 Further, since the technique of Patent Document 1 uses simple binarization, erroneous detection may occur due to a change in the lighting state or the like. Further, even the technique of Patent Document 1 is vulnerable to disturbance, and it is difficult to detect defects with good performance under conditions with disturbance.

本発明は、上記に鑑みてなされたものであって、サンプル画像数が少ない場合や、外乱にがある場合、新たな欠陥モードの場合でも、高精度に欠陥検出を行うことができる情報処理装置、欠陥検出方法およびプログラムを提供することを主な目的とする。 The present invention has been made in view of the above, and is an information processing apparatus capable of performing defect detection with high accuracy even when the number of sample images is small, when there is a disturbance, or even in a new defect mode. , The main purpose is to provide defect detection methods and programs.

上述した課題を解決し、目的を達成するために、本発明は、物体の外観上の欠陥を検出する情報処理装置であって、前記物体が撮像された検出対象の画像から教師なし学習を用いてクラスタに分類し、分類されたクラスタ群から前記物体の本来の画素に基づく値を元に前記物体が含まれるクラスタを抽出し、前記クラスタの領域をシード領域として設定したクラスタリングにより、前記物体が撮像された検出対象の画像から正常部分を抽出する分類部と、抽出された正常部分と、所定の正常なテンプレート画像とに基づいて、前記検出対象の画像から欠陥を検出する欠陥検出部と、を備えた。 In order to solve the above-mentioned problems and achieve the object, the present invention is an information processing apparatus that detects defects in the appearance of an object, and uses unsupervised learning from an image of a detection target in which the object is captured. The object is classified into clusters, and the cluster containing the object is extracted from the classified cluster group based on the value based on the original pixel of the object, and the area of the cluster is set as the seed area. A classification unit that extracts a normal part from the captured image to be detected, a defect detection unit that detects a defect from the image to be detected based on the extracted normal part and a predetermined normal template image, and a defect detection unit. Equipped with.

本発明によれば、サンプル画像数が少ない場合や、外乱がある場合、新たな欠陥モードの場合でも、高精度に欠陥検出を行うことができるという効果を奏する。 According to the present invention, there is an effect that defect detection can be performed with high accuracy even when the number of sample images is small, when there is disturbance, or even in the case of a new defect mode.

図1は、本実施形態に係る情報処理システムの一例の構成図である。FIG. 1 is a configuration diagram of an example of an information processing system according to the present embodiment. 図2は、本実施形態に係る情報処理装置の一例のハードウェア構成図である。FIG. 2 is a hardware configuration diagram of an example of the information processing device according to the present embodiment. 図3は、本実施形態に係る情報処理装置の一例の機能ブロック図である。FIG. 3 is a functional block diagram of an example of the information processing device according to the present embodiment. 図4は、本実施形態に係る欠陥検出処理の手順の一例を示すフローチャートである。FIG. 4 is a flowchart showing an example of the procedure of the defect detection process according to the present embodiment. 図5は、本実施形態において入力される画像の一例を示す図である。FIG. 5 is a diagram showing an example of an image input in the present embodiment. 図6は、本実施形態におけるシード領域の画像の一例を示す図である。FIG. 6 is a diagram showing an example of an image of the seed region in the present embodiment. 図7は、本実施形態において部品形状として抽出された画像の一例を示す図である。FIG. 7 is a diagram showing an example of an image extracted as a component shape in the present embodiment. 図8は、本実施形態におけるテンプレート画像の一例を示す図である。FIG. 8 is a diagram showing an example of a template image in the present embodiment. 図9は、本実施形態における検出結果の例を示す図である。FIG. 9 is a diagram showing an example of the detection result in the present embodiment.

以下、本発明の実施形態について、図面を参照しながら詳細に説明する。 Hereinafter, embodiments of the present invention will be described in detail with reference to the drawings.

<システム構成>
まず、第1の実施形態に係る情報処理システム1のシステム構成について説明する。図1は、第1の実施形態に係る情報処理システムの一例の構成図である。
<System configuration>
First, the system configuration of the information processing system 1 according to the first embodiment will be described. FIG. 1 is a configuration diagram of an example of an information processing system according to the first embodiment.

図1に示すように情報処理システム1は、情報処理装置10と、撮像装置30とを有する。また、情報処理装置10及び撮像装置30は、例えばUSB(Universal Serial Bus)ケーブル等を介して通信可能に接続されている。なお、情報処理装置10及び撮像装置30は、LAN(Local Area Network)等を介して通信可能に接続されていてもよい。 As shown in FIG. 1, the information processing system 1 includes an information processing device 10 and an image pickup device 30. Further, the information processing device 10 and the image pickup device 30 are communicably connected via, for example, a USB (Universal Social Bus) cable or the like. The information processing device 10 and the image pickup device 30 may be communicably connected via a LAN (Local Area Network) or the like.

情報処理装置10は、例えばPC(パーソナルコンピュータ)等である。情報処理装置10には、欠陥検出プログラム20がインストールされている。情報処理装置10は、欠陥検出プログラム20を用いることで、撮像装置30で撮像することにより入力された画像データにおける被写体の外観上の欠陥を検出することができる。本実施形態では、撮像装置30により撮像される被写体としては例えば工場で量産される製品等を想定し、外観上に欠陥がある場合とは、製品等の外観上(表面上)に傷等がある場合を言うものとする。 The information processing device 10 is, for example, a PC (personal computer) or the like. The defect detection program 20 is installed in the information processing device 10. By using the defect detection program 20, the information processing device 10 can detect defects in the appearance of the subject in the image data input by taking an image with the image pickup device 30. In the present embodiment, the subject imaged by the image pickup apparatus 30 is assumed to be, for example, a product mass-produced in a factory, and when there is a defect in the appearance, there is a scratch or the like on the appearance (surface) of the product or the like. Suppose there is a case.

ここで、欠陥検出プログラム20は、教師なし学習を用いた異常検知により画像データの被写体の外観上の欠陥を検出するものとする。ここで、教師なし学習とは、機械学習の一つであり、入力データのみで教師データが必要ない機械学習である。 Here, it is assumed that the defect detection program 20 detects defects in the appearance of the subject of the image data by abnormality detection using unsupervised learning. Here, unsupervised learning is one of machine learning, and is machine learning that uses only input data and does not require teacher data.

なお、情報処理装置10は、PCに限られず、スマートフォン、タブレット端末等の携帯端末装置であってもよい。 The information processing device 10 is not limited to a PC, and may be a mobile terminal device such as a smartphone or a tablet terminal.

撮像装置30は、被写体を撮像して画像データを生成するカメラ等である。撮像装置30により生成された画像データは、例えばUSBケーブル等を介して情報処理装置10に入力される。撮像装置30は、情報処理装置10に内蔵されていてもよい。 The image pickup device 30 is a camera or the like that captures a subject and generates image data. The image data generated by the image pickup apparatus 30 is input to the information processing apparatus 10 via, for example, a USB cable or the like. The image pickup device 30 may be built in the information processing device 10.

<ハードウェア構成>
次に、第1の実施形態に係る情報処理装置10のハードウェア構成について説明する。図2は、第1の実施形態に係る情報処理装置の一例のハードウェア構成図である。図2に示すように情報処理装置10は、CPU(Central Processing Unit)11と、HDD(Hard Disk Drive)12と、RAM(Random Access Memory)13と、ROM(Read Only Memory)14とを備えている。また、情報処理装置10は、入力装置15と、表示装置16と、外部I/F17と、通信I/F18とを備えている。これらの各部はバスBで接続されている。
<Hardware configuration>
Next, the hardware configuration of the information processing apparatus 10 according to the first embodiment will be described. FIG. 2 is a hardware configuration diagram of an example of the information processing device according to the first embodiment. As shown in FIG. 2, the information processing device 10 includes a CPU (Central Processing Unit) 11, an HDD (Hard Disk Drive) 12, a RAM (Random Access Memory) 13, and a ROM (Read Only Memory) 14. There is. Further, the information processing device 10 includes an input device 15, a display device 16, an external I / F 17, and a communication I / F 18. Each of these parts is connected by bus B.

CPU11は、ROM14やHDD12等の記憶装置からプログラムやデータをRAM13上に読み出し、処理を実行することで、情報処理装置10全体の制御や機能を実現する演算装置である。 The CPU 11 is an arithmetic unit that realizes control and functions of the entire information processing device 10 by reading a program or data from a storage device such as the ROM 14 or the HDD 12 onto the RAM 13 and executing processing.

HDD12は、プログラムやデータを格納している不揮発性の記憶装置である。格納されるプログラムやデータには、例えば、情報処理装置10全体を制御する基本ソフトウェアであるOS(Operating System)、OS上において各種機能を提供するアプリケーションソフトウェア(例えば、欠陥検出プログラム20)等がある。HDD12は格納しているプログラムやデータを所定のファイルシステム及び/又はDB(データベース)により管理している。なお、情報処理装置10は、HDD12の代わりに又はHDD12と併せて、SSD(Solid State Drive)等を備えていてもよい。 The HDD 12 is a non-volatile storage device that stores programs and data. The stored programs and data include, for example, an OS (Operating System) which is basic software for controlling the entire information processing apparatus 10, application software (for example, a defect detection program 20) which provides various functions on the OS, and the like. .. The HDD 12 manages the stored programs and data by a predetermined file system and / or DB (database). The information processing device 10 may include an SSD (Solid State Drive) or the like instead of the HDD 12 or in combination with the HDD 12.

RAM13は、プログラムやデータを一時保持する揮発性の半導体メモリ(記憶装置)である。ROM14は、電源を切ってもプログラムやデータを保持することができる不揮発性の半導体メモリ(記憶装置)である。 The RAM 13 is a volatile semiconductor memory (storage device) that temporarily holds programs and data. The ROM 14 is a non-volatile semiconductor memory (storage device) capable of holding programs and data even when the power is turned off.

入力装置15は、ユーザが各種操作信号を入力するのに用いられる装置である。入力装置15は、例えば、各種操作ボタン、タッチパネル、キーボード、マウス等である。表示装置16は、情報処理装置10による処理結果を表示する装置である。表示装置16は、例えば、ディスプレイ等である。 The input device 15 is a device used by the user to input various operation signals. The input device 15 is, for example, various operation buttons, a touch panel, a keyboard, a mouse, and the like. The display device 16 is a device that displays the processing result of the information processing device 10. The display device 16 is, for example, a display or the like.

外部I/F17は、外部装置とのインタフェースである。外部装置には、例えば、USB(Universal Serial Bus)メモリ、SDカード、CD、DVD等がある。通信I/F18は、撮像装置30とデータ通信を行うためのインタフェースである。 The external I / F 17 is an interface with an external device. The external device includes, for example, a USB (Universal Serial Bus) memory, an SD card, a CD, a DVD, and the like. The communication I / F 18 is an interface for performing data communication with the image pickup apparatus 30.

本実施形態に係る情報処理装置10は、上記ハードウェア構成を有することにより、後述する各種処理を実現することができる。 The information processing apparatus 10 according to the present embodiment can realize various processes described later by having the above hardware configuration.

<機能構成>
次に、第1の実施形態に係る情報処理装置10の機能構成について説明する。図3は、第1の実施形態に係る情報処理装置の一例の機能ブロック図である。図3に示すように、情報処理装置10は、部品画像生成部101と、分類部102と、欠陥検出部104と、テンプレート画像110とを主に備えている。部品画像生成部101、分類部102、欠陥検出部104は、例えばCPU11が欠陥検出プログラム20を実行させることにより実現される。
<Functional configuration>
Next, the functional configuration of the information processing apparatus 10 according to the first embodiment will be described. FIG. 3 is a functional block diagram of an example of the information processing device according to the first embodiment. As shown in FIG. 3, the information processing apparatus 10 mainly includes a component image generation unit 101, a classification unit 102, a defect detection unit 104, and a template image 110. The component image generation unit 101, the classification unit 102, and the defect detection unit 104 are realized by, for example, the CPU 11 executing the defect detection program 20.

テンプレート画像110は、物体を構成する部品ごとに存在、各部品に対応して予め定められた、正常な形状を示す画像(テンプレート)である。テンプレート画像110は、HDD12に保存されている。 The template image 110 is an image (template) that exists for each component constituting the object and that shows a normal shape that is predetermined for each component. The template image 110 is stored in the HDD 12.

部品画像生成部101は、撮像装置30で撮像された物体の画像を、テンプレート画像とのテンプレートマッチングを行って、撮像された画像から、物体の一または複数の部品画像を切り出して生成する。ここで、部品画像生成部101は、テンプレート画像110とのマッチングの際、部品の一部が表示画面外にある場合には、表示画面外の部分について、テンプレート画像を挿入(補完)して、マッチングを行う。これより、画面外に部品の一部が切れている場合でも、欠陥検出部104で欠陥と判定されないようにしている。 The component image generation unit 101 performs template matching with the template image of the image of the object captured by the imaging device 30, and cuts out one or a plurality of component images of the object from the captured image and generates the image. Here, when matching with the template image 110, the component image generation unit 101 inserts (complements) the template image for the portion outside the display screen when a part of the component is outside the display screen. Perform matching. As a result, even if a part of the component is cut off the screen, the defect detection unit 104 does not determine the defect.

分類部102は、物体が撮像された検出対象の画像から教師なし学習を用いてクラスタに分類し、分類されたクラスタ群から物体の本来の画素に基づく値を元に物体が含まれるクラスタを抽出し、クラスタの領域をシード領域として設定したクラスタリングにより、物体が撮像された検出対象の画像から正常部分を抽出する。具体的には、分類部102は、検出対象の画像としての物体の一または複数の部品画像の中央部分の輝度ヒストグラムを、教師なし学習のクラスタリングアルゴリズムとしてのk−meansアルゴリズムを用いて、2つのクラスタに分類し、一または複数の部品画像のそれぞれを構成する各画素をクラスタに分類する。ここで、分類部102は、クラスタに分類された画素のうち、本来の部品の輝度値に近似する画素のクラスタをシード領域として設定する。ここで、本来の部品の輝度値に近似する画素としては、本来の部品の輝度値との差が所定値以内の輝度値の画素とする。また、分類部102は、設定されたシード領域に基づいて、クラスタリングアルゴリズムとしてのChan−Veseアルゴリズムにより、部品画像から部品形状を抽出する。ここで、Chan−Veseアルゴリズムの詳細については、非特許文献「T. F. Chan and L. A. Vese, ”Active contours without edges,” IEEE Transactions on Image Processing, 10(2), 266-277 (2001).」に記載されている。 The classification unit 102 classifies the object into clusters by using unsupervised learning from the captured image of the object, and extracts the cluster containing the object from the classified cluster group based on the value based on the original pixel of the object. Then, by clustering in which the cluster area is set as the seed area, the normal part is extracted from the image of the detection target in which the object is captured. Specifically, the classification unit 102 uses a k-means algorithm as a clustering algorithm for unsupervised learning to obtain two brightness histograms of a central portion of an image of one or more parts of an object as an image to be detected. Classify into clusters, and classify each pixel constituting each of one or more component images into clusters. Here, the classification unit 102 sets a cluster of pixels that approximate the brightness value of the original component among the pixels classified into clusters as a seed region. Here, as the pixel that approximates the brightness value of the original component, the pixel has a brightness value whose difference from the brightness value of the original component is within a predetermined value. Further, the classification unit 102 extracts the component shape from the component image by the Chan-Vese algorithm as a clustering algorithm based on the set seed region. Here, the details of the Chan-Vese algorithm are described in the non-patent document "TF Chan and LA Vese," Active contours without edges, "IEEE Transactions on Image Processing, 10 (2), 266-277 (2001)." Has been done.

欠陥検出部104は、分類部102で抽出された正常部分と、所定の正常なテンプレート画像とに基づいて、検出対象の画像から欠陥を検出する。具体的には、欠陥検出部104は、分類部102で抽出された部品形状と、部品に対応して予め定められた、正常な形状のテンプレート画像とを比較し、差分が所定の閾値以上である場合に、部品画像が欠陥ありと識別する。 The defect detection unit 104 detects defects from the image to be detected based on the normal portion extracted by the classification unit 102 and a predetermined normal template image. Specifically, the defect detection unit 104 compares the component shape extracted by the classification unit 102 with a template image having a normal shape predetermined for the component, and the difference is equal to or higher than a predetermined threshold value. In some cases, the part image identifies it as defective.

また、欠陥検出部104は、欠陥ありと識別した場合に、部品画像のうち、テンプレート画像と差分がある領域を、欠陥領域と判定する。 Further, when the defect detection unit 104 determines that there is a defect, the defect detection unit 104 determines that the region having a difference from the template image in the component image is a defect region.

<処理の詳細>
次に、本実施形態に係る情報処理装置10による欠陥検出処理について説明する。図4は、本実施形態の欠陥検出処理の手順の一例を示すフローチャートである。
<Details of processing>
Next, the defect detection process by the information processing apparatus 10 according to the present embodiment will be described. FIG. 4 is a flowchart showing an example of the procedure of the defect detection process of the present embodiment.

まず、部品画像生成部101は、検査対象の画像である、撮像装置30で撮像された物体の画像を入力し、当該画像から、部品ごとのテンプレート画像110とのマッチング(テンプレートマッチング)を行って、物体を構成する部品の部位を切り出して一または複数の部品画像を生成する(S11)。 First, the component image generation unit 101 inputs an image of an object captured by the imaging device 30, which is an image to be inspected, and performs matching (template matching) with the template image 110 for each component from the image. , A part of a part constituting an object is cut out to generate one or a plurality of part images (S11).

図5は、本実施形態において入力される画像の一例を示す図である。この画像の例において、中央付近の黒い部分が欠陥であるとする。 FIG. 5 is a diagram showing an example of an image input in the present embodiment. In the example of this image, it is assumed that the black part near the center is a defect.

次に、分類部102は、S11で生成された各部品画像に対し、各部品の中央部の輝度ヒストグラムを、教師なし学習であるk−meansアルゴリズムにより2つのクラスタに分類し、各画素をそれぞれが属するクラスタに分類する(S12)。 Next, the classification unit 102 classifies the luminance histogram at the center of each component into two clusters by the k-means algorithm, which is unsupervised learning, for each component image generated in S11, and classifies each pixel into two clusters. It is classified into the cluster to which it belongs (S12).

次に、分類部102は、クラスタに分類された画素のうち、本来の部品の輝度値に近い画素(輝度値の差異が所定値以下の画素)のクラスタをシード領域として設定する(S13)。 Next, the classification unit 102 sets a cluster of pixels classified into clusters that are close to the brightness value of the original component (pixels whose difference in brightness value is equal to or less than a predetermined value) as a seed region (S13).

図6は、本実施形態におけるシード領域の画像の一例を示す図である。図6の例では、S12のk−meansアルゴリズムによるクラスタリングで、部品中央付近の元の輝度値に近い輝度値の領域のみが抽出され、シード領域として設定される。 FIG. 6 is a diagram showing an example of an image of the seed region in the present embodiment. In the example of FIG. 6, by clustering by the k-means algorithm of S12, only the region having the luminance value close to the original luminance value near the center of the component is extracted and set as the seed region.

そして、分類部102は、設定したシード領域に基づいて、クラスタリングアルゴリズムであるChan−Veseアルゴリズムにより部品形状を抽出する(S14)。図7は、本実施形態において部品形状として抽出された画像(正常領域画像)の一例を示す図である。 Then, the classification unit 102 extracts the component shape by the Chan-Vese algorithm, which is a clustering algorithm, based on the set seed region (S14). FIG. 7 is a diagram showing an example of an image (normal region image) extracted as a component shape in the present embodiment.

次に、欠陥検出部104は、S14で抽出された部品形状と、正常な部品形状のテンプレート画像を比較する(S15)。図8は、本実施形態におけるテンプレート画像110の一例を示す図である。図7の画像と図8の画像とが比較されることになる。 Next, the defect detection unit 104 compares the component shape extracted in S14 with the template image of the normal component shape (S15). FIG. 8 is a diagram showing an example of the template image 110 in the present embodiment. The image of FIG. 7 and the image of FIG. 8 will be compared.

そして、欠陥検出部104が、部品形状と、正常な部品形状のテンプレート画像との差異が所定の閾値以上であるか否かを判断する(S16)。差異が閾値以上である場合には(S16:Yes)、欠陥検出部104は、部品につき欠陥ありと識別する(S17)。そして、欠陥検出部104は、テンプレート画像110との差異がある部分について、欠陥領域と判定する(S18)。 Then, the defect detection unit 104 determines whether or not the difference between the component shape and the template image of the normal component shape is equal to or greater than a predetermined threshold value (S16). When the difference is equal to or greater than the threshold value (S16: Yes), the defect detection unit 104 identifies the component as having a defect (S17). Then, the defect detection unit 104 determines that the portion having a difference from the template image 110 is a defect region (S18).

S16で、部品形状と、正常な部品形状のテンプレート画像との差異が所定の閾値未満である場合には(S16:No)、部品は欠陥なしと判定される(S19)。 In S16, when the difference between the component shape and the template image of the normal component shape is less than a predetermined threshold value (S16: No), the component is determined to have no defect (S19).

上記S15からS18,S19までの処理は、部品毎に繰り返し実行される。全ての部品に対してS15からS18,S19までの処理が実行されたら、処理は終了する。 The processes from S15 to S18 and S19 are repeatedly executed for each component. When the processes from S15 to S18 and S19 are executed for all the parts, the process ends.

S12により、部品内に欠陥がある場合にも、欠陥がない部分の領域のみを次段のクラスタリングのシード領域として用いることができる。これにより、部品内に欠陥が存在する場合にもS14のクラスタリングにより、正常部分のみを抽出することが可能となる。 According to S12, even if there is a defect in the component, only the region of the portion without the defect can be used as the seed region for the clustering in the next stage. As a result, even when a defect exists in the component, only the normal portion can be extracted by clustering in S14.

<評価例>
以下、実際の評価例について示す。検出結果の評価には入力される画像が多いほうが望ましい。本評価例では、提供されている画像数が少ないため、提供画像に対して、ランダムに平行移動・回転・輝度変化を加えることで、Data augmentationを行い、評価用画像数を55枚に増加させた。表1に評価用画像の処理結果を示す。
<Evaluation example>
An actual evaluation example is shown below. It is desirable that many images are input for evaluation of the detection result. In this evaluation example, since the number of images provided is small, Data augmentation is performed by randomly adding translation, rotation, and brightness change to the provided images, and the number of images for evaluation is increased to 55. It was. Table 1 shows the processing results of the evaluation image.

ここで、欠陥検出を行ったコンピュータは、CPU:Core i7 870、メモリ20GBで、OSは、Windows(登録商標)7 64bitを用いた。 Here, the computer that performed the defect detection was a CPU: Core i7 870, a memory of 20 GB, and the OS was Windows (registered trademark) 7 64 bits.

欠陥検出率は、評価用画像の中に存在す30箇所の欠陥部位の検出率である。また、誤検出率はサンプル画像合計55枚の中で誤って正常部位を欠陥部位と誤検出した率を示している。今回準備したサンプル画像に対しては、全数正解しており、高い欠陥検出性能を有していることが分かる。 The defect detection rate is the detection rate of 30 defect sites existing in the evaluation image. The false detection rate indicates the rate at which a normal part is mistakenly detected as a defective part in a total of 55 sample images. All of the sample images prepared this time are correct, and it can be seen that they have high defect detection performance.

図9は、本実施形態における検出結果の例を示す図である。符号902の破線が正解の検出結果であり、符号901の実線が、本実施形態のアルゴリズムで検出した検出結果である。図9に示す検出結果では、正解とほぼ重なる形で正常に欠陥領域が検出できていることがわかる。処理時間に関しては処理内容をマルチスレッド化し、サンプル画像55枚を処理したところ一枚あたり777msであった。 FIG. 9 is a diagram showing an example of the detection result in the present embodiment. The broken line of reference numeral 902 is the detection result of the correct answer, and the solid line of reference numeral 901 is the detection result detected by the algorithm of the present embodiment. In the detection result shown in FIG. 9, it can be seen that the defective region can be normally detected so as to substantially overlap with the correct answer. Regarding the processing time, when the processing content was multithreaded and 55 sample images were processed, it was 777 ms per image.

このように本実施形態では、物体が撮像された検出対象の画像から教師なし学習を用いてクラスタに分類し、分類されたクラスタ群から物体の本来の画素に基づく値を元に物体が含まれるクラスタを抽出し、クラスタをシード領域として設定したクラスタリングにより、物体が撮像された検出対象の画像から正常部分を抽出し、抽出された正常部分と、正常なテンプレート画像とに基づいて、検出対象の画像から欠陥を検出する。すなわち、本実施形態では、教師なし学習と、クラスタリング処理を組み合わせた手法であるため、事前にサンプルを複数準備する必要はない。そして、本実施形態では、シード領域として、教師なし学習で分類されたクラスタから部品の本来の画素の輝度値に近い画素を使うことで、部品内に欠陥がある場合にも欠陥がない部分の領域のみを抽出することができる。この結果、本実施形態によれば、サンプル画像数が少ない場合や、外乱がある場合、新たな欠陥モードの場合でも、高精度に欠陥検出を行うことができる。 As described above, in the present embodiment, the object is classified into clusters by using unsupervised learning from the captured image of the object to be detected, and the object is included from the classified cluster group based on the value based on the original pixel of the object. By clustering that extracts the cluster and sets the cluster as the seed area, the normal part is extracted from the image of the detection target in which the object is captured, and the detection target is based on the extracted normal part and the normal template image. Detect defects in the image. That is, in this embodiment, since it is a method that combines unsupervised learning and clustering processing, it is not necessary to prepare a plurality of samples in advance. Then, in the present embodiment, by using pixels close to the brightness value of the original pixels of the component from the cluster classified by unsupervised learning as the seed region, even if there is a defect in the component, there is no defect. Only the region can be extracted. As a result, according to the present embodiment, defect detection can be performed with high accuracy even when the number of sample images is small, when there is disturbance, or even in the case of a new defect mode.

なお、本実施形態の情報処理装置10で実行される欠陥検出プログラム20は、インストール可能な形式又は実行可能な形式のファイルでCD−ROM、フレキシブルディスク(FD)、CD−R、DVD(Digital Versatile Disk)等のコンピュータで読み取り可能な記録媒体に記録されて提供される。 The defect detection program 20 executed by the information processing apparatus 10 of the present embodiment is a file in an installable format or an executable format, and is a CD-ROM, a flexible disk (FD), a CD-R, or a DVD (Digital Versaille). It is recorded and provided on a recording medium that can be read by a computer such as a Disc).

また、本実施形態の情報処理装置10で実行される欠陥検出プログラム20を、インターネット等のネットワークに接続されたコンピュータ上に格納し、ネットワーク経由でダウンロードさせることにより提供するように構成しても良い。また、本実施形態の情報処理装置10で実行される欠陥検出プログラム20をインターネット等のネットワーク経由で提供または配布するように構成しても良い。 Further, the defect detection program 20 executed by the information processing apparatus 10 of the present embodiment may be stored on a computer connected to a network such as the Internet and provided by downloading via the network. .. Further, the defect detection program 20 executed by the information processing apparatus 10 of the present embodiment may be provided or distributed via a network such as the Internet.

また、本実施形態の情報処理装置10で実行される欠陥検出プログラム20を、ROM14等に予め組み込んで提供するように構成してもよい。 Further, the defect detection program 20 executed by the information processing apparatus 10 of the present embodiment may be configured to be provided by being incorporated in the ROM 14 or the like in advance.

本発明のいくつかの実施形態を説明したが、これらの実施形態は、例として提示したものであり、発明の範囲を限定することは意図していない。これら新規な実施形態は、その他の様々な形態で実施されることが可能であり、発明の要旨を逸脱しない範囲で、種々の省略、置き換え、変更を行うことができる。これら実施形態やその変形は、発明の範囲や要旨に含まれるとともに、特許請求の範囲に記載された発明とその均等の範囲に含まれる。 Although some embodiments of the present invention have been described, these embodiments are presented as examples and are not intended to limit the scope of the invention. These novel embodiments can be implemented in various other embodiments, and various omissions, replacements, and changes can be made without departing from the gist of the invention. These embodiments and modifications thereof are included in the scope and gist of the invention, and are also included in the scope of the invention described in the claims and the equivalent scope thereof.

1 情報処理システム
10 情報処理装置
101 部品画像生成部
102 分類部
104 欠陥検出部
110 テンプレート画像
1 Information processing system 10 Information processing device 101 Parts image generation unit 102 Classification unit 104 Defect detection unit 110 Template image

特開2013−167596号公報Japanese Unexamined Patent Publication No. 2013-167596

Claims (10)

物体の外観上の欠陥を検出する情報処理装置であって、
前記物体が撮像された検出対象の画像から切り出された物体の1または複数の部分画像の各画素を、教師なし学習を用いて複数のクラスタのうちいずれかのクラスタに分類し、分類されたクラスタ群から前記物体の本来の画素の輝度値を元に前記物体に対応する画素が含まれるクラスタを抽出し、抽出した該クラスタに分類された画素で構成される領域をシード領域として用いたクラスタリングにより、前記物体が撮像された検出対象の画像から該物体の部品形状を抽出する分類部と、
抽出された前記部品形状と、所定の正常なテンプレート画像とに基づいて、前記検出対象の画像から欠陥を検出する欠陥検出部と、
を備えた情報処理装置。
An information processing device that detects defects in the appearance of an object.
Each pixel of one or more partial images of the object cut out from the image to be detected in which the object is captured is classified into one of a plurality of clusters by using unsupervised learning, and the classified clusters are used. By clustering, clusters including pixels corresponding to the object are extracted from the group based on the brightness value of the original pixels of the object, and a region composed of the extracted pixels classified into the cluster is used as a seed region. , A classification unit that extracts the component shape of the object from the image of the detection target in which the object is captured,
A defect detection unit that detects defects from the image to be detected based on the extracted component shape and a predetermined normal template image, and
Information processing device equipped with.
前記検出対象の画像から、前記物体の一または複数の部品画像を切り出す部品画像生成部を、さらに備え、
前記分類部は、前記検出対象の画像から切り出された前記物体の一または複数の部品画像の中央部分の画素の輝度値のヒストグラムである輝度ヒストグラムに基づいて、前記教師なし学習の前記クラスタリングのアルゴリズムとしてのk−meansアルゴリズムを用いて、前記輝度ヒストグラムに含まれる各画素を2つのクラスタのいずれかに分類することにより、前記一または複数の部品画像のそれぞれを構成する各画素を、前記2つのクラスタのいずれかに分類する、
請求項1に記載の情報処理装置。
A component image generator for cutting out one or more component images of the object from the image to be detected is further provided.
The classification unit is an algorithm for the clustering of unsupervised learning based on a brightness histogram which is a histogram of the brightness values of pixels in the central portion of one or a plurality of component images of the object cut out from the image to be detected. By classifying each pixel included in the brightness histogram into one of two clusters using the k-means algorithm as described above, each pixel constituting each of the one or a plurality of component images is divided into the two. Classify into one of the clusters,
The information processing device according to claim 1.
前記分類部は、前記2つのクラスタのうち、本来の部品の輝度値との差が所定値以内の輝度値の画素のクラスタを抽出し、抽出した該クラスタに分類された画素で構成される領域を前記シード領域とする、
請求項2に記載の情報処理装置。
The classification unit extracts a cluster of pixels having a brightness value whose difference from the brightness value of the original component is within a predetermined value from the two clusters, and an area composed of pixels classified into the extracted cluster. Is the seed region.
The information processing device according to claim 2.
前記分類部は、前記シード領域に基づいて、前記クラスタリングのアルゴリズムとしてのChan−Veseアルゴリズムにより、前記部品画像から前記部品形状を抽出する、
請求項3に記載の情報処理装置。
Based on the seed region, the classification unit extracts the component shape from the component image by the Chan-Vese algorithm as the clustering algorithm.
The information processing device according to claim 3.
前記欠陥検出部は、抽出された前記部品形状と、前記部品に対応して予め定められた、正常な形状のテンプレート画像とを比較し、差分が所定の閾値以上である場合に、前記部品画像が欠陥ありと識別する、
請求項4に記載の情報処理装置。
The defect detection unit compares the extracted component shape with a template image having a normal shape predetermined for the component, and when the difference is equal to or greater than a predetermined threshold value, the component image. Identify as defective,
The information processing device according to claim 4.
前記欠陥検出部は、欠陥ありと識別した場合に、前記部品画像のうち、前記テンプレート画像と差分がある領域を、欠陥領域と判定する、
請求項5に記載の情報処理装置。
When the defect detection unit determines that there is a defect, the defect detection unit determines, in the component image, a region having a difference from the template image as a defect region.
The information processing device according to claim 5.
前記部品画像生成部は、前記検出対象の画像から、前記テンプレート画像とのマッチングにより、前記物体の一または複数の部品画像を切り出す、
請求項5または6に記載の情報処理装置。
The component image generation unit cuts out one or a plurality of component images of the object from the image to be detected by matching with the template image.
The information processing device according to claim 5 or 6.
前記部品画像生成部は、前記テンプレート画像とのマッチングの際、前記部品の一部が表示画面外にある場合には、前記表示画面外の部分について、前記テンプレート画像で補完して、前記マッチングを行う、
請求項7に記載の情報処理装置。
When matching with the template image, the component image generation unit complements the portion outside the display screen with the template image when a part of the component is outside the display screen, and performs the matching. Do, do
The information processing device according to claim 7.
物体の外観上の欠陥を検出する欠陥検出方法であって、
前記物体が撮像された検出対象の画像から切り出された物体の1または複数の部分画像の各画素を、教師なし学習を用いて複数のクラスタのうちいずれかのクラスタに分類し、分類されたクラスタ群から前記物体の本来の画素の輝度値に基づく値を元に前記物体に対応する画素が含まれるクラスタを抽出し、抽出した該クラスタに分類された画素で構成される領域をシード領域として用いたクラスタリングにより、前記物体が撮像された検出対象の画像から該物体の部品形状を抽出し、
抽出された前記部品形状と、所定の正常なテンプレート画像とに基づいて、前記検出対象の画像から欠陥を検出する、
ことを含む欠陥検出方法。
A defect detection method that detects defects in the appearance of an object.
Each pixel of one or more partial images of the object cut out from the image to be detected in which the object is captured is classified into one of a plurality of clusters by using unsupervised learning, and the classified clusters are used. A cluster containing pixels corresponding to the object is extracted from the group based on a value based on the brightness value of the original pixel of the object, and an area composed of the extracted pixels classified into the cluster is used as a seed area. The component shape of the object was extracted from the image of the detection target in which the object was imaged by the clustering.
Defects are detected from the image to be detected based on the extracted part shape and a predetermined normal template image.
Defect detection methods including that.
物体の外観上の欠陥を検出するコンピュータに実行させるためのプログラムであって、
前記物体が撮像された検出対象の画像から切り出された物体の1または複数の部分画像の各画素を、教師なし学習を用いて複数のクラスタのうちいずれかのクラスタに分類し、分類されたクラスタ群から前記物体の本来の画素の輝度値を元に前記物体に対応する画素が含まれるクラスタを抽出し、抽出した該クラスタに分類された画素で構成される領域をシード領域として用いたクラスタリングにより、前記物体が撮像された検出対象の画像から該物体の部品形状を抽出し、
抽出された前記部品形状と、所定の正常なテンプレート画像とに基づいて、前記検出対象の画像から欠陥を検出する、
ことを前記コンピュータに実行させるためのプログラム。
A program to be executed by a computer that detects defects in the appearance of an object.
Each pixel of one or more partial images of the object cut out from the image to be detected in which the object is captured is classified into one of a plurality of clusters by using unsupervised learning, and the classified clusters are used. A cluster containing pixels corresponding to the object is extracted from the group based on the brightness value of the original pixel of the object, and a region composed of the extracted pixels classified into the cluster is used as a seed region by clustering. , The component shape of the object is extracted from the image of the detection target in which the object is captured.
Defects are detected from the image to be detected based on the extracted part shape and a predetermined normal template image.
A program that causes the computer to do this.
JP2015231096A 2015-11-26 2015-11-26 Information processing equipment, defect detection methods and programs Active JP6834126B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2015231096A JP6834126B2 (en) 2015-11-26 2015-11-26 Information processing equipment, defect detection methods and programs

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2015231096A JP6834126B2 (en) 2015-11-26 2015-11-26 Information processing equipment, defect detection methods and programs

Publications (2)

Publication Number Publication Date
JP2017096853A JP2017096853A (en) 2017-06-01
JP6834126B2 true JP6834126B2 (en) 2021-02-24

Family

ID=58803786

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2015231096A Active JP6834126B2 (en) 2015-11-26 2015-11-26 Information processing equipment, defect detection methods and programs

Country Status (1)

Country Link
JP (1) JP6834126B2 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112907536A (en) * 2021-02-20 2021-06-04 云南电网有限责任公司电力科学研究院 Crimping defect detection method and device for crimping type strain clamp
CN113554604B (en) * 2021-07-01 2024-02-02 常州大学 Melt-blown cloth defect area detection method based on machine vision

Family Cites Families (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11338848A (en) * 1998-05-26 1999-12-10 Ffc:Kk Data abnormality detector
JP2000292365A (en) * 1999-04-01 2000-10-20 Matsushita Electric Ind Co Ltd Defect detecting method and defect detecting device
US6535776B1 (en) * 1999-09-20 2003-03-18 Ut-Battelle, Llc Method for localizing and isolating an errant process step
US7873185B2 (en) * 2005-08-03 2011-01-18 Siemens Medical Solutions Usa, Inc. Method for detection and tracking of deformable objects
JP2007233871A (en) * 2006-03-02 2007-09-13 Fuji Xerox Co Ltd Image processor, control method for computer, and program
JP2008071790A (en) * 2006-09-12 2008-03-27 Sharp Corp Method of estimating failure step, device of estimating failure step, program, and recording medium
JP4867771B2 (en) * 2007-04-19 2012-02-01 パナソニック電工株式会社 Template matching device
JP2010008159A (en) * 2008-06-25 2010-01-14 Panasonic Electric Works Co Ltd Visual inspection processing method
JP5056695B2 (en) * 2008-09-24 2012-10-24 富士ゼロックス株式会社 Similar image presentation apparatus and program
JP2013167596A (en) * 2012-02-17 2013-08-29 Honda Motor Co Ltd Defect inspection device, defect inspection method, and program
JP5771561B2 (en) * 2012-05-30 2015-09-02 株式会社日立ハイテクノロジーズ Defect inspection method and defect inspection apparatus
JP5995756B2 (en) * 2013-03-06 2016-09-21 三菱重工業株式会社 Defect detection apparatus, defect detection method, and defect detection program

Also Published As

Publication number Publication date
JP2017096853A (en) 2017-06-01

Similar Documents

Publication Publication Date Title
CN109916906B (en) Defect detection device and method
US10572993B2 (en) Information processing apparatus, information processing method and recording medium
US10262410B2 (en) Methods and systems for inspecting goods
US11282186B2 (en) Anomaly detection using image-based physical characterization
US11397974B2 (en) Method and system for assessing quality of commodities
CN109492395B (en) Method, device and storage medium for detecting malicious program
Xu et al. Forensic detection of Gaussian low-pass filtering in digital images
JP6597972B2 (en) Image processing apparatus and image processing method
US9269017B2 (en) Cascaded object detection
JP6834126B2 (en) Information processing equipment, defect detection methods and programs
EP3660731B1 (en) Digitization of industrial inspection sheets by inferring visual relations
CN111191591A (en) Watermark detection method, video processing method and related equipment
US20210326615A1 (en) System and method for automatically detecting and repairing biometric crosslinks
EP3355240B1 (en) A method and a system for generating a multi-level classifier for image processing
WO2021199706A1 (en) Data classification device, data classification method, and data classification program
Zhu et al. Scene text detection via extremal region based double threshold convolutional network classification
KR102230559B1 (en) Method and Apparatus for Creating Labeling Model with Data Programming
US8977044B2 (en) Image processing apparatus for area separation of images, image processing method, and computer readable medium
JP7486574B2 (en) Scalable Structure Learning via Context-Free Recursive Document Decomposition
KR20210031444A (en) Method and Apparatus for Creating Labeling Model with Data Programming
JP7309101B2 (en) Attack detection device, hostile sample patch detection system, attack detection method, and attack detection program
KR20200143957A (en) Method and system for auto training for product inspection
US20230252768A1 (en) Method and system for dynamically generating annotated content for ar-vr applications
WO2022254858A1 (en) Inspection device, inspection method, and inspection program
JP2010182052A (en) Apparatus and program for processing image

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20181009

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20190731

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20190827

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20191023

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20200317

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20200515

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20201104

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20201225

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

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20210105

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20210118

R151 Written notification of patent or utility model registration

Ref document number: 6834126

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151