JP2024033867A - Surface inspection device and surface inspection method - Google Patents

Surface inspection device and surface inspection method Download PDF

Info

Publication number
JP2024033867A
JP2024033867A JP2022137749A JP2022137749A JP2024033867A JP 2024033867 A JP2024033867 A JP 2024033867A JP 2022137749 A JP2022137749 A JP 2022137749A JP 2022137749 A JP2022137749 A JP 2022137749A JP 2024033867 A JP2024033867 A JP 2024033867A
Authority
JP
Japan
Prior art keywords
pixel
rotation center
specifying
cutting tool
surface inspection
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2022137749A
Other languages
Japanese (ja)
Inventor
雄貴 石田
Original Assignee
株式会社トヨタプロダクションエンジニアリング
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 株式会社トヨタプロダクションエンジニアリング filed Critical 株式会社トヨタプロダクションエンジニアリング
Priority to JP2022137749A priority Critical patent/JP2024033867A/en
Publication of JP2024033867A publication Critical patent/JP2024033867A/en
Pending legal-status Critical Current

Links

Images

Landscapes

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

Abstract

【課題】フライス加工による平面出しを行う場合に、加工表面に生じた加工痕の影響を低減しつつ、加工表面の打痕等の傷を検出することを課題とする。【解決手段】表面検査装置10は、撮像部20により物体100の表面Sを撮像した物体表面画像101及び回転中心画像データ14aに基づいて、物体表面画像101の任意点Pnから回転半径r±許容誤差δの範囲内に回転中心VCiが存在するか否かを検索し、存在する場合には、任意点Pnから回転中心VCiへのベクトル方向を特定し、任意点Pnの方向ベクトルを算定する。そして、任意点Pnにおける加工痕SMに起因する明度勾配角度を算出し、明度勾配角度と方向ベクトルのベクトル角度が所定の範囲内の場合に、任意点Pnの画素値を補正し周囲の平均値となるように構成した。【選択図】図1An object of the present invention is to detect flaws such as dents on a machined surface while reducing the influence of machining marks generated on the machined surface when flattening is performed by milling. A surface inspection device 10 detects a rotation radius r±permissible from an arbitrary point Pn of an object surface image 101 based on an object surface image 101 obtained by capturing a surface S of an object 100 by an imaging unit 20 and rotation center image data 14a. It is searched whether or not the rotation center VCi exists within the range of the error δ, and if it exists, the vector direction from the arbitrary point Pn to the rotation center VCi is specified, and the direction vector of the arbitrary point Pn is calculated. Then, the brightness gradient angle caused by the machining mark SM at the arbitrary point Pn is calculated, and if the brightness gradient angle and the vector angle of the direction vector are within a predetermined range, the pixel value of the arbitrary point Pn is corrected to the surrounding average value. It was configured so that [Selection diagram] Figure 1

Description

本発明は、フライス加工による平面出しを行う場合に、加工表面に生じた加工痕の影響を低減しつつ、加工表面の打痕等の傷を検出することができる表面検査装置及び表面検査方法に関する。 The present invention relates to a surface inspection device and a surface inspection method that can detect scratches such as dents on a machined surface while reducing the influence of machining marks generated on the machined surface when flattening by milling. .

従来、物体の表面に存在する傷を研削痕と分離して検出する表面検査方法が知られている。例えば、特許文献1には、物体表面を撮像した画像の画素ごとに、X軸方向の微分値とY軸方向の微分値を成分とするベクトルを算出し、各画素のベクトルのX軸に対する角度の度数を計測して度数の高い角度に直角な方向を研削痕の延伸方向であると特定し、画像データの各画素のうちの度数の高い角度のベクトルの画素の輝度値を弱める補正を行うか、又は、度数の高くない角度のベクトルの画素の輝度値を高める補正を行う技術が開示されている。 Conventionally, a surface inspection method is known in which flaws existing on the surface of an object are detected separately from grinding marks. For example, in Patent Document 1, for each pixel of an image taken of an object surface, a vector whose components are a differential value in the X-axis direction and a differential value in the Y-axis direction is calculated, and the angle of the vector of each pixel with respect to the X-axis is calculated. Measures the frequency of the angle, identifies the direction perpendicular to the angle with the high frequency as the direction in which the grinding marks extend, and performs correction to weaken the brightness value of the pixel of the vector of the angle with the high frequency among each pixel of the image data. Alternatively, a technique has been disclosed that performs correction to increase the brightness value of a pixel of a vector at an angle that is not high in degree.

特開2012-008018号公報Japanese Patent Application Publication No. 2012-008018

しかしながら、上記特許文献1のものは、各画素のベクトルの角度の度数が高くなったならば、この画素が研削痕ではなく傷に起因するものであったとしても、研削痕の延伸方向であると特定されてしまい輝度値が補正されてしまう。その結果、研削痕以外の傷が研削痕とみなして除去されるという問題点が生ずる。 However, in Patent Document 1, if the degree of the angle of the vector of each pixel becomes high, even if this pixel is caused by a scratch rather than a grinding mark, it is in the extending direction of the grinding mark. , and the brightness value is corrected. As a result, a problem arises in that scratches other than grinding marks are treated as grinding marks and removed.

本発明は、上記の問題点(課題)を解決するためになされたものであり、フライス加工による平面出しを行う場合に、加工表面に生じた加工痕の影響を低減しつつ、加工表面の打痕等の傷を検出することができる表面検査装置及び表面検査方法を提供することを目的とする。 The present invention has been made in order to solve the above-mentioned problems (issues), and when flattening by milling, reduces the influence of machining marks generated on the machined surface, and also reduces the impact of the machining marks on the machined surface. It is an object of the present invention to provide a surface inspection device and a surface inspection method that can detect flaws such as marks.

上述した課題を解決し、目的を達成するため、本発明は、所定の回転軸に取り付けた切削工具を回転させつつ切削加工した物体の表面を撮像する撮像部により撮像された物体表面画像を用いて所定の物体の表面の検査を行う表面検査装置における表面検査方法であって、前記物体表面画像を形成する任意の第1の画素に対して影響を及ぼす前記切削工具の回転中心の移動軌跡上の第2の画素を特定する第1の特定工程と、前記第1の画素における複数の明度勾配のうち、前記切削工具の回転中心の移動軌跡上の第2の画素への方向ベクトルの明度勾配を特定する第2の特定工程と、前記第2の特定工程により特定された勾配角度に基づいて、前記物体表面画像を形成する各画素の画素値を補正する補正工程とを含むことを特徴とする。 In order to solve the above-mentioned problems and achieve the purpose, the present invention uses an object surface image captured by an imaging unit that captures an image of the surface of a cut object while rotating a cutting tool attached to a predetermined rotation axis. A surface inspection method in a surface inspection apparatus that inspects the surface of a predetermined object using a method, wherein the method includes: a method for inspecting a surface of a predetermined object; a first identifying step of identifying a second pixel of the first pixel; and a brightness gradient of a direction vector to a second pixel on the movement locus of the rotation center of the cutting tool among the plurality of brightness gradients in the first pixel. and a correction step of correcting the pixel value of each pixel forming the object surface image based on the gradient angle specified in the second specifying step. do.

また、本発明は、上記発明において、前記補正工程により前記物体表面画像が補正された補正画像に基づいて、前記物体の表面に形成された前記加工痕以外に起因する傷の検査を行う検査工程をさらに含むことを特徴とする。 Further, in the above invention, the present invention provides an inspection step of inspecting flaws caused by other than the machining marks formed on the surface of the object based on a corrected image in which the object surface image is corrected in the correction step. It is characterized by further including.

また、本発明は、上記発明において、前記切削工具は、所定の回転体の円周上に複数の刃が取り付けられ、前記所定の回転軸を中心として回転可能に形成された正面フライス又は物体の表面を研磨する研磨ブラシであることを特徴とする。 Further, in the above invention, the present invention provides a face milling cutter having a plurality of blades attached on the circumference of a predetermined rotating body and rotatable about the predetermined rotation axis, or a face milling cutter or an object cutting tool. It is characterized by being an abrasive brush that polishes the surface.

また、本発明は、上記発明において、前記第1の特定工程は、前記切削工具の回転中心の移動軌跡をなす画素に対して所定の画素値が付与された移動軌跡画像を用いて、前記物体表面画像を形成する第1の画素に対して影響を及ぼす前記切削工具の回転中心の移動軌跡上の前記第2の画素を特定することを特徴とする。 Further, in the above-mentioned invention, the present invention provides that the first identifying step uses a movement trajectory image in which a predetermined pixel value is assigned to a pixel forming a movement trajectory of the rotation center of the cutting tool. The present invention is characterized in that the second pixel on the movement locus of the rotation center of the cutting tool that affects the first pixel forming the surface image is specified.

また、本発明は、上記発明において、前記補正工程は、前記第2の特定工程により特定された明度勾配の勾配角度をなす前記物体表面画像上の第1の画素の画素値を補正することを特徴とする。 Further, in the above invention, the present invention provides that the correction step corrects the pixel value of the first pixel on the object surface image that forms the gradient angle of the brightness gradient specified in the second specifying step. Features.

