User:Dan.mankowitz
Range Flow is a topic in computer vision which is discussed in CVonline [1]
Introduction
[edit]Range Flow can be seen as an extension to the concept of Optical Flow. Optical Flow involves determining whether objects in an image are moving as well as the velocity with which an object is moving by analysing sequences of images[2]. This is computed and displayed as a 2D velocity vector field.
Range Flow is an extension of this concept to 3 dimensions. Here, the motion of deformable surfaces are determined from analysing sequences of depth maps [3]. The movement of objects as a result of the depth map sequence will produce a 3D velocity vector field describing the relevant object's movement. The 3D velocity is a vector of 3 components and is represented as the vector . This vector will be referred to for the remainder of the article as the 'Range Flow'.
Theory
[edit]Range Flow Constraint Equation
[edit]When analysing the motion of objects in a sequence of image frames, we can represent the time-varying motion of the object as a depth function . An assumption is made that the depth of an object in consecutive images is approximately constant . This means that a small change in depth represented by should have a negligable effect on the image. That is,
In addition to this assumption, it is also assumed that the object is made up of local planar patches [4]. This means that the depth function can be represented by a first order Taylor series yielding:
Here, represent partial derivatives and represent the local world coordinates around the point of interest [4]. This equation is then derived with respect to time and results in the following equation:
The slope does not change as it is assumed that the object undergoes a pure translation [4]. This is because the object moves an extremely small distance between consecutive depth map images. The movement can therefore be modelled as a translation. The last two terms equal zero due to the translation assumption resulting in the equation below.
This is referred to as the range flow constraint equation and is analogous to the brightness change constraint equation that is used in the calculation of Optical flow [2]. The equation is derived based on the assumption that an object observed between two consecutive frames will have a similar depth value as stated previously. The parameters denote the range flow and are equal to respectively [3]. This equation represents a constraint plane with parameters defined in the velocity solution space. The normal to the plane is .
Estimating the Partial Derivatives
[edit]Once the range flow constraint equation has been derived, the next logical step would be to calculate the range flow variables . However, there are a number of unknowns. These include the partial derivatives as well as the range flow variables . It is possible to estimate the partial derivatives using some simple matrix manipulation techniques.
The following calculation is based on the assumption that the derivatives are approximately constant in a local image neighborhood [3]. By considering an infinitesimally small movement represented by a first order approximation of the function can be computed yielding the equation below:
This equation can be extended to a linear system of equations of the form .
The system of equations are representative of a group of pixels in a local neighborhood where the partial derivatives are constant and the column vector . Each pixel is offset by a value respectively which forms the above-mentioned set of linear equations. This will enable the partial derivatives to be estimated and calculated using a pseudo inverse of the form:
The aperture problem
[edit]The aperture problem is an effect that causes ambiguities in determining the direction of motion of objects in a scene [5]. For example, consider looking through a small aperture at a plane with a uniform texture. It is impossible to visually determine the motion of the plane simply by looking through the aperture. This is extended to range flow and is a significant problem when determining the motion of the range flow components.
Once the partial derivatives have been calculated using the pseudo-inverse, the range flow variables need to be determined. However, in calculating these variables, a number of problems exist. Firstly, this is an underconstrained problem. Only one constraint equation exists but three unknowns need to be calculated. This results in ambiguities in the velocity solution space. One constraint equation does not provide enough information to unambiguously determine the motion of the range flow components.
The range flow constraint equation defines a constraint plane in space with a vector normal to the plane. Due to the aperture problem, it is only possible to observe motion that is perpendicular to the plane. The motion of the velocity components that lie on the plane will not be visible and thus motion ambiguities arise.
The only vector that can capture motion of the plane is the normal vector . The best normal vector describing this motion is the minimal vector between the velocity origin and the constraint plane and is referred to as raw normal flow [4].
This is one instance of the aperture problem.
In order to prevent these range flow ambiguities, more constraint planes are required to intersect the current constraint plane. These planes will slice up the velocity solution space, ultimately constraining the number of ambiguous range flow solutions. There are three different kinds of image neighborhoods that can be encountered in three dimensional range data. These include corner or point-like structures, lines and planes. The range flow associated with each of these image neighborhoods are termed Full flow, Line flow and Plane flow respectively [3].
- Full Flow
This flow representation is possible on corners or points of objects. It is possible to determine all three components, , of range flow motion at these locations. This is due to at least three independent constraint planes intersecting at a single point producing a unique solution for range flow [4].
- Line Flow
When two constraint planes intersect with one another, the range flow component along the constraint line resulting from the intersection cannot be determined. However, the range flow can be resolved in all other possible directions. A vector normal to this constraint line defines the flow of the line. This vector is called the line flow and is perpendicular to the linear structure [4]. The point closest to the velocity origin which lies on the constraint line, defines the appropriate line flow vector.
- Plane Flow
On a planar surface, it is impossible to detect any changes in velocity within the plane. The only change in velocity that can be detected is any movement that occurs perpendicular to the plane [3]. This vector component is termed plane flow. This vector is constructed from a point on the constraint plane that lies closest to the velocity origin.
Methods for Determining Range Flow
[edit]Local Total Least Squares (TLS)
[edit]This method is an extension of the structure tensor algorithm used in estimating optical flow [4]. This algorithm assumes that a local image neighborhood has constant range flow. The image neighborhood consists of n pixels and each pixel has its own constraint equation. The normal to each pixel's constraint plane in velocity space is and the range flow velocity components are defined as respectively [4]. Placing each of the pixel normals in a matrix , it is possible to estimate the range flow as:
which is subject to the normalising constraint
This is structured as a total least squares formula. That is, the pixel with the minimum norm to the velocity origin defines the range flow for that image neighborhood.
Calculating these normal flows can be achieved by analysing the structure tensor matrix. This matrix will determine the dominant direction in which the depth gradient is changing [6]. The matrix is calculated using the following formula:
This creates a 4 by 4 matrix where represents the average of the partial derivative product of and respectively. The average is computed locally using a Box or Binomial Filter [3]. By analysing the eigenvalues and eigenvectors of this matrix, the desired range flow can be calculated. It turns out that the smallest eigenvalue of this matrix is corresponding to the eigenvector [4]. This enables the calculation of the full flow :
where corresponds to element in the eigenvector .
In order to calculate the line flow, the two most significant eigenvalues and therefore eigenvectors define the minimum norm solution [4]. This solution, is presented below:
Finally, calculating the plane flow is achieved from the eigenvector corresponding to the largest eigenvalue [3]. This results in the plane flow norm .
It is important to note that if the trace of the structure tensor matrix is below a certain threshold, say , then the range flow for that image neighborhood will not be calculated [4]. This is because the image neighborhood does not display significant movement and therefore the range flow does not need to be calculated saving processing time.
Global Smoothing
[edit]Another method that can be used to estimate the range flow is global smoothing. This algorithm tries to minimise distortions in the flow over the entire image, hence the use of the word smoothness. It is largely based on the optical flow smoothness algorithm called the Horn-Schunck Method [7]. In order to perform this procedure, a smoothness term is defined and this term needs to be minimised imposing a smoothness constraint [3]. The smoothness term is shown below:
Here, represents the partial derivative with respect to the velocity component. This is then added to a global energy functional [7] which needs to be minimised. This functional is of the form shown below.
Minimisation of this functional can be solved iteratively using the Euler-Lagrange equations yielding a far smoother flow field [3]. The variable determines the importance of the smoothness term. Thus the larger the value of , the smoother the flow field becomes. However, should not be increased without bound as important flow field detail may be lost if the image is over-smoothed. Therefore a trade-off results between producing a smooth flow field without much detail (large values of ) or maintaining a noisy flow field (small values of ) with a significant amount of flow field detail.
The global energy functional is determined by integrating over an area . This area is representative of a segmented part of an image. Therefore, it is important to note that this method only makes sense if the image is segmented into different moving objects [3]. Minimising the energy functional and determining a suitable value for ultimately results in an estimation of the range flow.
The Addition of Intensity
[edit]There are certain instances where intensity data may be available in addition to the depth data. If this is the case, it is possible to construct another constraint equation of the form:
This has the same structural form as that of the optical flow constraint equation. This results in two constraint equations which can be utilised in the methods mentioned previously to estimate range flow [4]. For Local TLS, the new constraint equation results in a new structure tensor matrix. Summing the two tensor matrices together yields a new structure tensor which can then be used to estimate the range flow.
This equation can also be added to the smoothness algorithm with a regularisation parameter . The parameter acts much like a tuning-knob as it is used to control the influence of the intensity data and the depth data on the specified image [4]. Low values of give more influence to the intensity data whereas higher values of creates a bias towards the range data.
The utilisation of colour information as an additional constraint to estimate the range flow in an image has also been implemented [8]. The addition of this data creates an additional constraint which ultimately enables increased accuracy in estimating the range flow. This is because it has removed some of the motion ambiguities resulting from the aperture problem mentioned previously.
Examples
[edit]An example of range flow can be seen in a synthetic depth map in figure a below [4]. The rendered version of the figure is shown in figure b. It should be noted that these images are artificial but they do illustrate the three different types of range flow. Figures c,e and g illustrate the X-Y range flow components for full flow, line flow and plane flow respectively. Figures d,f and h illustrate the X-Z range flow components for full flow, line flow and plane flow respectively.
A toy tiger was used as a test subject in order to determine if there is a significant increase in the accuracy of the range flow calculations, when intensity information is added to the system [3]. The data was gathered using a laser range finder. As can be seen in the figure, intensity data provides a significant amount of additional information yielding a more detailed range flow diagram. The diagram is more dense and the directional error as well as the magnitude error of the individual range flow components decrease [3]. Both the local TLS method and the global smoothing method experience a significant increase in detail on their respective range flow diagrams [3].
Applications
[edit]Skinning
[edit]One notable example of range flow is its use in analysing soft tissue deformation [9] . By attaching speckled garments to a subjects arm, it is possible to determine the optical flows that show the deformation of the human skin. Using depth data gathered from these observations, corresponding range flows can be calculated and can then be used in analysing the deformations.
Analysing this deformation leads to one application of optical flow called skinning. This is used in 3D animation to animate the deformation of skin around articulations as characters perform various kinds of movements [9].
Plant Leaf Motion
[edit]Another application is determining the motion of living castor oil leaves [4]. This can be used to determine the diurnal motion patterns of these leaves [4].
It should also be noted that there are many other applications for range flow such as object tracking, motion estimation and gesture recognition [10].
References
[edit]- ^ R. B. Fisher, "CVonline: an overview", Int. Assoc. of Pat. Recog. Newsletter, 27(2), April 2005.
- ^ a b D. Marshall, Optical Flow, http://www.cs.cf.ac.uk/Dave/Vision_lecture/node46.html#SECTION001101000000000000000, Last Accessed 21 January 2012
- ^ a b c d e f g h i j k l m n o p q r Spies, H., & Barron, J. L., Range Flow: The 3D Movement of Deformable Surfaces. Retrieved from homepages.inf.ed.ac.uk/rbf/CVonline/LOCAL_COPIES/SPIES1/rangeFlow.pdf
- ^ a b c d e f g h i j k l m n o p q r Spies, H., Jahne, B., & Barron, J. (2002). Range Flow Estimation. Computer Vision and Image Understanding, 85(3), 209-231. doi:10.1006/cviu.2002.0970
- ^ The Aperture Problem, http://wiki.riteme.site/wiki/Aperture_problem#The_aperture_problem, Last Accessed 08 February 2012
- ^ Structure Tensor, http://wiki.riteme.site/wiki/Structure_tensor, Last Accessed 08 February 2012
- ^ a b Horn-Schunck Method, Wikipedia, http://wiki.riteme.site/wiki/Horn%E2%80%93Schunck_method, Last Accessed 08 February 2012
- ^ Lukins, T. C., & Fisher, R. B. (2005). Colour Constrained 4D Flow Calculating Colour Constrained 4D Flow. In Proceedings of the British Machine Vision Conference, 340-348
- ^ a b c Nebel, J. C., & Sibiryakov, A. (2002). Range flow from stereo-temporal matching: application to skinning. IASTED International Conference on Visualization, Imaging, and Image Processing (pp. 758-767). Citeseer. Retrieved from http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.18.7802&rep=rep1&type=pdf
- ^ Gottfried, J. M., Fehr, J., & Garbe, C. (2011). Computing range flow from multi-modal Kinect data. Advances in Visual Computing, 15(1), 758–767. Springer. Retrieved from http://www.springerlink.com/index/74758J3775428436.pdf