JP6584250B2 - Image classification method, classifier configuration method, and image classification apparatus - Google Patents

Image classification method, classifier configuration method, and image classification apparatus Download PDF

Info

Publication number
JP6584250B2
JP6584250B2 JP2015178300A JP2015178300A JP6584250B2 JP 6584250 B2 JP6584250 B2 JP 6584250B2 JP 2015178300 A JP2015178300 A JP 2015178300A JP 2015178300 A JP2015178300 A JP 2015178300A JP 6584250 B2 JP6584250 B2 JP 6584250B2
Authority
JP
Japan
Prior art keywords
classification
image
teacher
classifier
images
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
JP2015178300A
Other languages
Japanese (ja)
Other versions
JP2017054331A (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.)
Screen Holdings Co Ltd
Original Assignee
Screen Holdings 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 Screen Holdings Co Ltd filed Critical Screen Holdings Co Ltd
Priority to JP2015178300A priority Critical patent/JP6584250B2/en
Publication of JP2017054331A publication Critical patent/JP2017054331A/en
Application granted granted Critical
Publication of JP6584250B2 publication Critical patent/JP6584250B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Description

この発明は、教師画像を用いた機械学習により分類器を構成し、画像を自動分類する技術に関するものである。   The present invention relates to a technique for configuring a classifier by machine learning using a teacher image and automatically classifying images.

複数の画像を画像相互の類似度に応じて複数のカテゴリに自動分類する技術として、教師あり学習を用いたものがある。この技術では、事前に収集された教師画像の特徴量分布から各分類カテゴリの特徴量分布を推定し、誤分類を最小にするようなカテゴリ間境界を求めることで分類器を構築する。代表的な例としては、線形判別法やニューラルネットワーク、サポートベクタマシン(SVM)などが知られている。例えば特許文献1に記載の技術は、半導体基板やプリント基板等の欠陥を自動分類するものであり、予め用意された教師データに基づく機械学習によって生成された判別関数を用いて欠陥分類を行う。   As a technique for automatically classifying a plurality of images into a plurality of categories according to the degree of similarity between images, there is a technique using supervised learning. In this technique, the classifier is constructed by estimating the feature quantity distribution of each classification category from the feature quantity distribution of the teacher image collected in advance and obtaining the boundary between categories that minimizes misclassification. As typical examples, a linear discrimination method, a neural network, a support vector machine (SVM), and the like are known. For example, the technique described in Patent Document 1 automatically classifies defects such as semiconductor substrates and printed boards, and performs defect classification using a discriminant function generated by machine learning based on teacher data prepared in advance.

このような自動分類技術において誤分類を完全になくすことは困難であり、分類精度を向上させるための技術も種々提案されている。   In such an automatic classification technique, it is difficult to completely eliminate misclassification, and various techniques for improving the classification accuracy have been proposed.

特開2003−317083号公報JP 2003-317083 A

分類精度を向上させる手法の例として、複数の弱分類器を組み合わせたアンサンブル学習があり、例えばAdaBoostアルゴリズムがよく知られている。AdaBoostでは、学習に用いる事例の重みを適応的に更新してゆくことで汎化性能を高めることができるが、従来の学習アルゴリズムのうち各事例に対してこのような重み付けが可能なものは限定的であり、分類の目的に応じた任意の機械学習アルゴリズムに適用することができるものではない。   An example of a technique for improving the classification accuracy is ensemble learning in which a plurality of weak classifiers are combined. For example, the AdaBoost algorithm is well known. In AdaBoost, generalization performance can be improved by adaptively updating the weights of cases used for learning. However, there are only a limited number of conventional learning algorithms that can weight such cases. It cannot be applied to any machine learning algorithm according to the purpose of classification.

この発明は上記課題に鑑みなされたものであり、画像を自動分類するための教師画像を用いた分類器の構成に際し、任意の機械学習アルゴリズムに適用して優れた性能の分類器を構成することのできる技術を提供することを目的とする。   The present invention has been made in view of the above problems, and when a classifier using a teacher image for automatically classifying an image is configured, it is applied to an arbitrary machine learning algorithm to configure a classifier having excellent performance. It aims at providing the technology that can do.

この発明の一の態様は、P(Pは自然数)次元の特徴ベクトルによって表される教師画像と当該教師画像に付与される分類カテゴリとに関する情報を含む教師データを用いた機械学習の結果に基づき画像を自動分類する画像分類方法であって、上記目的を達成するため、複数の分類カテゴリの各々に、固有の識別番号を付与し、複数の前記教師画像に対応する前記教師データを用いた機械学習アルゴリズムを実行して分類器を構成する第1工程と、前記第1工程で構成された分類器により、前記教師画像の各々を複数の分類カテゴリに分類する第2工程と、前記教師画像の各々について、前記第2工程で付与された分類カテゴリと前記教師データにおいて予め付与されている分類カテゴリとを比較し、その結果に応じた数値を新たな特徴量として特徴ベクトルに追加することで、当該教師画像の特徴ベクトルの次元数を1増加させる第3工程とをこの順番でM(Mは2以上の整数)回実行して、入力ベクトルの次元が1ずつ異なるM組の分類器を準備し、ここで、前記第3工程では、前記第2工程で付与された分類カテゴリと前記教師データにおいて予め付与されている分類カテゴリとが異なる場合には、前記第2工程で付与された分類カテゴリの前記識別番号を前記新たな特徴量とし、前記第2工程で付与された分類カテゴリと前記教師データにおいて予め付与されている分類カテゴリとが一致する場合には、当該分類カテゴリの前記識別番号を中心とする所定の数値範囲内の不規則な数値を前記新たな特徴量とし、分類対象の画像について、P次元の特徴ベクトルをなすP種の特徴量を求め、当該画像の特徴ベクトルを、当該特徴ベクトルと同次元の入力ベクトルに対応する前記分類器により前記分類カテゴリのいずれかに分類する第4工程と、前記第4工程で分類された分類カテゴリの前記識別番号を新たな特徴量として特徴ベクトルに追加することで、当該画像の特徴ベクトルの次元数を1増加させる第5工程とをこの順番でM回実行して、M組の分類結果を取得し、前記M組の分類結果から選出した一の分類結果を、当該画像の分類結果として出力する。   One aspect of the present invention is based on the result of machine learning using teacher data including information related to a teacher image represented by a feature vector of P (P is a natural number) dimension and a classification category assigned to the teacher image. An image classification method for automatically classifying images, and in order to achieve the above object, a machine using the teacher data corresponding to a plurality of the teacher images by assigning a unique identification number to each of a plurality of category categories A first step of configuring a classifier by executing a learning algorithm; a second step of classifying each of the teacher images into a plurality of classification categories by the classifier configured in the first step; and For each, the classification category assigned in the second step is compared with the classification category assigned in advance in the teacher data, and a numerical value corresponding to the result is determined as a new feature amount. The third step of increasing the number of dimensions of the feature vector of the teacher image by 1 is executed M (M is an integer of 2 or more) times in this order, and the dimension of the input vector is 1 M different classifiers are prepared, and in the third step, when the classification category assigned in the second step is different from the classification category given in advance in the teacher data, When the identification number of the classification category assigned in the second step is the new feature amount, and the classification category assigned in the second step matches the classification category assigned in advance in the teacher data Then, an irregular numerical value within a predetermined numerical range centering on the identification number of the classification category is set as the new feature amount, and P types of P-type feature vectors are formed for the classification target image. A fourth step of obtaining the collected amount and classifying the feature vector of the image into any of the classification categories by the classifier corresponding to the input vector of the same dimension as the feature vector, and the classification in the fourth step By adding the identification number of the classification category as a new feature quantity to the feature vector, the fifth step of increasing the number of dimensions of the feature vector of the image by 1 is executed M times in this order, and M sets of classification A result is acquired, and one classification result selected from the M classification results is output as a classification result of the image.

また、この発明の他の態様は、画像を複数の分類カテゴリに自動分類するための分類器の構成方法であって、上記目的を達成するため、前記複数の分類カテゴリの各々に、固有の識別番号を付与し、P(Pは自然数)次元の特徴ベクトルによって表される複数の教師画像と、各教師画像に付与される分類カテゴリとに関する情報を含む教師データを取得し、前記教師画像に対応する前記教師データを用いた機械学習アルゴリズムを実行して分類器を構成する第1工程と、前記第1工程で構成された分類器により、前記教師画像の各々を複数の分類カテゴリに分類する第2工程と、前記教師画像の各々について、前記第2工程で付与された分類カテゴリと前記教師データにおいて予め付与されている分類カテゴリとを比較し、その結果に応じた数値を新たな特徴量として特徴ベクトルに追加することで、当該教師画像の特徴ベクトルの次元数を1つ増加させる第3工程とをこの順番でM(Mは2以上の整数)回実行して、入力ベクトルの次元が1ずつ異なるM組の分類器を構成し、前記第3工程では、前記第2工程で付与された分類カテゴリと前記教師データにおいて予め付与されている分類カテゴリとが異なる場合には、前記第2工程で付与された分類カテゴリの前記識別番号を前記新たな特徴量とし、前記第2工程で付与された分類カテゴリと前記教師データにおいて予め付与されている分類カテゴリとが一致する場合には、当該分類カテゴリの前記識別番号を中心とする所定の数値範囲内の不規則な数値を前記新たな特徴量とする。   According to another aspect of the present invention, there is provided a classifier configuration method for automatically classifying an image into a plurality of classification categories. In order to achieve the above object, each of the plurality of classification categories has a unique identification. Assigns a number, obtains teacher data including information on a plurality of teacher images represented by P (P is a natural number) -dimensional feature vector and a classification category assigned to each teacher image, and corresponds to the teacher image A first step of configuring a classifier by executing a machine learning algorithm using the teacher data and a classifier configured to classify each of the teacher images into a plurality of classification categories by the classifier configured in the first step. For each of the two teacher images, the classification category assigned in the second step is compared with the classification category assigned in advance in the teacher data, and according to the result By adding the value to the feature vector as a new feature quantity, the third step of increasing the number of dimensions of the feature vector of the teacher image by one is executed M (M is an integer of 2 or more) times in this order. , When M classifiers having different input vector dimensions are formed, and the classification category assigned in the second step is different from the classification category assigned in advance in the teacher data in the third step Includes the identification number of the classification category assigned in the second step as the new feature amount, and the classification category assigned in the second step matches the classification category assigned in advance in the teacher data. In this case, an irregular numerical value within a predetermined numerical range centering on the identification number of the classification category is set as the new feature amount.

このように構成された発明では、教師データを用いて学習した分類器によって教師画像自体が分類され、予め付与された分類カテゴリと異なる、つまり誤った分類結果が得られた教師画像については、その誤った分類カテゴリを示す識別番号が新たな特徴量として特徴ベクトルに追加される。一方、分類結果が予め付与された分類カテゴリと一致した場合には、当該分類カテゴリを示す識別番号の数値を中心とする所定数値範囲内の不規則な数値が新たな特徴量として特徴ベクトルに追加される。   In the invention configured as described above, the teacher image itself is classified by the classifier learned using the teacher data, and the teacher image that is different from the previously assigned classification category, that is, the erroneous classification result is obtained. An identification number indicating an incorrect classification category is added to the feature vector as a new feature amount. On the other hand, if the classification result matches a classification category assigned in advance, an irregular numerical value within a predetermined numerical range centering on the numerical value of the identification number indicating the classification category is added to the feature vector as a new feature amount. Is done.

新たな特徴量を創出して特徴ベクトルの次元を増やすのに際し、分類結果が誤っていた場合にはその誤った分類結果をそのまま新たな特徴量の値とする一方、分類結果が正しければその分類結果に若干の揺らぎを与えて新たな特徴量の値とすることで、誤分類の結果が分類性能の向上に寄与する特徴量として有効に機能することを本願発明者は見出した。誤分類結果を明確に後の学習に伝搬させる一方、正しい分類結果についてはより曖昧な形で伝搬させることで、間接的に事例に対する重み付けを行ったような効果が得られていると考えられる。   When creating a new feature quantity and increasing the dimension of the feature vector, if the classification result is incorrect, the incorrect classification result is used as a new feature value as it is. The inventor of the present application has found that the result of misclassification effectively functions as a feature amount contributing to improvement of the classification performance by giving a slight fluctuation to the result to be a new feature amount value. While misclassification results are clearly propagated to later learning, correct classification results are propagated in a more ambiguous manner, and it is considered that the effect of weighting cases indirectly is obtained.