また、本発明は、上記発明において、前記補正工程は、前記第2の特定工程により特定された明度勾配の勾配角度をなす前記物体表面画像上の第1の画素の画素値を下げることを特徴とする。 Further, in the above invention, the present invention is characterized in that the correction step lowers the pixel value of the first pixel on the object surface image that forms the gradient angle of the brightness gradient specified in the second specifying step. shall be.

また、本発明は、所定の回転軸に取り付けた切削工具を回転させつつ切削加工した物体の表面を撮像する撮像部により撮像された物体表面画像を用いて所定の物体の表面の検査を行う表面検査装置における表面検査方法であって、前記切削工具の回転中心の移動軌跡上の第2の画素が影響を及ぼす第1の画素を特定する第1の特定工程と、前記第1の特定工程により特定された前記第1の画素における複数の明度勾配のうち、該第1の画素から前記第2の画素への方向の明度勾配の勾配角度を特定する第2の特定工程と、前記第2の特定工程により特定された勾配角度に基づいて、前記物体表面画像を形成する各画素の画素値を補正する補正工程とを含むことを特徴とする。 The present invention also provides a surface inspection method for inspecting the surface of a predetermined object using an object surface image captured by an imaging unit that captures an image of the surface of the cut object while rotating a cutting tool attached to a predetermined rotating shaft. A surface inspection method in an inspection device, comprising: a first specifying step of specifying a first pixel affected by a second pixel on a movement locus of a rotation center of the cutting tool; and the first specifying step. a second specifying step of specifying a gradient angle of a brightness gradient in a direction from the first pixel to the second pixel among the plurality of brightness gradients in the specified first pixel; The present invention is characterized in that it includes a correction step of correcting the pixel value of each pixel forming the object surface image based on the gradient angle specified in the specifying step.

また、本発明は、所定の回転軸に取り付けた切削工具を回転させつつ切削加工した物体の表面を撮像する撮像部により撮像された物体表面画像を用いて所定の物体の表面の検査を行う表面検査装置であって、前記物体表面画像を形成する任意の第1の画素に対して影響を及ぼす前記切削工具の回転中心の移動軌跡上の第2の画素を特定する第1の特定手段と、前記第1の特定手段により特定された前記第1の画素における複数の明度勾配のうち、該第1の画素から前記第2の画素への方向の明度勾配の勾配角度を特定する第2の特定手段と、前記第2の特定手段により特定された勾配角度に基づいて、前記物体表面画像を形成する各画素の画素値を補正する補正手段とを備えたことを特徴とする The present invention also provides a surface inspection method for inspecting the surface of a predetermined object using an object surface image captured by an imaging unit that captures an image of the surface of the cut object while rotating a cutting tool attached to a predetermined rotating shaft. an inspection device, a first specifying means for specifying a second pixel on a movement locus of the rotation center of the cutting tool that affects an arbitrary first pixel forming the object surface image; a second specification for specifying a gradient angle of a brightness gradient in a direction from the first pixel to the second pixel among the plurality of brightness gradients in the first pixel specified by the first specifying means; and a correction means for correcting the pixel value of each pixel forming the object surface image based on the gradient angle specified by the second specifying means.

また、本発明は、所定の回転軸に取り付けた切削工具を回転させつつ切削加工した物体の表面を撮像する撮像部により撮像された物体表面画像を用いて所定の物体の表面の検査を行う表面検査装置における表面検査装置であって、前記切削工具の回転中心の移動軌跡上の第2の画素が影響を及ぼす第1の画素を特定する第1の特定手段と、前記第1の特定手段により特定された前記第1の画素における複数の明度勾配のうち、該第1の画素から前記第2の画素への方向の明度勾配の勾配角度を特定する第2の特定手段と、前記第2の特定手段により特定された勾配角度に基づいて、前記物体表面画像を形成する各画素の画素値を補正する補正手段とを備えたことを特徴とする。 The present invention also provides a surface inspection method for inspecting the surface of a predetermined object using an object surface image captured by an imaging unit that captures an image of the surface of the cut object while rotating a cutting tool attached to a predetermined rotating shaft. A surface inspection device in an inspection device, comprising a first specifying means for specifying a first pixel affected by a second pixel on a movement locus of a rotation center of the cutting tool, and the first specifying means. a second specifying means for specifying a gradient angle of a brightness gradient in a direction from the first pixel to the second pixel among the plurality of brightness gradients in the specified first pixel; The present invention is characterized by comprising a correction means for correcting the pixel value of each pixel forming the object surface image based on the gradient angle specified by the specifying means.

本発明によれば、フライス加工による平面出しを行う場合に、加工表面に生じた加工痕の影響を低減しつつ、加工表面の打痕等の傷を検出することができる。 According to the present invention, when performing planarization by milling, it is possible to detect flaws such as dents on the machined surface while reducing the influence of processing marks generated on the machined surface.

図1は、実施形態1に係る表面検査装置の構成を示す機能ブロック図である。FIG. 1 is a functional block diagram showing the configuration of a surface inspection apparatus according to the first embodiment. 図2は、任意点Pnから回転中心を特定する処理を説明するための説明図である。FIG. 2 is an explanatory diagram for explaining the process of specifying the rotation center from an arbitrary point Pn. 図3は、方向ベクトルの算定を説明するための説明図である。FIG. 3 is an explanatory diagram for explaining calculation of a direction vector. 図4は、図1に示した表面検査装置の処理手順を示すフローチャートである。FIG. 4 is a flowchart showing the processing procedure of the surface inspection apparatus shown in FIG. 図5は、図4に示した補正処理の処理手順を示すフローチャートである。FIG. 5 is a flowchart showing the processing procedure of the correction process shown in FIG. 図6は、図1に示した表面検査装置の物体表面画像及び処理済画像の一例を示す図である。FIG. 6 is a diagram showing an example of an object surface image and a processed image of the surface inspection apparatus shown in FIG. 1. 図7は、実施形態2に係る表面検査装置の構成を示す機能ブロック図である。FIG. 7 is a functional block diagram showing the configuration of a surface inspection device according to the second embodiment. 図8は、回転中心から任意点の座標を特定する処理について説明する説明図である。FIG. 8 is an explanatory diagram illustrating the process of specifying the coordinates of an arbitrary point from the center of rotation. 図9は、方向ベクトルの算定を説明するための説明図である。FIG. 9 is an explanatory diagram for explaining calculation of a direction vector. 図10は、図7に示した表面検査装置の処理手順を示すフローチャートである。FIG. 10 is a flowchart showing the processing procedure of the surface inspection apparatus shown in FIG.

以下に、本発明に係る表面検査装置及び表面検査方法の実施形態を図面に基づいて詳細に説明する。本実施形態では、円周端の複数の位置に刃を取り付けた回転体を、回転軸を中心として回転させる切削工具を用いて、物体の正面フライスを行う場合について説明する。 DESCRIPTION OF EMBODIMENTS Below, embodiments of a surface inspection apparatus and a surface inspection method according to the present invention will be described in detail based on the drawings. In this embodiment, a case will be described in which face milling of an object is performed using a cutting tool that rotates a rotating body having blades attached at a plurality of positions on the circumferential edge around a rotation axis.

[実施形態1]
<表面検査装置10の構成>
まず、本実施形態1に係る表面検査装置10の構成について説明する。図1は、実施形態1に係る表面検査装置10の構成を示す機能ブロック図である。図1に示すように、表面検査装置10は、表示部11、入力部12、記憶部14、制御部15及び撮像部20を有する。
[Embodiment 1]
<Configuration of surface inspection device 10>
First, the configuration of the surface inspection apparatus 10 according to the first embodiment will be described. FIG. 1 is a functional block diagram showing the configuration of a surface inspection apparatus 10 according to the first embodiment. As shown in FIG. 1, the surface inspection apparatus 10 includes a display section 11, an input section 12, a storage section 14, a control section 15, and an imaging section 20.

表示部11は、各種情報を表示する液晶ディスプレイなどの表示デバイスである。入力部12は、マウスやキーボードなどの入力デバイスである。 The display unit 11 is a display device such as a liquid crystal display that displays various information. The input unit 12 is an input device such as a mouse or a keyboard.

記憶部14は、ハードディスク装置や不揮発性メモリなどの記憶デバイスであり、回転中心画像データ14aと、画像データ14bとを記憶する。回転中心画像データ14aは、切削工具の回転中心VCiの座標と、該切削工具の回転中心VCiの軌跡である回転中心軌跡Lとを示す画像データである。画像データ14bは、撮像部20で物体100の表面を撮像した画像データである。なお、回転中心画像データ14a内の画素と、画像データ14bの画素とは、物体表面の同じ位置を指すように対応付けられるものとする。 The storage unit 14 is a storage device such as a hard disk drive or a nonvolatile memory, and stores rotation center image data 14a and image data 14b. The rotation center image data 14a is image data indicating the coordinates of the rotation center VC i of the cutting tool and a rotation center locus L that is the locus of the rotation center VC i of the cutting tool. The image data 14b is image data obtained by capturing an image of the surface of the object 100 by the imaging unit 20. It is assumed that the pixels in the rotation center image data 14a and the pixels in the image data 14b are associated so as to point to the same position on the object surface.

