JPH0772909B2 - Welding condition judgment method by visual inspection - Google Patents

Welding condition judgment method by visual inspection

Info

Publication number
JPH0772909B2
JPH0772909B2 JP21403291A JP21403291A JPH0772909B2 JP H0772909 B2 JPH0772909 B2 JP H0772909B2 JP 21403291 A JP21403291 A JP 21403291A JP 21403291 A JP21403291 A JP 21403291A JP H0772909 B2 JPH0772909 B2 JP H0772909B2
Authority
JP
Japan
Prior art keywords
welding
image
value
pixel
differential
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.)
Expired - Lifetime
Application number
JP21403291A
Other languages
Japanese (ja)
Other versions
JPH0554107A (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.)
Panasonic Electric Works Co Ltd
Original Assignee
Matsushita Electric Works Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Matsushita Electric Works Ltd filed Critical Matsushita Electric Works Ltd
Priority to JP21403291A priority Critical patent/JPH0772909B2/en
Publication of JPH0554107A publication Critical patent/JPH0554107A/en
Publication of JPH0772909B2 publication Critical patent/JPH0772909B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【産業上の利用分野】本発明は、溶接物である検査対象
物を撮像した画像にコンピュータによる画像処理を施す
ことによって、溶接状態の良否を判定する外観検査によ
る溶接状態判定方法に関するものである。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a welding condition judging method by visual inspection for judging the quality of a welding condition by subjecting an image of an inspection object, which is a welded object, to image processing by a computer. .

【0002】[0002]

【従来の技術】従来より、溶接物である検査対象物を含
む空間領域をITVカメラ等の画像入力装置で撮像し、
画像入力装置より入力された画像にコンピュータによる
画像処理を施すことによって溶接状態の良否を判定する
方法が提案されている(特開平1−181989号公報
参照)。この方法は、レーザ溶接後の溶接状態を検査す
るものであって、検査対象物の表面に斜め上方から帯状
平行光線を照射し、帯状平行光線が照射されている部位
を検査対象物の表面の垂直上方から画像入力装置によっ
て撮像し、このようにして得た画像に画像処理を施して
溶接状態の良否の判定を行っている。すなわち、検査対
象物の表面の斜め上方から帯状平行光線を照射すること
によって、検査対象物の表面の凹凸の写像を画像入力装
置から取り込むことができるのであって、検査対象物の
表面の高さ情報を得ることができるようになっている。
したがって、撮像した画像に基づいて溶接部分のヒケや
幅不足などの不良を検出することができるのである。
2. Description of the Related Art Conventionally, an image input device such as an ITV camera captures an image of a spatial region including an inspection object which is a welded product,
A method has been proposed in which the quality of a welding state is determined by performing image processing by a computer on an image input from an image input device (see Japanese Patent Laid-Open No. 181989/1989). This method is to inspect the welding state after laser welding, irradiating the strip-shaped parallel rays on the surface of the inspection object obliquely from above, and the portion where the strip-shaped parallel rays are irradiated is the surface of the inspection object. An image is captured from above in the vertical direction, and the image thus obtained is subjected to image processing to determine the quality of the welding state. That is, it is possible to capture the image of the unevenness of the surface of the inspection object from the image input device by irradiating the strip-shaped parallel rays obliquely above the surface of the inspection object, and You can get information.
Therefore, it is possible to detect defects such as sink marks and insufficient width of the welded portion based on the captured image.

【0003】[0003]

【発明が解決しようとする課題】しかしながら、上記方
法では、帯状平行光線の直線性や照度の均一性が検査精
度に影響するものであるから、帯状平行光線を照射する
ための光学系が複雑な構成になるという問題がある。ま
た、高さ情報を含む写像を画像入力装置に取り込んでい
るものであるから、検査対象物の表面に対する帯状平行
光線や画像入力装置の光軸の角度が検査精度に影響し、
また、画像入力装置から取り込んだ画像に対してそのよ
うな角度情報を含めて画像処理を施すことになるから処
理過程が複雑になるという問題もある。
However, in the above method, since the linearity of the strip-shaped parallel rays and the uniformity of the illuminance affect the inspection accuracy, the optical system for irradiating the strip-shaped parallel rays is complicated. There is a problem of becoming a configuration. In addition, since the map including the height information is captured in the image input device, the strip parallel rays with respect to the surface of the inspection object and the angle of the optical axis of the image input device affect the inspection accuracy,
There is also a problem that the processing process becomes complicated because the image processing is performed on the image captured from the image input device by including such angle information.

【0004】本発明は上記問題点の解決を目的とするも
のであり、検査対象物の表面を照射する光源が検査精度
に影響しないようにし、また、検査対象物の表面の高さ
情報に関する処理を含まない画像処理を施すことによっ
て、処理過程を簡略化した外観検査による溶接状態判定
方法を提供しようとするものである。
The present invention is intended to solve the above-mentioned problems, prevents the light source for irradiating the surface of the inspection object from affecting the inspection accuracy, and performs processing relating to height information of the surface of the inspection object. It is intended to provide a welding state determination method by visual inspection that simplifies the processing process by performing image processing that does not include.

【0005】[0005]

