[Insight-users] An overlap invariant mutual information metric
Luis Ibanez
luis . ibanez at kitware . com
Tue, 25 Nov 2003 11:21:14 -0500
Hi Jessica,
This error message indicates that your Transform is
so far off that the moving image is mapped quite far
from the fixed image. As a result there is no overlap
at all between the images and therefore the metric
cannot compute the similarity of the matching.
Here are some suggestions:
1) Very important: create an itk::Command class and
connect it as observer to the optimizer. You will
find multiple examples on the SoftwareGuide on how
to do this. Having an observer will provide you
feedback on the evolution of the transform as the
optimization process is running.
http://www . itk . org/ItkSoftwareGuide . pdf
2) Make sure that origin and spacing on both of your
images are assigned correctly. They don't have to
be the same, just check that the values correspond
to the actual physical range.
3) Check how you are initializing the transform.
It may be that from the very beginning your transform
is far off. A simple way to start is to set up the
transform to the identy by using the SetIdentity() method.
Please let us know if you have further questions,
Thanks
Luis
------------------------
Jessica de Ryk wrote:
> I have still been trying to implement the NormalizedMutualInformationMetric.
> As it is, my code generates a run time error that states 'all the points
> mapped to outside of the moving image'
> I am using;
> TranslationTransform
> RegularStepGradientOptimizer
> LinearInterpolateImageFunction
>
> unsigned int nBins = 50;
> MetricType::HistogramType::SizeType histSize;
> histSize[0] = nBins;
> histSize[1] = nBins;
> metric->SetHistogramSize(histSize);
>
> metric->SetPaddingValue(-1);
> metric->UsePaddingValue();
>
> I have set optimizer->MaximizeOn();
> optimizer->SetMaximumStepLength(2.0)
> optimizer->SetMinimumStepLength(0.005)
> optimizer->SetNumberOfIterations(200)
>
> I have set the
> Any ideas what could be causing this error?
> Thanks
> Jess
>
>
> _______________________________________________
> Insight-users mailing list
> Insight-users at itk . org
> http://www . itk . org/mailman/listinfo/insight-users
>