制御部15は、表面検査装置10の全体を制御する制御部であり、画像取得処理部15a、回転中心座標特定部15b、方向ベクトル算定部15c、明度勾配角度特定部15d、補正処理部15e及び傷検出部15fを有する。実際には、これらのプログラムをCPUにロードして実行することにより、画像取得処理部15a、回転中心座標特定部15b、方向ベクトル算定部15c、明度勾配角度特定部15d、補正処理部15e及び傷検出部15fにそれぞれ対応するプロセスを実行させることになる。 The control unit 15 is a control unit that controls the entire surface inspection apparatus 10, and includes an image acquisition processing unit 15a, a rotation center coordinate identification unit 15b, a direction vector calculation unit 15c, a brightness gradient angle identification unit 15d, a correction processing unit 15e, and It has a flaw detection section 15f. In reality, by loading these programs into the CPU and executing them, the image acquisition processing section 15a, rotation center coordinate identification section 15b, direction vector calculation section 15c, lightness gradient angle identification section 15d, correction processing section 15e, and scratches are processed. This causes each detection unit 15f to execute a corresponding process.

画像取得処理部15aは、撮像部20を制御して物体100の表面Sの物体表面画像を撮像させ、撮像された物体100の表面Sの物体表面画像を取得する処理部である。画像データ14bを形成する画素に対応する物体表面の位置は、回転中心画像データ14aを形成する物体表面の位置と対応付けられる。このように、画像データ14bは、あらかじめ記憶部14に記憶された回転中心画像データ14aが示す物体表面の同じ領域になるよう、位置合わせ、拡大縮小、回転、歪み補正などが行われる。 The image acquisition processing unit 15a is a processing unit that controls the imaging unit 20 to capture an object surface image of the surface S of the object 100, and acquires the object surface image of the imaged surface S of the object 100. The position of the object surface corresponding to the pixel forming the image data 14b is associated with the position of the object surface forming the rotation center image data 14a. In this way, the image data 14b is subjected to alignment, scaling, rotation, distortion correction, etc. so that it becomes the same area on the object surface indicated by the rotation center image data 14a stored in the storage unit 14 in advance.

回転中心座標特定部15bは、画像データ14bの任意の画素の座標位置(以下、「任意点Pn」と言う)に加工痕が生じた場合に、この加工痕をもたらした切削工具の回転中心VCiの座標を特定する処理部である。すなわち、かかる画像データ14bの任意点Pnに対応する物体表面の位置が切削工具により切削された場合には、必ず任意点Pnから所定の距離離れた位置に切削工具の回転中心VCiが存在したはずである。このため、任意点Pnから所定の距離離れた位置に存在した切削工具の回転中心VCiの座標を特定する。なお、任意点Pnから所定の距離離れた位置に存在した切削工具の回転中心VCiが存在せず、かつ、この任意点Pnの画素値が例えば低下しているような場合には、この任意点Pnに生じた傷は加工痕ではないことが分かる。 When a machining mark is generated at the coordinate position of an arbitrary pixel of the image data 14b (hereinafter referred to as "arbitrary point Pn"), the rotation center coordinate specifying unit 15b determines the rotation center VC of the cutting tool that caused the machining mark. This is a processing unit that specifies the coordinates of i . That is, when the position of the object surface corresponding to the arbitrary point Pn of the image data 14b is cut by the cutting tool, the rotation center VC i of the cutting tool always exists at a position a predetermined distance away from the arbitrary point Pn. It should be. Therefore, the coordinates of the rotation center VC i of the cutting tool located a predetermined distance away from the arbitrary point Pn are specified. Note that if the rotation center VC i of the cutting tool that was located a predetermined distance away from the arbitrary point Pn does not exist, and the pixel value of this arbitrary point Pn is decreasing, for example, this arbitrary point It can be seen that the scratches generated at point Pn are not machining marks.

具体的には、回転中心座標特定部15bは、回転中心画像データ14aの任意点Pnから、回転半径r±許容誤差δの範囲内に切削工具の回転中心VCiが存在するかを調べ、回転中心VCiが存在する場合には、回転中心VCiの座標を特定し、任意点Pnからの回転中心VCiへのベクトル角度θCを算定する処理を行う。 Specifically, the rotation center coordinate specifying unit 15b checks whether the rotation center VC i of the cutting tool exists within the range of rotation radius r±tolerance δ from an arbitrary point Pn of the rotation center image data 14a, and If the center VC i exists, the coordinates of the rotation center VC i are specified, and a process is performed to calculate the vector angle θ C from the arbitrary point Pn to the rotation center VC i .

方向ベクトル算定部15cは、回転中心座標特定部15bにより特定された回転中心VCiの座標から任意点Pnへの方向ベクトルを算定する処理を行う。例えば、切削工具に設けられた刃により傷つけられた物体表面の箇所の明度が低下する場合には、回転中心VCiから任意点Pnに向けた方向に明度が低下する勾配が発生する。ここで、方向ベクトルは、任意点Pnにおける加工痕の向きに直交した向きを示すベクトルである。 The direction vector calculation unit 15c performs a process of calculating a direction vector from the coordinates of the rotation center VC i specified by the rotation center coordinate identification unit 15b to an arbitrary point Pn. For example, when the brightness of a portion of the surface of an object damaged by a blade provided on a cutting tool decreases, a gradient in which the brightness decreases in a direction from the rotation center VC i toward an arbitrary point Pn occurs. Here, the direction vector is a vector indicating a direction perpendicular to the direction of the machining mark at the arbitrary point Pn.

明度勾配角度特定部15dは、撮像部20により撮像された物体表面画像の任意点Pnの画素に微分オペレータを適用して任意点Pn周りの複数の明度勾配を算定し、方向ベクトル算定部15cで算定した方向ベクトルを含む所定の角度範囲内に明度勾配角度が入るか否かを特定する処理部である。この微分オペレータとしては、Sobel又はRobertsなどの1次微分のオペレータ、2次微分オペレータ等を用いることができる。例えば、X軸方向のSobel微分オペレータを適用してX軸方向の明度勾配VXを生成するとともに、Y軸方向のSobel微分オペレータを適用してY軸方向の明度勾配VYを生成する。 The brightness gradient angle specifying unit 15d calculates a plurality of brightness gradients around the arbitrary point Pn by applying a differential operator to the pixels at the arbitrary point Pn of the object surface image captured by the imaging unit 20, and the direction vector calculating unit 15c calculates a plurality of brightness gradients around the arbitrary point Pn. This is a processing unit that specifies whether the brightness gradient angle falls within a predetermined angle range that includes the calculated direction vector. As this differential operator, a first-order differential operator such as Sobel or Roberts, a second-order differential operator, etc. can be used. For example, a Sobel differential operator in the X-axis direction is applied to generate a brightness gradient V X in the X-axis direction, and a Sobel differential operator in the Y-axis direction is applied to generate a brightness gradient V Y in the Y-axis direction.

そして、明度勾配角度特定部15dは、X軸方向の明度勾配VXとY軸方向の明度勾配VYの比を算定し、算定された明度勾配の比のデータの逆正接関数(tan-1(VX/VY))を算定することにより、明度勾配角度を算定する。その後、明度勾配角度特定部15dは、算定した明度勾配角度が方向ベクトル算定部15cで算定した方向ベクトルを含む所定の角度範囲内に入るか否かを判定する。また、明度勾配角度特定部15dは、算定した明度勾配角度が方向ベクトル算定部15cで算定した方向ベクトルの逆ベクトル方向を含む所定の角度範囲内に入るか否かも判定する。 Then, the brightness gradient angle specifying unit 15d calculates the ratio of the brightness gradient V X in the X-axis direction to the brightness gradient V Y in the Y-axis direction, and the arctangent function (tan -1 (V X /V Y )), the brightness gradient angle is calculated. Thereafter, the brightness gradient angle specifying unit 15d determines whether the calculated brightness gradient angle falls within a predetermined angle range that includes the direction vector calculated by the direction vector calculating unit 15c. The brightness gradient angle specifying unit 15d also determines whether the calculated brightness gradient angle falls within a predetermined angle range that includes the inverse vector direction of the direction vector calculated by the direction vector calculation unit 15c.

補正処理部15eは、明度勾配角度特定部15dの判定が、算定した明度勾配角度が方向ベクトル算定部15cで算定した方向ベクトルを含む所定の角度範囲内に入っている場合に、画像データ14bの任意点Pnの画素値を周囲の平均値に下げる補正処理を行う。また、明度勾配角度特定部15dの判定が、算定した明度勾配角度が方向ベクトル算定部15cで算定した方向ベクトルを含む所定の角度範囲内に入っていない場合には、補正処理を行わない。 The correction processing unit 15e corrects the image data 14b when the brightness gradient angle identifying unit 15d determines that the calculated brightness gradient angle is within a predetermined angle range that includes the direction vector calculated by the direction vector calculation unit 15c. A correction process is performed to lower the pixel value of the arbitrary point Pn to the surrounding average value. Further, if the brightness gradient angle specifying unit 15d determines that the calculated brightness gradient angle is not within a predetermined angle range that includes the direction vector calculated by the direction vector calculating unit 15c, no correction processing is performed.

