JP7080123B2 - Image inspection equipment - Google Patents

Image inspection equipment Download PDF

Info

Publication number
JP7080123B2
JP7080123B2 JP2018137839A JP2018137839A JP7080123B2 JP 7080123 B2 JP7080123 B2 JP 7080123B2 JP 2018137839 A JP2018137839 A JP 2018137839A JP 2018137839 A JP2018137839 A JP 2018137839A JP 7080123 B2 JP7080123 B2 JP 7080123B2
Authority
JP
Japan
Prior art keywords
image
search
inspection
unit
area
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
JP2018137839A
Other languages
Japanese (ja)
Other versions
JP2020016948A (en
Inventor
真達 下平
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Keyence Corp
Original Assignee
Keyence Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Keyence Corp filed Critical Keyence Corp
Priority to JP2018137839A priority Critical patent/JP7080123B2/en
Publication of JP2020016948A publication Critical patent/JP2020016948A/en
Application granted granted Critical
Publication of JP7080123B2 publication Critical patent/JP7080123B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Description

本発明は、検査対象物の外観を検査する画像検査装置に関する。 The present invention relates to an image inspection device for inspecting the appearance of an object to be inspected.

従来より、例えば、特許文献1に開示されているように、各種製品等のワークの外観を検査する現場では画像検査装置が使用されることがある。画像検査装置は、ワークの位置や姿勢を検出し、検査領域を設定するサーチ処理と、サーチ処理の結果に基づいて設定された検査領域内の傷などの表面欠陥を検査する検査処理とが行われる。サーチ処理を行うためには、設定時に使用者がパターン領域を設定画像上で設定し、設定されたパターン領域内のワークの特徴量を抽出する。そして、検査運用時に入力された検査画像に対し、設定された特徴量と相関値が高い領域を特定し、ワークの位置や姿勢が特定される。 Conventionally, for example, as disclosed in Patent Document 1, an image inspection device may be used at a site for inspecting the appearance of a work such as various products. The image inspection device performs a search process that detects the position and posture of the work and sets the inspection area, and an inspection process that inspects surface defects such as scratches in the inspection area set based on the result of the search process. Will be. In order to perform the search process, the user sets the pattern area on the set image at the time of setting, and extracts the feature amount of the work in the set pattern area. Then, with respect to the inspection image input during the inspection operation, a region having a high correlation value with the set feature amount is specified, and the position and posture of the work are specified.

特開2014-55916号公報Japanese Unexamined Patent Publication No. 2014-55916

ところで、画像検査装置のサーチ処理の手法としては、例えば正規化相関サーチが一般的によく使用されている。正規化相関サーチは、パターン領域と正規化相関値が最も高くなる画像領域を、パターン領域の位置や角度を変化させながらサーチする手法である。正規化相関サーチの場合、検査画像内に、本来検出したい領域と類似した濃淡値を有する領域が他に存在していると、誤検出を起こしやすい。 By the way, as a method of search processing of an image inspection device, for example, a normalized correlation search is generally often used. The normalized correlation search is a method of searching the pattern region and the image region having the highest normalized correlation value while changing the position and angle of the pattern region. In the case of the normalized correlation search, if there is another region in the inspection image having a shading value similar to the region originally desired to be detected, erroneous detection is likely to occur.

一方、パターン領域内のエッジを特徴量とするエッジベースのサーチ処理も知られている。エッジベースのサーチ処理では、類似した濃淡値を有する領域が検査画像内に存在していたとしても、類似したエッジが検査画像内に存在していなければ誤検出にはつながらないので、この点では正規化相関サーチに比べて有利である。しかし、エッジベースのサーチ処理では、検査画像内でエッジを検出することができなければ、サーチが失敗する。 On the other hand, an edge-based search process using an edge in a pattern region as a feature amount is also known. In the edge-based search process, even if a region having a similar shading value exists in the inspection image, if a similar edge does not exist in the inspection image, it does not lead to false detection, so it is normal in this respect. It is advantageous compared to the canonical correlation search. However, in the edge-based search process, if the edge cannot be detected in the inspection image, the search fails.

このように、ワークの表面状態や形状によって、サーチ処理に用いられる適切な特徴量は異なる。また、あるサーチアルゴリズムでサーチ処理に成功したとしても、どの程度余裕を持ってサーチ処理に成功しているか、他にもっと適切なサーチアルゴリズムが存在しないか、使用者が判断することは困難であるという問題がある。 As described above, the appropriate feature amount used for the search process differs depending on the surface condition and shape of the work. Moreover, even if the search processing is successful with a certain search algorithm, it is difficult for the user to determine how much margin the search processing is successful with and whether there is another more suitable search algorithm. There is a problem.

本発明は、かかる点に鑑みてなされたものであり、その目的とするところは、サーチ処理において、複数のサーチアルゴリズムについての特性や検査対象物との相性を知らない使用者であっても、適切なサーチアルゴリズムを簡単に決定できるようにすることにある。 The present invention has been made in view of this point, and an object of the present invention is to allow a user who does not know the characteristics of a plurality of search algorithms or compatibility with an inspection target in a search process. The purpose is to make it easy to determine the appropriate search algorithm.

上記目的を達成するために、第1の発明は、検査対象物の外観を検査する画像検査装置において、前記検査対象物を撮像して得られた登録画像を記憶する登録画像記憶部と、前記登録画像記憶部に記憶された前記登録画像上で、サーチ処理に用いるパターン領域を設定するパターン領域設定部と、前記パターン領域内の画像から抽出された第1の特徴量と、該第1の特徴量とは異なる第2の特徴量とを記憶する特徴量記憶部と、新たに前記検査対象物を撮像して得られた入力画像に対して、前記第1の特徴量と所定値以上の相関値を有する画像領域を検出する第1のサーチ処理と、前記第2の特徴量と所定値以上の相関値を有する画像領域を検出する第2のサーチ処理とを実行するサーチ処理部と、前記第1のサーチ処理の結果得られた画像領域の位置を表示した第1画像と、前記第2のサーチ処理の結果得られた画像領域の位置を表示した第2画像とを、同時又は切り替えて表示可能な表示制御部と、前記第1画像又は前記第2画像が表示された後に、前記第1のサーチ処理又は前記第2のサーチ処理のいずれかの選択を受け付けるサーチ処理選択部と、前記サーチ処理選択部により選択されたサーチ処理を検査設定として記憶する検査設定記憶部とを備える画像検査装置である。 In order to achieve the above object, the first invention comprises a registered image storage unit for storing a registered image obtained by imaging the inspection object in an image inspection apparatus for inspecting the appearance of the inspection object, and the above-mentioned. A pattern area setting unit for setting a pattern area used for search processing on the registered image stored in the registered image storage unit, a first feature amount extracted from an image in the pattern area, and the first feature amount. With respect to the feature amount storage unit that stores the second feature amount different from the feature amount and the input image obtained by newly imaging the inspection object, the first feature amount and the predetermined value or more are obtained. A search processing unit that executes a first search process for detecting an image region having a correlation value and a second search process for detecting an image region having a correlation value equal to or higher than a predetermined value with the second feature amount. The first image displaying the position of the image area obtained as a result of the first search process and the second image displaying the position of the image area obtained as a result of the second search process are simultaneously or switched. A display control unit that can be displayed, and a search process selection unit that accepts selection of either the first search process or the second search process after the first image or the second image is displayed. It is an image inspection apparatus including an inspection setting storage unit which stores the search process selected by the search process selection unit as an inspection setting.

この構成によれば、登録画像上で、サーチ処理に用いるパターン領域を設定すると、パターン領域内の画像から少なくとも2つの特徴量、即ち、第1の特徴量と第2の特徴量が抽出されてこれら特徴量が特徴量記憶部に記憶される。サーチ処理部は、第1の特徴量を用いて第1のサーチ処理を実行して、第1の特徴量と所定値以上の相関値を有する画像領域を検出し、また、第2の特徴量を用いて第2のサーチ処理を実行して、第2の特徴量と所定値以上の相関値を有する画像領域を検出する。第1のサーチ処理の結果得られた画像領域の位置が第1画像に表示され、また、第2のサーチ処理の結果得られた画像領域の位置が第2画像に表示される。これら第1画像や第2画像は表示制御部によって表示されるので、使用者は、第1のサーチ処理の結果及び第2のサーチ処理の結果を確認することが可能になり、どのサーチ処理を選択するか、決定するための材料として第1画像及び第2画像を利用することができる。使用者により選択されたサーチ処理は検査設定として検査設定記憶部に記憶されるので、画像検査装置の運用時には、選択されたサーチ処理により、サーチ処理が実行されることになる。 According to this configuration, when the pattern area used for the search process is set on the registered image, at least two feature amounts, that is, the first feature amount and the second feature amount are extracted from the image in the pattern area. These feature quantities are stored in the feature quantity storage unit. The search processing unit executes the first search process using the first feature amount, detects an image region having a correlation value equal to or higher than a predetermined value with the first feature amount, and also detects a second feature amount. A second search process is executed using the image to detect an image region having a correlation value of a predetermined value or more with the second feature amount. The position of the image area obtained as a result of the first search process is displayed on the first image, and the position of the image area obtained as a result of the second search process is displayed on the second image. Since these first images and second images are displayed by the display control unit, the user can confirm the result of the first search process and the result of the second search process, and which search process is performed. A first image and a second image can be used as materials for selection or determination. Since the search process selected by the user is stored in the inspection setting storage unit as the inspection setting, the search process is executed by the selected search process during the operation of the image inspection device.

第1のサーチ処理を第1のサーチアルゴリズムによるサーチ処理ということができ、また、第2のサーチ処理を第2のサーチアルゴリズムによるサーチ処理ということができるので、本発明では、サーチアルゴリズムの選択を行うこともできる。 Since the first search process can be referred to as a search process by the first search algorithm and the second search process can be referred to as a search process by the second search algorithm, in the present invention, the search algorithm is selected. You can also do it.

第2の発明は、前記表示制御部は、前記所定値以上の相関値を持った複数の画像領域の中で、相関値が最も高い最高相関画像領域と、前記最高相関画像領域の相関値未満の相関値を有する画像領域とを異なる表示形態で表示するように構成されているものとすることができる。 In the second invention, the display control unit has the highest correlation image region having the highest correlation value among the plurality of image regions having the correlation values equal to or higher than the predetermined value, and the correlation value less than the highest correlation image region. It is possible that the image area having the correlation value of is displayed in a different display form.

この構成によれば、相関値が最も高い最高相関画像領域と、それ未満の相関値を有する画像領域とを容易に区別することができる。例えば、最高相関画像領域が検査対象領域の第1候補になるとした場合、それ未満の相関値を有する画像領域は第2候補以下となり、第2候補以下がどの程度存在するか、視覚的に表現することができる。 According to this configuration, it is possible to easily distinguish between the highest correlation image region having the highest correlation value and the image region having a correlation value less than that. For example, if the highest correlation image area is the first candidate for the inspection target area, the image area having a correlation value less than that is the second candidate or less, and the extent to which the second candidate or less exists is visually expressed. can do.

異なる表示形態の例としては、最高相関画像領域を囲む枠線の色と、それ未満の相関値を有する画像領域を囲む枠線の色とを変える、枠線の線種を変える、枠線の太さを変える等を挙げることができる。また、最高相関画像領域に着色する色と、それ未満の相関値を有する画像領域に着色する色とを変えことも、異なる表示形態の一つである。 Examples of different display modes are changing the color of the border surrounding the highest correlated image area and the color of the border surrounding the image area having a correlation value less than that, changing the line type of the border, and changing the border. The thickness can be changed. Further, it is also one of the different display forms to change the color to be colored in the highest correlation image area and the color to be colored in the image area having a correlation value less than that.

第3の発明は、前記表示制御部は、前記所定値以上の相関値を持った画像領域を囲む検出枠を表示し、相関値の大きさが大きければ大きいほど前記検出枠を大きくするように構成されているものとすることができる。 In the third aspect of the invention, the display control unit displays a detection frame surrounding an image area having a correlation value equal to or higher than the predetermined value, and the larger the size of the correlation value, the larger the detection frame. It can be configured.

この構成によれば、相関値の大きさを視覚的に表現することができる。例えば、最高相関画像領域が検査対象領域の第1候補になるとした場合、それ未満の相関値を有する画像領域は第2候補以下となり、第2候補以下の相関値が第1候補の相関値とどの程度離れているか、または近いかを視覚的に表現することができる。 According to this configuration, the magnitude of the correlation value can be visually expressed. For example, if the highest correlated image area is the first candidate of the inspection target area, the image area having a correlation value less than that is the second candidate or less, and the correlation value of the second candidate or less is the correlation value of the first candidate. It is possible to visually express how far or close they are.

第4の発明は、前記所定値の調整が可能に構成されているものとすることができる。 The fourth invention can be configured so that the predetermined value can be adjusted.

この構成によれば、例えば所定値を下げた時に、最高相関画像領域以外の画像領域が表示されなければ、検査対象領域となる画像領域の検出精度が高く、安定して検出できていると判定することができる。 According to this configuration, for example, if an image area other than the highest correlation image area is not displayed when the predetermined value is lowered, it is determined that the detection accuracy of the image area to be inspected is high and stable detection is possible. can do.

第5の発明は、前記サーチ処理選択部は、前記表示制御部により表示された前記第1画像または前記第2画像が選択されたか否かを検出し、前記第1画像が選択されたことを検出した場合には前記第1のサーチ処理を選択し、前記第2画像が選択されたことを検出した場合には前記第2のサーチ処理を選択するように構成されているものとすることができる。 In the fifth aspect of the invention, the search processing selection unit detects whether or not the first image or the second image displayed by the display control unit is selected, and the first image is selected. If it is detected, the first search process is selected, and if it is detected that the second image is selected, the second search process may be selected. can.

この構成によれば、使用者が表示制御部により表示された第1画像を選択すると、第1のサーチ処理が自動的に選択され、使用者が表示制御部に表示された第2画像を選択すると、第2のサーチ処理が自動的に選択される。これにより、使用者の直感的な操作によってサーチ処理を選択することができる。 According to this configuration, when the user selects the first image displayed by the display control unit, the first search process is automatically selected, and the user selects the second image displayed on the display control unit. Then, the second search process is automatically selected. As a result, the search process can be selected by the user's intuitive operation.

尚、第1画像の選択とは、第1画像そのものの選択操作であってもよいし、第1画像を囲む枠を選択する操作や、各種ボタン等による選択操作であってもよい。第2画像の選択も同様である。 The selection of the first image may be an operation of selecting the first image itself, an operation of selecting a frame surrounding the first image, or a selection operation using various buttons or the like. The same applies to the selection of the second image.

第6の発明は、前記サーチ処理部は、前記第1のサーチ処理の処理時間と、前記第2のサーチ処理の処理時間とを取得し、前記表示制御部は、前記サーチ処理部が取得した前記第1のサーチ処理の処理時間と、前記第2のサーチ処理の処理時間とを表示するように構成されているものとすることができる。 In the sixth aspect of the invention, the search processing unit acquires the processing time of the first search processing and the processing time of the second search processing, and the display control unit is acquired by the search processing unit. It may be configured to display the processing time of the first search processing and the processing time of the second search processing.

すなわち、第1のサーチ処理と第2のサーチ処理とでは、用いる特徴量が異なっているので、処理を開始して完了するまでの時間(処理時間)に差が生じることがある。この発明では、第1のサーチ処理の処理時間と、第2のサーチ処理の処理時間とを表示することができるので、使用者が各処理時間を把握することができ、サーチ処理を選択するための材料として利用することができる。 That is, since the feature amount used is different between the first search process and the second search process, there may be a difference in the time (processing time) from the start to the completion of the process. In the present invention, since the processing time of the first search processing and the processing time of the second search processing can be displayed, the user can grasp each processing time and select the search processing. It can be used as a material for.

第7の発明は、前記サーチ処理部は、複数の前記入力画像を連続的に取得して前記各入力画像に対して前記第1のサーチ処理と前記第2のサーチ処理とを実行し、前記表示制御部は、前記第1画像及び前記第2画像を更新するように構成されているものとすることができる。 In a seventh aspect of the invention, the search processing unit continuously acquires a plurality of the input images and executes the first search process and the second search process on each of the input images. The display control unit may be configured to update the first image and the second image.

この構成によれば、第1のサーチ処理と第2のサーチ処理を複数の異なる入力画像に対してそれぞれ実行した結果を使用者に見せることができる。これにより、第1のサーチ処理と第2のサーチ処理の安定性を容易に比較することができる。 According to this configuration, it is possible to show the user the result of executing the first search process and the second search process on a plurality of different input images. This makes it possible to easily compare the stability of the first search process and the second search process.

第8の発明は、前記第1のサーチ処理及び前記第2のサーチ処理の共通設定項目を入力する項目入力部を備え、前記サーチ処理部は、前記項目入力部で入力された共通設定項目を前記第1のサーチ処理及び前記第2のサーチ処理に適用するように構成されているものとすることができる。 The eighth invention includes an item input unit for inputting common setting items for the first search process and the second search process, and the search processing unit inputs common setting items input in the item input unit. It may be configured to be applied to the first search process and the second search process.

この構成によれば、第1のサーチ処理及び第2のサーチ処理の設定項目として、両サーチ処理に共通した項目がある場合には、項目入力部で共通設定項目として入力することで、両サーチ処理に自動的に適用される。よって、設定項目の入力操作を簡素化することができる。 According to this configuration, if there is an item common to both search processes as a setting item of the first search process and the second search process, both searches can be input by inputting as a common setting item in the item input unit. It is automatically applied to the process. Therefore, the input operation of the setting item can be simplified.

第9の発明は、前記共通設定項目は、サーチ処理を行う角度範囲とする。 In the ninth invention, the common setting item is an angle range in which the search process is performed.

第10の発明は、前記サーチ処理部は、前記入力画像に適用される画像処理に係るパラメータを変更して、前記検査設定記憶部に記憶されたサーチ処理を繰り返し実行して複数の検出結果を取得するように構成され、前記表示制御部は、前記サーチ処理部で取得された複数の検出結果を同時又は切り替えて表示可能に構成されているものとすることができる。 According to a tenth aspect of the present invention, the search processing unit changes parameters related to image processing applied to the input image, repeatedly executes the search processing stored in the inspection setting storage unit, and obtains a plurality of detection results. It is configured to be acquired, and the display control unit may be configured to be able to display a plurality of detection results acquired by the search processing unit at the same time or by switching.

すなわち、適切なサーチ処理が選択された場合であっても、入力画像に適用される画像処理のパラメータによってサーチ処理の結果が安定したり、不安定になったりすることがある。この発明では、入力画像に適用される画像処理に係るパラメータを変更してサーチ処理を繰り返し実行し、複数の検出結果を取得した後、表示することができるので、運用時に適した画像処理のパラメータを設定することができる。 That is, even when an appropriate search process is selected, the result of the search process may be stable or unstable depending on the image processing parameters applied to the input image. In the present invention, the parameters related to the image processing applied to the input image can be changed, the search process can be repeatedly executed, and a plurality of detection results can be acquired and then displayed, so that the parameters of the image processing suitable for operation can be displayed. Can be set.

第11の発明は、前記パラメータには、フィルタ処理の有無、フィルタ処理の種別、フィルタ処理の強度のうち、いずれか1つが含まれているものとすることができる。 According to the eleventh invention, the parameter may include any one of the presence / absence of filtering, the type of filtering, and the strength of filtering.

すなわち、入力画像に施すフィルタ処理の有無、フィルタ処理の種別、フィルタ処理の強度は、いずれもサーチ処理の結果への影響が大きいものであり、これらのうち、1つまたは複数を変更してサーチ処理を繰り返し実行することで、サーチ処理の結果が安定するパラメータを見つけ出すことができる。 That is, the presence / absence of filter processing applied to the input image, the type of filter processing, and the strength of the filter processing all have a large effect on the result of the search processing, and one or more of these are changed for the search. By repeatedly executing the process, it is possible to find a parameter that stabilizes the result of the search process.

第12の発明は、前記パラメータには、画像縮小度が含まれているものとすることができる。 In the twelfth invention, the parameter may include the degree of image reduction.

本発明によれば、サーチ処理に用いるパターン領域内の画像から抽出された第1の特徴量を用いた第1のサーチ処理の結果得られた第1画像と、第2の特徴量を用いた第2のサーチ処理の結果得られた第2画像を表示させることができるので、複数のサーチアルゴリズムについての特性や検査対象物との相性を知らない使用者であっても、適切なサーチアルゴリズムを簡単に決定することができる。 According to the present invention, the first image obtained as a result of the first search process using the first feature amount extracted from the image in the pattern region used for the search process and the second feature amount are used. Since the second image obtained as a result of the second search process can be displayed, even a user who does not know the characteristics of a plurality of search algorithms or the compatibility with the inspection target can use an appropriate search algorithm. It can be easily decided.

本発明の実施形態に係る画像検査装置の運用時を示す概略図である。It is a schematic diagram which shows the operation time of the image inspection apparatus which concerns on embodiment of this invention. 画像検査装置のブロック図である。It is a block diagram of an image inspection apparatus. 傷検査ツールのパラメータの例を示す図である。It is a figure which shows the example of the parameter of a wound inspection tool. 前処理フィルタの例を示す図である。It is a figure which shows the example of the preprocessing filter. リアルタイム濃淡補正のパラメータの例を示す図である。It is a figure which shows the example of the parameter of real-time shading correction. パターン領域設定、サーチ領域設定を行った画面の例を示す図である。It is a figure which shows the example of the screen which performed the pattern area setting and the search area setting. 検査領域設定、欠陥サイズ設定を行った画面の例を示す図である。It is a figure which shows the example of the screen which performed the inspection area setting and the defect size setting. 欠陥検査処理用の項目入力部の例を示す図である。It is a figure which shows the example of the item input part for defect inspection processing. サーチ処理用の項目入力部の例を示す図である。It is a figure which shows the example of the item input part for a search process. サーチ処理結果画像の表示例を示す図である。It is a figure which shows the display example of the search processing result image. 検出レベルを下げた場合の図10相当図である。It is a figure corresponding to FIG. 10 when the detection level is lowered. パラメータ変更後のサーチ処理結果画像を複数表示した例を示す図である。It is a figure which shows the example which displayed a plurality of search processing result images after parameter change. 図12に示す画像の中から1つを選択表示した例を示す図である。It is a figure which shows the example which selected and displayed one from the image shown in FIG. 欠陥検査処理画像の表示例を示す図である。It is a figure which shows the display example of the defect inspection processing image. 検出レベルを下げた場合の図14相当図である。It is a figure corresponding to FIG. 14 when the detection level is lowered. パラメータ変更後の欠陥検査結果画像を複数表示した例を示す図である。It is a figure which shows the example which displayed a plurality of defect inspection result images after parameter change. 図16に示す画像の中から1つを選択表示した例を示す図である。It is a figure which shows the example which selected and displayed one from the image shown in FIG. 前処理フィルタの種別の表示例を示す図である。It is a figure which shows the display example of the type of a preprocessing filter. サーチ処理の選択手順を示すフローチャートである。It is a flowchart which shows the selection procedure of a search process. 選択用インターフェース上でサーチ処理が選択された場合を示す図である。It is a figure which shows the case where the search process is selected on the selection interface. 欠陥検査処理の選択手順を示すフローチャートである。It is a flowchart which shows the selection procedure of a defect inspection process. 選択用インターフェース上で欠陥検査処理が選択された場合を示す図である。It is a figure which shows the case which the defect inspection process is selected on the selection interface.

以下、本発明の実施形態を図面に基づいて詳細に説明する。尚、以下の好ましい実施形態の説明は、本質的に例示に過ぎず、本発明、その適用物或いはその用途を制限することを意図するものではない。 Hereinafter, embodiments of the present invention will be described in detail with reference to the drawings. It should be noted that the following description of the preferred embodiment is essentially merely an example and is not intended to limit the present invention, its application or its use.

図1は、本発明の実施形態に係る画像検査装置1の運用時を示す概略図である。画像検査装置1は、ある方向に移動するワークW(検査対象物)を撮像した画像を用いてワークWの欠陥を検査するように構成されており、具体的には、ワークWに対して光を照射する照明部2と、撮像部3と、制御ユニット4と、モニタ5と、キーボード6及びマウス7とを少なくとも備えているが、これら以外の機器を備えることもできる。たとえば、制御ユニット4には、プログラマブル・ロジック・コントローラ(PLC)等からなる外部制御機器8が接続されている。この外部制御機器8は、画像検査装置1の一部を構成するものとしてもよい。また、外部制御機器8は、画像検査装置1の構成要素としなくてもよい。 FIG. 1 is a schematic view showing an operation time of the image inspection apparatus 1 according to the embodiment of the present invention. The image inspection device 1 is configured to inspect a defect of the work W by using an image of a work W (object to be inspected) moving in a certain direction, and specifically, light with respect to the work W. A lighting unit 2, an image pickup unit 3, a control unit 4, a monitor 5, a keyboard 6 and a mouse 7 are provided at least, but devices other than these can also be provided. For example, an external control device 8 including a programmable logic controller (PLC) or the like is connected to the control unit 4. The external control device 8 may form a part of the image inspection device 1. Further, the external control device 8 does not have to be a component of the image inspection device 1.

図1では、工場等において、複数のワークWが搬送用ベルトコンベアBの上面に載置された状態で図1における白抜き矢印で示す方向へ搬送されている場合を示している。ワークWは検査対象物である。外部制御機器8は、搬送用ベルトコンベアB及び画像検査装置1をシーケンス制御するための機器であり、汎用のPLCを利用することができる。 FIG. 1 shows a case where a plurality of work W are conveyed in the direction indicated by the white arrow in FIG. 1 in a state of being placed on the upper surface of the conveying belt conveyor B in a factory or the like. The work W is an object to be inspected. The external control device 8 is a device for sequence control of the transport belt conveyor B and the image inspection device 1, and a general-purpose PLC can be used.

尚、この実施形態の説明では、搬送用ベルトコンベアBによるワークWの搬送方向(ワークWの移動方向)をY方向とし、搬送用ベルトコンベアBの平面視でY方向に直交する方向をX方向とし、X方向及びY方向に直交する方向(搬送用ベルトコンベアBの上面に直交する方向)をZ方向と定義するが、これは説明の便宜を図るために定義するだけである。 In the description of this embodiment, the transport direction of the work W by the transport belt conveyor B (moving direction of the work W) is the Y direction, and the direction orthogonal to the Y direction in the plan view of the transport belt conveyor B is the X direction. The direction orthogonal to the X direction and the Y direction (the direction orthogonal to the upper surface of the conveyor belt B for transportation) is defined as the Z direction, but this is defined only for convenience of explanation.

画像検査装置1は、ワークWの外観検査、即ちワークWの表面の傷、汚れ、打痕等の欠陥の有無を検査する場合に使用することができるものであり、外観検査装置と呼ぶこともできる。画像検査装置1は、その運用時において、外部制御機器8から信号線を介して、欠陥検査の開始タイミングを規定する検査開始トリガ信号を受信する。画像検査装置1は、この検査開始トリガ信号に基づいてワークWの撮像及び照明等を行って所定の処理後、検査用画像を得る。その後、検査結果は、信号線を介して外部制御機器8へ送信される。このように、画像検査装置1の運用時には、画像検査装置1と外部制御機器8との間で、信号線を介して検査開始トリガ信号の入力と検査結果の出力が繰り返し行われる。なお、検査開始トリガ信号の入力や検査結果の出力は、上述したように、画像検査装置1と外部制御機器8との間の信号線を介して行ってもよいし、それ以外の図示しない信号線を介して行ってもよい。例えば、ワークWの到着を検知するためのセンサと画像検査装置1とを直接的に接続し、そのセンサから画像検査装置1へ検査開始トリガ信号を入力するようにしてもよい。 The image inspection device 1 can be used for visual inspection of the work W, that is, for inspecting the presence or absence of defects such as scratches, stains, and dents on the surface of the work W, and is also called a visual inspection device. can. During its operation, the image inspection device 1 receives an inspection start trigger signal that defines the start timing of defect inspection from the external control device 8 via a signal line. The image inspection device 1 performs imaging, lighting, and the like of the work W based on the inspection start trigger signal, and obtains an inspection image after a predetermined process. After that, the inspection result is transmitted to the external control device 8 via the signal line. As described above, during the operation of the image inspection device 1, the inspection start trigger signal is repeatedly input and the inspection result is output between the image inspection device 1 and the external control device 8 via the signal line. As described above, the input of the inspection start trigger signal and the output of the inspection result may be performed via the signal line between the image inspection device 1 and the external control device 8, or other signals (not shown). It may be done via a line. For example, a sensor for detecting the arrival of the work W and the image inspection device 1 may be directly connected, and an inspection start trigger signal may be input from the sensor to the image inspection device 1.

また、画像検査装置1は、専用のハードウェアで構成する他、汎用の機器にソフトウェアをインストールしたもの、たとえば汎用もしくは専用のコンピュータに画像検査プログラムをインストールした構成としてもよい。以下の例では、グラフィックボードなどのハードウェアを画像検査処理に特化させた専用のコンピュータに、画像検査プログラムをインストールした構成とした場合について説明する。 In addition to being configured with dedicated hardware, the image inspection device 1 may be configured by installing software on a general-purpose device, for example, installing an image inspection program on a general-purpose or dedicated computer. In the following example, a case where the image inspection program is installed on a dedicated computer in which hardware such as a graphic board is specialized for image inspection processing will be described.

また、画像検査装置1は、いわゆるデフレクトメトリの原理を応用した画像検査装置であっても良い。その場合、照明部2によって照度が周期的に変化するパターン光を検査対象物に照射し、パターン光が照射されている検査対象物を撮像部3によって撮像する。照明部2は照度分布の位相をシフトさせた複数のパターン光を順次照射し、パターン光を照射する都度、撮像部3が検査対象物を撮像し、得られた複数の輝度画像に基づいて検査対象物の形状を示す位相データを生成する。位相データに基づいて検査用画像を生成し、この検査用画像を用いることにより、検査対象物の形状に係る欠陥検査を行うことができるようになっている。デフレクトメトリの原理を応用した画像検査の方法は、従来から周知の方法であってもよいので、詳細な説明は省略する。尚、検査用画像の生成については、デフレクトメトリの原理の応用に限られるものではなく、他の手法によって検査用画像を生成するようにしてもよい。 Further, the image inspection device 1 may be an image inspection device to which the principle of so-called deflectometry is applied. In that case, the inspection object is irradiated with the pattern light whose illuminance is periodically changed by the illumination unit 2, and the inspection object irradiated with the pattern light is imaged by the image pickup unit 3. The illumination unit 2 sequentially irradiates a plurality of pattern lights whose phases of the illuminance distribution are shifted, and each time the pattern light is irradiated, the image pickup unit 3 images an inspection object and inspects based on the obtained plurality of luminance images. Generates phase data showing the shape of the object. By generating an inspection image based on the phase data and using this inspection image, it is possible to perform a defect inspection related to the shape of the inspection object. The image inspection method to which the principle of deflationmetry is applied may be a conventionally known method, and therefore detailed description thereof will be omitted. The generation of the inspection image is not limited to the application of the principle of deflation metrics, and the inspection image may be generated by another method.

画像検査装置1は、搬送用ベルトコンベアBによって次々と搬送されてくるワークWの外観検査を行うモード、すなわち実際にワークWの良否判定を行う運転モード(Runモード)と、検査に用いるサーチ処理アルゴリズム、欠陥検査アルゴリズム、各種パラメータ、前処理等の選択や設定を行う設定モード(非Runモード)とに切替可能に構成されている。運転モードと設定モードとの切替は、例えばモニタ5に表示されたユーザーインターフェース上のモード切替手段によって行うことができる。使用者は、運転モードにおいて搬送用ベルトコンベアBによって次々と搬送されてくるワークWの外観検査を行う前に、設定モードにおいて各種設定や選択を行うとともに調整を行う。設定モードでは、モニタ5に表示されたユーザーインターフェース上で各種設定や選択等を行うことが可能になっている。 The image inspection device 1 has a mode for visually inspecting the work W conveyed one after another by the transport belt conveyor B, that is, an operation mode (Run mode) for actually determining the quality of the work W, and a search process used for the inspection. It is configured to be switchable to a setting mode (non-Run mode) for selecting and setting algorithms, defect inspection algorithms, various parameters, preprocessing, and the like. Switching between the operation mode and the setting mode can be performed, for example, by the mode switching means on the user interface displayed on the monitor 5. The user makes various settings and selections in the setting mode and makes adjustments before performing an appearance inspection of the work W conveyed one after another by the conveyor belt conveyor B in the operation mode. In the setting mode, various settings and selections can be made on the user interface displayed on the monitor 5.

基本的に、各種パラメータに対してはデフォルト値が設定されており、使用者がパラメータ値としてデフォルト値が最適であると判断した場合には、特段、パラメータ値を調整する必要はない。しかし、実際のところ、周囲の照明環境、撮像部3の取り付け位置、撮像部3の姿勢ずれ、ピント調整等の相違に起因して、デフォルト値のままでは使用者が望む結果を得ることができない場合がある。そこで、設定モードにおいて、モニタ5上にて、運転モードから設定モードに切り換え、各種パラメータの内容を編集できるようになっている。 Basically, default values are set for various parameters, and if the user determines that the default values are optimal as parameter values, there is no particular need to adjust the parameter values. However, in reality, due to differences in the surrounding lighting environment, the mounting position of the imaging unit 3, the posture deviation of the imaging unit 3, the focus adjustment, etc., the default values cannot be used to obtain the desired result. In some cases. Therefore, in the setting mode, the operation mode can be switched to the setting mode on the monitor 5 and the contents of various parameters can be edited.

運転モードでは、搬送用ベルトコンベアBのライン上を流れてくる複数のワークWを撮像部3によって撮像し、ワークWに傷や欠陥等が存在するか否かの判断を行う。ワークWに傷や欠陥等が存在すると判断した場合には、NG判定となる。一方、ワークWに傷や欠陥等が存在しないと判断した場合には、OK判定となる。このように、画像検査装置1は、ワークWを撮像した画像を用いて、ワークWの外観の良否判定を行う。 In the operation mode, a plurality of work W flowing on the line of the transport belt conveyor B are imaged by the image pickup unit 3, and it is determined whether or not the work W has scratches, defects, or the like. If it is determined that the work W has scratches, defects, etc., the determination is NG. On the other hand, if it is determined that the work W has no scratches or defects, the determination is OK. In this way, the image inspection device 1 determines the quality of the appearance of the work W by using the image obtained by capturing the image of the work W.

(照明部2の構成)
照明部2は、ワークWを照明する照明装置で構成されており、例えば、面照明、光沢を際立たせる同軸落射照明、傷や刻印のエッジが際立つローアングル照明、ブラックライトを当てるブラックライト照明、四方八方から拡散光を照射するドーム照明等、各種の照明を行う照明装置を使用することができる。照明部2は、制御ユニット4に対して信号線100aを介して接続されており、撮像部3及び制御ユニット4から離して設置することができるようになっている。
(Structure of lighting unit 2)
The lighting unit 2 is composed of a lighting device that illuminates the work W, for example, surface lighting, coaxial epi-illumination that emphasizes gloss, low-angle lighting that emphasizes scratches and engraved edges, and black light illumination that illuminates black light. Lighting devices that perform various types of lighting, such as dome lighting that irradiates diffused light from all directions, can be used. The illumination unit 2 is connected to the control unit 4 via a signal line 100a, and can be installed away from the image pickup unit 3 and the control unit 4.

また、デフレクトメトリ処理を行う場合、照明部2は、周期的な照度分布を有するパターン光をワークWに照射するパターン光照明装置であってもよい。パターン光照明装置は、たとえば複数の発光ダイオード、液晶パネル、有機ELパネル、デジタルマイクロミラーデバイス(DMD)等で構成することができ、単に照明部と呼ぶこともできる。液晶パネル、有機ELパネル、DMDについては図示しないが、従来から周知の構造のものを用いることができる。 Further, when performing the deflect metering process, the illumination unit 2 may be a pattern light illumination device that irradiates the work W with pattern light having a periodic illuminance distribution. The pattern light illuminating device can be composed of, for example, a plurality of light emitting diodes, a liquid crystal panel, an organic EL panel, a digital micromirror device (DMD), or the like, and may be simply called a lighting unit. Although the liquid crystal panel, the organic EL panel, and the DMD are not shown, those having a conventionally known structure can be used.

パターン光照明装置からなる照明部2に複数の発光ダイオードを用いる場合には、複数の発光ダイオードをドットマトリクス状に配置して電流値制御によって周期的な照度分布を有するパターン光を生成することができる。液晶パネル及び有機ELパネルの場合は、各パネルを制御することで各パネルから照射される光が周期的な照度分布を有するパターン光となるようにすることができる。デジタルマイクロミラーデバイスの場合は、内蔵された微小鏡面を制御することで周期的な照度分布を有するパターン光を生成して照射することができる。尚、照明部2の構成は上述したものに限られるものではなく、周期的な照度分布を有するパターン光を生成することができる機器や装置等も使用することができる。 When a plurality of light emitting diodes are used in the lighting unit 2 composed of the pattern light illuminating device, the plurality of light emitting diodes may be arranged in a dot matrix to generate patterned light having a periodic illuminance distribution by controlling the current value. can. In the case of a liquid crystal panel and an organic EL panel, by controlling each panel, the light emitted from each panel can be made into a pattern light having a periodic illuminance distribution. In the case of a digital micromirror device, it is possible to generate and irradiate a pattern light having a periodic illuminance distribution by controlling the built-in micromirror surface. The configuration of the illumination unit 2 is not limited to that described above, and equipment or devices capable of generating patterned light having a periodic illuminance distribution can also be used.

照明部2には、図2に示す制御ユニット4の照明制御部42から送信される照明トリガ信号が信号線100aを介して入力されるようになっている。照明部2は、照明トリガ信号を受信したら、その都度、ワークWを照明するように構成されている。 A lighting trigger signal transmitted from the lighting control unit 42 of the control unit 4 shown in FIG. 2 is input to the lighting unit 2 via the signal line 100a. The lighting unit 2 is configured to illuminate the work W each time it receives a lighting trigger signal.

照明部2の照度分布が面内で均一な光を照射することもでき、例えば、暗い面発光状態から明るい面発光状態まで発光状態を変化させることもできる。また、デフレクトメトリ処理を行う場合、ワークWに照射するパターン光はsin波形だけでなく、三角波等のパターン光でも可能である。 The illuminance distribution of the illumination unit 2 can irradiate light with a uniform in-plane, and for example, the light emission state can be changed from a dark surface emission state to a bright surface emission state. Further, when the deflect metering process is performed, the pattern light irradiating the work W can be not only a sine waveform but also a pattern light such as a triangular wave.

(撮像部3の構成)
図1に示す撮像部3は、受光素子と集光系光学系とを有している。受光素子は、集光系光学系を通して得られた光の強度を電気信号に変換するCCD(charge-coupled device)やCMOS(complementary metal oxide semiconductor)等の撮像素子からなるイメージセンサである。集光系光学系は、外部から入射する光を集光するための光学系であり、典型的には一以上の光学レンズを有している。集光系光学系には、従来から周知のオートフォーカス機構を設けることができる。
(Structure of Imaging Unit 3)
The image pickup unit 3 shown in FIG. 1 has a light receiving element and a condensing optical system. The light receiving element is an image sensor composed of an image pickup element such as a CCD (charge-coupled device) or a CMOS (complementary metal oxide semiconductor) that converts the intensity of light obtained through a condensing optical system into an electric signal. The condensing system optical system is an optical system for condensing light incident from the outside, and typically has one or more optical lenses. A conventionally well-known autofocus mechanism can be provided in the condensing optical system.

撮像部3は、図2に示す制御ユニット4に対して信号線100bを介して接続されている。尚、この実施形態では、撮像部3と照明部2とが別体である場合について説明するが、撮像部3と照明部2とは一体化されていてもよい。 The image pickup unit 3 is connected to the control unit 4 shown in FIG. 2 via a signal line 100b. In this embodiment, the case where the image pickup unit 3 and the illumination unit 2 are separate bodies will be described, but the image pickup unit 3 and the illumination unit 2 may be integrated.

撮像部3には、制御ユニット4の画像入力部41から送信される撮像トリガ信号が信号線100bを介して入力されるようになっている。撮像部3は、画像データを取り込むタイミングを規定する撮像トリガ信号を受信したら、その都度、ワークWの撮像を実行するように構成されている。 The image pickup trigger signal transmitted from the image input unit 41 of the control unit 4 is input to the image pickup unit 3 via the signal line 100b. The imaging unit 3 is configured to perform imaging of the work W each time it receives an imaging trigger signal that defines the timing for capturing image data.

(モニタ5の構成)
図1に示すモニタ5は、たとえば有機ELディスプレイや液晶ディスプレイ等からなるものであり、表示部と呼ぶこともできる。モニタ5は、図2に示す制御ユニット4の表示制御部43に接続され、たとえば、撮像部3で撮像された画像、撮像部3で撮像した画像に基づいて生成された各種画像、各種設定用画像、ワークWの欠陥検査結果、操作用のインターフェース、各種設定用のインターフェース、設定値等を表示させることができるように構成されている。モニタ5には、一度に複数の設定用画像や、検査用画像等を表示させることもできるようになっている。モニタ5をタッチ操作パネル型モニタとすることで、モニタ5に各種情報の入力機能を持たせることができる。
(Configuration of monitor 5)
The monitor 5 shown in FIG. 1 is made of, for example, an organic EL display, a liquid crystal display, or the like, and can also be called a display unit. The monitor 5 is connected to the display control unit 43 of the control unit 4 shown in FIG. 2, for example, an image captured by the image pickup unit 3, various images generated based on the image captured by the image pickup unit 3, and various settings. It is configured to be able to display an image, a defect inspection result of the work W, an interface for operation, an interface for various settings, setting values, and the like. The monitor 5 can also display a plurality of setting images, inspection images, and the like at one time. By using the monitor 5 as a touch operation panel type monitor, the monitor 5 can be provided with various information input functions.

使用者は、設定モード中にモニタ5を視認することで各種設定を行うことができ、また、運転モード中にモニタ5を視認することで動作状態を確認することができる。 The user can make various settings by visually recognizing the monitor 5 in the setting mode, and can confirm the operating state by visually recognizing the monitor 5 in the operation mode.

(キーボード6及びマウス7の構成)
図1に示すキーボード6及びマウス7は、従来から周知のコンピュータ操作用の機器であり、制御ユニット4が有する操作入力部44(図2に示す)に接続されている。キーボード6またはマウス7の操作により、各種情報を制御ユニット4に入力することができるとともに、モニタ5に表示されている画像等の選択やボタン操作等を行うことができる。尚、マウス7はポインティングデバイスの一例であり、他のポインティングデバイスを用いることもできる。また、キーボード6及びマウス7の代わり、またはキーボード6及びマウス7に加えて、たとえば、音声入力機器、タッチ操作パネル等のコンピュータ操作用の機器を使用することもできる。
(Structure of keyboard 6 and mouse 7)
The keyboard 6 and the mouse 7 shown in FIG. 1 are conventionally known computer operation devices, and are connected to an operation input unit 44 (shown in FIG. 2) of the control unit 4. By operating the keyboard 6 or the mouse 7, various information can be input to the control unit 4, and images and the like displayed on the monitor 5 can be selected and buttons can be operated. The mouse 7 is an example of a pointing device, and other pointing devices can also be used. Further, instead of the keyboard 6 and the mouse 7, or in addition to the keyboard 6 and the mouse 7, a computer operation device such as a voice input device and a touch operation panel can be used.

(制御ユニット4の構成)
制御ユニット4は、画像検査装置1の各部を制御するためのユニットであり、CPUやMPU、システムLSI、DSPや専用ハードウェア等で構成することができる。制御ユニット4は、後述するように様々な機能を搭載しているが、これらは論理回路によって実現されていてもよいし、ソフトウェアを実行することによって実現されていてもよい。制御ユニット4の一部又は全部がモニタ5に組み込まれていてもよいし、制御ユニット4の一部が照明部2や撮像部3に組み込まれていてもよい。
(Configuration of control unit 4)
The control unit 4 is a unit for controlling each part of the image inspection device 1, and can be configured by a CPU, an MPU, a system LSI, a DSP, dedicated hardware, or the like. The control unit 4 is equipped with various functions as described later, and these may be realized by a logic circuit or may be realized by executing software. A part or all of the control unit 4 may be incorporated in the monitor 5, or a part of the control unit 4 may be incorporated in the illumination unit 2 or the image pickup unit 3.

図2に一例を示すように、制御ユニット4は、画像入力部41と、照明制御部42と、表示制御部43と、操作入力部44と、主制御部45と、記憶部46と、設定部47と、欠陥検査用特徴量抽出部48と、項目入力部49と、画像処理部50と、選択部51とを有している。制御ユニット4の各部は、上述したように分けて記載しているが、同じ部分が複数種の処理を実行するように構成してもよいし、更に細かく分けてこれらを連携させて1つの処理を実行するように構成してもよい。 As an example shown in FIG. 2, the control unit 4 includes an image input unit 41, a lighting control unit 42, a display control unit 43, an operation input unit 44, a main control unit 45, and a storage unit 46. It has a unit 47, a feature amount extraction unit 48 for defect inspection, an item input unit 49, an image processing unit 50, and a selection unit 51. Although each part of the control unit 4 is described separately as described above, the same part may be configured to execute a plurality of types of processing, or may be further subdivided and linked to each other for one processing. May be configured to run.

上記各ハードウェアは、バスなどの電気的な通信路(配線)を介し、双方向通信可能または一方向通信可能に接続されている。 Each of the above hardware is connected so as to be capable of two-way communication or one-way communication via an electrical communication path (wiring) such as a bus.

図1に示す外部制御機器8は、図示しない通信部を介して制御ユニット4に対して通信可能に接続されている。通信部は、ワークWの到着タイミングを認識するために製造ラインに設置され、外部制御機器8に接続されたセンサ(光電センサ等、図示せず)からトリガ入力があったときに、外部制御機器8から撮像トリガ信号を受信するインターフェース(I/F)として機能する。また、通信部は、外部から転送されてくる制御プログラムなどを受信するインターフェース(I/F)としても機能する。 The external control device 8 shown in FIG. 1 is communicably connected to the control unit 4 via a communication unit (not shown). The communication unit is installed on the production line to recognize the arrival timing of the work W, and when a trigger input is received from a sensor (photoelectric sensor, etc., not shown) connected to the external control device 8, the external control device It functions as an interface (I / F) for receiving an image pickup trigger signal from 8. The communication unit also functions as an interface (I / F) for receiving a control program or the like transferred from the outside.

図2に示す主制御部45は、各種プログラムに基づき数値計算や情報処理を行うとともに、ハードウェア各部の制御を行う。主制御部45は、中央演算処理装置として機能するCPU45aと、主制御部45が各種プログラムを実行する際のワークエリアとして機能するRAM等のワークメモリ45bと、起動プログラムや初期化プログラム等が格納されたROM、フラッシュROMまたはEEPROM等のプログラムメモリ45cとを備えている。 The main control unit 45 shown in FIG. 2 performs numerical calculation and information processing based on various programs, and also controls each part of the hardware. The main control unit 45 stores a CPU 45a that functions as a central arithmetic processing unit, a work memory 45b such as a RAM that functions as a work area when the main control unit 45 executes various programs, a start-up program, an initialization program, and the like. It is provided with a program memory 45c such as a ROM, a flash ROM, or an EEPROM.

照明制御部42は、主制御部45のCPU45や外部制御機器8からの命令に基づいて、照明部2に対して照明トリガ信号を送信する。照明トリガ信号には、照度やパターン光に関する情報が含まれていてもよい。 The lighting control unit 42 transmits a lighting trigger signal to the lighting unit 2 based on a command from the CPU 45 of the main control unit 45 or the external control device 8. The illumination trigger signal may include information about illuminance and pattern light.

画像入力部41は、撮像部3での撮像により得られた画像データを取り込むASIC(Application Specific Integrated Circuit)などから構成することができる。画像入力部41には、画像データをバッファリングするためのフレームバッファが含まれていてもよい。具体的に、画像入力部41は、CPU45aから撮像部3の撮像指令を受信すると、撮像部3に対して画像データ取り込み信号(撮像トリガ信号)を送信する。そして、画像入力部41は、撮像部3で撮像が行われた後、撮像により得られた画像データを取り込む。取り込んだ画像データは、一旦バッファリング(キャッシュ)される。デフレクトメトリの原理に基づく画像処理は、図示しない処理部において行うことができる。 The image input unit 41 can be configured from an ASIC (Application Specific Integrated Circuit) or the like that captures image data obtained by image pickup by the image pickup unit 3. The image input unit 41 may include a frame buffer for buffering image data. Specifically, when the image input unit 41 receives the image pickup command of the image pickup unit 3 from the CPU 45a, the image input unit 41 transmits an image data acquisition signal (image capture trigger signal) to the image pickup unit 3. Then, the image input unit 41 captures the image data obtained by the image pickup after the image pickup is performed by the image pickup unit 3. The captured image data is once buffered (cached). Image processing based on the principle of deflectometry can be performed in a processing unit (not shown).

操作入力部44には、キーボード6やマウス7、その他の操作用デバイスからの操作信号が入力される。操作入力部44は、使用者の操作に基づきキーボード6やマウス7等からの操作信号を受信するインターフェース(I/F)として機能する部分である。 Operation signals from the keyboard 6, mouse 7, and other operation devices are input to the operation input unit 44. The operation input unit 44 is a part that functions as an interface (I / F) for receiving operation signals from the keyboard 6, the mouse 7, and the like based on the operation of the user.

表示制御部43は、モニタ5に対して画像を表示させる表示用DSPなどから構成される。表示制御部43には、画像を表示させる際に画像データを一時記憶するVRAMなどのビデオメモリが含まれていてもよい。CPU45aから送られてきた表示指令(表示コマンド)に基づいて、モニタ5に対して所定の画像を表示させるための制御信号を送信する。たとえば、撮像部3で撮像した画像データ(デフレクトメトリの原理に基づいて処理された画像)、画像処理後の画像データ、各種ユーザーインターフェース等を表示するために、モニタ5に対して制御信号を送信する。また、表示制御部43は、キーボード6やマウス7を用いた使用者の操作内容をモニタ5に表示させるための制御信号も送信する。また、マウス7で操作可能なポインタ等もモニタ5に表示することができるようになっている。 The display control unit 43 is composed of a display DSP or the like for displaying an image on the monitor 5. The display control unit 43 may include a video memory such as a VRAM that temporarily stores image data when displaying an image. Based on the display command (display command) sent from the CPU 45a, a control signal for displaying a predetermined image is transmitted to the monitor 5. For example, a control signal is sent to the monitor 5 in order to display image data captured by the image pickup unit 3 (image processed based on the principle of deflectometry), image data after image processing, various user interfaces, and the like. Send. The display control unit 43 also transmits a control signal for displaying the operation contents of the user using the keyboard 6 and the mouse 7 on the monitor 5. Further, a pointer or the like that can be operated by the mouse 7 can also be displayed on the monitor 5.

(検査ツール)
画像検査装置1は、外観検査を実行する計測モジュールを複数備えている。ここでは、外観検査を実行する計測モジュールを検査ツールと呼ぶことにする。検査ツールには様々なものがあり、主要な画像処理ツールとしては、エッジ位置計測ツール、エッジ角度計測ツール、エッジ幅計測ツール、エッジピッチ計測ツール、エリア計測ツール、ブロブ計測ツール、パターンサーチ計測ツール、傷計測ツールなどがある。詳細な説明は省略するが、各検査ツールは、従来から存在する各種画像処理の手法を用いて実現することができる。
(Inspection tool)
The image inspection device 1 includes a plurality of measurement modules for performing visual inspection. Here, the measurement module that executes the visual inspection is called an inspection tool. There are various inspection tools, and the main image processing tools are edge position measurement tool, edge angle measurement tool, edge width measurement tool, edge pitch measurement tool, area measurement tool, blob measurement tool, pattern search measurement tool. , Scratch measurement tools, etc. Although detailed description is omitted, each inspection tool can be realized by using various conventional image processing methods.

画像検査装置1が備える検査ツールは複数あり、例えば、一覧表の形式でモニタ5上に表示することができ、同時にモニタ5に表示されているポインタを使用者がマウス7等で操作し、使用したい検査ツールを選択することができるようになっている。 The image inspection device 1 has a plurality of inspection tools, for example, which can be displayed on the monitor 5 in the form of a list, and at the same time, the user operates the pointer displayed on the monitor 5 with the mouse 7 or the like to use the pointer. You can now select the inspection tool you want.

以下、各検査ツールの概要について説明するが、検査ツールの名称は説明の便宜を図るためだけに決めたものであり、どのような名称を用いてもよい。 The outline of each inspection tool will be described below, but the name of the inspection tool is determined only for the convenience of explanation, and any name may be used.

エッジ位置計測ツール:ワークWの画像が表示される画面上において、エッジ位置を検出したい検査領域に対してウインドウを設定することにより、設定された検査領域内で、任意の方向にスキャンして複数のエッジ(明から暗に切り替わる箇所または暗から明に切り替わる箇所)を検出する。検出した複数のエッジから、一のエッジの指定を受け付け、指定を受け付けたエッジの位置を計測する。 Edge position measurement tool: On the screen where the image of the work W is displayed, by setting a window for the inspection area where the edge position is to be detected, multiple scans can be performed in any direction within the set inspection area. Detects the edge of (the part that switches from light to dark or the part that switches from dark to light). From a plurality of detected edges, the designation of one edge is accepted, and the position of the edge that has received the designation is measured.

エッジ角度計測ツール:設定を受け付けた検査領域内に2つのセグメントを設定し、それぞれのセグメントで検出したエッジからのワークWの傾斜角度を計測する。傾斜角度は、たとえば時計回りを正とすることができる。 Edge angle measurement tool: Two segments are set in the inspection area where the setting is accepted, and the inclination angle of the work W from the edge detected in each segment is measured. The tilt angle can be positive, for example, clockwise.

エッジ幅計測ツール:設定を受け付けた検査領域内で、任意の方向にスキャンして複数のエッジを検出し、検出した複数のエッジ間の幅を計測する。 Edge width measurement tool: Within the inspection area where the setting is accepted, scan in any direction to detect multiple edges and measure the width between the detected multiple edges.

エッジピッチ計測ツール:設定を受け付けた検査領域内で、任意の方向にスキャンして複数のエッジを検出する。検出した複数のエッジ間の距離(角度)の最大値/最小値や平均値を計測する。 Edge pitch measurement tool: Scans in any direction to detect multiple edges within the inspection area where the settings have been accepted. Measure the maximum / minimum value and average value of the distances (angles) between multiple detected edges.

エリア計測ツール:撮像部3で撮像したワークWの画像を二値化処理して、白色領域または黒色領域の面積を計測する。たとえば、計測する対象として白色領域または黒色領域の指定をパラメータとして受け付けることにより、白色領域または黒色領域の面積を計測する。 Area measurement tool: The image of the work W captured by the image pickup unit 3 is binarized to measure the area of the white region or the black region. For example, the area of the white region or the black region is measured by accepting the designation of the white region or the black region as a parameter to be measured.

ブロブ計測ツール:撮像部3で撮像したワークWの画像を二値化処理して、同一の輝度値(255または0)の画素の集合(ブロブ)に対してパラメータとしての数、面積、重心位置等を計測する。ブロブ計測ツールは、検出される傷の大きさ(面積)が、実際の欠陥と同じ大きさで検出されるが、細かいノイズも検出されやすい傾向がある。また、検出状態に応じて処理時間が変動しやすい。 Blob measurement tool: The work W image captured by the imaging unit 3 is binarized, and the number, area, and center of gravity position as parameters for a set of pixels (blobs) with the same brightness value (255 or 0). Etc. are measured. The blob measurement tool detects the size (area) of the scratch as the same size as the actual defect, but tends to detect fine noise as well. In addition, the processing time tends to fluctuate depending on the detection state.

パターンサーチ計測ツール:比較対象とする画像パターン(モデル画像)を事前に記憶装置に記憶しておき、撮像したワーク8の画像の中から、事前に記憶してある画像パターンに類似している部分を検出することで、画像パターンの位置、傾斜角度、相関値を計測する。 Pattern search measurement tool: An image pattern (model image) to be compared is stored in a storage device in advance, and a portion of the captured image of the work 8 that is similar to the image pattern stored in advance. By detecting, the position, tilt angle, and correlation value of the image pattern are measured.

傷検査ツール:設定を受け付けた検査領域内で、小領域(セグメント)を移動させて画素値の平均濃度値を算出し、閾値以上の濃度差となった位置を傷が存在すると判定する。すなわち、傷検査とは、単純な二値化処理によって得られた白黒画像での面積判定ではなく、周辺の濃淡レベルと比較しながら傷や汚れなどの欠陥を探す外観検査アルゴリズムである。傷検査ツールは、傷検出処理を行うツールと呼ぶこともできる。 Scratch inspection tool: Within the inspection area where the setting is accepted, a small area (segment) is moved to calculate the average density value of the pixel values, and it is determined that a scratch exists at a position where the density difference is equal to or greater than the threshold value. That is, the scratch inspection is not an area determination in a black-and-white image obtained by a simple binarization process, but an visual inspection algorithm that searches for defects such as scratches and stains by comparing with the shading level of the surroundings. The scratch inspection tool can also be called a tool that performs a scratch detection process.

傷検査の検出原理を以下に説明する。ここでは、傷の検出方向としてX方向を指定した場合を例に取って説明する。
(1)まず、検査領域内で任意サイズの小領域(セグメント)を、所定量だけ移動させながら平均濃度計測を行う。移動させる量は、セグメントのサイズを基準に決定でき、例えばセグメントサイズの1/4とする。
(2)次に、注目セグメントを含む検出方向の所定の距離(ここではX方向に4セグメント)内での最大濃度と最小濃度の差を計測する。この値が、注目セグメントの「傷レベル」となる。
(3)傷レベルが、予め設定されたしきい値を超えている場合、その注目セグメントは傷としてカウントされる。このカウント値は「傷量」と呼ばれる検査結果となる。
以後、領域内で注目セグメントを移動量分ずらして上記(1)~(3)の工程を繰り返す。
The detection principle of scratch inspection will be described below. Here, a case where the X direction is specified as the scratch detection direction will be described as an example.
(1) First, the average concentration is measured while moving a small area (segment) of an arbitrary size within the inspection area by a predetermined amount. The amount to be moved can be determined based on the size of the segment, for example, 1/4 of the segment size.
(2) Next, the difference between the maximum concentration and the minimum concentration within a predetermined distance (here, 4 segments in the X direction) in the detection direction including the segment of interest is measured. This value is the "scratch level" of the segment of interest.
(3) When the scratch level exceeds a preset threshold value, the attention segment is counted as a scratch. This count value is a test result called "scratch amount".
After that, the attention segment is shifted by the amount of movement in the region, and the above steps (1) to (3) are repeated.

以上は、傷の検出方向としてX方向を指定した場合を説明した。傷の検出方向は、Y方向やXY方向で指定することもできる。ここで、傷の検出方向をXYの2次元方向に指定した場合の処理方法について説明する。XY方向を指定した場合は、注目セグメントを含むXY方向それぞれ4セグメント、計16セグメント内での最大濃度と最小濃度の差を計測する。傷検査ツールによれば、ワークWの形状や照明ムラなどの影響を受けず、検出すべき欠陥のみを検出できる。また、傷検査ツールは、セグメント化を行って処理するため、細かいノイズへの耐性が強いが、検出される傷の大きさ(面積)が、実際の欠陥よりも大き目に検出される傾向がある。 The above has described the case where the X direction is specified as the scratch detection direction. The scratch detection direction can also be specified in the Y direction or the XY direction. Here, a processing method when the scratch detection direction is specified in the two-dimensional direction of XY will be described. When the XY direction is specified, the difference between the maximum density and the minimum density within a total of 16 segments, 4 segments in each of the XY directions including the segment of interest, is measured. According to the scratch inspection tool, only defects to be detected can be detected without being affected by the shape of the work W and uneven lighting. In addition, since the scratch inspection tool processes by segmenting, it is highly resistant to fine noise, but the size (area) of the detected scratch tends to be larger than the actual defect. ..

その他にも、検査領域内の文字情報を切り出して辞書データ等と照合することで文字列を認識するOCR認識ツール、画像上に設定したウインドウ(領域)をシフトさせながら、各ウインドウの位置においてエッジの検出を繰り返す機能を有するトレンドエッジツール、設定したウインドウ内の濃淡の平均、偏差等を計測する機能を有する濃淡ツール、設定したウインドウ内の濃度の平均、偏差等を計測する機能を有する濃度ツールなどもあり、ユーザは検査内容に応じて必要な画像処理ツールを選択することができる。なお、これらの検査ツールは、典型的な機能およびその実現方法の代表例を示すものに過ぎない。あらゆる画像処理に対応する検査ツールを画像検査装置1が備えるように構成することもできる。また、各検査ツールは、それぞれ、個別の検査アルゴリズムに基づいて実現されるものであることから、検査アルゴリズムと呼ぶこともできる。 In addition, an OCR recognition tool that recognizes character strings by cutting out character information in the inspection area and collating it with dictionary data, etc., while shifting the window (area) set on the image, edge at the position of each window. Trend edge tool that has the function of repeating the detection of, the shade tool that has the function of measuring the average of the shades in the set window, the deviation, etc. The user can select the necessary image processing tool according to the inspection content. It should be noted that these inspection tools are merely representative examples of typical functions and methods for realizing them. The image inspection device 1 may be configured to include an inspection tool corresponding to all image processing. Further, since each inspection tool is realized based on an individual inspection algorithm, it can also be called an inspection algorithm.

(検査ツールのパラメータ)
図3は、傷検査ツールのパラメータの例を示している。図3に示す表示例は、使用者が傷検出ツールのパラメータを手動で設定するためのユーザーインターフェースであり、傷検査ツールパラメータ設定部61としてモニタ5上に表示することができる。傷検査ツールパラメータ設定部61の各値等は、キーボード6やマウス7等を操作することによって変更することができる。
(Parameter of inspection tool)
FIG. 3 shows an example of the parameters of the scratch inspection tool. The display example shown in FIG. 3 is a user interface for the user to manually set the parameters of the scratch detection tool, and can be displayed on the monitor 5 as the scratch inspection tool parameter setting unit 61. Each value of the scratch inspection tool parameter setting unit 61 and the like can be changed by operating the keyboard 6 and the mouse 7.

傷検査ツールのパラメータとしては、検出方向、方向別設定、高速モードのON/OFF、傷レベル、設定方向、セグメントサイズ、比較間隔設定、移動量、比較セグメント間隔、ゲイン等が挙げられる。図3に示す傷検査ツールパラメータ設定部61は、検出方向設定欄61a、方向別設定欄61b、高速モードのON/OFF設定欄61c、傷レベル設定欄61d、設定方向設定欄61e、セグメントサイズ設定欄61f、比較間隔設定欄61g、移動量設定欄61h、比較セグメント間隔設定欄61i、ゲイン設定欄61jを備えている。 The parameters of the scratch inspection tool include detection direction, setting for each direction, ON / OFF of high-speed mode, scratch level, setting direction, segment size, comparison interval setting, movement amount, comparison segment interval, gain, and the like. The scratch inspection tool parameter setting unit 61 shown in FIG. 3 has a detection direction setting field 61a, a direction-specific setting field 61b, a high-speed mode ON / OFF setting field 61c, a scratch level setting field 61d, a setting direction setting field 61e, and a segment size setting. A column 61f, a comparison interval setting column 61g, a movement amount setting column 61h, a comparison segment interval setting column 61i, and a gain setting column 61j are provided.

検出方向は、傷がどの方向に伸びているかを示すパラメータである。ここでは、ドロップダウンリストからXY、X、Yの何れかを選択する。例えば縦方向に傷が伸びている場合は、X方向を選択することで、横方向に差分を取って傷を検出できるようになる。 The detection direction is a parameter indicating in which direction the scratch is extended. Here, select any of XY, X, and Y from the drop-down list. For example, when the scratch is extended in the vertical direction, by selecting the X direction, the scratch can be detected by taking the difference in the horizontal direction.

方向別設定は、画像処理パラメータをX方向やY方向で異なる値に設定したい場合に指定する。 The direction-specific setting is specified when it is desired to set the image processing parameter to a different value in the X direction or the Y direction.

高速モードは、処理の高速化のON/OFFを切り替えるためのパラメータである。高速モードをONとした場合は、画像処理パラメータとして選択できる値が限られるものの(例えば4の倍数など)、内部処理の高速化が図られる。 The high-speed mode is a parameter for switching ON / OFF of high-speed processing. When the high-speed mode is turned on, the values that can be selected as image processing parameters are limited (for example, a multiple of 4), but the internal processing can be speeded up.

傷レベルは、傷として判定する周囲画素の平均濃度との差を規定するパラメータであり、例えば10を指定すると、周囲画素の平均濃度との差が10未満の画素は傷として判定されず、10以上の画素は傷として判定される。 The scratch level is a parameter that defines the difference from the average density of the surrounding pixels judged as scratches. For example, if 10 is specified, pixels having a difference of less than 10 from the average density of the surrounding pixels are not judged as scratches and 10 The above pixels are determined as scratches.

設定方向は、方向別設定と連動し、方向別設定がOFFの場合は、検出方向で設定された方向に共通で(図3の例ではXY共通)以下の画像処理パラメータが設定される。方向別設定がONの場合は、方向毎に以下の画像処理パラメータを個別に設定することになる。 The setting direction is linked to the direction-specific setting, and when the direction-specific setting is OFF, the following image processing parameters are set in common with the direction set in the detection direction (common to XY in the example of FIG. 3). When the direction-specific setting is ON, the following image processing parameters are individually set for each direction.

セグメントサイズは、傷の大きさに応じて規定するパラメータである。例えば図3の例ではセグメントサイズとして8を指定しており、検査対象の形状画像のある部位の周囲で8×8の領域を取り、これを4分割して領域毎の差分を取り、傷の量を決定する。このようにセグメントサイズは、傷を検出する領域の大きさを規定するパラメータである。 The segment size is a parameter defined according to the size of the scratch. For example, in the example of FIG. 3, 8 is specified as the segment size, an 8 × 8 area is taken around a part having a shape image to be inspected, this is divided into 4 parts, and the difference for each area is taken to obtain a scratch. Determine the amount. In this way, the segment size is a parameter that defines the size of the area where scratches are detected.

比較間隔設定は、マニュアル又は自動を選択する。 Select manual or automatic for the comparison interval setting.

移動量は、比較間隔を指定した画素(ここでは4ピクセル)毎に移動させる。 The movement amount is moved every pixel (here, 4 pixels) for which the comparison interval is specified.

比較セグメント間隔は、濃度差を比較するセグメントの間隔を規定する。 The comparison segment interval defines the interval between the segments that compare the concentration differences.

(前処理フィルタ)
画像検査装置1は、検査画像に適用される画像処理を前処理フィルタとして複数備えている。図4は、前処理フィルタの例を示している。図4に示す例は、使用者が検査画像に適用したい前処理フィルタを手動で設定するためのユーザーインターフェースであり、前処理フィルタ設定部62としてモニタ5上に表示することができる。前処理フィルタ設定部62には、ドロップダウンリストボタン62aが設けられており、このドロップダウンリストボタン62aをマウス7でクリック操作すると、図4に示すような前処理フィルタが表示され、マウス7によって選択することができる。前処理フィルタが不要な場合には、「なし」を選択すればよい。前処理フィルタには、「リアルタイム濃淡補正」(シェーディング補正)フィルタが含まれている。シェーディング補正は、周辺に対して明るい部分や、暗い部分のみを抽出するなど、明暗の選別機能を有している。
(Pretreatment filter)
The image inspection device 1 includes a plurality of image processes applied to the inspection image as a preprocessing filter. FIG. 4 shows an example of a preprocessing filter. The example shown in FIG. 4 is a user interface for manually setting a preprocessing filter that the user wants to apply to the inspection image, and can be displayed on the monitor 5 as the preprocessing filter setting unit 62. The preprocessing filter setting unit 62 is provided with a drop-down list button 62a, and when the drop-down list button 62a is clicked with the mouse 7, a preprocessing filter as shown in FIG. 4 is displayed, and the mouse 7 displays the preprocessing filter. You can choose. If you do not need the preprocessing filter, you can select "None". The preprocessing filter includes a "real-time shading correction" (shading correction) filter. The shading correction has a light / dark selection function such as extracting only a bright part or a dark part with respect to the periphery.

図5は、リアルタイム濃淡補正のパラメータの例を示している。図5に示す例は、使用者がリアルタイム濃淡補正のパラメータを手動で設定するためのユーザーインターフェースであり、リアルタイム濃淡補正パラメータ設定部63としてモニタ5上に表示することができる。リアルタイム濃淡補正パラメータ設定部63の各値等は、キーボード6やマウス7等を操作することによって変更することができる。 FIG. 5 shows an example of parameters for real-time shading correction. The example shown in FIG. 5 is a user interface for the user to manually set the parameters of the real-time shading correction, and can be displayed on the monitor 5 as the real-time shading correction parameter setting unit 63. Each value of the real-time shading correction parameter setting unit 63 and the like can be changed by operating the keyboard 6 and the mouse 7.

リアルタイム濃淡補正のパラメータとしては、補正方法、抽出サイズ、処理方向、抽出色、ゲイン、ノイズ除去、コントラスト均一化、領域外参照、回数等が挙げられる。リアルタイム濃淡補正パラメータ設定部63は、補正方法設定欄63a、抽出サイズ設定欄63b、処理方向設定欄63c、抽出色設定欄63d、ゲイン設定欄63e、ノイズ除去設定欄63f、コントラスト均一化設定欄63g、領域外参照設定欄63h、回数設定欄63iを備えている。 Parameters of real-time shading correction include correction method, extraction size, processing direction, extraction color, gain, noise removal, contrast equalization, out-of-area reference, number of times, and the like. The real-time shading correction parameter setting unit 63 includes a correction method setting field 63a, an extraction size setting field 63b, a processing direction setting field 63c, an extraction color setting field 63d, a gain setting field 63e, a noise removal setting field 63f, and a contrast equalization setting field 63g. , The out-of-area reference setting field 63h and the number of times setting field 63i are provided.

(記憶部46の構成)
図2に示す記憶部46は、例えばRAM等で構成することができ、登録画像記憶部46aと、サーチ処理用特徴量記憶部46bと、検査設定記憶部46cとを備えている。登録画像記憶部46aは、ワークWを撮像して得られた登録画像を記憶する部分である。登録画像は、設定モード時にワークWを撮像部3によって撮像した画像とすることができる。登録画像は、後述するサーチ処理に用いるパターン領域を設定する際に使用される。
(Structure of storage unit 46)
The storage unit 46 shown in FIG. 2 can be configured by, for example, a RAM or the like, and includes a registered image storage unit 46a, a feature amount storage unit 46b for search processing, and an inspection setting storage unit 46c. The registered image storage unit 46a is a portion that stores the registered image obtained by imaging the work W. The registered image can be an image captured by the image pickup unit 3 on the work W in the setting mode. The registered image is used when setting a pattern area used for the search process described later.

サーチ処理用特徴量記憶部46bは、パターン領域内の画像から抽出された第1のサーチ処理用特徴量と、第2のサーチ処理用特徴量とを記憶する部分である。第1のサーチ処理用特徴量は、例えばパターン領域内の画像から抽出することができる濃淡画像であり、正規化相関量とすることができる。第2のサーチ処理用特徴量は、パターン領域内の画像から抽出することができるエッジ情報(エッジ画像や向き、大きさといった幾何情報)である。 The search processing feature amount storage unit 46b is a portion that stores the first search processing feature amount extracted from the image in the pattern region and the second search processing feature amount. The first feature amount for search processing is, for example, a shade image that can be extracted from an image in a pattern region, and can be a normalized correlation amount. The second search processing feature amount is edge information (geometric information such as edge image, orientation, and size) that can be extracted from the image in the pattern area.

検査設定記憶部46cは、後述するサーチ処理選択部により選択されたサーチ処理(サーチアルゴリズム)を検査設定として記憶するとともに、検査処理選択部51bにより選択された欠陥検査処理(欠陥検査アルゴリズム)を検査設定として記憶する部分である。選択されたサーチ処理及び選択された欠陥検査処理は、設定モード時に検査設定記憶部46cに記憶される。運転モード時には、検査設定記憶部46cに記憶されているサーチ処理及び欠陥検査処理を検査設定記憶部46cから読み出して適用する。 The inspection setting storage unit 46c stores the search process (search algorithm) selected by the search process selection unit described later as an inspection setting, and inspects the defect inspection process (defect inspection algorithm) selected by the inspection process selection unit 51b. This is the part to be stored as a setting. The selected search process and the selected defect inspection process are stored in the inspection setting storage unit 46c in the setting mode. In the operation mode, the search process and the defect inspection process stored in the inspection setting storage unit 46c are read from the inspection setting storage unit 46c and applied.

(設定部47の構成)
設定部47は、パターン領域設定部47aと、検査領域設定部47bと、欠陥サイズ設定部47cとを備えている。パターン領域設定部47aは、登録画像記憶部46aに記憶されている登録画像を読み込み、当該登録画像上で、サーチ処理に用いるパターン領域を設定するための部分である。
(Structure of setting unit 47)
The setting unit 47 includes a pattern area setting unit 47a, an inspection area setting unit 47b, and a defect size setting unit 47c. The pattern area setting unit 47a is a part for reading the registered image stored in the registered image storage unit 46a and setting a pattern area to be used for the search process on the registered image.

具体的には、パターン領域設定部47aは、登録画像記憶部46aに記憶されている登録画像を読み込んだ後、表示制御部43を制御し、図6に示すように、登録画像64をモニタ5に表示させる。使用者がマウス7の操作により、パターン領域を囲むように枠線64aを描いたことをパターン領域設定部47aが検出する。使用者が例えばマウス7のボタンをクリックした状態でマウス7を動かすことで、パターン領域を囲む枠線64aを、登録画像64上に描くことができる。また、パターン領域の端を複数箇所クリックすることにより、パターン領域を囲むように枠線64aを自動で描くこともできる。パターン領域設定部47aは上述したようなマウス7の操作を検出して登録画像64上で、サーチ処理に用いるパターン領域の設定を受け付ける。パターン領域は、制御ユニット4の記憶部46に記憶しておくこともできる。 Specifically, the pattern area setting unit 47a controls the display control unit 43 after reading the registered image stored in the registered image storage unit 46a, and monitors the registered image 64 as shown in FIG. To display. The pattern area setting unit 47a detects that the user has drawn a frame line 64a so as to surround the pattern area by operating the mouse 7. By moving the mouse 7 while the user clicks the button of the mouse 7, for example, the frame line 64a surrounding the pattern area can be drawn on the registered image 64. Further, by clicking the edge of the pattern area at a plurality of places, the frame line 64a can be automatically drawn so as to surround the pattern area. The pattern area setting unit 47a detects the operation of the mouse 7 as described above and accepts the setting of the pattern area used for the search process on the registered image 64. The pattern area can also be stored in the storage unit 46 of the control unit 4.

また、図2に示す設定部47は、サーチ領域の設定を受け付けることもできように構成されている。サーチ領域の設定は、登録画像64上で受け付けることができ、パターン領域の設定と同様に、マウス7の操作により、サーチ領域を囲むように枠線64bを描く。設定部47は、上述したような使用者によるマウス7の操作を検出し、サーチ処理に用いるサーチ領域の設定を受け付ける。サーチ領域は、制御ユニット4の記憶部46に記憶しておくこともできる。サーチ領域は、サーチ処理を行う領域であり、サーチ領域以外の領域に対してはサーチ処理を行わないので、サーチ領域を小さくすればするほどサーチ処理に要する時間が短くなる。 Further, the setting unit 47 shown in FIG. 2 is configured to be able to accept the setting of the search area. The setting of the search area can be accepted on the registered image 64, and the frame line 64b is drawn so as to surround the search area by the operation of the mouse 7 in the same manner as the setting of the pattern area. The setting unit 47 detects the operation of the mouse 7 by the user as described above, and accepts the setting of the search area used for the search process. The search area can also be stored in the storage unit 46 of the control unit 4. Since the search area is an area for performing search processing and does not perform search processing for areas other than the search area, the smaller the search area, the shorter the time required for search processing.

検査領域設定部47bは、検査画像上で検査領域の設定を受け付ける部分である。検査領域は、欠陥検査処理を行う領域であり、検査領域以外の領域に対しては欠陥検査処理を行わないので、検査領域を小さくすればするほど欠陥検査処理に要する時間が短くなる。検査画像は、設定モード時にワークWを撮像部3によって撮像した画像とすることができ、上記登録画像と同様に記憶部46に記憶させておくことができる。従って、検査領域設定部47bは、記憶部46に記憶されている検査画像を読み込み、当該検査画像上で、欠陥検査処理を設定するための部分である。 The inspection area setting unit 47b is a part that accepts the setting of the inspection area on the inspection image. The inspection area is an area for performing defect inspection processing, and defect inspection processing is not performed for areas other than the inspection area. Therefore, the smaller the inspection area, the shorter the time required for defect inspection processing. The inspection image can be an image captured by the image pickup unit 3 in the setting mode, and can be stored in the storage unit 46 in the same manner as the registered image. Therefore, the inspection area setting unit 47b is a part for reading the inspection image stored in the storage unit 46 and setting the defect inspection process on the inspection image.

具体的には、検査領域設定部47bは、記憶部46に記憶されている検査画像を読み込んだ後、表示制御部43を制御し、図7に示すように、検査画像65をモニタ5に表示させる。上記パターン領域の設定時と同様に、使用者がマウス7の操作により、検査領域を囲むように枠線65aを描く。検査領域設定部47bは、上述したような使用者によるマウス7の操作を検出して検査画像65上で、欠陥検査処理に用いる検査領域の設定を受け付ける。検査領域は、制御ユニット4の記憶部46に記憶しておくこともできる。 Specifically, the inspection area setting unit 47b controls the display control unit 43 after reading the inspection image stored in the storage unit 46, and displays the inspection image 65 on the monitor 5 as shown in FIG. Let me. Similar to the setting of the pattern area, the user draws a frame line 65a so as to surround the inspection area by operating the mouse 7. The inspection area setting unit 47b detects the operation of the mouse 7 by the user as described above, and receives the setting of the inspection area used for the defect inspection process on the inspection image 65. The inspection area can also be stored in the storage unit 46 of the control unit 4.

図2に示す欠陥サイズ設定部47cは、検査領域設定部47bで受け付けた検査領域の中で欠陥として検出すべき画像領域の大きさである欠陥サイズの設定を使用者から受け付ける部分である。欠陥サイズは、検査領域の大きさよりも小さく、具体的には、図7に符号65cで欠陥部を示した場合、この欠陥部65cを全て入れることのできる最小の枠線(矩形領域)65bをマウス7の操作によって描くことによって欠陥サイズを設定することができる。欠陥サイズ設定部47cは、上述したようなマウス7の操作を検出して、検査画像65上で、欠陥サイズの設定を受け付けることができる。このように、欠陥サイズは、使用者が自ら設定しているので、実際の欠陥の大きさを反映した正確なものになる。 The defect size setting unit 47c shown in FIG. 2 is a portion that receives from the user the setting of the defect size, which is the size of the image area to be detected as a defect in the inspection area received by the inspection area setting unit 47b. The defect size is smaller than the size of the inspection area. Specifically, when the defect portion is indicated by reference numeral 65c in FIG. 7, the minimum frame line (rectangular region) 65b in which all the defect portions 65c can be inserted is provided. The defect size can be set by drawing by operating the mouse 7. The defect size setting unit 47c can detect the operation of the mouse 7 as described above and accept the defect size setting on the inspection image 65. In this way, since the defect size is set by the user, it is an accurate one that reflects the actual size of the defect.

欠陥サイズ設定部47cは、上述した矩形領域の描画による入力以外にも、例えば、欠陥サイズの数値での入力、欠陥部位の描画による入力のうち、少なくとも1つの入力が可能に構成することができる。欠陥サイズの数値での入力方法としては、例えば、キーボード6やマウス7等を操作することにより、欠陥部65cの縦寸法及び横寸法を入力する方法や、欠陥部65cの縦ピクセル数及び横ピクセル数を入力する方法等がある。欠陥部位の描画による入力方法としては、例えば、検査画像65上においてマウス7のポインタで欠陥部65cをなぞるように当該マウス7を操作する方法や、感圧ペンによって欠陥部65cをなぞるようにする方法等がある。これら何れの入力方法であっても欠陥サイズ設定部47cが欠陥サイズの設定を受け付ける。 The defect size setting unit 47c can be configured to enable at least one input of, for example, a numerical value of the defect size and an input by drawing the defect portion, in addition to the input by drawing the rectangular area described above. .. As a method of inputting the numerical value of the defect size, for example, a method of inputting the vertical dimension and the horizontal dimension of the defect portion 65c by operating the keyboard 6 or the mouse 7, or the number of vertical pixels and the horizontal pixel of the defect portion 65c. There is a method to enter the number. As an input method by drawing the defective portion, for example, a method of operating the mouse 7 so that the pointer of the mouse 7 traces the defective portion 65c on the inspection image 65, or a method of tracing the defective portion 65c with a pressure-sensitive pen. There are methods and so on. Regardless of any of these input methods, the defect size setting unit 47c accepts the defect size setting.

(欠陥検査用特徴量抽出部48の構成)
図2に示す欠陥検査用特徴量抽出部48は、検査領域設定部47bで受け付けた検査領域65a(図7に示す)内の各画素について、第1の欠陥検査用特徴量と、該第1の欠陥検査用特徴量とは異なる第2の欠陥検査用特徴量とを抽出する部分である。第1の欠陥検査用特徴量は、周辺画素との濃淡値の差であり、第2の欠陥検査用特徴量は、濃淡値である。従って、欠陥検査用特徴量抽出部48は、検査領域65a内の各画素について、周辺画素との濃淡値の差を求めるとともに、濃淡値も求め、これらに基づいて、周辺画素との濃淡値の差を第1の欠陥検査用特徴量とし、濃淡値を第2の欠陥検査用特徴量として抽出する。抽出した第1の欠陥検査用特徴量及び第2の欠陥検査用特徴量は、記憶部46に記憶させておくことができる。
(Structure of feature amount extraction unit 48 for defect inspection)
The defect inspection feature amount extraction unit 48 shown in FIG. 2 has the first defect inspection feature amount and the first defect inspection feature amount for each pixel in the inspection area 65a (shown in FIG. 7) received by the inspection area setting unit 47b. This is a part for extracting a second defect inspection feature amount different from the defect inspection feature amount of the above. The first defect inspection feature amount is the difference in shading value from the peripheral pixels, and the second defect inspection feature amount is the shading value. Therefore, the defect inspection feature amount extraction unit 48 obtains the difference in the shading value from the peripheral pixels for each pixel in the inspection region 65a, and also obtains the shading value. Based on these, the shading value with the peripheral pixels is obtained. The difference is extracted as the first defect inspection feature amount, and the shading value is extracted as the second defect inspection feature amount. The extracted first defect inspection feature amount and second defect inspection feature amount can be stored in the storage unit 46.

(項目入力部49の構成)
図2に示す項目入力部49は、第1の欠陥検査処理及び第2の欠陥検査処理の共通設定項目を入力するための部分である。第1の欠陥検査処理を傷検査ツールとし、第2の欠陥検査処理をブロブ計測ツールとした場合、共通設定項目は、欠陥の明暗指定とすることができる。欠陥の明暗を指定することは、明暗情報の入力ということもできる。
(Structure of item input unit 49)
The item input unit 49 shown in FIG. 2 is a part for inputting common setting items for the first defect inspection process and the second defect inspection process. When the first defect inspection process is a scratch inspection tool and the second defect inspection process is a blob measurement tool, the common setting item can be the light / dark designation of the defect. Specifying the brightness of a defect can also be said to be the input of brightness information.

具体的には、図8に示すように、項目入力部49は、表示制御部43を制御し、検査画像65をモニタ5に表示させ、この検査画像65が表示されたモニタ5に、共通設定項目入力欄66を表示させる。共通設定項目入力欄66には、ドロップダウンリストボタン66aが設けられており、このドロップダウンリストボタン66aをマウス7でクリック操作すると、図8に示すように、明暗指定の選択枝として、「白黒両方」、「白い傷のみ」、「黒い傷のみ」の3つの選択枝が表示される。キーボード6やマウス7により、3つの選択枝のうち、1つを選択することができ、項目入力部49は、この選択操作を検出して共通設定項目の入力を受け付ける。受け付けた共通項目は、記憶部46に記憶させておくことができ、第1の欠陥検査処理及び第2の欠陥検査処理に適用される。 Specifically, as shown in FIG. 8, the item input unit 49 controls the display control unit 43 to display the inspection image 65 on the monitor 5, and is set in common to the monitor 5 on which the inspection image 65 is displayed. The item input field 66 is displayed. A drop-down list button 66a is provided in the common setting item input field 66, and when the drop-down list button 66a is clicked with the mouse 7, as shown in FIG. 8, "black and white" is selected as a light / dark selection option. Three options are displayed: "Both", "White scratches only", and "Black scratches only". One of the three selection branches can be selected by the keyboard 6 or the mouse 7, and the item input unit 49 detects this selection operation and accepts the input of the common setting item. The received common items can be stored in the storage unit 46, and are applied to the first defect inspection process and the second defect inspection process.

また、項目入力部49は、第1のサーチ処理及び第2のサーチ処理の共通設定項目を入力することが可能な部分でもある。第1のサーチ処理をパターンサーチとし、第2のサーチ処理をエッジベースサーチとした場合、共通設定項目は、サーチ処理を行う角度範囲とすることができる。運転モードのサーチ処理時に、設定されているパターン領域が傾いた状態で現れる可能性がある場合には、角度範囲を設定しておく。角度範囲は、例えば時計回り方向を「+」とし、反時計回り方向を「-」として設定することができる。 The item input unit 49 is also a part capable of inputting common setting items for the first search process and the second search process. When the first search process is a pattern search and the second search process is an edge-based search, the common setting item can be an angle range in which the search process is performed. If there is a possibility that the set pattern area may appear in an inclined state during the search process of the operation mode, set the angle range. The angle range can be set, for example, as "+" in the clockwise direction and "-" in the counterclockwise direction.

具体的には、図9に示すように、項目入力部49は、表示制御部43を制御し、登録画像64をモニタ5に表示させ、この登録画像64が表示されたモニタ5に、共通設定項目入力欄67を表示させる。共通設定項目入力欄67には、角度範囲入力部67aが設けられており、この角度範囲入力部67aをマウス7でクリック操作すると、角度を数値で入力することができる。尚、キーボード6の操作により数値を直接入力するようにしてもよい。 Specifically, as shown in FIG. 9, the item input unit 49 controls the display control unit 43 to display the registered image 64 on the monitor 5, and is set in common to the monitor 5 on which the registered image 64 is displayed. The item input field 67 is displayed. An angle range input unit 67a is provided in the common setting item input field 67, and when the angle range input unit 67a is clicked with the mouse 7, the angle can be input numerically. It should be noted that the numerical value may be directly input by operating the keyboard 6.

項目入力部49は、キーボード6やマウス7の入力操作を検出して共通設定項目の入力を受け付ける。図9に示すように、「30」と入力された場合、設定されているパターン領域の中心線がモニタ5の縦方向に対してプラスマイナス30°傾いても、サーチ処理で画像領域を検出することが可能になる。項目入力部49で受け付けた共通項目は、記憶部46に記憶させておくことができ、第1のサーチ処理及び第2のサーチ処理に適用される。 The item input unit 49 detects the input operation of the keyboard 6 or the mouse 7 and accepts the input of the common setting item. As shown in FIG. 9, when "30" is input, the image area is detected by the search process even if the center line of the set pattern area is tilted by plus or minus 30 ° with respect to the vertical direction of the monitor 5. Will be possible. The common items received by the item input unit 49 can be stored in the storage unit 46, and are applied to the first search process and the second search process.

(画像処理部50)
図2に示す画像処理部50は、サーチ処理部50aと、欠陥検査部50bとを備えている。
(Image processing unit 50)
The image processing unit 50 shown in FIG. 2 includes a search processing unit 50a and a defect inspection unit 50b.

(選択部51の構成)
図2に示す選択部51は、サーチ処理選択部51aと、検査処理選択部51bとを備えている。
(Structure of selection unit 51)
The selection unit 51 shown in FIG. 2 includes a search processing selection unit 51a and an inspection processing selection unit 51b.

(サーチ処理部50aの構成)
サーチ処理部50aには、登録画像64とは別に、撮像部3によって新たにワークWを撮像して得られた画像が入力される。撮像部3によって新たにワークWを撮像して得られた画像を入力画像と呼ぶ。サーチ処理部50aは、入力画像に対して、第1のサーチ処理用特徴量と所定値以上の相関値(スコアー)を有する画像領域を検出する第1のサーチ処理と、第2のサーチ処理用特徴量と所定値以上の相関値を有する画像領域を検出する第2のサーチ処理とを実行する。サーチ処理部50aが使用する第1のサーチ処理用特徴量及び第2のサーチ処理用特徴量は、サーチ処理用特徴量記憶部46bから読み込む。
(Structure of search processing unit 50a)
In addition to the registered image 64, an image obtained by newly imaging the work W by the imaging unit 3 is input to the search processing unit 50a. An image obtained by newly imaging the work W by the imaging unit 3 is called an input image. The search processing unit 50a has a first search process for detecting an image region having a correlation value (score) equal to or higher than a predetermined value with a feature amount for the first search process and a second search process for the input image. A second search process for detecting an image region having a correlation value between the feature amount and a predetermined value or more is executed. The first search processing feature amount and the second search processing feature amount used by the search processing unit 50a are read from the search processing feature amount storage unit 46b.

第1のサーチ処理用特徴量が正規化相関量である場合には、第1のサーチ処理はパターンサーチとすることができる。パターンサーチは、正規化相関サーチであり、パターン領域と、入力画像の一部との相関値(類似度)を算出し、その相関値に基づいて相関値が高い(所定値以上)画像領域を検出する。 When the feature amount for the first search processing is the normalized correlation amount, the first search processing can be a pattern search. The pattern search is a normalized correlation search, in which a correlation value (similarity) between a pattern area and a part of an input image is calculated, and an image area having a high correlation value (predetermined value or more) is calculated based on the correlation value. To detect.

第2のサーチ処理用特徴量がエッジ情報である場合には、第2のサーチ処理はエッジベースサーチとすることができる。エッジベースサーチは、パターン領域のエッジ情報と、入力画像の一部のエッジ情報とを得て、両者のエッジの相関値(類似度)を算出し、その相関値に基づいて相関値が高い(所定値以上)画像領域を検出する。 When the feature amount for the second search processing is edge information, the second search processing can be an edge-based search. The edge-based search obtains the edge information of the pattern area and the edge information of a part of the input image, calculates the correlation value (similarity) of both edges, and has a high correlation value based on the correlation value (the correlation value is high). (More than a predetermined value) Detects an image area.

サーチ処理部50aは、第1のサーチ処理の処理時間と、第2のサーチ処理の処理時間とを取得する。すなわち、第1のサーチ処理を開始してから終了するまでの時間と、第2のサーチ処理を開始してから終了するまでの時間とをそれぞれ計測して保持または記憶部46に記憶させておくことができる。第1のサーチ処理と第2のサーチ処理とは並行して進めてもよいし、異なるタイミングで実施してもよい。 The search processing unit 50a acquires the processing time of the first search processing and the processing time of the second search processing. That is, the time from the start to the end of the first search process and the time from the start to the end of the second search process are measured and stored in the storage unit 46. be able to. The first search process and the second search process may be performed in parallel, or may be performed at different timings.

図2に示す表示制御部43は、第1のサーチ処理の結果得られた画像領域の位置を表示した第1サーチ処理結果画像と、第2のサーチ処理の結果得られた画像領域の位置を表示した第2サーチ処理結果画像とをモニタ5に同時に表示させるように構成されている。図10に示すように、表示制御部43は、サーチ結果画像表示用ユーザーインターフェース68をモニタ5に表示させる。サーチ結果画像表示用ユーザーインターフェース68には、第1のサーチ処理の結果得られた画像領域の位置を表示した第1サーチ処理結果画像71が表示される第1画像表示領域68aと、第2のサーチ処理の結果得られた画像領域の位置を表示した第2サーチ処理結果画像72が表示される第2画像表示領域68bと、検出レベル調整領域68cとが設けられている。第1サーチ処理結果画像71及び第2サーチ処理結果画像72は、入力画像に対して画像領域の位置を重畳表示した画像である。 The display control unit 43 shown in FIG. 2 determines the position of the first search processing result image displaying the position of the image area obtained as a result of the first search processing and the position of the image area obtained as a result of the second search processing. It is configured to simultaneously display the displayed second search processing result image on the monitor 5. As shown in FIG. 10, the display control unit 43 causes the monitor 5 to display the search result image display user interface 68. The user interface 68 for displaying the search result image has a first image display area 68a in which the first search processing result image 71 displaying the position of the image area obtained as a result of the first search processing is displayed, and a second image display area 68a. A second image display area 68b on which the second search processing result image 72 displaying the position of the image area obtained as a result of the search processing is displayed, and a detection level adjustment area 68c are provided. The first search processing result image 71 and the second search processing result image 72 are images in which the position of the image region is superimposed and displayed on the input image.

この実施形態では、第1サーチ処理結果画像71と第2サーチ処理結果画像72をモニタ5に同時に表示するようにしているが、これに限らず、第1サーチ処理結果画像71と第2サーチ処理結果画像72を切り替えてモニタ5に表示するようにしてもよい。例えば、サーチ結果画像表示用ユーザーインターフェース68に、画像切替手段(例:ボタン等)を設けておき、画像切替手段を使用者がマウス7等で操作することにより、第1サーチ処理結果画像71のみを表示させたり、第2サーチ処理結果画像72のみを表示させることができる。また、例えば、第1サーチ処理結果画像71及び第2サーチ処理結果画像72のそれぞれの周辺部にタブを設けておき、タブを操作することにより、第1サーチ処理結果画像71のみを表示させたり、第2サーチ処理結果画像72のみを表示させることもできる。 In this embodiment, the first search processing result image 71 and the second search processing result image 72 are simultaneously displayed on the monitor 5, but the present invention is not limited to this, and the first search processing result image 71 and the second search processing are not limited to this. The result image 72 may be switched and displayed on the monitor 5. For example, the search result image display user interface 68 is provided with an image switching means (eg, a button or the like), and the user operates the image switching means with a mouse 7 or the like to obtain only the first search processing result image 71. Can be displayed, or only the second search processing result image 72 can be displayed. Further, for example, tabs may be provided around each of the first search processing result image 71 and the second search processing result image 72, and by operating the tabs, only the first search processing result image 71 may be displayed. , It is also possible to display only the second search processing result image 72.

表示制御部43は、所定値以上の相関値を持った複数の画像領域の中で、相関値が最も高い最高相関画像領域と、最高相関画像領域の相関値未満の相関値を有する画像領域とを異なる表示形態で表示するように構成されている。例えば、図10に示す第1画像71には、最も大きな枠線(検出枠)71aと、この枠線71aよりも小さな枠線(検出枠)71bとが入力画像に重畳表示されている。枠線71aで囲まれた領域は、最高相関画像領域であり、この領域は、相関値が最も高い画像領域となる。一方、枠線71bで囲まれた領域は、枠線71aで囲まれた領域よりも相関値が低い画像領域である。枠線71a及び枠線71bの大きさは、相関値の大きさと関連しており、相関値の大きさが大きければ大きいほど枠線を大きくするように、表示制御部43が構成されている。第2サーチ処理結果画像72についても同様な枠線72aや枠線72b(図11に示す)を表示させることができる。枠線71a、71b内の矢印は、検出した画像領域の姿勢を表している。 The display control unit 43 includes an image region having the highest correlation value among a plurality of image regions having a correlation value of a predetermined value or more, and an image region having a correlation value less than the correlation value of the highest correlation image region. Is configured to be displayed in a different display format. For example, in the first image 71 shown in FIG. 10, the largest frame line (detection frame) 71a and the frame line (detection frame) 71b smaller than the frame line 71a are superimposed and displayed on the input image. The region surrounded by the frame line 71a is the highest correlation image region, and this region is the image region having the highest correlation value. On the other hand, the region surrounded by the frame line 71b is an image region having a lower correlation value than the region surrounded by the frame line 71a. The size of the frame line 71a and the frame line 71b is related to the size of the correlation value, and the display control unit 43 is configured so that the larger the size of the correlation value, the larger the frame line. Similar frame lines 72a and 72b (shown in FIG. 11) can be displayed on the second search processing result image 72 as well. The arrows in the frame lines 71a and 71b indicate the posture of the detected image area.

パターンサーチでは、第1サーチ処理結果画像71に示すように、複数の画像領域が表示されており、しかも、検出したいパターンとは反対向きのものが高い相関値で検出されてしまっているので、安定性が低いとい判断できる。一方、エッジベースサーチでは、第2サーチ処理結果画像72で示すように、検出された画像領域が1つであり、かつ、相関値が高いので、画像領域を安定して検出することができそうであると判断できる。 In the pattern search, as shown in the first search processing result image 71, a plurality of image areas are displayed, and the pattern opposite to the pattern to be detected is detected with a high correlation value. It can be judged that the stability is low. On the other hand, in the edge-based search, as shown in the second search processing result image 72, the detected image area is one and the correlation value is high, so that the image area can be stably detected. It can be judged that.

従って、使用者は、サーチ結果画像表示用ユーザーインターフェース68に表示されている第1サーチ処理結果画像71及び第2サーチ処理結果画像72を見ることで、どの程度の相関値で画像領域が検出されているのかを容易に把握することができる。 Therefore, the user can detect the image area with a correlation value by looking at the first search processing result image 71 and the second search processing result image 72 displayed on the search result image display user interface 68. You can easily grasp whether it is.

サーチ結果画像表示用ユーザーインターフェース68の第1画像表示領域68aには、サーチ処理部50aが取得した第1のサーチ処理の処理時間を表示する第1処理時間表示領域68dが設けられている。また、サーチ結果画像表示用ユーザーインターフェース68の第2画像表示領域68bには、サーチ処理部50aが取得した第2のサーチ処理の処理時間を表示する第2処理時間表示領域68fが設けられている。これにより、使用者は、第1のサーチ処理の処理時間と第2のサーチ処理の処理時間とを容易に比較することができる。相関値は、0~100の範囲で表示することができる。 The first image display area 68a of the search result image display user interface 68 is provided with a first processing time display area 68d for displaying the processing time of the first search processing acquired by the search processing unit 50a. Further, the second image display area 68b of the search result image display user interface 68 is provided with a second processing time display area 68f for displaying the processing time of the second search processing acquired by the search processing unit 50a. .. Thereby, the user can easily compare the processing time of the first search processing and the processing time of the second search processing. The correlation value can be displayed in the range of 0 to 100.

サーチ結果画像表示用ユーザーインターフェース68の第1画像表示領域68aには、最高相関画像領域の相関値を表示する第1相関値表示領域68eが設けられている。また、サーチ結果画像表示用ユーザーインターフェース68の第2画像表示領域68bには、最高相関画像領域の相関値を表示する第2相関値表示領域68gが設けられている。これにより、使用者は、第1のサーチ処理の最高相関値と第2のサーチ処理の最高相関値とを容易に比較することができる。 The first image display area 68a of the search result image display user interface 68 is provided with a first correlation value display area 68e for displaying the correlation value of the highest correlation image area. Further, the second image display area 68b of the search result image display user interface 68 is provided with a second correlation value display area 68g for displaying the correlation value of the highest correlation image area. Thereby, the user can easily compare the highest correlation value of the first search process and the highest correlation value of the second search process.

検出レベル調整領域68cは、検出レベル(所定値)を調整するための領域である。検出レベルは相関値とすることができ、例えば検出レベル調整領域68cに「60」と入力することで、相関値が60以上の画像領域だけを抽出して第1画像表示領域68a及び第2画像表示領域68bに表示させることができるようになっている。検出レベル調整領域68cに入力された検出レベルは、第1のサーチ処理と第2のサーチ処理の両方に適用される。つまり、第1のサーチ処理で使用される検出レベルと、第2のサーチ処理で使用される検出レベルとを一括して調整可能に構成されている。第1のサーチ処理で使用される検出レベルと、第2のサーチ処理で使用される検出レベルとは同じ値である。 The detection level adjustment area 68c is an area for adjusting the detection level (predetermined value). The detection level can be a correlation value. For example, by inputting "60" in the detection level adjustment area 68c, only the image area having the correlation value of 60 or more is extracted and the first image display area 68a and the second image are used. It can be displayed in the display area 68b. The detection level input to the detection level adjustment area 68c is applied to both the first search process and the second search process. That is, the detection level used in the first search process and the detection level used in the second search process can be collectively adjusted. The detection level used in the first search process and the detection level used in the second search process are the same values.

例えば、図11に示すように、検出レベル調整領域68cに「40」と入力して検出レベルを下げると、表示制御部43は、検出レベル調整後の第1サーチ処理結果画像71及び第2サーチ処理結果画像72をモニタ5に表示させる。検出レベル調整後の第1サーチ処理結果画像71及び第2サーチ処理結果画像72は、同時に表示してもよいし、切り替えて表示してもよい。 For example, as shown in FIG. 11, when "40" is input to the detection level adjustment area 68c to lower the detection level, the display control unit 43 performs the first search processing result image 71 and the second search after the detection level adjustment. The processing result image 72 is displayed on the monitor 5. The first search processing result image 71 and the second search processing result image 72 after the detection level adjustment may be displayed at the same time or may be switched and displayed.

検出レベルを下げると、第1画像表示領域68a及び第2画像表示領域68bに表示される画像領域の数が増えることになる。検出レベルを下げても画像領域の数が増えない場合は、最高相関画像領域と、それ未満の相関値を有する画像領域との相関値の差が大きいということであり、画像領域の検出が安定しているといえる。従って、検出レベルの調整によって画像領域の検出の安定度を把握することもできる。 When the detection level is lowered, the number of image areas displayed in the first image display area 68a and the second image display area 68b increases. If the number of image regions does not increase even if the detection level is lowered, it means that the difference between the highest correlation image region and the image region having a correlation value less than that is large, and the detection of the image region is stable. It can be said that it is doing. Therefore, the stability of detection of the image region can be grasped by adjusting the detection level.

この実施形態では、最高相関画像領域と、それ未満の相関値を有する画像領域とを容易に区別するために、これら画像領域を異なる表示形態で表示するようにしている。その一例として、枠線71a、71bの大きさを相関値によって変える形態を示したが、異なる表示形態の例としては、最高相関画像領域を囲む枠線の色と、それ未満の相関値を有する画像領域を囲む枠線の色とを変える、枠線の線種を変える、枠線の太さを変える等を挙げることができる。また、最高相関画像領域に着色する色と、それ未満の相関値を有する画像領域に着色する色とを変えことも、異なる表示形態の一つである。さらに、最高相関画像領域と、それ未満の相関値を有する画像領域とにそれぞれ相関値を表示する形態であってもよい。 In this embodiment, in order to easily distinguish between the highest correlated image region and the image region having a correlation value less than that, these image regions are displayed in different display modes. As an example, a form in which the sizes of the frame lines 71a and 71b are changed according to the correlation value is shown, but as an example of different display forms, the color of the frame line surrounding the highest correlation image area and the correlation value less than that are provided. The color of the border surrounding the image area can be changed, the line type of the border can be changed, the thickness of the border can be changed, and the like. Further, it is also one of the different display forms to change the color to be colored in the highest correlation image area and the color to be colored in the image area having a correlation value less than that. Further, the correlation value may be displayed in the highest correlation image area and the image area having a correlation value less than that.

サーチ処理部50aは、項目入力部49で受け付けた共通項目を第1のサーチ処理及び第2のサーチ処理に適用する。これにより、例えば角度範囲のように、第1のサーチ処理及び第2のサーチ処理に適用する項目を複数回入力しなくて済む。 The search processing unit 50a applies the common items received by the item input unit 49 to the first search processing and the second search processing. As a result, it is not necessary to input items to be applied to the first search process and the second search process a plurality of times, for example, an angle range.

サーチ処理部50aは、複数の入力画像を連続的に取得して各入力画像に対して第1のサーチ処理と第2のサーチ処理とを実行する。そして、表示制御部43は、第1サーチ処理結果画像71及び第2サーチ処理結果画像72を更新するように構成されている。1回のサーチ処理の結果を見ただけでは、サーチ処理の安定性を推測するのが難しい場合があるが、異なる入力画像のそれぞれに対して第1のサーチ処理を実行して、複数の第1サーチ処理結果画像71を得て、モニタ5に順次表示することで、第1のサーチ処理の安定性を推測することができる。第2のサーチ処理についても同様である。複数の第1サーチ処理結果画像71及び第2サーチ処理結果画像72をモニタ5に表示させて安定性を見ることもできる。 The search processing unit 50a continuously acquires a plurality of input images and executes a first search process and a second search process for each input image. The display control unit 43 is configured to update the first search processing result image 71 and the second search processing result image 72. It may be difficult to estimate the stability of the search process just by looking at the result of one search process, but the first search process is executed for each of the different input images, and a plurality of first search processes are performed. 1 Search processing result The stability of the first search processing can be estimated by obtaining the image 71 and sequentially displaying it on the monitor 5. The same applies to the second search process. It is also possible to display the plurality of first search processing result images 71 and the second search processing result images 72 on the monitor 5 to check the stability.

(サーチ処理選択部51aの構成)
サーチ処理選択部51aは、図11に示すサーチ結果画像表示用ユーザーインターフェース68に第1サーチ処理結果画像71と第2サーチ処理結果画像72が表示された後に、第1のサーチ処理又は第2のサーチ処理のいずれかの選択を受け付ける部分である。具体的には、サーチ処理選択部51aは、表示制御部43により表示された第1サーチ処理結果画像71または第2サーチ処理結果画像72が選択されたか否かを検出し、第1サーチ処理結果画像71が選択されたことを検出した場合には第1のサーチ処理を選択し、第2サーチ処理結果画像72が選択されたことを検出した場合には第2のサーチ処理を選択するように構成されている。
(Structure of search processing selection unit 51a)
After the first search processing result image 71 and the second search processing result image 72 are displayed on the search result image display user interface 68 shown in FIG. 11, the search processing selection unit 51a may perform the first search processing or the second search processing. This is the part that accepts the selection of any of the search processes. Specifically, the search processing selection unit 51a detects whether or not the first search processing result image 71 or the second search processing result image 72 displayed by the display control unit 43 is selected, and the first search processing result. When it is detected that the image 71 is selected, the first search process is selected, and when it is detected that the second search process result image 72 is selected, the second search process is selected. It is configured.

つまり、使用者がモニタ5に表示された第1サーチ処理結果画像71を選択すると、第1のサーチ処理が自動的に選択され、使用者がモニタ5に表示された第2サーチ処理結果画像72を選択すると、第2のサーチ処理が自動的に選択される。これにより、使用者の直感的な操作によってサーチ処理を選択することができる。 That is, when the user selects the first search processing result image 71 displayed on the monitor 5, the first search processing is automatically selected, and the user selects the second search processing result image 72 displayed on the monitor 5. When is selected, the second search process is automatically selected. As a result, the search process can be selected by the user's intuitive operation.

尚、第1サーチ処理結果画像71の選択とは、第1サーチ処理結果画像71そのものの選択操作であってもよいし、第1サーチ処理結果画像71を囲む枠を選択する操作や、各種ボタン等による選択操作であってもよい。第2サーチ処理結果画像72の選択も同様である。このような操作の検出は、例えば、マウス7のポインタ位置の検出及びクリック操作の検出により可能となる。あるいは、図11に示すサーチ結果画像表示用ユーザーインターフェース68の検出レベル調整領域68c内にあるツール選択のドロップダウンリストから、いずれかを選択しても良い。ツール選択後に検出レベル調整領域68cのインターフェース内にある「次へ」ボタンを押すと、検査に用いるツールが確定される。 The selection of the first search processing result image 71 may be an operation of selecting the first search processing result image 71 itself, an operation of selecting a frame surrounding the first search processing result image 71, and various buttons. It may be a selection operation by such as. The same applies to the selection of the second search processing result image 72. Such an operation can be detected, for example, by detecting the pointer position of the mouse 7 and detecting the click operation. Alternatively, one may be selected from the tool selection drop-down list in the detection level adjustment area 68c of the search result image display user interface 68 shown in FIG. When the "Next" button in the interface of the detection level adjustment area 68c is pressed after selecting the tool, the tool used for the inspection is confirmed.

(サーチ処理におけるパラメータ変更)
サーチ処理部50aは、入力画像に適用される画像処理に係るパラメータ(サーチ処理用パラメータ)を変更して、検査設定記憶部46cに記憶されたサーチ処理を繰り返し実行して複数の検出結果を取得するように構成されている。そして、表示制御部43は、サーチ処理部50aで取得された複数の検出結果を同時又は切り替えて表示可能に構成されている。
(Parameter change in search process)
The search processing unit 50a changes the parameters (search processing parameters) related to the image processing applied to the input image, repeatedly executes the search processing stored in the inspection setting storage unit 46c, and acquires a plurality of detection results. It is configured to do. The display control unit 43 is configured to be able to display a plurality of detection results acquired by the search processing unit 50a at the same time or by switching.

サーチ処理用パラメータには、フィルタ処理の有無、フィルタ処理の種別、フィルタ処理の強度のうち、いずれか1つまたは複数が含まれており、特に、画像縮小度を含むことができる。サーチ処理用パラメータには、フィルタ処理の有無、フィルタ処理の種別及びフィルタ処理の強度の全てが含まれていてもよい。サーチ処理用パラメータに含まれる項目や値は、第1のサーチ処理と第2のサーチ処理とで異なっていてもよい。 The search processing parameter includes any one or more of the presence / absence of filter processing, the type of filter processing, and the intensity of filter processing, and in particular, the degree of image reduction can be included. The search processing parameters may include all of the presence / absence of filtering processing, the type of filtering processing, and the strength of filtering processing. The items and values included in the search processing parameters may differ between the first search processing and the second search processing.

エッジベースサーチの場合、サーチ処理用パラメータには、エッジベースサーチで調整頻度の高いパラメータを含むことができ、例えば、エッジ抽出のための「画像縮小度」と、「エッジ抽出しきい値」の2つのパラメータを挙げることができる。 In the case of edge-based search, the parameters for search processing can include parameters that are frequently adjusted in edge-based search, for example, "image reduction" for edge extraction and "edge extraction threshold". There are two parameters.

図12は、サーチ処理選択部51aによって確定されたツールがエッジベースサーチの場合に、入力画像に適用される画像処理に係るパラメータを変更してサーチ処理し、その結果得られた画像を一覧表示した例であり、一覧表示用インターフェース90を示している。本例では、サーチ処理選択部51aによって確定されたツールが、第2のサーチ処理(エッジベースサーチ)としているので、図12に示す画像は、第2サーチ処理結果画像72とするが、サーチ処理選択部51aによって確定されたツールが、第1のサーチ処理(パターンサーチ)とする場合には、第1サーチ処理結果画像71を図12に示すような一覧表示形態として表示することもできる。以下、第2サーチ処理結果画像72を表示した場合について説明するが、第1サーチ処理結果画像71を表示した場合も同様である。 In FIG. 12, when the tool determined by the search processing selection unit 51a is an edge-based search, the parameters related to the image processing applied to the input image are changed and the search processing is performed, and the images obtained as a result are displayed in a list. This is an example of the above, and the list display interface 90 is shown. In this example, since the tool determined by the search process selection unit 51a is the second search process (edge-based search), the image shown in FIG. 12 is the second search process result image 72, but the search process is performed. When the tool determined by the selection unit 51a is the first search process (pattern search), the first search process result image 71 can be displayed as a list display form as shown in FIG. Hereinafter, the case where the second search processing result image 72 is displayed will be described, but the same applies to the case where the first search processing result image 71 is displayed.

図12に示す一覧表示用インターフェース90は、縦方向に並ぶ画像が「画像縮小度」を変更した画像であり、横方向に並ぶ画像が「エッジ抽出しきい値」を変更した画像となっている。8通りのパラメータ設定を行っているため、8つの第2サーチ処理結果画像72を表示しているが、これに限らず、2通り以上のパラメータ設定を行えばよく、従って、一覧表示用インターフェース90には少なくとも2つの第2サーチ処理結果画像72を表示することができる。一覧表示用インターフェース90では、表示される画像を切り替えたり、拡大して表示することもできるようになっている。 In the list display interface 90 shown in FIG. 12, the images arranged in the vertical direction are images in which the "image reduction degree" is changed, and the images arranged in the horizontal direction are images in which the "edge extraction threshold value" is changed. .. Since eight parameters are set, eight second search processing result images 72 are displayed. However, the present invention is not limited to this, and two or more parameters may be set. Therefore, the list display interface 90 is displayed. Can display at least two second search processing result images 72. In the list display interface 90, the displayed image can be switched or enlarged and displayed.

一覧表示用インターフェース90には、検出レベル調整領域90aが設けられている。検出レベル調整領域90aは、図10や図11に示す検出レベル調整領域68cと同じであり、第2サーチ処理結果画像72を一覧表示した状態で検出レベルを調整可能になっている。調整した検出レベルは、全ての第2サーチ処理結果画像72に対して適用される。 The list display interface 90 is provided with a detection level adjustment area 90a. The detection level adjustment area 90a is the same as the detection level adjustment area 68c shown in FIGS. 10 and 11, and the detection level can be adjusted while the second search processing result image 72 is displayed in a list. The adjusted detection level is applied to all the second search processing result images 72.

使用者は、一覧表示用インターフェース90に表示されている複数の第2サーチ処理結果画像72の中から任意の1つの第2サーチ処理結果画像72を選択することができる。使用者による第2サーチ処理結果画像72の選択操作は、例えば操作入力部44によって受け付けられる。例えば、使用者がモニタ5に表示された複数の第2サーチ処理結果画像72の中から「7」と表示されている画像にマウス7のポインタを合わせてクリック操作すると、当該画像の選択が完了する。 The user can select any one second search processing result image 72 from the plurality of second search processing result images 72 displayed on the list display interface 90. The selection operation of the second search processing result image 72 by the user is accepted by, for example, the operation input unit 44. For example, when the user puts the pointer of the mouse 7 on the image displayed as "7" from the plurality of second search processing result images 72 displayed on the monitor 5 and clicks the image, the selection of the image is completed. do.

尚、第2サーチ処理結果画像72の選択とは、第2サーチ処理結果画像72そのものの選択操作であってもよいし、第2サーチ処理結果画像72を囲む枠を選択する操作や、各種ボタン等による選択操作であってもよい。このような操作の検出は、例えば、マウス7のポインタ位置の検出及びクリック操作の検出により可能となる。あるいは、図12に示す一覧表示用インターフェース90の検出レベル調整領域90a内にある画像選択のドロップダウンリストから、「7」を選択しても良い。画像選択後に検出レベル調整領域90aのインターフェース内にある「終了」ボタンを押すと、検査に用いるパラメータが確定される。 The selection of the second search processing result image 72 may be an operation of selecting the second search processing result image 72 itself, an operation of selecting a frame surrounding the second search processing result image 72, and various buttons. It may be a selection operation by such as. Such an operation can be detected, for example, by detecting the pointer position of the mouse 7 and detecting the click operation. Alternatively, "7" may be selected from the image selection drop-down list in the detection level adjustment area 90a of the list display interface 90 shown in FIG. When the "End" button in the interface of the detection level adjustment area 90a is pressed after the image is selected, the parameters used for the inspection are confirmed.

例えば、図12に示す一覧表示用インターフェース90の検出レベル調整領域90a内にある「終了」ボタンの変わりに「次へ」ボタンにするなどし、始めに第1段階のパラメータ変更を行った後、変更後のパラメータに関連する第2段階のパラメータを調整する等、パラメータの変更を多階層化することにより、パラメータの詳細な設定を可能にしてもよい。多階層化された場合には、図13のような画像選択の画面が、画像選択の過程で複数回出現することになる。 For example, instead of the "End" button in the detection level adjustment area 90a of the list display interface 90 shown in FIG. 12, the "Next" button is used. By making the parameter changes multi-layered, such as adjusting the parameters of the second stage related to the changed parameters, it may be possible to set the parameters in detail. In the case of multi-layering, the image selection screen as shown in FIG. 13 appears a plurality of times in the process of image selection.

また、検出レベル調整領域90a内にある「前へ」ボタンを押すことで、1つ前の選択画面に戻る操作を受け付けるように構成することもできる。画像選択されているパラメータを維持した状態で1つ前の画面に戻ることで、好ましいパラメータに調整された状態で図10に示す画面に戻って検査ツール同士の比較を行うこともできる。 It can also be configured to accept an operation to return to the previous selection screen by pressing the "forward" button in the detection level adjustment area 90a. By returning to the previous screen while maintaining the parameters selected in the image, it is possible to return to the screen shown in FIG. 10 in a state adjusted to the preferable parameters and compare the inspection tools with each other.

図13は、パラメータ確定後に最終確認するために、選択された第2サーチ処理結果画像72を拡大表示する選択表示インターフェース91を示すものである。この選択表示インターフェース91には、パラメータ調整領域91aが設けられている。このパラメータ調整領域91aには、パラメータを個別に変更するための操作ボタン等が設けられており、使用者は、第2サーチ処理結果画像72の選択後においても必要に応じてパラメータの変更、微調整が可能である。 FIG. 13 shows a selection display interface 91 that enlarges and displays the selected second search processing result image 72 for final confirmation after the parameters are determined. The selection display interface 91 is provided with a parameter adjustment area 91a. The parameter adjustment area 91a is provided with an operation button or the like for individually changing the parameters, and the user can change or finely change the parameters as necessary even after selecting the second search processing result image 72. Adjustment is possible.

サーチ処理選択部51aで選択されたサーチ処理との組み合わせによってサーチ処理の安定性を高める画像処理を予め設定しておき、選択されたサーチ処理を行う入力画像に対して当該画像処理を自動で行うように構成することもできる。例えば、正規化相関のサーチ処理は、ワークWの細かい濃淡変化の影響をキャンセルするために、前処理フィルタとして「ぼかし処理」のような大きな範囲での平滑化フィルタと相性がよいので、正規化相関のサーチ処理では、「ぼかし処理」を入力画像に自動的に適用する。正規化相関のサーチ処理の場合、「ぼかし処理」の強度と、「画像縮小度」を変更することにより、図12に示すような複数のサーチ処理結果画像を得るのが好ましい。 Image processing that enhances the stability of the search processing by combining with the search processing selected by the search processing selection unit 51a is set in advance, and the image processing is automatically performed for the input image to be selected for the search processing. It can also be configured as follows. For example, the normalization correlation search process is compatible with a smoothing filter in a large range such as "blurring process" as a preprocessing filter in order to cancel the influence of fine shading changes of the work W, so it is normalized. In the correlation search process, "blurring process" is automatically applied to the input image. In the case of the normalization correlation search processing, it is preferable to obtain a plurality of search processing result images as shown in FIG. 12 by changing the intensity of the “blurring process” and the “image reduction degree”.

(欠陥検査部50bの構成)
欠陥検査部50bは、第1の欠陥検査処理と、第2の欠陥検査処理とを実行する部分である。第1の欠陥検査処理は、所定の閾値よりも大きな第1の欠陥検査用特徴量を有する画素の集合を、欠陥サイズ設定部47cで設定された欠陥サイズに基づいて欠陥として検出すべきか否かを判定する処理である。第2の欠陥検査処理は、所定の閾値よりも大きな第2の欠陥検査用特徴量を有する画素の集合を、欠陥サイズ設定部47cで設定された欠陥サイズに基づいて欠陥として検出すべきか否かを判定する処理である。第1の欠陥検査処理で使用する欠陥サイズと、第2の欠陥検査処理で使用する欠陥サイズとは同じである。第1の欠陥検査処理及び第2の欠陥検査処理は、撮像部3によって新たにワークWを撮像して得られた入力画像を用いて実行される。また、第1の欠陥検査用特徴量及び第2の欠陥検査用特徴量は、欠陥検査用特徴量抽出部48で抽出される。
(Structure of defect inspection unit 50b)
The defect inspection unit 50b is a portion that executes the first defect inspection process and the second defect inspection process. In the first defect inspection process, whether or not a set of pixels having a first defect inspection feature amount larger than a predetermined threshold value should be detected as a defect based on the defect size set by the defect size setting unit 47c. Is a process for determining. Whether or not the second defect inspection process should detect a set of pixels having a second defect inspection feature amount larger than a predetermined threshold value as a defect based on the defect size set by the defect size setting unit 47c. Is a process for determining. The defect size used in the first defect inspection process is the same as the defect size used in the second defect inspection process. The first defect inspection process and the second defect inspection process are executed by using the input image obtained by newly imaging the work W by the image pickup unit 3. Further, the first defect inspection feature amount and the second defect inspection feature amount are extracted by the defect inspection feature amount extraction unit 48.

第1の欠陥検査用特徴量が周辺画素との濃淡値の差である場合には、第1の欠陥検査処理は傷検査ツールとすることができる。第2の欠陥検査用特徴量が濃淡値である場合には、第2の欠陥検査処理はブロブ計測ツールとすることができる。 When the first defect inspection feature amount is the difference in shading value from the peripheral pixels, the first defect inspection process can be a scratch inspection tool. When the feature amount for the second defect inspection is a shading value, the second defect inspection process can be a blob measurement tool.

欠陥検査部50bは、第1の欠陥検査処理の処理時間と、第2の欠陥検査処理の処理時間とを取得する。すなわち、第1の欠陥検査処理を開始してから終了するまでの時間と、第2の欠陥検査処理を開始してから終了するまでの時間とをそれぞれ計測して保持または記憶部46に記憶させておくことができる。第1の欠陥検査処理と第2の欠陥検査処理とは並行して進めてもよいし、異なるタイミングで実施してもよい。 The defect inspection unit 50b acquires the processing time of the first defect inspection process and the processing time of the second defect inspection process. That is, the time from the start to the end of the first defect inspection process and the time from the start to the end of the second defect inspection process are measured and stored in the holding or storage unit 46, respectively. Can be kept. The first defect inspection process and the second defect inspection process may be performed in parallel or may be performed at different timings.

表示制御部43は、第1の欠陥検査処理により検出された欠陥領域を表示した第1欠陥検査処理画像と、第2の欠陥検査処理により検出された欠陥領域を表示した第2欠陥検査処理画像とをモニタ5に同時に表示させるように構成されている。 The display control unit 43 displays a first defect inspection processed image displaying the defect area detected by the first defect inspection process and a second defect inspection processed image displaying the defect area detected by the second defect inspection process. Is configured to be displayed on the monitor 5 at the same time.

図14に示すように、表示制御部43は、欠陥検査結果画像表示用ユーザーインターフェース78をモニタ5に表示させる。欠陥検査結果画像表示用ユーザーインターフェース78には、第1の欠陥検査処理の結果得られた画素の集合の位置を表示した第1欠陥検査処理画像81が表示される第1画像表示領域78aと、第2の欠陥検査処理の結果得られた画素の集合の位置を表示した第2欠陥検査処理画像82が表示される第2画像表示領域78bと、検出レベル調整領域78cとが設けられている。第1欠陥検査処理画像81及び第2欠陥検査処理画像82は、入力画像に対して画素の集合の位置を重畳表示した画像である。 As shown in FIG. 14, the display control unit 43 causes the monitor 5 to display the defect inspection result image display user interface 78. The defect inspection result image display user interface 78 includes a first image display area 78a on which a first defect inspection processing image 81 displaying the position of a set of pixels obtained as a result of the first defect inspection processing is displayed. A second image display area 78b on which a second defect inspection processed image 82 displaying the position of a set of pixels obtained as a result of the second defect inspection process is displayed, and a detection level adjustment area 78c are provided. The first defect inspection processed image 81 and the second defect inspection processed image 82 are images in which the positions of a set of pixels are superimposed and displayed on the input image.

この実施形態では、第1欠陥検査処理画像81と第2欠陥検査処理画像82をモニタ5に同時に表示するようにしているが、これに限らず、第1欠陥検査処理画像81と第2欠陥検査処理画像82を切り替えてモニタ5に表示するようにしてもよい。例えば、欠陥検査結果画像表示用ユーザーインターフェース78に、画像切替手段(例:ボタン等)を設けておき、画像切替手段を使用者がマウス7等で操作することにより、第1欠陥検査処理画像81のみを表示させたり、第2欠陥検査処理画像82のみを表示させることができる。また、例えば、第1欠陥検査処理画像81及び第2欠陥検査処理画像82のそれぞれの周辺部にタブを設けておき、タブを操作することにより、第1欠陥検査処理画像81のみを表示させたり、第2欠陥検査処理画像82のみを表示させることもできる。 In this embodiment, the first defect inspection processed image 81 and the second defect inspection processed image 82 are simultaneously displayed on the monitor 5, but the present invention is not limited to this, and the first defect inspection processed image 81 and the second defect inspection are not limited to this. The processed image 82 may be switched and displayed on the monitor 5. For example, the defect inspection result image display user interface 78 is provided with an image switching means (eg, a button or the like), and the user operates the image switching means with a mouse 7 or the like to obtain a first defect inspection processed image 81. Only the second defect inspection processed image 82 can be displayed. Further, for example, tabs may be provided around each of the first defect inspection processed image 81 and the second defect inspection processed image 82, and by operating the tabs, only the first defect inspection processed image 81 may be displayed. , Only the second defect inspection processed image 82 can be displayed.

表示制御部43は、第1の欠陥検査処理により検出された欠陥領域に目印81aを付し、この目印81aを第1欠陥検査処理画像81に重畳表示するように構成されている。目印81aは、例えば+印、矢印、丸印等を挙げることができる。また、欠陥領域を囲む枠線を第1欠陥検査処理画像81に重畳表示するように構成することもできる。 The display control unit 43 is configured to attach a mark 81a to the defect area detected by the first defect inspection process and display the mark 81a superimposed on the first defect inspection process image 81. Examples of the mark 81a include a + mark, an arrow, a circle mark, and the like. Further, the frame line surrounding the defect region may be configured to be superimposed and displayed on the first defect inspection processed image 81.

さらに、表示制御部43は、第2の欠陥検査処理により検出された欠陥領域に、第1欠陥検査処理画像81の場合と同様な目印82aを付し、この目印82aを第2欠陥検査処理画像82に重畳表示するように構成されている。また、欠陥領域を囲む枠線を第2欠陥検査処理画像82に重畳表示するように構成することもできる。 Further, the display control unit 43 attaches a mark 82a similar to that in the case of the first defect inspection processed image 81 to the defect region detected by the second defect inspection process, and uses this mark 82a as the second defect inspection processed image. It is configured to be superimposed and displayed on 82. Further, the frame line surrounding the defect region may be configured to be superimposed and displayed on the second defect inspection processed image 82.

欠陥検査結果画像表示用ユーザーインターフェース78の第1画像表示領域78aには、欠陥検査部50bが取得した第1の欠陥検査処理の処理時間を表示する第1処理時間表示領域78dが設けられている。また、欠陥検査結果画像表示用ユーザーインターフェース78の第2画像表示領域78bには、欠陥検査部50bが取得した第2の欠陥検査処理の処理時間を表示する第2処理時間表示領域78fが設けられている。これにより、使用者は、第1の欠陥検査処理の処理時間と第2の欠陥検査処理の処理時間とを容易に比較することができる。 The first image display area 78a of the defect inspection result image display user interface 78 is provided with a first processing time display area 78d for displaying the processing time of the first defect inspection process acquired by the defect inspection unit 50b. .. Further, the second image display area 78b of the defect inspection result image display user interface 78 is provided with a second processing time display area 78f for displaying the processing time of the second defect inspection process acquired by the defect inspection unit 50b. ing. This allows the user to easily compare the processing time of the first defect inspection process with the processing time of the second defect inspection process.

傷検査ツールにより得られた第1欠陥検査処理画像81と、ブロブ計測ツールにより得られた第2欠陥検査処理画像82と比較すると、第1欠陥検査処理画像81の方は、傷検査ツールによりセグメント化を行って処理するため、細かいノイズへの耐性が強いが、検出される傷の大きさ(面積)が、実際の欠陥よりも大きめに検出される傾向があることが分かる。一方、ブロブ計測ツールにより得られた第2欠陥検査処理画像82の方は、検出される傷の大きさ(面積)が、実際の欠陥と同じ大きさで検出されるが、細かいノイズも検出されやすい傾向がある。また、ブロブ計測ツールの場合、検出状態に応じて処理時間が変動しやすい。 Comparing the first defect inspection processed image 81 obtained by the scratch inspection tool and the second defect inspection processed image 82 obtained by the blob measurement tool, the first defect inspection processed image 81 is segmented by the scratch inspection tool. It can be seen that the size (area) of the detected scratches tends to be larger than the actual defects, although the resistance to fine noise is strong because the processing is performed. On the other hand, in the second defect inspection processed image 82 obtained by the blob measurement tool, the detected scratch size (area) is detected to be the same size as the actual defect, but fine noise is also detected. It tends to be easy. Further, in the case of the blob measurement tool, the processing time tends to fluctuate depending on the detection state.

検出レベル調整領域78cは、検出レベル(閾値)を調整するための領域である。検出レベルは階調値とすることができ、例えば検出レベル調整領域78cに「50」と入力することで、階調値が50よりも大きな画素の集合を抽出して第1画像表示領域78a及び第2画像表示領域78bに表示させることができるようになっている。検出レベル調整領域78cに入力された検出レベルは、第1の欠陥検査処理と第2の欠陥検査処理の両方に適用される。つまり、第1の欠陥検査処理で使用される検出レベルと、第2の欠陥検査処理で使用される検出レベルとを一括して調整可能に構成されている。第1の欠陥検査処理で使用される検出レベルと、第2の欠陥検査処理で使用される検出レベルとは同じ値である。傷検査ツールを用いる第1の欠陥検査処理では、小領域(セグメント)の平均濃度値の周辺との変化量が、指定された検出レベルを超える部分を検出する。ブロブ計測ツールを用いる第2の欠陥検査処理では、画面全体の濃淡値の平均値に対して、検出レベルを超える濃度値をもった部分を検出する。 The detection level adjustment area 78c is an area for adjusting the detection level (threshold value). The detection level can be a gradation value. For example, by inputting "50" in the detection level adjustment area 78c, a set of pixels having a gradation value larger than 50 is extracted and the first image display area 78a and It can be displayed in the second image display area 78b. The detection level input to the detection level adjustment region 78c is applied to both the first defect inspection process and the second defect inspection process. That is, the detection level used in the first defect inspection process and the detection level used in the second defect inspection process can be collectively adjusted. The detection level used in the first defect inspection process and the detection level used in the second defect inspection process are the same values. In the first defect inspection process using the scratch inspection tool, a portion where the amount of change from the periphery of the average concentration value of the small region (segment) exceeds the specified detection level is detected. In the second defect inspection process using the blob measurement tool, a portion having a density value exceeding the detection level is detected with respect to the average value of the shading values of the entire screen.

例えば、図15に示すように、検出レベル調整領域78cに「30」と入力して検出レベルを下げると、表示制御部43は、検出レベル調整後の第1欠陥検査処理画像81及び第2欠陥検査処理画像82をモニタ5に表示させる。検出レベル調整後の第1欠陥検査処理画像81及び第2欠陥検査処理画像82は、同時に表示してもよいし、切り替えて表示してもよい。 For example, as shown in FIG. 15, when "30" is input to the detection level adjustment area 78c to lower the detection level, the display control unit 43 displays the first defect inspection processed image 81 and the second defect after the detection level adjustment. The inspection processing image 82 is displayed on the monitor 5. The first defect inspection processed image 81 and the second defect inspection processed image 82 after the detection level adjustment may be displayed at the same time or may be switched and displayed.

検出レベルを下げると、第1画像表示領域78a及び第2画像表示領域78bに表示される画素の集合の数が増えることになる。検出レベルを変更することで、欠陥の検出状態を調整することができ、検出レベルの違いによる検出処理の安定性を比較することができる。 When the detection level is lowered, the number of sets of pixels displayed in the first image display area 78a and the second image display area 78b increases. By changing the detection level, the defect detection state can be adjusted, and the stability of the detection process due to the difference in the detection level can be compared.

欠陥検査部50bは、項目入力部49で受け付けた共通項目を第1の欠陥検査処理及び第2の欠陥検査処理に適用する。これにより、例えば明暗指定のように、第1の欠陥検査処理及び第2の欠陥検査処理に適用する項目を複数回入力しなくて済む。 The defect inspection unit 50b applies the common items received by the item input unit 49 to the first defect inspection process and the second defect inspection process. As a result, it is not necessary to input the items applied to the first defect inspection process and the second defect inspection process a plurality of times, for example, as in the case of light / dark designation.

欠陥検査部50bは、複数の検査画像を連続的に取得して各検査画像に対して第1の欠陥検査処理と第2の欠陥検査処理とを実行する。そして、表示制御部43は、第1欠陥検査処理画像81及び第2欠陥検査処理画像82を更新するように構成されている。1回の欠陥検査処理の結果を見ただけでは、欠陥検査処理の安定性を推測するのが難しい場合があるが、異なる入力画像のそれぞれに対して第1の欠陥検査処理を実行して、複数の第1欠陥検査処理画像81を得て、モニタ5に順次表示することで、第1の欠陥検査処理の安定性を推測することができる。第2の欠陥検査処理についても同様である。複数の第1欠陥検査処理画像81及び第2欠陥検査処理画像82をモニタ5に表示させて安定性を見ることもできる。 The defect inspection unit 50b continuously acquires a plurality of inspection images and executes a first defect inspection process and a second defect inspection process on each inspection image. The display control unit 43 is configured to update the first defect inspection processed image 81 and the second defect inspection processed image 82. It may be difficult to estimate the stability of the defect inspection process just by looking at the result of one defect inspection process, but the first defect inspection process is executed for each of the different input images. By obtaining a plurality of first defect inspection processed images 81 and sequentially displaying them on the monitor 5, the stability of the first defect inspection process can be estimated. The same applies to the second defect inspection process. It is also possible to display the plurality of first defect inspection processed images 81 and the second defect inspection processed image 82 on the monitor 5 to check the stability.

(検査処理選択部51bの構成)
検査処理選択部51bは、図14に示す欠陥検査結果画像表示用ユーザーインターフェース78に第1欠陥検査処理画像81と第2欠陥検査処理画像82が表示された後に、第1の欠陥検査処理又は第2の欠陥検査処理のいずれかの選択を受け付ける部分である。具体的には、検査処理選択部51bは、表示制御部43により表示された第1欠陥検査処理画像81または第2欠陥検査処理画像82が選択されたか否かを検出し、第1欠陥検査処理画像81が選択されたことを検出した場合には第1の欠陥検査処理を選択し、第2欠陥検査処理画像82が選択されたことを検出した場合には第2の欠陥検査処理を選択するように構成されている。
(Structure of inspection process selection unit 51b)
After the first defect inspection process image 81 and the second defect inspection process image 82 are displayed on the defect inspection result image display user interface 78 shown in FIG. 14, the inspection process selection unit 51b performs the first defect inspection process or the first defect inspection process. It is a part that accepts the selection of any one of the defect inspection processes of 2. Specifically, the inspection processing selection unit 51b detects whether or not the first defect inspection processing image 81 or the second defect inspection processing image 82 displayed by the display control unit 43 is selected, and the first defect inspection processing When it is detected that the image 81 is selected, the first defect inspection process is selected, and when it is detected that the image 82 is selected, the second defect inspection process is selected. It is configured as follows.

つまり、使用者がモニタ5に表示された第1欠陥検査処理画像81を選択すると、第1の欠陥検査処理が自動的に選択され、使用者がモニタ5に表示された第2欠陥検査処理画像82を選択すると、第2の欠陥検査処理が自動的に選択される。これにより、使用者の直感的な操作によってサーチ処理を選択することができる。 That is, when the user selects the first defect inspection processed image 81 displayed on the monitor 5, the first defect inspection process is automatically selected, and the user selects the second defect inspection processed image displayed on the monitor 5. When 82 is selected, the second defect inspection process is automatically selected. As a result, the search process can be selected by the user's intuitive operation.

尚、第1欠陥検査処理画像81の選択とは、第1欠陥検査処理画像81そのものの選択操作であってもよいし、第1欠陥検査処理画像81を囲む枠を選択する操作や、各種ボタン等による選択操作であってもよい。第2欠陥検査処理画像82の選択も同様である。このような操作の検出は、例えば、マウス7のポインタ位置の検出及びクリック操作の検出により可能となる。あるいは、図14に示す欠陥検査結果画像表示用ユーザーインターフェース78の検出レベル調整領域78c内にあるツール選択のドロップダウンリストから、いずれかを選択しても良い。ツール選択後に検出レベル調整領域78cのインターフェース内にある「次へ」ボタンを押すと、検査に用いるツールが確定される。 The selection of the first defect inspection processed image 81 may be an operation of selecting the first defect inspection processed image 81 itself, an operation of selecting a frame surrounding the first defect inspection processed image 81, and various buttons. It may be a selection operation by such as. The same applies to the selection of the second defect inspection processed image 82. Such an operation can be detected, for example, by detecting the pointer position of the mouse 7 and detecting the click operation. Alternatively, one may be selected from the tool selection drop-down list in the detection level adjustment area 78c of the defect inspection result image display user interface 78 shown in FIG. When the "Next" button in the interface of the detection level adjustment area 78c is pressed after selecting the tool, the tool used for the inspection is confirmed.

(欠陥検査処理におけるパラメータ変更)
図2に示す欠陥検査部50bは、検査画像に適用される画像処理に係るパラメータ(欠陥検査用パラメータ)を変更して、検査設定記憶部46cに記憶された欠陥検査処理を繰り返し実行して複数の検出結果を取得するように構成されている。そして、表示制御部43は、欠陥検査部50bで取得された複数の検出結果を同時又は切り替えて表示可能に構成されている。
(Parameter change in defect inspection processing)
A plurality of defect inspection units 50b shown in FIG. 2 change parameters (parameters for defect inspection) related to image processing applied to inspection images, and repeatedly execute defect inspection processing stored in the inspection setting storage unit 46c. It is configured to get the detection result of. The display control unit 43 is configured to be able to display a plurality of detection results acquired by the defect inspection unit 50b at the same time or by switching.

欠陥検査用パラメータには、フィルタ処理の有無、フィルタ処理の種別、フィルタ処理の強度のうち、いずれか1つまたは複数が含まれている。欠陥検査用パラメータには、フィルタ処理の有無、フィルタ処理の種別及びフィルタ処理の強度の全てが含まれていてもよい。欠陥検査用パラメータに含まれる項目や値は、第1の欠陥検査処理と第2の欠陥検査処理とで異なっていてもよい。 The defect inspection parameter includes one or more of the presence / absence of filtering, the type of filtering, and the strength of filtering. The defect inspection parameters may include all of the presence / absence of filtering, the type of filtering, and the strength of filtering. The items and values included in the defect inspection parameters may differ between the first defect inspection process and the second defect inspection process.

傷検査ツールの場合、検査画像に適用される画像処理に係る欠陥検査用パラメータには、傷検査ツールを使用する際に調整頻度の高いパラメータや、傷検査ツールと相性のよい前処理フィルタを含むことができる。傷検査ツールを使用する際に調整頻度の高いパラメータとしては、例えば、「セグメント」のサイズがある。傷検査ツールと相性のよい前処理フィルタは、「リアルタイム濃淡補正」があり、この「リアルタイム濃淡補正」の「抽出サイズ」を欠陥検査用パラメータとすることができる。 In the case of scratch inspection tools, the image processing defect inspection parameters applied to the inspection image include parameters that are frequently adjusted when using the scratch inspection tool and pretreatment filters that are compatible with the scratch inspection tool. be able to. A parameter that is frequently adjusted when using a scratch inspection tool is, for example, the size of a "segment". A pretreatment filter that is compatible with scratch inspection tools has "real-time shading correction", and the "extraction size" of this "real-time shading correction" can be used as a parameter for defect inspection.

図16は、検査処理選択部51bによって確定されたツールが傷検査ツールの場合に、検査画像に適用される画像処理に係るパラメータを変更して欠陥検査処理して得られた画像を一覧表示した例であり、一覧表示用インターフェース93を示している。本例では、検査処理選択部51bによって確定されたツールを第1の欠陥検査処理(傷検査ツール)としているので、図16に示す画像は、第1欠陥検査処理画像81とするが、検査処理選択部51bによって確定されたツールが、第2の欠陥検査処理(ブロブ計測ツール)とする場合には、第2欠陥検査処理画像82を図16に示すような一覧表示とすることもできる。以下、第1欠陥検査処理画像81を表示した場合について説明するが、第2欠陥検査処理画像82を表示した場合も同様である。 FIG. 16 shows a list of images obtained by defect inspection processing by changing the parameters related to image processing applied to the inspection image when the tool determined by the inspection processing selection unit 51b is a scratch inspection tool. As an example, the list display interface 93 is shown. In this example, since the tool determined by the inspection process selection unit 51b is the first defect inspection process (scratch inspection tool), the image shown in FIG. 16 is the first defect inspection process image 81, but the inspection process. When the tool determined by the selection unit 51b is the second defect inspection process (blob measurement tool), the second defect inspection process image 82 can be displayed in a list as shown in FIG. Hereinafter, the case where the first defect inspection processed image 81 is displayed will be described, but the same applies to the case where the second defect inspection processed image 82 is displayed.

図16に示す一覧表示用インターフェース93は、縦方向に並ぶ画像が「セグメントサイズ」を変更した画像であり、横方向に並ぶ画像が「リアルタイム濃淡補正」の「抽出サイズ」を変更した画像となっている。8通りのパラメータ設定を行っているため、8つの第1欠陥検査処理画像81を表示しているが、これに限らず、2通り以上のパラメータ設定を行えばよく、従って、一覧表示用インターフェース93には少なくとも2つの第1欠陥検査処理画像81を表示することができる。一覧表示用インターフェース93では、表示される画像を切り替えたり、拡大して表示することもできるようになっている。 In the list display interface 93 shown in FIG. 16, the images arranged in the vertical direction are the images in which the "segment size" is changed, and the images arranged in the horizontal direction are the images in which the "extraction size" of the "real-time shading correction" is changed. ing. Since eight parameters are set, eight first defect inspection processing images 81 are displayed. However, the present invention is not limited to this, and two or more parameters may be set. Therefore, the list display interface 93 is displayed. Can display at least two first defect inspection processed images 81. In the list display interface 93, the displayed image can be switched or enlarged and displayed.

一覧表示用インターフェース93には、検出レベル調整領域93aが設けられている。検出レベル調整領域93aは、図14や図15に示す検出レベル調整領域78cと同じであり、第1欠陥検査処理画像81を一覧表示した状態で検出レベルを調整可能になっている。調整した検出レベルは、全ての第1欠陥検査処理画像81に対して適用される。 The list display interface 93 is provided with a detection level adjustment area 93a. The detection level adjustment region 93a is the same as the detection level adjustment region 78c shown in FIGS. 14 and 15, and the detection level can be adjusted while the first defect inspection processed image 81 is displayed in a list. The adjusted detection level is applied to all first defect inspection processed images 81.

使用者は、一覧表示用インターフェース93に表示されている複数の第1欠陥検査処理画像81の中から任意の1つの第1欠陥検査処理画像81を選択することができる。使用者による第1欠陥検査処理画像81の選択操作は、例えば操作入力部44によって受け付けられる。例えば、使用者がモニタ5に表示された複数の第1欠陥検査処理画像81の中から「2」と表示されている画像にマウス7のポインタを合わせてクリック操作すると、当該画像の選択が完了する。 The user can select any one first defect inspection processed image 81 from the plurality of first defect inspection processed images 81 displayed on the list display interface 93. The selection operation of the first defect inspection processing image 81 by the user is accepted by, for example, the operation input unit 44. For example, when the user puts the pointer of the mouse 7 on the image displayed as "2" from the plurality of first defect inspection processed images 81 displayed on the monitor 5 and clicks the image, the selection of the image is completed. do.

尚、第1欠陥検査処理画像81の選択とは、第1欠陥検査処理画像81そのものの選択操作であってもよいし、第1欠陥検査処理画像81を囲む枠を選択する操作や、各種ボタン等による選択操作であってもよい。このような操作の検出は、例えば、マウス7のポインタ位置の検出及びクリック操作の検出により可能となる。あるいは、図16に示す一覧表示用インターフェース93の検出レベル調整領域93a内にある画像選択のドロップダウンリストから、「7」を選択しても良い。画像選択後に検出レベル調整領域93aのインターフェース内にある「終了」ボタンを押すと、検査に用いるパラメータが確定される。 The selection of the first defect inspection processed image 81 may be an operation of selecting the first defect inspection processed image 81 itself, an operation of selecting a frame surrounding the first defect inspection processed image 81, and various buttons. It may be a selection operation by such as. Such an operation can be detected, for example, by detecting the pointer position of the mouse 7 and detecting the click operation. Alternatively, "7" may be selected from the image selection drop-down list in the detection level adjustment area 93a of the list display interface 93 shown in FIG. When the "End" button in the interface of the detection level adjustment area 93a is pressed after the image is selected, the parameters used for the inspection are confirmed.

例えば、検出レベル調整領域93a内にある「終了」ボタンの変わりに「次へ」ボタンを配置するなどし、始めに第1段階のパラメータ変更を行った後、変更後のパラメータに関連する第2段階のパラメータを調整する等、パラメータの変更を多階層化することにより、パラメータの詳細な設定を可能にしてもよい。 For example, by arranging the "Next" button instead of the "End" button in the detection level adjustment area 93a, the first stage parameter change is performed first, and then the second parameter related to the changed parameter is changed. Detailed setting of parameters may be made possible by making the parameter changes into multiple layers, such as adjusting the parameters of the stage.

多階層化された場合には、図16のような画像選択の画面が、画像選択の過程で複数回出現することになる。また、検出レベル調整領域93aのインターフェース内にある「前へ」ボタンを押すことで、1つ前の選択画面に戻る操作を受け付けるように構成することもできる。画像選択されているパラメータを維持した状態で1つ前の画面に戻ることで、好ましいパラメータに調整された状態で図14の画面に戻って検査ツール同士の比較を行うこともできる。 In the case of multi-layering, the image selection screen as shown in FIG. 16 appears a plurality of times in the process of image selection. It can also be configured to accept an operation to return to the previous selection screen by pressing the "forward" button in the interface of the detection level adjustment area 93a. By returning to the previous screen while maintaining the parameters selected in the image, it is possible to return to the screen of FIG. 14 and compare the inspection tools with the parameters adjusted to the preferable parameters.

図17は、パラメータ確定後に最終確認するために、選択された第1欠陥検査処理画像81を拡大表示する選択表示インターフェース94を示すものである。この選択表示インターフェース94には、パラメータ調整領域94aが設けられている。このパラメータ調整領域94aには、パラメータを個別に変更するための操作ボタン等が設けられており、使用者は、第1欠陥検査処理画像81の選択後においても必要に応じてパラメータの変更、微調整が可能である。 FIG. 17 shows a selection display interface 94 that enlarges and displays the selected first defect inspection processed image 81 for final confirmation after the parameters are determined. The selection display interface 94 is provided with a parameter adjustment area 94a. The parameter adjustment area 94a is provided with an operation button or the like for individually changing the parameters, and the user can change or finely change the parameters as necessary even after selecting the first defect inspection processing image 81. Adjustment is possible.

検査処理選択部51bで選択された欠陥検査処理との組み合わせによって欠陥検査処理の安定性を高める画像処理を予め設定しておき、選択された欠陥検査処理を行う検査画像に対して当該画像処理を自動で行うように構成することもできる。 An image process that enhances the stability of the defect inspection process by combining with the defect inspection process selected by the inspection process selection unit 51b is set in advance, and the image process is applied to the selected inspection image to be subjected to the defect inspection process. It can also be configured to do so automatically.

例えば、傷検査ツールのアルゴリズムは、周辺との差分を検出する処理のため、単体のアルゴリズム自体は、周辺に対して白い傷も、黒い傷も両方検出してしまい、明暗の選別機能がない。これに対し、前処理フィルタとして搭載している「リアルタイム濃淡補正」は、周辺に対して明るい部分や、暗い部分の明暗の選別機能があるため、「リアルタイム濃淡補正」を傷検査ツールと組み合わせて使うことで、傷検査ツールに、明暗の選別機能を加えることができる。使用者に事前に入力してもらう欠陥(傷)の明暗情報に基づいて、画像検査装置1が前処理フィルタのパラメータを適切に設定することで、アルゴリズムの特性や、前処理フィルタの知識がなくても、熟練者が行うような設定を簡単に作ることができる。前処理フィルタの種別については図18に示すが、これらフィルタ以外のフィルタを搭載することもできる。図18に示すフィルタ種別表示インターフェース96には、前処理フィルタの名称を表示する前処理フィルタ表示部96aと、前処理フィルタ表示部96aに表示されている前処理フィルタの詳細設定画面を開くための詳細ボタン96bとが設けられている。前処理フィルタ表示部96aには、ドロップダウンリストが設けられており、ドロップダウンリストから前処理フィルタの選択が可能になっている。 For example, since the algorithm of the scratch inspection tool is a process of detecting the difference from the periphery, the single algorithm itself detects both white scratches and black scratches on the periphery, and has no light / dark selection function. On the other hand, the "real-time shading correction" installed as a pretreatment filter has a function to sort out the light and dark areas of bright and dark areas with respect to the surroundings, so "real-time shading correction" is combined with a scratch inspection tool. By using it, you can add a light / dark selection function to the scratch inspection tool. The image inspection device 1 appropriately sets the parameters of the preprocessing filter based on the light and dark information of the defect (scratch) that the user inputs in advance, so that there is no knowledge of the algorithm characteristics or the preprocessing filter. However, you can easily create settings that a skilled person would do. The types of pretreatment filters are shown in FIG. 18, but filters other than these filters can also be mounted. The filter type display interface 96 shown in FIG. 18 is for opening a pre-processing filter display unit 96a for displaying the name of the pre-processing filter and a detailed setting screen for the pre-processing filter displayed on the pre-processing filter display unit 96a. A detail button 96b is provided. The pre-processing filter display unit 96a is provided with a drop-down list, and the pre-processing filter can be selected from the drop-down list.

傷検査ツールのパラメータである「セグメント」のサイズは、検出したい欠陥と同程度の大きさに設定するのが、検出能力を最も引き出すことができる設定になる。使用者に事前に入力してもらう欠陥のサイズ情報に基づいて、画像検査装置1が初期値を適切に設定することで、アルゴリズムの特性を踏まえた、適切な設定を初期段階で提示することができる。 Setting the size of the "segment", which is a parameter of the scratch inspection tool, to the same size as the defect to be detected is the setting that can maximize the detection ability. By appropriately setting the initial value by the image inspection device 1 based on the defect size information input in advance by the user, it is possible to present an appropriate setting based on the characteristics of the algorithm at the initial stage. can.

ブロブ計測ツールは、単純な2値化をベースにしているため、明暗のシェーディングがかかると、2値化が安定しない。これに対し、前処理フィルタとして搭載している「リアルタイム濃淡補正」は、明暗のシェーディングを除外する効果を得られるため、「リアルタイム濃淡補正」をブロブ計測ツール組み合わせて使うことで、ブロブ計測ツールによる2値化を安定させることができる。 Since the blob measurement tool is based on simple binarization, binarization is not stable when light and dark shading is applied. On the other hand, the "real-time shading correction" installed as a pre-processing filter has the effect of excluding light and dark shading, so by using the "real-time shading correction" in combination with the blob measurement tool, the blob measurement tool can be used. The binarization can be stabilized.

また、ブロブ計測ツールは、細かいノイズにも反応してしまうデメリットがあるが、前処理フィルタとして搭載している「ぼかし処理」と組み合わせることで、ノイズ耐性を大きく上げることができる。使用者に事前に入力してもらう欠陥の明暗情報や欠陥のサイズ情報に基づいて、画像検査装置1が前処理フィルタのパラメータ初期値を適切に設定することで、前処理フィルタの知識がなくても、熟練者が行うような設定を簡単に作ることができる。 In addition, the blob measurement tool has the disadvantage of reacting to fine noise, but by combining it with the "blurring process" installed as a preprocessing filter, noise immunity can be greatly improved. The image inspection device 1 appropriately sets the parameter initial values of the preprocessing filter based on the defect light / dark information and the defect size information input in advance by the user, so that there is no knowledge of the preprocessing filter. However, it is possible to easily create settings that a skilled person would make.

また、ブロブ計測ツールでは、一定以下の面積を持つものを除外するパラメータを内部で持っているが、使用者に事前に入力してもらう欠陥のサイズ情報に基づいて、画像検査装置1が初期値を適切に設定する(例えば、指定された欠陥のサイズの半分以下の面積のものは除外するなど)ことで、使用者側でパラメータ調整せずに、適切な設定を初期段階で提示することができる。 In addition, the blob measurement tool has an internal parameter that excludes those with an area below a certain level, but the image inspection device 1 has an initial value based on the defect size information that the user inputs in advance. By setting properly (for example, excluding those with an area less than half the size of the specified defect), it is possible to present the appropriate setting at the initial stage without adjusting the parameters on the user side. can.

傷検査ツールのアルゴリズムについて、内部的に変更するパラメータとして、「検出方向」を設定するのもよい。背景模様が一様な方向に連続しているワークWに対しては、検出方向のパラメータが効きやすいからである。また、ブロブ計測ツールの場合、「リアルタイム濃淡補正」の抽出サイズと、「ぼかし処理」の強度を変更することにより、図16に示すような複数の検出結果画像を得るのが好ましい。 It is also good to set the "detection direction" as a parameter to be changed internally for the algorithm of the scratch inspection tool. This is because the parameter in the detection direction is likely to be effective for the work W in which the background pattern is continuous in a uniform direction. Further, in the case of the blob measurement tool, it is preferable to obtain a plurality of detection result images as shown in FIG. 16 by changing the extraction size of the “real-time shading correction” and the intensity of the “blurring process”.

(画像検査装置1の設定モードの説明)
次に、画像検査装置1の設定モードについて具体的に説明する。図19に示すフローチャートは、サーチ処理の設定モードの手順を示しており、使用者による所定の開始操作によってステップSA1に進み、ステップSA1では、撮像部3によりワークWを撮像して登録画像を取得する。ステップSA2では、ステップSA1で取得した登録画像64を登録画像記憶部46aに記憶するとともに、モニタ5に表示する。登録画像64の記憶及び表示後、ステップSA3に進む。ステップSA3では、図20に示すように、選択用インターフェース98を登録画像64に重畳表示する。選択用インターフェース98には、「傷検査」ボタン98aと、「サーチ」ボタン98bとが設けられており、使用者がマウス7でクリック操作することができるようになっている。図20では、「サーチ」ボタン98bがクリックされた状態を示している。
(Explanation of setting mode of image inspection device 1)
Next, the setting mode of the image inspection device 1 will be specifically described. The flowchart shown in FIG. 19 shows the procedure of the setting mode of the search process, and proceeds to step SA1 by a predetermined start operation by the user. In step SA1, the work W is imaged by the image pickup unit 3 to acquire a registered image. do. In step SA2, the registered image 64 acquired in step SA1 is stored in the registered image storage unit 46a and displayed on the monitor 5. After storing and displaying the registered image 64, the process proceeds to step SA3. In step SA3, as shown in FIG. 20, the selection interface 98 is superimposed and displayed on the registered image 64. The selection interface 98 is provided with a "scratch inspection" button 98a and a "search" button 98b so that the user can click and operate with the mouse 7. FIG. 20 shows a state in which the “search” button 98b is clicked.

図19のステップSA3では、サーチ処理が選択されたか否かを判定する。具体的には、図20に示す選択用インターフェース98の「サーチ」ボタン98bがクリックされたか否か及び「傷検査」ボタン98aがクリックされたか否かを検出し、「サーチ」ボタン98bがクリックされた場合にはYESと判定してステップSA4に進み、「傷検査」ボタン98aがクリックされた場合にはNOと判定し、後述する図21に示すフローチャートのステップSB4以降のステップを行う。 In step SA3 of FIG. 19, it is determined whether or not the search process is selected. Specifically, it is detected whether or not the "search" button 98b of the selection interface 98 shown in FIG. 20 is clicked and whether or not the "scratch inspection" button 98a is clicked, and the "search" button 98b is clicked. If the result is YES, the process proceeds to step SA4. If the “scratch inspection” button 98a is clicked, the result is determined to be NO, and the steps after step SB4 in the flowchart shown in FIG. 21 to be described later are performed.

図19に示すフローチャートのステップSA4では、サーチ処理の角度範囲の設定を受け付ける。具体的には、図9に示す共通設定項目入力欄67をモニタ5に表示させ、使用者が角度範囲入力部67aを操作することにより、サーチ処理の角度範囲を設定することができる。 In step SA4 of the flowchart shown in FIG. 19, the setting of the angle range of the search process is accepted. Specifically, the common setting item input field 67 shown in FIG. 9 is displayed on the monitor 5, and the user can operate the angle range input unit 67a to set the angle range of the search process.

サーチ処理の角度範囲の設定が終了して「OK」ボタンが押されたことを検出すると、図17に示すフローチャートのステップSA5に進み、サーチ領域の設定を受け付ける。具体的には、図6に示すようにモニタ5に表示された登録画像64上で、使用者がマウス7の操作によってサーチ領域を囲むように枠線64bを描く。これにより、サーチ領域が設定される。 When it is detected that the setting of the angle range of the search process is completed and the "OK" button is pressed, the process proceeds to step SA5 of the flowchart shown in FIG. 17, and the setting of the search area is accepted. Specifically, as shown in FIG. 6, on the registered image 64 displayed on the monitor 5, the user draws a frame line 64b so as to surround the search area by operating the mouse 7. As a result, the search area is set.

サーチ領域が設定された後、ステップSA6に進み、パターン領域の設定を受け付ける。具体的には、図6に示すようにモニタ5に表示された登録画像64上で、使用者がマウス7の操作によってサーチ対象のワークを囲むように枠線64aを描く。これにより、パターン領域が設定される。ステップSA4~SA6の順番は入れ替えることができる。 After the search area is set, the process proceeds to step SA6 to accept the setting of the pattern area. Specifically, as shown in FIG. 6, on the registered image 64 displayed on the monitor 5, the user draws a frame line 64a so as to surround the work to be searched by the operation of the mouse 7. As a result, the pattern area is set. The order of steps SA4 to SA6 can be changed.

ステップSA4~SA6を経た後、ステップSA7に進み、パターン領域内の画像から第1のサーチ処理用特徴量及び第2のサーチ処理用特徴量を抽出し、サーチ処理用特徴量記憶部46bに記憶させる。 After passing through steps SA4 to SA6, the process proceeds to step SA7, the first search processing feature amount and the second search processing feature amount are extracted from the image in the pattern region, and stored in the search processing feature amount storage unit 46b. Let me.

ステップSA7の後、ステップSA8に進み、サーチ処理部50aが第1のサーチ処理と第2のサーチ処理を実行する。この例では、第1のサーチ処理をパターンサーチとし、第2のサーチ処理をエッジベースサーチとする。 After step SA7, the process proceeds to step SA8, and the search processing unit 50a executes the first search process and the second search process. In this example, the first search process is a pattern search and the second search process is an edge-based search.

サーチ処理を実行した後、ステップSA9では、図10に示すサーチ結果画像表示用ユーザーインターフェース68をモニタ5に表示し、第1サーチ処理結果画像71及び第2サーチ処理結果画像72を当該モニタ5に表示する。 After executing the search process, in step SA9, the search result image display user interface 68 shown in FIG. 10 is displayed on the monitor 5, and the first search process result image 71 and the second search process result image 72 are displayed on the monitor 5. indicate.

第1サーチ処理結果画像71及び第2サーチ処理結果画像72をモニタ5に表示した状態で、ステップSA10に進み、検出レベル調整領域68cの検出レベルを調整する。検出レベル調整後の第1サーチ処理結果画像71及び第2サーチ処理結果画像72がモニタ5に表示される(図11参照)。このステップSA10は必要に応じて行えばよく、省略してもよい。 With the first search processing result image 71 and the second search processing result image 72 displayed on the monitor 5, the process proceeds to step SA10, and the detection level of the detection level adjustment region 68c is adjusted. The first search processing result image 71 and the second search processing result image 72 after adjusting the detection level are displayed on the monitor 5 (see FIG. 11). This step SA10 may be performed as needed or may be omitted.

その後のステップSA11では、サーチ処理選択部51aによりサーチ処理の選択を受け付ける。サーチ処理の選択後、ステップSA12に進み、選択したサーチ処理を検査設定記憶部46cに記憶させる。 In the subsequent step SA11, the search process selection unit 51a accepts the selection of the search process. After selecting the search process, the process proceeds to step SA12, and the selected search process is stored in the inspection setting storage unit 46c.

サーチ処理を記憶した後、ステップSA13に進み、サーチ処理用パラメータを変更し、ステップSA11で選択されたサーチ処理を各パラメータで実行し、複数のサーチ処理結果画像を得る。続くステップSA14では、図12に示す一覧表示用インターフェース90をモニタ5に表示し、ステップSA13のサーチ処理結果画像を当該モニタ5に表示させる。 After storing the search processing, the process proceeds to step SA13, the search processing parameters are changed, the search processing selected in step SA11 is executed for each parameter, and a plurality of search processing result images are obtained. In the following step SA14, the list display interface 90 shown in FIG. 12 is displayed on the monitor 5, and the search processing result image in step SA13 is displayed on the monitor 5.

ステップSA15では、サーチ処理用パラメータの選択を受け付ける。使用者が、一覧表示用インターフェース90上の複数のサーチ処理結果画像の中から1つのサーチ処理結果画像をマウス7等の操作によって選択すると、選択されたサーチ処理結果画像に適用されているサーチ処理用パラメータを読み込んで一旦記憶する。 In step SA15, the selection of the search processing parameter is accepted. When the user selects one search processing result image from a plurality of search processing result images on the list display interface 90 by operating the mouse 7 or the like, the search processing applied to the selected search processing result image is applied. Read the parameters and store them once.

ステップSA15で選択されたサーチ処理結果画像は、図13に示すように、選択表示インターフェース91によってモニタ5に表示される。ステップSA16では、選択表示インターフェース91のパラメータ調整領域91aの操作ボタンを操作してパラメータの変更、微調整を行う。ステップSA16は必要に応じて行えばよく、省略してもよい。 The search processing result image selected in step SA15 is displayed on the monitor 5 by the selection display interface 91 as shown in FIG. In step SA16, the operation buttons of the parameter adjustment area 91a of the selection display interface 91 are operated to change or fine-tune the parameters. Step SA16 may be performed as needed and may be omitted.

図21に示すフローチャートは、欠陥検査処理の設定モードの手順を示しており、使用者による所定の開始操作によってステップSB1に進み、ステップSB1では、撮像部3によりワークWを撮像して検査画像を取得する。ステップSB2では、ステップSB1で取得した検査画像を記憶部46に記憶するとともに、モニタ5に表示する。検査画像の記憶及び表示後、ステップSB3に進む。ステップSB3では、図22に示すように、図20と同様な選択用インターフェース98を検査画像に重畳表示する。図22では、「傷検査」ボタン98aがクリックされた状態を示している。 The flowchart shown in FIG. 21 shows the procedure of the setting mode of the defect inspection process, and proceeds to step SB1 by a predetermined start operation by the user. In step SB1, the work W is imaged by the image pickup unit 3 to obtain an inspection image. get. In step SB2, the inspection image acquired in step SB1 is stored in the storage unit 46 and displayed on the monitor 5. After storing and displaying the inspection image, the process proceeds to step SB3. In step SB3, as shown in FIG. 22, the selection interface 98 similar to that in FIG. 20 is superimposed and displayed on the inspection image. FIG. 22 shows a state in which the “scratch inspection” button 98a is clicked.

図21のステップSB3では、欠陥検査(傷検査)処理が選択されたか否かを判定する。具体的には、図22に示す選択用インターフェース98の「サーチ」ボタン98bがクリックされたか否か及び「傷検査」ボタン98aがクリックされたか否かを検出し、「傷検査」ボタン98aがクリックされた場合にはYESと判定してステップSB4に進み、「サーチ」ボタン98bがクリックされた場合にはNOと判定し、図19に示すフローチャートのステップSA4以降のステップを行う。 In step SB3 of FIG. 21, it is determined whether or not the defect inspection (scratch inspection) process is selected. Specifically, it is detected whether or not the "search" button 98b of the selection interface 98 shown in FIG. 22 and whether or not the "scratch inspection" button 98a is clicked, and the "scratch inspection" button 98a is clicked. If this is done, the result is determined to be YES, the process proceeds to step SB4, and if the "search" button 98b is clicked, the result is determined to be NO, and the steps after step SA4 in the flowchart shown in FIG. 19 are performed.

図21に示すフローチャートのステップSB4では、明暗情報の入力を受け付ける。具体的には、図8に示す共通設定項目入力欄66をモニタ5に表示させ、使用者がドロップダウンリストボタン66aを操作することにより、「白黒両方」、「白い傷のみ」、「黒い傷のみ」のうちから1つを選択することができる。 In step SB4 of the flowchart shown in FIG. 21, input of light / dark information is accepted. Specifically, the common setting item input field 66 shown in FIG. 8 is displayed on the monitor 5, and the user operates the drop-down list button 66a to "both black and white", "white scratches only", and "black scratches". You can select one from "only".

明暗情報の入力が終了して「OK」ボタンが押されたことを検出すると、図21に示すフローチャートのステップSB5に進み、検査領域の設定を受け付ける。具体的には、図7に示すようにモニタ5に表示された検査画像65上で、使用者がマウス7の操作によって検査領域を囲むように枠線65aを描く。これにより、検査領域が設定される。 When it is detected that the input of the light / dark information is completed and the "OK" button is pressed, the process proceeds to step SB5 of the flowchart shown in FIG. 21, and the setting of the inspection area is accepted. Specifically, as shown in FIG. 7, on the inspection image 65 displayed on the monitor 5, the user draws a frame line 65a so as to surround the inspection area by operating the mouse 7. As a result, the inspection area is set.

検査領域が設定された後、ステップSB6に進み、欠陥サイズの設定を受け付ける。具体的には、図7に示すようにモニタ5に表示された検査画像65上で、使用者がマウス7の操作によって欠陥部65cを囲むように枠線65bを描く。枠線65bを描く代わりに、上述した欠陥サイズの数値での入力、欠陥部位の描画による入力であってもよい。これにより、欠陥サイズが設定される。ステップSB4~SB6の順番は入れ替えることができる。 After the inspection area is set, the process proceeds to step SB6, and the defect size setting is accepted. Specifically, as shown in FIG. 7, on the inspection image 65 displayed on the monitor 5, the user draws a frame line 65b so as to surround the defective portion 65c by operating the mouse 7. Instead of drawing the frame line 65b, the input with the numerical value of the defect size described above or the input by drawing the defect portion may be performed. This sets the defect size. The order of steps SB4 to SB6 can be changed.

ステップSB4~SB6を経た後、ステップSB7に進み、検査領域内の各画像について、第1の欠陥検査用特徴量及び第2の欠陥検査用特徴量を抽出し、記憶部46に記憶させる。 After passing through steps SB4 to SB6, the process proceeds to step SB7, and for each image in the inspection area, the first defect inspection feature amount and the second defect inspection feature amount are extracted and stored in the storage unit 46.

ステップSB7の後、ステップSB8に進み、欠陥検査部50bが第1の欠陥検査処理と第2の欠陥検査処理を実行する。この例では、第1の欠陥検査処理を傷検査ツールとし、第2の欠陥検査処理をブロブ計測ツールとする。 After step SB7, the process proceeds to step SB8, and the defect inspection unit 50b executes the first defect inspection process and the second defect inspection process. In this example, the first defect inspection process is used as a scratch inspection tool, and the second defect inspection process is used as a blob measurement tool.

欠陥検査処理を実行した後、ステップSB9では、図14に示す欠陥検査結果画像表示用ユーザーインターフェース78をモニタ5に表示し、第1欠陥検査処理画像81及び第2欠陥検査処理画像82を当該モニタ5に表示する。 After executing the defect inspection process, in step SB9, the defect inspection result image display user interface 78 shown in FIG. 14 is displayed on the monitor 5, and the first defect inspection process image 81 and the second defect inspection process image 82 are displayed on the monitor. Display in 5.

第1欠陥検査処理画像81及び第2欠陥検査処理画像82をモニタ5に表示した状態で、ステップSB10に進み、検出レベル調整領域78cの検出レベルを調整する。検出レベル調整後の第1欠陥検査処理画像81及び第2欠陥検査処理画像82がモニタ5に表示される(図15参照)。このステップSB10は必要に応じて行えばよく、省略してもよい。 With the first defect inspection processed image 81 and the second defect inspection processed image 82 displayed on the monitor 5, the process proceeds to step SB10, and the detection level of the detection level adjustment region 78c is adjusted. The first defect inspection processed image 81 and the second defect inspection processed image 82 after adjusting the detection level are displayed on the monitor 5 (see FIG. 15). This step SB10 may be performed as needed or may be omitted.

その後のステップSB11では、検査処理選択部51bにより欠陥検査処理の選択を受け付ける。欠陥検査処理の選択後、ステップSB12に進み、選択した欠陥検査処理を検査設定記憶部46cに記憶させる。 In the subsequent step SB11, the inspection process selection unit 51b accepts the selection of the defect inspection process. After selecting the defect inspection process, the process proceeds to step SB12, and the selected defect inspection process is stored in the inspection setting storage unit 46c.

欠陥検査処理を記憶した後、ステップSB13に進み、欠陥検査用パラメータを変更し、ステップSB11で選択された欠陥検査処理を各パラメータで実行し、複数の欠陥検査処理画像を得る。続くステップSB14では、図16に示す一覧表示用インターフェース93をモニタ5に表示し、ステップSB13の欠陥検査処理画像を当該モニタ5に表示させる。 After storing the defect inspection process, the process proceeds to step SB13, the parameter for defect inspection is changed, the defect inspection process selected in step SB11 is executed for each parameter, and a plurality of defect inspection processing images are obtained. In the subsequent step SB14, the list display interface 93 shown in FIG. 16 is displayed on the monitor 5, and the defect inspection processed image of the step SB13 is displayed on the monitor 5.

ステップSB15では、欠陥検査用パラメータの選択を受け付ける。使用者が、一覧表示用インターフェース93上の複数の欠陥検査処理画像の中から1つの欠陥検査処理画像をマウス7等の操作によって選択すると、選択された欠陥検査処理画像に適用されている欠陥検査用パラメータを読み込んで一旦記憶する。 In step SB15, the selection of the defect inspection parameter is accepted. When the user selects one defect inspection processed image from a plurality of defect inspection processed images on the list display interface 93 by operating the mouse 7 or the like, the defect inspection applied to the selected defect inspection processed image is applied. Read the parameters and store them once.

ステップSB15で選択された欠陥検査処理画像は、図17に示すように、選択表示インターフェース94によってモニタ5に表示される。ステップSB16では、選択表示インターフェース94のパラメータ調整領域94aの操作ボタンを操作してパラメータの変更、微調整を行う。ステップSB16は必要に応じて行えばよく、省略してもよい。 The defect inspection processed image selected in step SB15 is displayed on the monitor 5 by the selection display interface 94 as shown in FIG. In step SB16, the operation buttons in the parameter adjustment area 94a of the selection display interface 94 are operated to change or fine-tune the parameters. Step SB16 may be performed as needed and may be omitted.

(実施形態の作用効果)
以上説明したように、この実施形態に係る画像検査装置1によれば、サーチ処理に用いるパターン領域内の画像から抽出された第1のサーチ処理用特徴量を用いた第1のサーチ処理の結果得られた第1サーチ処理結果画像と、第2のサーチ処理用特徴量を用いた第2のサーチ処理の結果得られた第2サーチ処理結果画像をモニタ5に表示させて簡単に検出状態を比較することができるので、複数のサーチアルゴリズムについての特性やワークWとの相性を知らない使用者であっても、適切なサーチアルゴリズムを簡単に決定することができる。また、指定してもらう情報を元に、アルゴリズム特性を踏まえた適切なパラメータや、有効な前処理フィルタの組み合わせを設定することができるため、アルゴリズムの特性を知らない使用者であっても、適切なパラメータを簡単に決定することができる。
(Action and effect of the embodiment)
As described above, according to the image inspection apparatus 1 according to this embodiment, the result of the first search processing using the first search processing feature amount extracted from the image in the pattern region used for the search processing. The obtained first search processing result image and the second search processing result image obtained as a result of the second search processing using the second search processing feature amount are displayed on the monitor 5 to easily check the detection state. Since comparisons can be made, even a user who does not know the characteristics of a plurality of search algorithms and compatibility with the work W can easily determine an appropriate search algorithm. In addition, it is possible to set appropriate parameters based on the algorithm characteristics and effective preprocessing filter combinations based on the specified information, so even users who do not know the algorithm characteristics are appropriate. Parameters can be easily determined.

また、欠陥検査処理に用いる検査領域内で第1のサーチ処理用特徴量を用いた第1の欠陥検査処理の結果得られた欠陥領域を表示した第1欠陥検査処理画像と、第2のサーチ処理用特徴量を用いた第2の欠陥検査処理の結果得られた欠陥領域を表示した第2欠陥検査処理画像を表示させて簡単に検出状態を比較することができるので、複数の欠陥検査アルゴリズムについての特性や検査対象物との相性を知らない使用者であっても、適切な欠陥検査アルゴリズムを簡単に決定することができる。また、指定してもらう情報を元に、アルゴリズム特性を踏まえた適切なパラメータや、有効な前処理フィルタの組み合わせを設定することが出来るため、アルゴリズムの特性を知らない使用者であっても、適切なパラメータを簡単に決定することができる。 Further, a first defect inspection processed image showing a defect area obtained as a result of the first defect inspection process using the first search processing feature amount in the inspection area used for the defect inspection process, and a second search. Since it is possible to easily compare the detection states by displaying the second defect inspection processing image showing the defect area obtained as a result of the second defect inspection processing using the feature quantity for processing, a plurality of defect inspection algorithms. Even a user who does not know the characteristics of the image or compatibility with the inspection object can easily determine an appropriate defect inspection algorithm. In addition, it is possible to set appropriate parameters based on the algorithm characteristics and effective preprocessing filter combinations based on the specified information, so even users who do not know the algorithm characteristics are appropriate. Parameters can be easily determined.

上述の実施形態はあらゆる点で単なる例示に過ぎず、限定的に解釈してはならない。さらに、特許請求の範囲の均等範囲に属する変形や変更は、全て本発明の範囲内のものである。 The above embodiments are merely exemplary in all respects and should not be construed in a limited way. Further, all modifications and modifications belonging to the equivalent scope of the claims are within the scope of the present invention.

以上説明したように、本発明に係る画像検査装置は、例えば各種製品等のワークの外観を検査する現場で使用することができる。 As described above, the image inspection apparatus according to the present invention can be used in the field of inspecting the appearance of a work such as various products.

1 画像検査装置
2 照明部
3 撮像部
4 制御ユニット
5 モニタ
6 キーボード
7 マウス
43 表示制御部
46a 登録画像記憶部
46b サーチ処理用特徴量記憶部
46c 検査設定記憶部
47a パターン領域設定部
47b 検査領域設定部
47c 欠陥サイズ設定部
48 欠陥検査用特徴量抽出部
49 項目入力部
50a サーチ処理部
50b 欠陥検査部
51a サーチ処理選択部
51b 検査処理選択部
1 Image inspection device 2 Lighting unit 3 Imaging unit 4 Control unit 5 Monitor 6 Keyboard 7 Mouse 43 Display control unit 46a Registered image storage unit 46b Search processing feature quantity storage unit 46c Inspection setting storage unit 47a Pattern area setting unit 47b Inspection area setting Unit 47c Defect size setting unit 48 Defect inspection feature quantity extraction unit 49 Item input unit 50a Search processing unit 50b Defect inspection unit 51a Search processing selection unit 51b Inspection processing selection unit

Claims (12)

検査対象物の外観を検査する画像検査装置において、
前記検査対象物を撮像して得られた登録画像を記憶する登録画像記憶部と、
前記登録画像記憶部に記憶された前記登録画像上で、サーチ処理に用いるパターン領域を設定するパターン領域設定部と、
前記パターン領域内の画像から抽出された濃淡画像と、エッジ情報とを記憶する特徴量記憶部と、
新たに前記検査対象物を撮像して得られた入力画像に対して、前記濃淡画像と所定値以上の第1の相関値を有する第1の画像領域を検出する第1のサーチ処理である正規化相関サーチと、前記エッジ情報と所定値以上の第2の相関値を有する第2の画像領域を検出する第2のサーチ処理であるエッジベースサーチとを実行するサーチ処理部と、
前記正規化相関サーチの結果得られた第1の画像領域の位置、及び当該第1の画像領域の前記第1の相関値を表示した第1画像と、前記エッジベースサーチの結果得られた前記第2の画像領域の位置、及び当該第2の画像領域の前記第2の相関値を表示した第2画像とを、同時又は切り替えて表示可能な表示制御部と、
前記第1画像又は前記第2画像が表示された後に、前記正規化相関サーチ又は前記エッジベースサーチのいずれかの選択を受け付けるサーチ処理選択部と、
前記サーチ処理選択部により選択されたサーチ処理を検査設定として記憶する検査設定記憶部とを備える画像検査装置。
In an image inspection device that inspects the appearance of an object to be inspected,
A registered image storage unit that stores a registered image obtained by imaging the inspection object, and a registered image storage unit.
A pattern area setting unit for setting a pattern area used for search processing on the registered image stored in the registered image storage unit, and a pattern area setting unit.
A feature amount storage unit that stores a shading image extracted from an image in the pattern area and edge information , and a feature amount storage unit.
Normalization, which is a first search process for detecting a first image region having a first correlation value equal to or higher than a predetermined value with the grayscale image for an input image newly obtained by imaging the inspection object. A search processing unit that executes a normalization correlation search , an edge-based search that is a second search process for detecting a second image region having a second correlation value equal to or higher than a predetermined value with the edge information , and a search processing unit.
The position of the first image region obtained as a result of the normalized correlation search , the first image displaying the first correlation value of the first image region, and the said image obtained as a result of the edge-based search . A display control unit capable of displaying the position of the second image area and the second image displaying the second correlation value of the second image area at the same time or by switching.
A search processing selection unit that accepts selection of either the normalized correlation search or the edge-based search after the first image or the second image is displayed.
An image inspection device including an inspection setting storage unit that stores the search process selected by the search processing selection unit as inspection settings.
請求項1に記載の画像検査装置において、
前記表示制御部は、前記所定値以上の相関値を持った複数の画像領域の中で、相関値が最も高い最高相関画像領域と、前記最高相関画像領域の相関値未満の相関値を有する画像領域とを異なる表示形態で表示するように構成されている画像検査装置。
In the image inspection apparatus according to claim 1,
The display control unit has an image having a correlation value of the highest correlated image region having the highest correlation value and a correlation value less than the correlation value of the highest correlated image region among a plurality of image regions having a correlation value of a predetermined value or more. An image inspection device configured to display an area in a different display form.
請求項1または2に記載の画像検査装置において、
前記表示制御部は、前記所定値以上の相関値を持った画像領域を囲む検出枠を表示し、相関値の大きさが大きければ大きいほど前記検出枠を大きくするように構成されている画像検査装置。
In the image inspection apparatus according to claim 1 or 2.
The display control unit displays a detection frame surrounding an image area having a correlation value equal to or higher than the predetermined value, and the larger the size of the correlation value, the larger the detection frame. Device.
請求項2に記載の画像検査装置において、
前記所定値の調整が可能に構成されている画像検査装置。
In the image inspection apparatus according to claim 2,
An image inspection device configured to be able to adjust the predetermined value.
請求項1から4のいずれか1つに記載の画像検査装置において、
前記サーチ処理選択部は、前記表示制御部により表示された前記第1画像または前記第2画像が選択されたか否かを検出し、前記第1画像が選択されたことを検出した場合には前記正規化相関サーチを選択し、前記第2画像が選択されたことを検出した場合には前記エッジベースサーチを選択するように構成されている画像検査装置。
In the image inspection apparatus according to any one of claims 1 to 4.
The search processing selection unit detects whether or not the first image or the second image displayed by the display control unit has been selected, and if it detects that the first image has been selected, the search process selection unit may detect that the first image has been selected. An image inspection apparatus configured to select a normalized correlation search and select the edge-based search when it detects that the second image has been selected.
請求項1から5のいずれか1つに記載の画像検査装置において、
前記サーチ処理部は、前記正規化相関サーチの処理時間と、前記エッジベースサーチの処理時間とを取得し、
前記表示制御部は、前記サーチ処理部が取得した前記正規化相関サーチの処理時間と、前記エッジベースサーチの処理時間とを表示するように構成されている画像検査装置。
In the image inspection apparatus according to any one of claims 1 to 5.
The search processing unit acquires the processing time of the normalized correlation search and the processing time of the edge-based search .
The display control unit is an image inspection device configured to display the processing time of the normalized correlation search acquired by the search processing unit and the processing time of the edge-based search .
請求項1から6のいずれか1つに記載の画像検査装置において、
前記サーチ処理部は、複数の前記入力画像を連続的に取得して前記各入力画像に対して前記正規化相関サーチと前記エッジベースサーチとを実行し、
前記表示制御部は、前記第1画像及び前記第2画像を更新するように構成されている画像検査装置。
In the image inspection apparatus according to any one of claims 1 to 6.
The search processing unit continuously acquires a plurality of the input images and executes the normalized correlation search and the edge-based search on each of the input images.
The display control unit is an image inspection device configured to update the first image and the second image.
請求項1から7のいずれか1つに記載の画像検査装置において、
前記正規化相関サーチ及び前記エッジベースサーチの共通設定項目を入力する項目入力部を備え、
前記サーチ処理部は、前記項目入力部で入力された共通設定項目を前記正規化相関サーチ及び前記エッジベースサーチに適用するように構成されている画像検査装置。
In the image inspection apparatus according to any one of claims 1 to 7.
It is provided with an item input unit for inputting common setting items of the normalized correlation search and the edge-based search .
The search processing unit is an image inspection device configured to apply the common setting items input by the item input unit to the normalized correlation search and the edge-based search .
請求項8に記載の画像検査装置において、
前記共通設定項目は、サーチ処理を行う角度範囲である画像検査装置。
In the image inspection apparatus according to claim 8,
The common setting item is an image inspection device that is an angle range for performing search processing.
請求項1から9のいずれか1つに記載の画像検査装置において、
前記サーチ処理部は、前記入力画像に適用される画像処理に係るパラメータを変更して、前記検査設定記憶部に記憶されたサーチ処理を繰り返し実行して複数の検出結果を取得するように構成され、
前記表示制御部は、前記サーチ処理部で取得された複数の検出結果を同時又は切り替えて表示可能に構成されている画像検査装置。
In the image inspection apparatus according to any one of claims 1 to 9.
The search processing unit is configured to change parameters related to image processing applied to the input image, repeatedly execute the search processing stored in the inspection setting storage unit, and acquire a plurality of detection results. ,
The display control unit is an image inspection device configured to be capable of displaying a plurality of detection results acquired by the search processing unit at the same time or by switching.
請求項10に記載の画像検査装置において、
前記パラメータには、フィルタ処理の有無、フィルタ処理の種別、フィルタ処理の強度のうち、いずれか1つが含まれている画像検査装置。
In the image inspection apparatus according to claim 10,
The image inspection apparatus includes any one of the presence / absence of filtering, the type of filtering, and the intensity of filtering in the parameters.
請求項10または11に記載の画像検査装置において、
前記パラメータには、画像縮小度が含まれている画像検査装置。
In the image inspection apparatus according to claim 10 or 11.
An image inspection device whose parameters include the degree of image reduction.
JP2018137839A 2018-07-23 2018-07-23 Image inspection equipment Active JP7080123B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2018137839A JP7080123B2 (en) 2018-07-23 2018-07-23 Image inspection equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2018137839A JP7080123B2 (en) 2018-07-23 2018-07-23 Image inspection equipment

Publications (2)

Publication Number Publication Date
JP2020016948A JP2020016948A (en) 2020-01-30
JP7080123B2 true JP7080123B2 (en) 2022-06-03

Family

ID=69581773

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2018137839A Active JP7080123B2 (en) 2018-07-23 2018-07-23 Image inspection equipment

Country Status (1)

Country Link
JP (1) JP7080123B2 (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000155011A (en) 1998-11-19 2000-06-06 Hitachi Ltd Position measuring method and device
JP2005321237A (en) 2004-05-07 2005-11-17 Hitachi High-Technologies Corp Pattern inspection method and pattern inspection device
JP2014082326A (en) 2012-10-16 2014-05-08 Hitachi High-Technologies Corp Charged particle beam device
WO2014112652A1 (en) 2013-01-16 2014-07-24 住友化学株式会社 Image generation device, defect inspection device, and defect inspection method
JP2018049655A (en) 2015-09-08 2018-03-29 日本電気株式会社 Face recognition device, face recognition method, face recognition program, display control device, display control method, and display control program

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000155011A (en) 1998-11-19 2000-06-06 Hitachi Ltd Position measuring method and device
JP2005321237A (en) 2004-05-07 2005-11-17 Hitachi High-Technologies Corp Pattern inspection method and pattern inspection device
JP2014082326A (en) 2012-10-16 2014-05-08 Hitachi High-Technologies Corp Charged particle beam device
WO2014112652A1 (en) 2013-01-16 2014-07-24 住友化学株式会社 Image generation device, defect inspection device, and defect inspection method
JP2018049655A (en) 2015-09-08 2018-03-29 日本電気株式会社 Face recognition device, face recognition method, face recognition program, display control device, display control method, and display control program

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
小屋 裕太郎,画像処理を用いた経編ニット製品の欠陥検出,計測自動制御学会論文集 第49巻 第8号,日本,公益社団法人計測自動制御学会,2013年08月31日,Vol.49, No.8,P.737-746

Also Published As

Publication number Publication date
JP2020016948A (en) 2020-01-30

Similar Documents

Publication Publication Date Title
JP6630545B2 (en) Positioning method, positioning device, program, and computer-readable recording medium
JP6745173B2 (en) Image inspection apparatus, image inspection method, image inspection program, computer-readable recording medium, and recorded device
US10489900B2 (en) Inspection apparatus, inspection method, and program
JP6917781B2 (en) Image inspection equipment
JP2020187657A (en) Image inspection device
JP6608682B2 (en) Positioning method, appearance inspection apparatus, program, computer-readable recording medium, and appearance inspection method
JP5564349B2 (en) Image processing apparatus and appearance inspection method
JP2021177186A (en) Three-dimensional image processing device and three-dimensional image processing method
JP7349816B2 (en) Image inspection device
US20050207655A1 (en) Inspection system and method for providing feedback
JP2018204994A (en) Image inspection device
JP2018205002A (en) Image inspection device
JP2023090819A (en) Image inspection device and method for setting image inspection device
JP6917780B2 (en) Image inspection equipment
JP3235387B2 (en) Lighting condition setting support apparatus and method
JP2020016471A (en) Image inspection device
JP7080123B2 (en) Image inspection equipment
JP5960433B2 (en) Image processing apparatus and image processing method
JP2008241424A (en) Image processing apparatus and method using the same
JP2020169961A (en) Image inspection system and image inspection method
JP7308656B2 (en) Image inspection device
JP5921190B2 (en) Image processing apparatus and image processing method
JP2018205000A (en) Image inspection device
JP2018204995A (en) Image inspection device
JP6979860B2 (en) Image processing system

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20210329

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20220222

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

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20220524

R150 Certificate of patent or registration of utility model

Ref document number: 7080123

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150