JP7070308B2 - Estimator generator, inspection device, estimator generator method, and estimator generator - Google Patents
Estimator generator, inspection device, estimator generator method, and estimator generator Download PDFInfo
- Publication number
- JP7070308B2 JP7070308B2 JP2018190513A JP2018190513A JP7070308B2 JP 7070308 B2 JP7070308 B2 JP 7070308B2 JP 2018190513 A JP2018190513 A JP 2018190513A JP 2018190513 A JP2018190513 A JP 2018190513A JP 7070308 B2 JP7070308 B2 JP 7070308B2
- Authority
- JP
- Japan
- Prior art keywords
- features
- estimator
- image
- learning
- product
- 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
Links
Images
Classifications
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02E—REDUCTION OF GREENHOUSE GAS [GHG] EMISSIONS, RELATED TO ENERGY GENERATION, TRANSMISSION OR DISTRIBUTION
- Y02E60/00—Enabling technologies; Technologies with a potential or indirect contribution to GHG emissions mitigation
- Y02E60/10—Energy storage using batteries
Landscapes
- Investigating Materials By The Use Of Optical Means Adapted For Particular Applications (AREA)
Description
本発明は、推定器生成装置、検査装置、推定器生成方法、及び推定器生成プログラムに関する。 The present invention relates to an estimator generation device, an inspection device, an estimator generation method, and an estimator generation program.
従来、製造ライン等の製品を製造する場面では、製造される製品を撮影装置により撮影し、得られた画像データに基づいて製品の良否を検査する技術が利用されている。例えば、特許文献1では、学習済みの第1のニューラルネットワークに基づいて画像に写る検査対象物が正常であるか異常であるかを判定し、検査対象物が異常であると判定した場合に、学習済みの第2のニューラルネットワークに基づいて当該異常の種類を分類する検査装置が提案されている。 Conventionally, in the scene of manufacturing a product such as a production line, a technique of photographing the manufactured product with an imaging device and inspecting the quality of the product based on the obtained image data has been used. For example, in Patent Document 1, it is determined whether the inspection target imaged in the image is normal or abnormal based on the learned first neural network, and when it is determined that the inspection target is abnormal, it is determined. An inspection device that classifies the type of the anomaly based on the learned second neural network has been proposed.
本件発明者らは、特許文献1のようなニューラルネットワーク等の学習モデルにより構成される推定器を利用して、画像データから製品の良否を判定する従来の技術には、次のような問題が生じ得ることを見出した。すなわち、学習画像のサイズが大きくなるほど、製品の良否を判定するための推定器の構成が複雑になってしまう。そのため、推定器の計算コストが大きくなってしまい、機械学習の計算処理の際にメモリの不足が生じてしまう、当該計算処理の時間が長くなってしまう、当該計算処理が所定時間内に完了しない等の不具合が生じてしまうという問題点が生じ得る。 The inventors of the present invention have the following problems in the conventional technique of determining the quality of a product from image data by using an estimator composed of a learning model such as a neural network as in Patent Document 1. I found that it could happen. That is, the larger the size of the learning image, the more complicated the configuration of the estimator for determining the quality of the product. Therefore, the calculation cost of the estimator becomes large, a memory shortage occurs during the calculation process of machine learning, the calculation process takes a long time, and the calculation process is not completed within a predetermined time. There may be a problem that problems such as the above occur.
そこで、本件発明者らは、学習画像から特徴を抽出し、抽出した特徴に基づいて製品の良否を判定する推定器を構築することを検討した。例えば、特許文献2には、物体を撮像して得られた画像データの特徴量を算出し、算出した特徴量に基づいて、物体の外観上の欠陥を検出する検査システムが提案されている。学習画像から抽出される特徴は、抽出処理により情報を部分的に削減したものになるため、その情報量は、通常、学習画像そのものよりも小さい(すなわち、低次元である)。そのため、この特徴を利用する推定器の構成は、学習画像そのものを利用する推定器よりも簡単にすることができ、これによって、推定器の計算コストを低減することができる。したがって、この方法によれば、推定器の学習時間を短くしたり、推定器の機械学習に利用するハードウェア資源を節約したりすることができる。
Therefore, the inventors of the present invention examined to construct an estimator that extracts features from the learning image and judges the quality of the product based on the extracted features. For example,
しかしながら、本件発明者らは、この方法には、次のような問題点があることを見出した。すなわち、推定器による判定の精度は、学習データの件数に依存する。そのため、学習画像の件数が少ないと、得られる特徴の件数も少なくなってしまい、学習済みの学習モデル(推定器)による欠陥推定の精度が不十分になってしまう。特に、学習画像から抽出される特徴は、学習画像に含まれる情報を抽出処理により部分的に削減したものである。つまり、推定器がこの特徴から得られる情報量は、学習画像そのものから得られる情報量よりも少ない。そのため、この方法により構築された推定器の欠陥推定の精度は、学習画像を利用して構築された推定器よりも悪くなる傾向にある。よって、学習データの件数が少ないことにより、学習済みの学習モデル(推定器)による欠陥推定の精度が極めて悪くなってしまう可能性がある。 However, the present inventors have found that this method has the following problems. That is, the accuracy of the determination by the estimator depends on the number of training data. Therefore, if the number of training images is small, the number of features that can be obtained is also small, and the accuracy of defect estimation by the trained learning model (estimator) becomes insufficient. In particular, the feature extracted from the training image is that the information contained in the training image is partially reduced by the extraction process. That is, the amount of information that the estimator can obtain from this feature is less than the amount of information that the estimator can obtain from the training image itself. Therefore, the accuracy of defect estimation of the estimator constructed by this method tends to be worse than that of the estimator constructed by using the learning image. Therefore, when the number of training data is small, the accuracy of defect estimation by the trained learning model (estimator) may become extremely poor.
なお、このような問題点は、製品の良否を判定するための推定器を機械学習により構築する場面だけではなく、画像に写る対象物の何らかの属性を推定するための推定器を構築するあらゆる場面で生じ得る。例えば、対象者の顔の器官を検出するための推定器を構築する場合に、学習データとして利用される顔画像(学習画像)の件数が少ないと、顔画像から得られる特徴の件数も少なくなってしまい、推定器による器官の推定の精度が不十分になってしまう可能性がある。 It should be noted that such a problem is not only in the case of constructing an estimator for judging the quality of a product by machine learning, but also in any situation in which an estimator for estimating some attribute of an object reflected in an image is constructed. Can occur in. For example, when constructing an estimator for detecting the facial organs of a subject, if the number of facial images (learning images) used as learning data is small, the number of features obtained from the facial images is also small. Therefore, the accuracy of organ estimation by the estimator may be insufficient.
本発明は、一側面では、このような実情を鑑みてなされたものであり、その目的は、推定器の計算コストを低減しつつ、学習画像の件数が比較的に少なくても、画像に写る対象物の属性を高精度に推定可能な推定器を構築する技術を提供することである。 The present invention has been made in view of such a situation on one aspect, and the purpose of the present invention is to reduce the calculation cost of the estimator and to capture the image even if the number of learning images is relatively small. It is to provide a technique for constructing an estimator capable of estimating the attributes of an object with high accuracy.
本発明は、上述した課題を解決するために、以下の構成を採用する。 The present invention adopts the following configuration in order to solve the above-mentioned problems.
すなわち、本発明の一側面に係る推定器生成装置は、外観検査の対象となる製品を写した学習画像、及び前記製品に含まれる欠陥の種別を示すラベルの組み合わせによりそれぞれ構成された複数の学習データセットを取得するデータ取得部と、前記各学習データセットに含まれる前記学習画像から1又は複数の第1特徴を抽出する抽出部と、抽出された前記1又は複数の第1特徴に拡大処理を適用することで、前記1又は複数の第1特徴とは異なる1又は複数の第2特徴を生成する拡大処理部と、機械学習を行うことで、前記1又は複数の第1特徴及び前記1又は複数の第2特徴の少なくともいずれかから、対応するラベルと一致するように、前記学習画像に写る前記製品に含まれる前記欠陥の種別を推定するように訓練された推定器を構築する学習処理部と、を備える。 That is, the estimator generator according to one aspect of the present invention is composed of a combination of a learning image showing a product to be visually inspected and a label indicating the type of defect contained in the product. A data acquisition unit for acquiring a data set, an extraction unit for extracting one or a plurality of first features from the training image included in each learning data set, and an expansion process for the extracted one or a plurality of first features. By applying the above-mentioned one or a plurality of first features and the above-mentioned one or a plurality of first features and the above-mentioned 1 by performing machine learning with an enlargement processing unit that generates one or a plurality of second features different from the above-mentioned one or a plurality of first features. Or a learning process that builds an estimator trained to estimate the type of defect contained in the product in the training image so as to match the corresponding label from at least one of the plurality of second features. It is equipped with a department.
当該構成では、推定器は、学習画像から直接的に製品の良否を推定するように訓練されるのではなく、学習画像より抽出された特徴から製品の良否を推定するように訓練される。一般的に、抽出される特徴の次元は学習画像そのものよりも低いため、抽出される特徴の有する情報量は、学習画像よりも少なくなる。そのため、学習画像から直接的に製品の良否を推定するように訓練されるケースと比較して、抽出された特徴から製品の良否を推定するように訓練されるケースでは、入力データの情報量を抑えることができるため、推定器の構成を単純化することができる。加えて、当該構成では、学習画像より抽出された第1特徴に拡大処理を適用することで、第1特徴とは異なる第2特徴を生成する。これにより、特徴のバリエーションを豊富にすることができる。すなわち、機械学習に利用する訓練データの件数を増やすことができる。そのため、学習画像の件数が少なくても、欠陥推定の一定の精度を担保するのに十分な件数の学習データを用意することができる。したがって、当該構成によれば、推定器の計算コストを低減しつつ、学習画像の件数が比較的に少なくても、画像に写る対象物の属性を高精度に推定可能な推定器を構築することができる。 In this configuration, the estimator is not trained to estimate the quality of the product directly from the training image, but to estimate the quality of the product from the features extracted from the training image. In general, the dimension of the extracted feature is lower than that of the training image itself, so that the amount of information contained in the extracted feature is smaller than that of the training image. Therefore, in the case of training to estimate the quality of the product from the extracted features, the amount of information of the input data is compared with the case of training to estimate the quality of the product directly from the training image. Since it can be suppressed, the configuration of the estimator can be simplified. In addition, in this configuration, by applying the enlargement processing to the first feature extracted from the learning image, a second feature different from the first feature is generated. This makes it possible to increase the variety of features. That is, the number of training data used for machine learning can be increased. Therefore, even if the number of training images is small, it is possible to prepare a sufficient number of training data to ensure a certain accuracy of defect estimation. Therefore, according to the configuration, it is possible to construct an estimator capable of estimating the attributes of the object reflected in the image with high accuracy even if the number of learning images is relatively small, while reducing the calculation cost of the estimator. Can be done.
なお、特徴は、画像から導出可能な何らかの情報であれば、その種類及びデータ形式は、特に限定されなくてもよく、実施の形態に応じて適宜選択されてよい。特徴の抽出には、例えば、一般的な画像処理(例えば、エッジ抽出)、SIFT(Scale-Invariant Feature Transform)、学習済みの学習モデル(例えば、畳み込みニューラルネットワーク)等が用いられてよい。例えば、畳み込みニューラルネットワークを利用して、第1特徴として特徴マップを学習画像から導出してもよい。拡大処理(data augmentation)は、1又は複数の特徴から異なる特徴を導出する処理である。拡大処理には、例えば、複数の特徴を合成する処理、幾何的な変換等により特徴を変換する処理等が用いられてよい。特徴が画像として導出される場合、特徴を変換する処理には、所定のノイズ(ホワイトノイズ、ランダムノイズ等)を特徴画像に合成する処理、特徴画像に含まれる画素を変換する処理等が用いられてよい。画素の変換には、色変換、濃度変換等が含まれてよく、これらの変換には、所定の変換関数が用いられてよい。 The type and data format of the feature may not be particularly limited as long as it is some information that can be derived from the image, and may be appropriately selected according to the embodiment. For feature extraction, for example, general image processing (for example, edge extraction), SIFT (Scale-Invariant Feature Transform), trained learning model (for example, convolutional neural network) and the like may be used. For example, a feature map may be derived from the training image as the first feature by using a convolutional neural network. The augmentation process (data augmentation) is a process of deriving different features from one or more features. For the enlargement process, for example, a process of synthesizing a plurality of features, a process of converting features by geometric conversion, or the like may be used. When a feature is derived as an image, the process of converting the feature includes a process of synthesizing predetermined noise (white noise, random noise, etc.) into the feature image, a process of converting pixels included in the feature image, and the like. It's okay. Pixel conversion may include color conversion, density conversion, and the like, and a predetermined conversion function may be used for these conversions.
また、製品は、外観検査の対象となり得るものであれば、その種類は、特に限定されなくてもよく、実施の形態に応じて適宜選択されてよい。製品は、例えば、電子機器、電子部品、自動車部品、薬品、食品等の製造ラインで搬送される物であってよい。電子機器は、例えば、携帯電話等である。電子部品は、例えば、基盤、チップコンデンサ、液晶、リレーの巻線等である。自動車部品は、例えば、コンロッド、シャフト、エンジンブロック、パワーウィンドウスイッチ、パネル等である。薬品は、例えば、包装済みの錠剤、未包装の錠剤等であってよい。また、欠陥は、製品の良否に関係し得るものであれば、その種類は、特に限定されなくてもよく、実施の形態に応じて適宜選択されてよい。欠陥は、例えば、傷、汚れ、クラック、打痕、バリ、色ムラ、異物混入等である。 Further, the type of the product is not particularly limited as long as it can be subject to visual inspection, and may be appropriately selected according to the embodiment. The product may be, for example, a product transported on a production line for electronic devices, electronic parts, automobile parts, chemicals, foods, and the like. The electronic device is, for example, a mobile phone or the like. Electronic components are, for example, boards, chip capacitors, liquid crystals, relay windings, and the like. Automotive parts are, for example, connecting rods, shafts, engine blocks, power window switches, panels and the like. The chemical may be, for example, a packaged tablet, an unpackaged tablet, or the like. Further, the type of the defect may be not particularly limited as long as it may be related to the quality of the product, and may be appropriately selected according to the embodiment. Defects include, for example, scratches, stains, cracks, dents, burrs, color unevenness, foreign matter contamination, and the like.
上記一側面に係る推定器生成装置において、前記1又は複数の第1特徴はそれぞれ、前記学習画像よりもサイズの小さい特徴画像として抽出されてよい。当該構成によれば、拡大処理に適した形式で特徴を得ることができるため、機械学習に利用する訓練データ(特徴)の件数を増やすことができる。これにより、画像に写る対象物を高精度に推定可能な推定器を構築することができる。なお、特徴画像は、例えば、畳み込みニューラルネットワークにより導出される特徴マップである。 In the estimator generator according to the one aspect, the one or a plurality of first features may be extracted as feature images smaller in size than the learning image, respectively. According to this configuration, features can be obtained in a format suitable for enlargement processing, so that the number of training data (features) used for machine learning can be increased. This makes it possible to construct an estimator capable of estimating an object reflected in an image with high accuracy. The feature image is, for example, a feature map derived by a convolutional neural network.
上記一側面に係る推定器生成装置において、前記複数の第1特徴それぞれには重みが設定されていてよく、前記拡大処理を適用することは、設定された前記重みを前記複数の第1特徴それぞれにかけること、及び重み付けされた前記複数の第1特徴を合成すること、を含んでもよい。当該構成によれば、機械学習に利用する特徴のバリエーションを適切に豊富化することができ、これによって、画像に写る対象物を高精度に推定可能な推定器を構築することができる。 In the estimator generation device according to the one aspect, weights may be set for each of the plurality of first features, and applying the enlargement processing means that the set weights are applied to each of the plurality of first features. It may include subjecting to and synthesizing the plurality of weighted first features. According to this configuration, it is possible to appropriately enrich the variation of the features used for machine learning, and thereby it is possible to construct an estimator capable of estimating the object to be reflected in the image with high accuracy.
上記一側面に係る推定器生成装置において、前記拡大処理を適用することは、前記1又は複数の第1特徴に対して幾何学的な変換を適用すること、を含んでもよい。当該構成によれば、機械学習に利用する特徴のバリエーションを適切に豊富化することができ、これによって、画像に写る対象物を高精度に推定可能な推定器を構築することができる。 In the estimator generator according to one aspect, applying the enlargement process may include applying a geometric transformation to the one or more first features. According to this configuration, it is possible to appropriately enrich the variation of the features used for machine learning, and thereby it is possible to construct an estimator capable of estimating the object to be reflected in the image with high accuracy.
上記一側面に係る推定器生成装置において、前記幾何学的な変換は、平行移動、回転移動、反転、又はこれら組み合わせであってよい。当該構成によれば、機械学習に利用する特徴のバリエーションを適切に豊富化することができ、これによって、画像に写る対象物を高精度に推定可能な推定器を構築することができる。 In the estimator generator according to one aspect, the geometric transformation may be translation, rotational movement, inversion, or a combination thereof. According to this configuration, it is possible to appropriately enrich the variation of the features used for machine learning, and thereby it is possible to construct an estimator capable of estimating the object to be reflected in the image with high accuracy.
また、本発明の一側面に係る検査装置は、外観検査の対象となる製品を写した対象画像を取得する画像取得部と、取得した前記対象画像から特徴を抽出する抽出部と、上記いずれかの形態に係る推定器生成装置により構築された前記推定器を利用し、抽出した前記特徴に基づいて、前記対象画像に写る前記製品に欠陥が含まれるか否かを検査する検査部と、前記検査の結果に関する情報を出力する出力部と、を備える。当該構成によれば、製品の外観検査を高精度に実施することができる。 Further, the inspection device according to one aspect of the present invention includes an image acquisition unit that acquires a target image of a product to be visually inspected, an extraction unit that extracts features from the acquired target image, and any of the above. An inspection unit that inspects whether or not the product shown in the target image contains a defect based on the extracted features by using the estimator constructed by the estimator generator according to the embodiment of the above. It is provided with an output unit that outputs information about the inspection result. According to this configuration, the appearance inspection of the product can be performed with high accuracy.
また、上記各形態に係る推定器生成装置及び検査装置は、画像から製品の良否を判定するための推定器を機械学習により構築する場面だけではなく、画像に写る対象物の何らかの属性を推定するための推定器を構築するあらゆる場面に適用されてよい。例えば、上記各形態に係る推定器生成装置及び検査装置は、対象者の顔を写した顔画像から器官を検出するための推定器を構築する場面に適用されてもよい。また、上記各形態に係る推定器生成装置は、学習画像から第1特徴を抽出する構成を省略し、第1特徴を直接的に取得するように構成されてもよい。 Further, the estimator generation device and the inspection device according to each of the above forms estimate not only the scene of constructing an estimator for judging the quality of a product from an image by machine learning, but also some attribute of an object reflected in the image. It may be applied in any situation to build an estimator for. For example, the estimator generation device and the inspection device according to each of the above forms may be applied to a scene of constructing an estimator for detecting an organ from a face image of a subject's face. Further, the estimator generator according to each of the above embodiments may be configured to omit the configuration of extracting the first feature from the learning image and directly acquire the first feature.
例えば、本発明の一側面に係る推定器生成装置は、対象物を写した学習画像、及び前記対象物の属性を示すラベルの組み合わせによりそれぞれ構成された複数の学習データセットを取得するデータ取得部と、前記各学習データセットに含まれる前記学習画像から1又は複数の第1特徴抽出する抽出部と、抽出された前記1又は複数の第1特徴に拡大処理を適用することで、前記1又は複数の第1特徴とは異なる1又は複数の第2特徴を生成する拡大処理部と、機械学習を行うことで、前記1又は複数の第1特徴及び前記1又は複数の第2特徴の少なくともいずれかから、対応するラベルと一致するように、前記学習画像に写る前記対象物の属性を推定するように訓練された推定器を構築する学習処理部と、を備える。 For example, the estimator generator according to one aspect of the present invention is a data acquisition unit that acquires a plurality of learning data sets each composed of a combination of a learning image showing an object and a label indicating the attribute of the object. By applying the enlargement processing to the extraction unit that extracts one or a plurality of first features from the learning image included in each learning data set and the extracted one or a plurality of first features, the one or a plurality of the first features are extracted. At least one of the one or more first features and the one or more second features by performing machine learning with an enlargement processing unit that generates one or more second features different from the plurality of first features. From this, it is provided with a learning processing unit that constructs an estimator trained to estimate the attributes of the object reflected in the learning image so as to match the corresponding label.
また、例えば、本発明の一側面に係る推定器生成装置は、対象物を写した学習画像から抽出された1又は複数の第1特徴、及び前記対象物の属性を示すラベルの組み合わせによりそれぞれ構成された複数の学習データセットを取得するデータ取得部と、前記各学習データセットに含まれる前記1又は複数の第1特徴に拡大処理を適用することで、前記1又は複数の第1特徴とは異なる1又は複数の第2特徴を生成する拡大処理部と、機械学習を行うことで、前記1又は複数の第1特徴及び前記1又は複数の第2特徴の少なくともいずれかから、対応するラベルと一致するように、前記学習画像に写る前記対象物の属性を推定するように訓練された推定器を構築する学習処理部と、を備える。 Further, for example, the estimator generator according to one aspect of the present invention is configured by a combination of one or a plurality of first features extracted from a learning image of an object and a label indicating the attribute of the object. By applying the expansion process to the one or more first features included in each of the learning data sets and the data acquisition unit for acquiring the plurality of learning data sets, the one or more first features are An enlargement processing unit that generates one or a plurality of different second features, and a corresponding label from at least one of the one or more first features and the one or more second features by performing machine learning. A learning processing unit that constructs an estimator trained to estimate the attributes of the object reflected in the learning image so as to match is provided.
また、例えば、本発明の一側面に係る推定装置は、対象物を写した対象画像を取得する画像取得部と、取得した前記対象画像から特徴を抽出する抽出部と、上記いずれかの形態に係る推定器生成装置により構築された前記推定器を利用し、抽出した前記特徴に基づいて、前記対象画像に写る前記対象物の状態を推定する推定部と、前記推定の結果に関する情報を出力する出力部と、を備える。 Further, for example, the estimation device according to one aspect of the present invention has an image acquisition unit for acquiring an object image in which an object is captured, an extraction unit for extracting features from the acquired target image, and any of the above forms. Using the estimator constructed by the estimator generator, the estimator for estimating the state of the object reflected in the target image and information on the estimation result are output based on the extracted features. It has an output unit.
なお、「対象物」は、何らかの属性を推定する対象となり得るものであれば、その種類は、特に限定されなくてもよく、実施の形態に応じて適宜選択されてよい。対象物は、例えば、上記外観検査の対象となる製品、人物、人物の身体部位(例えば、顔等)等であってよい。また、推定する対象となる対象物の「属性」は、対象物の何らかの性質に関するものであればよく、推定器により推定可能な対象物のあらゆる種類の属性を含んでもよい。対象物が人物の顔である場合、判定の対象となる属性は、例えば、表情の種別、顔のパーツ(器官を含む)の位置(特定の器官同士の相対位置関係を含む)、顔のパーツの形状、顔のパーツの色、顔のパーツの状態(開度、角度等)、その顔を所有する個人の属性等であってよい。また、対象物が人物の身体である場合、判定の対象となる属性は、例えば、身体のポーズ等であってよい。対象物が作業対象のワークである場合、判定の対象となる属性は、例えば、ワークの位置、姿勢等であってよい。 The type of the "object" is not particularly limited as long as it can be an object for which some attribute is estimated, and may be appropriately selected according to the embodiment. The object may be, for example, a product, a person, a body part of the person (for example, a face, etc.) to be subject to the visual inspection. Further, the "attribute" of the object to be estimated may be any property related to any property of the object, and may include all kinds of attributes of the object that can be estimated by the estimator. When the object is a person's face, the attributes to be judged are, for example, the type of facial expression, the position of facial parts (including organs) (including the relative positional relationship between specific organs), and facial parts. It may be the shape of the face, the color of the facial part, the state of the facial part (opening, angle, etc.), the attribute of the individual who owns the face, and the like. When the object is the body of a person, the attribute to be determined may be, for example, a pose of the body. When the object is a work to be worked on, the attributes to be determined may be, for example, the position and posture of the work.
本発明の一側面に係る検査システムは、上記いずれかの形態に係る推定器生成装置及び検査装置により構成されてもよい。また、本発明の一側面に係る推定システムは、上記いずれかの形態に係る推定器生成装置及び推定装置により構成されてもよい。更に、上記各形態に係る推定器生成装置、検査装置、検査システム及び推定システムそれぞれの別の形態として、本発明の一側面は、以上の各構成を実現する情報処理方法であってもよいし、プログラムであってもよいし、このようなプログラムを記憶した、コンピュータ等が読み取り可能な記憶媒体であってもよい。ここで、コンピュータ等が読み取り可能な記憶媒体とは、プログラム等の情報を、電気的、磁気的、光学的、機械的、又は、化学的作用によって蓄積する媒体である。 The inspection system according to one aspect of the present invention may be composed of an estimator generator and an inspection apparatus according to any one of the above embodiments. Further, the estimation system according to one aspect of the present invention may be composed of an estimator generator and an estimation device according to any one of the above embodiments. Further, as another form of the estimator generator, the inspection device, the inspection system, and the estimation system according to each of the above embodiments, one aspect of the present invention may be an information processing method that realizes each of the above configurations. , A program, or a storage medium that stores such a program and can be read by a computer or the like. Here, the storage medium that can be read by a computer or the like is a medium that stores information such as a program by electrical, magnetic, optical, mechanical, or chemical action.
例えば、本発明の一側面に係る推定器生成方法は、コンピュータが、外観検査の対象となる製品を写した学習画像、及び前記製品に含まれる欠陥の種別を示すラベルの組み合わせによりそれぞれ構成された複数の学習データセットを取得するステップと、前記各学習データセットに含まれる前記学習画像から1又は複数の第1特徴を抽出するステップと、抽出された前記1又は複数の第1特徴に拡大処理を適用することで、前記1又は複数の第1特徴とは異なる1又は複数の第2特徴を生成するステップと、機械学習を行うことで、前記1又は複数の第1特徴及び前記1又は複数の第2特徴の少なくともいずれかから、対応するラベルと一致するように、前記学習画像に写る前記製品に含まれる前記欠陥の種別を推定するように訓練された推定器を構築するステップと、を実行する、情報処理方法である。 For example, in the estimator generation method according to one aspect of the present invention, a computer is configured by a combination of a learning image showing a product to be visually inspected and a label indicating the type of defect contained in the product. A step of acquiring a plurality of training data sets, a step of extracting one or a plurality of first features from the training images included in each training data set, and an expansion process to the extracted one or a plurality of first features. By applying, the step of generating one or more second features different from the one or more first features, and by performing machine learning, the one or more first features and the one or more From at least one of the second features of the above, a step of constructing an estimator trained to estimate the type of defect contained in the product in the training image so as to match the corresponding label. It is an information processing method to be executed.
また、例えば、本発明の一側面に係る推定器生成プログラムは、コンピュータに、外観検査の対象となる製品を写した学習画像、及び前記製品に含まれる欠陥の種別を示すラベルの組み合わせによりそれぞれ構成された複数の学習データセットを取得するステップと、前記各学習データセットに含まれる前記学習画像から1又は複数の第1特徴を抽出するステップと、抽出された前記1又は複数の第1特徴に拡大処理を適用することで、前記1又は複数の第1特徴とは異なる1又は複数の第2特徴を生成するステップと、機械学習を行うことで、前記1又は複数の第1特徴及び前記1又は複数の第2特徴の少なくともいずれかから、対応するラベルと一致するように、前記学習画像に写る前記製品に含まれる前記欠陥の種別を推定するように訓練された推定器を構築するステップと、を実行させるための、プログラムである。 Further, for example, the estimator generation program according to one aspect of the present invention is configured by a combination of a learning image showing a product to be visually inspected and a label indicating the type of a defect contained in the product on a computer. The step of acquiring the plurality of learning data sets, the step of extracting one or a plurality of first features from the learning images included in each learning data set, and the extracted one or a plurality of first features. By applying the enlargement processing, a step of generating one or a plurality of second features different from the one or a plurality of first features, and by performing machine learning, the one or a plurality of first features and the above 1 Or with the step of constructing an estimator trained to estimate the type of defect contained in the product in the training image so as to match the corresponding label from at least one of the plurality of second features. , Is a program for executing.
本発明によれば、推定器の計算コストを低減しつつ、学習画像の件数が比較的に少なくても、画像に写る対象物の属性を高精度に推定可能な推定器を構築することができる。 According to the present invention, it is possible to construct an estimator capable of estimating the attributes of an object appearing in an image with high accuracy even if the number of learning images is relatively small, while reducing the calculation cost of the estimator. ..
以下、本発明の一側面に係る実施の形態(以下、「本実施形態」とも表記する)を、図面に基づいて説明する。ただし、以下で説明する本実施形態は、あらゆる点において本発明の例示に過ぎない。本発明の範囲を逸脱することなく種々の改良や変形を行うことができることは言うまでもない。つまり、本発明の実施にあたって、実施形態に応じた具体的構成が適宜採用されてもよい。なお、本実施形態において登場するデータを自然言語により説明しているが、より具体的には、コンピュータが認識可能な疑似言語、コマンド、パラメータ、マシン語等で指定される。 Hereinafter, an embodiment according to one aspect of the present invention (hereinafter, also referred to as “the present embodiment”) will be described with reference to the drawings. However, the embodiments described below are merely examples of the present invention in all respects. Needless to say, various improvements and modifications can be made without departing from the scope of the present invention. That is, in carrying out the present invention, a specific configuration according to the embodiment may be appropriately adopted. The data appearing in the present embodiment are described in natural language, but more specifically, they are specified in a pseudo language, a command, a parameter, a machine language, etc. that can be recognized by a computer.
§1 適用例
まず、図1を用いて、本発明が適用される場面の一例について説明する。図1は、本実施形態に係る検査システム100の適用場面の一例を模式的に例示する。図1の例では、製造ラインで製造される製品Rの外観検査を実施する場面に本発明が適用されている。外観検査の対象となる製品Rは、本発明の「対象物」の一例であり、製品Rの欠陥の有無及び欠陥の種別は、本発明の「対象物の属性」の一例である。しかしながら、本発明の適用対象は、このような例に限定されなくてもよく、対象物の何らかの属性を画像から推定するあらゆる場面に適用可能である。
§1 Application example First, an example of a situation in which the present invention is applied will be described with reference to FIG. FIG. 1 schematically illustrates an example of an application scene of the
図1に示されるとおり、本実施形態に係る検査システム100は、ネットワークを介して互いに接続される推定器生成装置1及び検査装置2を備えており、製品Rの欠陥の有無及び欠陥の種別を推定するための推定器を生成し、生成した推定器により製品Rの外観検査を実施するように構成される。推定器生成装置1及び検査装置2の間のネットワークの種類は、例えば、インターネット、無線通信網、移動通信網、電話網、専用網等から適宜選択されてよい。
As shown in FIG. 1, the
本実施形態に係る推定器生成装置1は、機械学習を実施することにより、製品Rの欠陥の有無及び欠陥の種別を画像から推定するための推定器50を構築するように構成されたコンピュータである。具体的には、推定器生成装置1は、外観検査の対象となる製品Rを写した学習画像61、及び製品Rに含まれる欠陥の種別を示すラベル63の組み合わせによりそれぞれ構成された複数の学習データセット60を取得する。次に、推定器生成装置1は、各学習データセット60に含まれる学習画像61から1又は複数の第1特徴71を抽出し、抽出された1又は複数の第1特徴71に拡大処理を適用することで、1又は複数の第1特徴71とは異なる1又は複数の第2特徴73を生成する。
The estimator generator 1 according to the present embodiment is a computer configured to construct an
そして、推定器生成装置1は、機械学習を行うことで、1又は複数の第1特徴71及び1又は複数の第2特徴73の少なくともいずれかから、対応するラベル63と一致するように、学習画像61に写る製品Rに含まれる欠陥の種別を推定するように訓練された推定器50を構築する。すなわち、推定器生成装置1は、1又は複数の第1特徴71及び1又は複数の第2特徴73を訓練データ(入力データ)として利用し、対応するラベル63を正解データ(教師データ)として利用して、推定器50の機械学習を実施する。これにより、推定器生成装置1は、各学習データセット60について、学習画像61から導出された1又は複数の第1特徴71及び1又は複数の第2特徴73の少なくともいずれかを入力すると、当該学習画像61に関連付けられたラベル63により示される欠陥の種別に対応する出力値を出力するように訓練された推定器50を構築する。
Then, the estimator generator 1 learns from at least one of one or a plurality of
これに対して、本実施形態に係る検査装置2は、推定器生成装置1により構築された学習済みの推定器50を利用して、製品Rの外観検査を実施するように構成されたコンピュータである。検査装置2は、画像に写る対象物の何らかの属性を推定するための推定装置の一例である。具体的には、検査装置2は、外観検査の対象となる製品Rを写した対象画像81を取得する。本実施形態では、検査装置2には、カメラCAが接続されている。そのため、検査装置2は、このカメラCAにより製品Rを撮影することで対象画像81を取得する。
On the other hand, the
次に、検査装置2は、取得した対象画像81から1又は複数の特徴83を抽出する。続いて、検査装置2は、推定器生成装置1により構築された学習済みの推定器50を利用して、抽出した1又は複数の特徴83に基づいて、対象画像81に写る製品Rに欠陥が含まれるか否かを検査する。すなわち、検査装置2は、抽出した1又は複数の特徴83を学習済みの推定器50に入力し、学習済みの推定器50の演算処理を実行する。これにより、検査装置2は、製品Rに欠陥が含まれるか否かを検査(推定)した結果に対応する出力値を学習済みの推定器50から取得する。そして、検査装置2は、検査の結果に関する情報を出力する。
Next, the
以上のとおり、本実施形態では、推定器50は、学習画像61から直接的に製品Rの良否を推定するように訓練されるのではなく、学習画像61から導出された第1特徴71及び第2特徴73の少なくともいずれかから製品Rの良否を推定するように訓練される。第1特徴71及び第2特徴73は、学習画像61そのものよりも次元が低くなるように導出されるため、第1特徴71及び第2特徴73の有する情報量は学習画像61の情報量よりも少なくなる。そのため、学習画像61から直接的に製品Rの良否を推定するように訓練されるケースと比較して、本実施形態では、推定器50に対する入力データの情報量を抑えることができるため、推定器50の構成を単純化することができる。
As described above, in the present embodiment, the
加えて、本実施形態では、学習画像61より抽出された第1特徴71に拡大処理を適用することで、第1特徴71とは異なる第2特徴73が生成される。これにより、製品Rの良否を導出するための特徴のバリエーションを豊富にすることができる。すなわち、機械学習に利用する訓練データの件数を増やすことができる。そのため、学習画像61の件数が少なくても、欠陥推定の一定の精度を担保するのに十分な件数の学習データを用意することができる。したがって、本実施形態に係る推定器生成装置1によれば、推定器50の計算コストを低減しつつ、学習画像61の件数が比較的に少なくても、画像に写る製品Rの良否を高精度に推定可能な推定器50を構築することができる。また、本実施形態に係る検査装置2によれば、この推定器50を利用することで、製品Rの外観検査を高精度かつ高速に実施することができる。
In addition, in the present embodiment, by applying the enlargement processing to the
なお、図1の例では、推定器生成装置1及び検査装置2は別個のコンピュータである。しかしながら、検査システム100の構成は、このような例に限定されなくてもよい。推定器生成装置1及び検査装置2は一体のコンピュータで構成されてもよい。また、推定器生成装置1及び検査装置2はそれぞれ複数台のコンピュータにより構成されてもよい。更に、推定器生成装置1及び検査装置2はネットワークに接続されていなくてもよい。この場合、推定器生成装置1及び検査装置2の間のデータのやりとりは、不揮発メモリ等の記憶媒体を介して行われてもよい。
In the example of FIG. 1, the estimator generator 1 and the
また、各特徴(71、73)は、画像から導出可能な何らかの情報であれば、その種類及びデータ形式は、特に限定されなくてもよく、実施の形態に応じて適宜選択されてよい。第1特徴71の抽出には、例えば、一般的な画像処理(例えば、エッジ抽出)、SIFT、学習済みの学習モデル(例えば、畳み込みニューラルネットワーク)等が用いられてよい。拡大処理は、1又は複数の第1特徴71から異なる第2特徴73を導出する処理である。拡大処理には、例えば、複数の第1特徴71を合成する処理、幾何的な変換等により第1特徴71を変換する処理等が用いられてよい。
The type and data format of each feature (71, 73) is not particularly limited as long as it is some information that can be derived from an image, and may be appropriately selected depending on the embodiment. For the extraction of the
また、製品Rは、外観検査の対象となり得るものであれば、その種類は、特に限定されなくてもよく、実施の形態に応じて適宜選択されてよい。製品Rは、例えば、電子機器、電子部品、自動車部品、薬品、食品等の製造ラインで搬送される物であってよい。電子機器は、例えば、携帯電話等である。電子部品は、例えば、基盤、チップコンデンサ、液晶、リレーの巻線等である。自動車部品は、例えば、コンロッド、シャフト、エンジンブロック、パワーウィンドウスイッチ、パネル等である。薬品は、例えば、包装済みの錠剤、未包装の錠剤等であってよい。また、欠陥は、製品Rの良否に関係し得るものであれば、その種類は、特に限定されなくてもよく、実施の形態に応じて適宜選択されてよい。欠陥は、例えば、傷、汚れ、クラック、打痕、バリ、色ムラ、異物混入等である。ラベル63により示される欠陥の種別には、製品Rに欠陥がないことも含まれてよい。
Further, the type of the product R may not be particularly limited as long as it can be a target of visual inspection, and may be appropriately selected according to the embodiment. The product R may be, for example, a product transported on a production line for electronic devices, electronic parts, automobile parts, chemicals, foods, and the like. The electronic device is, for example, a mobile phone or the like. Electronic components are, for example, boards, chip capacitors, liquid crystals, relay windings, and the like. Automotive parts are, for example, connecting rods, shafts, engine blocks, power window switches, panels and the like. The chemical may be, for example, a packaged tablet, an unpackaged tablet, or the like. Further, the type of the defect may not be particularly limited as long as it may be related to the quality of the product R, and may be appropriately selected according to the embodiment. Defects include, for example, scratches, stains, cracks, dents, burrs, color unevenness, foreign matter contamination, and the like. The type of defect indicated by
§2 構成例
[ハードウェア構成]
<推定器生成装置>
次に、図2を用いて、本実施形態に係る推定器生成装置1のハードウェア構成の一例について説明する。図2は、本実施形態に係る推定器生成装置1のハードウェアの一例を模式的に例示する。
§2 Configuration example [Hardware configuration]
<Estimator generator>
Next, an example of the hardware configuration of the estimator generator 1 according to the present embodiment will be described with reference to FIG. FIG. 2 schematically illustrates an example of the hardware of the estimator generator 1 according to the present embodiment.
図2に示されるとおり、本実施形態に係る推定器生成装置1は、制御部11、記憶部12、通信インタフェース13、入力装置14、出力装置15、及びドライブ16が電気的に接続されたコンピュータである。なお、図2では、通信インタフェースを「通信I/F」と記載している。
As shown in FIG. 2, the estimator generator 1 according to the present embodiment is a computer to which a
制御部11は、ハードウェアプロセッサであるCPU(Central Processing Unit)、RAM(Random Access Memory)、ROM(Read Only Memory)等を含み、プログラム及び各種データに基づいて情報処理を実行するように構成される。記憶部12は、メモリの一例であり、例えば、ハードディスクドライブ、ソリッドステートドライブ等で構成される。本実施形態では、記憶部12は、推定器生成プログラム121、複数の学習データセット60、学習結果データ125等の各種情報を記憶する。
The
推定器生成プログラム121は、推定器生成装置1に、後述する機械学習の情報処理(図6)を実行させ、学習済みの推定器50を構築させるためのプログラムである。推定器生成プログラム121は、この情報処理の一連の命令を含む。各学習データセット60は、上記学習画像61及びラベル63により構成され、推定器50の機械学習に利用される。学習結果データ125は、機械学習により構築された学習済みの推定器50の設定を行うためのデータである。学習結果データ125は、推定器生成プログラム121の実行結果として生成される。詳細は後述する。
The
通信インタフェース13は、例えば、有線LAN(Local Area Network)モジュール、無線LANモジュール等であり、ネットワークを介した有線又は無線通信を行うためのインタフェースである。推定器生成装置1は、この通信インタフェース13を利用することで、ネットワークを介したデータ通信を他の情報処理装置(例えば、検査装置2)と行うことができる。
The
入力装置14は、例えば、マウス、キーボード等の入力を行うための装置である。また、出力装置15は、例えば、ディスプレイ、スピーカ等の出力を行うための装置である。オペレータは、入力装置14及び出力装置15を利用することで、推定器生成装置1を操作することができる。
The
ドライブ16は、例えば、CDドライブ、DVDドライブ等であり、記憶媒体91に記憶されたプログラムを読み込むためのドライブ装置である。ドライブ16の種類は、記憶媒体91の種類に応じて適宜選択されてよい。上記推定器生成プログラム121及び複数の学習データセット60の少なくともいずれかは、この記憶媒体91に記憶されていてもよい。
The
記憶媒体91は、コンピュータその他装置、機械等が、記録されたプログラム等の情報を読み取り可能なように、当該プログラム等の情報を、電気的、磁気的、光学的、機械的又は化学的作用によって蓄積する媒体である。推定器生成装置1は、この記憶媒体91から、上記推定器生成プログラム121及び複数の学習データセット60の少なくともいずれかを取得してもよい。
The
ここで、図2では、記憶媒体91の一例として、CD、DVD等のディスク型の記憶媒体を例示している。しかしながら、記憶媒体91の種類は、ディスク型に限定される訳ではなく、ディスク型以外であってもよい。ディスク型以外の記憶媒体として、例えば、フラッシュメモリ等の半導体メモリを挙げることができる。
Here, in FIG. 2, as an example of the
なお、推定器生成装置1の具体的なハードウェア構成に関して、実施形態に応じて、適宜、構成要素の省略、置換及び追加が可能である。例えば、制御部11は、複数のハードウェアプロセッサを含んでもよい。ハードウェアプロセッサは、マイクロプロセッサ、FPGA(field-programmable gate array)、DSP(digital signal processor)等で構成されてよい。記憶部12は、制御部11に含まれるRAM及びROMにより構成されてもよい。通信インタフェース13、入力装置14、出力装置15及びドライブ16の少なくともいずれかは省略されてもよい。推定器生成装置1は、複数台のコンピュータで構成されてもよい。この場合、各コンピュータのハードウェア構成は、一致していてもよいし、一致していなくてもよい。また、推定器生成装置1は、提供されるサービス専用に設計された情報処理装置の他、汎用のサーバ装置、PC(Personal Computer)等であってもよい。
Regarding the specific hardware configuration of the estimator generator 1, components can be omitted, replaced, or added as appropriate according to the embodiment. For example, the
<検査装置>
次に、図3を用いて、本実施形態に係る検査装置2のハードウェア構成の一例について説明する。図3は、本実施形態に係る検査装置2のハードウェア構成の一例を模式的に例示する。
<Inspection equipment>
Next, an example of the hardware configuration of the
図3に示されるとおり、本実施形態に係る検査装置2は、制御部21、記憶部22、通信インタフェース23、入力装置24、出力装置25、ドライブ26、及び外部インタフェース27が電気的に接続されたコンピュータである。なお、図3では、外部インタフェースを「外部I/F」と記載している。検査装置2の制御部21~ドライブ26はそれぞれ上記推定器生成装置1の制御部11~ドライブ16それぞれと同様に構成されてよい。
As shown in FIG. 3, in the
すなわち、制御部21は、ハードウェアプロセッサであるCPU、RAM、ROM等を含み、プログラム及びデータに基づいて各種情報処理を実行するように構成される。記憶部22は、例えば、ハードディスクドライブ、ソリッドステートドライブ等で構成される。記憶部22は、検査プログラム221、学習結果データ125等の各種情報を記憶する。
That is, the
検査プログラム221は、学習済みの推定器50を利用して、対象画像81に写る製品Rの外観検査を実施する後述の情報処理(図10)を検査装置2に実行させるためのプログラムである。検査プログラム221は、この情報処理の一連の命令を含む。詳細は後述する。
The
通信インタフェース23は、例えば、有線LANモジュール、無線LANモジュール等であり、ネットワークを介した有線又は無線通信を行うためのインタフェースである。検査装置2は、この通信インタフェース23を利用することで、ネットワークを介したデータ通信を他の情報処理装置(例えば、推定器生成装置1)と行うことができる。
The
入力装置24は、例えば、マウス、キーボード等の入力を行うための装置である。また、出力装置25は、例えば、ディスプレイ、スピーカ等の出力を行うための装置である。オペレータは、入力装置24及び出力装置25を利用することで、検査装置2を操作することができる。
The
ドライブ26は、例えば、CDドライブ、DVDドライブ等であり、記憶媒体92に記憶されたプログラムを読み込むためのドライブ装置である。上記検査プログラム221及び学習結果データ125のうちの少なくともいずれかは、記憶媒体92に記憶されていてもよい。また、検査装置2は、記憶媒体92から、上記検査プログラム221及び学習結果データ125のうちの少なくともいずれかを取得してもよい。
The
外部インタフェース27は、例えば、USB(Universal Serial Bus)ポート、専用ポート等であり、外部装置と接続するためのインタフェースである。外部インタフェース27の種類及び数は、接続される外部装置の種類及び数に応じて適宜選択されてよい。本実施形態では、検査装置2は、外部インタフェース27を介して、カメラCAに接続される。
The
カメラCAは、製品Rを写した対象画像81を取得するのに利用される。カメラCAの種類及び配置場所は、特に限定されなくてもよく、実施の形態に応じて適宜決定されてよい。カメラCAには、例えば、デジタルカメラ、ビデオカメラ等の公知のカメラが利用されてよい。また、カメラCAは、製品Rが搬送される製造ラインの近傍に配置されてよい。なお、カメラCAが通信インタフェースを備える場合、検査装置4は、外部インタフェース27ではなく、通信インタフェース23を介して、カメラCAに接続されてもよい。
The camera CA is used to acquire the
なお、検査装置2の具体的なハードウェア構成に関して、上記推定器生成装置1と同様に、実施の形態に応じて、適宜、構成要素の省略、置換及び追加が可能である。例えば、制御部21は、複数のハードウェアプロセッサを含んでもよい。ハードウェアプロセッサは、マイクロプロセッサ、FPGA、DSP等で構成されてよい。記憶部22は、制御部21に含まれるRAM及びROMにより構成されてもよい。通信インタフェース23、入力装置24、出力装置25、ドライブ26及び外部インタフェース27の少なくともいずれかは省略されてもよい。検査装置2は、複数台のコンピュータで構成されてもよい。この場合、各コンピュータのハードウェア構成は、一致していてもよいし、一致していなくてもよい。また、検査装置2は、提供されるサービス専用に設計された情報処理装置の他、汎用のサーバ装置、汎用のデスクトップPC、ノートPC、タブレットPC、スマートフォンを含む携帯電話等が用いられてよい。
Regarding the specific hardware configuration of the
[ソフトウェア構成]
<推定器生成装置>
次に、図4を用いて、本実施形態に係る推定器生成装置1のソフトウェア構成の一例について説明する。図4は、本実施形態に係る推定器生成装置1のソフトウェア構成の一例を模式的に例示する。
[Software configuration]
<Estimator generator>
Next, an example of the software configuration of the estimator generator 1 according to the present embodiment will be described with reference to FIG. FIG. 4 schematically illustrates an example of the software configuration of the estimator generator 1 according to the present embodiment.
推定器生成装置1の制御部11は、記憶部12に記憶された推定器生成プログラム121をRAMに展開する。そして、制御部11は、RAMに展開された推定器生成プログラム121をCPUにより解釈及び実行して、各構成要素を制御する。これによって、図4に示されるとおり、本実施形態に係る推定器生成装置1は、データ取得部111、抽出部112、拡大処理部113、学習処理部114、及び保存処理部115をソフトウェアモジュールとして備えるコンピュータとして動作する。すなわち、本実施形態では、推定器生成装置1の各ソフトウェアモジュールは、制御部11(CPU)により実現される。
The
データ取得部111は、外観検査の対象となる製品Rを写した学習画像61、及び製品Rに含まれる欠陥の種別を示すラベル63の組み合わせによりそれぞれ構成された複数の学習データセット60を取得する。抽出部112は、各学習データセット60に含まれる学習画像61から1又は複数の第1特徴71を抽出する。拡大処理部113は、抽出された1又は複数の第1特徴71に拡大処理を適用することで、1又は複数の第1特徴71とは異なる1又は複数の第2特徴73を生成する。
The data acquisition unit 111 acquires a plurality of learning
学習処理部114は、機械学習を実施する対象となる推定器50を保持する。学習処理部114は、機械学習を行うことで、1又は複数の第1特徴71及び1又は複数の第2特徴73の少なくともいずれかから、対応するラベル63と一致するように、学習画像61に写る製品Rに含まれる欠陥の種別を推定するように訓練された推定器50を構築する。保存処理部115は、構築された学習済みの推定器50に関する情報を学習結果データ125として記憶部12に保存する。
The learning processing unit 114 holds an
なお、「推定」することは、例えば、グループ分け(分類、識別)により離散値(クラス)を導出すること、及び回帰により連続値を導出することのいずれかであってよい。ラベル63のデータ形式は、製品Rに含まれ得る欠陥の種別を示す形態(すなわち、推定器50の出力形式)に応じて適宜選択されてよい。クラス等の離散値で欠陥の種別を表現する場合、ラベル63は、離散値の数値データにより構成されてよい。あるいは、対応する種別の欠陥の存在する確率等の連続値で欠陥の種別を表現する場合、ラベル63は、連続値の数値データにより構成されてよい。
In addition, "estimation" may be either, for example, deriving a discrete value (class) by grouping (classification, identification) or deriving a continuous value by regression. The data format of the
(推定器)
次に、推定器50の構成の一例について説明する。図4に示されるとおり、本実施形態に係る推定器50は、ニューラルネットワークにより構成されている。具体的には、推定器50は、いわゆる深層学習に用いられる多層構造のニューラルネットワークにより構成されており、入力層501、中間層(隠れ層)503、及び出力層505を備えている。
(Estimator)
Next, an example of the configuration of the
なお、図4の例では、推定器50を構成するニューラルネットワークは、1層の中間層503を備えており、入力層501の出力が中間層503に入力され、中間層503の出力が出力層505に入力されている。ただし、推定器50の構成は、このような例に限定されなくてもよい。中間層503の数は、1層に限られなくてもよい。推定器50は、2層以上の中間層503を備えてもよい。
In the example of FIG. 4, the neural network constituting the
各層(501、503、505)は、1又は複数のニューロンを備えている。各層(501、503、505)に含まれるニューロンの数は、実施の形態に応じて適宜設定されてよい。隣接する層のニューロン同士は適宜結合され、各結合には重み(結合荷重)が設定されている。図4の例では、各ニューロンは、隣接する層の全てのニューロンと結合されている。しかしながら、ニューロンの結合は、このような例に限定されなくてもよく、実施の形態に応じて適宜設定されてよい。 Each layer (501, 503, 505) comprises one or more neurons. The number of neurons contained in each layer (501, 503, 505) may be appropriately set according to the embodiment. Neurons in adjacent layers are appropriately connected to each other, and a weight (bonding load) is set for each connection. In the example of FIG. 4, each neuron is connected to all neurons in adjacent layers. However, the connection of neurons does not have to be limited to such an example, and may be appropriately set according to the embodiment.
各ニューロンには閾値が設定されており、基本的には、各入力と各重みとの積の和が閾値を超えているか否かによって各ニューロンの出力が決定される。つまり、これらの各ニューロン間の結合の重み及び各ニューロンの閾値は、演算処理に利用される推定器50のパラメータの一例である。学習処理部114は、1又は複数の第1特徴71及び1又は複数の第2特徴73の少なくともいずれかを入力層501に入力し、これらのパラメータを利用して、推定器50の演算処理を実行する。
A threshold is set for each neuron, and basically, the output of each neuron is determined by whether or not the sum of the products of each input and each weight exceeds the threshold. That is, the weight of the connection between each of these neurons and the threshold value of each neuron are examples of the parameters of the
この演算処理の結果、学習処理部114は、学習画像61に写る製品Rの良否(すなわち、欠陥の種別)を推定した結果に対応する出力値を出力層505から取得する。続いて、学習処理部114は、取得した出力値とラベル63の値との誤差を算出する。そして、学習処理部114は、算出される誤差の和が小さくなるように、推定器50のパラメータの値を調節する。出力層505から得られる出力値とラベル63の値との誤差の和が閾値以下になるまで、学習処理部114は、推定器50のパラメータの値の調節を繰り返す。これにより、学習処理部114は、各学習データセット60について、学習画像61から導出された1又は複数の第1特徴71及び1又は複数の第2特徴73の少なくともいずれかを入力すると、当該学習画像61に関連付けられたラベル63により示される欠陥の種別に対応する出力値を出力するように訓練された推定器50を構築する。
As a result of this arithmetic processing, the learning processing unit 114 acquires an output value corresponding to the result of estimating the quality (that is, the type of defect) of the product R shown in the
この機械学習の処理が完了した後、保存処理部115は、構築された学習済みの推定器50の構成(例えば、ニューラルネットワークの層数、各層におけるニューロンの個数、ニューロン同士の結合関係、各ニューロンの伝達関数)、及び演算パラメータ(例えば、各ニューロン間の結合の重み、各ニューロンの閾値)を示す情報を学習結果データ125として生成する。そして、保存処理部115は、生成した学習結果データ125を記憶部12に保存する。
After the processing of this machine learning is completed, the preservation processing unit 115 determines the configuration of the constructed trained estimator 50 (for example, the number of layers of the neural network, the number of neurons in each layer, the connection relationship between neurons, and each neuron. Information indicating the transmission function) and the arithmetic parameters (for example, the weight of the connection between each neuron, the threshold value of each neuron) is generated as the learning
<検査装置>
次に、図5を用いて、本実施形態に係る検査装置2のソフトウェア構成の一例について説明する。図5は、本実施形態に係る検査装置2のソフトウェア構成の一例を模式的に例示する。
<Inspection equipment>
Next, an example of the software configuration of the
検査装置2の制御部21は、記憶部22に記憶された検査プログラム221をRAMに展開する。そして、制御部21は、RAMに展開された検査プログラム221をCPUにより解釈及び実行して、各構成要素を制御する。これによって、図5に示されるとおり、本実施形態に係る検査装置2は、画像取得部211、抽出部212、検査部213、及び出力部214をソフトウェアモジュールとして備えるコンピュータとして動作する。すなわち、本実施形態では、検査装置2の各ソフトウェアモジュールも、上記推定器生成装置1と同様に、制御部21(CPU)により実現される。
The
画像取得部211は、外観検査の対象となる製品Rを写した対象画像81を取得する。例えば、画像取得部211は、カメラCAにより製品Rを撮影することで対象画像81を取得する。抽出部212は、取得した対象画像81から1又は複数の特徴83を抽出する。検査部213は、学習結果データ125を保持することで、推定器生成装置1により構築された学習済みの推定器50を含んでいる。具体的には、検査部213は、学習結果データ125を参照して、学習済みの推定器50の設定を行う。そして、検査部213は、抽出した1又は複数の特徴83を学習済みの推定器50に入力し、学習済みの推定器50の演算処理を実行することで、製品Rに欠陥が含まれるか否かを検査(すなわち、製品Rの良否を判定)した結果に対応する出力値を学習済みの推定器50から取得する。これにより、検査部213は、学習済みの推定器50を利用して、抽出した1又は複数の特徴83に基づいて、対象画像81に写る製品Rに欠陥が含まれるか否かを検査する。出力部214は、検査の結果に関する情報を出力する。
The image acquisition unit 211 acquires the
<その他>
推定器生成装置1及び検査装置2の各ソフトウェアモジュールに関しては後述する動作例で詳細に説明する。なお、本実施形態では、推定器生成装置1及び検査装置2の各ソフトウェアモジュールがいずれも汎用のCPUによって実現される例について説明している。しかしながら、以上のソフトウェアモジュールの一部又は全部が、1又は複数の専用のプロセッサにより実現されてもよい。また、推定器生成装置1及び検査装置2それぞれのソフトウェア構成に関して、実施形態に応じて、適宜、ソフトウェアモジュールの省略、置換及び追加が行われてもよい。
<Others>
Each software module of the estimator generator 1 and the
§3 動作例
[推定器生成装置]
次に、図6を用いて、本実施形態に係る推定器生成装置1の動作例について説明する。図6は、本実施形態に係る推定器生成装置1の処理手順の一例を示す。以下で説明する処理手順は、本発明の「推定器生成方法」の一例である。ただし、以下で説明する処理手順は一例に過ぎず、各処理は可能な限り変更されてよい。また、以下で説明する処理手順について、実施の形態に応じて、適宜、ステップの省略、置換、及び追加が可能である。
§3 Operation example [Estimator generator]
Next, an operation example of the estimator generator 1 according to the present embodiment will be described with reference to FIG. FIG. 6 shows an example of the processing procedure of the estimator generator 1 according to the present embodiment. The processing procedure described below is an example of the "estimator generation method" of the present invention. However, the processing procedure described below is only an example, and each processing may be changed as much as possible. Further, with respect to the processing procedure described below, steps can be omitted, replaced, and added as appropriate according to the embodiment.
(ステップS101)
ステップS101では、制御部11は、データ取得部111として動作し、学習画像61及びラベル63の組み合わせによりそれぞれ構成された複数の学習データセット60を取得する。
(Step S101)
In step S101, the
複数の学習データセット60を取得する方法は、特に限定されなくてもよく、実施の形態に応じて適宜選択されてよい。例えば、カメラ及び製品Rを用意し、欠陥のある又は欠陥のない製品Rをカメラにより撮影する。これにより、学習画像61を生成することができる。そして、学習画像61に写る製品Rに含まれる欠陥の種別(欠陥が無いことも含む)を示すラベル63を適宜生成し、生成したラベル63を対応する学習画像61に関連付ける。これにより、各学習データセット60を生成することができる。
The method for acquiring the plurality of training data sets 60 does not have to be particularly limited, and may be appropriately selected depending on the embodiment. For example, a camera and a product R are prepared, and a defective or non-defective product R is photographed by the camera. As a result, the learning
この学習データセット60の生成は、コンピュータの動作により自動的に行われてもよいし、オペレータの操作により手動的に行われてもよい。また、学習データセット60を生成する情報処理は、推定器生成装置1において実行されてもよいし、推定器生成装置1以外の他のコンピュータにおいて実行されてもよい。
The generation of the
各学習データセット60を推定器生成装置1が生成する場合、制御部11は、自動的又はオペレータの操作により手動的に上記情報処理を実行することで、複数の学習データセット60を取得する。一方、各学習データセット60を他のコンピュータが生成する場合、制御部11は、例えば、ネットワーク、記憶媒体91等を介して、他のコンピュータにより生成された複数の学習データセット60を取得する。
When the estimator generator 1 generates each learning
なお、ラベル63のデータ形式は、上記のとおり、推定器50の出力形式に応じて適宜選択されてよい。例えば、ラベル63は、製品Rの良否を2値で示すように設定されてよい。また、例えば、ラベル63は、製品Rが良品である(すなわち、欠陥が無い)確率又は製品Rに欠陥が存在する確率を連続値で示すように設定されてもよい。また、例えば、ラベル63は、欠陥のある箇所等を示すように設定されてもよい。
As described above, the data format of the
取得する学習データセット60の件数は、特に限定されなくてもよく、実施の形態に応じて適宜決定されてよい。複数の学習データセット60を取得すると、制御部11は、次のステップS102に処理を進める。
The number of learning
(ステップS102)
ステップS102では、制御部11は、抽出部112として動作し、各学習データセット60に含まれる学習画像61から1又は複数の第1特徴71を抽出する。
(Step S102)
In step S102, the
図7は、本実施形態に係る特徴抽出処理の一例を模式的に例示する。本実施形態では、制御部11は、特徴抽出処理として畳み込み処理を各学習画像61に適用することで、各学習画像61から第1特徴71を抽出する。これにより、1又は複数の第1特徴71は、学習画像61よりもサイズの小さい特徴画像として抽出される。
FIG. 7 schematically illustrates an example of the feature extraction process according to the present embodiment. In the present embodiment, the
畳み込み処理は、画像と所定のフィルタとの相関を算出する演算処理に相当する。制御部11は、例えば、学習画像61の一部の領域に畳み込み処理を適用することで、学習画像61よりもサイズの小さい特徴画像を学習画像61から抽出してもよい。或いは、制御部11は、例えば、学習画像61に畳み込み処理を適用した後、得られた画像にプーリング処理を更に適用することにより、学習画像61よりもサイズの小さい特徴画像を学習画像61から抽出してもよい。プーリング処理は、画像内に表れる特徴の微小な位置変化に対する応答の不変性を得るために、対象領域内の複数の画素を1つの画素に集約する演算処理に相当する。この畳み込み処理及びプーリング処理は、一般的な画像処理により実行されてもよいし、学習済みの学習モデル(例えば、畳み込み層及びプーリング層を備える畳み込みニューラルネットワーク)を利用して実行されてもよい。また、畳み込み処理及びプーリング処理それぞれを適用する回数は、実施の形態に応じて適宜選択されてよい。
The convolution process corresponds to an arithmetic process for calculating the correlation between an image and a predetermined filter. For example, the
特徴画像の縦幅(h)及び横幅(w)はそれぞれ、学習画像61の縦幅(H)及び横幅(W)それぞれよりも小さくなるように適宜決定される。学習画像61の一部の領域に畳み込み処理を適用する場合、抽出される特徴画像のサイズは、畳み込み処理を適用する範囲に応じて決定される。また、プーリング処理を適用する場合、抽出される特徴画像のサイズは、プーリング処理のウィンドウサイズ及び適用回数に応じて決定される。制御部11は、畳み込み処理及びプーリング処理のこれらのパラメータを適宜決定することで、抽出される特徴画像のサイズを決定してよい。各特徴画像は、「特徴マップ」と称されてもよい。各第1特徴71に対応する特徴画像には、欠陥に関する像が含まれ得る。
The vertical width (h) and the horizontal width (w) of the feature image are appropriately determined so as to be smaller than the vertical width (H) and the horizontal width (W) of the learning
抽出する第1特徴71の数は、実施の形態に応じて適宜設定されてよい。制御部11は、各パラメータを変更しながら、上記いずれかの処理を学習画像61に適用することで、複数の異なる第1特徴71を学習画像61から抽出することができる。複数の第1特徴71を学習画像61から抽出する場合、各第1特徴71に対応する特徴画像のサイズは、互いに一致していてもよいし、互いに異なっていてもよい。1又は複数の第1特徴71を抽出すると、制御部11は、次のステップS103に処理を進める。
The number of the
ただし、第1特徴71の種類及び第1特徴71を抽出する方法は、このような例に限定されなくてもよい。第1特徴71は、学習画像61から導出可能な何らかの情報(特に、推定対象(本実施形態では、欠陥)に関連し得る情報)であれば、その種類及びデータ形式は、特に限定されなくてもよく、実施の形態に応じて適宜選択されてよい。また、第1特徴71を抽出する方法は、第1特徴71の種類及びデータ形式に応じて、実施の形態に応じて適宜選択されてよい。第1特徴71の抽出には、例えば、一般的な画像処理(例えば、エッジ抽出)、SIFT、学習済みの学習モデル(例えば、畳み込みニューラルネットワーク)等が用いられてよい。
However, the type of the
(ステップS103)
ステップS103では、制御部11は、拡大処理部113として動作し、抽出された1又は複数の第1特徴71に拡大処理を適用することで、1又は複数の第1特徴71とは異なる1又は複数の第2特徴73を生成する。
(Step S103)
In step S103, the
拡大処理は、1又は複数の特徴(第1特徴71)から異なる特徴(第2特徴73)を導出するための情報処理である。この拡大処理には、例えば、複数の特徴を合成する処理、幾何的な変換等により特徴を変換する処理等が用いられてよい。また、本実施形態では、第1特徴71は特徴画像として抽出される。そのため、特徴を変換する処理には、所定のノイズ(ホワイトノイズ、ランダムノイズ等)を特徴画像に合成する処理、特徴画像に含まれる画素を変換する処理等が用いられてよい。画素の変換には、色変換、濃度変換等が含まれてよく、これらの変換には、所定の変換関数が用いられてよい。本実施形態では、制御部11は、以下の2つの方法の少なくともいずれかを採用することにより、1又は複数の第1特徴71から第2特徴73を導出する。
The enlargement processing is information processing for deriving different features (second feature 73) from one or more features (first feature 71). For this enlargement processing, for example, a process of synthesizing a plurality of features, a process of converting features by geometric conversion, or the like may be used. Further, in the present embodiment, the
(1)第1の方法
まず、図8Aを用いて、第1の方法について説明する。図8Aは、第1の方法(重み付け合成)による拡大処理の一例を模式的に例示する。第1の方法では、各第1特徴71には重みが設定されている。各第1特徴71に対する重みを設定する方法は、特に限定されなくてもよく、実施の形態に応じて適宜選択されてよい。各第1特徴71に対する重みは、ランダムに決定されてもよいし、オペレータの入力により決定されてよい。制御部11は、設定された重みを各第1特徴71にかけることで、各第1特徴71の重み付けを行う。そして、制御部11は、重み付けされた各第1特徴71を合成することで、各第1特徴71とは異なる第2特徴73を生成する。
(1) First Method First, the first method will be described with reference to FIG. 8A. FIG. 8A schematically illustrates an example of the enlargement processing by the first method (weighted synthesis). In the first method, weights are set for each
図8Aの具体例では、複数の第1特徴71のうち3つの第1特徴711~713(特徴画像)を合成する場面が模式的に示されている。この具体例では、制御部11は、各第1特徴711~713(特徴画像)の各画素に各重みW1~W3を乗算する。そして、制御部11は、この乗算により得られた各画像を足し合わせることで、重み付けされた各第1特徴711~713(特徴画像)を合成する。これにより、制御部11は、各第1特徴711~713から新たな第2特徴73(特徴画像)を生成することができる。
In the specific example of FIG. 8A, a scene in which three
ただし、合成する第1特徴71の数は、3つに限定されなくてもよく、2つであってもよいし、4つ以上であってもよい。制御部11は、ステップS102で抽出した複数の第1特徴71から第2特徴73の生成に利用する複数の第1特徴71を適宜選択してよい。また、第1の方法により生成する第2特徴73の数は、特に限定されなくてもよく、実施の形態に応じて適宜選択されてよい。制御部11は、各第1特徴71に適用する重みを変更すること、及び合成する第1特徴71を変更することの少なくともいずれかにより、複数の異なる第2特徴73を生成することができる。合成する第1特徴71は、ランダムに選択されてもよいし、オペレータの指定により選択されてもよい。
However, the number of the
なお、図8Bに示されるとおり、合成する各第1特徴71に対応する特徴画像のサイズが異なる場合には、制御部11は、各特徴画像のサイズを一致させるための前処理を実行する。図8Bは、サイズの異なる複数の第1特徴71を取り扱う場面の一例を模式的に例示する。図8Bの具体例では、3つの第1特徴711~713(特徴画像)それぞれのサイズが異なる場面が模式的に示されている。この具体例では、制御部11は、各第1特徴711~713(特徴画像)をフィルタリングすることで、各第1特徴711~713(特徴画像)のサイズを互いに一致するように調節する。画像のサイズを調節するフィルタリングには、例えば、最近傍フィルタリング(nearest neighbor filtering)等の公知の画像処理のフィルタリングが用いられてよい。なお、画像のサイズを調整する変換処理は、このようなフィルタリングを用いた例に限られなくてもよい。画像のサイズを調整する変換処理には、例えば、バイリニア補間法(bilinear interpolation)、トリリニア補間法(trilinear interpolation)等の線形補間法、Guided Backpropagation等のネットワークによる方法が採用されてもよい。
As shown in FIG. 8B, when the sizes of the feature images corresponding to the
フィルタリング後の各第1特徴711~713(特徴画像)のサイズは、特に限定されなくてもよく、実施の形態に応じて適宜決定されてよい。フィルタリング後の各第1特徴711~713(特徴画像)のサイズは、フィルタリング前の第1特徴711~713(特徴画像)のうちのいずれかと一致していてもよいし、フィルタリング前の第1特徴711~713(特徴画像)のいずれとも異なっていてもよい。このように、合成する各第1特徴71のサイズが異なる場合には、制御部11は、前処理として、各第1特徴71のサイズを一致させるように調節する処理を実行する。そして、制御部11は、サイズの調整された各第1特徴71に上記重み付け合成の処理を適用することで、各第1特徴71から第2特徴73を生成することができる。
The size of each of the
(2)第2の方法
次に、図9を用いて、第2の方法について説明する。図9は、第2の方法(幾何変換)による拡大処理の一例を模式的に例示する。図9に示されるとおり、第2の方法では、制御部11は、1又は複数の第1特徴71に対して幾何学的な変換を適用することで、1又は複数の第1特徴71とは異なる第2特徴73を生成する。幾何学的な変換は、特に限定されなくてもよく、実施の形態に応じて適宜決定されてよい。例えば、幾何学的な変換は、平行移動、回転移動、反転、又はこれら組み合わせであってよい。
(2) Second method Next, the second method will be described with reference to FIG. 9. FIG. 9 schematically illustrates an example of enlargement processing by the second method (geometric transformation). As shown in FIG. 9, in the second method, the
第2の方法により生成する第2特徴73の数は、特に限定されなくてもよく、実施の形態に応じて適宜選択されてよい。制御部11は、1つの第1特徴71に対して幾何学的な変換を適用することで、1つの第2特徴73を生成することができる。制御部11は、幾何学的な変換を適用する第1特徴71を変更すること、及び幾何学的な変換のパラメータを変更することの少なくともいずれかにより、複数の異なる第2特徴73を生成することができる。幾何学的な変換を適用する第1特徴71は、ランダムに選択されてもよいし、オペレータの指定により選択されてもよい。また、幾何学的な変換のパラメータは、例えば、平行移動の量、回転移動の量、反転の有無等を規定する。幾何学的な変換の各パラメータの値は、ランダムに決定されてもよいし、オペレータの入力により決定されてもよい。
The number of the second features 73 generated by the second method may not be particularly limited and may be appropriately selected depending on the embodiment. The
以上のとおり、本実施形態では、制御部11は、上記第1の方法及び第2の方法の少なくともいずれかを採用することにより、1又は複数の第1特徴71とは異なる1又は複数の第2特徴73を当該1又は複数の第1特徴71から生成する。1又は複数の第2特徴73を生成すると、制御部11は、次のステップS104に処理を進める。
As described above, in the present embodiment, the
(ステップS104)
ステップS104では、制御部11は、学習処理部114として動作し、機械学習を行うことで、1又は複数の第1特徴71及び1又は複数の第2特徴73の少なくともいずれかから、対応するラベル63と一致するように、学習画像61に写る製品Rに含まれる欠陥の種別を推定するように訓練された推定器50を構築する。
(Step S104)
In step S104, the
まず、制御部11は、機械学習の処理対象となる推定器50を用意する。用意する推定器50の構成、各ニューロン間の結合の重みの初期値、及び各ニューロンの閾値の初期値は、テンプレートにより与えられてもよいし、オペレータの入力により与えられてもよい。また、再学習を行う場合には、制御部11は、過去の機械学習を行うことで得られた学習結果データに基づいて、推定器50を用意してもよい。
First, the
次に、制御部11は、各学習データセット60について、学習画像61から導出した1又は複数の第1特徴71及び1又は複数の第2特徴73の少なくともいずれかを入力データ(訓練データ)として利用し、対応するラベル63を正解データ(教師データ)として利用して、推定器50の学習処理を実行する。入力データとして選択する特徴の数、換言すると、推定器50に入力する特徴の数は、特に限定されなくてもよく、実施の形態に応じて適宜選択されてよい。複数の特徴を推定器50に入力する場合、当該複数の特徴は、第1特徴71のみで構成されてもよいし、第2特徴73のみで構成されてもよいし、第1特徴71及び第2特徴73の両方で構成されてもよい。推定器50に入力する特徴の数は、学習画像61に写る製品Rに含まれる欠陥の種別を推定するのに利用する特徴の数に相当する。
Next, the
つまり、学習画像61から導出された1又は複数の第1特徴71及び1又は複数の第2特徴73から選択された1又は複数の特徴、並びに対応するラベル63により、推定器50の機械学習に利用するためのデータセットが構成される。これにより、本実施形態では、1件の学習データセット60から、推定器50の機械学習にそれぞれ利用可能な複数のデータセットを導出することができる。例えば、上記ステップS102では、制御部11は、学習画像61から4件の第1特徴71を抽出したと想定する。また、上記ステップS103では、制御部11は、4件の第1特徴71から6件の第2特徴73を生成したと想定する。更に、推定器50は、1件の特徴の入力を受け付けるように構成されていると想定する。この場合、制御部11は、1件の学習データセット60から10件のデータセットを導出することができる。制御部11は、各学習データセット60から導出されるこのようなデータセットを利用して、推定器50の学習処理を実行する。この確率的勾配降下法等が用いられてよい。
That is, the machine learning of the
例えば、第1のステップでは、制御部11は、各データセットについて、選択された1又は複数の特徴を入力層501に入力し、入力側から順に各層(501、503、505)に含まれる各ニューロンの発火判定を行う。これにより、制御部11は、選択された1又は複数の特徴から欠陥の種別を推定した結果に対応する出力値を出力層505から取得する。第2のステップでは、制御部11は、取得した出力値とラベル63の値との誤差を算出する。第3のステップでは、制御部11は、誤差逆伝播法により、算出した出力値の誤差を用いて、各層(501、503、505)に含まれる各ニューロン間の結合の重み及び各ニューロンの閾値それぞれの誤差を算出する。第4のステップでは、制御部11は、算出した各誤差により、各ニューロン間の結合の重み及び各ニューロンの閾値それぞれの値の更新を行う。
For example, in the first step, the
制御部11は、上記第1~第4のステップを繰り返すことで、各データセットについて、選択された1又は複数の特徴を入力すると、対応するラベル63と一致する出力値を出力するように、推定器50のパラメータの値を調節する。換言すると、制御部11は、各データセットについて、出力層505から得られる出力値とラベル63の値との誤差の和が閾値以下になるまで、上記第1~第4のステップによる推定器50のパラメータの値の調節を繰り返す。閾値は、実施の形態に応じて適宜設定されてよい。これにより、制御部11は、1又は複数の第1特徴71及び1又は複数の第2特徴73の少なくともいずれかから、対応するラベル63と一致するように、学習画像61に写る製品Rに含まれる欠陥の種別を推定するように訓練された推定器50を構築することができる。この推定器50の機械学習が完了すると、制御部11は、次のステップS105に処理を進める。
By repeating the first to fourth steps, the
(ステップS105)
ステップS105では、制御部11は、保存処理部115として動作し、構築された学習済みの推定器50に関する情報を学習結果データ125として記憶部12に保存する。本実施形態では、制御部11は、ステップS104の機械学習により構築された推定器50の構成及びパラメータを示す情報を学習結果データ125として生成する。そして、制御部11は、生成した学習結果データ125を記憶部12に保存する。これにより、制御部11は、本動作例に係る処理を終了する。
(Step S105)
In step S105, the
なお、学習結果データ125の保存先は、記憶部12に限られなくてもよい。制御部11は、例えば、NAS(Network Attached Storage)等のデータサーバに学習結果データ125を格納してもよい。
The storage destination of the learning
また、学習済みの推定器50を構築した後、制御部11は、生成した学習結果データ125を任意のタイミングで検査装置2に転送してもよい。検査装置2は、推定器生成装置1から転送を受けることで学習結果データ125を取得してもよいし、推定器生成装置1又はデータサーバにアクセスすることで学習結果データ125を取得してもよい。学習結果データ125は、検査装置2に予め組み込まれてもよい。
Further, after constructing the trained
更に、制御部11は、上記ステップS101~S105の処理を定期的に繰り返すことで、学習結果データ125を定期的に更新してもよい。この繰り返す際には、学習データセット60の変更、修正、追加、削除等が適宜実行されてよい。そして、制御部11は、更新した学習結果データ125を学習処理の実行毎に検査装置2に転送することで、検査装置2の保持する学習結果データ125を定期的に更新してもよい。
Further, the
[検査装置]
次に、図10を用いて、本実施形態に係る検査装置2の動作例について説明する。図10は、本実施形態に係る検査装置2の処理手順の一例を例示するフローチャートである。ただし、以下で説明する処理手順は一例に過ぎず、各処理は可能な限り変更されてよい。また、以下で説明する処理手順について、実施の形態に応じて、適宜、ステップの省略、置換、及び追加が可能である。
[Inspection equipment]
Next, an operation example of the
(ステップS201)
ステップS201では、制御部21は、画像取得部211として動作し、外観検査の対象となる製品Rを写した対象画像81を取得する。本実施形態では、検査装置2は、外部インタフェース27を介してカメラCAに接続している。そのため、制御部21は、カメラCAから対象画像81を取得する。この対象画像81は、動画像データであってもよいし、静止画像データであってもよい。対象画像81を取得すると、制御部21は、次のステップS202に処理を進める。
(Step S201)
In step S201, the
ただし、対象画像81を取得する経路は、このような例に限定されなくてもよく、実施の形態に応じて適宜選択されてよい。例えば、検査装置2とは異なる他の情報処理装置が、カメラCAに接続されていてもよい。この場合、制御部21は、他の情報処理装置を介して対象画像81を取得してもよい。
However, the route for acquiring the
(ステップS202)
ステップS202では、制御部21は、抽出部212として動作し、取得した対象画像81から1又は複数の特徴83を抽出する。
(Step S202)
In step S202, the
本ステップS202は、上記ステップS102と同様に処理される。本実施形態では、制御部21は、対象画像81に畳み込み処理を適用することで、対象画像81から1又は複数の特徴83を抽出する。また、抽出する特徴83の数は、上記ステップS104で入力データとして選択された特徴の数、すなわち、推定器50が入力を受け付ける特徴の数と一致するように決定される。1又は複数の特徴83を抽出すると、制御部21は、次のステップS203に処理を進める。
This step S202 is processed in the same manner as in step S102. In the present embodiment, the
(ステップS203)
ステップS203では、制御部21は、検査部213として動作し、学習済みの推定器50を利用して、抽出した1又は複数の特徴83に基づいて、対象画像81に写る製品Rに欠陥が含まれるか否かを検査する。
(Step S203)
In step S203, the
本実施形態では、制御部21は、学習結果データ125を参照して、学習済みの推定器50の設定を行う。次に、制御部21は、抽出した1又は複数の特徴83を推定器50の入力層501に入力し、入力側から順に各層(501、503、505)に含まれる各ニューロンの発火判定を行う。これにより、制御部21は、対象画像81に写る製品Rに欠陥が含まれるか否か(すなわち、製品Rの良否)を推定した結果に対応する出力値を推定器50の出力層505から取得する。制御部21は、推定器50の出力層505から取得した出力値に基づいて、対象画像81に写る製品Rに欠陥が含まれるか否かを検査する。
In the present embodiment, the
なお、製品Rの良否の検査は、推定器50の出力形式に応じて適宜行われてよい。例えば、推定器50から得られる出力値が製品Rの良否を2値で示す場合、制御部21は、推定器50から得られる出力値に応じて、製品Rの良否を特定することができる。また、例えば、推定器50から得られる出力値が、製品Rが良品である確率又は製品Rに欠陥がある確率を連続値で示す場合、制御部21は、推定器50から得られる出力値と閾値とを比較することで、製品Rの良否を判定することができる。また、例えば、推定器50から得られる出力値が欠陥のある箇所を示す場合、制御部21は、推定器50から得られる出力値に基づいて、対象画像81に写る製品Rの良否を判定することができると共に、欠陥が存在する場合にはその欠陥の箇所を特定することができる。
The quality of the product R may be inspected as appropriate according to the output format of the
また、例えば、推定器50から得られる出力値が、製品Rの良否又は欠陥の種別のインデックスを示す場合、検査装置2は、推定器50から得られる出力値と製品Rの良否又は欠陥の種別とを対応付けたテーブル形式等の参照情報(不図示)を記憶部22に保持していてもよい。この場合、制御部21は、この参照情報を参照することにより、推定器50から得られた出力値に応じて、製品Rの良否を判定することができる。
Further, for example, when the output value obtained from the
以上により、制御部21は、学習済みの推定器50を利用して、抽出した1又は複数の特徴83に基づいて、対象画像81に写る製品Rに欠陥が含まれるか否かを検査することができる。製品Rの外観検査が完了すると、制御部21は、次のステップS204に処理を進める。
As described above, the
(ステップS204)
ステップS204では、制御部21は、出力部214として動作し、ステップS203により製品Rの良否を検査した結果に関する情報を出力する。
(Step S204)
In step S204, the
製品Rの良否を検査した結果の出力形式は、特に限定されなくてもよく、実施の形態に応じて適宜選択されてよい。例えば、制御部21は、製品Rの良否を検査した結果をそのまま出力装置25に出力してもよい。また、ステップS203において、製品Rに欠陥があると判定した場合、制御部21は、欠陥を発見したことを知らせるための警告を本ステップS204の出力処理として行ってもよい。また、制御部21は、本ステップS204の出力処理として、製品Rの良否を検査した結果に応じた所定の制御処理を実行してもよい。具体例として、製品の搬送を行う製造ラインに検査装置2が接続されている場合、製品Rに欠陥があると判定したときに、制御部21は、欠陥のある製品Rを欠陥のない製品とは異なる経路で搬送する指令を製造ラインに送信する処理を本ステップS204の出力処理として行ってもよい。
The output format as a result of inspecting the quality of the product R does not have to be particularly limited, and may be appropriately selected depending on the embodiment. For example, the
製品Rの良否を検査した結果に関する情報の出力処理が完了すると、制御部21は、本動作例に係る処理を終了する。なお、制御部21は、製造ライン上を搬送される製品RがカメラCAの撮影範囲に入る度に、ステップS201~S204の一連の処理を実行してもよい。これにより、検査装置2は、製造ライン上を搬送される製品Rの外観検査を行うことができる。
When the output processing of the information regarding the result of inspecting the quality of the product R is completed, the
[特徴]
以上のとおり、本実施形態では、推定器50は、学習画像61から直接的に製品Rの良否を推定するのではなく、ステップS102及びS103により学習画像61から導出された第1特徴71及び第2特徴73の少なくともいずれかから製品Rの良否を推定するように訓練される。上記ステップS102及びS103において、第1特徴71及び第2特徴73は、学習画像61そのものよりも次元が低くなるように導出されるため、第1特徴71及び第2特徴73の有する情報量は学習画像61の情報量よりも少なくなる。そのため、学習画像61から直接的に製品Rの良否を推定するように訓練されるケースと比較して、本実施形態では、推定器50に対する入力データの情報量を抑えることができるため、推定器50の構成を単純化することができる。例えば、推定器50を構成する各層(501、503、505)に含まれるニューロンの数を低減することができる。
[feature]
As described above, in the present embodiment, the
加えて、本実施形態では、ステップS103により、学習画像61より抽出された第1特徴71に拡大処理を適用することで、第1特徴71とは異なる第2特徴73が生成される。これにより、製品Rの良否を導出するための特徴のバリエーションを豊富にすることができる。すなわち、ステップS104における機械学習に利用する訓練データの件数を増やすことができる。そのため、ステップS101で取得される学習データセット60(学習画像61)の件数が少なくても、欠陥推定の一定の精度を担保するのに十分な件数の学習データを用意することができる。したがって、本実施形態に係る推定器生成装置1によれば、推定器50の計算コストを低減しつつ、学習画像61の件数が比較的に少なくても、画像に写る製品Rの良否を高精度に推定可能な推定器50を構築することができる。また、本実施形態に係る検査装置2は、この推定器50を利用することで、ステップS201~204による製品Rの外観検査を高精度かつ高速に実施することができる。
In addition, in the present embodiment, by applying the enlargement processing to the
§4 変形例
以上、本発明の実施の形態を詳細に説明してきたが、前述までの説明はあらゆる点において本発明の例示に過ぎない。本発明の範囲を逸脱することなく種々の改良や変形を行うことができることは言うまでもない。例えば、以下のような変更が可能である。なお、以下では、上記実施形態と同様の構成要素に関しては同様の符号を用い、上記実施形態と同様の点については、適宜説明を省略した。以下の変形例は適宜組み合わせ可能である。
§4 Modifications Although the embodiments of the present invention have been described in detail above, the above description is merely an example of the present invention in all respects. Needless to say, various improvements and modifications can be made without departing from the scope of the present invention. For example, the following changes can be made. In the following, the same reference numerals will be used for the same components as those in the above embodiment, and the same points as in the above embodiment will be omitted as appropriate. The following modifications can be combined as appropriate.
<4.1>
上記実施形態では、推定器50にはいわゆる多層構造の全結合ニューラルネットワークが用いられている。しかしながら、推定器50を構成するニューラルネットワークの構造及び種類は、このような例に限定されなくてもよく、実施の形態に応じて適宜選択されてよい。例えば、推定器50には、畳み込み層及びプーリング層を備える畳み込みニューラルネットワークが利用されてよい。
<4.1>
In the above embodiment, the
また、上記実施形態では、推定器50を構成する学習モデルとしてニューラルネットワークが用いられている。しかしながら、推定器50を構成する学習モデルは、各特徴(71、73)から製品Rの良否を推定するための機械学習を実施可能であれば、その種類は、特に限定されなくてもよく、実施の形態に応じて適宜選択されてよい。
Further, in the above embodiment, a neural network is used as a learning model constituting the
<4.2>
上記実施形態では、学習結果データ125は、推定器50の構成を示す情報を含んでいる。しかしながら、学習結果データ125の構成は、このような例に限定されなくてもよく、実施の形態に応じて適宜決定されてよい。例えば、利用するニューラルネットワークの構成が各装置で共通化されている場合、学習結果データ125は、ニューラルネットワークの構成を示す情報を含んでいなくてもよい。
<4.2>
In the above embodiment, the learning
<4.3>
上記実施形態に係る各情報処理(図6及び図10)について、実施の形態に応じて、適宜、ステップの省略、置換、及び追加が可能である。例えば、上記実施形態に係る推定器生成装置1は、各学習データセット60の学習画像61から抽出された1又は複数の第1特徴71を直接的に取得してもよい。この場合、推定器生成装置1のソフトウェア構成において、抽出部112は省略されてよい。加えて、上記情報処理において、ステップS102の処理は省略されてよい。
<4.3>
For each information processing (FIGS. 6 and 10) according to the above embodiment, steps can be omitted, replaced, and added as appropriate according to the embodiment. For example, the estimator generator 1 according to the above embodiment may directly acquire one or a plurality of
図11は、本変形例に係る推定器生成装置1Aのソフトウェア構成の一例を模式的に例示する。抽出部112が省略される点を除き、本変形例に係る推定器生成装置1Aのハードウェア構成及びソフトウェア構成は、上記実施形態に係る推定器生成装置1と同じであってよい。本変形例に係る推定器生成装置1Aは、1又は複数の第1特徴71を直接的に取得する点及び上記ステップS102を省略する点を除き、上記実施形態に係る推定器生成装置1と同様に動作してもよい。
FIG. 11 schematically illustrates an example of the software configuration of the
すなわち、ステップS101では、推定器生成装置1Aの制御部は、データ取得部111として動作し、製品Rを写した学習画像から抽出された1又は複数の第1特徴71及びラベル63の組み合わせによりそれぞれ構成された複数の学習データセット60Aを取得する。ステップS103では、制御部は、拡大処理部113として動作し、各学習データセット60Aに含まれる1又は複数の第1特徴71に拡大処理を適用することで、1又は複数の第1特徴71とは異なる1又は複数の第2特徴73を生成する。ステップS104では、制御部は、学習処理部114として動作し、機械学習を行うことで、1又は複数の第1特徴71及び1又は複数の第2特徴73の少なくともいずれかから、対応するラベル63と一致するように、学習画像に写る製品Rに含まれる欠陥の種別を推定するように訓練された推定器50を構築する。ステップS105では、制御部は、保存処理部115として動作し、構築された学習済みの推定器50に関する情報を学習結果データ125として保存する。これにより、本変形例に係る推定器生成装置1Aは、上記実施形態と同様に、製品Rの外観検査に利用可能な学習済みの推定器50を生成することができる。
That is, in step S101, the control unit of the
<4.4>
上記実施形態では、画像に写る製品Rの外観検査を実施する場面に本発明を適用した例を示している。しかしながら、本発明の適用範囲は、このような外観検査の例に限られる訳ではない。本発明は、画像に写る対象物の何らかの属性を推定するあらゆる場面に適用可能である。製品Rの写る画像から対象物の写る画像に検査システム100で取り扱う画像を変更することで、対象物の写る画像から何らかの属性を推定する推定システムを適宜構成することができる。
<4.4>
In the above embodiment, an example in which the present invention is applied to a scene where an appearance inspection of a product R shown in an image is performed is shown. However, the scope of application of the present invention is not limited to such an example of visual inspection. The present invention is applicable to all situations in which some attribute of an object in an image is estimated. By changing the image handled by the
図12は、本変形例に係る推定システム100Bの適用場面の一例を模式的に例示する。図12に示されるとおり、本変形例に係る推定システム100Bは、ネットワークを介して接続される推定器生成装置1B及び推定装置2Bを備えている。製品Rの写る画像から対象物の写る画像に取り扱う画像を変更する点を除き、各装置(1B、2B)のハードウェア構成及びソフトウェア構成は、上記実施形態に係る各装置(1、2)と同じであってよい。また、各装置(1B、2B)は、上記実施形態に係る各装置(1、2)と同様に動作してもよい。
FIG. 12 schematically illustrates an example of an application scene of the
すなわち、本変形例に係る推定器生成装置1Bは、対象物RBを写した学習画像61B、及び対象物RBの属性を示すラベル63Bの組み合わせによりそれぞれ構成された複数の学習データセット60Bを取得する。次に、推定器生成装置1Bは、各学習データセット60Bに含まれる学習画像61Bから1又は複数の第1特徴71Bを抽出する。推定器生成装置1Bは、抽出された1又は複数の第1特徴71Bに拡大処理を適用することで、1又は複数の第1特徴71Bとは異なる1又は複数の第2特徴73Bを生成する。そして、推定器生成装置1Bは、機械学習を行うことで、1又は複数の第1特徴71B及び1又は複数の第2特徴73Bの少なくともいずれかから、対応するラベル63Bと一致するように、学習画像61Bに写る対象物RBの属性を推定するように訓練された推定器50Bを構築する。なお、推定器50Bの構成は、上記実施形態に係る推定器50と同じであってよい。
That is, the
また、推定器生成装置1Bは、上記<4.3>と同様に、1又は複数の第1特徴71Bを直接的に取得してもよい。すなわち、推定器生成装置1Bは、対象物RBを写した学習画像61Bから抽出された1又は複数の第1特徴71B、及び対象物RBの属性を示すラベル63Bの組み合わせによりそれぞれ構成された複数の学習データセットを取得してもよい。次に、推定器生成装置1Bは、各学習データセットに含まれる1又は複数の第1特徴71Bに拡大処理を適用することで、1又は複数の第1特徴71Bとは異なる1又は複数の第2特徴73Bを生成してもよい。そして、推定器生成装置1Bは、機械学習を行うことで、1又は複数の第1特徴71B及び1又は複数の第2特徴73Bの少なくともいずれかから、対応するラベル63Bと一致するように、学習画像61Bに写る対象物RBの属性を推定するように訓練された推定器50Bを構築してもよい。
Further, the
図13は、本変形例に係る推定装置2Bのソフトウェア構成の一例を模式的に例示する。推定器生成装置1Bは、構築された学習済みの推定器50Bに関する情報を学習結果データ125Bとして保存する。本変形例に係る推定装置2Bは、当該学習結果データ125Bを適宜取得する。ステップS201では、推定装置2Bの制御部は、画像取得部211として動作し、対象物RBを写した対象画像81Bを取得する。ステップS202では、制御部は、抽出部212として動作し、対象画像81Bから1又は複数の特徴83Bを抽出する。
FIG. 13 schematically illustrates an example of the software configuration of the
ステップS203では、推定装置2Bの制御部は、推定部213Bとして動作し、学習済みの推定器50Bを利用して、抽出した1又は複数の特徴83Bに基づいて、対象画像81Bに写る対象物RBの属性を推定する。具体的に、制御部は、学習結果データ125Bを参照して、学習済みの推定器50Bの設定を行う。続いて、制御部は、抽出した1又は複数の特徴83Bを学習済みの推定器50Bに入力し、学習済みの推定器50Bの演算処理を実行する。この演算処理の結果、推定装置2Bの制御部は、対象物RBの属性を推定した結果に対応する出力値を学習済みの推定器50Bから取得する。ステップS204では、推定装置2Bの制御部は、対象物RBの属性を推定した結果に関する情報を出力する。これにより、本変形例に係る推定システム100Bは、対象物RBを写した画像から何らかの属性を推定するように構成される。
In step S203, the control unit of the
なお、対象物RBは、何らかの属性を推定する対象となり得るものであれば、その種類は、特に限定されなくてもよく、実施の形態に応じて適宜選択されてよい。対象物RBは、例えば、上記外観検査の対象となる製品、人物、人物の身体部位(例えば、顔等)等であってよい。また、推定する対象となる対象物の「属性」は、対象物の何らかの性質に関するものであればよく、推定器により推定可能な対象物のあらゆる種類の属性を含んでもよい。対象物が人物の顔である場合、判定の対象となる属性は、例えば、表情の種別、顔のパーツ(器官を含む)の位置(特定の器官同士の相対位置関係を含む)、顔のパーツの形状、顔のパーツの色、顔のパーツの状態(開度、角度等)、その顔を所有する個人の属性等であってよい。また、対象物が人物の身体である場合、判定の対象となる属性は、例えば、身体のポーズ等であってよい。対象物が作業対象のワークである場合、判定の対象となる属性は、例えば、ワークの位置、姿勢等であってよい。 The type of the object RB may not be particularly limited as long as it can be a target for estimating some attribute, and may be appropriately selected according to the embodiment. The object RB may be, for example, a product, a person, a body part of the person (for example, a face, etc.) to be subject to the visual inspection. Further, the "attribute" of the object to be estimated may be any property related to any property of the object, and may include all kinds of attributes of the object that can be estimated by the estimator. When the object is a person's face, the attributes to be judged are, for example, the type of facial expression, the position of facial parts (including organs) (including the relative positional relationship between specific organs), and facial parts. It may be the shape of the face, the color of the facial part, the state of the facial part (opening, angle, etc.), the attribute of the individual who owns the face, and the like. When the object is the body of a person, the attribute to be determined may be, for example, a pose of the body. When the object is a work to be worked on, the attributes to be determined may be, for example, the position and posture of the work.
100…検査システム、
1…推定器生成装置、
11…制御部、12…記憶部、13…通信インタフェース、
14…入力装置、15…出力装置、16…ドライブ、
111…データ取得部、112…抽出部、
113…拡大処理部、114…学習処理部、
115…保存処理部、
121…推定器生成プログラム、125…学習結果データ、
2…検査装置、
21…制御部、22…記憶部、23…通信インタフェース、
24…入力装置、25…出力装置、26…ドライブ、
27…外部インタフェース、
211…画像取得部、212…抽出部、
213…検査部、214…出力部、
221…検査プログラム、
50…推定器、
501…入力層、503…中間(隠れ)層、505…出力層、
60…学習データセット、
61…学習画像、63…ラベル、
71…第1特徴、73…第2特徴、
81…対象画像、83…特徴、
91・92…記憶媒体
100 ... Inspection system,
1 ... Estimator generator,
11 ... control unit, 12 ... storage unit, 13 ... communication interface,
14 ... input device, 15 ... output device, 16 ... drive,
111 ... Data acquisition unit, 112 ... Extraction unit,
113 ... Enlargement processing unit, 114 ... Learning processing unit,
115 ... Preservation processing unit,
121 ... Estimator generation program, 125 ... Learning result data,
2 ... Inspection equipment,
21 ... Control unit, 22 ... Storage unit, 23 ... Communication interface,
24 ... Input device, 25 ... Output device, 26 ... Drive,
27 ... External interface,
211 ... Image acquisition unit, 212 ... Extraction unit,
213 ... Inspection unit, 214 ... Output unit,
221 ... Inspection program,
50 ... Estimator,
501 ... Input layer, 503 ... Intermediate (hidden) layer, 505 ... Output layer,
60 ... Learning dataset,
61 ... learning image, 63 ... label,
71 ... 1st feature, 73 ... 2nd feature,
81 ... Target image, 83 ... Features,
91/92 ... Storage medium
Claims (8)
前記各学習データセットに含まれる前記学習画像から1又は複数の第1特徴を抽出する抽出部と、
抽出された前記1又は複数の第1特徴に拡大処理を適用することで、前記1又は複数の第1特徴とは異なる1又は複数の第2特徴を生成する拡大処理部と、
機械学習を行うことで、前記1又は複数の第1特徴及び前記1又は複数の第2特徴の少なくともいずれかから、対応するラベルと一致するように、前記学習画像に写る前記製品に含まれる前記欠陥の種別を推定するように訓練された推定器を構築する学習処理部と、
を備え、
前記1又は複数の第1特徴はそれぞれ、前記学習画像よりもサイズの小さい特徴画像として抽出され、
前記複数の第1特徴それぞれには重みが設定されており、
前記拡大処理を適用することは、前記複数の第1特徴のサイズを一致させること、設定された前記重みを、サイズを一致させた前記複数の第1特徴それぞれにかけること、及び重み付けされた前記複数の第1特徴を合成すること、を含む、
推定器生成装置。 A data acquisition unit that acquires a plurality of learning data sets composed of a combination of a learning image showing a product to be visually inspected and a label indicating the type of defect contained in the product, and a data acquisition unit.
An extraction unit that extracts one or a plurality of first features from the training image included in each training data set.
An enlargement processing unit that generates one or more second features different from the one or more first features by applying the enlargement processing to the extracted one or more first features.
By performing machine learning, the product included in the product to be reflected in the training image so as to match the corresponding label from at least one of the one or more first features and the one or more second features. A learning processor that builds an estimator trained to estimate the type of defect,
Equipped with
Each of the one or a plurality of first features is extracted as a feature image having a size smaller than that of the learning image.
Weights are set for each of the plurality of first features.
Applying the enlargement process means matching the sizes of the plurality of first features, applying the set weights to each of the plurality of size-matched first features, and weighting the first feature. Including synthesizing multiple first features,
Estimator generator.
請求項1に記載の推定器生成装置。 Applying the enlargement process includes applying a geometric transformation to the one or more first features.
The estimator generator according to claim 1.
請求項2に記載の推定器生成装置。 The geometric transformation is translation, rotational movement, inversion, or a combination thereof.
The estimator generator according to claim 2.
取得した前記対象画像から特徴を抽出する抽出部と、
請求項1から3のいずれか1項に記載の推定器生成装置と、
前記推定器生成装置により構築された前記推定器を利用し、抽出した前記特徴に基づいて、前記対象画像に写る前記製品に欠陥が含まれるか否かを検査する検査部と、
前記検査の結果に関する情報を出力する出力部と、
を備える、
検査システム。 An image acquisition unit that acquires a target image of a product that is subject to visual inspection,
An extraction unit that extracts features from the acquired target image,
The estimator generator according to any one of claims 1 to 3, and the estimator generator.
Using the estimator constructed by the estimator generator, an inspection unit that inspects whether or not the product shown in the target image contains defects based on the extracted features, and an inspection unit.
An output unit that outputs information about the results of the inspection, and
To prepare
Inspection system .
外観検査の対象となる製品を写した学習画像、及び前記製品に含まれる欠陥の種別を示すラベルの組み合わせによりそれぞれ構成された複数の学習データセットを取得するステップと、
前記各学習データセットに含まれる前記学習画像から1又は複数の第1特徴を抽出するステップと、
抽出された前記1又は複数の第1特徴に拡大処理を適用することで、前記1又は複数の第1特徴とは異なる1又は複数の第2特徴を生成するステップと、
機械学習を行うことで、前記1又は複数の第1特徴及び前記1又は複数の第2特徴の少なくともいずれかから、対応するラベルと一致するように、前記学習画像に写る前記製品に含まれる前記欠陥の種別を推定するように訓練された推定器を構築するステップと、
を実行し、
前記1又は複数の第1特徴はそれぞれ、前記学習画像よりもサイズの小さい特徴画像として抽出され、
前記複数の第1特徴それぞれには重みが設定されており、
前記拡大処理を適用することは、前記複数の第1特徴のサイズを一致させること、設定された前記重みを、サイズを一致させた前記複数の第1特徴それぞれにかけること、及び重み付けされた前記複数の第1特徴を合成すること、を含む、
推定器生成方法。 The computer
A step of acquiring a plurality of training data sets composed of a combination of a training image showing a product to be visually inspected and a label indicating the type of defect contained in the product, and a step of acquiring a plurality of training data sets.
A step of extracting one or more first features from the training image included in each training data set, and
A step of generating one or more second features different from the one or more first features by applying the expansion process to the extracted one or more first features.
By performing machine learning, the product included in the product to be reflected in the training image so as to match the corresponding label from at least one of the one or more first features and the one or more second features. Steps to build an estimator trained to estimate the type of defect,
And run
Each of the one or a plurality of first features is extracted as a feature image having a size smaller than that of the learning image.
Weights are set for each of the plurality of first features.
Applying the enlargement process means matching the sizes of the plurality of first features, applying the set weights to each of the plurality of size-matched first features, and weighting the first feature. Including synthesizing multiple first features,
Estimator generation method.
外観検査の対象となる製品を写した学習画像、及び前記製品に含まれる欠陥の種別を示すラベルの組み合わせによりそれぞれ構成された複数の学習データセットを取得するステップと、
前記各学習データセットに含まれる前記学習画像から1又は複数の第1特徴を抽出するステップと、
抽出された前記1又は複数の第1特徴に拡大処理を適用することで、前記1又は複数の第1特徴とは異なる1又は複数の第2特徴を生成するステップと、
機械学習を行うことで、前記1又は複数の第1特徴及び前記1又は複数の第2特徴の少なくともいずれかから、対応するラベルと一致するように、前記学習画像に写る前記製品に含まれる前記欠陥の種別を推定するように訓練された推定器を構築するステップと、
を実行させ、
前記1又は複数の第1特徴はそれぞれ、前記学習画像よりもサイズの小さい特徴画像として抽出され、
前記複数の第1特徴それぞれには重みが設定されており、
前記拡大処理を適用することは、前記複数の第1特徴のサイズを一致させること、設定された前記重みを、サイズを一致させた前記複数の第1特徴それぞれにかけること、及び重み付けされた前記複数の第1特徴を合成すること、を含む、
推定器生成プログラム。 On the computer
A step of acquiring a plurality of training data sets composed of a combination of a training image showing a product to be visually inspected and a label indicating the type of defect contained in the product, and a step of acquiring a plurality of training data sets.
A step of extracting one or more first features from the training image included in each training data set, and
A step of generating one or more second features different from the one or more first features by applying the expansion process to the extracted one or more first features.
By performing machine learning, the product included in the product to be reflected in the training image so as to match the corresponding label from at least one of the one or more first features and the one or more second features. Steps to build an estimator trained to estimate the type of defect,
To execute,
Each of the one or a plurality of first features is extracted as a feature image having a size smaller than that of the learning image.
Weights are set for each of the plurality of first features.
Applying the enlargement process means matching the sizes of the plurality of first features, applying the set weights to each of the plurality of size-matched first features, and weighting the first feature. Including synthesizing multiple first features,
Estimator generator.
前記各学習データセットに含まれる前記学習画像から1又は複数の第1特徴を抽出する抽出部と、
抽出された前記1又は複数の第1特徴に拡大処理を適用することで、前記1又は複数の第1特徴とは異なる1又は複数の第2特徴を生成する拡大処理部と、
機械学習を行うことで、前記1又は複数の第1特徴及び前記1又は複数の第2特徴の少なくともいずれかから、対応するラベルと一致するように、前記学習画像に写る前記対象物の属性を推定するように訓練された推定器を構築する学習処理部と、
を備え、
前記1又は複数の第1特徴はそれぞれ、前記学習画像よりもサイズの小さい特徴画像として抽出され、
前記複数の第1特徴それぞれには重みが設定されており、
前記拡大処理を適用することは、前記複数の第1特徴のサイズを一致させること、設定された前記重みを、サイズを一致させた前記複数の第1特徴それぞれにかけること、及び重み付けされた前記複数の第1特徴を合成すること、を含む、
推定器生成装置。 A data acquisition unit that acquires a plurality of learning data sets each composed of a combination of a learning image showing an object and a label indicating the attribute of the object, and a data acquisition unit.
An extraction unit that extracts one or a plurality of first features from the training image included in each training data set.
An enlargement processing unit that generates one or more second features different from the one or more first features by applying the enlargement processing to the extracted one or more first features.
By performing machine learning, the attributes of the object appearing in the training image can be determined from at least one of the one or more first features and the one or more second features so as to match the corresponding label. A learning processor that builds an estimator trained to estimate,
Equipped with
Each of the one or a plurality of first features is extracted as a feature image having a size smaller than that of the learning image.
Weights are set for each of the plurality of first features.
Applying the enlargement process means matching the sizes of the plurality of first features, applying the set weights to each of the plurality of size-matched first features, and weighting the first feature. Including synthesizing multiple first features,
Estimator generator.
前記各学習データセットに含まれる前記1又は複数の第1特徴に拡大処理を適用することで、前記1又は複数の第1特徴とは異なる1又は複数の第2特徴を生成する拡大処理部と、
機械学習を行うことで、前記1又は複数の第1特徴及び前記1又は複数の第2特徴の少なくともいずれかから、対応するラベルと一致するように、前記学習画像に写る前記対象物の属性を推定するように訓練された推定器を構築する学習処理部と、
を備え、
前記1又は複数の第1特徴はそれぞれ、前記学習画像よりもサイズの小さい特徴画像として抽出され、
前記複数の第1特徴それぞれには重みが設定されており、
前記拡大処理を適用することは、前記複数の第1特徴のサイズを一致させること、設定された前記重みを、サイズを一致させた前記複数の第1特徴それぞれにかけること、及び重み付けされた前記複数の第1特徴を合成すること、を含む、
推定器生成装置。
A data acquisition unit that acquires a plurality of learning data sets each composed of a combination of one or a plurality of first features extracted from a learning image of an object and labels indicating the attributes of the object, and a data acquisition unit.
An expansion processing unit that generates one or a plurality of second features different from the one or a plurality of first features by applying the enlargement processing to the one or a plurality of first features included in each learning data set. ,
By performing machine learning, the attributes of the object appearing in the training image can be determined from at least one of the one or more first features and the one or more second features so as to match the corresponding label. A learning processor that builds an estimator trained to estimate,
Equipped with
Each of the one or a plurality of first features is extracted as a feature image having a size smaller than that of the learning image.
Weights are set for each of the plurality of first features.
Applying the enlargement process means matching the sizes of the plurality of first features, applying the set weights to each of the plurality of size-matched first features, and weighting the first feature. Including synthesizing multiple first features,
Estimator generator.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2018190513A JP7070308B2 (en) | 2018-10-05 | 2018-10-05 | Estimator generator, inspection device, estimator generator method, and estimator generator |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2018190513A JP7070308B2 (en) | 2018-10-05 | 2018-10-05 | Estimator generator, inspection device, estimator generator method, and estimator generator |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2020060398A JP2020060398A (en) | 2020-04-16 |
JP7070308B2 true JP7070308B2 (en) | 2022-05-18 |
Family
ID=70219553
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2018190513A Active JP7070308B2 (en) | 2018-10-05 | 2018-10-05 | Estimator generator, inspection device, estimator generator method, and estimator generator |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP7070308B2 (en) |
Families Citing this family (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP7581811B2 (en) | 2020-12-04 | 2024-11-13 | 東洋製罐グループホールディングス株式会社 | Image processing system and image processing program |
KR102524151B1 (en) * | 2020-12-14 | 2023-04-21 | 주식회사 아이디알인비전 | Labeling learning method of artificial intelligence machine for smart products inspection |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2008130865A (en) | 2006-11-22 | 2008-06-05 | Fuji Mach Mfg Co Ltd | Component suction posture discrimination method and component suction posture discrimination system |
US20160163035A1 (en) | 2014-12-03 | 2016-06-09 | Kla-Tencor Corporation | Automatic Defect Classification Without Sampling and Feature Selection |
JP2016109495A (en) | 2014-12-03 | 2016-06-20 | タカノ株式会社 | Classifier generation device, appearance inspection device, classifier generation method, and program |
JP2016168046A (en) | 2015-03-09 | 2016-09-23 | 学校法人法政大学 | Plant disease diagnosis system, plant disease diagnosis method, and program |
JP2018005640A (en) | 2016-07-04 | 2018-01-11 | タカノ株式会社 | Classifying unit generation device, image inspection device, and program |
-
2018
- 2018-10-05 JP JP2018190513A patent/JP7070308B2/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2008130865A (en) | 2006-11-22 | 2008-06-05 | Fuji Mach Mfg Co Ltd | Component suction posture discrimination method and component suction posture discrimination system |
US20160163035A1 (en) | 2014-12-03 | 2016-06-09 | Kla-Tencor Corporation | Automatic Defect Classification Without Sampling and Feature Selection |
JP2016109495A (en) | 2014-12-03 | 2016-06-20 | タカノ株式会社 | Classifier generation device, appearance inspection device, classifier generation method, and program |
JP2016168046A (en) | 2015-03-09 | 2016-09-23 | 学校法人法政大学 | Plant disease diagnosis system, plant disease diagnosis method, and program |
JP2018005640A (en) | 2016-07-04 | 2018-01-11 | タカノ株式会社 | Classifying unit generation device, image inspection device, and program |
Also Published As
Publication number | Publication date |
---|---|
JP2020060398A (en) | 2020-04-16 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US11715190B2 (en) | Inspection system, image discrimination system, discrimination system, discriminator generation system, and learning data generation device | |
CN108416266B (en) | A Fast Video Behavior Recognition Method Using Optical Flow to Extract Moving Objects | |
CN110619618A (en) | Surface defect detection method and device and electronic equipment | |
JP7435303B2 (en) | Inspection device, unit selection device, inspection method, and inspection program | |
JP6844563B2 (en) | Inspection equipment, image identification equipment, identification equipment, inspection method, and inspection program | |
US11348349B2 (en) | Training data increment method, electronic apparatus and computer-readable medium | |
CN111758117B (en) | Inspection system, identification system and learning data generation device | |
JP2020060879A (en) | Learning device, image generator, method for learning, and learning program | |
TWI818367B (en) | Method, electronic device, and non-transitory computer-readable storage medium for enhancing image resolution for sequences of 2-d images of additively manufactured products | |
Gupta et al. | Deep learning model for defect analysis in industry using casting images | |
JP7070308B2 (en) | Estimator generator, inspection device, estimator generator method, and estimator generator | |
JP7059889B2 (en) | Learning device, image generator, learning method, and learning program | |
US11361424B2 (en) | Neural network-type image processing device, appearance inspection apparatus and appearance inspection method | |
CN119131009B (en) | Unsupervised defect detection method, system and medium based on multimodal intercalibration | |
Sol | A Sim-to-Real Deformation Classification Pipeline using Data Augmentation and Domain Adaptation | |
CN114066809B (en) | A method and device for detecting soft edge defects of packaging boxes | |
JP2024141773A (en) | Pre-learning device, pre-learning method, and computer program | |
CN119205712A (en) | A method, device, equipment and medium for risk assessment of hydropower station dam | |
JP2023104488A (en) | Machine learning device, machine learning method, machine learning program, inspection device, inspection method, and inspection program | |
JP2024102439A (en) | Learning support device, method for supporting learning, and learning support program | |
CN118052788A (en) | Electric tower detection method and device | |
JP2021179902A (en) | Image inspection device, image inspection method, and learned model creation device | |
CN116894837A (en) | Appearance defect detection method and system | |
CN116402783A (en) | Multi-scale information fusion-based insulator image detection method |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20201214 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20210914 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20210921 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20211014 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20220308 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20220317 |
|
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: 20220405 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20220418 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 7070308 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |