VCORR

VisionX V4
NAME

vcorr - calculates various template matching metrics.

SYNOPSIS

vcorr [if=] [of=] [k=] [s=] [c=] [r=] [vx=] [th=] [thk=] [-c] [-r] [-n] [-e] [-a] [-m] [-l] [-d] [-i] [-v] [-sh] [-wi]

DESCRIPTION

vcorr calculates various matching metrics between input subimage [if=] and template either specified using input argument [k=] or selected from built-in functions using the option [s=] at a single point. The available matching metric options are normalized covariance (correlation factor) [-c], cross correlation [-r], convolution [-n], mean square error [-e] and mean absolute error [-a].

If -i is specified, the program searches the entire image for the location of the template that gives the best metric. The program will output the location and corresponding metric value if the -wi or -sh flags are specified. A floating point output image will ALWAYS be generated; the value of each pixel is the value of the metric at that point in the original image.

The metric is computed only for those pixels where the template (k=) completely fits; the pixels in the areas of the image where the template doesn’t completely fit will be set to 0. If the template image has an even size in any dimension, the location will be offset by a pixel in that dimension.

OPTIONS

[if=]

input file: Input Image (byte, short, or float format)

[of=]

output file: only for -i and -n flags. Always generated for -n flag; for -i flag, only output if of= is specified.

[k=]

kernel image. Only float images are accepted.

[s=]

kernel function: 0=cube, 1=sphere, 2=gauss, 3=LOG, 4=sphere2 5=wLOG (default: gauss)

[c=]

tx,ty,tz: point to compute metric (default: xc=yc=zc=0)

[r=]

radius if sphere kernel selected or sigma for gauss kernel(default=1

[vx=]

anisotropic voxels: ratio between z-res and xy-res (default=1

[th=]

input image intensity threshold

[thk=]

kernel intensity threshold

[-c]

correlation coefficient(normalized cross covariance)

[-r]

correlation

[-n]

convolution

[-e]

MSE (mean square error)

[-a]

MAE (mean absolute error

[-m]

partition template(positive and negative)

[-l]

absolute matching

[-d]

generate the kernel

[-i]

search through the entire if image for the best location of the k= image. Currently only works with -c and -e.

[-v]

verbose operation

[-sh]

output metric (and location with -i) in shell format

[-wi]

output metric (and location with -i) in TCL format

CONSTRAINTS

The kernel image (k=) must be a floating point image. Calculations are done internally in floating point.

For computing metrics, the images should be the same size (that is, if -i or -n are not used).

SEE ALSO

vcorr

AUTHOR

Andinet Asmamaw and Artit Jirapatnakul