[Insight-users] different spacing

Grace Chen Grace.Chen at swri.ca
Wed Dec 28 14:36:36 EST 2005


Hi Luis,

Sorry, I should have explained a little more.

My program has several levels.  The input images were first stored as
vtkImageData.  I moved the fixed image using a vtkTransform object.  Then, I
used a lower level program which converts these vtkImageData to ImageData in
ITK and perform registration using ITK.

The ouput of the optimizer seems to improve the image.  I use
MattesMutualInformationImageToImageMetric. And the ouput of  the first and
last 10  interations are listed as followed:

[optimizer->GetCurrentIteration() , optimizer->GetValue() ,
optimizer->GetCurrentPosition()]
0 -0.180789 [-0.00372431, -0.00216522, -0.00342151, 0.0378279, -0.24234,
0.763643]

1 -0.188343 [-0.00466395, -0.0035364, -0.00456701, 0.158607, -0.401006,
0.778505]

2 -0.189109 [-0.00576653, -0.00498698, -0.00826052, 0.303473, -0.53851,
0.784736]

3 -0.191558 [-0.00700445, -0.00593562, -0.00978375, 0.433646, -0.690175,
0.790528]

4 -0.19593 [-0.0078935, -0.00709936, -0.0107574, 0.591992, -0.811806,
0.801494]

5 -0.197633 [-0.00820251, -0.00741444, -0.0104682, 0.728001, -0.955385,
0.831249]

6 -0.198881 [-0.00741882, -0.00554459, -0.0136817, 0.88545, -1.0598,
0.89643]

7 -0.200073 [-0.00726651, -0.0062833, -0.0140401, 0.985172, -1.22836,
0.936929]

8 -0.201326 [-0.00560797, -0.0076424, -0.0215794, 1.14407, -1.33802,
0.98674]

9 -0.203174 [-0.00389283, -0.00771673, -0.0122035, 1.06042, -1.38851,
0.996157]

10 -0.204234 [-0.00378966, -0.0086788, -0.0158924, 1.04266, -1.48046,
1.0304]

 ......

190 -0.211569 [0.00630339, -0.00207671, -0.00499892, 1.33912, -3.38962,
2.04202]

191 -0.211627 [0.00623288, -0.00207366, -0.00491154, 1.34527, -3.39987,
2.04566]

192 -0.211695 [0.0062031, -0.00205791, -0.00481467, 1.35246, -3.40914,
2.04997]

193 -0.211739 [0.00619409, -0.00206643, -0.00479264, 1.359, -3.41882,
2.05441]

194 -0.211778 [0.00619392, -0.00206125, -0.00470146, 1.36589, -3.42833,
2.05869]

195 -0.211825 [0.00620295, -0.00204558, -0.00465544, 1.37306, -3.43779,
2.06261]

196 -0.211863 [0.00621339, -0.00200221, -0.00454069, 1.37962, -3.44758,
2.06679]

197 -0.211899 [0.00622509, -0.00194811, -0.00455557, 1.38273, -3.45872,
2.07151]

198 -0.211928 [0.00621682, -0.0018781, -0.00455407, 1.38537, -3.47006,
2.07607]

199 -0.211961 [0.00616729, -0.00182871, -0.00457491, 1.3884, -3.48145,
2.08022]



Grace



----- Original Message ----- 

From: "Luis Ibanez" <luis.ibanez at kitware.com>
To: "Grace Chen" <Grace.Chen at swri.ca>
Cc: <insight-users at itk.org>
Sent: Wednesday, December 28, 2005 2:11 PM
Subject: Re: [Insight-users] different spacing


