Misplaced Pages

Horn–Schunck method

Article snapshot taken from Wikipedia with creative commons attribution-sharealike license. Give it a read and then ask your questions in the chat. We can research this topic together.

The Horn–Schunck method of estimating optical flow is a global method which introduces a global constraint of smoothness to solve the aperture problem (see Optical Flow for further description).

Mathematical details

The Horn-Schunck algorithm assumes smoothness in the flow over the whole image. Thus, it tries to minimize distortions in flow and prefers solutions which show more smoothness.

The flow is formulated as a global energy functional which is then sought to be minimized. This function is given for two-dimensional image streams as:

E = [ ( I x u + I y v + I t ) 2 + α 2 ( u 2 + v 2 ) ] d x d y {\displaystyle E=\iint \left{{\rm {d}}x{\rm {d}}y}}

where I x {\displaystyle I_{x}} , I y {\displaystyle I_{y}} and I t {\displaystyle I_{t}} are the derivatives of the image intensity values along the x, y and time dimensions respectively, V = [ u ( x , y ) , v ( x , y ) ] {\displaystyle {\vec {V}}=^{\top }} is the optical flow vector (which is to be solved for), and the parameter α {\displaystyle \alpha } is a regularization constant. Larger values of α {\displaystyle \alpha } lead to a smoother flow. This functional can be minimized by solving the associated multi-dimensional Euler–Lagrange equations. These are

L u x L u x y L u y = 0 {\displaystyle {\frac {\partial L}{\partial u}}-{\frac {\partial }{\partial x}}{\frac {\partial L}{\partial u_{x}}}-{\frac {\partial }{\partial y}}{\frac {\partial L}{\partial u_{y}}}=0}
L v x L v x y L v y = 0 {\displaystyle {\frac {\partial L}{\partial v}}-{\frac {\partial }{\partial x}}{\frac {\partial L}{\partial v_{x}}}-{\frac {\partial }{\partial y}}{\frac {\partial L}{\partial v_{y}}}=0}

where L {\displaystyle L} is the integrand of the energy expression, giving

I x ( I x u + I y v + I t ) α 2 Δ u = 0 {\displaystyle I_{x}(I_{x}u+I_{y}v+I_{t})-\alpha ^{2}\Delta u=0}
I y ( I x u + I y v + I t ) α 2 Δ v = 0 {\displaystyle I_{y}(I_{x}u+I_{y}v+I_{t})-\alpha ^{2}\Delta v=0}

where subscripts again denote partial differentiation and Δ = 2 x 2 + 2 y 2 {\displaystyle \Delta ={\frac {\partial ^{2}}{\partial x^{2}}}+{\frac {\partial ^{2}}{\partial y^{2}}}} denotes the Laplace operator. In practice the Laplacian is approximated numerically using finite differences, and may be written Δ u ( x , y ) = ( u ¯ ( x , y ) u ( x , y ) ) {\displaystyle \Delta u(x,y)=({\overline {u}}(x,y)-u(x,y))} where u ¯ ( x , y ) {\displaystyle {\overline {u}}(x,y)} is a weighted average of u {\displaystyle u} calculated in a neighborhood around the pixel at location (x,y). Using this notation the above equation system may be written

( I x 2 + α 2 ) u + I x I y v = α 2 u ¯ I x I t {\displaystyle (I_{x}^{2}+\alpha ^{2})u+I_{x}I_{y}v=\alpha ^{2}{\overline {u}}-I_{x}I_{t}}
I x I y u + ( I y 2 + α 2 ) v = α 2 v ¯ I y I t {\displaystyle I_{x}I_{y}u+(I_{y}^{2}+\alpha ^{2})v=\alpha ^{2}{\overline {v}}-I_{y}I_{t}}

which is linear in u {\displaystyle u} and v {\displaystyle v} and may be solved for each pixel in the image. However, since the solution depends on the neighboring values of the flow field, it must be repeated once the neighbors have been updated. The following iterative scheme is derived using Cramer's rule:

u k + 1 = u ¯ k I x ( I x u ¯ k + I y v ¯ k + I t ) α 2 + I x 2 + I y 2 {\displaystyle u^{k+1}={\overline {u}}^{k}-{\frac {I_{x}(I_{x}{\overline {u}}^{k}+I_{y}{\overline {v}}^{k}+I_{t})}{\alpha ^{2}+I_{x}^{2}+I_{y}^{2}}}}
v k + 1 = v ¯ k I y ( I x u ¯ k + I y v ¯ k + I t ) α 2 + I x 2 + I y 2 {\displaystyle v^{k+1}={\overline {v}}^{k}-{\frac {I_{y}(I_{x}{\overline {u}}^{k}+I_{y}{\overline {v}}^{k}+I_{t})}{\alpha ^{2}+I_{x}^{2}+I_{y}^{2}}}}

where the superscript k+1 denotes the next iteration, which is to be calculated and k is the last calculated result. This is in essence a Matrix splitting method, similar to the Jacobi method, applied to the large, sparse system arising when solving for all pixels simultaneously.

Properties

Advantages of the Horn–Schunck algorithm include that it yields a high density of flow vectors, i.e. the flow information missing in inner parts of homogeneous objects is filled in from the motion boundaries. On the negative side, it is more sensitive to noise than local methods.

See also

References

  • B.K.P. Horn and B.G. Schunck, "Determining optical flow." Artificial Intelligence, vol 17, pp 185–203, 1981. Manuscript available on MIT server.

External links

Category: