Download as pdf or txt
Download as pdf or txt
You are on page 1of 8

NDT&E International 44 (2011) 563–570

Contents lists available at ScienceDirect

NDT&E International
journal homepage: www.elsevier.com/locate/ndteint

Discontinuities detection in welded joints based on inverse


surface thresholding
Haniza Yazid a,b,n, H. Arof a, Hafizal Yazid c, Sahrim Ahmad c, A.A. Mohamed c, F. Ahmad d
a
Electrical Engineering Department, Faculty of Engineering, University of Malaya, 50603 Kuala Lumpur, Malaysia
b
School of Mechatronic Engineering, Universiti Malaysia Perlis, 02600, Ulu Pauh, Arau, Perlis, Malaysia
c
Industrial Technology Division, Block 34, Malaysian Institute for Nuclear Technology Research (MINT), Bangi, 43000 Kajang, Malaysia
d
Electrical Engineering Department, UTMSPACE, UTM International Campus, 54100 Kuala Lumpur, Malaysia

a r t i c l e i n f o abstract

Article history: Automated detection of welding defects in radiographic images becomes nontrivial when uneven
Received 28 July 2010 illumination, contrast and noise are present. In this paper, a new approach using surface thresholding
Received in revised form method is proposed to detect defects in radiographic images of welding joints. In the first stage, several
26 April 2011
image processing techniques namely fuzzy c means clustering, region filling, mean filtering, edge
Accepted 3 June 2011
Available online 17 June 2011
detection, Otsu thresholding, and morphological operations method are utilized to locate the area
where defects might exist. This is followed by the construction of the inverse thresholding surface and
Keywords: its implementation to locate defects in the identified area. The proposed method was tested on 60
Non-destructive testing radiographic images and it obtained 94.6% sensitivity. Its performance is compared to that of the
Welded joints
watershed segmentation, which obtained 69.6%.
Inverse surface thresholding
& 2011 Elsevier Ltd. All rights reserved.
Fuzzy c means clustering

1. Introduction an algorithm that automatically locates discontinuities that exist


in radiographic images of welded joints.
Products made of polymer and metal are subjected to test and Algorithms used for detecting discontinuities in weldment
evaluation before they are considered safe to be used. One of the usually comprise a number of steps. These steps may constitute
parts that deserve thorough scrutiny is the welded joints that pre-processing, segmentation and classification. The segmenta-
hold the metal structure together. Consequently, industrial radio- tion step is crucial as the result from this stage strongly influence
graphy is used as one of the non-destructive techniques to the final quality of interpretation [3]. In this step, locations and
evaluate the quality of the welded joint. In Ditchburn et al. [1], features of the objects of interest like welding defects are
the latest development on radiographic inspection, ultrasonic, extracted and separated from the background. Usually, welding
alternating current potential drop technique, measurement of defects in radiographic images have lower intensity than non-
residue stress and in production weld inspection had been defective area that make up the background. It is sufficient to use
reviewed. The advancement in computer technology spurs the this feature to identify defects as the intensity difference is large.
use of image analysis and pattern recognition systems to assist The intensity of an area is essentially based on the gray level of
human interpreter in assessing the radiographed image in an pixels in it. The process of partitioning images into objects and
automated manner. The purpose of the radiographic interpreta- background based on pixels0 gray level values is called thresh-
tion is to reach a decision on the acceptability or rejection of the olding. This is a widely used technique that has been studied and
component being assessed. This is based on the adopted code and used extensively [4].
standard in use, for example ASME Code Section 1 [2]. There are In 2005, a comparative study of non-parametric histogram
many types of discontinuities as described by the standard, which thresholding for automatic extraction of weld defect was inves-
include cracks, lack of weld penetration, lack of weld fusion, tigated by Nacereddine et al. [5]. Four methods based on within
porosity, void and others. The objective of this work is to develop class variance minimization, the minimum error of clustering, the
class entropy maximization and the moment preservation were
implemented and the result showed that entropy maximization
n
gave the best result. Wang and Wong [6] proposed an adaptive
Corresponding author at: Electrical Engineering Department, Faculty of Engi-
neering, University of Malaya, 50603 Kuala Lumpur, Malaysia.
wavelet thresholding and histogram equalization to improve the
Tel.: þ603 79675205. quality of the radiographic image. Three level thresholding, which
E-mail address: haniza.yazid@gmail.com (H. Yazid). is based on maximum fuzzy entropy is adopted to classify the