また、補正処理部15eは、明度勾配角度特定部15dの判定が、算定した明度勾配角度が方向ベクトル算定部15cで算定した方向ベクトルの逆ベクトル方向を含む所定の角度範囲内に入っている場合に、画像データ14bの任意点Pnの画素値を周囲の平均値に下げる補正処理を行う。また、明度勾配角度特定部15dの判定が、算定した明度勾配角度が方向ベクトル算定部15cで算定した方向ベクトルの逆ベクトル方向を含む所定の角度範囲内に入っていない場合には、補正処理を行わない。その結果、画像データ14bから加工痕が低減される。 Further, the correction processing unit 15e determines that when the brightness gradient angle specifying unit 15d determines that the calculated brightness gradient angle is within a predetermined angle range that includes the inverse vector direction of the direction vector calculated by the direction vector calculation unit 15c. Then, a correction process is performed to lower the pixel value of the arbitrary point Pn of the image data 14b to the surrounding average value. Further, if the brightness gradient angle specifying unit 15d determines that the calculated brightness gradient angle is not within a predetermined angle range that includes the direction of the inverse vector of the direction vector calculated by the direction vector calculating unit 15c, a correction process is performed. Not performed. As a result, processing marks are reduced from the image data 14b.

傷検出部15fは、補正処理部15eにより補正された画像データ14bから傷に関する情報を検出する処理部である。例えば、深層学習、機械学習などにより教師有学習させた学習済モデルを用いて傷の発生確率を出力させ、この傷の発生確率に係数を掛けて傷スコアを出力することができる。また、テンプレートマッチング又は線分追跡技術を用いて、所定長以上の傷を検出することもできる。 The flaw detection unit 15f is a processing unit that detects information regarding flaws from the image data 14b corrected by the correction processing unit 15e. For example, it is possible to output the probability of scratch occurrence using a trained model that has undergone supervised learning using deep learning, machine learning, etc., and to output a scratch score by multiplying the probability of scratch occurrence by a coefficient. Furthermore, scratches longer than a predetermined length can also be detected using template matching or line segment tracing techniques.

<回転中心VCiを特定する処理>
次に、任意点Pnから回転中心VCiを特定する処理について説明する。図2は、任意点Pnから回転中心VCiを特定する処理を説明するための説明図である。ここでは、画像データ14bと回転中心画像データ14aとを重畳した状態を図示している。物体表面画像101は、撮像部20で撮像された画像であり、ここに切削工具の回転中心VCiの座標と該切削工具の回転中心VCiの軌跡(回転中心軌跡L)をオーバーラップさせている。
<Processing to identify rotation center VC i >
Next, a process for specifying the rotation center VC i from an arbitrary point Pn will be described. FIG. 2 is an explanatory diagram for explaining the process of specifying the rotation center VC i from an arbitrary point Pn. Here, a state in which the image data 14b and the rotation center image data 14a are superimposed is illustrated. The object surface image 101 is an image captured by the imaging unit 20, and is obtained by overlapping the coordinates of the rotation center VC i of the cutting tool with the locus (rotation center locus L) of the rotation center VC i of the cutting tool. There is.

まず、任意点Pnを中心として回転半径r±許容誤差δの範囲内に、回転中心VCiが存在するか否かを判定する。かかる判定を行う場合には、円のテンプレートの中心を任意点Pnとし、円内に存在する回転中心VCiの座標を特定すればよい。 First, it is determined whether or not a rotation center VC i exists within a range of rotation radius r±permissible error δ with an arbitrary point Pn as the center. When making such a determination, it is sufficient to set the center of the circular template to an arbitrary point Pn and specify the coordinates of the rotation center VC i existing within the circle.

このようにして、回転中心VCiの座標を特定したならば、任意点Pnから回転中心VCiに向かう回転中心ベクトルCVを求め、この回転中心ベクトルCVとX軸とのなすベクトル角度θCを算定する。なお、任意点Pnから回転半径r±許容誤差δの範囲内に複数の回転中心VCiが存在する場合には、それぞれの回転中心VCiの座標を特定し、それぞれの回転中心ベクトルCVのベクトル角度θCnを算定する。 Once the coordinates of the rotation center VC i are determined in this way, the rotation center vector CV directed from the arbitrary point Pn toward the rotation center VC i is determined, and the vector angle θ C between this rotation center vector CV and the X-axis is calculated. Calculate. In addition, if there are multiple rotation centers VC i within the range of rotation radius r±tolerance δ from arbitrary point Pn, specify the coordinates of each rotation center VC i and calculate the vector of each rotation center vector CV. Calculate the angle θ Cn .

<任意点Pnにおける方向ベクトル>
次に、任意点Pnにおける方向ベクトルBVの算定について説明する。図3は、方向ベクトルBVの算定を説明するための説明図である。ここでは、切削工具の刃により任意点Pnに生じた加工痕のベクトルを加工痕ベクトルSVと表記することとする。
<Direction vector at arbitrary point Pn>
Next, calculation of the direction vector BV at the arbitrary point Pn will be explained. FIG. 3 is an explanatory diagram for explaining calculation of the direction vector BV. Here, the vector of a machining mark created at an arbitrary point Pn by the blade of a cutting tool will be expressed as a machining mark vector SV.

図3(a)に示すように、任意点Pnにおける加工痕ベクトルSVは、任意点Pnから回転中心座標に向かう回転中心ベクトルCVと直交する。そして、加工痕ベクトルSVに対する方向ベクトルBVは、加工痕ベクトルSVと直交するため、結果的に方向ベクトルBVは、回転中心ベクトルCVの逆ベクトル(回転中心ベクトルCVのベクトル角度θCの180度位相が異なる)となる。 As shown in FIG. 3A, the machining mark vector SV at the arbitrary point Pn is orthogonal to the rotation center vector CV from the arbitrary point Pn toward the rotation center coordinates. Since the direction vector BV with respect to the machining mark vector SV is orthogonal to the machining mark vector SV, the direction vector BV is, as a result, the inverse vector of the rotation center vector CV (180 degrees phase of the vector angle θ C of the rotation center vector CV). are different).

図3(b)に示すように、任意点Pnの周辺の表面の形状を模式的に表わすと、加工痕ベクトルSV上の任意点Pnが加工痕として抉られた底部にあり、その回りが加工痕ベクトルSVに沿って盛り上がる。すなわち、画像が256階調の白黒濃淡画像であり、白画素ほど画素値が高くなる場合に、加工痕となる画素の画素値が低くなるならば、任意点Pnの画素値が低くなり、回転中心VCiに向かうほど画素値が高くなる。このため、任意点Pnの方向ベクトルBVは、回転中心VCiより任意点Pnに向かうベクトルとなり、その方向は、回転中心ベクトルCVの逆ベクトル方向となる。 As shown in FIG. 3(b), when the shape of the surface around an arbitrary point Pn is schematically expressed, the arbitrary point Pn on the machining mark vector SV is at the bottom of the gouged part as a machining mark, and the area around it is It rises along the trace vector SV. In other words, if the image is a 256-level black and white gray image, and the whiter the pixel, the higher the pixel value, if the pixel value of the pixel that is a processing mark is lower, the pixel value of the arbitrary point Pn will be lower, and the rotation The pixel value becomes higher toward the center VC i . Therefore, the direction vector BV of the arbitrary point Pn is a vector directed from the rotation center VC i toward the arbitrary point Pn, and its direction is the opposite direction of the rotation center vector CV.

<表面検査装置10の処理手順>
次に、図1に示した表面検査装置10の処理手順について説明する。図4は、図1に示した表面検査装置10の処理手順を示すフローチャートである。図4に示すように、表面検査装置10は、まず、撮像部20により撮像された物体100の表面Sの物体表面画像101を取得する(ステップS101)。
<Processing procedure of surface inspection device 10>
Next, the processing procedure of the surface inspection apparatus 10 shown in FIG. 1 will be explained. FIG. 4 is a flowchart showing the processing procedure of the surface inspection apparatus 10 shown in FIG. As shown in FIG. 4, the surface inspection apparatus 10 first obtains an object surface image 101 of the surface S of the object 100 captured by the imaging unit 20 (step S101).

そして、表面検査装置10は、この物体表面画像101と、切削工具の回転中心VCiの座標と該切削工具の回転中心VCiの軌跡を示す移動軌跡画像である回転中心画像との位置合わせを行うとともに、かかる物体表面画像101からノイズを除去する前処理を行う(ステップS102)。このノイズ除去処理としては、例えば公知の平滑化フィルタ、メディアンフィルタなどを適用すればよい。 Then, the surface inspection device 10 aligns this object surface image 101 with a rotation center image that is a movement trajectory image showing the coordinates of the rotation center VC i of the cutting tool and the locus of the rotation center VC i of the cutting tool. At the same time, preprocessing is performed to remove noise from the object surface image 101 (step S102). As this noise removal process, for example, a known smoothing filter, median filter, etc. may be applied.

