This Matlab GUI demonstrates how muscle fascicles from the medial gastrocnemius (MG) muscle in humans that are imaged using B-mode ultrasound can be automatically tracked using optical flow algorithms utilising an affine transformation to track end points of muscle fascicles as determined in an initial frame.
Please cite the following manuscripts in any academic work which uses this algorithm -
1. Cronin, NJ, Carty, CP, Barrett, RS & Lichtwark G. (2011) Automatic tracking of medial gastrocnemius fascicle length during human locomotion. Journal of Applied Physiology. In Press. doi:10.1152/japplphysiol.00530.2011
2. Gillett, J, Barrett, R & Lichtwark, G. (2011) Reliability and accuracy of an automatic tracking algorithm to measure passive and active muscle fascicle length changes from B-mode ultrasound. Computer Methods in Biomechanics and Biomedical Engineering. In Press.
This toolbox requires the Image Processing toolbox.
This toolbox utilises Dr David Young's (Susses University) excellent algorithms for calculating the optical flow using the affine transformation
extension - http://www.mathworks.com/matlabcentral/fileexchange/27093-affine-optic-flow
It also uses Sandra Martinka's Rubberband Line function -
The GUI comes with an example video file and represents a passive rotation of the ankle which in turn changes the length of the MG muscle. This may require DivX codecs to be installed. Please read README.txt file for full information.