Gamma LAT: Reference Manual


ratio

ANSI-C program: ratio.c

NAME
ratio - Estimate ratio of image data values: d1/d2  (float data).

SYNOPSIS
ratio <d1> <d2> <rati> <width> [bx] [by] [wgt_flg]

<d1> (input) data file 1 (float)
<d2> (input) data file 2 (float)
<ratio> (output) ratio: d1/d2  (float)
<width> number of samples/row of the input image
[bx] number of range samples to average before evaluating ratio (default: 5)
[by] number of azimuth lines to average before evaluating ratio (default: bx)
[wgt_flg] weighting flag
     0: no weighting function applied (default)
     1: linear weighting function
     2: Gaussian weighting function

EXAMPLE
ratio 19990915.mli 19991020.mli 19990915_19991020.ratio 2456 15 15 1

In the selected example both images are averaged using a 15 x 15 pixels window before the ratio between the averaged images 19990915.mli/19991020.mli is calculated. 

DESCRIPTION

ratio estimates the ratio between two data files. In the case of radar images it is very important to first sufficiently filter the individual images before calculation of the ratio. This is due to radar speckle noise in the backscatter data. The program ratio does this filtering using an running average with user-defined filter size and optional weighting function. The input and the output data are binary files of type float.

The size of the window used for the filtering and the weighting function to apply may be specified. For weights_flag:0 no spatial weighting function is applied to the data, i.e. all filter coefficients are set to 1. For weights_flag=1 a linear triangular weighting function is applied, i.e. the filter coefficients decrease linearly with increasing distance to the center of the filter window. For weights_flag=2, a Gaussian weighting function is applied, i.e. the filter coefficients decrease with increasing distance to the center of the filter window following a Gauss function.
The ratio of two radar backscatter images reflects the relative change. Calculating the ratio and converting the result to dB scale is equal to expressing both backscatter images in dB scale and then taking the difference between the first and the second image. The result may be converted to dB scale with the program linear_to_dB. Instead of the built in running average filtering adaptive filtering may be preferred using the program frost.

SEE ALSO
typedef_ISP.h, linear_to_dB, frost .


© Copyrights for Documentation, Users Guide and Reference Manual by Gamma Remote Sensing, 2015.
UW, CW, last change 5-Feb-2015.