このように、分類結果に応じた新たな特徴量を教師データの特徴ベクトルに追加しながら繰り返し学習を実行するという方法は、どのような学習アルゴリズムにも適用可能なものである。そして、このようにして機械学習を実行することにより、分類性能の優れた、より正確には汎化能力の高い分類器を構成することが可能となり、こうして得られた分類器を用いることで、未知の画像についても分類精度を高めることができる。   As described above, the method of repeatedly performing learning while adding a new feature amount corresponding to the classification result to the feature vector of the teacher data can be applied to any learning algorithm. And by executing machine learning in this way, it becomes possible to configure a classifier with excellent classification performance, more precisely a generalization ability, and by using the classifier thus obtained, Classification accuracy can also be improved for unknown images.

また、この発明のさらに他の態様は、教師画像となる複数の画像および分類対象となる画像を取得する画像取得手段と、上記した画像分類方法を実行して画像を分類する分類手段あるいは上記した分類器の構成方法により構成された分類器を用いて、画像を分類する分類手段と、出力された分類結果をユーザに報知する報知手段とを備える画像分類装置である。このように構成された発明では、上記方法により従来よりも分類性能が向上した分類器を用いて画像を分類することで、より高い分類精度で種々の画像を分類することが可能である。   According to still another aspect of the present invention, there are provided an image acquisition means for acquiring a plurality of images to be a teacher image and an image to be classified, a classification means for classifying an image by executing the image classification method described above, or the above-described An image classification apparatus comprising: a classification unit that classifies images using a classifier configured by a classifier configuration method; and a notification unit that notifies a user of an output classification result. In the invention configured as described above, it is possible to classify various images with higher classification accuracy by classifying images by using the classifier having improved classification performance compared to the conventional method by the above method.

以上のように、本発明によれば、教師あり学習により得られた分類器を用いて教師データを分類し、分類結果に応じた特徴量を各教師データに追加してさらに学習を実行することで、構成される分類器の分類性能を向上させることができる。この方法は任意の機械学習アルゴリズムに対し適用可能であり、当該アルゴリズムを用いた自動分類における分類精度を向上させることができる。   As described above, according to the present invention, teacher data is classified using a classifier obtained by supervised learning, and a feature amount corresponding to the classification result is added to each teacher data to further perform learning. Thus, the classification performance of the configured classifier can be improved. This method can be applied to any machine learning algorithm, and can improve classification accuracy in automatic classification using the algorithm.

この発明を好適に適用可能な検査システムの概略構成を示す図である。1 is a diagram showing a schematic configuration of an inspection system to which the present invention can be preferably applied. 欠陥検出装置の動作を示すフローチャートである。It is a flowchart which shows operation | movement of a defect detection apparatus. 欠陥分類装置の動作を示すフローチャートである。It is a flowchart which shows operation | movement of a defect classification device. 欠陥分類装置により実行される事前学習処理を示すフローチャートである。It is a flowchart which shows the prior learning process performed by the defect classification device. 特徴ベクトル更新処理を示すフローチャートである。It is a flowchart which shows the feature vector update process. 未分類の欠陥画像に対する分類処理を示すフローチャートである。It is a flowchart which shows the classification process with respect to an unclassified defect image. 本実施形態の効果を例示する図である。It is a figure which illustrates the effect of this embodiment.

図1はこの発明を好適に適用可能な検査システムの概略構成を示す図である。この検査システム1は、検査対象である半導体基板Sの外観に現れたピンホールや異物等の欠陥検査を行い、検出された欠陥の自動分類を行う検査システムである。検査システム1は、基板S上の検査対象領域から欠陥を検出する欠陥検出装置2と、欠陥検出装置2により検出された欠陥をより詳細に分析して欠陥の種類を特定する欠陥分類装置3とを備えている。欠陥検出装置2は基板Sの製造ラインに組み込まれ、検査システム1はいわゆるインライン型のシステムとなっている。   FIG. 1 is a diagram showing a schematic configuration of an inspection system to which the present invention can be preferably applied. This inspection system 1 is an inspection system that performs inspection of defects such as pinholes and foreign matters appearing on the appearance of a semiconductor substrate S to be inspected, and automatically classifies detected defects. The inspection system 1 includes a defect detection device 2 that detects a defect from an inspection target region on the substrate S, a defect classification device 3 that analyzes the defect detected by the defect detection device 2 in more detail and identifies the type of defect, and It has. The defect detection device 2 is incorporated in the production line of the substrate S, and the inspection system 1 is a so-called in-line system.

欠陥検出装置2は、基板S上の検査対象領域の画像を取得する画像取得ユニット20と、画像取得ユニット20からの画像データを解析して欠陥検出を行う検出ユニット21とを備えている。画像取得ユニット20は、例えばCCDセンサまたはCMOSセンサなどの撮像素子を有し基板S上の検査対象領域を撮像することにより画像データを取得する撮像部201、基板Sを保持するステージ202、および、撮像部201に対してステージ202を相対的に移動させるステージ駆動部203を備えている。ステージ駆動部203はボールねじ、ガイドレールおよびモータなどにより構成される。撮像部201およびステージ駆動部203は検出ユニット21に設けられた機構制御部211により制御されており、機構制御部211からの制御指令に応じて動作することで、基板S上の検査対象領域を撮像する。   The defect detection apparatus 2 includes an image acquisition unit 20 that acquires an image of an inspection target area on the substrate S, and a detection unit 21 that analyzes the image data from the image acquisition unit 20 and detects a defect. The image acquisition unit 20 has an imaging element such as a CCD sensor or a CMOS sensor, for example, and acquires an image data by acquiring an image of an inspection target area on the substrate S, a stage 202 that holds the substrate S, and A stage driving unit 203 that moves the stage 202 relative to the imaging unit 201 is provided. The stage driving unit 203 includes a ball screw, a guide rail, a motor, and the like. The imaging unit 201 and the stage driving unit 203 are controlled by a mechanism control unit 211 provided in the detection unit 21, and operate according to a control command from the mechanism control unit 211, so that an inspection target region on the substrate S is changed. Take an image.

撮像部201による撮像で得られた画像データに対して欠陥検出部212が適宜のデータ処理を施して欠陥検出を行う。欠陥検出部212は、撮像部201から与えられた画像データに対して適宜のデータ処理、例えばノイズ除去処理や平滑化処理などを施し、こうして処理された画像データに基づき欠陥検出を行う。より具体的には、実際の基板Sにおいて撮像された画像と、記憶部213に予め記憶された無欠陥の基板の画像とを比較して、その差異が予め定められた基準を超える場合には当該画像に欠陥が含まれると判定する。欠陥検出部212は、検出した欠陥の画像データをインターフェース(I/F)214を介して欠陥分類装置3に送信する。   The defect detection unit 212 performs appropriate data processing on the image data obtained by imaging by the imaging unit 201 to detect defects. The defect detection unit 212 performs appropriate data processing such as noise removal processing or smoothing processing on the image data given from the imaging unit 201, and performs defect detection based on the image data thus processed. More specifically, when an image captured on the actual substrate S is compared with an image of a defect-free substrate stored in advance in the storage unit 213, and the difference exceeds a predetermined reference It is determined that the image includes a defect. The defect detection unit 212 transmits the detected defect image data to the defect classification device 3 via the interface (I / F) 214.

欠陥分類装置3は、欠陥検出装置2から与えられる欠陥データに基づき、検出された欠陥の種別を判定する。すなわち、欠陥分類装置3は欠陥検出装置2から与えられる欠陥画像データに基づいて当該欠陥が属すべき分類カテゴリへと欠陥を自動分類(ADC;Automatic Defect Classification)する機能を有している。この欠陥分類装置3は、この発明にかかる画像分類装置の一実施形態を実装した装置である。以下に説明するように、一般的なパーソナルコンピュータが有するハードウェア資源を用いて、本発明にかかる各処理を記述した制御プログラムを実行させることにより、欠陥分類装置3としての機能を実現することが可能である。   The defect classification device 3 determines the type of the detected defect based on the defect data given from the defect detection device 2. That is, the defect classification device 3 has a function of automatically classifying defects (ADC: Automatic Defect Classification) into classification categories to which the defect belongs based on the defect image data given from the defect detection device 2. This defect classification device 3 is a device on which an embodiment of an image classification device according to the present invention is mounted. As described below, the function as the defect classification device 3 can be realized by executing a control program describing each process according to the present invention using hardware resources of a general personal computer. Is possible.

欠陥分類装置3は、予め読み込まれた制御プログラムを実行することにより、図1に示す各機能ブロックをハードウェアおよびソフトウェアにより実現し、後述する各種処理を実行する。欠陥分類装置3は、欠陥検出装置2から欠陥画像データを受信するためのインターフェース(I/F)31、欠陥画像データに基づく自動分類により、当該欠陥の種別を判定する欠陥分類部(ADC)32を備えている。インターフェース31は例えばLAN(Local Area Network)を介して他の外部機器と通信が可能となっている。   The defect classification device 3 executes each control block shown in FIG. 1 by hardware and software by executing a control program read in advance, and executes various processes described later. The defect classification device 3 includes an interface (I / F) 31 for receiving defect image data from the defect detection device 2, and a defect classification unit (ADC) 32 that determines the type of the defect by automatic classification based on the defect image data. It has. The interface 31 can communicate with other external devices via, for example, a LAN (Local Area Network).

欠陥検出装置2から与えられる画像データおよび欠陥分類部32における処理過程で生じる種々の処理データは必要に応じて記憶部33に随時保存される。欠陥分類部32は、与えられた欠陥画像データに基づき特徴量算出部34が算出した複数種の特徴量の値に基づき、当該欠陥画像を、欠陥種別に対応して予め設定された複数の分類カテゴリのいずれかに分類する。   The image data given from the defect detection device 2 and various processing data generated in the process in the defect classification unit 32 are stored in the storage unit 33 as needed. The defect classifying unit 32 classifies the defect image into a plurality of classifications set in advance corresponding to the defect type based on the values of the plurality of types of feature amounts calculated by the feature amount calculating unit 34 based on the given defect image data. Sort into one of the categories.

さらに、欠陥分類装置3は、ユーザからの操作入力を受け付けるキーボードおよびマウスなどの入力受付部35および操作手順や処理結果等のユーザ向け視覚情報を表示する表示部36を備えている。   Furthermore, the defect classification device 3 includes an input receiving unit 35 such as a keyboard and a mouse that receives an operation input from a user, and a display unit 36 that displays visual information for the user such as an operation procedure and a processing result.

欠陥分類部32は、検出された欠陥をSVM(サポートベクタマシン;Support Vector Machine)、ニューラルネットワーク、決定木、判別分析、ロジスティック回帰等適宜の学習アルゴリズムを利用して分類する処理をソフトウェア的に実行する。具体的には、欠陥検査装置2または他の外部装置から与えられて記憶部33に記憶保存された欠陥画像データと、当該欠陥画像が分類されるべき分類カテゴリに関するユーザからの教示情報とに基づいて予め適宜の学習アルゴリズムによる機械学習を行っておく。そして、未分類の欠陥画像に対応する画像データが新たに与えられると、学習結果に基づく自動分類を行って新たな欠陥画像をいずれかの分類カテゴリに分類する。   The defect classification unit 32 executes a process of classifying detected defects using an appropriate learning algorithm such as SVM (Support Vector Machine), neural network, decision tree, discriminant analysis, logistic regression, and the like in software. To do. Specifically, based on the defect image data given from the defect inspection apparatus 2 or another external apparatus and stored in the storage unit 33, and teaching information from the user regarding the classification category into which the defect image should be classified. Machine learning using an appropriate learning algorithm in advance. When new image data corresponding to an unclassified defect image is given, automatic classification based on the learning result is performed to classify the new defect image into any one of the classification categories.

