Application of Image Processing for the Quality Testing of Sheet Metal Work

Accurate and timely information is needed for industries to improve their quality and increase the production of goods. Digital image processing is used in many fields mainly for the detection of faulted parts or missing part. Automated visual inspection is the key factor behind all the industrial application of digital image processing. The proposed study mainly deals with analysis to find faulty sheet metal piece and correcting it. Rather than a statistical approach, this proposed idea employs verification of measurements of all the pieces that are coming out of product line. Based on the error rate modification in the design can be pursued. This experimental results show that manual inspection can be replaced with the proposed idea and hence productivity can be increased.


INTRODUCTION
Today there is no field of technical endeavor left out without the impact of Digital Image Processing (Gonzales and Woods, 2008).Digital Image Processing is the technique for analyzing and manipulation of the digital images using computers (Gonzales and Woods, 2008).Automated visual inspection uses digital camera that captures image which is coming out of product line.The captured image is then fed to computer for further processing.The typical image processing task is to find the faulty piece by comparing the user requirements and manufactured product image .Sheet metal is a flat solid that is deformed to thin plate which has meager thickness.Sheet metal having high magnetic permeability is used in transformers and electric machines.Designs of different shapes are punched on the sheet metal based on machine type.Punching is naturally performed by placing a metal stock between a die and mounted in a press.The press pushes the punch against and into the die with enough force to cut a hole in the stock.A simple shape (e.g., a square, circle, or hexagon) is cut directly on the sheet.These sheets have to be taken from the product line and verified for their dimension.In practice only a few pieces are taken and verified for dimension and orientation of the shapes.This way of performing a test manually is a tedious process and prone to human errors which reduce the quality of the sheet metal work.
In this study we propose to perform the quality test using Image Processing Techniques.Image of every sheet metal is taken and the dimension and orientation of the shapes cut are calculated and checked with the actual dimension in the drawing.This increases the speed and accuracy and avoids human errors which are common in quality testing.

Using digital image processing to verify quality:
The block diagram portrays steps handled in this study (Fig. 1).Digital image processing techniques are employed to verify almost all the punched sheet metals that are coming out of product line.This is pursued by taking image of each and every sheet metal as soon as the designs are pressed.The captured image is fed to computer and it is pre-processed (Gonzales and Woods, 2008).Pre-processing is the process of suppressing noise and enhancing the quality of the digital image.Then colored image is converted to black and white image and is subjected to edge detection.
Edge detection (Gonzales and Woods, 2008) is the process of identifying sharp discontinuities in an image (Fig. 2).Discontinuities are the abrupt changes in the pixel variations which characterize boundaries of different shapes in an image.By comparing efficiency of different filters, Robert filter (Gonzales and Woods, 2008), is suited well for this application.By applying this, clean and sharp edge of image can be obtained.Since the punched designs create hole in sheet metal, edge detection is necessary for the extraction of edges of all shapes in a single image (Fig. 3).
Edges are detected from the image and it is stored as separate image in the system memory.The endpoints are detected from the image extracted from the previous step.This process is done by scanline approach.Each pixel is represented in terms of x and y coordinates.Here, the image is scanned line by line (Donald and Let us consider, the pixel i, j in Fig. 5. i, j is said to be an endpoint if and only if (i-1, j+1), (i-1, j), (i-1, j-1), (i, j-1), (i, j+1) and (i+1, j+1) must be '0' and (i+1, j) and (i+1, j+1) are '1'.Similarly, the conditions are checked for all possible lines.The endpoints detected from this approach are stored for further computations.The stored endpoints are then subjected to phase-I verification.
In case of circles and ellipse, different approach has to be followed.The top, bottom, right and left extreme points of the circle are found first.Considering top and bottom point a midpoint is calculated and by considering right and left points another midpoint is calculated.With the help of these points center of the circle is found with respect to the axes.Other parameters such as diameter and radius can be calculated with the help of this.Likewise major axis and minor axis distance of the ellipse are computed and also center is determined.Phase-I verification: Each figure in every sheet metal image can be looked in terms of individual lines when shape is non-elliptical and the origin is taken in case of elliptical objects.The distances of each endpoint (origin for elliptical objects) from all the corners and axes of the image are found.The calculated values are compared with the user specified values.In case of any discrepancy, error rate is considered as a decision parameter.When the error rate is within the feasibility limit, particular piece is preceded to phase-II verification.

Phase-II verification:
Phase II verification is succeeded by phase I verification.If each sheet metal passes previous stage, phase II verification is done.Similar to phase I verification, this stage is also different for elliptical objects where the length of major and minor axes are found for all elliptical shapes in the metal piece are compared with user specified measurement.Phase II verification is where dimension of each lines and the angle between two lines formed are calculated when the shape is found to be a nonelliptical.The combination of points that forms a line is taken and the distance between each pair of points is computed.This is the required dimension of each line in regular polygon.For computing angle, each pair of points that shares a common point as vertex is taken as two vectors.Angle is computed by dot product of two vectors.These line parameters are retrieved later for comparison and error computation.If error exceeds tolerance level then the piece is rejected.Tolerance value is user specified.In case of circle, radius is compared with the user defined measurement.The algorithm given below illustrates the various steps in quality testing of sheet metal.This sounds good when compared to existing method (Fig. 6).
Shape detection: Shape detection (Pedro, 2005) is very much essential for automated visual inspection.Shapes present in the image can be found out if necessary for further usage.This allows easy verification of the sheet metal piece which results in higher accuracy of the testing.This process differs entirely for non-elliptical and elliptical objects.Hence the points found from previous stages are analyzed whether the points form a line or an ellipse.If the points form a line then shape detection for non-elliptical shapes are done or elliptical Fig. 6: Algorithm design for quality testing of sheet matel object shape detection is preceded.For non-elliptical shapes, first the combination of points that forms a line is taken and is arrayed.Then traversing is done.
Starting point is noted down and the pointer moves in the direction in which line exists.Each time a line is encountered counter is incremented.This approach is done until the pointer reaches the starting point.With the help of counter number of sides of the shape can be determined.For instance square, rectangle, rhombus, quadrilateral has four sides.Knowing the properties of the shapes, certain checking is done and the shape can be detected accurately.Likewise all the shapes are detected in the image.For elliptical shapes, the major and minor axes lengths are arrayed.If both lengths are found to be same then the elliptical object is declared as circle.If they are different then shape is declared as ellipse.Knowing these two length parameters it is easy to differentiate whether the figure is circle or not.Shape detection is very essential for easier verification of the perforated sheet metal piece.

CONCLUSION
A major area of imaging is in automated visual inspection of manufactured goods.Detecting anomalies is the major task of this proposed idea.This study proposes the detection of faulty pieces using image processing techniques and overcomes the weakness in the existing system.This can be implemented in MATLAB environment.This proposed idea can also be extended to irregular shapes.