[Insight-users] Re: GradientDifferenceImageToImageMetric?

Vicente Grau vicente at robots.ox.ac.uk
Thu Feb 23 04:30:58 EST 2006


Damiaan,

sorry for taking so long to reply. You can see the discussion about this 
class in

http://public.kitware.com/pipermail/insight-users/2005-December/015845.html

I also think the metric doesn't work well. But, as you say, it could be 
that I wasn't using it correctly. The documentation on this is very 
limited, and it doesn't seem that many people are using it.

Vicente


D.F.Habets wrote:

> Hi Vincent,
>
>   thank you for replying.
>
>> are you using the CVS version? Some time ago, I reported a bug on 
>> this metric that was then corrected.
>
>
> I should be using the CVS version. Could you let me know what the bug 
> was? Or was it the one where the test was ran and the GetValue metric 
> didn't change? The GetValue it returns seems ok, however, the 
> derivatives are problematic.
>
>> delta value is used here just to approximate the derivative with a 
>> finite difference calculation. In other metrics, the derivative is 
>> calculated explicitly.
>
>
> Yes, that delta function seems to still be hard coded to 0.001, and 
> I've changed that now, however, that still results in many cases where 
> the derivative will always return 0 because the range of values for 
> the parameters is larger.
>
> I wasn't sure this was right either:
>
> - In GetValue():
> subtractionFactor[iDimension] shouldn't that never be 0? (It's 
> initialised to 0)
>
> - In ComputeVariance:
> m_MinMovedGradient[iDimension] = gradient
>
> shouldn't that be
>
> m_MinFixedGradient[iDimension] = gradient; ?
>
> Same for Max.
>
> There's some more things that I find questionable, but it could just 
> me misunderstanding some of the code.
>
> Has anyone successfully used it? Or is the concensus that this metric 
> isn't ready for use?
>
> Thanks,
> Damiaan
>


More information about the Insight-users mailing list