0963-8695/$ - see front matter & 2011 Elsevier Ltd. All rights reserved.
doi:10.1016/j.ndteint.2011.06.002
564 H. Yazid et al. / NDT&E International 44 (2011) 563–570

image into three regions namely the black, gray and white. The regions and the detection of the weld defects. On the other hand,
optimal threshold is obtained using genetic algorithm. In [7], Zapata et al. [20] proposed a set of 12 geometrical features, which
histogram concavity threshold approach has been used to seg- characterise the defect shape and orientation.
ment the defect. The proposed method was compared with Attempts to classify the welding flaws types have been made
maximum entropy thresholding and Otsu methods. The proposed using various classifiers and a number of studies on various
method yields a better result compared to both of the conven- different features of welding defects have been conducted and
tional thresholding methods. In 2008, Wang et al. [8] introduced a used for classification [21–24]. Recently Liao [25] introduced an
method based on multiple threshold and support vector machine improvement for feature extraction selection in two versions and
to classify the welding defect. In every block that contains the is known as ant colony optimization based algorithm. Four
defect, Hough Transform is performed to remove the noisy pixels classification methods are used including nearest mean, k-nearest
and obtain an accurate segmentation and location of the defect. neighbor, fuzzy k-nearest neighbor and center based nearest
Meanwhile Tang et al. [9] claim that it is possible to obtain the neighbor. In this paper, a new approach is presented to identify
optimal threshold by maximizing the fuzzy exponential entropy defects using inverse surface thresholding.
based on the distribution of the defect and the background classes
in the bound histogram. Valavanis and Kosmopoulos [10] utilized
Sauvola local thresholding and graph based segmentation to 2. Methodology
segment the weld defect from the background. Then, the defects
were classified using multi-class support vector machine and The flow of steps for the proposed method is illustrated in
neural network classifiers. Fig. 1. The input image is a grayscale radiographic image of
In 2002, Wang and Liao [11] implemented background sub- weldment. It is observed that the area that contains defects
traction and histogram thresholding in the segmentation phase of usually lies in the middle of the image and is brighter than the
line weld defect detection. 12 numerical features were extracted rest of the area. Thus the first step is to identify and isolate this
and used to classify the defects using fuzzy k-nearest neighbor area using fuzzy c means clustering. The fuzzy c means clustering
and multi-layer perceptron neural networks. Soo et al. [12] segments the image into 5 regions of which two regions with the
introduced a defect segmentation using background subtraction highest average intensity are considered as the area that contain
and rank levelling. Comparison is made between the rank level- the welding defects and the remaining three regions are com-
ling and polynomial surface fitting for background estimation. bined as the background and excluded from further processing.
The proposed method indicates a better result to isolate the Defects that are present in the high intensity area (or the
defects. In 2006, Alaknanda et al. [13] adopted Canny operator region of interest) are low in intensity and thus are usually
to detect the defect boundaries and then fixed the boundaries excluded from the region of interest (ROI). Therefore these defects
using morphological image processing. Afterward in 2009, appear as holes in the ROI that need to be filled up, processed and
Alaknanda et al. [14] introduced a new two stage water segmen- detected properly. A simple region filling algorithm is performed
tation to reduce oversegmentation in detecting flaws in weldment on the ROI where each row of the ROI is checked horizontally.
images. In the first stage, the watershed transformation is When break (hole) is detected, it is filled with the intensities of
adopted and mosaic resulting image is obtained. The Otsu thresh- the original pixels back. The ROI is then subjected to edge and
olding is applied and converted into a binary image. The mor- valley detection.
phological and top hat transform is utilized onto the binary image
to separate the overlapping defects. In the second stage, the Input image
watershed segmentation is used to obtain well defined bound-
aries while removing the oversegmented regions.
Lawson [15] combined two networks to locate the defect. In the Fuzzy C Means
first step, a multi-layer perceptron backpropogation network was
utilized to locate the weld region based on the gray level and spatial Region filling
structure of the input image. Then, in the second step, the multi-
Clustered image
layer perceptron was trained on a test set of segmented image by a
conventional adaptive threshold method to detect the defect area in
the image. Shafeek et al. [16] utilized a host of algorithms such as Mean filter Edge detection
gray level histogram, thresholding, histogram stretching and histo-
gram equalization in addition to the 8 neighborhood boundary chain
code algorithm to identify the contour of defects. Then, information Valley detection Otsu thresholding
such as the length, width, area and perimeter of the defect are
calculated. Felisberto et al. [17] adopted genetic algorithm to find a
suitable parameters values such as position, width, length and angle Otsu thresholding
that are best defined in a window and matched it with the model of
the defect sample. However this method is more suitable for
detecting weld bead stretches that are linear or almost linear rather Inverse Surface
that the curved welds. Yazid et al. [18] introduced a system to detect
circular discontinuities that are present in the weld joints. The Thresholding
system utilizes separability filter to identify the best object candi-
dates and the Circular Hough Transform to detect the presence of
Detected
circular objects. The algorithm generates satisfactory result in
defects
recognizing circular discontinuities in the radiographic images.
However, the limitation of this approach is its difficulty in detecting
defects, which are not circular. Vilar et al. [19] utilized several Final output
methods including noise reduction, contrast enhancement, Otsu
thresholding and labeling to assist the recognition of the weld Fig. 1. Flow of steps in the proposed method.
H. Yazid et al. / NDT&E International 44 (2011) 563–570 565

