NKS 2004 Abstracts.nb

Scratch-Detection

Andreas Eckerstorfer
Johannes Kepler University Linz

A rotation-invariant algorithm for a self-acting inspection system to detect scratches in grayscale images of ground metallic material will be discussed. Scratches are darker curves on the image, which can easily be detected with our eyes. So it is obvious to use the methods of visual perception presented by Stephen Wolfram.

The algorithm is divided into three main parts.

1. Halftoning

Each pixel-value is compared with the average pixel-value in a small neighborhood of 3x3 pixels. If the pixel is much darker than the neighborhood and the pixel itself is not too light, the new pixel is set to black, otherwise white. By this method the information about the scratches is preserved.

2. Searching of small line segments

As a variant to the approach presented, only the correspondence between the black cells of different line segments and the neighborhood of each pixel of the halftoned image is observed. If this correspondence is high, the new pixel at the center of this neighborhood is set to black.

3. Scratch classification

Now the resulting image is partitioned into stripes of the same direction as the line segment used in step 2. If the number of black pixels in one of these stripes is much larger than the number of black pixels in the other stripes, then with high probability there must be a scratch in this stripe. If no scratch is found, the material passes the inspection.

As an example this algorithm is applied to a typical image.
original image:                        “scratch.bmp”
halftoned image:                        “halftoned.bmp”
the correspondences with two special line segments:        “25degreeimage.bmp,” “85 degreeimage.bmp”

With stripes of 10 pixel width both scratches in the original image are detected.



Created by Mathematica  (April 20, 2004)




Program Outline
Schedule
Logistics
Presentations
Gallery
Photo Scrapbook

NKS 2007
NKS 2006
NKS 2003