[ITK] [ITK-users] Multiresolution Registration error while trying to improve a journal paper
Dženan Zukić
dzenanz at gmail.com
Tue Feb 9 10:18:18 EST 2016
Hey Vishal,
I tried setting the transform to the metric, and that gets rid of the
"transform not set" exception:
metric->SetTransform(transform);
metric->SetInterpolator(interpolator1);
metric->Initialize();
Take a look at the Initialize method on line 300 in
ITK-git\Modules\Registration\Common\include\itkImageToImageMetric.hxx to
see all the things you need to provide to metric before a call to
initialize.
I guess that you are also migrating the code from registration V3 framework
to V4, in addition to going from 2 projections to 1, which complicates your
life. May I suggest you first do one, and once that works then the other?
E.g. first update the example to use V4 registration framework, and then
change the code to go from two projections to one.
Regards
On Tue, Feb 9, 2016 at 2:28 AM, vishal <itkhelpacc at gmail.com> wrote:
> hi,
> I made some changes to the code i attached previously no i getting this
> error:
>
> Starting the registration now...
> Exception in the Metric )intialize caught!!
> itk::ERROR: NormalizedCorrelationImageToImageMetric(0000000002832510):
> Transform
> is not present
> -------------------------------------
> MultiResolution Level : 0
>
> ExceptionObject caught !
>
> itk::ExceptionObject (000000000027E8A0)
> Location: "void __cdecl itk::NormalizedCorrelationImageToImageMetric<class
> itk::
> Image<float,3>,class itk::Image<float,3> >::GetValueAndDerivative(const
> class it
> k::OptimizerParameters<double> &,double &,class itk::Array<double> &)
> const"
> File:
> c:\itk\insighttoolkit-4.8.2\modules\registration\common\include\itkNormali
> zedCorrelationImageToImageMetric.hxx
> Line: 332
> Description: itk::ERROR:
> NormalizedCorrelationImageToImageMetric(000000000283251
> 0): The gradient image is null, maybe you forgot to call Initialize()
>
> Please find the modified code along with this post... please help me out
> with this problem!!
> regards
> Vishal
>
> code: RegularStepGradientDescentWithNGC.cxx
> <
> http://itk-users.7.n7.nabble.com/file/n36758/RegularStepGradientDescentWithNGC.cxx
> >
>
>
>
> --
> View this message in context:
> http://itk-users.7.n7.nabble.com/Multiresolution-Registration-error-while-trying-to-improve-a-journal-paper-tp36739p36758.html
> Sent from the ITK - Users mailing list archive at Nabble.com.
> _____________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Kitware offers ITK Training Courses, for more information visit:
> http://www.kitware.com/products/protraining.php
>
> Please keep messages on-topic and check the ITK FAQ at:
> http://www.itk.org/Wiki/ITK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/insight-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/community/attachments/20160209/f2a4e2c0/attachment-0001.html>
-------------- next part --------------
_____________________________________
Powered by www.kitware.com
Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html
Kitware offers ITK Training Courses, for more information visit:
http://www.kitware.com/products/protraining.php
Please keep messages on-topic and check the ITK FAQ at:
http://www.itk.org/Wiki/ITK_FAQ
Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/insight-users
More information about the Community
mailing list