For edge detection, Prewitt operator is used to obtain the edge weldment. The selected region is denoted as R(i,j). Further
information in the ROI. Then Otsu thresholding is performed on information on fuzzy clustering can be found in [27].
the resulting edge image to separate pixels of the weak edges
from the strong ones. Then all pixels of the weak edges are set to 2.2. Morphological valley detection
zero and the strong ones are kept for further processing. Mean-
while, a copy of the ROI is subjected to an averaging process, Valley detection algorithm is a type of morphological proces-
which utilizes a 3  3 window. This is followed by valley detection sing. There are several type of structuring element that can be
using morphological operators. Valley detection is performed to applied such as circle, sphere and square. In this paper, half
catch tiny defects that are present in the image that are too small sphere structuring element is applied. Details of the morphologi-
for the inverse thresholding surface to capture. Then, Otsu cal valley detection is available in [28]. Let G denote the set of
thresholding is performed on the valley image to remove pixels integer points on the spherical surface of a half sphere (Fig. 2).
of weak valley by setting them to zero. If the radius of the sphere is r, G is given by:
In order to construct the inverse surface, the original input image
G ¼ fi,j,gði,jÞg r ri r r
and the edge image are used. The inverse surface is then utilized to jpffiffiffiffiffiffiffiffiffiffiffiffik jpffiffiffiffiffiffiffiffiffiffiffiffik
detect defects in the ROI and the result is combined with that  r 2 i2 r j r r 2 i2 ð5Þ
obtained from the thresholded valley image. This is because result of
the valley detection complements that of the inverse surface thresh- for all i and height;
 qffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffi
olding especially in detecting small defects that have weak edges
gði,jÞ ¼ r r 2 i2 j2 ð6Þ
often overlooked by the inverse thresholding.