図2は欠陥検出装置の動作を示すフローチャートである。欠陥検出装置2は、検査対象基板Sを撮像し、その撮像結果から欠陥を検出するための動作として以下の欠陥検出処理を実行する。最初に検査対象基板Sが画像取得ユニット20のステージ202にロードされると(ステップS101)、機構制御部211が撮像部201およびステージ駆動部203を制御して、基板S上の所定の検査対象位置を撮像し画像を取得する(ステップS102)。こうして得られた画像データに対して、欠陥検出部212は、必要に応じて例えば輝度調整やノイズ除去等の処理を行う。さらに、予め記憶部213に記憶されている無欠陥の基板の画像(基準画像)のうち、当該検査対象位置に対応する部分の画像データを読み出して、撮像により得られた画像データとの画素単位の差分を算出する(ステップS103)。   FIG. 2 is a flowchart showing the operation of the defect detection apparatus. The defect detection apparatus 2 images the inspection target substrate S, and executes the following defect detection processing as an operation for detecting defects from the imaging result. When the inspection target substrate S is first loaded on the stage 202 of the image acquisition unit 20 (step S101), the mechanism control unit 211 controls the imaging unit 201 and the stage driving unit 203 to perform a predetermined inspection target on the substrate S. The position is imaged and an image is acquired (step S102). For the image data obtained in this way, the defect detection unit 212 performs processes such as brightness adjustment and noise removal as necessary. Further, the image data of a portion corresponding to the inspection target position in the image of the defect-free substrate (reference image) stored in advance in the storage unit 213 is read and pixel unit with the image data obtained by imaging Is calculated (step S103).

撮像された画像に欠陥が含まれなければ予め記憶されていた無欠陥の画像との差は小さい一方、欠陥が含まれていれば大きな差異が現れる。このことを利用して、両者の差分を求めることで欠陥の有無を判定することが可能である。具体的には、得られた差分画像に対して適宜の平滑化処理および二値化処理を行って(ステップS104)、有意な差が認められる領域があればその部分を欠陥部分として抽出する(ステップS105)。欠陥が検出された画像については(ステップS106)、当該画像を欠陥画像として、インターフェース214を介して欠陥分類装置3に送信する(ステップS107)。上記処理を、検査対象位置を順次変えながら基板Sの全体について行うことで(ステップS108)、基板Sの検査が完了する。   If the captured image does not include a defect, the difference from the previously stored defect-free image is small, but if a defect is included, a large difference appears. By utilizing this fact, it is possible to determine the presence or absence of a defect by obtaining the difference between the two. Specifically, appropriate smoothing processing and binarization processing are performed on the obtained difference image (step S104), and if there is a region where a significant difference is recognized, that portion is extracted as a defective portion ( Step S105). For an image in which a defect is detected (step S106), the image is transmitted as a defect image to the defect classification device 3 via the interface 214 (step S107). By performing the above processing on the entire substrate S while sequentially changing the inspection target position (step S108), the inspection of the substrate S is completed.

欠陥検出装置2は、検査対象基板Sの各位置を検査して欠陥の有無を判定する。一方、欠陥分類装置3は、検出された欠陥の種別を判定して、欠陥の発生傾向を分析してその結果を製造ラインにフィードバックしたり、欠陥検出装置2による欠陥検出処理の処理内容の調整を行うのに用いられる。検出された欠陥の分析を欠陥分類装置3により行うことで、欠陥検出装置2は欠陥検出に特化した処理を実行することができるので、高速での欠陥検出が可能となる。   The defect detection device 2 inspects each position of the inspection target substrate S to determine whether there is a defect. On the other hand, the defect classification device 3 determines the type of detected defect, analyzes the tendency of occurrence of the defect, and feeds back the result to the production line, or adjusts the processing content of the defect detection processing by the defect detection device 2 Used to do By analyzing the detected defect by the defect classification device 3, the defect detection device 2 can execute a process specialized for defect detection, so that a defect can be detected at high speed.

図3は欠陥分類装置の動作を示すフローチャートである。上記した通り、欠陥分類装置3は欠陥検出装置2から出力される欠陥画像を、その欠陥種別に応じた分類カテゴリに分類する。より具体的には、欠陥分類部32が予め収集された欠陥画像データに基づき事前学習(後述)を行っておき(ステップS201)、未分類の欠陥画像が欠陥検出装置2から新たに与えられると(ステップS202)、特徴量算出部34が当該欠陥画像を特徴付ける複数の特徴量の値を算出する(ステップS203)。そして、欠陥分類部32が、算出された特徴量の値に基づき、事前学習により構成された分類器を用いて当該欠陥画像を複数の分類カテゴリのいずれかに分類する(ステップS204)。   FIG. 3 is a flowchart showing the operation of the defect classification apparatus. As described above, the defect classification device 3 classifies the defect image output from the defect detection device 2 into a classification category corresponding to the defect type. More specifically, when the defect classification unit 32 performs pre-learning (described later) based on the defect image data collected in advance (step S201), an unclassified defect image is newly given from the defect detection device 2. (Step S202), the feature quantity calculation unit 34 calculates a plurality of feature quantity values that characterize the defect image (Step S203). Then, based on the calculated feature value, the defect classification unit 32 classifies the defect image into one of a plurality of classification categories using a classifier configured by prior learning (step S204).

分類カテゴリは当該基板Sにおいて発生し得る複数の欠陥種別に対応して複数種が予め設定されており、例えば異物、傷、気泡、ピンホール、パターン断線、短絡などが代表的なものであるが、これらに限定されるものではない。以下の処理において、分類カテゴリは上記した欠陥種別の名称ではなく、分類カテゴリと1対1に対応させて予め付与されたカテゴリ番号によって特定されるものとする。カテゴリ番号としては整数列における連番が用いられる。例えば、欠陥種別「異物」、「傷」、「気泡」、…に対応する各分類カテゴリに対し、それぞれカテゴリ番号「1」、「2」、「3」、…を付すことで、これらが区別される。   A plurality of types of classification categories are set in advance corresponding to a plurality of types of defects that may occur in the substrate S. For example, foreign materials, scratches, bubbles, pinholes, pattern disconnections, short circuits, and the like are representative. However, it is not limited to these. In the following processing, the classification category is not specified by the above-described defect type name, but by a category number assigned in advance in a one-to-one correspondence with the classification category. A serial number in an integer sequence is used as the category number. For example, the category numbers “1”, “2”, “3”,... Are assigned to the classification categories corresponding to the defect types “foreign matter”, “scratch”, “bubble”,. Is done.

図4は欠陥分類装置により実行される事前学習処理を示すフローチャートである。事前学習処理は、種々の欠陥を撮像した教師画像と、ユーザから教示される、当該教師画像がどの分類カテゴリに分類すべきものであるかを示す教示情報とに基づいて行われる。欠陥の典型的な外観を示す教師画像が多いほど学習効果が向上し、分類精度を高めることが可能である。   FIG. 4 is a flowchart showing a pre-learning process executed by the defect classification apparatus. The pre-learning process is performed based on a teacher image obtained by imaging various defects and teaching information indicating which classification category the teacher image should be classified, which is taught by the user. The more teacher images that show the typical appearance of the defect, the better the learning effect and the higher the classification accuracy.

最初に、教師画像として用いられる複数の欠陥画像が収集される(ステップS301)。ここでは欠陥検出装置2から出力される欠陥画像を教師画像としてこれを順次記憶部33に保存することで収集を行うものとするが、例えば予め用意された画像ライブラリや外部のストレージに収集された教師画像データを取得する態様であってもよい。当然ながら、欠陥画像は、分類すべきカテゴリの数よりも多数が必要である。以下では、収集された教師画像の総数をNとし、教師画像のそれぞれに符号T(1),T(2),…,T(N)を付してこれらを区別することとする。   First, a plurality of defect images used as teacher images are collected (step S301). Here, the defect images output from the defect detection device 2 are collected by sequentially storing them as teacher images in the storage unit 33. For example, the defect images are collected in an image library prepared in advance or in an external storage. It may be an aspect in which teacher image data is acquired. Of course, more defect images are required than the number of categories to be classified. In the following, the total number of collected teacher images is N, and the teacher images are distinguished from each other by adding symbols T (1), T (2),..., T (N).

次に、収集された教師画像の各々について、当該教師画像が分類されるべき分類カテゴリを指定するための教示入力をユーザから受け付ける(ステップS302)。ユーザからの入力は入力受付部35により受け付けられる。これにより、教師画像と教示された分類カテゴリとが対応付けられた教師データが作成される。   Next, for each collected teacher image, a teaching input for specifying a classification category in which the teacher image is to be classified is received from the user (step S302). Input from the user is received by the input receiving unit 35. Thereby, teacher data in which the teacher image is associated with the taught classification category is created.

全ての教師画像に対し教示入力がなされると、各教師画像の特徴ベクトルが算出される(ステップS303)。具体的には、教師画像の外観的特徴を表す特徴量が複数種算出され、これら複数の特徴量からなる特徴ベクトルが求められる。以下、教師画像T(n)を表す特徴ベクトルを符号V(n)により表すこととする(n=1,2,…,N)。また、このときの特徴ベクトルの次元を符号P(Pは2以上の整数)とする。つまり、各教師画像はP種の特徴量により表される。なお、教示入力の受付および特徴ベクトル算出の処理順序は上記の逆でもよい。   When teaching input is made for all teacher images, the feature vector of each teacher image is calculated (step S303). Specifically, a plurality of types of feature amounts representing appearance features of the teacher image are calculated, and a feature vector composed of the plurality of feature amounts is obtained. Hereinafter, a feature vector representing the teacher image T (n) is represented by a symbol V (n) (n = 1, 2,..., N). The dimension of the feature vector at this time is a code P (P is an integer of 2 or more). That is, each teacher image is represented by P types of feature amounts. It should be noted that the processing order for receiving the teaching input and calculating the feature vector may be reversed.

続いて、ループ処理のための内部パラメータiの値が0に設定され(ステップS304)、ステップS305〜S309のループ処理が実行される。まず、SVM、ニューラルネットワーク、決定木、判別分析、ロジスティック回帰等の適宜の学習アルゴリズムにより、教師データを用いた事例学習が実行されて分類器が構成される。この分類器を符号C(i)により表す(ステップS305)。第1回目のループでは、分類器C(0)が構成される。   Subsequently, the value of the internal parameter i for loop processing is set to 0 (step S304), and the loop processing of steps S305 to S309 is executed. First, case learning using teacher data is executed by an appropriate learning algorithm such as SVM, neural network, decision tree, discriminant analysis, logistic regression, etc., and a classifier is configured. This classifier is represented by code C (i) (step S305). In the first loop, a classifier C (0) is configured.

次に、構成された分類器C(i)により、当該分類器C(i)自身を構成するのに用いられた教師画像が分類される(ステップS306)。理想的には、各教師画像はユーザが教示入力により付与した分類カテゴリに分類されるはずである。しかしながら、収集された教師画像およびユーザによる教示入力、分類に用いる特徴量の選択などの適否により、分類結果は必ずしもそうならない。すなわち、分類器による分類結果の正答率は、一般には100%に満たない。つまり、1回の事例学習で最適な分類器が得られる可能性は必ずしも高くない。   Next, the teacher image used to configure the classifier C (i) itself is classified by the configured classifier C (i) (step S306). Ideally, each teacher image should be classified into a classification category given by the user by teaching input. However, the classification result is not necessarily so depending on the suitability of the collected teacher image, the teaching input by the user, the selection of the feature amount used for classification, and the like. That is, the correct answer rate of the classification result by the classifier is generally less than 100%. That is, the possibility that an optimal classifier can be obtained by one case study is not necessarily high.

ステップS305〜S309のループ処理に対して、ループを脱出するための脱出条件が予め定められている(ステップS307)。脱出条件としては例えば、予め教示された分類に対する分類器による分類結果の正答率が所定値以上であること、ループ処理を実行しても分類結果に有意な変化がない(例えば誤答数の変化がない)こと、ループ処理の実行回数が予め設定された上限回数に達したことなどが適用可能であり、これらのいずれかの要件が満たされたとき、脱出条件が成立したものとされる。なお脱出条件はこれらに限定されるものではない。   With respect to the loop processing in steps S305 to S309, an exit condition for exiting the loop is determined in advance (step S307). The escape conditions include, for example, that the correct answer rate of the classification result by the classifier for the class taught in advance is equal to or higher than a predetermined value, and that the classification result does not change significantly even when the loop process is executed (for example, the change in the number of incorrect answers) That the number of executions of the loop processing has reached a preset upper limit number of times is applicable, and when any of these requirements is satisfied, the escape condition is satisfied. The escape conditions are not limited to these.