>
> Hi Grace,
>
>
>   *  Did your registration converged ?
>
>
>   *  Could you please post the output of the Command/Observer
>      class that you connected to the optimizer ?
>
>
>   *  Why is that you end up with a vtkTransform
>      if you are doing registration with ITK ?
>
>
>
> Please let us know,
>
>
>    Thanks
>
>
>       Luis
>
>
>
> -----------------
> Grace Chen wrote:
> > Hi Luis,
> >
> > Thanx for the reply.  I know the registration should have been done in
the
> > physical space.  Even if the viewer I use is a naive viewer, after I
apply
> > the registration transform and then I scale the image, both images (now
look
> > approximiatly of the same size) should look aligned too, am I correct?
But
> > that's not the case for me.
> >
> > By looking at the result of the registration, I notice that the
translation
> > is ( 1.3884, -3.48145, 2.08022) which is not the movement I simulated
i.e.
> > through the call transform->Translate(5, -25, 0).<'transform' is a
> > vtkTransform.>
> >
> > Grace
> >
> > ----- Original Message ----- 
> > From: "Luis Ibanez" <luis.ibanez at kitware.com>
> > To: "Grace Chen" <Grace.Chen at swri.ca>
> > Cc: <insight-users at itk.org>
> > Sent: Wednesday, December 28, 2005 1:32 PM
> > Subject: Re: [Insight-users] different spacing
> >
> >
> >
> >>Hi Grace,
> >>
> >>Please read with more attention the "Image Registration" Chapter
> >>of the ITK Software Guide.
> >>
> >>
> >>If the two images are taken from the same patient and the image
> >>spacings are set correctly by the scanner, you *should not need*
> >>to do *any scaling* when registering the images.
> >>
> >>
> >>The fact that the images look of different sizes in your screen
> >>just shows that you are using a poor image viewer.
> >>
> >>
> >>You are probably comparing the images based on their number of
> >>pixels instead of based on their physical extent in space.
> >>
> >>
> >>
> >>Please study Figure 8.7 in pdf-page 358.
> >>
> >>
> >>The Transfrom that ITK compute is the one that maps the *physical*
> >>space of one image into the *physical* space of the other image.
> >>
> >>
> >>In that context, if the patient is the same, you shouldn't need
> >>any scaling unless the head of the patient if physically shrinking
> >>or expanding between the time of acquiring both scans. (hopefully
> >>that doesn't happen in any hospital).
> >>
> >>
> >>The transformations from the discrete image grid and the physical
> >>space are done using the origin and spacing. (Transform T1 and T2
> >>in Figure 8.7).
> >>
> >>
> >>The transform that ITK computes for you is the "Space Transform".
> >>
> >>Please read Section 8.3, from the ITK Software Guide
> >>
> >>
> >>and also read the Tutorial
> >>
> >>http://wiki.na-mic.org/Wiki/images/b/ba/Insight-Registration.ppt
> >>
> >>
> >>
> >>    Regards,
> >>
> >>
> >>      Luis
> >>
> >>
> >>
> >>------------------
> >>Grace Chen wrote:
> >>
> >>>Hi there,
> >>>
> >>>I am trying to perform multi-modality registration for two volumes.
The
> >>>two image data have different physical attributes, etc.
> >>>different origin, spacing and dimension (so, on the screen, one looks
> >>>bigger than the other).  I simulated a movement (e.g. a translation (5,
> >>>-25, 0) in the fixed image.  However, when the registration program
> >>>returns, the final transform matrix is
> >>>
> >>>
> >>> 0.999951     0.00912699   -0.00371374     1.3884
> >>>
> >>>-0.0091721   0.999882       -0.0123175       -3.48145
> >>>
> >>>0.00360089  0.0123509      0.999917         2.08022
> >>>
> >>>0                   0                     0                      1
> >>>
> >>>This result is wrong, isn't it?  Does the registration program scale
the
> >>>images before aligning them?  What's going on?
> >>>
> >>>Thanx!
> >>>
> >>>Grace
> >>>
> >>>
> >>>
> >>>
>
>>>------------------------------------------------------------------------
> >>>
> >>>_______________________________________________
> >>>Insight-users mailing list
> >>>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
> >
> >
>
> _______________________________________________
> 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