for all j. where byc denotes the greatest integer smaller than or
2.1. Fuzzy C means clustering equal to a real number of G. Given the following definition:
Iðx,yÞð0 r x rm1, 0 ry r n1Þ ð7Þ
Conventional clustering will assign each datum into one and
only one cluster. In contrast, fuzzy clustering assigns each datum I(x,y) is the original image; r is radius of the sphere; byc is the
into several clusters. For each assignment to a cluster, a degree of largest integer smaller than or equal to a; m,n are the length and
membership is specified by a membership grade. A collection of D height of the image.
data (xi; i¼1.2.3yD) to be segmented into C fuzzy groups/classes. max gði,jÞ means the maximum of gði,jÞ overall the points ði,jÞ
There will be a membership matrix u of size C  D. The element uij inside G.
represents the membership of the jth data (xj) to class i. FCM min gði,jÞ means the minimum of gði,jÞ overall the points ði,jÞ
partitions the data into C groups and then find the cluster center inside G.
in each group iteratively while minimizing a cost function of Valley detection algorithm is a closing morphology. The dila-
dissimilarity [26]. Initially, the membership matrix, u is randomly tion is performed first followed by erosion. The overall valley
initialized with values between 0 and 1. detection process is simplified as the following;
X
c
uij ¼ 1, 8j ¼ 1,. . .,d: ð1Þ  Find point (i,j) in half sphere with radius r, then find the
i¼1 corresponding value of g(i,j)
The dissimilarity function, which will be used in FCM as  Perform grayscale dilation onto each pixel in the image and
follow; obtain D(x,y)
D(x,y):¼max{I(x  1,y  1)þg(i,j)}; ( 5o ¼io ¼5)
X
c X
d
 Grayscale erosion is performed onto D(x,y) and stored into
J¼ ðuij Þm d2ij ð2Þ
i¼1j¼1
K(x,y)
K(x,y):¼min{D(x  1,y  1) g(i,j)};
where uij is the in between 0 and 1; ci the cluster center of fuzzy  Perform V(x,y)¼K(x,y) I(x,y) for each pixel (x,y)
group i; dij the Euclidean distance between ith cluster and the jth V(x,y)¼1 if (x,y) is a valley pixel
data point and m the weighting exponent. V(x,y)¼0 otherwise
A minimum of dissimilarity function can be reached using the  If V(x,y) 4 ¼T for a threshold value T, (x,y) is determined to be
following formula a valley.
Sdj¼ 1 um
ij xj
ci ¼ , 8i ¼ 1,    ,C ð3Þ z
Sdj¼ 1 ðuij Þm

1 (0,0,r)
uij ¼ : ð4Þ
SCk ¼ 1 ðdij =dkj Þ2=ðm1Þ
The determination of the cluster0 s center ci and the member-
ship matrix can be illustrated in the following steps:
Step 1: Initialize the membership matrix u with random value
between 0 and 1.
Step 2: Calculate c fuzzy cluster centers ci.
Step 3: Compute the cost function and terminate if u below a y
certain tolerance value. g (i,j)
Step 4: Compute a new u and go to step 2 again.
In our experiment, the input image is segmented into two
regions. The region with the higher average intensity will be x (i,j)
selected for further processing, since the one with the lower
intensity is considered as the background that does not contain Fig. 2. Half sphere structuring element.
566 H. Yazid et al. / NDT&E International 44 (2011) 563–570

2.3. Otsu thresholding image I(i,j) and the negative image N(i,j) in 4 passes. The difference
between one pass to another is the path of processing the pixels in
Otsu threshoding is a method that selects a threshold that the image as shown in Fig. 3. Firstly, for each pass a primary surface
minimized the intra class variance. In this work, Otsu thresholding Pm(i,j) (m¼1, 2, 3, 4) is initialized to the original image I(i,j). Then the
is utilized to threshold the edge and valley pixels. We expect the edge intensity of pixels on the primary surface Pm(i,j) is reconstructed
values of pixels at the border of the discontinuities to be higher than depending on whether the pixels are border pixels or non-border
other areas in the image. Therefore, we can separate border pixels pixels. Border pixels are those with strong edge (E(i,j)40) and their
from the others by thresholding the edge image E(i,j). Otsu thresh- gradients are made equal to those of the negative image N(i,j). Non-
olding splits the edge values of E(i,j) into two groups where pixels border pixels are those with weak edge (E(i,j)¼ 0) and their
from the group with the higher mean (border pixels) are kept while gradients are set equal to those of the original image I(i,j). The final
pixels of the other group are set zero. Otsu method is also used on the inverse surface is the average of the four primary surfaces.
valley image obtained from the morphological operation to eliminate Of course, the gradients of a pixel (i,j) in an image can be
low valley values from V(i,j) by setting them to zero. After this oper- measured in four directions. For each pixel (i,j), the four gradients
ation, only the strong edge and high valley are kept and considered. are calculated in horizontal, vertical, diagonal and anti-diagonal dire-
Further details on this method can be found in [29]. As a consequence ctions between the pixel (i,j) and four of its nearest neighbors that
of this step, we could identify the locations of strong edge and valley have been traversed. The reconstruction of the primary surface P1(i,j)
pixels in the region of interest (ROI) now denoted as R(i,j). for the first pass (LRTB) is summarized as follows. The formation of
the other three primary surfaces can be generalized from P1(i,j). Keep
in mind that only locations (pixels) that belong to R(i,j) are processed.
2.4. Inverse surface construction

