Optical Flow (OF) approaches for motion estimation calculate vector fields for the apparent velocities of objects in image sequences. In 1981 Horn and Schunck (HS) introduced two basic assumptions: "brightness value constancy" and "smooth variation" to estimate a smooth OF field over the entire image -global approach-. In parallel, Lucas and Kanade (LK) assumed constant motion patterns for image patches, estimating piecewise-homogeneous OF fields -local approach-. Several variations of these approaches exist today. Here we present the combined local-global (CLG) approach by Bruhn et al. which encompasses properties of HS-OF and LK-OF, aiming to improve the OF accuracy for small-scale variations, while delivering the HS-OF dense and smooth fields. A multiscale implementation is provided for 2D images, together with two numerical solvers: Successive Over-Relaxation and the faster Pointwise-Coupled GaussSeidel by Bruhn et al.. The algorithm works on gray-scale (single channel) images, with color images being converted prior to the OF computation.
Source CodeThe source code (ANSI C), its documentation, and the online demo are accessible at the IPOL web page of this article 1 .
Supplementary MaterialSample images and the CLG-OF demo are available here 2 .