その後、ノイズが除去された物体表面画像101上の任意の画素を選択する(ステップS103)。そして、表面検査装置10は、物体表面画像101及び回転中心画像に基づいて、画像の所定の画素から回転半径r±許容誤差δの範囲内に回転中心VCiが存在するか否かを判定し、回転中心VCiが存在する場合には、回転中心VCiの座標を特定する(ステップS104)。 After that, an arbitrary pixel on the object surface image 101 from which noise has been removed is selected (step S103). Then, the surface inspection device 10 determines, based on the object surface image 101 and the rotation center image, whether the rotation center VC i exists within the range of rotation radius r ± tolerance δ from a predetermined pixel of the image. , if a rotation center VC i exists, the coordinates of the rotation center VC i are specified (step S104).

表面検査装置10は、回転中心VCiの座標が特定されたか否かを判定し、回転中心VCiの座標が特定されない場合には(ステップS105;No)、次の画素を選択し(ステップS110)、ステップS104に移行する。 The surface inspection device 10 determines whether the coordinates of the rotation center VC i have been specified, and if the coordinates of the rotation center VC i have not been specified (step S105; No), selects the next pixel (step S110). ), the process moves to step S104.

これに対して、回転中心VCiの座標が特定された場合は(ステップS105;Yes)、任意点Pnから回転中心VCiの座標に向けた回転中心ベクトルCVを算定する(ステップS106)。そして、表面検査装置10は、算出された回転中心ベクトルCVに基づいて、任意点Pnの方向ベクトルBVを算定する(ステップS107)。 On the other hand, if the coordinates of the rotation center VC i are specified (step S105; Yes), a rotation center vector CV directed from the arbitrary point Pn to the coordinates of the rotation center VC i is calculated (step S106). Then, the surface inspection apparatus 10 calculates the direction vector BV of the arbitrary point Pn based on the calculated rotation center vector CV (step S107).

その後、表面検査装置10は、選択した画素の画素値の補正処理を行い(ステップS108)、処理した画素が最後の画素であるか否かを判定する(ステップS109)。最後の画素でない場合は(ステップS109;No)、次の画素を選択し(ステップS110)、ステップS104に移行する。これに対して、最後の画素である場合には(ステップS109;Yes)、全ての画素について処理が行われた画像に基づいて、傷の検出を行い(ステップS111)、一連の処理を終了する。 After that, the surface inspection apparatus 10 performs a correction process on the pixel value of the selected pixel (step S108), and determines whether the processed pixel is the last pixel (step S109). If it is not the last pixel (step S109; No), the next pixel is selected (step S110), and the process moves to step S104. On the other hand, if it is the last pixel (step S109; Yes), a flaw is detected based on the image in which all pixels have been processed (step S111), and the series of processes ends. .

<補正処理の処理手順>
次に、補正処理について説明する。図5は、図4に示した補正処理の処理手順を示すフローチャートである。図5に示すように、表面検査装置10は、選択された画素(任意点Pn)のX軸方向の明度勾配VXを算定するとともに(ステップS201)、この画素のY軸方向の明度勾配VYを算定する(ステップS202)。
<Correction processing procedure>
Next, the correction process will be explained. FIG. 5 is a flowchart showing the processing procedure of the correction process shown in FIG. As shown in FIG. 5, the surface inspection apparatus 10 calculates the brightness gradient V X of the selected pixel (arbitrary point Pn) in the X-axis direction (step S201), and also calculates the brightness gradient V X of this pixel in the Y-axis direction. Y is calculated (step S202).

その後、表面検査装置10は、X軸方向の明度勾配VXとY軸方向の明度勾配VYの比(VX/VY)を求め、その比の逆正接関数tan-1(VX/VY)を明度勾配角度として算定する(ステップS203)。 After that, the surface inspection device 10 determines the ratio ( V X / V Y ) of the brightness gradient V V Y ) is calculated as the brightness gradient angle (step S203).

そして、表面検査装置10は、算出した明度勾配角度と方向ベクトルBVのベクトル方向(ベクトル角度)を比較する(ステップS204)。算出した明度勾配角度と方向ベクトルBVのベクトル方向が所定の範囲内でない場合は(ステップS205;No)、図4のステップS109に移行する。 Then, the surface inspection apparatus 10 compares the calculated brightness gradient angle and the vector direction (vector angle) of the direction vector BV (step S204). If the calculated brightness gradient angle and the vector direction of the direction vector BV are not within the predetermined range (step S205; No), the process moves to step S109 in FIG. 4.

これに対して、算出した明度勾配角度と方向ベクトルBVのベクトル方向が所定の範囲内である場合は(ステップS205;Yes)、画素値を周囲の平均値に補正し(ステップS206)、図4のステップS109に移行する。ここで、補正処理を行う所定の範囲は、例えば方向ベクトルBVの角度に対して±10度であり、また、方向ベクトルBVの方向とその逆ベクトルの方向を補正の対象とする。 On the other hand, if the calculated brightness gradient angle and the vector direction of the direction vector BV are within the predetermined range (step S205; Yes), the pixel value is corrected to the surrounding average value (step S206), and as shown in FIG. The process moves to step S109. Here, the predetermined range in which the correction process is performed is, for example, ±10 degrees with respect to the angle of the direction vector BV, and the direction of the direction vector BV and the direction of its inverse vector are targeted for correction.

<物体表面画像101及び処理済画像の一例>
次に、図1に示した表面検査装置10の物体表面画像101及び処理済画像の一例について説明する。図6は、図1に示した表面検査装置10の物体表面画像101及び処理済画像の一例を示す図である。図6(a)に示すように、撮像部20により撮像された物体表面画像101は、物体100に存在する意図しない打痕などの傷と加工によって生じる加工痕との区別がつかず目視で視認することが難しい画像となる。
<Example of object surface image 101 and processed image>
Next, an example of the object surface image 101 and processed image of the surface inspection apparatus 10 shown in FIG. 1 will be described. FIG. 6 is a diagram showing an example of an object surface image 101 and a processed image of the surface inspection apparatus 10 shown in FIG. 1. As shown in FIG. 6A, an object surface image 101 captured by the imaging unit 20 is visually recognizable because it is difficult to distinguish between scratches such as unintentional dents existing on the object 100 and machining marks caused by machining. This results in an image that is difficult to capture.

これに対して、図6(a)の物体表面画像101を表面検査装置10で処理をしたならば、図6(b)に示すように、各画素で加工痕の明度勾配に補正が行われているため、加工痕が削除された処理済画像が得られる。これにより、加工痕ではない、欠陥部位P1、P2、P3及びP4が明確に視認しやすい画像が得られる。 On the other hand, if the object surface image 101 in FIG. 6(a) is processed by the surface inspection device 10, the brightness gradient of the machining mark will be corrected at each pixel, as shown in FIG. 6(b). As a result, a processed image with processing marks removed can be obtained. As a result, an image is obtained in which the defective parts P1, P2, P3, and P4, which are not machining marks, are clearly and easily visible.

このように、本実施形態1では、表面検査装置10は、撮像部20により物体100の表面Sを撮像した物体表面画像101及び回転中心画像データ14aに基づいて、物体表面画像101の任意点Pnから回転半径r±許容誤差δの範囲内に回転中心VCiが存在するか否かを検索し、存在する場合には、任意点Pnから回転中心VCiへのベクトル方向を特定し、任意点Pnの方向ベクトルBVを算定する。そして、任意点Pnにおける加工痕SMに起因する明度勾配角度を算出し、明度勾配角度と方向ベクトルBVが所定の範囲内の場合に、任意点Pnの画素値を周囲の平均値となるように構成したので、加工痕の影響を低減しつつ、加工表面の打痕等の傷を検出することができる。 As described above, in the first embodiment, the surface inspection apparatus 10 calculates the arbitrary point Pn of the object surface image 101 based on the object surface image 101 captured by the imaging unit 20 of the surface S of the object 100 and the rotation center image data 14a. Search to see if the rotation center VC i exists within the range of rotation radius r±tolerance δ from , and if it exists, specify the vector direction from the arbitrary point Pn to the rotation center VC i , Calculate the direction vector BV of Pn. Then, the brightness gradient angle caused by the machining mark SM at an arbitrary point Pn is calculated, and when the brightness gradient angle and the direction vector BV are within a predetermined range, the pixel value of the arbitrary point Pn is set to the surrounding average value. With this configuration, flaws such as dents on the machined surface can be detected while reducing the influence of the process marks.

[実施形態2]
ところで、上記実施形態1では、物体表面画像101から加工痕SMを削除するために、任意点Pnから回転中心VCiの座標を探索する場合を説明したが、本実施形態2では、回転中心VCiから加工痕SMが発生する任意点Pnを求めて、その任意点Pnにおける加工痕SMを削除する場合について説明する。なお、実施形態1と同様の部位については、同一の符号を付すこととして、その詳細な説明を省略する。
[Embodiment 2]
By the way, in the first embodiment described above, in order to delete the machining marks SM from the object surface image 101, a case was explained in which the coordinates of the rotation center VC i are searched from an arbitrary point Pn, but in the present embodiment 2, the coordinates of the rotation center VC i A case will be described in which an arbitrary point Pn where a machining mark SM is generated is determined from i and the machining mark SM at the arbitrary point Pn is deleted. Note that the same parts as in Embodiment 1 are given the same reference numerals, and detailed explanation thereof will be omitted.