1. Obtain the negative image of I(i,j) by negating it using Eq. (8).


The novelty of our approach lies in the use of an inverse surface
The gradients of each pixel in the negative image N(i,j) should
for locating the defects in the R(i,j) region. In constructing the
be the opposite of those in the original image I(i,j)
inverse surface, the locations of edge points (pixels) are given by the
nonzero pixels of Otsu thresholded edge image E(i,j). The intensity of
the inverse surface S(i,j) is derived from the gradients of the original Nði,jÞ ¼ 2552Iði,jÞ ð8Þ

Fig. 3. Processing directions (a) first pass in left-right-top-bottom(LRTB) direction, (b)second pass in right-left-bottom-top (RLBT) direction, (c) third pass in top-bottom-
right-left (TBRL) direction and (d) fourth pass in bottom-top-left-right (BTLR) direction.
H. Yazid et al. / NDT&E International 44 (2011) 563–570 567

2. Initialize the primary surface P1(i,j) to the original image I(i,j) (c) For BTLR pass, N(i,j 1), N(iþ1,j), N(i 1,j 1), N(iþ
1,j1) and I(i,j1), I(iþ1,j), I(i1,j 1), I(iþ1,j 1) are
P1 ði,jÞ ¼ Iði,jÞ the respective neighbors used for border and non-border
pixels in reconstructing P4(i,j).
4. The final inverse surface S(i,j) is the average of the four
3. For every pixel(i,j), adjust the intensity of P1(i,j) according to primary surfaces
the following cases
(i) Case 1: If the pixel(i,j) is a border pixel (E(i,j)40) we
Sði,jÞ ¼ ðP1 ði,jÞ þP2 ði,jÞ þ P3 ði,jÞ þ P4 ði,jÞÞ=4:0 ð11Þ
equate the gradients of P1(i,j) to those of the negative
image N(i,j).
Find the gradients of the pixel(i,j) in four directions relative
to four of its nearest neighbors that have been traversed in
the negative image. In LRTB pass, the neighboring pixels are 2.5. Surface thresholding
(N(i,j 1), N(i 1,j), N(i 1,j-1), N(i 1,jþ1)) and the gra-
dients in horizontal, vertical, diagonal and anti-diagonal In surface thresholding, the main task is to adjust the position of
directions are the inverse surface S(i,j) so that only the areas containing defects
will overlap with the original image I(i,j). Fig. 4(a) shows the
D1 ¼ Nði,jÞ2Nði,j1Þ D2 ¼ Nði,jÞ2Nði1,jÞ intensities of pixels that fall on a line drawn on I(i,j) while
D3 ¼ Nði,jÞ2Nði1,j1Þ D4 ¼ Nði,jÞ2Nði1,j þ1Þ Fig. 4(b) shows the same pixels on S(i,j). The positions of the
edge pixels are marked with ‘‘ þ’’. The main idea is to treat S(i,j) as
a thresholding surface and to position the two surfaces as in Fig. 5
Then using each gradient, we estimate the value of P1(i,j)
such that the edge pixels coincide. This is done by adjusting the
using its corresponding neighbors as follows
intensities of S(i,j) by adding/subtracting a constant to it, in order
to move the inverse surface up or down. Since edge pixels do not
e1 ði,jÞ ¼ P1 ði1,j1Þ þ D1 e2 ði,jÞ ¼ P1 ði,j1Þ þ D2 have the same intensity, the strategy is to minimize the absolute
e3 ði,jÞ ¼ P1 ði1,jÞ þ D3 e4 ði,jÞ ¼ P1 ði1,j þ 1Þ þ D4 difference between the edge pixels on the input image I(i,j) and
the adjusted inverse surface S(i,j)þk, where k is the added
The four estimates are then averaged to give us the final constant. The value of k that achieves this minimum sum of
value of P1(i,j) for the pass absolute difference is denoted as ko.
Once the right position of the inverse image (or constant ko) is
found, we can extract the defects as the area where I(i,j) is greater
P1 ði,jÞ ¼ ðe1 ði,jÞ þ e2 ði,jÞ þ e3 ði,jÞ þe4 ði,jÞÞ=4:0 ð9Þ than S(i,j)þko. In Fig. 5 the defects are designated by the area
where the bold line is higher than the thin line. The whole process
(ii) Case 2: If the pixel(i,j) is a non-border pixel (E(i,j) ¼0) the of the surface thresholding can be summarized as follows;
gradients of P1(i,j) are the same as those of the original Step 1: Construct the inverse image S(i,j) as directed in
image I(i,j). previous section
The neighboring pixels are I(i,j 1), I(i 1,j), I(i 1,j  1), Step 2:Find the value of a constant ko that minimizes the sum
I(i  1,j þ1) and the gradients in horizontal, vertical, diag- of the absolute difference of I(i,j) S(i,j)þk for the edge pixel at
onal and anti-diagonal directions are

