**Introduction**

Spatial convolution filtering- based on the use of convolution masks

- used to enhance low and high frequency detail, and edgesLinear spatial filteroutput BVij

= function (weighted average of BVs around input pixel (i,j)

Convolution mask or kernel- 2 dimensional window of coefficients- size of neighborhood is usually 3x3, 5x5, 7x7, 9x9

c

_{1}c_{2}c_{3}

- mask template = c_{4}c_{5}c_{6}

c_{7}c_{8}c_{9}

_{Input image subset}

1,1 1,2 1,3 1,4 1,5 2,1 2,2 2,3 2,4 2,5 3,1 3,2 3,3 3,4 3,5 4,1 4,2 4,3 4,4 4,5 5,1 5,2 5,3 5,4 5,5 1 1 1

Mask A = 1 1 1

1 1 1c

_{1}x BV_{1,1}c_{2 }x BV_{1,2}c_{3}x BV_{1,3}

Mask template = c_{4}x BV_{2,1}c_{5 }x BV_{2,2}c_{6}x BV_{2,3}

c_{7}x BV_{3,1}c_{8 }x BV_{3,2}c_{9}x BV_{3,3}Output pixel BV

_{2,2}= Int [ (c1 x BV_{1,1}+ c2 x BV_{1,2}+ ... c9 x BV_{3,3}) / 9 ]Spatial moving window begins at pixel (2,2) then shifts to the next pixel (2,3) and repeats for every pixel in input image

Low frequency (low pass) filters -image enhancement that de-emphasize or block the high spatial frequency detail

Low pass filter ("smoothing")3 by 3 matrix of coefficients

Set of coefficients used for image smoothing and noise removal:

1/9 * 1 1 1 1 1 1 1 1 1 Sample image:

3 3 4 4 5 6 2 3 3 4 4 5 1 2 2 3 3 4 1 1 2 4 4 7 1 2 4 20 20 20 2 3 6 20 20 20 2 3 4 20 20 20 Image has a low smoothly varying gray scale, except for the bottom right region, which exhibits a sharp brightness changeTo eliminate edge effect - - - > start the overlay of the moving window pixel (2,2) end on pixel (6,5)

Output pixel (2,2) would be________________.

Fill in the table below to determine the output image from the input image subset above applying a 3x3 low-pass filter given above.

High pass filtering is applied to imagery to remove the slowly varying components and enhance high frequency local variations.E.g., output BV

_{2,2}= (2 x BV_{2,2}) - output BV_{2,2}from low pass filterHigh pass filters that accentuate or sharpen edges produced by applying convolution masks shown in 7-14 and 7-15.

Edge enhancement delineates edges surrounding objects.Linear and non linear edge enhancement techniques

Linear edge enhancement

- directional first difference that approximates the first derivative between 2 adjacent pixels
- algorithm produces first difference of input image in horizontal, vertical, and diagonal edges

Vertical: BV

_{i,j}= BV_{i,j}- BV_{i,j+1}+ KHorizontal: BV

_{i,j}= BV_{i,j}- BV_{i-1,j}+ KNE diagonal: BV

_{i,j}= BV_{i,j}- BV_{i+1,j+1}+ KSE diagonal: BV

_{i,j}= BV_{i,j}- BV_{i-1,j+1}+ K

- the subtraction (BV

_{i,j}- BV_{i,j+1}) can be either positive or negative, so constant K is added to make all values positive and centered between 0 and 255.

ArcView Spatial FilteringImages for this exercise are found under ~tracyd/Geog474/images directory on strauss and the files are called:

flevolandradar.img

landsat_tm_manaus.img

landsat_tm_rondonia.imgExamine the spatial filtering enhancement capabilities available with ArcView. Online Help discusses the spatial enhancement tools under:

Content ---> Extensions ---> Image Analysis --->Working with Image Analysis Themes ---> Smoothing and Image, Sharpening an image

QUESTION: For continuous remotely sensed data, what type and size of convolution kernel is used to apply a smooth filter to an image? What type and size of convolution kernel is used to sharpen an image? Do you have an capabilities to alter the convolution kernel?Smoothing image appearance

Add the

Sharpening an imageflevolanradar.imgimage analysis data theme to a view. This theme is a radar image with high degree of speckling typical of most radar data. Remove the noise by applying a smooth filtering (low pass filter). To highlight the speckled radar image, select Zoom to Image Resolution from theView menu or click the Zoom to Image Resolution button. Do the same for the smoothed image.

Describe the resultant smoothed image in comparison to the original radar image.

Perform the smoothing filter to the Amazon images - landsat_tm_manaus.img or landsat_tm_rondonia.img.

Describe the resultant smoothed image in comparison to the original image.

Apply a sharpening filter to the Amazon image.

Describe the resultant sharpened images in comparison to the original image.Erdas ImagineTake a look at the spatial enhancement capabilities available with Erdas Imagine. What types of spatial enhancement tools are available with Imagine. Which s/w has greater capabilities?

To start Imagine, logon to strauss and the bring up an xterm window on Geography's SGI davinci.

strauss% ssh davinci.geog

password:davinci.geog% imagine

If you are adventuresome, load an image and apply a spatial filter.Turn in answers to the questions above by Wednesday, November 24, 1999. You are not required to print any of the original or enhanced images.

Source: Remote Sensing Core Curriculum Module 6.4 (Faust)

*Last revised on November 18, 1999 by Tracy DeLiberty.*