DIPlib Documentation - ©1995-2008 Quantitative Imaging Group, Delft University of Technology.

IDivergence

difference measure

SYNOPSIS

#include "dip_math.h"

dip_Error dip_IDivergence ( in1, in2, mask, out )

DATA TYPES

binary, integer, float

FUNCTION

Calculates the I-divergence between each pixel value of in1 and in2. Optionally the mask image can be used to exclude pixels from the calculation by setting the value of these pixels in mask to zero.

The I-Divergence is defined as: I(x,y) = x ln(x/y) - (x - y) and is divied by the number of pixels. It is the -log of a possion distribution p(x,y)=e^(-y)/x!-y^x with the stirling approximation for ln x!. For x=0, the stirling approximation would fail, y is returned.

ARGUMENTS

Data typeNameDescription
dip_Imagein1First input, Data:x
dip_Imagein2Second input, Model:y
dip_ImagemaskMask
dip_ImageoutOutput

LITERATURE

Why Least Squares and Maximum Entropy? An axiomatic approach to inference for linear inverse problems , I. Csiszar, The Annals of Statistics, 19, 2032-2066, 1991.

SEE ALSO

MeanError, MeanSquareError, RootMeanSquareError, MeanAbsoluteError, LnNormError

DIPlib on-line documentation | Function reference | Global function index