This method neatly demonstrates gradient-based direct image alignment: it fits a a target image to a reference image using a homography.
However, it also includes some great software for use in other projects:
Autodiff - fairly comprehensive auto differentiation class, to dramatically simplify and speed up development of gradient-based optimization.
Lie - Lie algebra class supporting various geometric groups, which also supports auto differentiation.
Ojw_interp2 - Fast mex-based image and gradient sampling, which also supports auto differentiation. Mex this function first by calling "mex ojw_interp2.cpp" in the directory you installed the files from this submission in.
Oliver Woodford (2022). Image Alignment Demo with several goodies: Lie algebra, auto differentiation... (https://www.mathworks.com/matlabcentral/fileexchange/62547-image-alignment-demo-with-several-goodies-lie-algebra-auto-differentiation), MATLAB Central File Exchange. Retrieved .
MATLAB Release Compatibility
Platform CompatibilityWindows macOS Linux
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!Start Hunting!