脱出条件が成立すると(ステップS307においてYES)、ループ処理は終了する。上記したように、実際には1回目の処理で脱出条件が成立することはほとんどないと考えられる。脱出条件が未成立であれば(ステップS307においてNO)、各教師画像の特徴ベクトルが、分類結果に基づく後述する方法により更新される(ステップS308)。そして、パラメータiが1つインクリメントされ(ステップS309)、処理はステップS305に戻る。   When the escape condition is satisfied (YES in step S307), the loop process ends. As described above, it is considered that the escape condition is hardly satisfied in the first process. If the escape condition is not satisfied (NO in step S307), the feature vector of each teacher image is updated by a method described later based on the classification result (step S308). Then, the parameter i is incremented by 1 (step S309), and the process returns to step S305.

脱出条件が成立するまで上記のループ処理が繰り返し実行される。ステップS307において脱出条件が成立していたとき、そのときのパラメータiから1を減じた値がパラメータMとして保存されて(ステップS310)、事前学習処理は完了する。   The above loop processing is repeatedly executed until the escape condition is satisfied. When the escape condition is satisfied in step S307, a value obtained by subtracting 1 from the parameter i at that time is stored as the parameter M (step S310), and the pre-learning process is completed.

0を初期値としてループ処理の実行ごとにインクリメントされるパラメータiの値は、ステップS305が実行された回数に1を加えた値となっている。したがって、これから1を減じたパラメータMの値は、ステップS305の実行回数に対応する。ステップS305を実行する度に分類器C(i)が構成されるため、全体では符号C(0)〜C(M−1)で表されるM組の分類器が構成されることとなる。教師データが同一であればこれらの分類器も全て同じとなるが、教師データに含まれる特徴ベクトルが都度更新されているため、分類器C(i)(i=0,1,…,M−1)は互いに異なる。   The value of the parameter i incremented each time the loop process is executed with 0 as an initial value is a value obtained by adding 1 to the number of times step S305 is executed. Therefore, the value of the parameter M obtained by subtracting 1 from this corresponds to the number of executions of step S305. Since the classifier C (i) is configured every time step S305 is executed, M sets of classifiers represented by codes C (0) to C (M−1) are configured as a whole. If the teacher data is the same, these classifiers are all the same. However, since the feature vector included in the teacher data is updated each time, the classifier C (i) (i = 0, 1,..., M− 1) are different from each other.

図5は特徴ベクトル更新処理を示すフローチャートである。この特徴ベクトル更新処理は、図4のフローチャートにおけるステップS308に対応する処理であり、ループ処理の実行回数に応じてパラメータiは種々の値を取り得るが、図4から明らかなように、図5に示す一連の処理においてはパラメータiの値は固定されている。また、以下では、分類器C(i)により分類された分類カテゴリに対応するカテゴリ番号を符号L(i)により表す。   FIG. 5 is a flowchart showing the feature vector update process. This feature vector update process is a process corresponding to step S308 in the flowchart of FIG. 4, and the parameter i can take various values depending on the number of executions of the loop process. As is apparent from FIG. In the series of processes shown in FIG. 8, the value of the parameter i is fixed. In the following, the category number corresponding to the classification category classified by the classifier C (i) is represented by the symbol L (i).

最初に、処理に用いられる閾値が0以上1未満の範囲で適宜に設定される(ステップS401)。閾値の適切な決め方については後述する。次に、教師画像を特定するための内部パラメータnの値が1に設定され(ステップS402)、収集された教師画像のうち1つの画像T(n)が選択される(ステップS403)。この時点では、N枚の教師画像のうち符号T(1)が付与されたものが選択される。選択された教師画像T(n)について、予めユーザにより付与された分類カテゴリと、分類器C(i)を用いた自動分類の結果とが比較される(ステップS404)。   First, the threshold used for processing is appropriately set within a range of 0 or more and less than 1 (step S401). An appropriate method for determining the threshold will be described later. Next, the value of the internal parameter n for specifying the teacher image is set to 1 (step S402), and one image T (n) is selected from the collected teacher images (step S403). At this time, among the N teacher images, the one assigned with the code T (1) is selected. For the selected teacher image T (n), the classification category previously given by the user is compared with the result of automatic classification using the classifier C (i) (step S404).

自動分類により付与された分類カテゴリがユーザにより付与された分類カテゴリと一致しない、すなわち分類結果が誤っていたときには(ステップS404においてNO)、分類器C(i)が出力した分類カテゴリのカテゴリ番号L(i)が新たな特徴量の値として設定され(ステップS412)、この特徴量が、当該教師画像T(n)の特徴ベクトルV(n)に新たな要素として追加される(ステップS409)。これにより、特徴ベクトルV(n)の次元は1つ増加する。   If the classification category assigned by automatic classification does not match the classification category assigned by the user, that is, if the classification result is incorrect (NO in step S404), the category number L of the classification category output by the classifier C (i). (I) is set as a new feature value (step S412), and this feature value is added as a new element to the feature vector V (n) of the teacher image T (n) (step S409). As a result, the dimension of the feature vector V (n) increases by one.

一方、自動分類により付与された分類カテゴリがユーザにより付与された分類カテゴリと一致する、すなわち分類結果が正答であったときには(ステップS404においてYES)、0以上1未満の乱数が発生され(ステップS405)、その乱数が予め定められた閾値と比較される(ステップS406)。発生された乱数が閾値より小さい場合には(ステップS406においてYES)、誤分類であった場合と同様に、分類器C(i)が出力した分類カテゴリのカテゴリ番号L(i)が新たな特徴量の値とされ(ステップS411)、当該教師画像T(n)の特徴ベクトルV(n)に新たな要素として追加される(ステップS409)。   On the other hand, when the classification category assigned by automatic classification matches the classification category assigned by the user, that is, the classification result is a correct answer (YES in step S404), a random number between 0 and 1 is generated (step S405). ), And the random number is compared with a predetermined threshold (step S406). If the generated random number is smaller than the threshold value (YES in step S406), the category number L (i) of the classification category output by the classifier C (i) is a new feature as in the case of misclassification. The amount is set as a value (step S411), and is added as a new element to the feature vector V (n) of the teacher image T (n) (step S409).

発生された乱数が閾値以上である場合には(ステップS406においてNO)、さらに(−1)以上(+1)未満の乱数が発生され(ステップS407)、分類器C(i)が出力した分類カテゴリのカテゴリ番号L(i)にこの乱数が加算された値が新たな特徴量の値とされ(ステップS408)、当該特徴量が特徴ベクトルV(n)の新たな要素として追加される(ステップS409)。このとき追加される特徴量の値は、分類器C(i)が出力した分類カテゴリのカテゴリ番号の値L(i)を中心とする区間[L(i)−1,L(i)+1)内の乱数となる。   If the generated random number is greater than or equal to the threshold (NO in step S406), a random number greater than or equal to (−1) and less than (+1) is generated (step S407), and the classification category output by classifier C (i) The value obtained by adding the random number to the category number L (i) of the first is used as a new feature value (step S408), and the feature is added as a new element of the feature vector V (n) (step S409). ). The value of the feature amount added at this time is a section [L (i) -1, L (i) +1) centered on the category number value L (i) of the classification category output by the classifier C (i). It becomes the random number in.

なお、ステップS401、S405〜S406の処理は、新たな特徴量の値を決定するための2つのルールを一定の確率で選択的に適用するためのものである。すなわち、分類器C(i)による分類結果が正答であったとき、特徴ベクトルに追加される新たな特徴量の値を決める際のルールとしては、出力されたカテゴリ番号Liをそのまま特徴量の値とする、または、出力されたカテゴリ番号Liを中心とする所定範囲内の乱数とする、という2種類がある。ステップS405において発生される乱数と閾値との大小関係に応じて一方のルールが選択されるため、これら2つのルールがどのような確率で適用されるかが、閾値の設定値により決まることとなる。   The processes in steps S401 and S405 to S406 are for selectively applying two rules for determining a new feature value with a certain probability. That is, when the classification result by the classifier C (i) is a correct answer, as a rule for determining a new feature value to be added to the feature vector, the output category number Li is directly used as the feature value. Or a random number within a predetermined range centered on the output category number Li. Since one rule is selected in accordance with the magnitude relationship between the random number generated in step S405 and the threshold value, the probability that these two rules will be applied is determined by the set value of the threshold value. .

つまり、2つのルールの適用確率を調整するためのパラメータとして閾値が設定され乱数が用いられているが、閾値と乱数との大小関係に物理的な意味はない。したがって、ステップS406における「YES」と「NO」とは逆であってもよいし、上記のように2つのルールが一定の確率で選択的に適用され、かつその確率を変化させることが可能であれば、その具体的手法は任意である。   That is, although a threshold value is set as a parameter for adjusting the application probability of the two rules and a random number is used, the magnitude relationship between the threshold value and the random number has no physical meaning. Therefore, “YES” and “NO” in step S406 may be reversed, and the two rules are selectively applied with a certain probability as described above, and the probability can be changed. If there are, the specific method is arbitrary.

このように、教師画像T(n)を表す特徴ベクトルV(n)は、分類器C(i)が出力した分類結果に応じた数値を有する新たな特徴量が要素として追加されることで、次元が1つ増加した新たな特徴ベクトルに更新される。   In this way, the feature vector V (n) representing the teacher image T (n) is added with a new feature amount having a value corresponding to the classification result output from the classifier C (i) as an element. The dimension is updated to a new feature vector increased by one.

パラメータnが教師画像の総数Nとなるまで(ステップS410)、パラメータnの値を1ずつインクリメントしながら(ステップS412)、ステップS403〜S409のループ処理を繰り返すことにより、N枚の教師画像T(1)〜T(N)に対応する特徴ベクトルV(1)〜V(n)がそれぞれ更新される。   Until the parameter n reaches the total number N of teacher images (step S410), the parameter n is incremented by 1 (step S412), and the loop processing of steps S403 to S409 is repeated to obtain N teacher images T ( Feature vectors V (1) to V (n) corresponding to 1) to T (N) are updated.

必要に応じて閾値を修正することが可能となっており(ステップS413)、閾値の修正が必要であれば、ステップS401に戻って上記処理が再実行される。このとき、先の閾値設定に基づき実行された特徴ベクトルの更新結果は破棄され、もとの次元数の特徴ベクトルに対して新たな更新処理が行われる。   The threshold value can be corrected as necessary (step S413). If the threshold value needs to be corrected, the process returns to step S401 and the above process is re-executed. At this time, the update result of the feature vector executed based on the previous threshold setting is discarded, and a new update process is performed on the feature vector having the original number of dimensions.

上記のように、特徴ベクトル更新処理が実行されることにより、特徴ベクトルV(n)の次元が1つ増加する。したがって、図4に示されるループ処理において、第i回目の処理と第(i+1)回目の処理との間では、ステップS305の事例学習に与えられる入力ベクトルの次元が1つ異なっている。そのため、分類器C(i)と分類器C(i+1)とは、それぞれ異なる次元の入力ベクトルに対応した異なる分類器となっている。   As described above, when the feature vector update process is executed, the dimension of the feature vector V (n) increases by one. Therefore, in the loop process shown in FIG. 4, the dimension of the input vector given to the case learning in step S305 is one different between the i-th process and the (i + 1) -th process. Therefore, the classifier C (i) and the classifier C (i + 1) are different classifiers corresponding to input vectors of different dimensions.

分類器C(i)と比較すると、分類器C(i+1)では対応する入力ベクトルの要素が1つ増えており、増やされた要素は分類器C(i)が出力した分類結果(カテゴリ番号)に基づく値を有する特徴量である。つまり、分類器C(i+1)に教師データとして与えられる特徴ベクトルは、直前に構成された分類器C(i)による分類結果に関する情報を特徴量として含む。そのため、ステップS305における事例学習では、それまでに実行された分類結果が特徴量として伝搬している。   Compared with the classifier C (i), the classifier C (i + 1) has one more corresponding input vector element, and the increased element is the classification result (category number) output by the classifier C (i). Is a feature quantity having a value based on. That is, the feature vector given as the teacher data to the classifier C (i + 1) includes information on the classification result by the classifier C (i) configured immediately before as a feature amount. Therefore, in the case study in step S305, the classification results executed so far are propagated as feature quantities.

