0% found this document useful (0 votes)
11 views7 pages

4 Detection

Uploaded by

Samir Bagalkote
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views7 pages

4 Detection

Uploaded by

Samir Bagalkote
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

ISSN(Online): 2320-9801

ISSN (Print): 2320-9798

International Journal of Innovative Research in Computer


and Communication Engineering
(An ISO 3297: 2007 Certified Organization)

Vol. 1, Issue 6, August 2013

Detection of Defects in Glass Using Edge


Detection with Adaptive Histogram
Equalization
Nitin kumar1, Ranjit kaur2
M.Tech (ECE), UCoE, Punjabi University, Patiala, India1
Associate Professor, UCoE, Punjabi University, Patiala, India2

Abstract: Defects in glass which show poor quality are the major problem for manufacturer in glass making industry. It is
very difficult and prone to error process to manually inspect very large size glass. The manual examination process is slow,
time consuming and prone to human error. The glass detection technique using image processing provide much relief from
error to manufacturer and also provide strength to hold in market providing best quality and low cost glass to customers. In
this paper all types of faults are taken. The previous work has been done for only major faults or defects. Detection of
defects is based on segmentation using edge detection using gradient approach based on sobel operator. Gray color space
and the adaptive histogram technique are used for better contrast and it helps in detection of defects and compares it with
the help of structural similarity index (SSIM) parameter with contour detection technique.
Keywords: Structural similarity Index (SSIM), Adaptive histogram equalization, gray color space, glass, image
segmentation.
I. INTRODUCTION
Defect free glass provides strength to the manufacturer of glass making industry. In past manual inspection is prominent
and play a vital role in glass inspection. But nowadays the detection take place through automatic detection technique
provide better reliability, fast and very less prone to error than traditional one. Nowadays An automated visual inspection
system is used for detecting and measuring the defects in satin glass and real time system is used [1].
For quality control the technique is used called Color space which specifies and visualizes color. Different color
spaces are better for different applications [2]. Five most commonly used color spaces are tested. Researchers randomly
select one of the color spaces for color image processing applications. But there should be a way to select a suitable color
space according to the purpose because the choice will directly affect final results of image processing [3]. The conversion
of color images between RGB, HSV, YCbCr, NTSC, Gray is done. Their conversion efficiency is computed and their
performance in quantifying the defect visibility is compared based on which the best color space can be chosen [4]. The
RGB color space is recommended if one needs to view and process various defects like scratches, spots, edge defects etc in
images. If any color space conversions are required the best choice is RGB to Gray color space conversion which makes the
defect visible to largest extent and segmentation using contour region growing method applied for detection of defective
areas in glass sheets[5]
Copyright to IJIRCCE www.ijircce.com 1321
ISSN(Online): 2320-9801
ISSN (Print): 2320-9798

International Journal of Innovative Research in Computer


and Communication Engineering
(An ISO 3297: 2007 Certified Organization)

Vol. 1, Issue 6, August 2013

The rest of the paper is organized as follows: Section 2 is about problem formulation means what types of problems are in
previous work. After that section 3 for design methodology, in which steps regarding algorithm takes place. In section 4
implementation of algorithm carried out for detection of defects and the Section 5 discuss the results and last section 6
concludes the paper.

II. PROBLEM FORMULATION


 From research it is analyzed that various color spaces have been analyzed and compare for their performance in
quantifying the visibility of defects in digital images.
 RGB model gives the best detection of fault like scratches, spots, edge defects etc in images but processing in RGB is
very slow & computationally inefficient.
 Image enhancement has been done by ordinary histogram equalization [5]. It is good for the image having distribution
of pixel values similar throughout the image but the image contains regions that have darker and lighter than most of
the image, the contrast will not enhanced in those regions.
 In previous work segmentation is done by contour region growing method but it is not suitable for low contrast images
[5].

III. DESIGN METHODOLOGY


The various possible defects that can be present in a glass sheet can be identified in few steps which include the following:-
 First read the image.
 Select RGB color space.
 Convert RGB to gray model.
 Image enhancement using adaptive histogram equalization.
 Image segmentation using edge detection.
 Segmented image.
 Inverted segmented image.
 Fault outline in original image.

Copyright to IJIRCCE www.ijircce.com 1322


ISSN(Online): 2320-9801
ISSN (Print): 2320-9798

International Journal of Innovative Research in Computer