D1 ¼ Iði,jÞ2Iði,j1Þ D2 ¼ Iði,jÞ2Iði1,jÞ
D3 ¼ Iði,jÞ2Iði1,j1Þ D4 ¼ Iði,jÞ2Iði1,j þ1Þ

The estimates for P1(i,j) using its corresponding neighbors


as follows

e1 ði,jÞ ¼ P1 ði1,j1Þ þ D1 e2 ði,jÞ ¼ P1 ði,j1Þ þ D2


e3 ði,jÞ ¼ P1 ði1,jÞ þ D3 e4 ði,jÞ ¼ P1 ði1,j þ 1Þ þ D4

They are then averaged to give us the final value of P1(i,j)


for the pass
P1 ði,jÞ ¼ ðe1 ði,jÞ þ e2 ði,jÞ þ e3 ði,jÞ þe4 ði,jÞÞ=4:0 ð10Þ Fig. 4. (a) A cross section of I(i,j) and (b) the same cross section on S(i,j).

For the other passes, steps (1) and (2) are identical and for
step (3) the neighbors to consider for horizontal, vertical,
diagonal and anti-diagonal directions are
(a) For RLBT pass, N(i,jþ 1), N(iþ1,j), N(iþ 1,jþ1),
N(iþ1,j 1) and I(i,jþ 1), I(iþ1,j), I(iþ1,jþ1), I(iþ1,j-1)
are the respective neighbors used for border and non-
border pixels in reconstructing P2(i,j).
(b) For TBRL pass, N(i,jþ 1), N(i 1,j), N(iþ1,jþ1), N(i 1,jþ
1) and I(i,jþ1), I(i1,j), I(iþ1,jþ1), I(i 1,jþ1) are the
respective neighbors used for border and non-border
pixels in reconstructing P3(i,j). Fig. 5. Combination of image surface (bold line) and inverse surface (thin line).
568 H. Yazid et al. / NDT&E International 44 (2011) 563–570

Fig. 6. (a) Test image, (b) fuzzy clustered image, (c) region filled image, (d) thresholded edge image, (e) thresholded valley image, (f) inverse surface image and
(g) final thresholded image.