分類器C(i+1)を構成するための事例学習においては、過去に構成された分類器C(0)〜C(i)における教師画像T(n)それぞれの分類結果を反映した特徴量を含む特徴ベクトルV(n)が、教師データとして用いられる。分類結果に基づき追加される特徴量の値は、ユーザによる教示と異なる誤答であった場合には誤った分類結果そのものを表すカテゴリ番号である一方、正答であった場合には、分類されたカテゴリ番号を中心として一定の揺らぎを有する値である。   The case study for configuring the classifier C (i + 1) includes a feature amount reflecting the classification result of each of the teacher images T (n) in the classifiers C (0) to C (i) configured in the past. The feature vector V (n) is used as teacher data. The feature value added based on the classification result is a category number indicating the incorrect classification result itself if it is an incorrect answer different from the instruction from the user, while it is classified if it is a correct answer. It is a value having a certain fluctuation around the category number.

このため、誤った分類結果は以後の事例学習に対し強い特徴量として伝搬する一方、正しい分類結果はより弱い特徴量として伝搬する。これにより、事例学習を繰り返すに際して各事例に重み付けをしたような効果が間接的に得られるため、分類器の性能が向上することが期待される。本願発明者の実験によれば、分類結果が正答であった場合の特徴量の値への揺らぎの与え方、より具体的にはステップS401(図5)における閾値の設定を適切なものとすることにより、優れた分類性能を有する分類器を得ることが可能であることがわかっている。   For this reason, an incorrect classification result propagates as a strong feature quantity with respect to subsequent case learning, while a correct classification result propagates as a weak feature quantity. As a result, the effect of weighting each case is indirectly obtained when repeating case learning, and therefore the performance of the classifier is expected to be improved. According to the experiment of the present inventor, how to give fluctuation to the value of the feature amount when the classification result is a correct answer, more specifically, setting the threshold value in step S401 (FIG. 5) is appropriate. Thus, it has been found that it is possible to obtain a classifier having excellent classification performance.

原理的には、次のようにして閾値を最適化することができる。分類器C(i)による教師画像の分類後に特徴ベクトル更新処理(図5)を実行し、更新された特徴ベクトルを用いて事例学習を行うことで分類器C(i+1)を得る。得られた分類器C(i+1)を用いて教師画像を分類し、その分類成績を評価する。具体的には、N枚の教師画像のうち分類器C(i+1)がユーザ教示と一致する分類結果を出力したものの割合(正答率)を求める。このような処理を、特徴ベクトル更新処理における閾値の設定値を種々に変更しながら繰り返し実行し、分類器C(i+1)の分類成績が最良となる閾値の設定値を決定する。   In principle, the threshold can be optimized as follows. After classifying the teacher image by the classifier C (i), the feature vector update process (FIG. 5) is executed, and class learning is performed using the updated feature vector to obtain the classifier C (i + 1). The teacher image is classified using the obtained classifier C (i + 1), and the classification result is evaluated. Specifically, the ratio (correct answer rate) of N teacher images from which the classifier C (i + 1) outputs a classification result that matches the user teaching is obtained. Such a process is repeatedly executed while variously changing the threshold setting value in the feature vector updating process, and the threshold setting value with the best classification result of the classifier C (i + 1) is determined.

なお、以下のようにすることで、最良に近い分類性能をより簡便に得られることがわかっている。すなわち、本願発明者の知見によれば、図5に示す特徴ベクトル更新処理において、ステップS404において「NO」と判断された教師画像の数と、ステップS406において「YES」と判断された教師画像の数とがほぼ同数であるとき、分類器C(i+1)の分類成績が最良となる傾向が見られる。つまり、分類器C(i)の分類結果が正しかった教師画像のうち、分類されたカテゴリ番号そのものが特徴量の値とされるケースと、分類器C(i)の分類結果が誤っていたために誤ったカテゴリ番号が特徴量の値とされるケースとがほぼ同数となるようにすればよい。   In addition, it turns out that the classification performance close | similar to the best can be obtained more simply by doing as follows. That is, according to the knowledge of the present inventor, in the feature vector update process shown in FIG. 5, the number of teacher images determined as “NO” in step S404 and the number of teacher images determined as “YES” in step S406. When the number is almost equal, the classification result of the classifier C (i + 1) tends to be the best. That is, among the teacher images in which the classification result of the classifier C (i) is correct, the classified category number itself is the feature value, and the classification result of the classifier C (i) is incorrect. What is necessary is just to make it the same number as the case where an incorrect category number is made into the value of a feature-value.

分類器C(i)の分類結果が正しかったとき、分類されたカテゴリ番号そのものが特徴量の値とされるケースと、該カテゴリ番号に乱数を加えた値が特徴量の値とされるケースとの比率は、ステップS401で設定される閾値に依存する。したがって、分類されたカテゴリ番号が特徴量の値とされるケースが誤答数とほぼ等しくなるように閾値を調節することで、閾値を最適化することができる。   When the classification result of the classifier C (i) is correct, the classified category number itself is used as the feature value, and the value obtained by adding a random number to the category number is used as the feature value. The ratio depends on the threshold value set in step S401. Therefore, the threshold value can be optimized by adjusting the threshold value so that the case where the classified category number is the value of the feature amount is approximately equal to the number of erroneous answers.

実際の運用は例えば以下の通りである。図5の特徴ベクトル更新処理において、ステップS401で閾値を適宜の値に仮設定してステップS402〜S412を実行する。このとき、ステップS403において分類結果が教示と一致しないと判断された事例の数、つまり誤答数と、分類結果が教示と一致する正答のうちステップS406において乱数が閾値より小さいと判断された事例の数とをそれぞれ計数しておく。   The actual operation is as follows, for example. In the feature vector update process of FIG. 5, the threshold value is temporarily set to an appropriate value in step S401, and steps S402 to S412 are executed. At this time, out of the number of cases in which the classification result is determined not to match the teaching in step S403, that is, the number of wrong answers and the correct answer in which the classification result matches the teaching, the case in which the random number is determined to be smaller than the threshold in step S406. And count the number of each.

ステップS413では、上記の両事例の数を比較し、その差(または比)が所定の許容範囲以内であれば閾値の修正は不要と判断される(ステップS413においてNO)。一方、許容範囲を超える差異がある場合には閾値の修正が必要と判断され(ステップS413においてYES)、ステップS401に戻って閾値の値が変更されて再度処理が実行される。閾値は、ステップS406において「YES」と判断される事例が誤答数よりも多ければより小さな値に、誤答数よりも少ない場合にはより大きな値に変更される。このようにすることで、分類結果が教示と一致する正答のうちステップS406において乱数が閾値より小さいと判断される事例の数が誤答数とほぼ一致することとなり、閾値が最適化される。   In step S413, the number of both cases is compared, and if the difference (or ratio) is within a predetermined allowable range, it is determined that the threshold value need not be corrected (NO in step S413). On the other hand, if there is a difference exceeding the allowable range, it is determined that the threshold needs to be corrected (YES in step S413), the process returns to step S401, the threshold value is changed, and the process is executed again. The threshold value is changed to a smaller value if the number of cases judged “YES” in step S406 is larger than the number of erroneous answers, and to a larger value if the number is less than the number of erroneous answers. By doing in this way, the number of cases in which the random number is determined to be smaller than the threshold value in step S406 out of the correct answers whose classification results match the teachings substantially matches the number of erroneous answers, and the threshold value is optimized.

引き続き実行される事例学習では、分類器C(i)よりも分類性能が改善された分類器C(i+1)を得ることができる。図4のループ処理でこのような改善を繰り返すことにより、より分類性能の優れた分類器を得ることが可能である。しかしながら、ループ処理の実行回数が増えるにつれて処理に要する時間も長くなるのに対し、分類性能の改善度合いは一般には次第に頭打ちとなる。このため、ある程度の改善効果が得られた時点でループ処理が終了するように、ステップS307における脱出条件が前述のように定められている。   In the case learning that is subsequently performed, a classifier C (i + 1) with improved classification performance over the classifier C (i) can be obtained. By repeating such an improvement in the loop processing of FIG. 4, it is possible to obtain a classifier with better classification performance. However, as the number of executions of the loop process increases, the time required for the process becomes longer. On the other hand, the degree of improvement in the classification performance generally reaches its peak gradually. For this reason, the escape condition in step S307 is determined as described above so that the loop process is completed when a certain improvement effect is obtained.

上記のようにして、本実施形態の事前学習処理では、入力ベクトルの次元が1ずつ異なるM組の分類器C(0)〜C(M−1)が構成される。このうち分類器C(0)はステップS303(図4)で求められた教師画像の特徴ベクトルと同じP次元の入力ベクトルに対応しており、他の分類器C(1)、C(2)、…、C(M−1)はそれぞれ(P+1)、(P+2)、…、(P+M−1)次元の入力ベクトルに対応するものとなっている。このように構成されたM組の分類器を用いて未分類の欠陥画像を分類する方法について、次に説明する。   As described above, in the pre-learning process of the present embodiment, M sets of classifiers C (0) to C (M-1) having different input vector dimensions by 1 are configured. Among these, the classifier C (0) corresponds to the same P-dimensional input vector as the feature vector of the teacher image obtained in step S303 (FIG. 4), and the other classifiers C (1) and C (2). ,..., C (M−1) correspond to (P + 1), (P + 2),..., (P + M−1) -dimensional input vectors, respectively. Next, a method for classifying unclassified defect images using the M sets of classifiers configured as described above will be described.

図6は未分類の欠陥画像に対する分類処理を示すフローチャートである。図6に示す処理は、図3のステップS202〜S204に相当するものである。まず、分類対象となる未分類の欠陥画像を取得する(ステップS501)。この処理ステップは図3のステップS202に相当する。以下、取得された分類対象画像を符号Ixにより表す。例えば、欠陥検出装置2により検査対象基板Sにおいて検出された欠陥を含む画像が、分類対象画像Ixとされる。   FIG. 6 is a flowchart showing a classification process for an unclassified defect image. The process shown in FIG. 6 corresponds to steps S202 to S204 in FIG. First, an unclassified defect image to be classified is acquired (step S501). This processing step corresponds to step S202 in FIG. Hereinafter, the acquired classification target image is represented by reference numeral Ix. For example, an image including a defect detected on the inspection target substrate S by the defect detection apparatus 2 is set as the classification target image Ix.

次に、分類対象画像Ixの特徴ベクトルVxが求められる(ステップS502)。この処理ステップは図3のステップS203に相当するものであり、分類対象画像Ixについて教師画像と同じP種類の特徴量が算出され、P次元の特徴ベクトルVxが特定される。   Next, a feature vector Vx of the classification target image Ix is obtained (step S502). This processing step corresponds to step S203 in FIG. 3, and the same P types of feature amounts as the teacher image are calculated for the classification target image Ix, and the P-dimensional feature vector Vx is specified.

続くステップS503〜S509が、図3のステップS204に相当している。ステップS503では、M組の分類器から1つを選択するための内部パラメータjの値が初期値0に設定され(ステップS503)、これにより特定される分類器C(j)、この場合には分類器C(0)を用いて分類対象画像Ixが分類される(ステップS504)。そして、分類器C(j)が出力した分類結果、すなわち当該分類対象画像Ixが分類されるべき分類カテゴリに対応するカテゴリ番号が、分類対象画像Ixを表す特徴ベクトルVxに新たな要素として追加される(ステップS505)。これにより、特徴ベクトルVxが更新され、その次元が1つ増加する。   Subsequent steps S503 to S509 correspond to step S204 in FIG. In step S503, the value of the internal parameter j for selecting one from the M classifiers is set to an initial value 0 (step S503), and the classifier C (j) identified by this is set. In this case, The classification target image Ix is classified using the classifier C (0) (step S504). Then, the classification result output from the classifier C (j), that is, the category number corresponding to the classification category to which the classification target image Ix should be classified is added as a new element to the feature vector Vx representing the classification target image Ix. (Step S505). As a result, the feature vector Vx is updated, and its dimension increases by one.

