Image Processing Reference
In-Depth Information
6.2 Binary WOS Filters
Document images have two distinct gray level distributions corresponding to text
and background. After rank ordering, the pixel values corresponding to text go to
one end of the list and background pixels to the other. Because the median is the
sample at the center of the list, it corresponds to whichever value occurs most often.
When applied to binary values it is in effect the majority filter. This causes fine de-
tail in images to be removed. While the median is very good for preserving steps in
intensity values, it is poor at preserving the location of such steps.
As explained above, the task now becomes that of designing the optimum bi-
nary filter . The objective is still to find the weights W i and selection parameter T ,
neither of which is necessarily binary. The behavior of the binary filter
may be
expressed in terms of the linear summation and inequality shown in Eqn. 6.2.
ψ
n
1
1
,
if
W X
T
i
i
i
=
0
ψ
()
x
=
(6.2)
0
,
otherwise
In the case of binary filters, the standard median is a majority function. This may be
expressed in terms of logic. For example, for five variables, three of these are re-
quired to be 1, i.e.,
ψ
med = X 0 X 1 X 2 + X 0 X 1 X 3 + X 0 X 1 X 4 + X 0 X 2 X 3 + X 0 X 2 X 4
+ X 0 X 3 X 4 + X 1 X 2 X 3 + X 1 X 2 X 4 + X 1 X 3 X 4 + X 2 X 3 X 4 .
(6.3)
It can be seen that even for five variables the binary expression is already becoming
large. It may therefore be computed as a counting operation rather than a sorting
operation. This can result in large reductions in the processing time. It will be
shown later that this principle may be extended to grayscale images where the com-
putational advantages are even greater.
6.3 Positive and Negative Medians
Two variations on the median are the positive and negative median. These filters
behave in a similar way to the standard median filter but only allow changes in one
direction either from 0 to 1 or 1 to 0 . They are an asymmetric version of the median
filter and remove either positive or negative impulses, respectively.
 
Search WWH ::




Custom Search