JP2023077051A - Setting device and setting method - Google Patents
Setting device and setting method Download PDFInfo
- Publication number
- JP2023077051A JP2023077051A JP2021190169A JP2021190169A JP2023077051A JP 2023077051 A JP2023077051 A JP 2023077051A JP 2021190169 A JP2021190169 A JP 2021190169A JP 2021190169 A JP2021190169 A JP 2021190169A JP 2023077051 A JP2023077051 A JP 2023077051A
- Authority
- JP
- Japan
- Prior art keywords
- image
- defective
- defective product
- machine learning
- learning network
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Images
Landscapes
- Image Analysis (AREA)
Abstract
Description
本開示は、外観検査装置の設定装置及び設定方法に関する。 The present disclosure relates to a setting device and a setting method for a visual inspection apparatus.
例えば特許文献1には、コンピュータによる機械学習を用いて、ワークが良品であるか不良品であるかの判定を行う処理装置が開示されている。特許文献1の処理装置は、良品データを対象とした教師ありの機械学習を行って良品学習モデルを生成するとともに、不良品データを対象とした教師ありの機械学習を行って不良品学習モデルを生成した後、判定対象となるワークのデータを入力し、良品学習モデル及び不良品学習モデルによってワークが良品であるか不良品であるかの判定が行えるように構成されており、このような装置はワークの外観検査装置とも呼ばれている。
For example,
ところで、不良品データを対象とした教師あり学習を行う場合、そのワークのどこが不良箇所であるかをユーザ自身が明示する作業、いわゆるアノテーションが必要になる。不良品学習によって生成された不良品学習モデルによる判定性能は、アノテーションを詳細に行うほど向上する傾向にあるので、アノテーションをより詳細に行いたい。 By the way, when supervised learning is performed on defective product data, it is necessary for the user to clearly indicate which part of the work is defective, that is, so-called annotation. Since the judgment performance of the defective product learning model generated by defective product learning tends to improve as the annotation is performed in detail, it is desirable to perform the annotation in more detail.
しかしながら、不良箇所は単純な形状であるとは限らず、様々な形状であったり、ワークの様々な位置にあることが多く、そのような不良箇所に対応する領域を不良品画像上で正確に指定する作業は難しい。不良箇所に対応する領域の指定が不正確であった場合には、不良品学習モデルによる判定性能の低下を招く結果となる。また、人間がアノテーションを行っている以上、不良箇所としてアノテーションするべき領域であるか否かを不良品画像上で判断に迷う場合や、不良箇所に対応する領域よりも大きな領域をアノテーションしてしまう場合、反対に、不良箇所に対応する領域よりも小さな領域をアノテーションしてしまう場合等も考えられる。このようなユーザによるアノテーションの違いは、最終的に生成された不良品学習モデルの性能に差を生じさせる結果となり得る。つまり、アノテーションを詳細にするのが理想であるが、詳細にすればするほど属人性が現れてしまい、結果として良好な判定性能を持った不良品学習モデルが得られなくなるおそれがある。 However, the defective part is not always a simple shape, and often has various shapes and is located at various positions on the workpiece. The task of specifying is difficult. If the designation of the area corresponding to the defective portion is inaccurate, this results in deterioration of the determination performance of the defective product learning model. In addition, as long as humans are annotating, there are cases where it is difficult to judge whether an area should be annotated as a defective part on the defective product image, or an area larger than the area corresponding to the defective part is annotated. In some cases, on the contrary, it is conceivable that an area smaller than the area corresponding to the defective portion is annotated. Such differences in annotations by users can result in differences in the performance of the finally generated defective product learning model. In other words, it is ideal to make the annotations more detailed, but the more the annotations are made, the more dependent the annotation becomes, and as a result, there is a risk that a defective product learning model with good judgment performance cannot be obtained.
また、不良品学習モデルを生成するに当たっては、例えば数十枚、数百枚の不良品画像が必要になるが、これほどの枚数の不良品画像の全てに正確にアノテーションを行おうとすると、ユーザに大きな時間的負担を強いることになり、このことも問題であった。 In addition, in order to generate a defective product learning model, for example, dozens or hundreds of defective product images are required. This was also a problem.
本開示は、かかる点に鑑みたものであり、その目的とするところは、機械学習ネットワークの学習時におけるユーザの手間を削減するとともに、属人性を排除しながらも、高い検出性能を持った機械学習ネットワークが得られるようにすることにある。 The present disclosure has been made in view of this point, and its purpose is to reduce the user's time and effort when learning a machine learning network, and to eliminate the dependence on individuals, while having a machine with high detection performance. The object is to obtain a learning network.
上記目的を達成するために、本開示の一態様では、良品に対応する良品画像と、不良品に対応する不良品画像とを学習することにより生成された機械学習ネットワークに、検査対象のワークを撮像したワーク画像を入力し、当該ワーク画像の良否判定を行う外観検査装置の設定を行う設定装置を前提とすることができる。設定装置は、前記機械学習ネットワークに学習させるための画像を表示部に表示させる表示制御部と、前記表示部に表示された画像に対し、良品画像または不良品画像であることを示すラベルを付与する第1アノテーション方式と、前記表示部に表示された画像が不良品画像である場合に不良箇所を指定する第2アノテーション方式とのいずれかの方式で入力された不良情報を受け付ける入力部と、プロセッサとを備えている。プロセッサは、前記第1アノテーション方式でラベルが付与された良品画像または不良品画像と、前記第2アノテーション方式で入力された不良情報を有する不良品画像との両方を前記機械学習ネットワークに学習させて、当該機械学習ネットワークのパラメータを調整することができる。 In order to achieve the above object, in one aspect of the present disclosure, a machine learning network generated by learning a non-defective product image corresponding to a non-defective product and a defective product image corresponding to a defective product is provided with a work to be inspected. It is possible to presuppose a setting device for inputting a photographed work image and setting a visual inspection device for determining the quality of the work image. The setting device includes a display control unit that causes a display unit to display an image for learning by the machine learning network, and a label indicating that the image displayed on the display unit is a non-defective product image or a defective product image. an input unit that receives defect information input by either a first annotation method that specifies a defective part when the image displayed on the display unit is a defective product image; with a processor. The processor causes the machine learning network to learn both the non-defective product image or the defective product image labeled by the first annotation method and the defective product image having the defect information input by the second annotation method. , the parameters of the machine learning network can be adjusted.
この構成によれば、第1アノテーション方式では、表示部に表示された画像をラベル指定によって良品画像と不良品画像に振り分けることができるので、全体的に不良であると判定すべき不良品画像のアノテーションが可能になる。一方、第2アノテーション方式では、不良品画像上で不良箇所を指定できるので、第1アノテーション方式に比べて不良箇所を詳細に指定するアノテーションが可能になる。つまり、不良品画像には、ラベルを付与するだけで不良であると判定が可能な不良品画像と、不良箇所を明確に指定しないと不良であると判定ができない不良品画像とが含まれている場合があり、前者の場合は、ユーザの手間をかけずに容易にアノテーションが行え、一方、後者の場合はユーザが詳細にアノテーションすることが可能になる。 According to this configuration, in the first annotation method, images displayed on the display unit can be sorted into non-defective product images and defective product images by label designation. Annotation becomes possible. On the other hand, in the second annotation method, since the defective part can be specified on the defective product image, it is possible to make an annotation that specifies the defective part in more detail than in the first annotation method. In other words, the defective product image includes a defective product image that can be determined as defective simply by attaching a label, and a defective product image that cannot be determined as defective unless the defective part is clearly specified. In the former case, the annotation can be easily performed without the user's trouble, while in the latter case, the user can annotate in detail.
他の態様に係る入力部は、前記第2アノテーション方式として、不良品画像の不良箇所を囲むことで当該不良箇所を指定する領域指定方式と、不良品画像の不良箇所をなぞることで当該不良箇所を自由形状で指定する精密指定方式とが選択可能に構成されている。 The input unit according to another aspect includes, as the second annotation method, a region specification method of specifying the defective portion by enclosing the defective portion of the defective product image, and a defective portion specifying method of tracing the defective portion of the defective product image. can be selected from a precise designation method that designates in a free form.
この構成によれば、領域指定方式を選択した場合には、不良箇所を囲む枠を例えばポインティングデバイス等によって生成することで、不良箇所を容易に指定することができる。また、不良箇所が例えば自由形状である場合には、精密指定方式を選択することで、自由形状の不良箇所を精密に指定することができる。つまり、不良箇所の大まかな指定と精密な指定とを必要に応じて切り替えることができるので、ユーザの手間を削減しながら、不良品画像を用いた機械学習ネットワークの学習を効果的に行うことができる。 According to this configuration, when the region designation method is selected, the defective portion can be easily designated by generating a frame surrounding the defective portion using, for example, a pointing device. Further, when the defective portion is, for example, a free-form, the precise designation method can be selected to precisely designate the free-form defective portion. In other words, since it is possible to switch between rough designation and precise designation of defective parts as needed, it is possible to effectively learn a machine learning network using defective product images while reducing the user's labor. can.
他の態様に係る入力部は、不良品画像の不良箇所と当該不良箇所の周囲とを囲むことによって指定された領域内で当該不良箇所を自動抽出する自動抽出方式を実行できるものである。 An input unit according to another aspect can execute an automatic extraction method for automatically extracting a defective portion within a designated area by enclosing a defective portion of a defective product image and the periphery of the defective portion.
この構成によれば、ユーザが不良箇所とその周囲を大まかに囲むだけで、自動的に不良箇所が抽出されるので、ユーザの手間をより一層削減できる。 According to this configuration, the user can automatically extract the defective portion simply by encircling the defective portion and its surroundings, thereby further reducing the user's trouble.
他の態様に係る入力部は、前記自動抽出方式の実行後、当該自動抽出方式で自動抽出された領域の形状の修正を受け付けることができるので、例えば、自動抽出された領域が不良箇所の形状から外れていた場合に、自動抽出された領域の形状が不良箇所の形状と一致するように、自動抽出された領域の形状をユーザが修正することで、より精密なアノテーションが可能になる。 Since the input unit according to another aspect can accept correction of the shape of the region automatically extracted by the automatic extraction method after the execution of the automatic extraction method, for example, the automatically extracted region can change the shape of the defective part The user can correct the shape of the automatically extracted area so that it matches the shape of the defective area, thereby enabling more precise annotation.
他の態様に係るプロセッサは、前記第1アノテーション方式でラベルが付与された良品画像または不良品画像と、前記第2アノテーション方式で不良箇所が指定された不良品画像とを単一の前記機械学習ネットワークに入力し、当該機械学習ネットワークのパラメータを調整することができるので、異なる方式でアノテーションが実行された複数の不良品画像で単一の機械学習ネットワークの学習が行える。 A processor according to another aspect performs a single machine learning process on a non-defective product image or a defective product image labeled by the first annotation method and a defective product image on which a defective portion is designated by the second annotation method. Inputs to the network and parameters of the machine learning network can be adjusted so that a single machine learning network can be trained on multiple defective images annotated in different ways.
他の態様に係るプロセッサは、不良品画像を学習することにより生成された前記機械学習ネットワークに、検証用画像データを入力して当該検証用画像データの良否判定を実行する検証処理が行える。プロセッサは、前記検証処理後、不良品に対応する前記検証用画像データであるにも関わらず不良として判定されなかった場合、不良箇所が前記第2アノテーション方式により指定された前記検証用画像データを前記機械学習ネットワークに学習させて当該機械学習ネットワークのパラメータを更新する更新処理を実行することができる。 A processor according to another aspect can perform a verification process of inputting verification image data to the machine learning network generated by learning defective product images and determining whether the verification image data is good or bad. After the verification process, if the verification image data corresponding to a defective product is not determined to be defective, the processor outputs the verification image data in which a defective portion is designated by the second annotation method. An update process can be performed for causing the machine learning network to learn and updating the parameters of the machine learning network.
すなわち、不良品に対応する検証用画像データを不良として判定しない機械学習ネットワークは更なる学習の余地があるということである。このような機械学習ネットワークに対して、不良箇所が第2アノテーション方式により精密に指定された検証用画像データを学習させることで、機械学習ネットワークの判定性能をより一層向上させることができる。 In other words, there is room for further learning for a machine learning network that does not determine verification image data corresponding to defective products as defective. By allowing such a machine learning network to learn the verification image data in which the defective portion is precisely specified by the second annotation method, the judgment performance of the machine learning network can be further improved.
他の態様では、前記表示制御部は、前記第1アノテーション方式で不良品画像のラベルが付与された画像の中で、不良として判定されなかった画像の一覧を前記表示部に表示させることができる。前記入力部は、前記表示部に一覧表示された画像の中から前記第2アノテーション方式で不良箇所の指定を行う画像の選択入力を受け付け、選択された画像に対して前記第2アノテーション方式で不良箇所の指定を受け付ける。 In another aspect, the display control unit can cause the display unit to display a list of images that are not determined to be defective among images labeled as defective product images by the first annotation method. . The input unit accepts a selection input of an image for which a defective portion is to be designated by the second annotation method from among the images displayed as a list on the display unit, and determines whether the selected image is defective by the second annotation method. Accept designation of location.
すなわち、不良品画像のラベルが付与された画像の中で、不良として判定されなかった画像があるということは、機械学習ネットワークに更なる学習の余地があるということである。このような場合、不良として判定されなかった画像を機械学習ネットワークに学習させることが考えられるが、そのまま学習させたのでは学習効果は殆ど向上しない。本構成では、不良品画像のラベルが付与された画像であるにも関わらず、不良として判定されなかった画像を表示部に表示させることでユーザに提示することができ、ユーザは、その画像の中から、第2アノテーション方式により精密に不良箇所を指定するのに適した画像を選択し、精密に不良箇所を指定した画像で機械学習ネットワークを学習させることができ、学習効果が向上する。 In other words, the fact that there are images that are not determined as defective among the images labeled as defective images means that there is room for further learning in the machine learning network. In such a case, it is conceivable to let the machine learning network learn images that have not been judged as defective, but if the machine learning network is allowed to learn them as they are, the learning effect will hardly improve. In this configuration, an image that is not determined to be defective despite being labeled as a defective product image can be presented to the user by displaying it on the display unit. An image suitable for precisely specifying the defective portion can be selected from among them by the second annotation method, and the machine learning network can be trained with the image in which the defective portion is precisely specified, thereby improving the learning effect.
他の態様では、前記プロセッサは、機械学習ネットワークに、複数の互いに異なる検証用画像データを入力して当該各検証用画像データの良否判定を実行し、表示制御部は、前記プロセッサが取得した前記判定結果を前記表示部に表示してユーザに提示することができる。 In another aspect, the processor inputs a plurality of verification image data different from each other to a machine learning network to determine whether each verification image data is good or bad; The determination result can be displayed on the display unit and presented to the user.
この構成によれば、複数の検証用画像データの良否判定を機械学習ネットワークに実行させることでプロセッサは判定結果を取得できる。この判定結果が表示部に表示されるので、ユーザは、良品、不良品と指定されている画像が分離できているかを把握できる。良品画像であると判定された判定結果と、不良品画像であると判定された判定結果とが分離できている場合には、機械学習ネットワークの学習が十分に行われているとユーザ側で判断でき、また、きれいに分離できていない場合には、機械学習ネットワークの学習が不十分であって更なる学習が必要であるとユーザ側で判断できる。 According to this configuration, the processor can acquire the determination result by causing the machine learning network to perform the pass/fail determination of the plurality of verification image data. Since this determination result is displayed on the display unit, the user can grasp whether the images designated as non-defective products and defective products are separated. If the determination result that the image is determined to be a non-defective product can be separated from the determination result that the image is determined to be a defective product, the user can determine that the machine learning network has sufficiently learned. If it can be separated, the user can judge that the learning of the machine learning network is insufficient and further learning is necessary.
他の態様では、良品画像であると判定された度数と不良品画像であると判定された度数とに基づく累積ヒストグラムを生成して表示部に表示させるものである。 In another aspect, a cumulative histogram based on the number of times the image is determined to be a non-defective image and the number of times the image is determined to be a defective image is generated and displayed on the display unit.
この構成によれば、検証用画像データを機械学習ネットワークで良否判定した結果として、良品画像であると判定された度数と不良品画像であると判定された度数とに基づくヒストグラムをユーザに提示することができる。これにより、良品、不良品と指定されている画像が分離できているか否かをユーザが容易に判断できる。 According to this configuration, as a result of pass/fail judgment of the verification image data by the machine learning network, the user is presented with a histogram based on the number of times the image data for verification is judged to be a non-defective image and the number of times the image is judged to be a defective image. be able to. This allows the user to easily determine whether or not the images designated as non-defective products and defective products are separated.
他の態様に係るプロセッサは、良品情報を有する画像の異常度マップと不良品情報を有する画像の異常度マップとの距離を所定以上離す処理を実行可能に構成されている。 A processor according to another aspect is configured to be capable of executing a process of increasing a distance between an abnormality degree map of an image having non-defective product information and an abnormality degree map of an image having defective product information by a predetermined distance or more.
この構成によれば、良品情報を有する画像と、不良品情報を有する画像とを用いた学習効果がより一層向上する。 According to this configuration, the learning effect using the image having non-defective product information and the image having defective product information is further improved.
他の態様に係るプロセッサは、良品情報を有する画像同士の異常度マップ間の距離を近づける処理と、不良品情報を有する画像同士の異常度マップ間の距離を近づける処理との少なくとも一方を実行可能に構成されている。 A processor according to another aspect can execute at least one of a process of reducing the distance between the abnormality maps of images having non-defective product information and the process of reducing the distance between the abnormality maps of images having defective product information. is configured to
この構成によれば、良品情報を有する複数の画像を用いた学習効果、不良品情報を有する複数の画像を用いた学習効果がより一層向上する。 According to this configuration, the learning effect using a plurality of images having non-defective product information and the learning effect using a plurality of images having defective product information are further improved.
他の態様に係るプロセッサは、第1アノテーション方式で入力された良品情報を有する良品画像を前記機械学習ネットワークに入力して生成された異常度マップ内の各画素値が0となるように当該機械学習ネットワークのパラメータを調整することができる。 A processor according to another aspect, the machine so that each pixel value in the degree of anomaly map generated by inputting a non-defective product image having non-defective product information input by the first annotation method into the machine learning network is 0 Parameters of the learning network can be adjusted.
他の態様に係るプロセッサは、前記第2アノテーション方式で入力された不良品情報を有する不良品画像を前記機械学習ネットワークに入力して生成された異常度マップ内において、前記第2アノテーション方式で指定された不良箇所以外に対応する部分の画素値が0となるように当該機械学習ネットワークのパラメータを調整することができる。 A processor according to another aspect specifies, in an anomaly map generated by inputting a defective product image having defective product information input by the second annotation method into the machine learning network, by the second annotation method The parameters of the machine learning network can be adjusted so that the pixel value of the portion corresponding to the non-defective portion is 0.
以上説明したように、良品画像または不良品画像であることを示すラベルを付与する第1アノテーション方式と、不良品画像の不良箇所を指定する第2アノテーション方式とのいずれかの方式で不良情報を入力し、その不良情報に基づいて機械学習ネットワークのパラメータを調整することができるので、学習時におけるユーザの手間を削減するとともに、属人性を排除しながらも、高い検出性能を持った機械学習ネットワークを得ることができる。 As described above, defect information is obtained by either the first annotation method, which assigns a label indicating whether the image is a non-defective product image or the defective product image, or the second annotation method, which designates the defective part of the defective product image. It is possible to input and adjust the parameters of the machine learning network based on the defect information, reducing the user's labor during learning, eliminating the dependence on individuality, and having high detection performance. can be obtained.
以下、本発明の実施形態を図面に基づいて詳細に説明する。尚、以下の好ましい実施形態の説明は、本質的に例示に過ぎず、本発明、その適用物或いはその用途を制限することを意図するものではない。 BEST MODE FOR CARRYING OUT THE INVENTION Hereinafter, embodiments of the present invention will be described in detail based on the drawings. It should be noted that the following description of preferred embodiments is essentially merely illustrative, and is not intended to limit the invention, its applications, or its uses.
図1は、本発明の実施形態に係る外観検査装置の設定装置(以下、単に設定装置という)1の構成を示す模式図である。設定装置1は、外観検査装置の各種設定(詳細は後述する)をユーザが行えるようにするための装置である。外観検査装置は、例えば各種部品や製品等のような検査対象であるワークを撮像して取得されたワーク画像の良否判定を行うための装置であり、工場等の生産現場等で使用することができる。具体的には、外観検査装置の内部には機械学習ネットワークが構築されており、この機械学習ネットワークは、良品に対応する良品画像と、不良品に対応する不良品画像とを学習することにより生成されている。生成された機械学習ネットワークに、検査対象のワークを撮像したワーク画像を入力し、当該ワーク画像の良否判定を機械学習ネットワークによって行うことができるようになっている。
FIG. 1 is a schematic diagram showing the configuration of a setting device (hereinafter simply referred to as a setting device) 1 for an appearance inspection apparatus according to an embodiment of the present invention. The
ワークは、それ全体が検査対象であってもよいし、ワークの一部のみが検査対象であってもよい。また、1つのワークに複数の検査対象が含まれていてもよい。また、ワーク画像には、複数のワークが含まれていてもよい。 The entire workpiece may be inspected, or only part of the workpiece may be inspected. Also, one workpiece may include a plurality of inspection targets. Also, the workpiece image may include a plurality of workpieces.
設定装置1は、装置本体となる制御ユニット2と、撮像ユニット3と、表示装置(表示部)4と、パーソナルコンピュータ5とを備えている。パーソナルコンピュータ5は、必須なものではなく、省略することもできる。表示装置4の代わりにパーソナルコンピュータ5を使用して各種情報や画像を表示させることもできるし、パーソナルコンピュータ5の機能を制御ユニット2に組み込むことや、表示装置4に組み込むことができる。
The
図1では、設定装置1の構成例の一例として、制御ユニット2、撮像ユニット3、表示装置4及びパーソナルコンピュータ5を記載しているが、これらのうち、任意の複数を組み合わせて一体化することもできる。例えば、制御ユニット2と撮像ユニット3を一体化することや、制御ユニット2と表示装置4を一体化することもできる。また、制御ユニット2を複数のユニットに分割して一部を撮像ユニット3や表示装置4に組み込むことや、撮像ユニット3を複数のユニットに分割して一部を他のユニットに組み込むこともできる。
In FIG. 1, a
また、設定装置1のハードウエアと、外観検査装置のハードウエアとは共通する部分が多いので、設定装置1に外観検査装置の各機能を実現するためのプログラムを組み込んで外観検査機能を有する設定装置1としてもよいし、外観検査装置に設定装置1の各機能を実現するためのプログラムを組み込んで後述する設定機能を有する外観検査装置としてもよい。また、設定装置1と、外観検査装置とは互いに分離された装置であってもよく、この場合、設定装置1と外観検査装置とを相互に通信可能に接続して使用することができる。
Since the hardware of the
(撮像ユニット3の構成)
図2に示すように、撮像ユニット3は、カメラモジュール(撮像部)14と、照明モジュール(照明部)15とを備えており、ワーク画像の取得を実行するユニットである。カメラモジュール14は、撮像光学系を駆動するAF用モータ141と、撮像基板142とを備えている。AF用モータ141は、撮像光学系のレンズを駆動することにより、自動でピント調整を実行する部分であり、従来から周知のコントラストオートフォーカス等の手法によってピント調整を行うことができる。撮像基板142は、撮像光学系から入射した光を受光する受光素子としてCMOSセンサ143を備えている。CMOSセンサ143は、カラー画像を取得することができるように構成された撮像センサである。CMOSセンサ143の代わりに、例えばCCDセンサ等の受光素子を用いることもできる。
(Configuration of imaging unit 3)
As shown in FIG. 2, the
照明モジュール15は、ワークを含む撮像領域を照明する発光体としてのLED(発光ダイオード)151と、LED151を制御するLEDドライバ152とを備えている。LED151による発光タイミング、発光時間、発光量は、LEDドライバ152によって任意に制御することができる。LED151は、撮像ユニット3に一体に設けてもよいし、撮像ユニット3とは別体として外部照明ユニットとして設けてもよい。
The
(表示装置4の構成)
表示装置4は、例えば液晶パネルや有機ELパネル等からなる表示パネルを有している。制御ユニット2から出力されたワーク画像やユーザーインターフェース画像等は表示装置4に表示される。また、パーソナルコンピュータ5が表示パネルを有している場合、パーソナルコンピュータ5の表示パネルを表示装置4の代わりとして利用することができる。
(Configuration of display device 4)
The
(操作機器)
設定装置1をユーザが操作するための操作機器としては、例えば、パーソナルコンピュータ5が有するキーボード51やマウス52等を挙げることができるが、これらに限られるものではなく、ユーザによる各種操作を受付可能に構成された機器であればよい。例えば、表示装置4が有するタッチパネル41のようなポインティングデバイスも操作機器に含まれる。
(operating device)
The operation device for the user to operate the
キーボード51やマウス52のユーザによる操作は制御ユニット2で検出可能になっている。また、タッチパネル41は、例えば感圧センサを搭載した従来から周知のタッチ式操作パネルであり、ユーザのタッチ操作は制御ユニット2で検出可能になっている。他のポインティングデバイスを用いた場合も同様である。
The user's operation of the
(制御ユニット2の構成)
制御ユニット2は、メイン基板13と、コネクタ基板16と、通信基板17と、電源基板18とを備えている。メイン基板13には、表示制御部13aと、画像の不良情報を受け付ける入力部13bと、プロセッサ13cとが設けられている。表示制御部13a及び入力部13bは、例えば、メイン基板13に実装された演算処理装置によって構成することができる。また、1つの演算処理装置によって表示制御部13a、入力部13b及びプロセッサ13cが構成されていてもよいし、別々の演算処理装置によって表示制御部13a、入力部13b及びプロセッサ13cが構成されていてもよい。
(Configuration of control unit 2)
The
表示制御部13a、入力部13b及びプロセッサ13cは、接続されている各基板及びモジュールの動作を制御する。例えば、プロセッサ13cは、照明モジュール15のLEDドライバ152に対してLED151の点灯/消灯を制御する照明制御信号を出力する。LEDドライバ152は、プロセッサ13cからの照明制御信号に応じて、LED151の点灯/消灯の切替及び点灯時間の調整を行うとともに、LED151の光量等を調整する。
The
また、プロセッサ13cは、カメラモジュール14の撮像基板142に、CMOSセンサ143を制御する撮像制御信号を出力する。CMOSセンサ143は、プロセッサ13cからの撮像制御信号に応じて、撮像を開始するとともに、露光時間を任意の時間に調整して撮像を行う。すなわち、撮像ユニット3は、プロセッサ13cから出力される撮像制御信号に応じてCMOSセンサ143の視野範囲内を撮像し、視野範囲内にワークがあれば、ワークを撮像することになるが、ワーク以外の物が視野範囲内にあれば、それも撮像することができる。例えば、設定装置1は、機械学習ネットワークの学習用の画像として、撮像ユニット3により、良品に対応する良品画像と不良品に対応する不良品画像とを撮像することができる。学習用の画像は、撮像ユニット3で撮像された画像でなくてもよく、他のカメラ等で撮像された画像であってもよい。
The
一方、外観検査装置の運用時には、撮像ユニット3により、ワークを撮像することができる。また、CMOSセンサ143は、ライブ画像、即ち現在の撮像された画像を短いフレームレートで随時出力することができるように構成されている。
On the other hand, during operation of the visual inspection apparatus, the image of the work can be imaged by the
CMOSセンサ143による撮像が終わると、撮像ユニット3から出力された画像信号は、メイン基板13のプロセッサ13cに入力されて処理されるとともに、メイン基板13のメモリ13dに記憶されるようになっている。メイン基板13のプロセッサ13cによる具体的な処理内容の詳細については後述する。尚、メイン基板13には、FPGAやDSP等の処理装置が設けられていてもよい。FPGAやDSP等の処理装置が統合されたプロセッサ13cであってもよい。
When the CMOS sensor 143 finishes capturing an image, the image signal output from the
コネクタ基板16は、電源インターフェース161に設けてある電源コネクタ(図示せず)を介して外部から電力の供給を受ける部分である。電源基板18は、コネクタ基板16で受けた電力を各基板及びモジュール等に分配する部分であり、具体的には、照明モジュール15、カメラモジュール14、メイン基板13、及び通信基板17に電力を分配する。電源基板18は、AF用モータドライバ181を備えている。AF用モータドライバ181は、カメラモジュール14のAF用モータ141に駆動電力を供給し、オートフォーカスを実現している。AF用モータドライバ181は、メイン基板13のプロセッサ13cからのAF制御信号に応じて、AF用モータ141に供給する電力を調整する。
The
通信基板17は、メイン基板13と表示装置4及びパーソナルコンピュータ5との通信、メイン基板13と外部制御機器(図示せず)との通信等を実行する部分である。外部制御機器は、例えばプログラマブルロジックコントローラ等を挙げることができる。通信は、有線であってもよいし、無線であってもよく、いずれの通信形態も、従来から周知の通信モジュールによって実現することができる。
The
制御ユニット2には、例えばソリッドステートドライブ、ハードディスクドライブ等からなる記憶装置(記憶部)19が設けられている。記憶装置19には、後述する各制御及び処理を上記ハードウエアによって実行可能にするためのプログラムファイル80や設定ファイル等(ソフトウエア)が記憶されている。プログラムファイル80や設定ファイルは、例えば光ディスク等の記憶媒体90に格納しておき、この記憶媒体90に格納されたプログラムファイル80や設定ファイルを制御ユニット2にインストールすることができる。プログラムファイル80は、外部サーバから通信回線を利用してダウンロードされるものであってもよい。また、記憶装置19には、例えば、上記画像データや、外観検査装置の機械学習ネットワークを構築するためのパラメータ等を記憶させておくこともできる。
The
(アノテーション)
設定装置1は、外観検査装置の機械学習ネットワークに、良品に対応する良品画像と不良品に対応する不良品画像とを入力して学習させることにより、当該機械学習ネットワークのパラメータを調整する。例えば、機械学習ネットワークのパラメータの初期値を無作為に決定しておき、機械学習ネットワークから出力される画像認識の誤差をフィードバックしながらパラメータを調整していく手法を採用できる。
(annotation)
The
ユーザは、機械学習ワークの学習に先立ち、機械学習ネットワークに入力する画像が良品画像であるか、不良品画像であるか、また、機械学習ネットワークに入力する画像が不良品画像である場合にどこが不良箇所であるかを指定する必要がある。これがユーザ自身によるアノテーションであり、本実施形態では、第1アノテーション方式と、第2アノテーション方式を含む複数の方式でアノテーションの実行が可能になっている。 Prior to learning the machine learning work, the user determines whether the image input to the machine learning network is a good product image or a defective product image, and if the image input to the machine learning network is a defective product image, where is it? It is necessary to specify whether it is a defective part. This is the annotation by the user himself/herself, and in this embodiment, annotation can be executed by a plurality of methods including the first annotation method and the second annotation method.
図3に示すように、ユーザによるアノテーションの実行開始操作が行われると、ステップSA1に進み、アノテーションを行う画像をユーザが選択する。例えば図4に示すようなワークWを含む画像を設定装置1に複数記憶させておき、その中からユーザが所望の画像を選択する。その後、ステップSA2に進むと、図4のFIG.4A及びFIG.4Bにそれぞれ示すように、表示制御部13aは、アノテーション実行用ユーザーインターフェース画面200を生成し、表示装置4に表示させる。アノテーション実行用ユーザーインターフェース画面200には、機械学習ネットワークに学習させるための画像を表示するための画像表示領域201が設けられている。FIG.4Aには、画像表示領域201に不良品画像202が表示されている場合を示しており、黒丸の部分が不良箇所202aである。またFIG.4Bには、画像表示領域201に良品画像203が表示されている場合を示している。これが表示ステップである。つまり、ユーザがアノテーションを実行する前段階で、表示制御部13aが機械学習ネットワークに学習させるための画像を表示装置4に表示させることで、ユーザは表示装置4に表示されている画像を見ながら、アノテーションを実行することができる。
As shown in FIG. 3, when the user performs an annotation execution start operation, the process proceeds to step SA1, where the user selects an image to be annotated. For example, a plurality of images including a workpiece W as shown in FIG. 4 are stored in the
次いでステップSA3に進み、第1アノテーション方式によるアノテーションをユーザが行う。第1アノテーション方式では、表示装置4に表示された画像に対し、良品画像または不良品画像であることを示すラベルを付与する。具体的には、図4のFIG.4Aでは、不良品画像202が表示されているので、その不良品画像202には、右側に示すように不良品画像であることを示すラベルとして例えば「NG」等と記載された不良品ラベルA1を付与する。この不良品ラベルA1が第1アノテーション方式で入力された不良情報である。
Next, in step SA3, the user makes an annotation according to the first annotation method. In the first annotation method, the image displayed on the
一方、図4のFIG.4Bでは、良品画像203が表示されているので、その画像203には、右側に示すように良品画像であることを示すラベルとして例えば「OK」等と記載された良品ラベルA2を付与する。この良品ラベルA2が第1アノテーション方式で入力された良品情報である。ユーザによるラベルの付与方法はどのような方法であってもよく、例えば「NG」と表示されたボタン及び「OK」と表示されたボタンをアノテーション実行用ユーザーインターフェース画面200に設けておき、このボタンの操作によって所望のラベルA1、A2を付与するようにしてもよい。
On the other hand, FIG. In 4B, a
第1アノテーション方式によるラベルの付与方法としては、画像に1枚ずつ付与してもよいし、例えば複数の不良品画像を特定のフォルダに保存しておき、そのフォルダ内の不良品画像に対して一括して不良品ラベルA1を付与してもよい。また、良品画像についても同様に複数の良品画像を特定のフォルダに保存しておき、そのフォルダ内の良品画像に対して一括して良品ラベルA2を付与してもよい。 As a labeling method according to the first annotation method, labels may be attached to images one by one. The defective product label A1 may be given collectively. Also, as for non-defective product images, a plurality of non-defective product images may be similarly stored in a specific folder, and the non-defective product images in the folder may collectively be given the non-defective product label A2.
良品画像203の場合は、図3に示すフローチャートのステップSA4及びSA5を省略してステップSA6に進む。ステップSA6では、入力部13bが、第1アノテーション方式で入力された良品情報を受け付ける。入力部13bは、表示装置4に表示されている良品画像203と、良品情報(ラベルA2)とを関連付けた状態で、記憶装置19に記憶させておくことができる。
In the case of the
不良品画像202の場合は、図3に示すフローチャートのステップSA4及びSA5を省略してステップSA6に進んでもよいし、ステップSA4及びSA5を実行してステップSA6に進んでもよい。ステップSA4及びSA5を省略する場合、ステップSA6では、入力部13bが、第1アノテーション方式で入力された不良情報を受け付ける。入力部13bは、表示装置4に表示されている不良品画像202と、不良情報(不良品ラベルA1)とを関連付けた状態で、記憶装置19に記憶させておくことができる。
In the case of the
ステップSA4及びステップSA5は、表示装置4に表示された画像が不良品画像202である場合に不良箇所を指定する第2アノテーション方式の例である。ステップSA4及びステップSA5の一方のみ実行してもよいし、両方を実行してもよい。ステップSA3からステップSA4またはステップSA5に進む場合には、ユーザが所定の操作を行うようにしてもよいし、不良ラベルA2が付与されたことを検知し、自動で進むようにしてもよい。
Steps SA4 and SA5 are an example of a second annotation method for designating a defective portion when the image displayed on the
ステップSA4は、表示装置4に表示された不良品画像202の不良箇所202aを囲むことで当該不良箇所202aを指定する領域指定方式の例であり、またステップSA5は、表示装置4に表示された不良品画像202の不良箇所202aをなぞることで当該不良箇所202aを自由形状で指定する精密指定方式の例である。ユーザは、領域指定方式と、精密指定方式のどちらでも選択することができる。
Step SA4 is an example of a method of specifying the
ステップSA3の後、図5に示すように、表示制御部13aは、アノテーション実行用ユーザーインターフェース画面200を表示装置4に表示させ、画像表示領域201には不良品ラベルA1が付与された不良品画像202を表示させる。アノテーション実行用ユーザーインターフェース画面200には、指定方式選択ウインドウ204が表示される。指定方式選択ウインドウ204には、領域指定方式を選択するための第1ボタン204aと、精密指定方式を選択するための第2ボタン204bと、消しゴムツールを選択するための第3ボタン204cとが設けられている。第1ボタン204aがユーザによって操作されたことを検出すると図3に示すフローチャートのステップSA4に進み、第2ボタン204bがユーザによって操作されたことを検出するとステップSA5に進む。尚、第3ボタン204cを操作すると、領域指定方式や精密指定方式による指定操作の少なくとも一部を取り消したり、指定した領域の一部を消したりすることができる。
After step SA3, as shown in FIG. 5, the
ステップSA4では、表示装置4に表示されているマウス52のポインタ205(図5に示す)やマウス52のクリックボタン(図示せず)をユーザが操作して不良品画像202の不良箇所202aを囲む。図5に示す例では、ユーザがマウス52のポインタ205及びクリックボタンを操作し、不良箇所202aを囲む大きさの矩形状の枠206を生成した例である。矩形状の枠206を生成する際には、例えば左上の頂点に対応する位置にポインタ205を置いて斜め右下にドラッグすることで、所望の位置に所望の大きさ及び形状の枠206を生成できる。枠206の大きさや位置はマウス52の操作によって変更可能になっている。
In step SA4, the user operates the pointer 205 (shown in FIG. 5) of the
また、図6のFIG.6Aに示すように、不良品画像202上でポインタ205によって3つの点207を指定し、これら3つの点207を通る円形の枠208を生成し、この枠208で不良箇所202aを囲むようにしてもよい。また、図6のFIG.6Bに示すように、不良品画像202上でポインタ205によって点210を指定し、この点210を中心とする円形の枠211を生成し、この枠211で不良箇所202aを囲むようにしてもよい。
Also, FIG. As shown in 6A, three
また、図6のFIG.6Cに示すように、不良品画像202上でポインタ205によって複数の点212を指定し、この点212を繋ぐ形状の枠213を生成し、この枠213で不良箇所202aを囲むようにしてもよい。また、図6のFIG.6Dに示すように、不良品画像202上で不良箇所202aを囲むようにポインタ205を動かして自由形状の枠214を生成し、この枠214で不良箇所202aを囲むようにしてもよい。FIG.6Dに示す例では、いわゆるフリーハンドツールによる自由描画によって領域を指定する方法である。どの指定方法にするかは、不良箇所202aの形状や大きさによって決定すればよい。
Also, FIG. As shown in 6C, a plurality of
以上のようにしてステップSA4では、不良情報として不良箇所202aを囲む枠206、208、211、213、214の位置、形状及び大きさが取得される。例えば、図5に示す枠206の中心座標と、縦辺及び横辺の長さとを取得することで、不良品画像202における不良箇所202aを特定することができる。図6に示す場合も同様に枠208、211、213、214の情報を取得することで、不良品画像202における不良箇所202aを特定することができる。この不良箇所202aを特定する情報が不良情報である。
As described above, in step SA4, the positions, shapes, and sizes of
ステップSA4でユーザが不良箇所202aを指定すると、ステップSA6に進む。ステップSA6では、入力部13bが、ステップSA4で入力された不良情報を受け付ける。入力部13bは、表示装置4に表示されている不良品画像202と、ステップSA4で入力された不良情報とを関連付けた状態で、記憶装置19に記憶させておくことができる。
When the user designates the
図5に示すアノテーション実行用ユーザーインターフェース画面200上の指定方式選択ウインドウ204でユーザが第2ボタン204bを操作してステップSA5に進むと、図7のFIG.7Aに示すように、塗り潰しツール220がアノテーション実行用ユーザーインターフェース画面200に表示される。ユーザがマウス52を操作することによって塗り潰しツール220を自由に動かすことができる。ユーザは、不良品画像202における不良箇所202aをなぞるように塗り潰しツール220を動かすことで、不良箇所202aを自由形状で指定することができる。塗り潰しツール220によって不良箇所202aをなぞることで、不良箇所202a以外の部分が含まれにくくなるので、ステップSA4の領域指定方式に比べて精密なアノテーションが可能になる。塗り潰しツール220によって塗りつぶされた領域の位置及び形状、大きさを取得することで、不良品画像202における不良箇所202aを特定することができる。この不良箇所202aを特定する情報が不良情報である。
When the user operates the
図3に示すフローチャートのステップSA5でユーザが塗り潰しツール220によって不良箇所202aを指定すると、ステップSA6に進む。ステップSA6では、入力部13bが、ステップSA5で入力された不良情報を受け付ける。入力部13bは、表示装置4に表示されている不良品画像202と、ステップSA5で入力された不良情報とを関連付けた状態で、記憶装置19に記憶させておくことができる。
When the user designates the
ステップSA5では、上述した塗り潰しツール220以外にも、例えば図7のFIG.7Bに示すようなマグネットツール221で不良箇所202aを指定してもよい。マグネットツール221は、マウス52の操作で移動させることができ、不良箇所202aの近傍まで移動させると、不良箇所202aへ自動的に吸い付けられるように移動する。複数のマグネットツール221を繋ぐ枠222内に不良箇所202aが入るので、ユーザの負担を軽減しながら不良箇所202aの精密な指定を行うことができる。枠222の位置及び形状、大きさが不良情報である。
In step SA5, for example, FIG. The
また、ステップSA5では、例えば図7のFIG.7Cに示すようなGrabCutツール223で不良箇所202aを指定してもよい。GrabCutツール223によって不良箇所202aと当該不良箇所202aの周囲とを囲むと、その領域が指定され、指定された領域内で当該不良箇所202aを自動抽出する自動抽出方式を実行する。自動抽出方式では、不良箇所202aのみが指定され、不良箇所202aの周囲の領域が指定されないので、右に白丸で示すように不良箇所202aの精密指定が自動的に行われる。これにより、ユーザの負担を軽減できる。
Further, in step SA5, for example, FIG. A
ただし、GrabCutツール223の場合、不良箇所202aの精密指定が失敗する場合があり、この場合、不良箇所202aの周囲の領域まで含まれてしまう。精密指定が失敗した場合をFIG.7Cの下に示しており、この例では円形の不良箇所202aが矩形に近い形状であると誤って指定されている。このような場合、自動抽出方式の実行後、ストローク修正を行うか、クリック修正を行うことにより、前景背景をユーザが細かく指定していき、GrabCutツール223によって自動抽出された領域の形状の修正を入力部13bが受け付ける。
However, in the case of the
また、AI Assisted指定によって不良箇所202aを指定してもよい。AI Assisted指定の場合、不良箇所202aの輪郭を大まかに指定して抽出した後、その抽出箇所の内部をFillツール等で指定する。これにより、不良箇所202aを自動抽出することができる。不良箇所202aを自動抽出した後、微修正することも可能である。
Alternatively, the
ステップSA6の後、ステップSA7に進み、アノテーションを行った画像の数が必要数に達したか否かを判定する。NOと判定されて必要数に満たない場合にはステップSA1に進む。一方、YESと判定されて必要数のアノテーションが完了すると、アノテーションを終了する。ステップSA1~SA7は、第1アノテーション方式と第2アノテーション方式とのいずれかの方式で入力された不良情報を受け付ける入力ステップである。 After step SA6, the process proceeds to step SA7 to determine whether or not the number of annotated images has reached the required number. If the determination is NO and the required number is not reached, the process proceeds to step SA1. On the other hand, when the determination is YES and the required number of annotations is completed, the annotation is terminated. Steps SA1 to SA7 are input steps for receiving defect information input by either the first annotation method or the second annotation method.
(アノテーションの具体例)
図8のFIG.8Aは、不良品画像202に1本の線状の不良箇所202aが存在する場合を示している。FIG.8Bは、ステップSA3の第1アノテーション方式によって不良品ラベルA1が付与された状態を示している。FIG.8Cは、ステップSA4の領域指定方式で矩形状の枠206を生成し、生成した枠206で不良箇所202aを囲むことによって当該不良箇所202aを指定した場合を示している。FIG.8Dは、ステップSA4の領域指定方式で複数の点を繋ぐ枠213を生成し、生成した枠213で不良箇所202aを囲むことによって当該不良箇所202aを指定した場合を示している。FIG.8Eは、ステップSA5の精密指定方式でフリーハンドツールを使用して不良箇所202aを囲む枠230を生成し、この枠230によって不良箇所202aを指定した場合を示している。ユーザは、第1アノテーション方式の後、領域指定方式によるアノテーションを行ってもよいし、精密指定方式によるアノテーションを行ってもよい。領域指定方式によるアノテーション後、当該領域指定方式によるアノテーションを取り消してから、精密指定方式によるアノテーションを行ってもよい。
(Specific example of annotation)
FIG. 8A shows the case where the
図9のFIG.9Aは、不良品画像202に、互いに交わる2本の線状の不良箇所202aが存在する場合を示している。FIG.9Bは、ステップSA3の第1アノテーション方式によって不良品ラベルA1が付与された状態を示している。FIG.9Cは、ステップSA4の領域指定方式で矩形状の枠206を生成し、生成した枠206で不良箇所202aを囲むことによって当該不良箇所202aを指定した場合を示している。FIG.9Dは、ステップSA4の領域指定方式で複数の点を繋ぐ枠213を生成し、生成した枠213で不良箇所202aを囲むことによって当該不良箇所202aを指定した場合を示している。FIG.9Eは、ステップSA5の精密指定方式でフリーハンドツールを使用して不良箇所202aを囲む枠230を生成し、この枠230によって不良箇所202aを指定した場合を示している。FIG.9D及びFIG.9Eに示す例では、FIG.9Cに示す例に比べて不良箇所202aの精密指定が可能になる。
FIG. 9A shows the case where the
FIG.9Fは、ステップSA4の領域指定方式で矩形状の枠206を2つ生成し、2つの枠206で不良箇所202aを指定した場合を示している。FIG.9Gは、ステップSA4の領域指定方式で矩形状の枠206と、複数の点を繋ぐ枠213とを生成し、枠206、213で不良箇所202aを指定した場合を示している。このように、複数種の枠206、213を組み合わせて不良箇所202aを指定してもよい。
FIG. 9F shows the case where two
(機械学習ネットワークのパラメータ調整手順の第1の例)
プロセッサ13cは、第1アノテーション方式で入力された不良情報を有する不良品画像202と、第2アノテーション方式で入力された不良情報を有する不良品画像202との両方を機械学習ネットワークに学習させる。すなわち、第1アノテーション方式で不良品画像202であることを示す不良品ラベルA1が付与された不良品画像202と、第2アノテーション方式で不良箇所202aが指定された不良品画像202とを単一の前記機械学習ネットワークに入力し、各不良品画像202の不良情報に基づいて当該機械学習ネットワークのパラメータを調整するように構成されている。
(First example of parameter adjustment procedure for machine learning network)
The
以下、図10に示すフローチャートに基づいて、機械学習ネットワークのパラメータ調整手順の第1の例について具体的に説明する。機械学習ネットワークのパラメータ調整は、ユーザが行ってもよいし、設定装置1を製造するメーカが行ってもよいし、クラウド上でおこなってもよい。
A first example of the parameter adjustment procedure of the machine learning network will be specifically described below based on the flowchart shown in FIG. The parameter adjustment of the machine learning network may be performed by the user, by the manufacturer of the
スタート後のステップSB1では、第1アノテーション方式によるアノテーションを行う。ステップSB2では、プロセッサ13cが、第1アノテーション方式で良品ラベルA2が付与された良品画像203と、第1アノテーション方式で不良品ラベルA1が付与された不良品画像202を機械学習ネットワークに学習させる。すなわち、プロセッサ13cは、各良品画像203の良品情報と、各不良品画像202の不良情報とに基づいて機械学習ネットワークのパラメータを調整する。ステップSB2で機械学習ネットワークに学習させる良品画像203及び不良品画像202の枚数は任意の枚数に設定することができる。ステップSB2は、不良品画像の不良情報に基づいて機械学習ネットワークのパラメータを調整する調整ステップである。
At step SB1 after the start, annotation is performed according to the first annotation method. At step SB2, the
その後、ステップSB3に進み、プロセッサ13cが検証処理を実行する。具体的には、第1アノテーション方式で不良品画像202であることを示す不良品ラベルA1が付与された不良品画像202を学習することにより生成された機械学習ネットワークに、プロセッサ13cが複数の互いに異なる検証用画像データを入力して当該検証用画像データの良否判定を機械学習ネットワークに実行させる。ステップSB3では、プロセッサ13cが図11に示すようなユーザーインターフェース画面300を生成し、表示制御部13aが表示装置4に表示させる。ステップSB3は、パラメータが調整された後の機械学習ネットワークに検証用画像データを入力して当該検証用画像データの良否判定を実行する検証ステップである。
After that, the process proceeds to step SB3, and the
ユーザーインターフェース画面300には、検証用画像データを表示する検証用画像データ表示領域301が設けられている。検証用画像データ表示領域301には、プロセッサ13cが機械学習ネットワークに入力した検証用画像データが一覧形式で表示される。「OK」と付されている検証用画像データは良品画像であり、「NG」と付されている検証用画像データは不良品画像である。
The
ユーザーインターフェース画面300には、拡大画像表示領域302が設けられている。検証用画像データ表示領域301に表示されている検証用画像データのうち、ユーザが選択した検証用画像データが拡大画像表示領域302に拡大表示される。
A
ユーザーインターフェース画面300には、学習パラメータ分析領域303が設けられている。すなわち、プロセッサ13cは、複数の検証用画像データの良否判定を機械学習ネットワークに実行させることにより、複数の判定結果を取得する。表示制御部13aは、プロセッサ13cが取得した複数の判定結果を表示装置4に学習パラメータ分析領域303として表示させることで、ユーザは機械学習ネットワークの推論性能がどの程度であるかを把握できる。
A learning
本例では、判定結果の表示形態として累積ヒストグラムを表示させる場合について説明する。この場合、例えば、プロセッサ13cは、判定結果として、良品画像であると判定された度数と、不良品画像であると判定された度数とを取得する。プロセッサ13cは、良品画像であると判定された度数と、不良品画像であると判定された度数とに基づく累積ヒストグラムを生成する。表示制御部13aは、プロセッサ13cが生成した累積ヒストグラムを表示装置4に表示させる。図11に示す学習パラメータ分析領域303には、良品画像の度数分布と、不良品画像の度数分布とがグラフ形式で表示される。図11に示すグラフでは、良品画像の領域(図中にOKと記載された領域)と不良品画像の領域(図中にNGと記載された領域)とが分離できていない。このような場合には、機械学習ネットワークの推論性能が不十分であると考えられるので、ステップSB4において、ステップSB2のパラメータ調整で望ましい結果が得られていないと判断する。一方、ステップSB4で望ましい結果が得られたと判断される場合には、ステップSB5に進む。「望ましい結果が得られたと判断される場合」については後述する。ステップSB5の「運用」とは、外観検査装置を運用可能な状態することであり、直ちに運用を開始してもよいし、待機状態であってもよい。
In this example, a case will be described in which a cumulative histogram is displayed as the display form of the determination result. In this case, for example, the
ステップSB4でNOと判定されて進んだステップSB6では、ユーザに対して第2アノテーションの実行を促す。すなわち、図11に示すユーザーインターフェース画面300には、メッセージ表示領域304が設けられている。この例では、良品画像の領域と不良品画像の領域とが分離できておらず、機械学習ネットワークの推論性能が不十分であると考えられるので、メッセージ表示領域304には、機械学習ネットワークの推論性能を向上させる方法をプロセッサ13cが生成し、表示制御部13aが表示装置4に表示させる。機械学習ネットワークの推論性能を向上させる方法としては、例えば「特徴サイズを見直す」、「画像の変動を考慮する」、「アノテーションを詳細化する」等である。
At Step SB6, to which the determination at Step SB4 is NO, the user is urged to perform the second annotation. That is, a
上述したように第2アノテーション方式は第1アノテーション方式に比べて詳細なアノテーションが可能である。よって、「アノテーションを詳細化する」という表示をメッセージ表示領域304に表示することは、ユーザに対して第2アノテーション方式の実行を促すこと、または機械学習ネットワークの推論性能の向上させる方法の選択肢として第2アノテーションがあることをユーザに提示することである。
As described above, the second annotation method enables more detailed annotation than the first annotation method. Therefore, displaying the display "refine the annotation" in the
図11に示すユーザーインターフェース画面300には、画像数表示領域305が設けられている。画像数表示領域305には、表が表示されており、その表には「ラベル指定」の欄が設けられている。「ラベル指定」の欄には、第1アノテーション方式で不良品ラベルA1が付与された不良品画像202のうち、不良品画像として検出できた画像数と、不良品画像として検出できなかった画像数とが表示される。本例では、不良品画像として検出できた画像数が「80」であり、不良品画像として検出できなかった画像数が「6」である。つまり、検証処理での良否判定の結果、不良品に対応する検証用画像データであるにも関わらず不良として判定されなかった画像が6枚あるということは、機械学習ネットワークの推論性能が不十分であると判断できる。尚、仮に、不良品画像として検出できなかった画像数が「0」であった場合、機械学習ネットワークの推論性能が十分であると判断できるので、その機械学習ネットワークで運用を開始すればよい。
A
ユーザは、画像数表示領域305に表示されている表のうち、不良品画像として検出できなかった画像数を示している数字「6」をマウス52でクリックすることが可能である。数字「6」をマウス52でクリックすると、図12に示すように、表示制御部13aは、不良品に対応する検証用画像データであるにも関わらず不良として判定されなかった6枚の画像を表示装置4に表示させる。具体的には、上記6枚の画像をユーザーインターフェース画面300の検証用画像データ表示領域301に一覧で表示する。画像の枚数が多い場合には、上下や左右のスクロールを利用して全ての画像をユーザが閲覧可能にしておく。
The user can use the
ユーザが第2アノテーションを実行する場合には、図12に示すユーザーインターフェース画面300の検証用画像データ表示領域301に表示されている上記6枚の画像の中から所望の画像を選択する。この選択操作は、例えばマウス52等の操作機器によって可能である。つまり、入力部13bは、表示装置4に一覧表示された画像の中から第2アノテーション方式で不良箇所の指定を行う画像の選択入力を受け付ける。
When the user executes the second annotation, a desired image is selected from the six images displayed in the verification image
入力部13bが画像の選択入力を受け付けると、図13に示すように、表示制御部13aは、選択された画像をユーザーインターフェース画面300の拡大画像表示領域302に表示させるとともに、上述した指定方式選択ウインドウ204も表示させる。ユーザは、指定方式選択ウインドウ204のツールを使用して、領域指定方式によるアノテーションや、精密指定方式によるアノテーションを実行する。このようにして、入力部13bは、選択された画像に対して第2アノテーション方式で不良箇所の指定を受け付け、受け付けた結果は、画像と共に記憶装置19に記憶される。1枚の画像に対する第2アノテーション方式での指定が終わると、別の画像を選択し、その別の画像に対して第2アノテーション方式で不良箇所の指定をおこなってもよい。以上が図10に示すフローチャートのステップSB6の処理である。
When the
ステップSB6の後、ステップSB7に進む。ステップSB7では、ステップSB6において不良箇所が第2アノテーション方式により指定された検証用画像データを機械学習ネットワークに学習させて当該機械学習ネットワークのパラメータを更新する更新処理を実行する。学習を実行する際には、ユーザがユーザーインターフェース画面300の実行ボタン306を操作すればよい。すなわち、第1アノテーション方式よりも詳細な第2アノテーション方式によって不良箇所を指定した画像を機械学習ネットワークに学習させることで、機械学習ネットワークのパラメータが変更される。これにより、機械学習ネットワークの推論性能が向上する。
After step SB6, the process proceeds to step SB7. At Step SB7, an update process is executed to update the parameters of the machine learning network by learning the verification image data in which the defective portion was designated by the second annotation method at Step SB6. When executing learning, the user may operate the
機械学習ネットワークの推論性能が十分であるか否か、即ち、望ましい結果が得られたと判断される場合であるか否かは、図14に示すユーザーインターフェース画面300の学習パラメータ分析領域303に表示されているグラフを見ることで確認できる。図14に示すグラフでは、良品画像の領域と不良品画像の領域とが完全に分離できており、良品画像と不良品画像とを明確に判別可能な推論性能を機械学習ネットワークが持っていることが分かる。
Whether or not the inference performance of the machine learning network is sufficient, that is, whether or not it is determined that a desired result has been obtained is displayed in the learning
また、図14に示すように、画像数表示領域305に表示されている表には「四角領域指定」の欄と、「詳細指定」の欄とが設けられている。「四角領域指定」とは、領域指定方式によるアノテーションを行った後に不良品画像として検出できた画像数と、不良品画像として検出できなかった画像数とを示す欄である。不良品画像として検出できた画像数が「87」となっているので、不良品画像として検出すべき画像の全てを、不良品画像として検出できていることが分かる。また、「詳細指定」とは、精密指定方式によるアノテーションを行った後に不良品画像として検出できた画像数と、不良品画像として検出できなかった画像数とを示す欄である。例えば、「四角領域指定」の欄で、不良品画像として検出できなかった画像数が「0」以外である場合には、ユーザが精密指定方式によるアノテーションを行えばよい。「詳細指定」の欄で、不良品画像として検出できなかった画像数を「0」にすることができる。
In addition, as shown in FIG. 14, the table displayed in the image
以上が設定装置1を使用した設定方法の説明である。第1アノテーション方式のみで十分な推論性能が得られる場合には、第2アノテーション方式を実行することなく、運用に移行することができるので、ユーザに無用な負担を強いることはない。また、第1アノテーション方式のみで十分な推論性能が得られない場合には、第2アノテーション方式のうち、比較的負担の少ない領域指定方式でアノテーションを行って推論性能を確認することができる。その結果、十分な推論性能が得られていない場合には、必要な画像についてのみ、精密指定方式によるアノテーションを実行すればよいので、ユーザの負担が軽減される。
The above is the description of the setting method using the
(機械学習ネットワークのパラメータ調整手順の第2の例)
図15に示すフローチャートに基づいて、機械学習ネットワークのパラメータ調整手順の第2の例について具体的に説明する。スタート後のステップSC1は図10に示すフローチャートのステップSB1と同じである。その後、ステップSC2では、第2アノテーション方式によるアノテーションを行う。ステップSC3では、プロセッサ13cが、第1アノテーション方式で良品ラベルA2が付与された良品画像203と、第1アノテーション方式で不良品ラベルA1が付与された不良品画像202と、第2アノテーション方式で不良箇所が指定された画像とを機械学習ネットワークに学習させる。すなわち、プロセッサ13cは、各良品画像203の良品情報と、各不良品画像202の不良情報とに基づいて機械学習ネットワークのパラメータを調整する。
(Second example of parameter adjustment procedure for machine learning network)
A second example of the parameter adjustment procedure of the machine learning network will be specifically described based on the flowchart shown in FIG. 15 . Step SC1 after the start is the same as step SB1 in the flow chart shown in FIG. After that, in step SC2, annotation is performed according to the second annotation method. At step SC3, the
その後、ステップSC4に進み、プロセッサ13cが検証処理を実行する。具体的には、ステップSC3で生成された機械学習ネットワークに、プロセッサ13cが複数の互いに異なる検証用画像データを入力して当該検証用画像データの良否判定を機械学習ネットワークに実行させる。ステップSC5、SC6は図10に示すフローチャートのステップSB4、SB5と同じである。
After that, the process proceeds to step SC4, and the
ステップSC5でNOと判定されて進んだステップSC7では、ユーザに対して再アノテーションの実行を促す。例えば、ある画像に対して第2アノテーション方式で領域指定方式しか実行していない場合には、その画像に対して精密指定方式によるアノテーションを実行するように促す。また、精密指定方式によるアノテーションをより精密に実行するように促してもよい。 At Step SC7, to which Step SC5 is judged as NO, the user is prompted to re-annotate. For example, if only the region specification method is performed on a certain image by the second annotation method, the user is prompted to perform annotation by the precise specification method on that image. In addition, the user may be prompted to perform annotation using the precise specification method more precisely.
ステップSC7の後、ステップSC8に進む。ステップSC8では、ステップSC7において再アノテーションされた検証用画像データを機械学習ネットワークに学習させて当該機械学習ネットワークのパラメータを更新する更新処理を実行する。再アノテーションによって不良箇所を指定した画像を機械学習ネットワークに学習させることで、機械学習ネットワークのパラメータが変更される。これにより、機械学習ネットワークの推論性能が向上する。 After step SC7, the process proceeds to step SC8. In step SC8, an update process is executed to update the parameters of the machine learning network by learning the verification image data re-annotated in step SC7. The parameters of the machine learning network are changed by having the machine learning network learn images in which the defect locations are specified by re-annotation. This improves the inference performance of the machine learning network.
(異常抽出用のニューラルネットワークの詳細)
上記機械学習ネットワークは、例えば図16に概念図として示すような異常抽出用のニューラルネットワークで構成されている。異常抽出用のニューラルネットワークは、入力画像を構成している各画素が異常であるかを表す異常度をヒートマップ(異常度マップ)として出力する。このヒートマップが出力画像になる。したがって、良品画像を入力画像とした場合、出力画像は全てが同じ画素値の画素で構成された異常度マップとなる一方、不良品画像を入力画像とした場合、出力画像は不良箇所(異常箇所)の画素だけ他の画素と画素値が異なる異常度マップとなる。
(Details of neural network for anomaly extraction)
The machine learning network is composed of, for example, a neural network for anomaly extraction as conceptually shown in FIG. The anomaly extraction neural network outputs an anomaly degree as a heat map (abnormality degree map) indicating whether each pixel forming the input image is abnormal. This heatmap becomes the output image. Therefore, when a non-defective product image is used as an input image, the output image is an anomaly degree map in which all pixels with the same pixel value are configured. ) becomes an abnormality degree map in which pixel values differ from those of other pixels.
本実施形態では、第2アノテーション方式による精密指定でなくても、さらに、第1アノテーション方式と第2アノテーション方式のように複数アノテーション方式が混在している状態でも、不良箇所だけを抽出可能な学習方法を採用している。すなわち、図17に示すように、プロセッサ13cは、第1アノテーション方式で入力された良品情報を有する良品画像と不良品情報を有する不良品画像との両方を含み、かつ互いに異なる少なくとも3枚の画像を機械学習ネットワークに入力して異常度マップを生成する。図17に示す例では、第1入力画像、第2入力画像及び第3入力画像を1つのグループとして同一の機械学習ネットワークに入力している。第1入力画像及び第2入力画像は良品画像であり、第3入力画像は不良品画像である。第1入力画像、第2入力画像及び第3入力画像には、第1アノテーション方式によってラベルA1、A2が付与されている。
In this embodiment, even if the second annotation method is not used for precise designation, and even if multiple annotation methods are mixed such as the first annotation method and the second annotation method, learning that can extract only the defective part is performed. method is adopted. That is, as shown in FIG. 17, the
プロセッサ13cは、第1アノテーション方式で入力された良品情報を有する良品画像を機械学習ネットワークに入力して生成された異常度マップ内の各画素値が0となるように当該機械学習ネットワークのパラメータを調整する。本例では、第1入力画像及び第2入力画像が良品画像であることから、第1出力画像及び第2出力画像内の各画素値が0となるように制限をかける。
The
また、プロセッサ13cは、良品情報を有する画像同士の異常度マップ間の距離を近づける処理と、不良品情報を有する画像同士の異常度マップ間の距離を近づける処理との少なくとも一方を実行可能に構成されている。本例では、第1入力画像及び第2入力画像が良品画像であることから、第1出力画像及び第2出力画像の異常度マップ間の距離を近づける処理を行う。尚、第1入力画像及び第2入力画像が不良品画像であった場合には、第1出力画像及び第2出力画像の異常度マップ間の距離を近づける処理を行う。
In addition, the
また、プロセッサ13cは、良品情報を有する画像の異常度マップと、不良品情報を有する画像の異常度マップとの距離を所定以上離す処理を実行可能に構成されている。本例では、第2入力画像が良品画像であり、第3入力画像が不良品画像であることから、第2出力画像と第3出力画像の異常度マップを所定以上離す処理を行う。
In addition, the
具体的には、以下の計算式及び考え方(例えば下記演算方法1、2)を適用することができる。まず、Loss関数の定義を行う。各入力画像の対応異常度マップの画素値平均は以下の式で計算できる。
Specifically, the following calculation formulas and ideas (for example,
尚、nは異常度マップHの画素数、x、yは異常度マップHの画素座標値である。 In addition, n is the number of pixels of the abnormality degree map H, and x and y are pixel coordinate values of the abnormality degree map H.
異常度マップの画素値平均を使用し、異常度マップ間の距離を画素値平均の差の絶対値に定義する。 The average pixel values of the anomaly maps are used, and the distance between the anomaly maps is defined as the absolute value of the difference between the average pixel values.
演算方法1(異常度マップ間距離を直接に制限する方法)
αは距離マージンを表すハイパーパラメータであり、λは異常度マップの良品対応部分のLoss制限の強さを表すハイパーパラメータである。 α is a hyperparameter that represents the distance margin, and λ is a hyperparameter that represents the strength of the Loss restriction for the non-defective part of the anomaly degree map.
演算方法2(異常度マップ間距離を間接に制限する方法)
尚、異常度マップ間の距離は異常度マップを一次元ベクトルにし、ベクトル間のユークリッド距離として定義することも可能である。また、Loss関数を最小化することで学習が行える。 It should be noted that the distance between the anomaly maps can also be defined as the Euclidean distance between the vectors by converting the anomaly maps into one-dimensional vectors. Also, learning can be performed by minimizing the Loss function.
以上は、第1アノテーション方式によってラベルが付与されている画像を学習する場合であるが、第2アノテーション方式によって不良箇所が指定されている画像についても学習できる。すなわち、プロセッサ13cは、第2アノテーション方式で入力された不良品情報を有する不良品画像を機械学習ネットワークに入力して生成された異常度マップ内において、第2アノテーション方式で指定された不良箇所以外に対応する部分の画素値が0となるように当該機械学習ネットワークのパラメータを調整する。
The above is the case of learning images labeled by the first annotation method, but learning can also be performed on images with defect locations designated by the second annotation method. That is, the
図18に基づいて具体的に説明する。図18は、第3入力画像に対して第2アノテーション方式により不良箇所が指定されている場合を示している。本例では、領域指定方式で不良箇所を囲む枠206を生成した場合を示しているが、精密指定方式で不良箇所を指定してもよい。第3入力画像の下にマスク画像として示すように、枠206外に対応する領域の画素値を0にする。第3出力画像では、不良箇所として指定された領域以外の部分の画素値を0にする。
A specific description will be given based on FIG. FIG. 18 shows a case where a defective portion is designated by the second annotation method for the third input image. In this example, the case where the
Loss関数の定義については上述したとおりであるが、第3入力画像に対して、アノテーション領域内外の画素平均値をそれぞれ計算する。 The definition of the Loss function is as described above, but the pixel average values inside and outside the annotation region are calculated for the third input image.
また、異常度マップの画素値平均を使用し、マップ間距離を画素値平均の差の絶対値に定義する。 Also, the average pixel values of the anomaly degree maps are used, and the distance between maps is defined as the absolute value of the difference between the average pixel values.
演算方法1(異常度マップ間距離を直接に制限する方法)
演算方法2(異常度マップ間距離を間接に制限する方法)
(実施形態の作用効果)
以上説明したように、本実施形態によれば、第1アノテーション方式では、表示装置4に表示された画像をラベル指定によって良品画像と不良品画像に振り分けることができるので、全体的に不良であると判定すべき不良品画像のアノテーションが可能になる。一方、第2アノテーション方式では、不良品画像上で不良箇所の位置や形状を具体的に指定できるので、第1アノテーション方式に比べて不良箇所を明確に指定することが可能になる。これにより、全体的に不良であると判定すべき不良品画像はユーザの手間をかけずにアノテーションを行いつつ、不良箇所を明確に指定すべき不良品画像についてはユーザが詳細にアノテーションを行うことができる。これにより、機械学習ネットワークの学習時におけるユーザの手間を削減しながら、属人性を排除し、高い検出性能を持った機械学習ネットワークを得ることができる。
(Action and effect of the embodiment)
As described above, according to the present embodiment, in the first annotation method, images displayed on the
上述の実施形態はあらゆる点で単なる例示に過ぎず、限定的に解釈してはならない。さらに、特許請求の範囲の均等範囲に属する変形や変更は、全て本発明の範囲内のものである。 The above-described embodiments are merely examples in all respects and should not be construed in a restrictive manner. Furthermore, all modifications and changes within the equivalent scope of claims are within the scope of the present invention.
以上説明したように、本発明は、例えばワークの外観を検査する外観検査装置の設定を行う場合に利用できる。 INDUSTRIAL APPLICABILITY As described above, the present invention can be used, for example, when setting an appearance inspection apparatus for inspecting the appearance of a work.
1 設定装置
13a 表示制御部
13b 入力部
13c プロセッサ
1 setting
Claims (15)
前記機械学習ネットワークに学習させるための画像を表示部に表示させる表示制御部と、
前記表示部に表示された画像に対し、良品画像または不良品画像であることを示すラベルを付与する第1アノテーション方式と、前記表示部に表示された画像が不良品画像である場合に不良箇所を指定する第2アノテーション方式とのいずれかの方式で入力された不良情報を受け付ける入力部と、
前記第1アノテーション方式でラベルが付与された良品画像または不良品画像と、前記第2アノテーション方式で入力された不良情報を有する不良品画像との両方を前記機械学習ネットワークに学習させて、当該機械学習ネットワークのパラメータを調整するプロセッサとを備える、外観検査装置の設定装置。 A work image of a work to be inspected is input to a machine learning network generated by learning non-defective product images corresponding to non-defective products and defective product images corresponding to defective products, and the quality of the work image is determined. A setting device for setting the appearance inspection device to be performed,
a display control unit for displaying an image for learning by the machine learning network on a display unit;
A first annotation method of adding a label indicating a non-defective product image or a defective product image to the image displayed on the display unit; an input unit that receives defect information input by one of the second annotation method that specifies the
Let the machine learning network learn both the non-defective product image or the defective product image labeled by the first annotation method and the defective product image having the defect information input by the second annotation method, and a processor for adjusting parameters of the learning network.
前記入力部は、前記第2アノテーション方式として、不良品画像の不良箇所を囲むことで当該不良箇所を指定する領域指定方式と、不良品画像の不良箇所をなぞることで当該不良箇所を自由形状で指定する精密指定方式とが選択可能に構成されている、外観検査装置の設定装置。 The setting device according to claim 1,
The input unit includes, as the second annotation method, a region specification method in which the defective portion is designated by enclosing the defective portion in the defective product image, and a free-form defective portion by tracing the defective portion in the defective product image. A setting device for an appearance inspection device, configured to be able to select a precise specification method to specify.
前記入力部は、前記第2アノテーション方式として、不良品画像の不良箇所と当該不良箇所の周囲とを囲むことによって指定された領域内で当該不良箇所を自動抽出する自動抽出方式を実行可能に構成されている、外観検査装置の設定装置。 The setting device according to claim 1,
The input unit is configured to be capable of executing, as the second annotation method, an automatic extraction method for automatically extracting the defective portion within a designated area by enclosing the defective portion of the defective product image and the periphery of the defective portion. A setting device for a visual inspection device.
前記入力部は、前記第2アノテーション方式として、前記自動抽出方式の実行後、当該自動抽出方式で自動抽出された領域の形状の修正を受け付ける、外観検査装置の設定装置。 The setting device according to claim 3,
The setting device of the appearance inspection apparatus, wherein the input unit receives correction of the shape of the region automatically extracted by the automatic extraction method as the second annotation method after execution of the automatic extraction method.
前記プロセッサは、前記第1アノテーション方式でラベルが付与された良品画像または不良品画像と、前記第2アノテーション方式で不良箇所が指定された不良品画像とを単一の前記機械学習ネットワークに入力し、当該機械学習ネットワークのパラメータを調整する、外観検査装置の設定装置。 The setting device according to any one of claims 1 to 4,
The processor inputs a non-defective product image or a defective product image labeled by the first annotation method and a defective product image to which a defective part is specified by the second annotation method into the single machine learning network. , a setting device for a visual inspection device for adjusting the parameters of the machine learning network.
前記プロセッサは、
前記第1アノテーション方式で良品画像または不良品画像であることを示すラベルが付与された良品画像または不良品画像を学習することにより生成された前記機械学習ネットワークに、検証用画像データを入力して当該検証用画像データの良否判定を実行する検証処理と、
前記検証処理での前記良否判定の結果、不良品に対応する前記検証用画像データであるにも関わらず不良として判定されなかった場合、不良箇所が前記第2アノテーション方式により指定された前記検証用画像データを前記機械学習ネットワークに学習させて当該機械学習ネットワークのパラメータを更新する更新処理とを実行可能に構成されている、外観検査装置の設定装置。 The setting device according to any one of claims 1 to 5,
The processor
inputting verification image data to the machine learning network generated by learning a non-defective product image or a defective product image labeled as a non-defective product image or a defective product image by the first annotation method; a verification process for determining whether the verification image data is good or bad;
As a result of the pass/fail determination in the verification process, if the verification image data corresponding to the defective product is not determined to be defective, the verification image data in which the defective portion is specified by the second annotation method is selected. A setting device for a visual inspection apparatus configured to be capable of executing an update process of causing the machine learning network to learn image data and updating parameters of the machine learning network.
前記表示制御部は、前記第1アノテーション方式で不良品画像のラベルが付与された画像の中で、不良として判定されなかった画像の一覧を前記表示部に表示させ、
前記入力部は、前記表示部に一覧表示された画像の中から前記第2アノテーション方式で不良箇所の指定を行う画像の選択入力を受け付け、選択された画像に対して前記第2アノテーション方式で不良箇所の指定を受け付ける、外観検査装置の設定装置。 The setting device according to any one of claims 1 to 6,
The display control unit causes the display unit to display a list of images that are not determined to be defective among the images labeled as defective product images by the first annotation method,
The input unit accepts a selection input of an image for which a defective portion is to be designated by the second annotation method from among the images displayed as a list on the display unit, and determines whether the selected image is defective by the second annotation method. A setting device for a visual inspection device that accepts location designations.
前記プロセッサは、前記第1アノテーション方式で不良品画像であることを示すラベルが付与された不良品画像を学習することにより生成された前記機械学習ネットワークに、複数の互いに異なる検証用画像データを入力して当該各検証用画像データの良否判定を実行することによって判定結果を取得し、
前記表示制御部は、前記プロセッサが取得した前記判定結果を前記表示部に表示させる、外観検査装置の設定装置。 The setting device according to any one of claims 1 to 6,
The processor inputs a plurality of verification image data different from each other to the machine learning network generated by learning the defective product image labeled as the defective product image by the first annotation method. to acquire the judgment result by executing the pass/fail judgment of each verification image data,
The display control unit is a setting device for a visual inspection apparatus, which causes the display unit to display the determination result acquired by the processor.
前記プロセッサは、前記判定結果として、良品画像であると判定された度数と不良品画像であると判定された度数とを取得し、良品画像であると判定された度数と不良品画像であると判定された度数とに基づく累積ヒストグラムを生成し、
前記表示制御部は、前記プロセッサが生成した前記累積ヒストグラムを前記表示部に表示させる、外観検査装置の設定装置。 The setting device according to claim 8,
The processor acquires the number of times the image is determined to be a non-defective image and the number of times the image is determined to be a defective image as the determination results, and the number of times the image is determined to be a non-defective image and the image is determined to be a defective image. generating a cumulative histogram based on the determined frequencies and
A setting device for a visual inspection apparatus, wherein the display control unit causes the display unit to display the cumulative histogram generated by the processor.
前記プロセッサは、
前記第1アノテーション方式で入力された良品情報を有する良品画像と不良品情報を有する不良品画像との両方を含み、かつ互いに異なる少なくとも3枚の画像を前記機械学習ネットワークに入力して異常度マップを生成し、
良品情報を有する画像の異常度マップと不良品情報を有する画像の異常度マップとの距離を所定以上離す処理を実行可能に構成されている、外観検査装置の設定装置。 A setting device according to any one of claims 1 to 9,
The processor
At least three images that include both a non-defective product image having non-defective product information and a defective product image having defective product information input by the first annotation method and are different from each other are input to the machine learning network to provide an anomaly map to generate
A setting device for a visual inspection apparatus configured to be capable of executing a process of separating an abnormality degree map of an image having non-defective product information and an abnormality degree map of an image having defective product information by a predetermined distance or more.
前記プロセッサは、良品情報を有する画像同士の異常度マップ間の距離を近づける処理と、不良品情報を有する画像同士の異常度マップ間の距離を近づける処理との少なくとも一方を実行可能に構成されている、外観検査装置の設定装置。 The setting device according to claim 10, wherein
The processor is configured to be able to execute at least one of a process of reducing the distance between the images having non-defective product information and the process of reducing the distance between the abnormality maps of the images having defective product information. A setting device for visual inspection equipment.
前記プロセッサは、前記第1アノテーション方式で入力された良品情報を有する良品画像を前記機械学習ネットワークに入力して生成された異常度マップ内の各画素値が0となるように当該機械学習ネットワークのパラメータを調整する、外観検査装置の設定装置。 The setting device according to claim 10 or 11,
The processor inputs the non-defective product image having the non-defective product information input by the first annotation method to the machine learning network so that each pixel value in the abnormality map generated is 0 of the machine learning network A setting device for visual inspection equipment that adjusts parameters.
前記プロセッサは、前記第2アノテーション方式で入力された不良品情報を有する不良品画像を前記機械学習ネットワークに入力して生成された異常度マップ内において、前記第2アノテーション方式で指定された不良箇所以外に対応する部分の画素値が0となるように当該機械学習ネットワークのパラメータを調整する、外観検査装置の設定装置。 A setting device according to claim 12, wherein
The processor inputs the defective product image having the defective product information input by the second annotation method to the machine learning network, and the defect location specified by the second annotation method in the anomaly degree map generated by the machine learning network A setting device for a visual inspection device that adjusts the parameters of the machine learning network so that the pixel value of the portion corresponding to the area other than the above is 0.
前記機械学習ネットワークに学習させるための画像を表示部に表示させる表示ステップと、
前記表示ステップで前記表示部に表示された画像に対し、良品画像または不良品画像であることを示すラベルを付与する第1アノテーション方式と、前記表示部に表示された画像が不良品画像である場合に不良箇所を指定する第2アノテーション方式とのいずれかの方式で入力された不良情報を受け付ける入力ステップと、
前記第1アノテーション方式でラベルが付与された良品画像または不良品画像と、前記第2アノテーション方式で入力された不良情報を有する不良品画像との両方を前記機械学習ネットワークに学習させて、当該機械学習ネットワークのパラメータを調整する調整ステップとを備える、外観検査装置の設定方法。 A work image of a work to be inspected is input to a machine learning network generated by learning non-defective product images corresponding to non-defective products and defective product images corresponding to defective products, and the quality of the work image is determined. A setting method for a visual inspection apparatus to perform
a display step of displaying an image for learning by the machine learning network on a display unit;
a first annotation method of adding a label indicating a non-defective product image or a defective product image to the image displayed on the display unit in the display step; an input step of receiving defect information input by any one of a second annotation method for designating a defect location in a case;
Let the machine learning network learn both the non-defective product image or the defective product image labeled by the first annotation method and the defective product image having the defect information input by the second annotation method, and an adjusting step of adjusting parameters of the learning network.
前記第1アノテーション方式で不良品画像であることを示すラベルが付与された不良品画像を前記機械学習ネットワークに学習させた後、検証用画像データを前記機械学習ネットワークに入力して当該検証用画像データの良否判定を実行する検証ステップと、
前記検証ステップでの前記良否判定の結果、不良品に対応する前記検証用画像データであるにも関わらず不良として判定されなかった場合、不良箇所を前記第2アノテーション方式により指定した後、当該第2アノテーション方式により不良箇所が指定された前記検証用画像データを前記機械学習ネットワークに学習させて当該機械学習ネットワークのパラメータを更新する更新ステップとをさらに備える、外観検査装置の設定方法。 In the setting method according to claim 14,
After having the machine learning network learn the defective product image to which the label indicating the defective product image is given by the first annotation method, the verification image data is input to the machine learning network to generate the verification image. a verification step for performing pass/fail judgment of data;
As a result of the pass/fail judgment in the verification step, if the verification image data corresponding to the defective product is not judged to be defective, after specifying the defective portion by the second annotation method, and an updating step of causing the machine learning network to learn the verification image data in which the defective portion is designated by the 2 annotation method, and updating parameters of the machine learning network.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2021190169A JP2023077051A (en) | 2021-11-24 | 2021-11-24 | Setting device and setting method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2021190169A JP2023077051A (en) | 2021-11-24 | 2021-11-24 | Setting device and setting method |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2023077051A true JP2023077051A (en) | 2023-06-05 |
Family
ID=86610394
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2021190169A Pending JP2023077051A (en) | 2021-11-24 | 2021-11-24 | Setting device and setting method |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2023077051A (en) |
-
2021
- 2021-11-24 JP JP2021190169A patent/JP2023077051A/en active Pending
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP2009175954A (en) | Generating device of processing robot program | |
US10306149B2 (en) | Image processing apparatus, robot system, robot, and image processing method | |
JP2020125919A (en) | Image inspection device | |
EP1710649A2 (en) | Motion control apparatus for teaching robot position, robot-position teaching apparatus, motion control method for teaching robot postion, robot-position teaching method, and motion control program for teaching robot-position | |
CN1580748A (en) | Methods and apparatus for inspection of lines embedded in highly textured material | |
JP2013148361A (en) | Method for registering inspection standard for soldering inspection, and board inspection apparatus based on said method | |
JP7337495B2 (en) | Image processing device, its control method, and program | |
JP2020125920A (en) | Image inspection device | |
JP2020125918A (en) | Image inspection device | |
US20230162344A1 (en) | Appearance inspection apparatus and appearance inspection method | |
CN115803155A (en) | Programming device | |
JP2017191492A (en) | Information processing device, information processing method and video generation system | |
JP2020187071A (en) | Image inspection device and method for setting image inspection device | |
JP2023090819A (en) | Image inspection device and method for setting image inspection device | |
JP2570239B2 (en) | Mounting component inspection data generation method and mounting component inspection apparatus used for implementing the method | |
JP5277505B2 (en) | End material management method and management system | |
JP2023077051A (en) | Setting device and setting method | |
JP7391571B2 (en) | Electronic devices, their control methods, programs, and storage media | |
CN111609933A (en) | Spectroscopic inspection method, image processing apparatus, and robot system | |
WO2021215333A1 (en) | Program editing device | |
JP2019212166A (en) | Image processing apparatus, image processing method, and image processing program | |
JP2013238947A (en) | Substrate wiring operation support system | |
JP6220514B2 (en) | Robot control system and robot control method | |
JP6835020B2 (en) | Image processing system, image processing device, image processing program | |
JP6629250B2 (en) | Work support device, work support method, and program |