パラメータjの値を1ずつインクリメントしながら(ステップS506)、パラメータjの値が分類器の数Mに達するまで(ステップS507)、ステップS504、S505が繰り返される。分類器C(j)による分類が行われる度に、その結果が(P+j)次元の特徴ベクトルVxに新たな特徴量として追加され、特徴ベクトルは次元が1増加して(P+j+1)次元となる。そして、(P+j+1)次元の入力ベクトルに対応する分類器C(J+1)に入力されて再度分類される。   While incrementing the value of parameter j by 1 (step S506), steps S504 and S505 are repeated until the value of parameter j reaches the number M of classifiers (step S507). Each time classification is performed by the classifier C (j), the result is added as a new feature amount to the (P + j) -dimensional feature vector Vx, and the dimension of the feature vector is increased by 1 to become (P + j + 1) -dimensional. Then, it is input to the classifier C (J + 1) corresponding to the (P + j + 1) -dimensional input vector and classified again.

このような処理が繰り返されることで、M組の分類器から出力されたM組の分類結果が得られる。各分類器の分類性能が異なるため、これらM組の分類結果は必ずしも同じとはならない。これらの分類結果の中からいずれかが、最終的な分類結果として選出され(ステップS508)、ユーザに対し報知出力される(ステップS509)。最終結果の選出方法としては、例えば次のようにすることができる。   By repeating such processing, M sets of classification results output from the M sets of classifiers are obtained. Since the classification performance of each classifier is different, these M sets of classification results are not necessarily the same. One of these classification results is selected as the final classification result (step S508), and a notification is output to the user (step S509). For example, the final result can be selected as follows.

第1に、最後の分類器C(M−1)により出力された分類結果を最終結果とすることが考えられる。前記したように、分類結果に応じて特徴ベクトルを更新しながら新たな分類器を構成してゆくことで、分類器の分類性能が次第に向上する。したがって、一般には後に構成される分類器ほど優れた分類性能を有していると期待される。このことから、最後の分類器C(M−1)が分類した分類カテゴリを最終結果とすることが考えられる。   First, it is conceivable that the classification result output by the last classifier C (M−1) is the final result. As described above, the classification performance of the classifier is gradually improved by configuring a new classifier while updating the feature vector according to the classification result. Therefore, it is generally expected that the classifier configured later has superior classification performance. From this, it can be considered that the classification category classified by the last classifier C (M-1) is the final result.

第2に、M組の分類結果において最も出現頻度の高い分類カテゴリを最終結果とすることが考えられる。つまり、M組の分類器による分類結果の多数決を取ることで最終結果を決定する方法である。分類結果として特定の分類カテゴリが多数回出現することは、当該分類カテゴリの妥当性を示すものと言えるからである。   Secondly, it is conceivable that the classification category having the highest appearance frequency in the M classification results is the final result. That is, the final result is determined by taking the majority of the classification results by the M classifiers. This is because that a specific classification category appears many times as a classification result indicates the validity of the classification category.

第3に、M組の分類結果それぞれに適宜の重み付けを与え、重みの合計が最も大きい分類カテゴリを最終結果とすることが考えられる。具体的には、M組の分類器それぞれについて教師データに対する正答率、すなわちN枚の教師画像のうちユーザによる教示と一致する分類結果が出力されたものの割合を評価する。そして、正答率の高い分類器ほど大きくなるような重み付けを各分類器に与え、分類カテゴリごとに、当該分類カテゴリを分類結果として出力した分類器の重みを合計する。合計値が最も大きい分類カテゴリが、最終的な分類結果となる。正答率の高い分類器が出力した結果は比較的信頼性が高いと推定されるから、このような重みを合計する方法で最終結果を選出することも合理的と言える。   Third, it is conceivable that an appropriate weight is given to each of the M classification results, and the classification category having the largest weight is the final result. Specifically, the correct answer rate with respect to the teacher data for each of the M classifiers, that is, the ratio of the N teacher images to which the classification result that matches the teaching by the user is output is evaluated. Then, a weight that increases as the classifier having a higher correct answer rate is given to each classifier, and the weights of the classifiers that output the classification category as a classification result are totaled for each classification category. The classification category having the largest total value is the final classification result. Since the result output by the classifier having a high correct answer rate is estimated to be relatively reliable, it can be said that it is reasonable to select the final result by the method of summing the weights.

なお、本願発明者の知見では、特徴ベクトル更新処理において閾値が適切に設定されていれば、後に例示するように、上記した第1の方法で十分に高精度な分類結果を得ることが可能である。   According to the knowledge of the inventor of the present application, if the threshold value is appropriately set in the feature vector update process, it is possible to obtain a sufficiently accurate classification result by the above-described first method, as will be exemplified later. is there.

また、ステップS509における報知出力の態様は任意であるが、例えば、最終的な分類結果(カテゴリ番号)に対応する欠陥種別を当該分類対象画像とともに表示部36に表示することで、分類結果をユーザに報知することができる。   In addition, although the manner of the notification output in step S509 is arbitrary, for example, by displaying the defect type corresponding to the final classification result (category number) on the display unit 36 together with the classification target image, the classification result is displayed to the user. Can be notified.

図7は本実施形態の効果を例示する図である。図7(a)〜図7(c)は、事例学習により構成された分類器による分類結果をユーザが事前に教示した分類カテゴリと比較対照した表であり、コンフュージョン・マトリクスとも呼ばれるものである。本願発明者は、5115枚の欠陥画像を用い、これらを教師画像として線形判別分析を行って得た分類器により、教師画像の再分類を行った。このときに構成された分類器は上記実施形態における分類器C(0)に相当する。再分類の結果をコンフュージョン・マトリクスとして図7(a)に示す。   FIG. 7 is a diagram illustrating the effect of this embodiment. FIG. 7A to FIG. 7C are tables comparing and comparing the classification results obtained by the classifier constituted by the case learning with the classification categories taught in advance by the user, and are also called a confusion matrix. . The inventor of the present application reclassified the teacher image using a classifier obtained by performing linear discriminant analysis using 5115 defect images as the teacher images. The classifier configured at this time corresponds to the classifier C (0) in the above embodiment. FIG. 7A shows the result of reclassification as a confusion matrix.

表中左端の「教示」と記載された行見出しはユーザにより教示されたカテゴリ番号を示し、最上段の「ADC」と記載された列見出しは分類器により分類されたカテゴリ番号を示している。数字「1」、「2」、「3」は3種類の分類カテゴリのそれぞれに付されたカテゴリ番号である。ユーザがカテゴリ番号「1」と教示した画像が1578枚あり、そのうち分類器C(0)がユーザの教示通りに正しく分類した正答数が1427枚である。したがって、ユーザ教示によるカテゴリ番号「1」に対する分類器C(0)の再現率(Recall)は90.4%である。分類器C(0)は、他の画像のうち150枚をカテゴリ番号「2」に、1枚をカテゴリ番号「3」に誤分類した。   The row heading described as “teach” at the left end of the table indicates the category number taught by the user, and the column heading described as “ADC” at the top indicates the category number classified by the classifier. The numbers “1”, “2”, and “3” are category numbers assigned to the three types of classification categories. There are 1578 images taught by the user as category number “1”, and the number of correct answers correctly classified by the classifier C (0) as taught by the user is 1427. Therefore, the recall (Recall) of the classifier C (0) for the category number “1” taught by the user is 90.4%. The classifier C (0) misclassified 150 of the other images as category number “2” and 1 as category number “3”.

同様に、ユーザがカテゴリ番号「2」を付与した2849枚の画像のうち分類器C(0)による正答数は2354枚であり、再現率は82.6%である。また、ユーザがカテゴリ番号「3」を付与した688枚の画像のうち分類器C(0)による正答数は644枚であり、再現率は93.9%である。表を横方向に見ることでこれらのことがわかる。   Similarly, the number of correct answers by the classifier C (0) out of 2849 images assigned by the user with the category number “2” is 2354, and the recall is 82.6%. The number of correct answers by the classifier C (0) is 644 out of 688 images to which the user has assigned the category number “3”, and the recall is 93.9%. These can be seen by looking at the table horizontally.

一方、表を縦方向に見て分類器C(0)が出力した分類結果に着目すると、分類器C(0)がカテゴリ番号「1」に分類した画像は1692枚あり、そのうちユーザ教示と一致したのが1427枚である。したがって、カテゴリ番号「1」に対する精度(precision)は84.3%である。同様に、カテゴリ番号「2」、カテゴリ番号「3」に対する精度はそれぞれ92.5%、73.7%である。そして、全5115枚の画像のうちユーザ教示と分類結果とが一致した正答数は4427枚であり、正確度(accuracy)は86.5%である。   On the other hand, looking at the classification result output by the classifier C (0) when the table is viewed in the vertical direction, there are 1692 images classified by the classifier C (0) into the category number “1”, of which match the user teaching. It was 1427 sheets. Therefore, the precision for the category number “1” is 84.3%. Similarly, the accuracy for category number “2” and category number “3” is 92.5% and 73.7%, respectively. Of the total 5115 images, the number of correct answers that matched the user teaching and the classification result is 4427, and the accuracy is 86.5%.

次に、分類器C(0)により出力された分類結果(カテゴリ番号)の正誤に応じた特徴ベクトル更新処理(図5)によって各教師画像の特徴ベクトルに新たな特徴量を追加し、これを教師データとして線形判別分析により新たな分類器を構成した。この分類器は上記実施形態における分類器C(1)に相当する。分類器C(1)を用いて教師画像を再分類した結果を図7(b)に示す。再現率および精度を見ると低下する項目もあるが全体としては図7(a)よりも改善されており、正確度については図7(a)に示す結果に対し0.4ポイントの向上が見られる。   Next, a new feature quantity is added to the feature vector of each teacher image by the feature vector update process (FIG. 5) according to the correctness of the classification result (category number) output by the classifier C (0). A new classifier was constructed by linear discriminant analysis as teacher data. This classifier corresponds to the classifier C (1) in the above embodiment. FIG. 7B shows the result of reclassifying the teacher image using the classifier C (1). Although there are items that decrease when looking at the recall and accuracy, the overall improvement is better than that in FIG. 7A, and the accuracy is improved by 0.4 points from the result shown in FIG. 7A. It is done.

さらに、分類器C(1)により出力された分類結果(カテゴリ番号)に基づいて特徴ベクトル更新処理を実行して各教師画像の特徴ベクトルに新たな特徴量を追加し、これを教師データとして線形判別分析により新たな分類器を構成した。この分類器は上記実施形態における分類器C(2)に相当する。分類器C(2)を用いて教師画像を分類した結果を図7(c)に示す。図7(b)に示す結果に比べ、正確度がさらに0.4ポイント向上している。   Furthermore, a feature vector update process is executed based on the classification result (category number) output by the classifier C (1) to add a new feature amount to the feature vector of each teacher image, and this is linearly used as teacher data. A new classifier was constructed by discriminant analysis. This classifier corresponds to the classifier C (2) in the above embodiment. FIG. 7C shows the result of classifying the teacher image using the classifier C (2). Compared with the result shown in FIG. 7B, the accuracy is further improved by 0.4 points.

このように、分類器により分類された結果に基づく新たな特徴量を追加することで教師データを更新し、それに基づく事例学習により新たな分類器を構成するという分類器の構成方法を採ることで、より分類性能の高い分類器が得られることがわかる。このような手法を採り入れるに際して学習アルゴリズムそのものを変更する必要はないため、種々の機械学習アルゴリズムに対してこの手法を適用することが可能である。   In this way, by adopting a classifier configuration method in which teacher data is updated by adding a new feature amount based on the result classified by the classifier, and a new classifier is configured by case learning based on it. It can be seen that a classifier with higher classification performance can be obtained. Since it is not necessary to change the learning algorithm itself when adopting such a method, this method can be applied to various machine learning algorithms.

以上説明したように、上記実施形態では、図4のステップS305、S306、S308がそれぞれ本発明の「第1工程」、「第2工程」、「第3工程」に相当している。また、図6のステップS504、S505がそれぞれ本発明の「第4工程」、「第5工程」に相当している。また、分類カテゴリを表すカテゴリ番号が、本発明の「識別番号」に相当している。   As described above, in the above embodiment, steps S305, S306, and S308 in FIG. 4 correspond to the “first step”, “second step”, and “third step” of the present invention, respectively. Steps S504 and S505 in FIG. 6 correspond to the “fourth step” and “fifth step” of the present invention, respectively. The category number representing the classification category corresponds to the “identification number” of the present invention.

また、上記実施形態の検査システム1が本発明の「画像分類装置」に相当しており、欠陥検出装置2および欠陥分類装置3がそれぞれ本発明の「画像取得手段」および「分類手段」として機能している。また、欠陥分類装置3が単独でも本発明の「画像分類装置」としての機能を有しており、この場合、インターフェース31が本発明の「画像取得手段」として機能し、欠陥分類部32が本発明の「分類手段」として機能する。また、表示部36が本発明の「報知手段」として機能している。   The inspection system 1 of the above embodiment corresponds to the “image classification device” of the present invention, and the defect detection device 2 and the defect classification device 3 function as the “image acquisition unit” and “classification unit” of the present invention, respectively. is doing. Further, the defect classification device 3 alone has the function as the “image classification device” of the present invention. In this case, the interface 31 functions as the “image acquisition means” of the present invention, and the defect classification unit 32 is It functions as the “classification means” of the invention. The display unit 36 functions as the “notification unit” of the present invention.

なお、本発明は上記した実施形態に限定されるものではなく、その趣旨を逸脱しない限りにおいて上述したもの以外に種々の変更を行うことが可能である。例えば、上記実施形態では半導体基板を撮像して得られた欠陥画像の分類に本発明を適用しているが、本発明の手法に基づく分類対象となる画像は、このような基板上の欠陥を撮像したものに限定されず任意である。例えば、培地中で培養された細胞や細菌等を撮像した画像の分類にも、本発明を適用することが可能である。   The present invention is not limited to the above-described embodiment, and various modifications other than those described above can be made without departing from the spirit of the present invention. For example, in the above-described embodiment, the present invention is applied to classification of defect images obtained by imaging a semiconductor substrate. However, an image to be classified based on the method of the present invention shows such defects on the substrate. It is arbitrary without being limited to what was imaged. For example, the present invention can be applied to classification of images obtained by imaging cells or bacteria cultured in a medium.

また例えば、上記実施形態の検査システム1では、欠陥検出装置2と欠陥分類装置3とが別体として構成されているが、これらは一体のものであってもよい。また、上記実施形態の欠陥分類装置3では、教師画像に基づく事例学習と、その結果に基づく未知の画像の分類とが同一の装置により実行されているが、これらは個別の装置で実行されてもよい。この場合、1つの装置で行われた事例学習により構成された分類器が他の装置に実装されて画像の分類が行われることになる。   Further, for example, in the inspection system 1 of the above embodiment, the defect detection device 2 and the defect classification device 3 are configured as separate bodies, but these may be integrated. In the defect classification device 3 of the above embodiment, case learning based on a teacher image and classification of an unknown image based on the result are performed by the same device, but these are performed by individual devices. Also good. In this case, the classifier constituted by the case learning performed in one apparatus is mounted in another apparatus, and the image is classified.

また例えば、上記実施形態の検査システムは撮像機能を有する欠陥検出装置2を備えるが、自らは撮像機能を備えず、専ら外部から画像データを受け取って処理を行う装置にも、本発明を適用することが可能である。   Further, for example, the inspection system of the above embodiment includes the defect detection apparatus 2 having an imaging function, but the present invention is also applied to an apparatus that does not have an imaging function itself and exclusively receives image data from outside and performs processing. It is possible.

以上、具体的な実施形態を例示して説明してきたように、この発明にかかる画像分類方法では、例えば、M組の分類器を用いて求められたM組の分類結果のうちM回目に取得された分類結果を出力するように構成することができる。先の分類結果を特徴量に加えながら事例学習を繰り返すことで、分類器の分類性能が次第に向上することが期待される。よって、最後に取得された分類器の結果を最終的な分類の結果として出力することで、良好な分類精度を得ることができる。   As described above, the specific embodiment has been described by way of example. In the image classification method according to the present invention, for example, the Mth classification result is obtained from the M classification results obtained by using the M classifiers. The classified result can be output. It is expected that the classification performance of the classifier will gradually improve by repeating the case learning while adding the previous classification result to the feature quantity. Therefore, it is possible to obtain a good classification accuracy by outputting the finally obtained classifier result as the final classification result.

また例えば、M組の分類結果の多数決により決定される分類結果を出力とするように構成されてもよい。分類器それぞれの分類結果は信頼性が低いものであったとしても、それらの多数決により出力が決定されることで、より精度の高い分類結果を安定して得ることができる。   Further, for example, the classification result determined by the majority of the M classification results may be output. Even if the classification results of the classifiers are low in reliability, the output is determined by their majority vote, so that a more accurate classification result can be stably obtained.

また例えば、複数の分類カテゴリの各々に、整数列において連続する数値が識別番号として付与され、数値範囲の広さが2より小さくなるように設定されてもよい。連続する整数が識別番号として用いられる場合、隣り合う識別番号間の差は1である。この場合、特徴量として正しい分類結果に加える揺らぎの範囲が2より大きいと、元の分類結果が何であったかがわからなくなり、特徴量として適切に機能しなくなるおそれがある。揺らぎの範囲が2より小さくなるようにすることで、元の分類結果に関する情報が失われることなく後の学習に伝搬されることになり、分類性能の向上に寄与することができる。   Further, for example, a numerical value that is continuous in an integer string may be assigned as an identification number to each of a plurality of classification categories, and the range of the numerical value range may be set to be smaller than 2. When consecutive integers are used as identification numbers, the difference between adjacent identification numbers is 1. In this case, if the range of fluctuation added to the correct classification result as the feature quantity is larger than 2, it may not be understood what the original classification result was and may not function properly as the feature quantity. By setting the fluctuation range to be smaller than 2, information on the original classification result is propagated to later learning without being lost, which can contribute to improvement of classification performance.

また例えば、第3工程において、第2工程で付与された分類カテゴリと教師データにおいて予め付与されている分類カテゴリとが一致する場合、当該分類カテゴリの識別番号と同じ数値に先述の数値範囲内で発生させた乱数を加えた値を新たな特徴量としてもよい。こうすることで、特徴量の値に適切かつ不規則な揺らぎを与え、分類器の分類性能の向上を図ることができる。   Further, for example, in the third step, when the classification category assigned in the second step matches the classification category assigned in advance in the teacher data, the same numerical value as the identification number of the classification category falls within the numerical range described above. A value obtained by adding the generated random number may be used as a new feature amount. By doing so, it is possible to give an appropriate and irregular fluctuation to the value of the feature value, and to improve the classification performance of the classifier.

また例えば、第3工程において、第2工程で付与された分類カテゴリと教師データにおいて予め付与されている分類カテゴリとが一致する場合、所定の確率で、当該分類カテゴリの識別番号と同じ数値を新たな特徴量とするように構成されてもよい。本願発明者の知見によれば、分類器により求められた分類カテゴリと教示された分類カテゴリとが一致する場合でも、一定の割合で当該分類カテゴリに対応する識別番号をそのまま新たな特徴量の値とすることで、分類性能を効果的に向上させることが可能である。   Also, for example, in the third step, when the classification category assigned in the second step matches the classification category assigned in advance in the teacher data, a new value that is the same as the identification number of the classification category is newly added with a predetermined probability. It may be configured to have various feature amounts. According to the knowledge of the present inventor, even when the classification category obtained by the classifier and the taught classification category match, the identification number corresponding to the classification category is a new feature value as it is at a certain ratio. By doing so, it is possible to effectively improve the classification performance.

また例えば、第2工程において、教師画像のうち予め付与されている分類カテゴリとは異なる分類結果となった画像の数を誤答数と呼ぶとき、第2工程における誤答数が、前回に実行した第2工程における誤答数と同じになれば、第1ないし第3工程の繰り返しを終了するように構成されてもよい。第1工程ないし第3工程を繰り返し実行することで分類性能の向上が見込めるが、処理時間も長くなる。誤答数の変化がなくなったことを以って繰り返しを終了することで、処理時間をむやみに長くすることなく一定以上の分類性能の分類器を得ることが可能である。   Also, for example, when the number of images that have a classification result different from the classification category assigned in advance in the second step is referred to as the number of erroneous answers, the number of erroneous answers in the second step is executed last time. If it becomes the same as the number of wrong answers in the second step, the repetition of the first to third steps may be terminated. Repeated execution of the first to third steps can improve the classification performance, but the processing time also becomes longer. By ending the repetition with the change in the number of erroneous answers eliminated, it is possible to obtain a classifier with a certain level of classification performance without unnecessarily increasing the processing time.

また、この発明にかかる画像分類装置では、例えば、画像取得手段が撮像機能を有するものであってもよい。このような構成によれば、画像の取得から分類までを一体の装置で実現することが可能である。   In the image classification device according to the present invention, for example, the image acquisition means may have an imaging function. According to such a structure, it is possible to implement | achieve from acquisition of an image to classification | category with an integrated apparatus.

この発明は、教師画像を用いた機械学習により分類器を構成し、該分類器を用いて未知の画像を分類する技術分野に好適に適用可能であり、適用対象となる学習アルゴリズムとしては任意のものを使用可能である。   The present invention can be suitably applied to a technical field in which a classifier is configured by machine learning using a teacher image and an unknown image is classified using the classifier, and any learning algorithm to be applied can be applied. Things can be used.

1 検査システム(画像分類装置)
2 欠陥検出装置(画像取得手段)
3 欠陥分類装置(分類手段、画像分類装置)
31 インターフェース(画像取得手段)
32 欠陥分類部(分類手段)
36 表示部(報知手段)
S305(第1工程)
S306(第2工程)
S308(第3工程)
S504(第4工程)
S505(第5工程)
1 Inspection system (image classification device)
2 Defect detection device (image acquisition means)
3. Defect classification device (classification means, image classification device)
31 Interface (Image acquisition means)
32 Defect classification part (classification means)
36 Display section (notification means)
S305 (first step)
S306 (second step)
S308 (third step)
S504 (4th process)
S505 (5th process)

Claims (11)