the border S(i,j) where k is an integer that varies from  255 to 3. Results and discussions
255.
2 The algorithm is developed using C programming in LINUX
argmin X operating system with Intel Core 2 Duo processor. The system
k0 ¼ 4 9Iði,jÞSði,jÞ þ k9,
k was tested on 60 radiography images. It is observed that, the new
border pixels ði,jÞ
proposed method is able to detect defects of varying shapes and
sizes. Fig. 6(a) shows the original radiographic image while
kA f255,254,. . .0. . .,254,255g ð12Þ
Fig. 6(b) is the clustered image of the FCM operation wherein
the holes can be clearly observed. The result of hole filling on the
Step 3: Segment R(i,j) into defect and background.
clustered image is shown in Fig. 6(c). Edge detection is performed
( on the image in Fig. 6(c) followed by the Otsu thresholding that
0ðdefectsÞ If Iði,jÞ 4 Sði,jÞ þ ko
resultði,jÞ ¼ ð13Þ removes weak edges. The result is shown in Fig. 6(d). Fig. 6(e) is
255ðbackgroundÞ If Iði,jÞ o Sði,jÞ þ ko
the outcome of morphological valley detection on Fig. 6(c) where
H. Yazid et al. / NDT&E International 44 (2011) 563–570 569

Fig. 7. (a) Original image, (b) valley detection and (c) final thresholded image.

Table 1
Comparison between human grader and the proposed method.
Original image Human grader Inverse surface Watershed segmentation
thresholding

the weak valley has been removed by the Otsu thresholding. is calculated. Sensitivity measures the ratio of the actual positive
Meanwhile Fig. 6(f) shows the inverse image after inverse surface which is correctly identified meanwhile specificity measures the
thresholding. Lastly, the final result is indicated in Fig. 6(g). ratio of the negative which are correctly identified. In this paper,
In order to demonstrate the importance of inverse threshold- sensitivity measures the proportion of the defect pixels that is
ing; the test image, the valley detected image V(i,j) and the final correctly identified as defects while specificity measures the
thresholded image are shown in Fig. 7(a), (b) and (c), respectively. proportion of the normal pixels that is correctly identified as
The circle on the images shows the defect missed by valley normal. The sensitivity of the inverse surface threholding is 94.6%
detection but picked up by inverse thresholding. while its specificity is 99%. On the other hand, the valley detection
To show the contribution of the proposed method, the sensi- alone obtains a lower sensitivity of 75% and the same specificity of
tivity and specificity with and without inverse surface thresholding 99%. For further comparison, result of the method is compared to
570 H. Yazid et al. / NDT&E International 44 (2011) 563–570

that of the watershed segmentation. Table 1 shows several [7] Saravanan TBS, John Philip, Jayakumar T, Baldev Raj. Segmentation of defects
examples of detected defects from human grader, inverse surface from radiography images by the histogram concavity threshold method.
Insight—Non-Destructive Testing and Condition Monitoring 2007;49(10):
thresholding and watershed segmentation.
578–84.
In watershed segmentation, several methods had been [8] Wang Y, Sun Y, et al. Detection of line weld defects based on multiple thresholds
adopted namely thresholding, extended maxima, minima imposi- and support vector machine. NDT&E International 2008;41(7):517–24.
tion and contrast adjustment. One major drawback of this method [9] Tang Y, Zhang X, et al. Application of a new image segmentation method to
detection of defects in castings. The International Journal of Advanced
is the manual selection of the threshold value to convert the Manufacturing Technology 2009;43(5):431–9.
grayscale into binary image before watershed segmentation is [10] Valavanis I, Kosmopoulos D. Multiclass defect detection and classification in
performed. In watershed segmentation method, the sensitivity weld radiographic images using geometric and texture features. Expert
achieved is 69.6% while the specificity is 98.8%. Systems with Applications 2010;37(12):7606–14.
[11] Wang G, Liao TW. Automatic identification of different types of welding
defects in radiographic images. NDT&E International 2002;35(8):519–28.
[12] Soo SL, Ratnam MM, Samad Z, Khalid MA. Segmentation of weld defects in
4. Conclusions radiographs using rank-levelling and background subtraction. Insight: Non-
Destructive Testing and Condition Monitoring 2008;50(4):188–94.
The novelty of this work is in the application of inverse surface [13] Alaknanda, Anand RS, et al. Flaw detection in radiographic weld images
using morphological approach. NDT&E International 2006;39(1):29–33.
thresholding for defect detection. The method is simple and yet [14] Alaknanda Anand RS, Kumar Pradeep. Flaw detection in radiographic weld-
powerful. The inverse thresholding method is introduced to ment images using morphological watershed segmentation technique.
construct a new thresholding surface to extract the defects. Then NDT&E International 2009;42:2–8.
[15] Lawson SE, Parker GA. Intelligent Segmentation of industrial radiographic
the least square distance measure is used to adjust the position of
images using neural networks, in: Proceedings of SPIE Architectures and
the inverse image for optimum thresholding. The main advantage Systems Integration III 2347, (1994), pp. 245–55.
of this proposed method is it can be applied to databases with [16] Shafeek HI, Gadelmawla ES, et al. Assessment of welding defects for
uneven illumination and contrast. This method does not depend gas pipeline radiographs using computer vision. NDT&E International
2004;37(4):291–9.
on selected parameters that need to be changed for different
[17] Felisberto MK, Lopes HS, et al. An object detection and recognition system
databases. The proposed method demonstrates 94.6% sensitivity for weld bead extraction from digital radiographs. Computer Vision and
and 99% specificity in detecting defects in weldment images. In a Image Understanding 2006;102(3):238–49.
few images, some of the defects are either not detected or overly [18] Yazid H, et al. Circular discontinuities detection in welded joints using
circular hough transform. NDT&E International 2007;40:594–601.
detected. However, most of the time the missing defects are [19] Vilar R, Zapata J, et al. An automatic system of classification of weld defects
either too small or blurred. in radiographic images. NDT&E International 2009;42(5):467–76.
[20] Zapata J, Vilar R, et al. An adaptive-network-based fuzzy inference system for
classification of welding defects. NDT&E International 2010;43(3):191–9.
Acknowledgement [21] Liao TW, Ni J. An automated radiographic NDT system for weld inspection:
part I—weld extraction. NDT&E International 1996;29(3):157–62.
[22] Liao TW, Li Y. An automated radiographic NDT system for weld inspection:
The authors wish to thank Materials Technology Group for part II—Flaw detection. NDT&E International 1998;31(3):183–92.
providing the image data. [23] Liao TW LD, Li YM. Detection of welding flaws from radiographic images with
fuzzy clustering methods. Fuzzy Sets System 1999;108(2):145–58.
[24] Liao TW, Li D, et al. Extraction of welds from radiographic images using fuzzy
References classifiers. Information Sciences 2000;126(1–4):21–40.
[25] Liao TW. Improving the accuracy of computer-aided radiographic weld
inspection by feature selection. NDT&E International 2009;42(4):229–39.
[1] Ditchburn RJ, Burke SK, et al. NDT of welds: state of the art. NDT&E
[26] Chuai-Aree SS, Lursinsap C, Sophatsathit P, Siripant S, Fuzzy C-Mean: A
International 1996;29(2):111–7.
statistical feature classification of text and image segmentation method, in:
[2] American Society of Mechanical Engineers (ASME), Section 1; 1998, pp. 204.
[3] Soler L, Malandrin G, Delinguette H. Segmentation automatique: application Proceedings of International Conference on Intelligent Technology 2000,
aux angioscanner 3D. Revue de Traitement de Signal 1998;15. December 13–15, Assumption University Bangkok, Thailand, 2000,
[4] Sezgin M, Sankur B. Survey over image thresholding techniques and quanti- pp. 279–84.
tave performance evaluation. Journal of Electronic imaging 2004;13(1): [27] Sergios Theodoridis, Koutroumbas Konstantinos. Pattern Recognition.3rd
146–65. Edition USA: Academic Press; 2006.
[5] Nacereddine N, Hamami L, Tridi M, Oucief N. Non-parametric histogram [28] Fauzan Ahmad, Face Localization for Facial Features Extraction using Sym-
based thresholding methods for weld defect detection in radiography. World metrical Filter and Linear Hough transform, Dissertation (M.Eng.Sc.), Elec-
Academy of Science, Engineering and Technology 2005;9. trical Engineering Department, Faculty of Engineering, University of Malaya,
[6] Wang X, Wong BS. Radiographic image segmentation for weld inspection 2007.
using a robust algorithm. Research in Nondestructive Evaluation 2005;16(3): [29] Otsu. A threshold selection method from gray-level histogram. IEEE Transac-
131–42. tions on Systems Man and Cybernetics 1979;9(1):62–6.

You might also like