<表面検査装置30の構成>
次に、本実施形態2に係る表面検査装置30の構成について説明する。図7は、実施形態2に係る表面検査装置30の構成を示す機能ブロック図である。図7に示すように、表面検査装置30は、表示部11、入力部12、記憶部14、制御部35及び撮像部20を有する。
<Configuration of surface inspection device 30>
Next, the configuration of the surface inspection device 30 according to the second embodiment will be explained. FIG. 7 is a functional block diagram showing the configuration of a surface inspection device 30 according to the second embodiment. As shown in FIG. 7, the surface inspection device 30 includes a display section 11, an input section 12, a storage section 14, a control section 35, and an imaging section 20.

制御部35は、表面検査装置30の全体を制御する制御部であり、画像取得処理部15a、方向ベクトル算定部15c、明度勾配角度特定部15d、補正処理部15e、傷検出部15f及び任意点座標特定部35aを有する。実際には、これらのプログラムをCPUにロードして実行することにより、画像取得処理部15a、方向ベクトル算定部15c、明度勾配角度特定部15d、補正処理部15e、傷検出部15f及び任意点座標特定部35aにそれぞれ対応するプロセスを実行させることになる。 The control unit 35 is a control unit that controls the entire surface inspection apparatus 30, and includes an image acquisition processing unit 15a, a direction vector calculation unit 15c, a brightness gradient angle identification unit 15d, a correction processing unit 15e, a flaw detection unit 15f, and an arbitrary point. It has a coordinate specifying section 35a. Actually, by loading and executing these programs on the CPU, the image acquisition processing section 15a, the direction vector calculation section 15c, the brightness gradient angle specification section 15d, the correction processing section 15e, the flaw detection section 15f, and the arbitrary point coordinates are calculated. The specifying unit 35a is caused to execute the corresponding process.

任意点座標特定部35aは、回転中心画像データ14aの任意の回転中心VCiを中心に切削工具が加工痕をもたらす任意点の座標を特定する処理部である。すなわち、かかる回転中心画像データ14aの任意の回転中心VCiを中心に切削工具が回転した場合に、任意の回転中心VCiから所定の距離離れた位置に加工痕が生じるはずである。このため、回転中心VCiから所定の距離離れた位置の任意点Pnの座標を特定する。 The arbitrary point coordinate specifying unit 35a is a processing unit that specifies the coordinates of an arbitrary point where a cutting tool produces a machining mark around an arbitrary rotation center VC i of the rotation center image data 14a. That is, when the cutting tool rotates around an arbitrary rotation center VC i of the rotation center image data 14a, machining marks should be produced at a position a predetermined distance away from the arbitrary rotation center VC i . Therefore, the coordinates of an arbitrary point Pn located a predetermined distance away from the center of rotation VC i are specified.

具体的には、回転中心画像データ14aの回転中心VCiから、回転半径r±許容誤差δの円周上に任意点Pnの座標を特定し、回転中心VCiから任意点Pnに向かう任意点ベクトルPVのベクトル角度θPを特定する処理を行う。 Specifically, from the rotation center VCi of the rotation center image data 14a, the coordinates of an arbitrary point Pn on the circumference of the rotation radius r±tolerance δ are specified, and an arbitrary point vector directed from the rotation center VC i to the arbitrary point Pn is determined. Processing is performed to specify the vector angle θ P of PV.

<任意点Pnを特定する処理>
次に、回転中心VCiから任意点Pnの座標を特定する処理について説明する。図8は、回転中心VCiから任意点Pnの座標を特定する処理について説明する説明図である。ここでは、画像データ14bと回転中心画像データ14aとを重畳した状態を図示している。物体表面画像101は、撮像部20で撮像された画像であり、ここに切削工具の回転中心VCiの座標と該切削工具の回転中心VCiの軌跡をオーバーラップさせている。
<Processing to identify arbitrary point Pn>
Next, a process for specifying the coordinates of an arbitrary point Pn from the center of rotation VC i will be described. FIG. 8 is an explanatory diagram illustrating the process of specifying the coordinates of an arbitrary point Pn from the center of rotation VC i . Here, a state in which the image data 14b and the rotation center image data 14a are superimposed is illustrated. The object surface image 101 is an image captured by the imaging unit 20, in which the coordinates of the rotation center VC i of the cutting tool and the locus of the rotation center VC i of the cutting tool overlap.

図8に示すように、画像上の所定の回転中心VCiから回転半径r±許容誤差δの範囲内の円周上の任意点Pnの座標を特定する。 As shown in FIG. 8, the coordinates of an arbitrary point Pn on the circumference within a range of rotation radius r±permissible error δ from a predetermined rotation center VC i on the image are specified.

このようにして、任意点Pnの座標を特定したならば、回転中心VCiから任意点Pnに向かう任意点ベクトルPVを求め、この任意点ベクトルPVとX軸とのなすベクトル角度θPを算定する。 Once the coordinates of the arbitrary point Pn are specified in this way, the arbitrary point vector PV directed from the rotation center VC i to the arbitrary point Pn is determined, and the vector angle θ P between this arbitrary point vector PV and the X-axis is calculated. do.

<方向ベクトルBVの算定>
次に、任意点Pnにおける方向ベクトルBVの算定について説明する。図9は、方向ベクトルBVの算定を説明するための説明図である。図9に示すように、任意点Pnにおける加工痕ベクトルSVは、回転中心VCiから任意点Pnの座標に向かう任意点ベクトルPVと直交する。そして、加工痕ベクトルSVに対する方向ベクトルBVは、加工痕ベクトルSVと直交するため、結果的に方向ベクトルBVは、任意点ベクトルPVと同じ方向ベクトルとなる。
<Calculation of direction vector BV>
Next, calculation of the direction vector BV at the arbitrary point Pn will be explained. FIG. 9 is an explanatory diagram for explaining calculation of the direction vector BV. As shown in FIG. 9, the machining mark vector SV at the arbitrary point Pn is orthogonal to the arbitrary point vector PV directed from the rotation center VC i to the coordinates of the arbitrary point Pn. Since the direction vector BV with respect to the machining mark vector SV is orthogonal to the machining mark vector SV, the direction vector BV becomes the same direction vector as the arbitrary point vector PV.

<表面検査装置30の処理手順>
次に、表面検査装置30の処理手順について説明する。図10は、図7に示した表面検査装置30の処理手順を示すフローチャートである。図10に示すように、表面検査装置30は、まず、撮像部20により撮像された物体100の表面Sの物体表面画像101を取得する(ステップS301)。
<Processing procedure of surface inspection device 30>
Next, the processing procedure of the surface inspection device 30 will be explained. FIG. 10 is a flowchart showing the processing procedure of the surface inspection apparatus 30 shown in FIG. As shown in FIG. 10, the surface inspection device 30 first obtains an object surface image 101 of the surface S of the object 100 captured by the imaging unit 20 (step S301).

そして、表面検査装置30は、この物体表面画像101と、切削工具の回転中心VCiの座標と該切削工具の回転中心VCiの軌跡を示す回転中心画像との位置合わせを行うとともに、かかる物体表面画像101からノイズを除去する前処理を行う(ステップS302)。このノイズ除去処理としては、例えば公知の平滑化フィルタ、メディアンフィルタなどを適用すればよい。 Then, the surface inspection device 30 aligns this object surface image 101 with a rotation center image showing the coordinates of the rotation center VC i of the cutting tool and the locus of the rotation center VC i of the cutting tool, and Preprocessing is performed to remove noise from the surface image 101 (step S302). As this noise removal process, for example, a known smoothing filter, median filter, etc. may be applied.

その後、表面検査装置30は、ノイズが除去された画面上の任意の回転中心VCiの座標を選択する(ステップS303)。そして、回転中心座標から回転半径r±許容誤差δの円周上に処理する任意点Pnの座標を特定する(ステップS304)。 Thereafter, the surface inspection device 30 selects the coordinates of an arbitrary rotation center VC i on the screen from which noise has been removed (step S303). Then, the coordinates of an arbitrary point Pn to be processed on the circumference of the rotation radius r±permissible error δ are specified from the rotation center coordinates (step S304).

そして、表面検査装置30は、回転中心VCiから任意点Pnの座標への任意点ベクトルPVを算定する(ステップS305)、その後、任意点ベクトルPVに基づいて、方向ベクトルBVを算定し(ステップS306)、補正処理を行う(ステップS307)。表面検査装置30は、処理を行った任意点Pnが最後の任意点であるか否かを判定し、最後の任意点でない場合は(ステップS308;No)、次に任意点を選択し(ステップS309)、ステップS304に移行する。 Then, the surface inspection device 30 calculates an arbitrary point vector PV from the rotation center VC i to the coordinates of the arbitrary point Pn (step S305), and then calculates a direction vector BV based on the arbitrary point vector PV (step S305). S306), and correction processing is performed (step S307). The surface inspection device 30 determines whether the processed arbitrary point Pn is the last arbitrary point, and if it is not the last arbitrary point (step S308; No), then selects the arbitrary point (step S309), the process moves to step S304.

