From: Susan on
I'm resurrecting an old question here.

> "Sachitha Obeysekara" <sachitha.obeysekara(a)nospam.nokia.com> wrote:
> > Hi,
> > I have a filter formed by:
> > b = fir1(5,0.5)
> > b =
> > -0.0078 0.0645 0.4433 0.4433 0.0645 -0.0078
> > Whats the most efficient way of applying this filter to a 2D
> > image, first in the x-direction, then in the y-direction?
> > ...I've already considered using ftrans2 to form a 2D filter
> > and do it all in one go, but I want to to it the 1D way.

and Peter Boettcher <boettcher(a)ll.mit.edu> replied:
(in message <muy7ibwy1py.fsf(a)G99-Boettcher.llan.ll.mit.edu>)
> That's called a separable filter, and it is indeed much more efficient
> to apply it separately than to form the full 2D kernel.
> "conv2" will do the separable filter for you. Just specify the same
> kernel for both H1 and H2.

My question is, the image data that results from doing the conv2 using a 1D fir filter on a 2D image now has negative values. Unlike audio data that varies above and below zero, the data range for images is all positive. How do you interpret the negative values in the filtered image?
Specifically, I'm blurring a simple white (1, or 255) rectangle on a black background (0). Using this type of filtering, the result has some negative values. Is there a valid normalization procedure to use? If you just raise everything up, then the filtered image has ripples - but maybe that just reflects an inadequate filter?
In general, are there things to be aware of when comparing 1D and 2D results?
Thanks! - Susan