and Communication Engineering
(An ISO 3297: 2007 Certified Organization)

Vol. 1, Issue 6, August 2013

Read the image Segmented images

Select RGB color space

Convert RGB to gray


model

Image enhancement
using adaptive
Invert segmented image
histogram equilization

Image segmentation
using edge detection Fault outline in original
image

Fig. 1: Design methodology

IV. IMPLEMENTATION
In this paper combine a series of images processing steps to solve our purpose of detection based on well defined operators
present nowadays. First read the image then select the RGB color space. After that convert the image into gray scale and
then segmentation using edge detection takes place.
Segmentation is the basic process of image analyses. The goal of segmentation is to simplify and change the
representation of an image into something that is more meaningful and easier to analyze. Image segmentation is typically
used to locate objects and boundaries (lines, curves, etc.) in images [6]. Edge detection technique is used for segmenting
images based on abrupt change in intensity. Sobel operator is used to detect the edges of fault with gradient based
approach[7]. The Sobel operator performs a 2-D spatial gradient measurement on an image. Typically it is used to find the
approximate absolute gradient magnitude at each point in an input grayscale image. The Sobel edge detector uses a pair of
3x3 convolution masks, one estimating the gradient in the x-direction (columns) and the other estimating the gradient in the
y-direction (rows).

Copyright to IJIRCCE www.ijircce.com 1323


ISSN(Online): 2320-9801
ISSN (Print): 2320-9798

International Journal of Innovative Research in Computer


and Communication Engineering
(An ISO 3297: 2007 Certified Organization)

Vol. 1, Issue 6, August 2013

Fig. 2: (a) Gx (b) Gy

G  Gx 2  Gy 2

-1 0 +1 +1 +2 +1
-1 0 +1 0 0 0
-2 0 +2 -1 -2 -1
(a) (b)

(1)

G  Gx  Gy
(2)

Where Gx is the3x3 convolution mask which estimates the gradient in x-direction and Gy is the3x3 convolution mask which
estimates the gradient in y-direction.
Sobel operator is better than prewitt and Roberts operators because of better noise suppression (smoothing) characteristics
makes it preferable. Sobel operator is applied on selected image for detection the edges of fault and then invert the image
for better visibility of defects. Now compare this technique with contour detection using structural similarity index (SSIM)
parameter [8]. The structural similarity (SSIM) index is a method for measuring the similarity between two images.
V. RESULTS AND COMPARISON
The intended method has been functional to digital images of the glass sheets taken for detecting various defects like
scratches, inclusions, surface defects etc using MATLAB and compare it with contour method of detection of defects in
glass with the help of Structural similarity (SSIM) index. SSIM provided the similarity between two images. It is full
reference matrix in which one image taken as original image as reference and other image is produced by both contour and
edge detection method. The complete results have been shown below:-
Detection of faults using contour region technique:-

Copyright to IJIRCCE www.ijircce.com 1324


ISSN(Online): 2320-9801
ISSN (Print): 2320-9798

International Journal of Innovative Research in Computer


and Communication Engineering
(An ISO 3297: 2007 Certified Organization)

Vol. 1, Issue 6, August 2013

(a) (b) (c)


Fig. 3: (a) Original image, (b) Final contour, (c) Final detective region

Apply the contour regrow method on image figure 3: (a) which is the original image taken for evaluation and in figure 3:
(b) show the final contour image and after that figure 3: (c) show the final detective region.The contour method detects fault
using region regrow techniqe which takes many iterations and using simple technque for enhancement. In this paper
another technique is used which is based on edge detection for segmentation and for enhancement adaptive histogram
equilization is used which provide better detection of faults. The outputs of proposed algorithm is shown below:-

(a) (b) (c)


Fig. 4: (a) Original image, (b) Original gray scale image, (c) Gray scale enhanced image

(d) (e) (f)


Fig. 5: (d) Binary gradient mask, (e) Dilated gradient mask, (f) Binary image with filling holes

Copyright to IJIRCCE www.ijircce.com 1325


ISSN(Online): 2320-9801
ISSN (Print): 2320-9798

International Journal of Innovative Research in Computer


and Communication Engineering
(An ISO 3297: 2007 Certified Organization)

Vol. 1, Issue 6, August 2013

(g) (h) (i)


Fig. 6: (g) Segmented image, (h) Inverted segmented image, (i) Fault outlined in original image.