これに対して、処理を行った任意点Pnが最後の任意点である場合は(ステップS308;Yes)、処理を行った回転中心VCiが最後の回転中心VCiであるか否かを判定する(ステップS310)。処理を行った回転中心VCiが最後の回転中心VCiでない場合は(ステップS310;No)、次の回転中心VCiを選択し(ステップS311)、ステップS303に移行する。 On the other hand, if the processed arbitrary point Pn is the last arbitrary point (step S308; Yes), it is determined whether the processed rotation center VC i is the last rotation center VC i . (Step S310). If the processed rotation center VC i is not the last rotation center VC i (step S310; No), the next rotation center VC i is selected (step S311), and the process moves to step S303.

これに対して、処理を行った回転中心VCiが最後の回転中心VCiである場合は(ステップS310;Yes)、傷の検出を行い(ステップS312)、一連の処理を終了する。なお、図10の補正処理(ステップS307)については、実施形態1の図4の補正処理(ステップS108)と同様であるため説明を省略する。 On the other hand, if the processed rotation center VC i is the last rotation center VC i (step S310; Yes), a flaw is detected (step S312) and the series of processes ends. Note that the correction process (step S307) in FIG. 10 is the same as the correction process (step S108) in FIG. 4 of the first embodiment, so a description thereof will be omitted.

このように、本実施形態2では、表面検査装置30が、撮像部20により物体100を撮像した物体表面画像101に基づいて、回転中心VCiから回転半径r±許容誤差δの範囲内の任意点Pnの座標を特定し、回転中心VCiから任意点Pnへのベクトル方向を算出し、任意点Pnの方向ベクトルBVを特定する。そして、任意点Pnにおける加工痕SMに起因する明度勾配角度を算出し、明度勾配角度が方向ベクトルBVのベクトル角度の所定の範囲内であるならば、任意点Pnの画素値を周辺の平均値にするように構成したので、加工痕の影響を低減しつつ、加工表面の打痕等の傷を検出することができる。 As described above, in the second embodiment, the surface inspection device 30 detects an arbitrary value within the range of the rotation radius r±permissible error δ from the rotation center VC i based on the object surface image 101 captured by the imaging unit 20 of the object 100. The coordinates of point Pn are specified, the vector direction from rotation center VC i to arbitrary point Pn is calculated, and the direction vector BV of arbitrary point Pn is specified. Then, the brightness gradient angle caused by the machining mark SM at an arbitrary point Pn is calculated, and if the brightness gradient angle is within a predetermined range of the vector angle of the direction vector BV, the pixel value of the arbitrary point Pn is set to the surrounding average value. With this structure, it is possible to detect flaws such as dents on the machined surface while reducing the influence of the process marks.

なお、上記実施形態1及び実施形態2では、切削工具の回転中心の移動軌跡は、該切削工具の回転中心の移動軌跡をなす画素に対して所定の画素値が付与された移動軌跡画像である回転中心画像データを用いた場合について説明したが、本発明はこれに限定されるものではなく、回転中心の軌跡を含む加工データであってもよい。また、回転中心の軌跡を示す座標データであってもよい。また、該切削工具の回転中心の移動軌跡をなす画素に対して所定の画素値が付与された移動軌跡画像は、ビットマップ形式又はベクター形式の画像であってもよい。 In the first and second embodiments described above, the movement trajectory of the rotation center of the cutting tool is a movement trajectory image in which a predetermined pixel value is assigned to the pixels forming the movement trajectory of the rotation center of the cutting tool. Although a case has been described in which rotation center image data is used, the present invention is not limited to this, and processed data including a locus of the rotation center may be used. Alternatively, it may be coordinate data indicating a locus of the center of rotation. Further, the movement trajectory image in which predetermined pixel values are assigned to pixels forming the movement trajectory of the rotation center of the cutting tool may be an image in a bitmap format or a vector format.

なお、上記実施形態1及び実施形態2では、任意点Pnの明度勾配角度を求めて補正を行う場合について説明したが、線集中度フィルタを用いることもできる。また、上記実施形態1及び実施形態2では、切削工具に正面フライスを用いる場合について説明したが、本発明はこれに限定されるものではなく、切削工具に研磨ブラシを用いてもよい。 Note that in the first and second embodiments described above, a case has been described in which the brightness gradient angle of an arbitrary point Pn is determined and correction is performed, but a line concentration filter may also be used. Furthermore, in the first and second embodiments described above, a case has been described in which a face milling cutter is used as the cutting tool, but the present invention is not limited to this, and an abrasive brush may be used as the cutting tool.

上記の各実施形態で図示した各構成は機能概略的なものであり、必ずしも物理的に図示の構成をされていることを要しない。すなわち、各装置の分散・統合の形態は図示のものに限られず、その全部又は一部を各種の負荷や使用状況などに応じて、任意の単位で機能的又は物理的に分散・統合して構成することができる。 The configurations illustrated in each of the above embodiments are functionally schematic and do not necessarily have to be physically configured as illustrated. In other words, the form of dispersion/integration of each device is not limited to the one shown in the diagram, but all or part of it can be functionally or physically distributed/integrated in arbitrary units depending on various loads and usage conditions. Can be configured.

本発明に係る表面検査装置及び表面検査方法は、フライス加工による平面出しを行う場合に加工表面に生じた加工痕の影響を低減しつつ、加工表面の打痕等の傷を検出する場合に適している。 The surface inspection device and surface inspection method according to the present invention are suitable for detecting flaws such as dents on the machined surface while reducing the influence of machining marks generated on the machined surface when flattening by milling. ing.

10 表面検査装置
11 表示部
12 入力部
14 記憶部
14a 回転中心画像データ
14b 画像データ
15 制御部
15a 画像取得処理部
15b 回転中心座標特定部
15c 方向ベクトル算定部
15d 補正処理部
15e 傷検出部
20 撮像部
30 表面検査装置
35 制御部
35a 任意点座標特定部
100 物体
101 物体表面画像
BV 方向ベクトル
CV 回転中心ベクトル
L 回転中心軌跡
Pn 任意点
PV 任意点ベクトル
P1,P2、P3、P4 欠陥表面
r 回転半径
S 表面
SM 加工痕
SV 加工痕ベクトル
VCi 回転中心
δ 許容誤差
θC 回転中心ベクトル角度
θP 任意点ベクトル角度
10 Surface inspection device 11 Display section 12 Input section 14 Storage section 14a Rotation center image data 14b Image data 15 Control section 15a Image acquisition processing section 15b Rotation center coordinate specifying section 15c Direction vector calculation section 15d Correction processing section 15e Flaw detection section 20 Imaging Section 30 Surface inspection device 35 Control section 35a Arbitrary point coordinate specifying section 100 Object 101 Object surface image BV Direction vector CV Rotation center vector L Rotation center locus Pn Arbitrary point PV Arbitrary point vector P1, P2, P3, P4 Defect surface r Rotation radius S Surface SM Machining mark SV Machining mark vector VC i Rotation center δ Tolerance θ C Rotation center vector angle θ P Arbitrary point vector angle

Claims (9)

