> I seem to have a problem using the deformation toolbox with SPM5b, which
> used to work fine with SPM2.
The spm_Deformations.m and spm_write_defs.m code are a bit old, and I hadn't
got around to removing them from the SPM5b before its release.
> The normalization was performed in SPM5b.
If you want to invert a deformation field, then you could use the segment
button of SPM5b, which will write out sets of both forward and inverse
spatial normalisation parameters. Spatial normalisation parameters estimated
by the Segment button should also be more accurate.
> Is there a new version for the defomration tool box?
The TASKS->Util->Deformations option (from a pulldown in the Graphics window)
is now the official way of doing such things. Are you trying to write out an
inverse deformation field? If so, then you need to get the job structure in
the following form:
-Deformations
. -Composition
. . -Inverse
. . . -Composition
. . . . -Imported _sn.mat
. . . . . Parameter File
. . . . . Voxel Sizes
. . . . . Bounding Box
. . . Image to base inverse on
. Save as
. Apply to
> Can I use the normalization by SPM5b and deformation by SPM2?
This should also work as the format of the sn.mat file hasn't really changed
(apart from a bit of additional segmentation-related information being
incorporated into the *_seg_sn.mat and *_seg_inv_sn.mat files.
>
> The error is as follows:
>
> %-------------------------
> ??? Error using ==> spm_create_vol>create_vol
> "dim" field is the wrong size (1 4).
>
> Error in ==> spm_create_vol at 16
> v = create_vol(V(i));
>
> Error in ==> spm_sn2def>spm_write_defs at 486
> VX = spm_create_vol(VX);
>
> Error in ==> spm_sn2def at 134
> spm_write_defs(sn(i),defs.vox,defs.bb);
>
> ??? Error while evaluating uimenu Callback.
The error is because the structure returned by spm_vol has now changed.
Datatypes and information about byte-order are now stored in a different
field, rather than being tagged on to the dim field. spm_sn2def.m hasn't
been modified to accomodate this (as it will eventually be removed from the
spm5 distribution).
Best regards,
-John
|