Figure 4: (a) is original image which is used for analyzed the faults. RGB to gray scale model conversion is applied to
figure 4: (a) and show the result of original gray scaled image in figure 4: (b). Enhancement is done by adaptive histogram
equalization and enhanced image is shown in figure 4: (c). Edge and the Sobel operator is used to calculate the threshold
value, then tune the threshold value and use edge again to obtain a binary mask that contains the fault. Figure 5: (d) shows
binary gradient mask. The binary mask that contains the fault is compared to the original image. There are gaps in the lines
surrounding the object in the gradient mask. These linear gaps are disappeared by dilate the sobel image using the vertical
& horizontal value in strel function shown in figure 5: (e). Binary image is obtained by filling holes in binary mask that
contains the fault is shown in figure 5: (f). After this segmented image is obtained by smoothing the binary image with
filling holes shown in figure 6: (g). Invert the segmented image for better detection of fault shown in figure 6: (h). The final
output of edge detection technique is figure 6: (i) which provide better detection of fault with the subjective point of view
because in segmentation most of the comparisons are subjective but in this paper both the detection methods are compare
objectively with structural similarity index (SSIM) parameter. Contour detection and edge detection technique applied on
many images and compare with SSIM index, some of these images are shown below:

(a) (b) (c) (d)

Fig. 7: (a), (b), (c), (d) original images

Copyright to IJIRCCE www.ijircce.com 1326


ISSN(Online): 2320-9801
ISSN (Print): 2320-9798

International Journal of Innovative Research in Computer


and Communication Engineering
(An ISO 3297: 2007 Certified Organization)

Vol. 1, Issue 6, August 2013

Table 1 Structural similarity (SSIM) index values:-

Images Contour Edge


detection detection
method method
Fig. 3: (a) 0.913 0.936
Fig. 7: (a) 0.872 0.991
Fig. 7: (b) 0.835 0.887
Fig. 7: (c) 0.854 0.887
Fig. 7: (d) 0.774 0.829

This measure shows that the detected defect shape is more close to original defect in the image by edge detection approach
as compared to contour detection method.

VI. CONCLUSION
In this paper various types of defects are detected using edge detection method present in glass sheets. First a best suited
color space is selected for processing based on conversion time and maximum visibility of faults and then gray color space
and adaptive histogram equalization for image enhancement for better detection are used. Now final image generated by
contour detection method and edge detection method are compared with the help of structural similarity index. SSIM index
provide information about defect detected shape is more close to original image or not. The segmentation algorithm using
the edge detection method show better results than contour method to detect the various defects.

REFERENCES
[1] M.A.Coulthard, “Image Processing for Automatic Surface Defect Detection,” Surface Inspection Ltd, UK, pp.192-196.
[2] F. Adamo, F. Attivissimo, A. Di Nisio, M. Savino, “An Automated visual inspection system for the glass industry”, Proc. of 16th IMEKO TC4
Symposium, Florence, Italy, 2008,
[3] Yuanyuan Pu, Xiaomin Wei, Yi Su, Zhengpeng Zhao, Wenhua Qian, Dan Xu, “Implementation and Research of Multi-Method Color Transfer
Algorithms in Different Color Spaces”, International Conference on Machine Vision and Human-machine Interface, IEEE Computer Society,
pp.713-717, 2010.
[4] Nishu Gupta, Sunil Agrawal, “Glass Defect Detection Techniques using Digital Image Processing –A Review”, IJCA Special Issue on IP Multimedia
Communications, pp. 65-67, 2011.
[5] Nishu Gupta, Sunil Agrawal, “ Automated Inspection of Defects in Glass by proper Color space selection and Segmentation Technique of Digital
Image processing”, Int.J.Computer Technology & Applications,vol 3 (3), 1058-1063,2012
[6] Rafael C. Gonzalez, Richard E. Woods, “digital image processing” Third Edition,PHI publications.
[7] Mr. Manoj K.Vairalkar , Prof. S.U.Nimbhorkar, “Edge Detection of Images Using Sobel Operator” International Journal of Emerging Technology
and Advanced Engineering, vol 2, Issue 1, 2012.
[8] Z.Wang, A. C. Bovik, H. R. Sheikh and E. P. Simoncelli,”Image quality assessment: From error visibility to structural similarity,” IEEE Trans. On
Image Processing, Vol. 13, no. 4, pp. 600-612, 2004.

Copyright to IJIRCCE www.ijircce.com 1327

You might also like