Hi,
I suggest you look at:
http://www.fmrib.ox.ac.uk/fsl/avwutils/index.html
and specifically the "Orientation-related Utilities".
This explains the relationship between FSLView
display and orientation information in the NIfTI
file. It also explains how to use the new tool
"fslreorient2std" which is a much easier tool and
I believe is just what you need.
All the best,
Mark
On 28 Sep 2010, at 09:00, Linev FSL wrote:
> --00151750d89c2434e604915245ce
> Content-Type: text/plain; charset=ISO-8859-1
> Content-Transfer-Encoding: quoted-printable
>
> Hi,
>
> thank you for your quick reply!
>
> Sorry, my explanations were a bit confusing.
> While looking at the display in FSLview the brain was displayed in a
> strang=
> e
> way. The labels (RL, AP and IS) were correctly placed around the
> brain but
> the sagittal view was displayed at the bottom left of the window
> (z), the
> coronal view at the top right (x) and the axial view at the top left
> (y).
>
> If I use this file to do a registration to a standard space, the
> registration does not work properly. That is why I thought using
> fslswapdim
> on the file I have.
> I looked at #7 in the FSL FAQ you mentioned. It is not completely
> clear in
> my head how I should use fslorient on my data.
>
> While looking at the header of my original file that comes out from
> dcm2nii
> I have:
> qform_name Unknown
> qform_code 0
> qto_xyz:1 1.000000 0.000000 0.000000 0.000000
> qto_xyz:2 0.000000 1.000000 0.000000 0.000000
> qto_xyz:3 0.000000 0.000000 1.000000 0.000000
> qto_xyz:4 0.000000 0.000000 0.000000 1.000000
> qform_xorient Left-to-Right
> qform_yorient Posterior-to-Anterior
> qform_zorient Inferior-to-Superior
> sform_name Scanner Anat
> sform_code 1
> sto_xyz:1 0.000000 0.000000 1.000000 -88.105324
> sto_xyz:2 -1.000000 0.000000 0.000000 138.895889
> sto_xyz:3 0.000000 1.000000 0.000000 -131.237289
> sto_xyz:4 0.000000 0.000000 0.000000 1.000000
> sform_xorient Anterior-to-Posterior
> sform_yorient Inferior-to-Superior
> sform_zorient Left-to-Right
>
> Then, I apply fslswapdim original_file -z -x y new_file
>
> If I look at the header info of the new file I have
> qform_name Scanner Anat
> qform_code 1
> qto_xyz:1 -1.000000 0.000000 -0.000000 86.894676
> qto_xyz:2 0.000000 1.000000 -0.000000 -116.104111
> qto_xyz:3 0.000000 0.000000 1.000000 -131.237289
> qto_xyz:4 0.000000 0.000000 0.000000 1.000000
> qform_xorient Right-to-Left
> qform_yorient Posterior-to-Anterior
> qform_zorient Inferior-to-Superior
> sform_name Scanner Anat
> sform_code 1
> sto_xyz:1 -1.000000 0.000000 0.000000 86.894676
> sto_xyz:2 0.000000 1.000000 0.000000 -116.104111
> sto_xyz:3 0.000000 0.000000 1.000000 -131.237289
> sto_xyz:4 0.000000 0.000000 0.000000 1.000000
> sform_xorient Right-to-Left
> sform_yorient Posterior-to-Anterior
> sform_zorient Inferior-to-Superior
>
> How should I apply fslorient on my new file to make sure the header
> info ar=
> e
> appropriate? Should I copy the sform of the original file (since the
> qform
> is unknown)? If yes, how should I copy it?
>
> Thank you!
> Best,
>
> C=E9cile
>
>
>
> On Mon, Sep 27, 2010 at 11:13 PM, Michael Harms <[log in to unmask]
> >wro=
> te:
>
>> What do you mean by "not well oriented while looking at them in
>> fslview"?
>> Is the brain just sideways or upside-down in the display, or are the
>> orientation labels shown within fslview actually in the wrong
>> position?
>>
>> You might want to read #7 in the FSL FAQ, which makes clear that
>> using
>> fslswapdim in the fashion that you appear to be doing (i.e., without
>> fslorient) will mess up the orientation if you are starting with a
>> valid
>> nifti file (i.e., one in the which the R/L, A/P, and S/I labels
>> show up i=
> n
>> the proper locations within fslview).
>>
>> Best,
>> -MH
>>
>>
>>> Hi,
>>>
>>> I am using feat to run analyses on fMRI data that were acquired
>> sagittally
>>> (anatomical and EPI runs).
>>>
>>> Because of the direction of the acquisitions, the nifti files
>>> created
>> from
>>> the dicom with dcm2nii were not well oriented while looking at
>>> them in
>>> fslview and the registration step did not work properly
>>> (everything was
>>> flipped 180=B0. The frontal lobe of the example_function was in the
>>> occipital
>>> of the standard images etc...).
>>>
>>> I then decided to re-orient the nifti files using:
>>> fslswapdim input.nii.gz -z -x y output.nii.gz
>>> But in doing this I am afraid it might be problematic for the slice
>> timing
>>> correction step. Am I right? How does feat determine the slice
>>> order an=
> d
>>> the
>>> direction of slice acquisition?
>>>
>>> So as an other solution I kept the run and anatomical we acquired
>>> in th=
> e
>>> "wrong orientation" and created an icbm152 template (using
>>> fslswapdim -=
> y
>> z
>>> -x) with the same orientation as our acquisitions. This way, the
>>> registration seems to work properly and I could run a group
>>> analysis.
>>> My only concern is about the coordinates of my images. Does
>>> fslswapdim
>>> affect the coordinates of the volume acquired? Are the coordinates
>>> of t=
> he
>>> cluster list still accurate (as I used a template with different
>>> orientations)?
>>> If I reorient my final group statistic maps in the "right"
>>> orientation
>>> using
>>> once again fslswapdim (-z -x y), can I use the Atlas tools without
>>> havi=
> ng
>>> to
>>> worry about the coordinates?
>>>
>>> I went through a lot of anterior posts in the FSL archives. That
>>> is how=
> I
>>> discovered fslswapdim (thank you for those very useful posts!). I
>>> did n=
> ot
>>> find any post regarding analysis of data acquired sagittally though
>> (maybe
>>> I
>>> did not use the right keywords...).
>>> Any help and suggestions will be very welcome.
>>>
>>> Thanks in advance!
>>> Best,
>>>
>>> C=E9cile Madjar
>>>
>>
>
> --00151750d89c2434e604915245ce
> Content-Type: text/html; charset=ISO-8859-1
> Content-Transfer-Encoding: quoted-printable
>
> Hi,<br><br>thank you for your quick reply!<br><br>Sorry, my
> explanations we=
> re a bit confusing. <br>While looking at the display in FSLview the
> brain w=
> as displayed in a strange way. The labels (RL, AP and IS) were
> correctly pl=
> aced around the brain but the sagittal view was displayed at the
> bottom lef=
> t of the window (z), the coronal view at the top right (x) and the
> axial vi=
> ew at the top left (y). <br>
> <br>If I use this file to do a registration to a standard space, the
> regist=
> ration does not work properly. That is why I thought using
> fslswapdim on th=
> e file I have.<br>I looked at #7 in the FSL FAQ you mentioned. It is
> not co=
> mpletely clear in my head how I should use fslorient on my data.<br>
> <br>While looking at the header of my original file that comes out
> from dcm=
> 2nii I have:<br>qform_name=A0=A0=A0=A0
> Unknown<br>qform_code=A0=A0=A0=A0 0<=
> br>qto_xyz:1=A0=A0=A0=A0=A0 1.000000=A0 0.000000=A0 0.000000=A0
> 0.000000<br=
>> qto_xyz:2=A0=A0=A0=A0=A0 0.000000=A0 1.000000=A0 0.000000=A0
>> 0.000000<br>
> qto_xyz:3=A0=A0=A0=A0=A0 0.000000=A0 0.000000=A0 1.000000=A0
> 0.000000<br>qt=
> o_xyz:4=A0=A0=A0=A0=A0 0.000000=A0 0.000000=A0 0.000000=A0
> 1.000000<br>qfor=
> m_xorient=A0 Left-to-Right<br>qform_yorient=A0 Posterior-to-
> Anterior<br>qfo=
> rm_zorient=A0 Inferior-to-Superior<br>
> sform_name=A0=A0=A0=A0 Scanner Anat<br>sform_code=A0=A0=A0=A0
> 1<br>sto_xyz:=
> 1=A0=A0=A0=A0=A0 0.000000=A0 0.000000=A0 1.000000=A0
> -88.105324<br>sto_xyz:=
> 2=A0=A0=A0=A0=A0 -1.000000=A0 0.000000=A0 0.000000=A0
> 138.895889<br>sto_xyz=
> :3=A0=A0=A0=A0=A0 0.000000=A0 1.000000=A0 0.000000=A0 -131.237289<br>
> sto_xyz:4=A0=A0=A0=A0=A0 0.000000=A0 0.000000=A0 0.000000=A0
> 1.000000<br>sf=
> orm_xorient=A0 Anterior-to-Posterior<br>sform_yorient=A0 Inferior-to-
> Superi=
> or<br>sform_zorient=A0 Left-to-Right<br><br>Then, I apply fslswapdim
> origin=
> al_file -z -x y new_file<br>
> <br>If I look at the header info of the new file I have
> <br>qform_name=A0=
> =A0=A0=A0 Scanner Anat<br>qform_code=A0=A0=A0=A0 1<br>qto_xyz:
> 1=A0=A0=A0=A0=
> =A0 -1.000000=A0 0.000000=A0 -0.000000=A0 86.894676<br>qto_xyz:
> 2=A0=A0=A0=
> =A0=A0 0.000000=A0 1.000000=A0 -0.000000=A0 -116.104111<br>
> qto_xyz:3=A0=A0=A0=A0=A0 0.000000=A0 0.000000=A0 1.000000=A0
> -131.237289<br=
>> qto_xyz:4=A0=A0=A0=A0=A0 0.000000=A0 0.000000=A0 0.000000=A0
>> 1.000000<br>q=
> form_xorient=A0 Right-to-Left<br>qform_yorient=A0 Posterior-to-
> Anterior<br>=
> qform_zorient=A0 Inferior-to-Superior<br>
> sform_name=A0=A0=A0=A0 Scanner Anat<br>sform_code=A0=A0=A0=A0
> 1<br>sto_xyz:=
> 1=A0=A0=A0=A0=A0 -1.000000=A0 0.000000=A0 0.000000=A0
> 86.894676<br>sto_xyz:=
> 2=A0=A0=A0=A0=A0 0.000000=A0 1.000000=A0 0.000000=A0
> -116.104111<br>sto_xyz=
> :3=A0=A0=A0=A0=A0 0.000000=A0 0.000000=A0 1.000000=A0 -131.237289<br>
> sto_xyz:4=A0=A0=A0=A0=A0 0.000000=A0 0.000000=A0 0.000000=A0
> 1.000000<br>sf=
> orm_xorient=A0 Right-to-Left<br>sform_yorient=A0 Posterior-to-
> Anterior<br>s=
> form_zorient=A0 Inferior-to-Superior<br><br>How should I apply
> fslorient on=
> my new file to make sure the header info are appropriate? Should I
> copy th=
> e sform of the original file (since the qform is unknown)? If yes,
> how shou=
> ld I copy it?<br>
> <br>Thank you!<br>Best,<br><br>C=E9cile<br><br><br><br><div
> class=3D"gmail_=
> quote">On Mon, Sep 27, 2010 at 11:13 PM, Michael Harms <span
> dir=3D"ltr">&l=
> t;<a href=3D"mailto:[log in to unmask]">[log in to unmask]</
> a>><=
> /span> wrote:<br>
> <blockquote class=3D"gmail_quote" style=3D"margin: 0pt 0pt 0pt
> 0.8ex; borde=
> r-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">What do
> you mean =
> by "not well oriented while looking at them in fslview"?<br>
> Is the brain just sideways or upside-down in the display, or are
> the<br>
> orientation labels shown within fslview actually in the wrong
> position?<br>
> <br>
> You might want to read #7 in the FSL FAQ, which makes clear that
> using<br>
> fslswapdim in the fashion that you appear to be doing (i.e.,
> without<br>
> fslorient) will mess up the orientation if you are starting with a
> valid<br=
>>
> nifti file (i.e., one in the which the R/L, A/P, and S/I labels show
> up in<=
> br>
> the proper locations within fslview).<br>
> <br>
> Best,<br>
> <font color=3D"#888888">-MH<br>
> </font><div><div></div><div class=3D"h5"><br>
> <br>
> > Hi,<br>
> ><br>
> > I am using feat to run analyses on fMRI data that were acquired
> sagitt=
> ally<br>
> > (anatomical and EPI runs).<br>
> ><br>
> > Because of the direction of the acquisitions, the nifti files
> created =
> from<br>
> > the dicom with dcm2nii were not well oriented while looking at
> them in=
> <br>
> > fslview and the registration step did not work properly
> (everything wa=
> s<br>
> > flipped 180=B0. The frontal lobe of the example_function was in
> the<br=
>>
> > occipital<br>
> > of the standard images etc...).<br>
> ><br>
> > I then decided to re-orient the nifti files using:<br>
> > fslswapdim input.nii.gz -z -x y output.nii.gz<br>
> > But in doing this I am afraid it might be problematic for the
> slice ti=
> ming<br>
> > correction step. Am I right? How does feat determine the slice
> order a=
> nd<br>
> > the<br>
> > direction of slice acquisition?<br>
> ><br>
> > So as an other solution I kept the run and anatomical we
> acquired in t=
> he<br>
> > "wrong orientation" and created an icbm152 template
> (using f=
> slswapdim -y z<br>
> > -x) with the same orientation as our acquisitions. This way,
> the<br>
> > registration seems to work properly and I could run a group
> analysis.<=
> br>
> > My only concern is about the coordinates of my images. Does
> fslswapdim=
> <br>
> > affect the coordinates of the volume acquired? Are the
> coordinates of =
> the<br>
> > cluster list still accurate (as I used a template with
> different<br>
> > orientations)?<br>
> > If I reorient my final group statistic maps in the
> "right" o=
> rientation<br>
> > using<br>
> > once again fslswapdim (-z -x y), can I use the Atlas tools
> without hav=
> ing<br>
> > to<br>
> > worry about the coordinates?<br>
> ><br>
> > I went through a lot of anterior posts in the FSL archives.
> That is ho=
> w I<br>
> > discovered fslswapdim (thank you for those very useful posts!).
> I did =
> not<br>
> > find any post regarding analysis of data acquired sagittally
> though (m=
> aybe<br>
> > I<br>
> > did not use the right keywords...).<br>
> > Any help and suggestions will be very welcome.<br>
> ><br>
> > Thanks in advance!<br>
> > Best,<br>
> ><br>
> > C=E9cile Madjar<br>
> ><br>
> </div></div></blockquote></div><br>
>
> --00151750d89c2434e604915245ce--
>
|