[Insight-users] Supplying a transform to the metric?

Luis Ibanez luis.ibanez at kitware.com
Sun Nov 22 16:34:35 EST 2009


Hi Motes,

If you set the Transform to Identity, then the actual type
of transform that you use shouldn't have any impact on
the value that is computed by the metric.

You could use a Translation, Affine or BSpline transform,
and as long as you initialize them to Identity, you should
get the same value of the Metric.

As Bill pointed out,
you could simply use the itk::IdentityTransform.

You may also want to take a look at the example:

           Insight/Examples/Registration/
                         MeanSquaresImageMetric1.cxx


    Regards,


           Luis


--------------------------------------------------------------------------------------
On Wed, Nov 18, 2009 at 4:02 AM, motes motes <mort.motes at gmail.com> wrote:
> I am working on a little function that given two images computes the
> metric value. In this context I was wondering if the type of transform
> has any influence on the metric value.
>
> Setting up the metric typically looks something like this:
>
>    transform->SetIdentity();
>    metric->SetTransform(transform);
>    metric->SetInterpolator(interpolator);
>    metric->SetFixedImage(imageF);
>    metric->SetMovingImage(imageM);
>    metric->SetFixedImageRegion(region);
>
> Is it true that it does not matter what type of transform is
> specified? I have tried with :
>
>  typedef itk::BSplineDeformableTransform<CoordinateRepType,
> Dimension, SplineOrder>      TransformType;
>  typedef itk::AffineTransform< double, Dimension>
>                       AffineTransformType;
>
> but it does not seem to change the metric value.
>
> If the metric only needs to get the indentity transform, is it
> possible to supply this without using one of the above specific
> transform typedefs?
> _____________________________________
> 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.html
>
> 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://www.itk.org/mailman/listinfo/insight-users
>


More information about the Insight-users mailing list