Learn R Programming

Rvision (version 0.6.0)

findTransformECC: Enhanced Correlation Coefficient-based Geometric Transform

Description

findTransformECC computes the geometric transform between two images in terms of the Enhanced Correlation Coefficient criterion.

Usage

findTransformECC(
  template,
  image,
  warp_mode = "affine",
  max_it = 200,
  epsilon = 0.001,
  filt_size = 0
)

Arguments

template

A grayscale Image object.

image

A grayscale Image object of the same dimensions as template.

warp_mode

A character string indicating the type of warping required to transform image into template. It can be any of the following:

  • "translation":simple translational transformation.

  • "euclidean":Euclidean (rigid) transformation (translation + rotation).

  • "affine" (default):affine transformation (Euclidean + shear; this transformation will preserve parallelism between lines).

  • "homography":homography transformation (affine + perspective; this transformation does not preserve parallelism between lines).

max_it

The maximum number of iterations (default: 200).

epsilon

The convergene tolerance (default: 1e-3).

filt_size

The size in pixels of a gaussian blur filter applied to the images before computation of the transform. When set to 0 (the default), no filtering is applied.

Value

A 2x3 or 3x3 (if warp_mode = "homography") matrix.

References

Evangelidis, G. D., and Psarakis, E. Z. (2008). Parametric image alignment using enhanced correlation coefficient maximization. IEEE Trans. Pattern Anal. Mach. Intell. 30, 1858<U+2013>1865. doi:10.1109/TPAMI.2008.113.

See Also

computeECC, findTransformORB

Examples

Run this code
# NOT RUN {
file1 <- system.file("sample_img/balloon1.png", package = "Rvision")
file2 <- system.file("sample_img/balloon2.png", package = "Rvision")
balloon1 <- changeColorSpace(image(file1), "GRAY")
balloon2 <- changeColorSpace(image(file2), "GRAY")
findTransformECC(balloon1, balloon2)

# }

Run the code above in your browser using DataLab