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

Segmentation via Edges &Gray Shades

Introduction
This chapter explains image segmentation using edges and gray shades. The previous
chapter discussed image segmentation using histograms. That basic technique examined
the histogram of an image, transformed the image in to a 1-0 image, and "grew" regions.
The results were acceptable given the simplicity of the approach.
There are more powerful segmentation techniques that use the edges in an image, grow
regions using the gray shades in an image, and use both the edges and gray shades.
These techniques work well over a range of images because edges and gray shades are
important clues to objects in a scene.

Segmentation Using Edges & Gray Shades

Figure 10.1 shows the result of using edges to segment an image. The left side shows
the output of an edge detector. The right side is the result of grouping the pixels \inside"
the edges as objects | a triangle and rectangle.
This idea is simple. Detect the edges and group the pixels as objects.
Figure 10.2 illustrates growing objects using the gray shades in an image.
Pixels are grouped with a neighboring pixel if their gray shades are close enough. Two
pixels are replaced with their average and examination shifts to the neighbors of this
two-pixel object. If the gray shades of the neighbors are close enough, they become part
of the object and their values adjust the average gray shade of the object. The left side
shows the input, and the right side shows the result of growing objects in this manner.
The 1s are the background object produced by grouping the 1s, 2s, and 3s. The triangle
of 2s is a grouping of the 7s and 8s, and the rectangle of 3s is the 8s and 9s.

Image processing fourth year of computer science prepared by : Khaled Matrod


Image processing fourth year of computer science prepared by : Khaled Matrod
Figure 10.3 combines the two techniques. The left side shows a gray shade image with
the output of an edge detector (*s) superimposed. The right side shows the result of
growing regions using the gray shades while ignoring the detected edges (*s). The result
is the three objects produced in Figure 10.2 separated by the edges.

Image processing fourth year of computer science prepared by : Khaled Matrod


These three simple techniques work well in ideal situations. Most images, however, are
not ideal. Real images and image processing routines introduce problems.

Image processing fourth year of computer science prepared by : Khaled Matrod

You might also like