P(Pは自然数)次元の特徴ベクトルによって表される教師画像と当該教師画像に付与される分類カテゴリとに関する情報を含む教師データを用いた機械学習の結果に基づき画像を自動分類する画像分類方法において、
複数の分類カテゴリの各々に、固有の識別番号を付与し、
複数の前記教師画像に対応する前記教師データを用いた機械学習アルゴリズムを実行して分類器を構成する第1工程と、
前記第1工程で構成された分類器により、前記教師画像の各々を複数の分類カテゴリに分類する第2工程と、
前記教師画像の各々について、前記第2工程で付与された分類カテゴリと前記教師データにおいて予め付与されている分類カテゴリとを比較し、その結果に応じた数値を新たな特徴量として特徴ベクトルに追加することで、当該教師画像の特徴ベクトルの次元数を1増加させる第3工程と
をこの順番でM(Mは2以上の整数)回実行して、入力ベクトルの次元が1ずつ異なるM組の分類器を準備し、
ここで、前記第3工程では、前記第2工程で付与された分類カテゴリと前記教師データにおいて予め付与されている分類カテゴリとが異なる場合には、前記第2工程で付与された分類カテゴリの前記識別番号を前記新たな特徴量とし、前記第2工程で付与された分類カテゴリと前記教師データにおいて予め付与されている分類カテゴリとが一致する場合には、当該分類カテゴリの前記識別番号を中心とする所定の数値範囲内の不規則な数値を前記新たな特徴量とし、
分類対象の画像について、P次元の特徴ベクトルをなすP種の特徴量を求め、
当該画像の特徴ベクトルを、当該特徴ベクトルと同次元の入力ベクトルに対応する前記分類器により前記分類カテゴリのいずれかに分類する第4工程と、
前記第4工程で分類された分類カテゴリの前記識別番号を新たな特徴量として特徴ベクトルに追加することで、当該画像の特徴ベクトルの次元数を1増加させる第5工程と
をこの順番でM回実行して、M組の分類結果を取得し、
前記M組の分類結果から選出した一の分類結果を、当該画像の分類結果として出力する画像分類方法。
An image classification method for automatically classifying images based on the result of machine learning using teacher data including information on a teacher image represented by a feature vector of P (P is a natural number) dimension and a classification category assigned to the teacher image In
A unique identification number is assigned to each of a plurality of classification categories,
A first step of configuring a classifier by executing a machine learning algorithm using the teacher data corresponding to a plurality of the teacher images;
A second step of classifying each of the teacher images into a plurality of classification categories by the classifier configured in the first step;
For each of the teacher images, the classification category assigned in the second step is compared with the classification category assigned in advance in the teacher data, and a numerical value corresponding to the result is added as a new feature amount to the feature vector. Thus, the third step of increasing the number of dimensions of the feature vector of the teacher image by 1 is executed M (M is an integer of 2 or more) times in this order, and M sets of input vectors whose dimensions are different by 1 Prepare a classifier,
Here, in the third step, when the classification category given in the second step is different from the classification category given in advance in the teacher data, the classification category given in the second step When the classification number assigned in the second step and the classification category assigned in advance in the teacher data match with the identification number as the new feature amount, the identification number of the classification category is the center. An irregular numerical value within a predetermined numerical value range as the new feature amount,
For the images to be classified, P type feature amounts forming a P-dimensional feature vector are obtained,
A fourth step of classifying the feature vector of the image into one of the classification categories by the classifier corresponding to an input vector of the same dimension as the feature vector;
By adding the identification number of the classification category classified in the fourth step to the feature vector as a new feature amount, the fifth step of increasing the number of dimensions of the feature vector of the image by M is performed M times in this order. Execute to get the classification results of M sets,
An image classification method for outputting one classification result selected from the M classification results as the classification result of the image.
前記M組の分類結果のうちM回目に取得された分類結果を出力する請求項1に記載の画像分類方法。   The image classification method according to claim 1, wherein a classification result acquired for the Mth time among the M sets of classification results is output. 前記M組の分類結果の多数決により決定される分類結果を出力とする請求項1に記載の画像分類方法。   The image classification method according to claim 1, wherein a classification result determined by a majority vote of the M sets of classification results is output. 複数の前記分類カテゴリの各々に、整数列において連続する数値が前記識別番号として付与され、前記数値範囲の広さが2より小さい請求項1ないし3のいずれかに記載の画像分類方法。   The image classification method according to any one of claims 1 to 3, wherein each of the plurality of classification categories is assigned a numerical value that is continuous in an integer string as the identification number, and a range of the numerical value range is smaller than two. 前記第3工程において、前記第2工程で付与された分類カテゴリと前記教師データにおいて予め付与されている分類カテゴリとが一致する場合、当該分類カテゴリの前記識別番号と同じ数値に前記数値範囲内で発生させた乱数を加えた値を前記新たな特徴量とする請求項1ないし4のいずれかに記載の画像分類方法。   In the third step, when the classification category assigned in the second step matches the classification category assigned in advance in the teacher data, the same numerical value as the identification number of the classification category falls within the numerical value range. The image classification method according to claim 1, wherein a value obtained by adding the generated random number is used as the new feature amount. 前記第3工程において、前記第2工程で付与された分類カテゴリと前記教師データにおいて予め付与されている分類カテゴリとが一致する場合、所定の確率で、当該分類カテゴリの前記識別番号と同じ数値を前記新たな特徴量とする請求項1ないし5のいずれかに記載の画像分類方法。   In the third step, when the classification category assigned in the second step matches the classification category assigned in advance in the teacher data, the same number as the identification number of the classification category is obtained with a predetermined probability. The image classification method according to claim 1, wherein the new feature amount is used. 前記第2工程において、前記教師画像のうち予め付与されている分類カテゴリとは異なる分類結果となった画像の数を誤答数と呼ぶとき、
前記第2工程における誤答数が、前回に実行した前記第2工程における誤答数と同じになれば、前記第1ないし前記第3工程の繰り返しを終了する請求項1ないし6のいずれかに記載の画像分類方法。
In the second step, when the number of images resulting in a classification result different from the classification category assigned in advance among the teacher images is referred to as the number of incorrect answers,
The repetition of said 1st thru | or 3rd process is complete | finished if the number of wrong answers in the said 2nd process becomes the same as the number of wrong answers in the said 2nd process performed last time. The image classification method described.
画像を複数の分類カテゴリに自動分類するための分類器の構成方法において、
前記複数の分類カテゴリの各々に、固有の識別番号を付与し、
P(Pは自然数)次元の特徴ベクトルによって表される複数の教師画像と、各教師画像に付与される分類カテゴリとに関する情報を含む教師データを取得し、
前記教師画像に対応する前記教師データを用いた機械学習アルゴリズムを実行して分類器を構成する第1工程と、
前記第1工程で構成された分類器により、前記教師画像の各々を複数の分類カテゴリに分類する第2工程と、
前記教師画像の各々について、前記第2工程で付与された分類カテゴリと前記教師データにおいて予め付与されている分類カテゴリとを比較し、その結果に応じた数値を新たな特徴量として特徴ベクトルに追加することで、当該教師画像の特徴ベクトルの次元数を1つ増加させる第3工程と
をこの順番でM(Mは2以上の整数)回実行して、入力ベクトルの次元が1ずつ異なるM組の分類器を構成し、
前記第3工程では、前記第2工程で付与された分類カテゴリと前記教師データにおいて予め付与されている分類カテゴリとが異なる場合には、前記第2工程で付与された分類カテゴリの前記識別番号を前記新たな特徴量とし、前記第2工程で付与された分類カテゴリと前記教師データにおいて予め付与されている分類カテゴリとが一致する場合には、当該分類カテゴリの前記識別番号を中心とする所定の数値範囲内の不規則な数値を前記新たな特徴量とする、分類器の構成方法。
In a method of configuring a classifier for automatically classifying an image into a plurality of classification categories,
A unique identification number is assigned to each of the plurality of classification categories,
Obtaining teacher data including information on a plurality of teacher images represented by a feature vector of P (P is a natural number) dimension and a classification category assigned to each teacher image;
A first step of configuring a classifier by executing a machine learning algorithm using the teacher data corresponding to the teacher image;
A second step of classifying each of the teacher images into a plurality of classification categories by the classifier configured in the first step;
For each of the teacher images, the classification category assigned in the second step is compared with the classification category assigned in advance in the teacher data, and a numerical value corresponding to the result is added as a new feature amount to the feature vector. Thus, the third step of increasing the number of dimensions of the feature vector of the teacher image by one is executed M (M is an integer of 2 or more) times in this order, and M sets whose input vector dimensions are different by one Configure the classifier
In the third step, when the classification category assigned in the second step is different from the classification category assigned in advance in the teacher data, the identification number of the classification category assigned in the second step is set. When the classification category given in the second step matches the classification category given in advance in the teacher data as the new feature amount, a predetermined centered on the identification number of the classification category A classifier configuration method in which an irregular numerical value within a numerical value range is used as the new feature amount.
教師画像となる複数の画像および分類対象となる画像を取得する画像取得手段と、
請求項1ないし7のいずれかに記載の画像分類方法を実行して画像を分類する分類手段と、
出力された分類結果をユーザに報知する報知手段と
を備える画像分類装置。
Image acquisition means for acquiring a plurality of images to be teacher images and images to be classified;
Classifying means for classifying an image by executing the image classification method according to any one of claims 1 to 7,
An image classification device comprising notification means for notifying a user of an output classification result.
分類対象となる画像を取得する画像取得手段と、
請求項8に記載の分類器の構成方法により構成された分類器を用いて画像を分類する分類手段と、
出力された分類結果をユーザに報知する報知手段と
を備える画像分類装置。
Image acquisition means for acquiring images to be classified;
Classifying means for classifying an image using a classifier configured by the classifier configuration method according to claim 8;
An image classification device comprising notification means for notifying a user of an output classification result.
前記画像取得手段が撮像機能を有する請求項9または10に記載の画像分類装置。   The image classification device according to claim 9 or 10, wherein the image acquisition unit has an imaging function.
JP2015178300A 2015-09-10 2015-09-10 Image classification method, classifier configuration method, and image classification apparatus Active JP6584250B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2015178300A JP6584250B2 (en) 2015-09-10 2015-09-10 Image classification method, classifier configuration method, and image classification apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2015178300A JP6584250B2 (en) 2015-09-10 2015-09-10 Image classification method, classifier configuration method, and image classification apparatus

Publications (2)

Publication Number Publication Date
JP2017054331A JP2017054331A (en) 2017-03-16
JP6584250B2 true JP6584250B2 (en) 2019-10-02

Family

ID=58320853

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2015178300A Active JP6584250B2 (en) 2015-09-10 2015-09-10 Image classification method, classifier configuration method, and image classification apparatus

Country Status (1)

Country Link
JP (1) JP6584250B2 (en)

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP6871807B2 (en) * 2017-05-31 2021-05-12 株式会社Screenホールディングス Classifier construction method, classifier and classifier construction device
JP6909657B2 (en) * 2017-07-12 2021-07-28 株式会社日立製作所 Video recognition system
JP6753833B2 (en) * 2017-09-13 2020-09-09 ヤフー株式会社 Grant device, grant method, grant program, and program
JP6768620B2 (en) * 2017-09-27 2020-10-14 富士フイルム株式会社 Learning support device, operation method of learning support device, learning support program, learning support system, terminal device and program
JP7161948B2 (en) * 2018-09-07 2022-10-27 株式会社フジクラ Machine learning device, machine learning method, machine learning program, and inspection device
US11308365B2 (en) * 2019-06-13 2022-04-19 Expedia, Inc. Image classification system
JP7052778B2 (en) * 2019-07-17 2022-04-12 Jfeスチール株式会社 Belt conveyor belt abnormality monitoring method and belt abnormality monitoring device
CN113408571B (en) * 2021-05-08 2022-07-19 浙江智慧视频安防创新中心有限公司 Image classification method and device based on model distillation, storage medium and terminal

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4220595B2 (en) * 1998-08-10 2009-02-04 株式会社日立製作所 Defect classification method and teaching data creation method
JP2013167596A (en) * 2012-02-17 2013-08-29 Honda Motor Co Ltd Defect inspection device, defect inspection method, and program

Also Published As

Publication number Publication date
JP2017054331A (en) 2017-03-16

Similar Documents

Publication Publication Date Title
JP6584250B2 (en) Image classification method, classifier configuration method, and image classification apparatus
US10489687B2 (en) Classification method, classification module and computer program product using the same
US10878283B2 (en) Data generation apparatus, data generation method, and data generation program
US20200356718A1 (en) Implementation of deep neural networks for testing and quality control in the production of memory devices
WO2019233166A1 (en) Surface defect detection method and apparatus, and electronic device
JP6472621B2 (en) Classifier construction method, image classification method, and image classification apparatus
US11176650B2 (en) Data generation apparatus, data generation method, and data generation program
JP6669453B2 (en) Image classification device and image classification method
JP6113024B2 (en) Classifier acquisition method, defect classification method, defect classification device, and program
US20130279795A1 (en) Optimization of unknown defect rejection for automatic defect classification
US10803575B2 (en) System, method and computer program product for generating a training set for a classifier
JP2017062713A (en) Identifier creation circuit, identifier creation method, and program
CN110914864A (en) Information processing apparatus, information processing program, and information processing method
US9842279B2 (en) Data processing method for learning discriminator, and data processing apparatus therefor
JP6401648B2 (en) Defect classification apparatus and defect classification method
JP2017102906A (en) Information processing apparatus, information processing method, and program
JP2018026122A5 (en)
US6336086B1 (en) Method and system for analyzing wafer processing order
JP6641195B2 (en) Optimization method, optimization device, program, and image processing device
TWI791930B (en) System, method and computer readable medium for classifying defects in a semiconductor specimen
JP2020085583A (en) Inspection device and inspection method
US20220076404A1 (en) Defect management apparatus, method and non-transitory computer readable medium
JP2019016249A (en) Determining apparatus, determining method, and determining program
CN111310826A (en) Method and device for detecting labeling abnormity of sample set and electronic equipment
JP2018106618A (en) Image data classifying apparatus, object detection apparatus, and program therefor

Legal Events

Date Code Title Description
RD04 Notification of resignation of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7424

Effective date: 20170725

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20180626

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: 20190827

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20190903

R150 Certificate of patent or registration of utility model

Ref document number: 6584250

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250