所定の回転軸に取り付けた切削工具を回転させつつ切削加工した物体の表面を撮像する撮像部により撮像された物体表面画像を用いて所定の物体の表面の検査を行う表面検査装置における表面検査方法であって、
前記物体表面画像を形成する任意の第1の画素に対して影響を及ぼす前記切削工具の回転中心の移動軌跡上の第2の画素を特定する第1の特定工程と、
前記第1の特定工程により特定された前記第1の画素における複数の明度勾配のうち、前記切削工具の回転中心の移動軌跡上の第2の画素への方向ベクトルの明度勾配を特定する第2の特定工程と、
前記第2の特定工程により特定された勾配角度に基づいて、前記物体表面画像を形成する各画素の画素値を補正する補正工程と
を含むことを特徴とする表面検査方法。
A surface inspection method in a surface inspection device that inspects the surface of a predetermined object using an object surface image captured by an imaging unit that images the surface of a cut object while rotating a cutting tool attached to a predetermined rotating shaft. And,
a first specifying step of specifying a second pixel on a movement trajectory of the rotation center of the cutting tool that affects an arbitrary first pixel forming the object surface image;
A second step of identifying a brightness gradient of a direction vector toward a second pixel on the movement locus of the rotation center of the cutting tool among the plurality of brightness gradients at the first pixel identified in the first identifying step; a specific process,
A surface inspection method comprising: a correction step of correcting a pixel value of each pixel forming the object surface image based on the gradient angle specified in the second specifying step.
前記補正工程により前記物体表面画像が補正された補正画像に基づいて、前記物体の表面に形成された前記加工痕以外に起因する傷の検査を行う検査工程をさらに含むことを特徴とする請求項1に記載の表面検査方法。 Claim further comprising: an inspection step of inspecting flaws caused by other than the machining marks formed on the surface of the object based on a corrected image in which the object surface image is corrected in the correction step. 1. The surface inspection method described in 1. 前記切削工具は、
所定の回転体の円周上に複数の刃が取り付けられ、前記所定の回転軸を中心として回転可能に形成された正面フライス又は物体の表面を研磨する研磨ブラシであることを特徴とする請求項1に記載の表面検査方法。
The cutting tool is
A claim characterized in that the blade is a face milling cutter or an abrasive brush for polishing the surface of an object, in which a plurality of blades are attached to the circumference of a predetermined rotating body, and is formed to be rotatable about the predetermined rotation axis. 1. The surface inspection method described in 1.
前記第1の特定工程は、
前記切削工具の回転中心の移動軌跡をなす画素に対して所定の画素値が付与された移動軌跡画像を用いて、前記物体表面画像を形成する第1の画素に対して影響を及ぼす前記切削工具の回転中心の移動軌跡上の前記第2の画素を特定することを特徴とする請求項1に記載の表面検査方法。
The first specifying step is
The cutting tool influences the first pixels forming the object surface image using a movement trajectory image in which a predetermined pixel value is assigned to the pixels forming the movement trajectory of the rotation center of the cutting tool. 2. The surface inspection method according to claim 1, further comprising specifying the second pixel on a movement locus of a rotation center.
前記補正工程は、
前記第2の特定工程により特定された明度勾配の勾配角度をなす前記物体表面画像上の第1の画素の画素値を補正することを特徴とする請求項4に記載の表面検査方法。
The correction step includes:
5. The surface inspection method according to claim 4, further comprising correcting a pixel value of a first pixel on the object surface image that forms a gradient angle of the brightness gradient specified in the second specifying step.
前記補正工程は、
前記第2の特定工程により特定された明度勾配の勾配角度をなす前記物体表面画像上の第1の画素の画素値を下げることを特徴とする請求項5に記載の表面検査方法。
The correction step includes:
6. The surface inspection method according to claim 5, further comprising lowering a pixel value of a first pixel on the object surface image that forms a gradient angle of the brightness gradient specified in the second specifying step.
所定の回転軸に取り付けた切削工具を回転させつつ切削加工した物体の表面を撮像する撮像部により撮像された物体表面画像を用いて所定の物体の表面の検査を行う表面検査装置における表面検査方法であって、
前記切削工具の回転中心の移動軌跡上の第2の画素が影響を及ぼす第1の画素を特定する第1の特定工程と、
前記第1の特定工程により特定された前記第1の画素における複数の明度勾配のうち、前記切削工具の回転中心の移動軌跡上の第2の画素から前記第1の画素への方向ベクトルの明度勾配を特定する第2の特定工程と、
前記第2の特定工程により特定された勾配角度に基づいて、前記物体表面画像を形成する各画素の画素値を補正する補正工程と
を含むことを特徴とする表面検査方法。
A surface inspection method in a surface inspection device that inspects the surface of a predetermined object using an object surface image captured by an imaging unit that images the surface of a cut object while rotating a cutting tool attached to a predetermined rotating shaft. And,
a first specifying step of specifying a first pixel affected by a second pixel on the movement trajectory of the rotation center of the cutting tool;
Among the plurality of brightness gradients in the first pixel identified in the first identifying step, the brightness of the direction vector from the second pixel on the movement trajectory of the rotation center of the cutting tool to the first pixel. a second identifying step of identifying the slope;
A surface inspection method comprising: a correction step of correcting a pixel value of each pixel forming the object surface image based on the gradient angle specified in the second specifying step.
所定の回転軸に取り付けた切削工具を回転させつつ切削加工した物体の表面を撮像する撮像部により撮像された物体表面画像を用いて所定の物体の表面の検査を行う表面検査装置であって、
前記物体表面画像を形成する任意の第1の画素に対して影響を及ぼす前記切削工具の回転中心の移動軌跡上の第2の画素を特定する第1の特定手段と、
前記第1の特定手段により特定された第1の画素における複数の明度勾配のうち、前記切削工具の回転中心の移動軌跡上の第2の画素への方向ベクトルの明度勾配を特定する第2の特定手段と、
前記第2の特定手段により特定された勾配角度に基づいて、前記物体表面画像を形成する各画素の画素値を補正する補正手段と
を備えたことを特徴とする表面検査装置。
A surface inspection device that inspects the surface of a predetermined object using an object surface image captured by an imaging unit that images the surface of a cut object while rotating a cutting tool attached to a predetermined rotation axis,
first specifying means for specifying a second pixel on the movement trajectory of the rotation center of the cutting tool that affects any first pixel forming the object surface image;
A second method for specifying a brightness gradient of a direction vector toward a second pixel on the movement locus of the rotation center of the cutting tool among the plurality of brightness gradients at the first pixel identified by the first identifying means; specific means,
A surface inspection apparatus comprising: a correction means for correcting a pixel value of each pixel forming the object surface image based on the gradient angle specified by the second specifying means.
所定の回転軸に取り付けた切削工具を回転させつつ切削加工した物体の表面を撮像する撮像部により撮像された物体表面画像を用いて所定の物体の表面の検査を行う表面検査装置であって、
前記切削工具の回転中心の移動軌跡上の第2の画素が影響を及ぼす第1の画素を特定する第1の特定手段と、
前記第1の特定手段により特定された前記第1の画素における複数の明度勾配のうち、前記切削工具の回転中心の移動軌跡上の第2の画素から前記第1の画素への方向ベクトルの明度勾配を特定する第2の特定手段と、
前記第2の特定手段により特定された勾配角度に基づいて、前記物体表面画像を形成する各画素の画素値を補正する補正手段と
を備えたことを特徴とする表面検査装置。
A surface inspection device that inspects the surface of a predetermined object using an object surface image captured by an imaging unit that images the surface of a cut object while rotating a cutting tool attached to a predetermined rotation axis,
a first specifying means for specifying a first pixel affected by a second pixel on the movement trajectory of the rotation center of the cutting tool;
Among the plurality of brightness gradients in the first pixel specified by the first specifying means, the brightness of a direction vector from a second pixel on the movement trajectory of the rotation center of the cutting tool to the first pixel. a second identifying means for identifying the slope;
A surface inspection apparatus comprising: a correction means for correcting a pixel value of each pixel forming the object surface image based on the gradient angle specified by the second specifying means.
JP2022137749A 2022-08-31 2022-08-31 Surface inspection device and surface inspection method Pending JP2024033867A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2022137749A JP2024033867A (en) 2022-08-31 2022-08-31 Surface inspection device and surface inspection method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2022137749A JP2024033867A (en) 2022-08-31 2022-08-31 Surface inspection device and surface inspection method

Publications (1)

Publication Number Publication Date
JP2024033867A true JP2024033867A (en) 2024-03-13

Family

ID=90193987

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2022137749A Pending JP2024033867A (en) 2022-08-31 2022-08-31 Surface inspection device and surface inspection method

Country Status (1)

Country Link
JP (1) JP2024033867A (en)

Similar Documents

Publication Publication Date Title
JP5371848B2 (en) Tire shape inspection method and tire shape inspection device
JP5726045B2 (en) Tire shape inspection method and tire shape inspection device
WO2009148095A1 (en) Tire shape inspection method and tire shape inspection device
JP5302701B2 (en) Tire shape inspection method, tire shape inspection device
JP4206723B2 (en) Image processing method and image processing apparatus
CN112577969B (en) Defect detection method and defect detection system based on machine vision
JP5302702B2 (en) Tire shape inspection method, tire shape inspection device
JP4644210B2 (en) Pattern defect inspection method
CN113781424B (en) Surface defect detection method, device and equipment
WO2015115499A1 (en) Tool inspection method and tool inspection device
CN116128873A (en) Bearing retainer detection method, device and medium based on image recognition
JP4279833B2 (en) Appearance inspection method and appearance inspection apparatus
JP7163219B2 (en) End mill inspection device
CN112669265B (en) Method for realizing surface defect detection based on Fourier transform and image gradient characteristics
US11493453B2 (en) Belt inspection system, belt inspection method, and recording medium for belt inspection program
CN113916893A (en) Method for detecting die-cutting product defects
JP2024033867A (en) Surface inspection device and surface inspection method
US11768159B2 (en) Belt examination system and computer-readable non-transitory recording medium having stored belt examination program
JP7469740B2 (en) Belt inspection system and belt inspection program
JP2014190805A (en) Data processing method of tire shape inspection device, data processing program of tire shape inspection device, and data processing device of tire shape inspection device
JP5605010B2 (en) Surface inspection method
CN108921882A (en) One kind being based on machine vision button automatic aligning method
JP2014190825A (en) Data processing method of tire shape inspection device, data processing program of tire shape inspection device, and data processing device of tire shape inspection device
JP4247993B2 (en) Image inspection apparatus, image inspection method, control program, and readable storage medium
JP2003042737A (en) Cut workpiece inspecting method