[Insight-users] Gradient Difference Metric

Luis Ibanez luis.ibanez at kitware.com
Sat Jun 28 22:42:35 EDT 2008


Hi Aviv,

Thanks a lot for posting your corrections to this class.

They have been committed now to the CVS repository:
http://www.itk.org/cgi-bin/viewcvs.cgi/Code/Algorithms/itkGradientDifferenceImageToImageMetric.txx?root=Insight&r1=1.18&r2=1.19&sortby=date


We have tested along with the new ImageRegistration18.cxx
example in


          Insight/Examples/Registration


It will be run Nightly as the test:

            ImageRegistration18Test


It currently converges in 38 iterations for a translation
of (13,17) millimeters.



    Regards,


       Luis



-------------------
Aviv Hurvitz wrote:
> Hi Sven,
> 
> I'll give you more information than you bargained for, but the goal is 
> to save you and others from wasting any more time with this metric.
> 
> In short, the GradientDifferenceImageToImageMetric is bad! It has one 
> huge bug and a few other debatable problems. The huge bug is that it 
> returns the MAXIMUM value when the registered images are perfectly 
> aligned, whereas it should return the MINIMUM. That's right, this metric 
> actually pushes the moving image away from the right result.
> 
> I wonder how this came to be? My guess is that the original developer 
> was using it in a different framework, where registration involved 
> maximizing. I Googled a bit and the few reports on this metric were 
> either that it doesn't work or that it *maybe* works, so I guess it  
> checks out.
> 
> This is good news, actually, because it means we can change the metric 
> without worrying about breaking existing working code. :)
> 
> As for the other debatable problems:
> 1. I don't like the way it finds the "subtractionFactor" -- really slow.
> 2. I don't like the way it computes the derivative using finite 
> differences - slow and highly dependent on the magic number "delta".
> 
> I was intending to insert a formal bug fix, but I got held up by nagging 
> tasks like writing an M.Sc. thesis.
> 
> I'm attaching a fixed version, however in this version I crippled the 
> (questionable) "subtractionFactor"  feature.
> 
> As for optimizers, this metric computes its derivative using finite 
> differences, which seems somehow wrong. (Isn't this the job of the 
> optimizer?) I recommend to use a derivative-free optimizer like 
> AmoebaOptimizer or SPSAOptimizer.
> 
> Hope this helps.
> 
> - Aviv
> 
> On Wed, Jun 25, 2008 at 2:44 PM, Fischer, Sven 
> <Sven.Fischer at medizin.uni-leipzig.de 
> <mailto:Sven.Fischer at medizin.uni-leipzig.de>> wrote:
> 
>     Hi all,
> 
>      
> 
>     I'm using the Gradient Difference Metric for registering two images.
>     It seems to me that I have a global optima at the correct position,
>     but there are also a lot of local optima. So the registration isn't
>     able to find the correct transformation. Has someone an advice which
>     optimizer I should use or how I could smooth the objective function?
> 
>     Also I wished to know if there is a pattern intensity metric
>     available in ITK?
> 
>      
> 
>     Regards,
> 
>     Sven
> 
> 
>     _______________________________________________
>     Insight-users mailing list
>     Insight-users at itk.org <mailto:Insight-users at itk.org>
>     http://www.itk.org/mailman/listinfo/insight-users
> 
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Insight-users mailing list
> Insight-users at itk.org
> http://www.itk.org/mailman/listinfo/insight-users


More information about the Insight-users mailing list