myimagelib.myImageLib.normxcorr2¶
- myimagelib.myImageLib.normxcorr2(template, image, mode='full')¶
Compute normalized cross-correlation map between an image and a template. Input arrays should be floating point numbers.
- Parameters
template (float array) – N-D array, of template or filter you are using for cross-correlation. Must be less or equal dimensions to image. Length of each dimension must be less than length of image.
image (float array) – N-D array
mode – Options, “full”, “valid”, “same”. full (Default): The output of fftconvolve is the full discrete linear convolution of the inputs. Output size will be image size + 1/2 template size in each dimension. valid: The output consists only of those elements that do not rely on the zero-padding. same: The output is the same size as image, centered with respect to the ‘full’ output.
- Returns
N-D array of same dimensions as image. Size depends on mode parameter.
- Return type
float array