【課題を解決するための手段】請求項1の発明では、複
数の被加工物を重ね合わせてレーザ溶接により溶着した
検査対象物の溶接箇所を含む空間領域を画像入力装置に
より撮像した後、画像処理を施すことによって溶接状態
の良否判定を行う外観検査による溶接状態判定方法にお
いて、画像入力装置より入力された濃淡画像である原画
像に基づいて、隣接画素との濃度の変化率に相当する微
分絶対値を各画素の値とした微分絶対値画像と、隣接画
素との濃度の変化方向に対応する微分方向値を各画素の
値とした微分方向値画像と、濃度変化の境界線を示すエ
ッジ画像とを作成し、溶接箇所を含む検査領域を設定し
た後、検査領域内でエッジ画像内の境界線上の画素につ
いて微分絶対値が所定の閾値より大きい画素を溶接特徴
画素として求め、溶接特徴画素の微分方向値に関する度
数分布を、あらかじめ設定されている良品の度数分布と
比較することによって、溶接状態の良否を判定するので
ある。
According to a first aspect of the present invention, a space region including a welded portion of an inspection object, which is obtained by superposing a plurality of workpieces and welding them by laser welding, is imaged by an image input device, and then an image is obtained. In a welding state determination method by visual inspection that determines the quality of the welding state by performing processing, based on an original image that is a grayscale image input from an image input device, a differentiation corresponding to the rate of change in density with adjacent pixels A differential absolute value image in which the absolute value is the value of each pixel, a differential direction value image in which the differential direction value corresponding to the changing direction of the density with an adjacent pixel is the value of each pixel, and an edge indicating the boundary line of the density change After creating an image and setting an inspection area including a welding point, a pixel whose differential absolute value is larger than a predetermined threshold value for a pixel on a boundary line in an edge image in the inspection area is obtained as a welding feature pixel, A frequency distribution relating to the differential direction value of contact feature pixel, by comparing the frequency distribution of the non-defective are preset, it is to judge the quality of the welding conditions.

【0006】請求項2の発明では、検査領域を、一方の
被加工物の上で溶接された部分と溶接されていない部分
とを含むように設定し、溶接特徴画素について微分方向
値の所定範囲の度数の総和が、同範囲の良品の度数の総
和としてあらかじめ設定された閾値よりも大きいときに
溶接状態が良好であると判定するのである。請求項3の
発明では、検査領域を、溶接箇所の内側に設定し、溶接
特徴画素について微分方向値の所定範囲の度数の総和
が、同範囲の良品の度数の総和としてあらかじめ設定さ
れた閾値よりも大きいときに溶接状態が不良であると判
定するのである。
According to the second aspect of the present invention, the inspection area is set so as to include a welded portion and a non-welded portion on one of the workpieces, and a predetermined range of the differential direction value for the welding feature pixel. The welding state is determined to be good when the sum of the frequencies is higher than a threshold value set in advance as the sum of the frequencies of non-defective products in the same range. In the invention of claim 3, the inspection area is set inside the welding spot, and the sum of the frequencies of the differential direction value of the welding feature pixel in the predetermined range is greater than the preset threshold value as the sum of the frequencies of non-defective products in the same range. Is also large, it is determined that the welding state is poor.

【0007】[0007]

【作用】請求項1の方法では、レーザ溶接によって形成
される凹凸の境界線上の画素について微分方向値に関す
る度数分布を求め、良品の度数分布と比較するから、光
源と画像入力装置との位置関係は、検査対象物の表面の
高さ情報を含むような位置関係とする必要がなく、単
に、溶接箇所の凹凸に応じた陰影が形成されるように設
定すればよいことになる。すなわち、帯状平行光線を照
射するような特殊な光源を必要としないのであり、光源
の構成が簡単になるとともに、光源の配置についても制
約が少なくなるのである。また、画像処理についても検
査対象物の表面の高さ情報を含むような複雑な演算を行
う必要がなく、微分処理や細線化処理等の一般的な処理
に加えて加算や大小比較程度の簡単な処理を行えばよい
のであって、画像処理の処理過程が簡単になるのであ
る。
According to the method of claim 1, since the frequency distribution regarding the differential direction value is obtained for the pixels on the boundary line of the unevenness formed by laser welding and compared with the frequency distribution of the non-defective product, the positional relationship between the light source and the image input device is obtained. Does not need to have a positional relationship that includes height information of the surface of the inspection object, and may be set so that a shadow corresponding to the unevenness of the welding location is formed. That is, since no special light source for irradiating the band-shaped parallel rays is required, the structure of the light source is simplified and the restrictions on the arrangement of the light sources are reduced. Also, with regard to image processing, there is no need to perform complicated calculations that include information about the height of the surface of the inspection target. In addition to general processing such as differential processing and thinning processing, addition and simple comparison of size comparison Therefore, the processing steps of the image processing are simplified.

【0008】請求項2および請求項3の方法は望ましい
実施態様であって、検査領域の設定方法を工夫すること
によって良否判定が行いやすくなっており、また、検査
対象物についての微分方向値に関する度数分布と良品の
度数分布との比較を、微分方向値の範囲を制限して、そ
の範囲の度数を閾値と比較するだけの簡単な処理で行う
ようにしているから、溶接箇所の良否判定を行うための
画像処理の処理過程が一層簡単になるのである。
The methods of claims 2 and 3 are desirable embodiments, and the quality of the inspection can be easily determined by devising the method of setting the inspection area, and the differential direction value of the inspection object can be easily determined. Since the frequency distribution and the frequency distribution of non-defective products are compared by a simple process of limiting the range of differential direction values and comparing the frequency of that range with a threshold value, it is possible to judge the quality of the welded part. The process of the image processing for performing the process becomes simpler.

【0009】[0009]

【実施例】【Example】

