[Insight-users] Re: Initial Level : Tracking motion in video
sequences & GeodesicActiveContours.
Luis Ibanez
luis.ibanez at kitware.com
Sat, 24 Apr 2004 20:09:42 -0400
Hi Jayant,
You probably want to combine both the information from
the difference image and the original images.
For example, in order to generate a mask for the subject
that is walking in the scene, you could take the current
binarization of the difference image and perform on it
morphological operations in order to fill the inside.
Note that a filter such as the BinaryMedianImageFilter
http://www.itk.org/Insight/Doxygen/html/classitk_1_1BinaryMedianImageFilter.html
will produce a similar effect, and probably much faster,
specially if you use masks on the order of 5 pixels wide.
One great advantage in your case is that the mask that you
provide to the GAC level set filter doesn't have to be perfect,
a rough initialization around the object is enought.
The speed image should be computed from the *most*
recent image in the sequence. Not from the difference
image. The goal in the speed image is to capture the edges
from the image to which you want to fit the contour
implicitly represented by the level set.
So, if you have two images
Ai Ai+1
and their differnce Di = Ai+1 - Ai
you can generate a level set Li = Median( Di )
and feed it as input to the GAC.
The speed image will be
Si = Sigmoid( GradientMagnitude( Ai+1 ) )
This speed image will be passed to the GAC filter.
Note also that if you have a long sequece of A images,
you only need to do the initailization of the level set
for the first pair of images. After that, you simply
keep changing the Speed image by the speed image
of the next A image in the series .
The resulting level set of one pair will be used as
the inital level set of the next pair.
Regards,
Luis
-------------------------
Jayant Chauhan wrote:
> Hey Luis,
>
> Thanks for clarifying my blunder :)
>
> One last doubt regarding this. As you have said, I should not give a
> contour but a region. But is that with reference to just the initial
> level set or is even the feature image supposed to be like that ? (as
> in, I was a bit confused by u asking me to " filling in the inside of
> the figure that you define as the object" ). Because I dont have any
> prior knowledge of the object, only the difference image. So is it
> just the init level set that you meant, as in a solid rectangle
> instead of just the rectangular mesh ???
>
> with regards
>
> Jayant Chauhan
>
>
>