Dear David,
There are two important things to point out here.
The first is that for 2D registration FLIRT only works with "axial"
slices (dim3=1, dim1 and dim2 > 1). So that means that it will
not work with your "coronal" slices. You could change this with
fslswapdim if you wanted to.
The second is that even if they were axial slices then you
still need to specify an appropriate schedule file for the
transformation. The -2D option simply says that the input
images are 2D (which affects the internal interpolation)
but does not specify what kind of transformation you want.
You would need to pick from the files in $FSLDIR/etc/flirtsch
such as sch2D_3dof, sch2D_4dof, ... sch2D_6dof.
The datatype is completely unimportant.
All the best,
Mark
On 14 Aug 2010, at 02:19, David Gutman wrote:
> I am playing around with some data and am trying to do a 2-D rigid
> body registration of consecutive slices... and I could have sworn
> I've done this in the past and it worked... anyways it seems like
> every time I run this command it basically just outputs the original
> "input" file un-registered and runs EXTREMELY quickly... so it seems
> like it's not even trying to do any math... and then outputs the
> identity matrix (Which makes sense if it's outputting the original
> image)....
>
> Has any thing in the schedule used for 3-DOF registration somehow
> changed (or broken?) so this no longer works properly? I played
> around with changing the data type of my input images to float32
> from uint8, and also played around with setting some upper threshold/
> etc... and keep getting the same result.... so just wanted to get
> some advice from the FSL guru's and see if there's something obvious
> I am doing wrong...
>
>
> flirt -in slice80.nii.gz -ref slice79.nii.gz -out
> test_2D_reg.nii.gz -2D
>
>
>
> Final result:
> 1.000000 0.000000 0.000000 0.000000
> 0.000000 1.000000 0.000000 0.000000
> 0.000000 0.000000 1.000000 0.000000
> 0.000000 0.000000 0.000000 1.000000
>
>
>
> fslinfo slice79.nii.gz
> data_type FLOAT32
> dim1 256
> dim2 1
> dim3 158
> dim4 1
> datatype 16
> pixdim1 1.0000000000
> pixdim2 1.0000000000
> pixdim3 1.0000000000
> pixdim4 1.0000000000
> cal_max 0.0000
> cal_min 0.0000
> file_type NIFTI-1+
>
> fslinfo slice80.nii.gz
> data_type FLOAT32
> dim1 256
> dim2 1
> dim3 158
> dim4 1
> datatype 16
> pixdim1 1.0000000000
> pixdim2 1.0000000000
> pixdim3 1.0000000000
> pixdim4 1.0000000000
> cal_max 0.0000
> cal_min 0.0000
> file_type NIFTI-1+
>
>
>
> --
> David A Gutman, M.D. Ph.D.
> Center for Comprehensive Informatics
> Emory University School of Medicine
|