(実施例1)本実施例では、レーザスポット溶接におけ
る溶接状態の不良を検出する場合について説明する。図
2に示すように一対の被加工物11a,11bが互いに
重ねられ、被加工物11a,11bの接触部分に跨がる
ようにレーザビームが照射されることによって、図3の
ように表面に凹所12が形成された状態で両被加工物1
1a,11bが溶着される(図4参照)。検査対象物で
ある被加工物11a,11bの表面状態は、ITVカメ
ラ等の画像入力装置1により撮像されるのであって、溶
着前に被加工物11a,11bの表面で反射された光源
(図示せず)からの正反射光(光線を矢印で示す)が画
像入力装置1に入射するような位置関係で光源が配置さ
れる。したがって、溶着後には凹所12では正反射光が
得られず、溶接によって形成された凹所12と、それ以
外の部分とでは画像入力装置1から取り込んだ画像にコ
ントラストが得られることになる。本実施例では、この
ように形成された画像のコントラストを利用して溶接状
態の良否を判定するものである。
(Embodiment 1) In this embodiment, a case of detecting a defective welding state in laser spot welding will be described. As shown in FIG. 2, a pair of workpieces 11a and 11b are overlapped with each other, and a laser beam is applied so as to straddle the contact portions of the workpieces 11a and 11b, so that the surface is exposed as shown in FIG. Both workpieces 1 with the recess 12 formed
1a and 11b are welded (see FIG. 4). The surface condition of the workpieces 11a and 11b, which are inspection objects, is captured by the image input device 1 such as an ITV camera, and the light source reflected by the surfaces of the workpieces 11a and 11b before welding (see FIG. The light sources are arranged in such a positional relationship that specularly reflected light (light rays are shown by arrows) from (not shown) enter the image input apparatus 1. Therefore, after welding, regular reflection light cannot be obtained in the recess 12, and the recess 12 formed by welding and the other portion can obtain contrast in the image captured from the image input device 1. In this embodiment, the quality of the welded state is determined by using the contrast of the image formed in this way.

【0010】画像入力装置1により取り込まれた画像
は、図9に示すように、各画素の濃度がアナログ−デジ
タル変換部2においてデジタル信号に変換され、前処理
部3において以下の前処理が施されることによって、ア
ナログ−デジタル変換部2の出力として得られる原画像
のほかに、微分絶対値画像、微分方向値画像、エッジ画
像が得られる。
As shown in FIG. 9, the density of each pixel of the image captured by the image input device 1 is converted into a digital signal by the analog-digital converter 2, and the following pre-processing is performed by the pre-processor 3. As a result, in addition to the original image obtained as the output of the analog-digital conversion unit 2, a differential absolute value image, a differential direction value image, and an edge image are obtained.

【0011】すなわち、検査対象物を含む空間領域を撮
像して得られる原画像は濃淡画像であり、この濃淡画像
から検査対象物の輪郭線等のエッジを抽出する処理は、
「エッジは濃度変化が大きい部分に対応している」とい
う考え方に基づいている。したがって、濃度を微分する
ことによってエッジの抽出を行なう。微分処理は、図1
0に示すように、原画像P1 を3×3画素の局所並列ウ
インドウWに分割して行なう。つまり、原画像P1 の中
で注目する画素Eを中心として、その画素Eの周囲の8
画素(8近傍)A〜D,F〜Iとで局所並列ウインドウ
Wを形成し、局所並列ウインドウW内の画素A〜Iの濃
度の縦方向の濃度変化ΔVと横方向の濃度変化ΔHとを
次式によって求める。
That is, the original image obtained by imaging the spatial region including the inspection object is a grayscale image, and the processing for extracting the edge such as the contour line of the inspection target from the grayscale image is
It is based on the idea that "the edge corresponds to a portion where the density change is large". Therefore, the edge is extracted by differentiating the density. The differential processing is shown in Fig. 1.
As shown in 0, the original image P 1 is divided into 3 × 3 pixel local parallel windows W. That is, with the pixel E of interest in the original image P 1 as the center, 8 pixels surrounding the pixel E
The pixels (near 8) A to D and F to I form a local parallel window W, and the vertical density change ΔV and the horizontal density change ΔH of the density of the pixels A to I in the local parallel window W are defined. Calculate by the following formula.

【0012】ΔV=(A+B+C)−(G+H+I) ΔH=(A+D+G)−(C+F+I) ただし、A〜Iは対応する画素の濃度を示している。さ
らに、画素Eについての微分絶対値abs(E) と微分方向
値deg(E) とを次式によって求める。 abs(E) =(ΔV2 +ΔH2 1/2 deg(E) =tan -1(ΔV/ΔH)+(π/2) 微分絶対値abs(E) は、原画像の注目する画素Eの近傍
領域における濃度の変化率を表し、微分方向値deg(E)
は、同近傍領域における濃度変化の方向に直交する方向
を表している。以上の演算を原画像P1 の全画素につい
て行なうことにより、検査対象物の輪郭線のような濃度
変化が大きい部分と、その変化の方向とを抽出すること
ができるのである。ここに、各画素の値が、微分絶対値
abs(E) である画像を微分絶対値画像、微分方向値deg
(E) である画像を微分方向値画像と呼ぶ。
ΔV = (A + B + C)-(G + H + I) ΔH = (A + D + G)-(C + F + I) where A to I represent the densities of the corresponding pixels. Further, the differential absolute value abs (E) and the differential direction value deg (E) for the pixel E are obtained by the following equation. abs (E) = (ΔV 2 + ΔH 2 ) 1/2 deg (E) = tan −1 (ΔV / ΔH) + (π / 2) The differential absolute value abs (E) is the pixel E of interest in the original image. Represents the rate of change of density in the vicinity area, and the differential direction value
Indicates a direction orthogonal to the direction of density change in the same neighborhood area. By performing the above calculation for all the pixels of the original image P 1 , it is possible to extract a portion such as the contour line of the inspection object where the density change is large and the direction of the change. Here, the value of each pixel is the differential absolute value
Image that is abs (E) is the differential absolute value image, differential direction value deg
The image of (E) is called a differential direction value image.

【0013】次に細線化処理が施される。細線化処理
は、微分絶対値が大きいほど濃度変化が大きいことを表
わしている点に着目して行なわれる。すなわち、各画素
の微分絶対値を周囲の画素の微分絶対値と比較し、周囲
の画素よりも大きくなるものを連結していくことによ
り、1画素の幅を有したエッジを抽出するのである。図
11に示すように、各画素の位置をX−Y座標で表わ
し、微分絶対値をZ座標で表した微分絶対値画像P2
考えれば、細線化処理は、この曲面における稜線を求め
ることに相当する。ここまでの処理により、微分絶対値
の大小にかかわらず、すべての稜線が抽出される。この
段階で得られている稜線には、ノイズ等による不要な小
さな山も含まれているから、図12に示すように、適宜
閾値SLを設定し、この閾値SL以上の値のみを採用し
てノイズ成分を除去する。この処理で得られた画像は、
原画像のコントラストが不十分であるときやノイズが多
いようなときには不連続線になりやすい。そこで、エッ
ジ延長処理を行なう。エッジ延長処理では、不連続線の
端点から始めて、注目する画素とその周囲の画素とを比
較し、次式で表わされる評価関数f(J) がもっとも大き
くなる方向に線を延長し、他の線の端点に衝突するまで
これを続ける。
Next, thinning processing is performed. The thinning process is performed by paying attention to the fact that the larger the differential absolute value, the larger the density change. That is, the differential absolute value of each pixel is compared with the differential absolute value of the surrounding pixels, and those having a larger value than the surrounding pixels are connected to extract an edge having a width of one pixel. As shown in FIG. 11, considering the differential absolute value image P 2 in which the position of each pixel is represented by XY coordinates and the differential absolute value is represented by Z coordinates, the thinning process is to find the ridgeline on this curved surface. Equivalent to. By the processing up to this point, all ridgelines are extracted regardless of the magnitude of the differential absolute value. Since the ridge line obtained at this stage also includes unnecessary small peaks due to noise or the like, as shown in FIG. 12, a threshold SL is appropriately set, and only a value equal to or higher than this threshold SL is adopted. Remove noise components. The image obtained by this process is
When the contrast of the original image is insufficient or when there is much noise, discontinuous lines are likely to occur. Therefore, edge extension processing is performed. In the edge extension processing, starting from the end point of the discontinuous line, the pixel of interest and the surrounding pixels are compared, the line is extended in the direction in which the evaluation function f (J) represented by the following equation becomes the largest, and the other Continue doing this until you hit the end of the line.

【0014】 f(J) =abs(J)・cos(deg(J)−deg(0)) ・cos((J−1)π/4−deg(O)) ここに、deg(O)は中心画素(局所並列ウインドウWのE
に相当する)の微分方向値、deg(J)は隣接画素(局所並
列ウインドウWの8近傍に相当する)の微分方向値、ab
s(J)は隣接画素の微分絶対値である。ただし、J=1,
2,……,8である。
F (J) = abs (J) · cos (deg (J) −deg (0)) · cos ((J−1) π / 4−deg (O)) where deg (O) is Center pixel (E of the local parallel window W
Deg (J) is the differential direction value of an adjacent pixel (corresponding to 8 neighborhoods of the local parallel window W), ab
s (J) is the differential absolute value of the adjacent pixel. However, J = 1,
2, ..., 8.

【0015】以上の処理により、原画像P1 において濃
度変化が大きい部分の輪郭をなぞるようなエッジ画像が
得られる。こうして、図13に示すように、原画像
1 、微分絶対値画像P2 、微分方向値画像P3 、エッ
ジ画像P4 の4種類の画像が得られ、各画像が原画像メ
モリ4、微分絶対値画像メモリ5、微分方向値画像メモ
リ6、エッジ画像メモリ7にそれぞれ格納される。以下
の説明では、各画像P1 〜P4 の画素の位置をX−Y座
標で表現するものとし、各画像における画素の値をそれ
ぞれf1(x,y) 、f2(x,y) 、f3(x,y) 、f
4(x,y) とする。
By the above processing, an edge image that traces the contour of the portion of the original image P 1 where the density change is large can be obtained. Thus, as shown in FIG. 13, four types of images of the original image P 1 , the differential absolute value image P 2 , the differential direction value image P 3 , and the edge image P 4 are obtained, and each image is acquired by the original image memory 4, the differential image. It is stored in the absolute value image memory 5, the differential direction value image memory 6, and the edge image memory 7, respectively. In the following description, the pixel positions of the images P 1 to P 4 are represented by XY coordinates, and the pixel values in each image are f 1 (x, y) and f 2 (x, y), respectively. , F 3 (x, y), f
4 (x, y).

【0016】原画像は濃淡画像であって、各画素の濃度
a(=f1(x,y) )は、たとえば8ビットで表されて
0≦a≦255となる。また、微分絶対値画像の各画素
の微分絶対値b(=f2(x,y) )は、たとえば6ビッ
トで表されて0≦b≦63となり、微分方向値画像の各
画素の微分方向値c(=f3(x,y) )は、たとえば1
6方向で表されて0≦c≦15となる。エッジ画像につ
いては、線の有無のみであるから、線となる画素の値は
「1」、それ以外の画素の値は「0」になる。つまり、
4(x,y) の値域は{0,1}になる。なお、以下の
説明においては、濃度という用語は白の濃度を表し、濃
度値が大きいほど明るいものとする。
The original image is a grayscale image, and the density a (= f 1 (x, y)) of each pixel is represented by, for example, 8 bits and 0 ≦ a ≦ 255. Further, the differential absolute value b (= f 2 (x, y)) of each pixel of the differential absolute value image is represented by 6 bits, for example, 0 ≦ b ≦ 63, and the differential direction of each pixel of the differential direction value image The value c (= f 3 (x, y)) is, for example, 1
Expressed in six directions, 0 ≦ c ≦ 15. As for the edge image, only the presence / absence of a line is present, and therefore the value of the pixel forming the line is “1” and the value of the other pixels is “0”. That is,
The range of f 4 (x, y) is {0, 1}. In the following description, the term density represents white density, and the larger the density value, the brighter.

【0017】演算処理部8は、マイクロコンピュータに
よる画像処理を施す部分であって、図1に示す処理を行
う。すなわち、図5に示すように、原画像メモリ4に格
納された原画像に基づいて溶接前に正反射光が画像入力
装置1に入射するように設定しておいた一方の被加工物
11aの上で明暗を有する部分に検査領域M1 を設定す
る(ステップS1)。検査領域M1 は、一方の被加工物
11aの上で溶着部分と非溶着部分とに跨がるように設
定するのであれば、任意の形状に設定することができ
る。次に、図6に矢印で示すように、設定された検査領
域M1 の中でエッジ画像メモリ7に格納されたデータに
対するラスタ走査を行い(ステップS2)、値が「1」
である画素をエッジフラグ点として検出する。こうして
得られたエッジフラグ点について、微分絶対値画像メモ
リ5から同一座標を有する画素の値(微分絶対値)を求
め、求めた微分絶対値Aと所定の閾値SL1との大小を
比較する(ステップS4)。ここで、 A>SL1 という条件が満たされると、コントラストが大きい部分
であるから、凹所12の境界線上の点と推定される。こ
のようにして求めた画素を溶接特徴画素と呼ぶことにす
る。そこで、微分方向値画像メモリ6から、溶接特徴画
素の値(微分方向値)を読み出し、微分方向値ごとの度
数を積算する(ステップS5)。すなわち、溶接特徴画
素が見つかると微分方向値ごとに分類して個数をインク
リメントするのである。検査領域M1 のすべての画素を
走査し終わるまで上記処理を繰り返し(ステップS
6)、溶接特徴画素の微分方向値に関する度数分布を求
める。
The arithmetic processing section 8 is a section for performing image processing by a microcomputer, and performs the processing shown in FIG. That is, as shown in FIG. 5, based on the original image stored in the original image memory 4, one of the workpieces 11 a, which is set so that the specular reflection light enters the image input device 1 before welding, is displayed. The inspection area M 1 is set in the above-mentioned bright and dark portion (step S1). The inspection region M 1 can be set in any shape as long as it is set so as to straddle the welded portion and the non-welded portion on the one workpiece 11a. Next, as shown by the arrow in FIG. 6, raster scanning is performed on the data stored in the edge image memory 7 in the set inspection area M 1 (step S2), and the value is “1”.
Is detected as an edge flag point. With respect to the edge flag point thus obtained, the value (differential absolute value) of the pixel having the same coordinates is obtained from the differential absolute value image memory 5, and the obtained differential absolute value A and the predetermined threshold value SL1 are compared in size (step). S4). Here, when the condition of A> SL1 is satisfied, it is estimated that the point is on the boundary line of the recess 12 because it is a portion where the contrast is large. The pixel thus obtained will be referred to as a welding feature pixel. Therefore, the value of the welding feature pixel (differential direction value) is read from the differential direction value image memory 6 and the frequency for each differential direction value is integrated (step S5). That is, when a welding feature pixel is found, it is classified for each differential direction value and the number is incremented. The above process is repeated until all the pixels in the inspection area M 1 have been scanned (step S
6) Obtain the frequency distribution regarding the differential direction value of the welding feature pixel.

【0018】このようにして度数分布を求めた後、あら
かじめ登録されている良品の度数分布との比較を行うこ
とにより溶接状態の良否を判定する。溶接がなされてい
ると、凹所12が形成されることによってコントラスト
が強くなるから溶接特徴点の数が多くなって図7(a)
のように微分方向値の度数が大きくなる。未溶接や溶接
不具合の場合には、凹所12が形成されていないから原
画像のコントラストが小さく、溶接特徴画素の数が少な
くなる。したがって、図7(b)に示すように、微分方
向値の度数が小さくなる。また、溶接がなされていると
きには、微分方向値の度数は2極に集中するが、溶接状
態が良好であると集中度は低く、不良であるほど集中度
が高くなる。このような知見に基づいて、微分方向値に
ついて度数が集中する2極について範囲を設定し、各範
囲の度数の総和α,βと所定の閾値SL2,SL3との
大小を比較する(ステップS7,S8)。ここで、 α>SL2 β>SL3 がともに満たされたときには、溶接状態が良好であると
判定し、いずれか一方でも満たされない場合には、不良
であると判定する。
After the frequency distribution is obtained in this way, the quality of the welded state is determined by comparing it with the frequency distribution of a non-defective product registered in advance. When welding is performed, the contrast is increased due to the formation of the recess 12, so that the number of welding feature points increases and the number of welding feature points increases, as shown in FIG.
The frequency of the differential direction value increases as shown in. In the case of non-welding or welding failure, since the recess 12 is not formed, the contrast of the original image is small and the number of welding characteristic pixels is small. Therefore, as shown in FIG. 7B, the frequency of the differential direction value becomes small. Further, when welding is performed, the frequencies of the differential direction values are concentrated in two poles. If the welding state is good, the concentration is low, and if the welding is poor, the concentration is high. Based on such knowledge, a range is set for two poles in which the frequencies are concentrated with respect to the differential direction value, and the sums α and β of the frequencies in each range are compared with predetermined thresholds SL2 and SL3 (step S7, S8). Here, when α> SL2 β> SL3 are both satisfied, it is determined that the welding state is good, and when either one is not satisfied, it is determined that the welding condition is bad.

【0019】(実施例2)実施例1では一方の被加工物
11aの上で検査領域M1 を設定しているから、溶接状
態が不具合である場合にも良品と認識される場合がない
わけではない。そこで、本実施例では、図8に示すよう
に、両被加工物11a,11bの上に跨がるとともに、
凹所12の中において検査領域M2 を設定する。溶着部
分の深さは、溶接状態が良好であれば100μm程度に
なるが、溶接状態が不具合であると20〜30μm程度
の深さになることがわかっている。この場合、溶接状態
が不具合であると、凹所12の底部付近からの正反射光
が増加して凹所12の周部付近との間のコントラストが
強くなる。本実施例では、これを利用して溶接状態の良
否を判定するものである。すなわち、検査領域M2 につ
いて微分方向値に関する度数分布を求めた後、微分方向
値の特定の範囲(2極)についての度数の総和γ,δと
所定の閾値SL4,SL5との大小を比較する。ここ
で、 γ>SL4 δ>SL5 がともに満たされたときには、溶接状態が不良であると
判定し、いずれか一方でも満たされない場合には、良好
であると判定するのである。ここで、溶接状態が良好で
あっても正反射光が生じる場合があるが、正反射光が生
じる位置がずれており、微分方向値の度数分布も異なる
形になるから、上記判定条件によって良否を識別するこ
とができる。他の手順については実施例1と同様である
から説明を省略する。
(Embodiment 2) In Embodiment 1, since the inspection area M 1 is set on one of the workpieces 11a, even if the welding state is defective, it may not be recognized as a good product. is not. Therefore, in this embodiment, as shown in FIG. 8, while straddling over both the workpieces 11a and 11b,
An inspection area M 2 is set in the recess 12. It is known that the depth of the welded portion is about 100 μm when the welding state is good, but it is about 20 to 30 μm when the welding state is defective. In this case, if the welding state is defective, the specularly reflected light from the vicinity of the bottom of the recess 12 increases and the contrast with the vicinity of the periphery of the recess 12 becomes stronger. In this embodiment, this is used to judge the quality of the welding state. That is, after obtaining the frequency distribution regarding the differential direction value for the inspection region M 2 , the magnitudes of the total sum γ, δ of the frequency for the specific range (two poles) of the differential direction value and the predetermined threshold values SL4, SL5 are compared. . Here, when both γ> SL4 δ> SL5 are satisfied, it is determined that the welding state is bad, and when neither is satisfied, it is determined that the welding state is good. Here, even if the welding state is good, specular reflection light may be generated, but the position where specular reflection light is generated is displaced and the frequency distribution of the differential direction value is also different. Can be identified. The other procedures are the same as those in the first embodiment, and the description thereof will be omitted.

【0020】(実施例3)本実施例は、実施例1と実施
例2との方法を組み合わせたものであって、検査領域M
1 による判定と、検査領域M2 による判定とを行うこと
によって、良否判定を一層正確に行えるようにしたもの
である。ここで、両方で良好と判定されたとき以外は、
不良と判定するようにすれば、良品に対する信頼性が高
くなるものである。
(Embodiment 3) This embodiment is a combination of the methods of Embodiments 1 and 2, and has an inspection area M
By making the judgment according to 1 and the judgment according to the inspection region M 2 , the quality judgment can be made more accurately. Here, except when both are judged to be good,
If it is judged as defective, the reliability of non-defective products is improved.

【0021】[0021]

【発明の効果】請求項1の発明は、レーザ溶接によって
形成される凹凸の境界線上の画素について微分方向値に
関する度数分布を求め、良品の度数分布と比較するか
ら、光源と画像入力装置との位置関係は、検査対象物の
表面の高さ情報を含むような位置関係とする必要がな
く、単に、溶接箇所の凹凸に応じた陰影が形成されるよ
うに設定すればよいことになる。すなわち、帯状平行光
線を照射するような特殊な光源を必要としないのであ
り、光源の構成が簡単になるとともに、光源の配置につ
いても制約が少なくなるという利点がある。また、画像
処理についても検査対象物の表面の高さ情報を含むよう
な複雑な演算を行う必要がなく、微分処理や細線化処理
等の一般的な処理に加えて加算や大小比較程度の簡単な
処理を行えばよいのであって、画像処理の処理過程が簡
単になるという効果を奏する。
According to the first aspect of the present invention, since the frequency distribution regarding the differential direction value is obtained for the pixels on the boundary line of the unevenness formed by laser welding and compared with the frequency distribution of the non-defective product, the light source and the image input device are combined. The positional relationship does not need to include the height information of the surface of the inspection object, and may be set so that a shadow corresponding to the unevenness of the welding location is formed. That is, there is no need for a special light source for irradiating a band-shaped parallel light beam, which is advantageous in that the structure of the light source is simplified and the arrangement of the light sources is reduced. Also, with regard to image processing, there is no need to perform complicated calculations that include information about the height of the surface of the inspection target. In addition to general processing such as differential processing and thinning processing, addition and simple comparison of size comparison Since it suffices to perform such processing, there is an effect that the processing process of image processing is simplified.

【0022】請求項2および請求項3の方法では、検査
領域の設定方法を工夫することによって良否判定が行い
やすくなるのであり、また、検査対象物についての微分
方向値に関する度数分布と良品の度数分布との比較を、
微分方向値の範囲を制限して、その範囲の度数を閾値と
比較するだけの簡単な処理で行うようにしているから、
溶接箇所の良否判定を行うための画像処理の処理過程が
一層簡単になるという効果がある。
In the methods of claims 2 and 3, the quality of the judgment can be easily made by devising the method of setting the inspection area, and the frequency distribution regarding the differential direction value of the inspection object and the frequency of the non-defective product. Compare with the distribution,
Since the range of the differential direction value is limited and the frequency of the range is compared with the threshold value, it is performed by a simple process.
This has the effect of further simplifying the process of image processing for determining the quality of the welded portion.

【図面の簡単な説明】[Brief description of drawings]

【図1】実施例1の手順を示す説明図である。FIG. 1 is an explanatory diagram showing a procedure of a first embodiment.

【図2】実施例の溶接前の検査対象物での反射光の状態
を示す説明図である。
FIG. 2 is an explanatory diagram showing a state of reflected light on an inspection object before welding in the example.

【図3】実施例の溶接後の検査対象物での反射光の状態
を示す説明図である。
FIG. 3 is an explanatory diagram showing a state of reflected light on an inspection object after welding in the embodiment.

【図4】実施例における被加工物の溶接状態を示す斜視
図である。
FIG. 4 is a perspective view showing a welded state of a workpiece in the example.

【図5】実施例1における検査領域の設定例を示す図で
ある。
FIG. 5 is a diagram showing an example of setting an inspection area in the first embodiment.

【図6】実施例におけるラスタ走査の概念を説明する図
である。
FIG. 6 is a diagram illustrating a concept of raster scanning according to an embodiment.

【図7】実施例1における微分方向値に関する度数分布
の例を示し、(a)は溶接状態が良好の場合、(b)は
溶接状態が不良の場合を示す。
7A and 7B show examples of frequency distributions regarding differential direction values in Example 1, where FIG. 7A shows a case where the welding state is good, and FIG. 7B shows a case where the welding state is bad.

【図8】実施例2における検査領域の設定例を示す図で
ある。
FIG. 8 is a diagram showing an example of setting an inspection area in the second embodiment.

【図9】実施例に用いる処理回路のブロック図である。FIG. 9 is a block diagram of a processing circuit used in the embodiment.

【図10】実施例における局所並列ウインドウの概念を
示し、(a)は画像内での位置、(b)は局所並列ウイ
ンドウの画素の構成を示す図である。
10A and 10B are views showing the concept of a local parallel window in the embodiment, FIG. 10A is a position in an image, and FIG. 10B is a diagram showing a pixel configuration of the local parallel window.

【図11】実施例における微分絶対値画像の概念を示す
図である。
FIG. 11 is a diagram showing a concept of a differential absolute value image in the example.

【図12】実施例において微分絶対値画像からエッジ画
像を得る処理の説明図である。
FIG. 12 is an explanatory diagram of a process of obtaining an edge image from a differential absolute value image in the embodiment.

【図13】実施例における原画像、微分絶対値画像、微
分方向値画像、エッジ画像の関係を示す図である。
FIG. 13 is a diagram showing a relationship among an original image, a differential absolute value image, a differential direction value image, and an edge image in the example.

【符号の説明】[Explanation of symbols]

1 画像入力装置 2 アナログ−ディジタル変換部 3 前処理部 4 原画像メモリ 5 微分絶対値画像メモリ 6 微分方向値画像メモリ 7 エッジ画像メモリ 8 演算処理部 1 Image Input Device 2 Analog-Digital Converter 3 Preprocessor 4 Original Image Memory 5 Differential Absolute Value Image Memory 6 Differential Direction Value Image Memory 7 Edge Image Memory 8 Arithmetic Processor

───────────────────────────────────────────────────── フロントページの続き (51)Int.Cl.6 識別記号 庁内整理番号 FI 技術表示箇所 G01N 21/88 Z 7172−2J H04N 7/18 B ─────────────────────────────────────────────────── ─── Continuation of the front page (51) Int.Cl. 6 Identification code Office reference number FI Technical display location G01N 21/88 Z 7172-2J H04N 7/18 B

Claims (3)

【特許請求の範囲】[Claims] 【請求項1】 複数の被加工物を重ね合わせてレーザ溶
接により溶着した検査対象物の溶接箇所を含む空間領域
を画像入力装置により撮像した後、画像処理を施すこと
によって溶接状態の良否判定を行う外観検査による溶接
状態判定方法において、画像入力装置より入力された濃
淡画像である原画像に基づいて、隣接画素との濃度の変
化率に相当する微分絶対値を各画素の値とした微分絶対
値画像と、隣接画素との濃度の変化方向に対応する微分
方向値を各画素の値とした微分方向値画像と、濃度変化
の境界線を示すエッジ画像とを作成し、溶接箇所を含む
検査領域を設定した後、検査領域内でエッジ画像内の境
界線上の画素について微分絶対値が所定の閾値より大き
い画素を溶接特徴画素として求め、溶接特徴画素の微分
方向値に関する度数分布を、あらかじめ設定されている
良品の度数分布と比較することによって、溶接状態の良
否を判定することを特徴とする外観検査による溶接状態
判定方法。
1. A pass / fail judgment of a welding state is performed by imaging an image of a spatial region including a welded portion of an inspection object welded by laser welding in which a plurality of workpieces are superposed and welded, and then image processing is performed. In the welding state determination method by the visual inspection to be performed, based on the original image which is a grayscale image input from the image input device, the differential absolute value corresponding to the change rate of the density with the adjacent pixel is set as the value of each pixel. A value image, a differential direction value image in which the differential direction value corresponding to the changing direction of the density of adjacent pixels is used as the value of each pixel, and an edge image indicating the boundary line of the density change are created, and the inspection including the welding point is made. After setting the area, the pixel on the boundary line in the edge image whose differential absolute value is larger than a predetermined threshold is found as a welding feature pixel in the inspection area, and the frequency related to the differential direction value of the welding feature pixel is obtained. A welding state determination method by visual inspection, characterized by determining the quality of the welding state by comparing the distribution with a preset frequency distribution of non-defective products.
【請求項2】 検査領域を、一方の被加工物の上で溶接
された部分と溶接されていない部分とを含むように設定
し、溶接特徴画素について微分方向値の所定範囲の度数
の総和が、同範囲の良品の度数の総和としてあらかじめ
設定された閾値よりも大きいときに溶接状態が良好であ
ると判定することを特徴とする請求項1記載の外観検査
による溶接状態判定方法。
2. The inspection region is set so as to include a welded portion and a non-welded portion on one of the workpieces, and the sum of frequencies in a predetermined range of the differential direction value for the welding feature pixel is set. The welding state determining method according to claim 1, wherein the welding state is determined to be good when the sum of the frequencies of non-defective products in the same range is larger than a preset threshold value.
【請求項3】 検査領域を、溶接箇所の内側に設定し、
溶接特徴画素について微分方向値の所定範囲の度数の総
和が、同範囲の良品の度数の総和としてあらかじめ設定
された閾値よりも大きいときに溶接状態が不良であると
判定することを特徴とする請求項1記載の外観検査によ
る溶接状態判定方法。
3. The inspection area is set inside the welding point,
It is characterized in that the welding state is determined to be defective when the sum of the frequencies of the differential direction values in the predetermined range of the welding feature pixels is larger than a threshold value set in advance as the sum of the frequencies of non-defective products in the same range. Item 1. A method for determining a welding state by the visual inspection according to Item 1.
JP21403291A 1991-08-27 1991-08-27 Welding condition judgment method by visual inspection Expired - Lifetime JPH0772909B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP21403291A JPH0772909B2 (en) 1991-08-27 1991-08-27 Welding condition judgment method by visual inspection

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP21403291A JPH0772909B2 (en) 1991-08-27 1991-08-27 Welding condition judgment method by visual inspection

Publications (2)

Publication Number Publication Date
JPH0554107A JPH0554107A (en) 1993-03-05
JPH0772909B2 true JPH0772909B2 (en) 1995-08-02

Family

ID=16649149

Family Applications (1)

Application Number Title Priority Date Filing Date
JP21403291A Expired - Lifetime JPH0772909B2 (en) 1991-08-27 1991-08-27 Welding condition judgment method by visual inspection

Country Status (1)

Country Link
JP (1) JPH0772909B2 (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4000417B2 (en) * 2002-07-22 2007-10-31 四国化工機株式会社 Quality evaluation method of weld bead and shape measurement method therefor
JP5033076B2 (en) * 2008-07-28 2012-09-26 パナソニック株式会社 Appearance inspection method and apparatus
JP5033077B2 (en) * 2008-07-28 2012-09-26 パナソニック株式会社 Method and apparatus for inspecting appearance of molded product
JP7308461B2 (en) * 2018-12-19 2023-07-14 パナソニックIpマネジメント株式会社 Appearance inspection device and method for improving the accuracy of determining the presence or absence and type of shape defects in welded locations using the same, welding system and work welding method using the same

Also Published As

Publication number Publication date
JPH0554107A (en) 1993-03-05

Similar Documents

Publication Publication Date Title
JP3051279B2 (en) Bump appearance inspection method and bump appearance inspection device
US4974261A (en) Optical surface inspection method
JP3890844B2 (en) Appearance inspection method
JP4293653B2 (en) Appearance inspection method
JPH0772909B2 (en) Welding condition judgment method by visual inspection
JP3508518B2 (en) Appearance inspection method
JP2758823B2 (en) Weld appearance inspection method
JP3159063B2 (en) Surface defect inspection equipment
JPH06103275B2 (en) Defect extraction method by visual inspection
JP2686053B2 (en) Defect inspection method by visual inspection
JPH0718811B2 (en) Defect inspection method
JP3260425B2 (en) Pattern edge line estimation method and pattern inspection device
JP2710685B2 (en) Defect detection method by visual inspection
JPH08190633A (en) Defect judging method
JP2003311464A (en) Instrument and method for inspecting welded state in annular welded part
JPH11132743A (en) Defect inspecting device by image signal processing
JP3494006B2 (en) Appearance inspection method
JPH02187651A (en) Image processing method
JPH1010053A (en) Inspection device for surface defect
JP2003247954A (en) Defect detection method for round body circumference
JPH10247669A (en) Device and method for inspecting bonding wire
JP3189604B2 (en) Inspection method and device
JPH1114317A (en) Appearance inspection method and device
JPH09113467A (en) Method for deciding defect
JPS61126455A (en) Image processing method

Legal Events

Date Code Title Description
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 19960123

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20070802

Year of fee payment: 12

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20080802

Year of fee payment: 13

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090802

Year of fee payment: 14

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090802

Year of fee payment: 14

S533 Written request for registration of change of name

Free format text: JAPANESE INTERMEDIATE CODE: R313533

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090802

Year of fee payment: 14

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090802

Year of fee payment: 14

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20100802

Year of fee payment: 15

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110802

Year of fee payment: 16

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120802

Year of fee payment: 17

EXPY Cancellation because of completion of term
FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120802

Year of fee payment: 17