Hello, Freesurfer group, I registered the example_func.nii.gz to brain.mgz in tkregister2 using FS/anat2exf.register.dat, and --fslregout fsl.feat/reg/example_func2highres.mat. I have a couple of questions.
1) could anybody confirm that using--fslregout does apply .mat file for registration based on the following information on the screen? surfname set to orig target volume PT01/mri/brain.mgz movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat LoadVol 1 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 ---- Input registration matrix -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; float2int = 0 --------------------------------------- INFO: loading target PT01/mri/brain.mgz INFO: changing target type to float Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 ---- Input registration matrix -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; subject = PT01 Reading lh surface orig Done reading surface Reading rh surface orig Done reading surface Zoom Factor = 2 FOV = 256 Opening window PT01 NVIDIA: could not open the device file /dev/nvidiactl (Permission denied). NVIDIA: Direct rendering failed; attempting indirect rendering. Setting scale Tagging mov volume tkregister2: interface: /net/dysthymia/freesurfer/lib/tcl/tkregister2.tcl tkregister.tcl: startup done tkregister.tcl: default macro interface (to change: macro,mini,micro) tkregister.tcl: or: setenv tkregisterinterface {macro,mini,micro} %
2) The results are quite the same (and good) in the tkregister2 with a slightly difference as shown below. Could anyone please tell me what these numbers mean?
with .bat file Screen: 256 257 (113,113,113), inorm = 1, mov_frame = 0 Anat: (128 126 127) ( 0.0 -1.0 2.0) 25.0000 32.7 Func: ( 31 32 21) ( 4.2 3.1 1.4) 756.0000 112.5
with .mat file Screen: 257 257 (175,175,175), inorm = 1, mov_frame = 0 Anat: (128 126 127) ( 0.0 -1.0 2.0) 25.0000 28.3 Func: ( 31 32 21) ( 4.2 3.1 1.4) 756.0000 106.2
Thanks,
Xin
-----Original Message----- From: Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] Sent: Mon 1/12/2009 4:02 PM To: Wang, Xin Cc: analysis-bugs@nmr.mgh.harvard.edu Subject: Re: [Freesurfer] reg-feat2anat failed
reg-feat2anat calls fslregister, so they should produce the same result. There is no need for an "intermediate" volume since you are registering from the subject's EPI to the subject's structure. Does the registration not look good?
Wang, Xin wrote:
Thank you, Dr. Greve. It seems work ok. what is the difference between reg-feat2anat and fslregister? although both commands are working for me, I don't think either of them serve my propose. Freesurfer does not use initial_highres to improve the reg of example_func to highres, but FSL/FEAT uses this inter-mediate step. I try to use registration.mat files of FSL/FEAT step-wise registrations to improve the reg. I think flag --fsl allow me to use a fsl.mat file as reg file. How to make it work in the way I need?
Thank you again,
Xin
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 3:29 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
when you say everything looked ok, do you mean that the orientation was correct? If so, try running this:
fslregister --s subject --mov example_func.nii.gz --reg newreg.dat
then
tkregister2 --mov example_func.nii.gz --reg newreg.dat --surfs
Wang, Xin wrote:
Sorry, Dr. Greve. I copied addtional parts after I killed the tkmedit. The following is on the screen when I saw the image.
[]$ tkmedit -f Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Reading /net/dysthymia/freesurfer/lib/tcl/tkm_common.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkm_wrappers.tcl Reading /net/dysthymia/freesurfer/lib/tcl/fsgdfPlot.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkUtils.tcl %
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 3:10 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
I don't understand. If it segfaulted how did you look at the images?
Wang, Xin wrote:
Thank you, Dr. Greve. This time tkmedit read the image, and the image looks ok to me. But following information appeared.
[]$ tkmedit -f Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Reading /net/dysthymia/freesurfer/lib/tcl/tkm_common.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkm_wrappers.tcl Reading /net/dysthymia/freesurfer/lib/tcl/fsgdfPlot.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkUtils.tcl % Killed
=================================== ERROR: A segfault has occurred. This is not your fault, : but is most likely an unrecoverable error and has : made the program unstable. : : Please send the contents of the file .xdebug_tkmedit : that should be in this directory to analysis-bugs@nmr.mgh.harvard.edu mailto:analysis-bugs@nmr.mgh.harvard.edu : : Now exiting... : []$ cat .xdebug_tkmedit tkmedit started: Mon Jan 12 15:14:52 2009 tkmedit.bin -f Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz $Id: tkmedit.c,v 1.320.2.5 2008/03/10 14:02:35 nicks Exp $ $Name: stable4 $ Set user home dir to /net/data4/CCMB08/PTSD/Thickness Set subject home dir to Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Using interface file /net/dysthymia/freesurfer/lib/tcl/tkmedit.tcl Tcl: Successfully parsed tkmedit.tcl Tcl: Successfully parsed tkm_functional.tcl Segfault Entering main loop xDebug stack (length: 2) 01: main() 01: Entering main loop 00: 00:
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 2:55 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
what is your tkmedit cmd?
It should be
tkmedit -f example_func.nii.gz
Wang, Xin wrote:
Hello, Dr. Greve, tkmedit can not open the example_func.nii.gzI attached the header of example_func.nii.gz (after mri_convert), and the contents of .xdebug_tkmedit file
[]$ fslhd
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
filename Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz sizeof_hdr 348 data_type FLOAT32 dim0 3 dim1 64 dim2 64 dim3 40 dim4 1 dim5 1 dim6 1 dim7 1 vox_units mm time_units s datatype 16 nbyper 4 bitpix 32 pixdim0 0.0000000000 pixdim1 3.4375000000 pixdim2 3.4375000000 pixdim3 3.0000000000 pixdim4 1.0000000000 pixdim5 1.0000000000 pixdim6 1.0000000000 pixdim7 1.0000000000 vox_offset 352 cal_max 0.0000 cal_min 0.0000 scl_slope 0.000000 scl_inter 0.000000 phase_dim 0 freq_dim 0 slice_dim 0 slice_name Unknown slice_code 0 slice_start 0 slice_end 0 slice_duration 0.000000 time_offset 0.000000 intent Unknown intent_code 0 intent_name intent_p1 0.000000 intent_p2 0.000000 intent_p3 0.000000 qform_name Scanner Anat qform_code 1 qto_xyz:1 -3.437500 0.000000 -0.000000 220.000000 qto_xyz:2 0.000000 3.437500 -0.000000 0.000000 qto_xyz:3 0.000000 0.000000 3.000000 0.000000 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 -3.437500 0.000000 0.000000 220.000000 sto_xyz:2 0.000000 3.437500 0.000000 0.000000 sto_xyz:3 0.000000 0.000000 3.000000 0.000000 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 file_type NIFTI-1+ file_code 1 descrip FreeSurfer Jun 14 2008 aux_file .xdebug_tkmedit tkmedit started: Mon Jan 12 15:05:46 2009 tkmedit.bin Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz $Id: tkmedit.c,v 1.320.2.5 2008/03/10 14:02:35 nicks Exp $ $Name: stable4 $ Set user home dir to /net/data4/CCMB08/PTSD/Thickness ERROR: Parsing arguments Subject and image not declared Fatal error in parsing command line args. Segfault Copying argv[1] xDebug stack (length: 3) 02: ParseCmdLineArgs( argc=2, argv=tkmedit.bin ) 02: Copying argv[1] 01: main() 01: Parsing command line arguments 00: 00:
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 2:38 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
If the orientation of the example func in tkmedit is wrong, then the reg-feat2anat is destined to fail. tkmedit (usually) reads the nifti header correctly. How do you know the header is right?
Wang, Xin wrote:
My problem about tkregister2 is that the flag -fsl example_func2highres.mat does not work properly. The tkregister2 catastrophically failed to register two brains. I submit the bugreport of tkregister2 (please see the COMMAND
3). The
two early steps (mri_convert and reg-feat2anat) are included for
your
references.
Thanks,
Xin
FREESURFER_HOME: /net/dysthymia/freesurfer
Build stamp: freesurfer-Linux-centos4_x86_64-stable-pub-v4.0.5
RedHat release: Red Hat Enterprise Linux Client release 5.2
(Tikanga)
Kernel info: Linux 2.6.18-92.1.1.el5 x86_64
Subject name: PT01
COMMAND 1: []$ mri_convert Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz mri_convert Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz $Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ reading from Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz... TR=1000.00, TE=0.00, TI=0.00, flip angle=0.00 i_ras = (-1, 0, 0) j_ras = (0, 1, 0) k_ras = (0, 0, 1) writing to Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz...
COMMAND 2: []$ reg-feat2anat --feat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat
--subject PT01 FeatDir is Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat template volume is Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz log file is
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/reg-feat2anat.log
Mon Jan 12 14:08:56 CST 2009 /net/data4/CCMB08/PTSD/Thickness /net/dysthymia/freesurfer/bin/reg-feat2anat --feat Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat --subject PT01 Linux schizo.psych.med.umich.edu 2.6.18-92.1.1.el5 #1 SMP Thu
May 22
09:01:47 EDT 2008 x86_64 x86_64 x86_64 GNU/Linux example_func ras_good_flag 1
Initializing exf2anat with header tkregister2_cmdl --targ /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.init
--fslregout
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
--regheader --noedit target volume
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.init
LoadVol 0 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 1, float2int = 0 Computing reg from header (and possibly input matrix) ---- Input registration matrix (computed) -------- 1.000 0.000 0.000 -110.507; 0.000 0.000 1.000 -41.354; 0.000 -1.000 0.000 93.531; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 1.000 0.000 0.000 -110.507; 0.000 0.000 1.000 -41.354; 0.000 -1.000 0.000 93.531; 0.000 0.000 0.000 1.000; subject = subject-unknown RegMat --------------------------- 1.000 0.000 0.000 -110.507; 0.000 0.000 1.000 -41.354; 0.000 -1.000 0.000 93.531; 0.000 0.000 0.000 1.000; register: file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.init
written FSLOUTPUTTYPE NIFTI_GZ tkreg2FSL: mov det = -35.4492, ref det = -1 fslregister --s PT01 --reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--mov
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--dof 6 --bins 256 --cost corratio --fslmat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--fsvol brainmask --maxangle 90 --initfslmat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
--tmp
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp
--out
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
Log file is
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.fslregister.log
Mon Jan 12 14:08:56 CST 2009 --s PT01 --reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--mov
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--dof 6 --bins 256 --cost corratio --fslmat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--fsvol brainmask --maxangle 90 --initfslmat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
--tmp
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp
--out
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
$Id: fslregister,v 1.16 2007/07/26 16:52:54 greve Exp $ schizo.psych.med.umich.edu Linux schizo.psych.med.umich.edu 2.6.18-92.1.1.el5 #1 SMP Thu
May 22
09:01:47 EDT 2008 x86_64 x86_64 x86_64 GNU/Linux
/net/data4/CCMB08/PTSD/Thickness mri_convert
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii
mri_convert
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii
$Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ reading from
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz...
TR=12.27, TE=5.21, TI=650.00, flip angle=9.00 i_ras = (-1, 0, 0) j_ras = (0, 0, -1) k_ras = (0, 1, 0) writing to
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii...
/net/data4/CCMB08/PTSD/Thickness mri_convert Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
--frame 0 mri_convert Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
--frame 0 $Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ reading from Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz... TR=1000.00, TE=0.00, TI=0.00, flip angle=0.00 i_ras = (-1, 0, 0) j_ras = (0, 1, 0) k_ras = (0, 0, 1) keeping frame 0 writing to
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii...
Mon Jan 12 14:09:00 CST 2009 /net/data4/CCMB08/PTSD/Thickness bet
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
-f 0.1 Mon Jan 12 14:09:04 CST 2009 /net/data4/CCMB08/PTSD/Thickness flirt -ref
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii
-in
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
-omat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
-cost corratio -dof 6 -searchrx -90 90 -searchry -90 90
-searchrz -90
90 -init
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
-o
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii
Mon Jan 12 14:09:20 CST 2009 /net/data4/CCMB08/PTSD/Thickness mri_convert
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
mri_convert
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
$Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ reading from
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii...
TR=1000.00, TE=0.00, TI=0.00, flip angle=0.00 i_ras = (-1, 0, 0) j_ras = (0, 0, -1) k_ras = (0, 1, 0) writing to
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz...
tkregister2_cmdl --s PT01 --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--noedit ---- FSL registration matrix -------- 0.995 -0.035 0.091 20.763; 0.093 0.066 -0.994 171.738; 0.028 0.997 0.069 11.368; 0.000 0.000 0.000 1.000;
INFO: no target volume specified, assuming FreeSurfer orig volume. target volume orig movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
LoadVol 0 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/orig.mgz
Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 FSLOUTPUTTYPE NIFTI fsl2TkReg: mov det = -35.4492, ref det = -1 ---- Input registration matrix (computed) -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; subject = PT01 RegMat --------------------------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; register: file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
written (standard_in) 1: illegal character: P (standard_in) 1: illegal character: T
Started at Mon Jan 12 14:08:57 CST 2009 Ended at Mon Jan 12 14:09:24 CST 2009
fslregister Done
To check results, run: tkregister2 --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--surf orig
tkregister2_cmdl --targ /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz --fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/example_func2standard.mat
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2exf.register.dat
--noedit ---- FSL registration matrix -------- 1.122 0.029 0.006 -34.123; -0.061 1.041 0.128 -3.403; -0.010 -0.119 1.224 25.844; 0.000 0.000 0.000 1.000;
target volume /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2exf.register.dat
LoadVol 0 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target
/net/misc/fsl/etc/standard/avg152T1_brain.nii.gz
INFO: target does not conform to COR format, so I'm going to reslice to COR. This will not affect the final registration. Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 FSLOUTPUTTYPE NIFTI_GZ fsl2TkReg: mov det = -35.4492, ref det = -8 ---- Input registration matrix (computed) -------- 0.890 0.025 0.002 1.505; -0.013 0.092 0.807 4.483; 0.051 -0.947 0.099 3.604; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 0.890 0.025 0.002 1.505; -0.013 0.092 0.807 4.483; 0.051 -0.947 0.099 3.604; 0.000 0.000 0.000 1.000; subject = subject-unknown RegMat --------------------------- 0.890 0.002 -0.025 1.505; -0.013 0.807 -0.092 4.483; 0.051 0.099 0.947 3.604; 0.000 0.000 0.000 1.000; register: file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2exf.register.dat
written mri_matrix_multiply -fsl -im
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
-iim
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/example_func2standard.mat
-om
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2anat.fsl.mat
tkregister2_cmdl --s PT01 --targ /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz --mov /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz --reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2std.register.dat
--fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2anat.fsl.mat
--noedit ---- FSL registration matrix -------- 0.885 -0.049 0.075 48.869; 0.074 -0.031 -0.809 195.041; 0.077 0.950 -0.044 18.348; 0.000 0.000 0.000 1.000;
target volume
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
movable volume /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2std.register.dat
LoadVol 0 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable
/net/misc/fsl/etc/standard/avg152T1_brain.nii.gz
Tmov: -------------------- -2.000 0.000 0.000 91.000; 0.000 0.000 2.000 -91.000; 0.000 -2.000 0.000 109.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 FSLOUTPUTTYPE NIFTI_GZ fsl2TkReg: mov det = -8, ref det = -1 ---- Input registration matrix (computed) -------- 1.116 -0.061 0.100 2.757; -0.105 -0.035 1.225 -4.398; -0.085 -1.046 -0.064 -3.213; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 1.116 -0.061 0.100 2.757; -0.105 -0.035 1.225 -4.398; -0.085 -1.046 -0.064 -3.213; 0.000 0.000 0.000 1.000; subject = PT01 RegMat --------------------------- 1.116 -0.061 0.100 2.757; -0.105 -0.035 1.225 -4.398; -0.085 -1.046 -0.064 -3.213; 0.000 0.000 0.000 1.000; register: file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2std.register.dat
written
To visually check your results, run: tkregister2_cmdl --s PT01 --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--surf orig --tag
Mon Jan 12 14:09:25 CST 2009 reg-feat2anat done
COMMAND 3: []$ tkregister2 --s PT01 --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
call/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--surf orig --tag --fsl
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/example_func2highres.mat
---- FSL registration matrix -------- 0.995 -0.035 0.091 20.763; 0.093 0.066 -0.994 171.738; 0.028 0.997 0.069 11.368; 0.000 0.000 0.000 1.000;
surfname set to orig ---- FSL registration matrix -------- 1.043 -0.038 0.042 18.354; 0.020 1.036 0.060 9.413; -0.046 -0.068 1.128 70.358; 0.000 0.000 0.000 1.000;
INFO: no target volume specified, assuming FreeSurfer orig volume. target volume orig movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
LoadVol 1 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/orig.mgz
INFO: changing target type to float Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 FSLOUTPUTTYPE NIFTI_GZ fsl2TkReg: mov det = -35.4492, ref det = -1 ---- Input registration matrix (computed) -------- 0.956 0.037 0.032 3.452; -0.038 0.882 -0.059 1.969; -0.021 0.050 0.961 1.159; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 0.956 0.037 0.032 3.452; -0.038 0.882 -0.059 1.969; -0.021 0.050 0.961 1.159; 0.000 0.000 0.000 1.000; subject = PT01 Reading lh surface orig Done reading surface Reading rh surface orig Done reading surface Zoom Factor = 2 FOV = 256 Opening window PT01 Setting scale Tagging mov volume tkregister2: interface:
/net/dysthymia/freesurfer/lib/tcl/tkregister2.tcl
tkregister.tcl: startup done tkregister.tcl: default macro interface (to change:
macro,mini,micro)
tkregister.tcl: or: setenv tkregisterinterface {macro,mini,micro} %
-----Original Message----- From: Doug Greve [mailto:greve@nmr.mgh.harvard.edu] Sent: Tue 1/6/2009 12:30 PM To: Wang, Xin Cc: freesurfer Subject: Re: [Freesurfer] reg-feat2anat failed
Hi Xin, I'm not sure what's going wrong here, I think I need more
info.
Can you follow the steps in surfer.nmr.mgh.harvard.edu/fswiki/BugReporting?
doug
Wang, Xin wrote:
hello, Freesurfer group,
I try to use registration.mat files of FSL/FEAT routines,
instead of
anat2example_func.bat, to register the orig.mgz and example_func.nii.gz with the thinking that using
initial_highres in
FEAT may improve the reg. However, tkregister2 catastrophically
failed
to register two brains when I use --fsl flag. Modifying
header of
example_func with mri_convert does not solve the problem. I will appreciate any suggestion on using .mat file for registration.
second question: what is the best registration of
example_func and
orig.mgz? In another word, what should I check besides things
in the
FS tutorial when I check/modify the registration in
tkregister2? Is
there golden reference points I can use?
Thank you in advance for any suggestion.
Xin wang
-----Original Message----- From: Doug Greve [mailto:greve@nmr.mgh.harvard.edu] Sent: Mon 12/15/2008 1:26 PM To: Wang, Xin Cc: freesurfer Subject: Re: [Freesurfer] reg-feat2anat failed
There is a flag in the nifti header saying whether the qform or
sform
are valid, and it looks like your scripts do not set this flag.
You can
use mri_convert (the freesurfer program). This will create valid
files
that can be read into any program.
doug
Wang, Xin wrote:
> Thank you very much for your quick reply, Dr. Greve. I
asked our
> institutional MRI center for correct information on qform and
sform
> since the header of nifti files are created by their scripts.
But I do
> not know what they can do to fix this problem. I will
appreciate if
> you have any further suggestion on how to do the registration
without
> the information on qform and sform in case I can not get them.
Does
> convert to ANALYZE format or manually correct in tkregister2
work?
> > Thank you again, > > Xin > > > -----Original Message----- > From: Doug Greve [mailto:greve@nmr.mgh.harvard.edu] > Sent: Mon 12/15/2008 1:09 PM > To: Wang, Xin > Cc: freesurfer > Subject: Re: [Freesurfer] reg-feat2anat failed > > Hi Xin, the problem is that neither the sform nor the
qform are
valid.
> Did the message below not appear when you ran tkmedit? > > WARNING: neither NIfTI-1 qform or sform are valid > WARNING: your volume will probably be incorrectly oriented > > Fix that, and everything will work fine. > > doug > > > Wang, Xin wrote: > > > Hello, Freesurfer group, > > I am registering the fMRI results to surface using
reg-feat2anat (v
> > 1.26.2.1 2007/08/15) and tkregister2. The automatic
registration
> > catastrophically failed in the subject space, but worked
fine
in the
> > standard space. The orientations of example_func.nii.gz
in the
subject
> > space are flipped in any view. I use the tkmedit to view the > > example_func, and found the orientation is wrong. It seems
Freesurfer
> > can not read nifti header correctly. I attach the
reg-feat2anat log
> > file and an example_func.nii.gz. > > I found the following message from Freesurfer email list. > >
http://www.mail-archive.com/freesurfer@nmr.mgh.harvard.edu/msg05573.html
> > Does Freesurfer have a solution for this type of problems by
now?
> > > > Thank you in advance, > > > > Xin > > >
> > > >_______________________________________________ > >Freesurfer mailing list > >Freesurfer@nmr.mgh.harvard.edu > >https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer > > > > -- > Douglas N. Greve, Ph.D. > MGH-NMR Center > greve@nmr.mgh.harvard.edu > Phone Number: 617-724-2358 > Fax: 617-726-7422 > > In order to help us help you, please follow the steps in: > surfer.nmr.mgh.harvard.edu/fswiki/BugReporting > > >
-- Douglas N. Greve, Ph.D. MGH-NMR Center greve@nmr.mgh.harvard.edu Phone Number: 617-724-2358 Fax: 617-726-7422
In order to help us help you, please follow the steps in: surfer.nmr.mgh.harvard.edu/fswiki/BugReporting
-- Douglas N. Greve, Ph.D. MGH-NMR Center greve@nmr.mgh.harvard.edu Phone Number: 617-724-2358 Fax: 617-726-7422
In order to help us help you, please follow the steps in: surfer.nmr.mgh.harvard.edu/fswiki/BugReporting
what did you use as the highres volume in feat? If you want that reg to work, it has to be a "freesurfer anatomical volume", meaning 256^3, 1mm3
doug
Wang, Xin wrote:
Hello, Freesurfer group, I registered the example_func.nii.gz to brain.mgz in tkregister2 using FS/anat2exf.register.dat, and --fslregout fsl.feat/reg/example_func2highres.mat. I have a couple of questions.
- could anybody confirm that using--fslregout does apply .mat file
for registration based on the following information on the screen? surfname set to orig target volume PT01/mri/brain.mgz movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat LoadVol 1 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 ---- Input registration matrix -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; float2int = 0
INFO: loading target PT01/mri/brain.mgz INFO: changing target type to float Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 ---- Input registration matrix -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; subject = PT01 Reading lh surface orig Done reading surface Reading rh surface orig Done reading surface Zoom Factor = 2 FOV = 256 Opening window PT01 NVIDIA: could not open the device file /dev/nvidiactl (Permission denied). NVIDIA: Direct rendering failed; attempting indirect rendering. Setting scale Tagging mov volume tkregister2: interface: /net/dysthymia/freesurfer/lib/tcl/tkregister2.tcl tkregister.tcl: startup done tkregister.tcl: default macro interface (to change: macro,mini,micro) tkregister.tcl: or: setenv tkregisterinterface {macro,mini,micro} %
- The results are quite the same (and good) in the tkregister2 with a
slightly difference as shown below. Could anyone please tell me what these numbers mean?
with .bat file Screen: 256 257 (113,113,113), inorm = 1, mov_frame = 0 Anat: (128 126 127) ( 0.0 -1.0 2.0) 25.0000 32.7 Func: ( 31 32 21) ( 4.2 3.1 1.4) 756.0000 112.5
with .mat file Screen: 257 257 (175,175,175), inorm = 1, mov_frame = 0 Anat: (128 126 127) ( 0.0 -1.0 2.0) 25.0000 28.3 Func: ( 31 32 21) ( 4.2 3.1 1.4) 756.0000 106.2
Thanks,
Xin
-----Original Message----- From: Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] Sent: Mon 1/12/2009 4:02 PM To: Wang, Xin Cc: analysis-bugs@nmr.mgh.harvard.edu Subject: Re: [Freesurfer] reg-feat2anat failed
reg-feat2anat calls fslregister, so they should produce the same result. There is no need for an "intermediate" volume since you are registering from the subject's EPI to the subject's structure. Does the registration not look good?
Wang, Xin wrote:
Thank you, Dr. Greve. It seems work ok. what is the difference between reg-feat2anat and fslregister? although both commands are working for me, I don't think either of them serve my propose. Freesurfer does not use initial_highres to improve the reg of example_func to highres, but FSL/FEAT uses this inter-mediate step. I try to use registration.mat files of FSL/FEAT step-wise registrations to improve the reg. I think flag --fsl allow me to use a fsl.mat file as reg file. How to make it work in the way I need?
Thank you again,
Xin
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 3:29 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
when you say everything looked ok, do you mean that the orientation was correct? If so, try running this:
fslregister --s subject --mov example_func.nii.gz --reg newreg.dat
then
tkregister2 --mov example_func.nii.gz --reg newreg.dat --surfs
Wang, Xin wrote:
Sorry, Dr. Greve. I copied addtional parts after I killed the tkmedit. The following is on the screen when I saw the image.
[]$ tkmedit -f Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Reading /net/dysthymia/freesurfer/lib/tcl/tkm_common.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkm_wrappers.tcl Reading /net/dysthymia/freesurfer/lib/tcl/fsgdfPlot.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkUtils.tcl %
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 3:10 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
I don't understand. If it segfaulted how did you look at the images?
Wang, Xin wrote:
Thank you, Dr. Greve. This time tkmedit read the image, and the image looks ok to me. But following information appeared.
[]$ tkmedit -f Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Reading /net/dysthymia/freesurfer/lib/tcl/tkm_common.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkm_wrappers.tcl Reading /net/dysthymia/freesurfer/lib/tcl/fsgdfPlot.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkUtils.tcl % Killed
=================================== ERROR: A segfault has occurred. This is not your fault, : but is most likely an unrecoverable error and has : made the program unstable. : : Please send the contents of the file .xdebug_tkmedit : that should be in this directory to analysis-bugs@nmr.mgh.harvard.edu mailto:analysis-bugs@nmr.mgh.harvard.edu : : Now exiting... : []$ cat .xdebug_tkmedit tkmedit started: Mon Jan 12 15:14:52 2009 tkmedit.bin -f Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz $Id: tkmedit.c,v 1.320.2.5 2008/03/10 14:02:35 nicks Exp $ $Name: stable4 $ Set user home dir to /net/data4/CCMB08/PTSD/Thickness Set subject home dir to Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Using interface file /net/dysthymia/freesurfer/lib/tcl/tkmedit.tcl Tcl: Successfully parsed tkmedit.tcl Tcl: Successfully parsed tkm_functional.tcl Segfault Entering main loop xDebug stack (length: 2) 01: main() 01: Entering main loop 00: 00:
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 2:55 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
what is your tkmedit cmd?
It should be
tkmedit -f example_func.nii.gz
Wang, Xin wrote:
Hello, Dr. Greve, tkmedit can not open the example_func.nii.gzI attached the
header of
example_func.nii.gz (after mri_convert), and the contents of .xdebug_tkmedit file
[]$ fslhd
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
filename Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz sizeof_hdr 348 data_type FLOAT32 dim0 3 dim1 64 dim2 64 dim3 40 dim4 1 dim5 1 dim6 1 dim7 1 vox_units mm time_units s datatype 16 nbyper 4 bitpix 32 pixdim0 0.0000000000 pixdim1 3.4375000000 pixdim2 3.4375000000 pixdim3 3.0000000000 pixdim4 1.0000000000 pixdim5 1.0000000000 pixdim6 1.0000000000 pixdim7 1.0000000000 vox_offset 352 cal_max 0.0000 cal_min 0.0000 scl_slope 0.000000 scl_inter 0.000000 phase_dim 0 freq_dim 0 slice_dim 0 slice_name Unknown slice_code 0 slice_start 0 slice_end 0 slice_duration 0.000000 time_offset 0.000000 intent Unknown intent_code 0 intent_name intent_p1 0.000000 intent_p2 0.000000 intent_p3 0.000000 qform_name Scanner Anat qform_code 1 qto_xyz:1 -3.437500 0.000000 -0.000000 220.000000 qto_xyz:2 0.000000 3.437500 -0.000000 0.000000 qto_xyz:3 0.000000 0.000000 3.000000 0.000000 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 -3.437500 0.000000 0.000000 220.000000 sto_xyz:2 0.000000 3.437500 0.000000 0.000000 sto_xyz:3 0.000000 0.000000 3.000000 0.000000 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 file_type NIFTI-1+ file_code 1 descrip FreeSurfer Jun 14 2008 aux_file .xdebug_tkmedit tkmedit started: Mon Jan 12 15:05:46 2009 tkmedit.bin Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz $Id: tkmedit.c,v 1.320.2.5 2008/03/10 14:02:35 nicks Exp $ $Name: stable4 $ Set user home dir to /net/data4/CCMB08/PTSD/Thickness ERROR: Parsing arguments Subject and image not declared Fatal error in parsing command line args. Segfault Copying argv[1] xDebug stack (length: 3) 02: ParseCmdLineArgs( argc=2, argv=tkmedit.bin ) 02: Copying argv[1] 01: main() 01: Parsing command line arguments 00: 00:
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 2:38 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
If the orientation of the example func in tkmedit is wrong,
then the
reg-feat2anat is destined to fail. tkmedit (usually) reads the
nifti
header correctly. How do you know the header is right?
Wang, Xin wrote:
My problem about tkregister2 is that the flag -fsl example_func2highres.mat does not work properly. The tkregister2 catastrophically failed to register two brains. I submit the bugreport of tkregister2 (please see the COMMAND
3). The
two early steps (mri_convert and reg-feat2anat) are included for
your
references.
Thanks,
Xin
FREESURFER_HOME: /net/dysthymia/freesurfer
Build stamp: freesurfer-Linux-centos4_x86_64-stable-pub-v4.0.5
RedHat release: Red Hat Enterprise Linux Client release 5.2
(Tikanga)
Kernel info: Linux 2.6.18-92.1.1.el5 x86_64
Subject name: PT01
COMMAND 1: []$ mri_convert Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz mri_convert Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz $Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ reading from
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz...
TR=1000.00, TE=0.00, TI=0.00, flip angle=0.00 i_ras = (-1, 0, 0) j_ras = (0, 1, 0) k_ras = (0, 0, 1) writing to
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz...
COMMAND 2: []$ reg-feat2anat --feat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat
--subject PT01 FeatDir is Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat template volume is Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz log file is
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/reg-feat2anat.log
Mon Jan 12 14:08:56 CST 2009 /net/data4/CCMB08/PTSD/Thickness /net/dysthymia/freesurfer/bin/reg-feat2anat --feat Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat --subject
PT01
Linux schizo.psych.med.umich.edu 2.6.18-92.1.1.el5 #1 SMP Thu
May 22
09:01:47 EDT 2008 x86_64 x86_64 x86_64 GNU/Linux example_func ras_good_flag 1
Initializing exf2anat with header tkregister2_cmdl --targ /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.init
--fslregout
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
--regheader --noedit target volume
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.init
LoadVol 0 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 1, float2int = 0 Computing reg from header (and possibly input matrix) ---- Input registration matrix (computed) -------- 1.000 0.000 0.000 -110.507; 0.000 0.000 1.000 -41.354; 0.000 -1.000 0.000 93.531; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 1.000 0.000 0.000 -110.507; 0.000 0.000 1.000 -41.354; 0.000 -1.000 0.000 93.531; 0.000 0.000 0.000 1.000; subject = subject-unknown RegMat --------------------------- 1.000 0.000 0.000 -110.507; 0.000 0.000 1.000 -41.354; 0.000 -1.000 0.000 93.531; 0.000 0.000 0.000 1.000; register: file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.init
written FSLOUTPUTTYPE NIFTI_GZ tkreg2FSL: mov det = -35.4492, ref det = -1 fslregister --s PT01 --reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--mov
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--dof 6 --bins 256 --cost corratio --fslmat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--fsvol brainmask --maxangle 90 --initfslmat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
--tmp
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp
--out
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
Log file is
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.fslregister.log
Mon Jan 12 14:08:56 CST 2009 --s PT01 --reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--mov
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--dof 6 --bins 256 --cost corratio --fslmat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--fsvol brainmask --maxangle 90 --initfslmat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
--tmp
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp
--out
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
$Id: fslregister,v 1.16 2007/07/26 16:52:54 greve Exp $ schizo.psych.med.umich.edu Linux schizo.psych.med.umich.edu 2.6.18-92.1.1.el5 #1 SMP Thu
May 22
09:01:47 EDT 2008 x86_64 x86_64 x86_64 GNU/Linux
/net/data4/CCMB08/PTSD/Thickness mri_convert
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii
mri_convert
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii
$Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ reading from
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz...
TR=12.27, TE=5.21, TI=650.00, flip angle=9.00 i_ras = (-1, 0, 0) j_ras = (0, 0, -1) k_ras = (0, 1, 0) writing to
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii...
/net/data4/CCMB08/PTSD/Thickness mri_convert Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
--frame 0 mri_convert Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
--frame 0 $Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ reading from
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz...
TR=1000.00, TE=0.00, TI=0.00, flip angle=0.00 i_ras = (-1, 0, 0) j_ras = (0, 1, 0) k_ras = (0, 0, 1) keeping frame 0 writing to
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii...
Mon Jan 12 14:09:00 CST 2009 /net/data4/CCMB08/PTSD/Thickness bet
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
-f 0.1 Mon Jan 12 14:09:04 CST 2009 /net/data4/CCMB08/PTSD/Thickness flirt -ref
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii
-in
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
-omat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
-cost corratio -dof 6 -searchrx -90 90 -searchry -90 90
-searchrz -90
90 -init
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
-o
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii
Mon Jan 12 14:09:20 CST 2009 /net/data4/CCMB08/PTSD/Thickness mri_convert
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
mri_convert
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
$Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ reading from
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii...
TR=1000.00, TE=0.00, TI=0.00, flip angle=0.00 i_ras = (-1, 0, 0) j_ras = (0, 0, -1) k_ras = (0, 1, 0) writing to
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz...
tkregister2_cmdl --s PT01 --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--noedit ---- FSL registration matrix -------- 0.995 -0.035 0.091 20.763; 0.093 0.066 -0.994 171.738; 0.028 0.997 0.069 11.368; 0.000 0.000 0.000 1.000;
INFO: no target volume specified, assuming FreeSurfer orig
volume.
target volume orig movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
LoadVol 0 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/orig.mgz
Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 FSLOUTPUTTYPE NIFTI fsl2TkReg: mov det = -35.4492, ref det = -1 ---- Input registration matrix (computed) -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; subject = PT01 RegMat --------------------------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; register: file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
written (standard_in) 1: illegal character: P (standard_in) 1: illegal character: T
Started at Mon Jan 12 14:08:57 CST 2009 Ended at Mon Jan 12 14:09:24 CST 2009
fslregister Done
To check results, run: tkregister2 --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--surf orig
tkregister2_cmdl --targ /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz --fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/example_func2standard.mat
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2exf.register.dat
--noedit ---- FSL registration matrix -------- 1.122 0.029 0.006 -34.123; -0.061 1.041 0.128 -3.403; -0.010 -0.119 1.224 25.844; 0.000 0.000 0.000 1.000;
target volume /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2exf.register.dat
LoadVol 0 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target
/net/misc/fsl/etc/standard/avg152T1_brain.nii.gz
INFO: target does not conform to COR format, so I'm going to reslice to COR. This will not affect the final registration. Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 FSLOUTPUTTYPE NIFTI_GZ fsl2TkReg: mov det = -35.4492, ref det = -8 ---- Input registration matrix (computed) -------- 0.890 0.025 0.002 1.505; -0.013 0.092 0.807 4.483; 0.051 -0.947 0.099 3.604; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 0.890 0.025 0.002 1.505; -0.013 0.092 0.807 4.483; 0.051 -0.947 0.099 3.604; 0.000 0.000 0.000 1.000; subject = subject-unknown RegMat --------------------------- 0.890 0.002 -0.025 1.505; -0.013 0.807 -0.092 4.483; 0.051 0.099 0.947 3.604; 0.000 0.000 0.000 1.000; register: file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2exf.register.dat
written mri_matrix_multiply -fsl -im
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
-iim
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/example_func2standard.mat
-om
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2anat.fsl.mat
tkregister2_cmdl --s PT01 --targ /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz --mov /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz --reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2std.register.dat
--fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2anat.fsl.mat
--noedit ---- FSL registration matrix -------- 0.885 -0.049 0.075 48.869; 0.074 -0.031 -0.809 195.041; 0.077 0.950 -0.044 18.348; 0.000 0.000 0.000 1.000;
target volume
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
movable volume /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2std.register.dat
LoadVol 0 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable
/net/misc/fsl/etc/standard/avg152T1_brain.nii.gz
Tmov: -------------------- -2.000 0.000 0.000 91.000; 0.000 0.000 2.000 -91.000; 0.000 -2.000 0.000 109.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 FSLOUTPUTTYPE NIFTI_GZ fsl2TkReg: mov det = -8, ref det = -1 ---- Input registration matrix (computed) -------- 1.116 -0.061 0.100 2.757; -0.105 -0.035 1.225 -4.398; -0.085 -1.046 -0.064 -3.213; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 1.116 -0.061 0.100 2.757; -0.105 -0.035 1.225 -4.398; -0.085 -1.046 -0.064 -3.213; 0.000 0.000 0.000 1.000; subject = PT01 RegMat --------------------------- 1.116 -0.061 0.100 2.757; -0.105 -0.035 1.225 -4.398; -0.085 -1.046 -0.064 -3.213; 0.000 0.000 0.000 1.000; register: file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2std.register.dat
written
To visually check your results, run: tkregister2_cmdl --s PT01 --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--surf orig --tag
Mon Jan 12 14:09:25 CST 2009 reg-feat2anat done
COMMAND 3: []$ tkregister2 --s PT01 --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
call/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--surf orig --tag --fsl
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/example_func2highres.mat
---- FSL registration matrix -------- 0.995 -0.035 0.091 20.763; 0.093 0.066 -0.994 171.738; 0.028 0.997 0.069 11.368; 0.000 0.000 0.000 1.000;
surfname set to orig ---- FSL registration matrix -------- 1.043 -0.038 0.042 18.354; 0.020 1.036 0.060 9.413; -0.046 -0.068 1.128 70.358; 0.000 0.000 0.000 1.000;
INFO: no target volume specified, assuming FreeSurfer orig
volume.
target volume orig movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
LoadVol 1 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/orig.mgz
INFO: changing target type to float Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 FSLOUTPUTTYPE NIFTI_GZ fsl2TkReg: mov det = -35.4492, ref det = -1 ---- Input registration matrix (computed) -------- 0.956 0.037 0.032 3.452; -0.038 0.882 -0.059 1.969; -0.021 0.050 0.961 1.159; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 0.956 0.037 0.032 3.452; -0.038 0.882 -0.059 1.969; -0.021 0.050 0.961 1.159; 0.000 0.000 0.000 1.000; subject = PT01 Reading lh surface orig Done reading surface Reading rh surface orig Done reading surface Zoom Factor = 2 FOV = 256 Opening window PT01 Setting scale Tagging mov volume tkregister2: interface:
/net/dysthymia/freesurfer/lib/tcl/tkregister2.tcl
tkregister.tcl: startup done tkregister.tcl: default macro interface (to change:
macro,mini,micro)
tkregister.tcl: or: setenv tkregisterinterface
{macro,mini,micro}
%
-----Original Message----- From: Doug Greve [mailto:greve@nmr.mgh.harvard.edu] Sent: Tue 1/6/2009 12:30 PM To: Wang, Xin Cc: freesurfer Subject: Re: [Freesurfer] reg-feat2anat failed
Hi Xin, I'm not sure what's going wrong here, I think I need
more
info.
Can you follow the steps in surfer.nmr.mgh.harvard.edu/fswiki/BugReporting?
doug
Wang, Xin wrote:
> hello, Freesurfer group, > > I try to use registration.mat files of FSL/FEAT routines,
instead of
> anat2example_func.bat, to register the orig.mgz and > example_func.nii.gz with the thinking that using
initial_highres in
> FEAT may improve the reg. However, tkregister2
catastrophically
failed
> to register two brains when I use --fsl flag. Modifying
header of
> example_func with mri_convert does not solve the problem.
I will
> appreciate any suggestion on using .mat file for registration. > > second question: what is the best registration of
example_func and
> orig.mgz? In another word, what should I check besides things
in the
> FS tutorial when I check/modify the registration in
tkregister2? Is
> there golden reference points I can use? > > Thank you in advance for any suggestion. > > Xin wang > > > -----Original Message----- > From: Doug Greve [mailto:greve@nmr.mgh.harvard.edu] > Sent: Mon 12/15/2008 1:26 PM > To: Wang, Xin > Cc: freesurfer > Subject: Re: [Freesurfer] reg-feat2anat failed > > There is a flag in the nifti header saying whether the
qform or
sform
> are valid, and it looks like your scripts do not set this
flag.
You can
> use mri_convert (the freesurfer program). This will create
valid
files
> that can be read into any program. > > doug > > Wang, Xin wrote: > > > Thank you very much for your quick reply, Dr. Greve. I
asked our
> > institutional MRI center for correct information on
qform and
sform
> > since the header of nifti files are created by their
scripts.
But I do
> > not know what they can do to fix this problem. I will
appreciate if
> > you have any further suggestion on how to do the
registration
without
> > the information on qform and sform in case I can not get
them.
Does
> > convert to ANALYZE format or manually correct in tkregister2
work?
> > > > Thank you again, > > > > Xin > > > > > > -----Original Message----- > > From: Doug Greve [mailto:greve@nmr.mgh.harvard.edu] > > Sent: Mon 12/15/2008 1:09 PM > > To: Wang, Xin > > Cc: freesurfer > > Subject: Re: [Freesurfer] reg-feat2anat failed > > > > Hi Xin, the problem is that neither the sform nor the
qform are
valid.
> > Did the message below not appear when you ran tkmedit? > > > > WARNING: neither NIfTI-1 qform or sform are valid > > WARNING: your volume will probably be incorrectly oriented > > > > Fix that, and everything will work fine. > > > > doug > > > > > > Wang, Xin wrote: > > > > > Hello, Freesurfer group, > > > I am registering the fMRI results to surface using
reg-feat2anat (v
> > > 1.26.2.1 2007/08/15) and tkregister2. The automatic
registration
> > > catastrophically failed in the subject space, but worked
fine
in the
> > > standard space. The orientations of example_func.nii.gz
in the
subject > > > space are flipped in any view. I use the tkmedit to
view the
> > > example_func, and found the orientation is wrong. It seems Freesurfer > > > can not read nifti header correctly. I attach the
reg-feat2anat log
> > > file and an example_func.nii.gz. > > > I found the following message from Freesurfer email list. > > > >
http://www.mail-archive.com/freesurfer@nmr.mgh.harvard.edu/msg05573.html
> > > Does Freesurfer have a solution for this type of
problems by
now?
> > > > > > Thank you in advance, > > > > > > Xin > > > > > >
> > > > > >_______________________________________________ > > >Freesurfer mailing list > > >Freesurfer@nmr.mgh.harvard.edu > >
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
> > > > > > > -- > > Douglas N. Greve, Ph.D. > > MGH-NMR Center > > greve@nmr.mgh.harvard.edu > > Phone Number: 617-724-2358 > > Fax: 617-726-7422 > > > > In order to help us help you, please follow the steps in: > > surfer.nmr.mgh.harvard.edu/fswiki/BugReporting > > > > > > > > -- > Douglas N. Greve, Ph.D. > MGH-NMR Center > greve@nmr.mgh.harvard.edu > Phone Number: 617-724-2358 > Fax: 617-726-7422 > > In order to help us help you, please follow the steps in: > surfer.nmr.mgh.harvard.edu/fswiki/BugReporting > > >
-- Douglas N. Greve, Ph.D. MGH-NMR Center greve@nmr.mgh.harvard.edu Phone Number: 617-724-2358 Fax: 617-726-7422
In order to help us help you, please follow the steps in: surfer.nmr.mgh.harvard.edu/fswiki/BugReporting
Hello, Dr. Greve, I used brain.mgz of freesurfer after mri_converted it to nii.gz as highres in feat registration with the thinking that the brain.mgz is the final product of freesurfer pre-processing. Using scalp-striped brain.mgz should be more comparable between fsl and FS than using T1.mgz or orig.mgz as I guess. Correct me if I am wrong.
Xin
-----Original Message----- From: Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] Sent: Tue 1/13/2009 11:27 AM To: Wang, Xin Cc: analysis-bugs@nmr.mgh.harvard.edu; freesurfer Subject: Re: [Freesurfer] reg-feat2anat failed
what did you use as the highres volume in feat? If you want that reg to work, it has to be a "freesurfer anatomical volume", meaning 256^3, 1mm3
doug
Wang, Xin wrote:
Hello, Freesurfer group, I registered the example_func.nii.gz to brain.mgz in tkregister2 using FS/anat2exf.register.dat, and --fslregout fsl.feat/reg/example_func2highres.mat. I have a couple of questions.
- could anybody confirm that using--fslregout does apply .mat file
for registration based on the following information on the screen? surfname set to orig target volume PT01/mri/brain.mgz movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat LoadVol 1 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 ---- Input registration matrix -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; float2int = 0
INFO: loading target PT01/mri/brain.mgz INFO: changing target type to float Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 ---- Input registration matrix -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; subject = PT01 Reading lh surface orig Done reading surface Reading rh surface orig Done reading surface Zoom Factor = 2 FOV = 256 Opening window PT01 NVIDIA: could not open the device file /dev/nvidiactl (Permission denied). NVIDIA: Direct rendering failed; attempting indirect rendering. Setting scale Tagging mov volume tkregister2: interface: /net/dysthymia/freesurfer/lib/tcl/tkregister2.tcl tkregister.tcl: startup done tkregister.tcl: default macro interface (to change: macro,mini,micro) tkregister.tcl: or: setenv tkregisterinterface {macro,mini,micro} %
- The results are quite the same (and good) in the tkregister2 with a
slightly difference as shown below. Could anyone please tell me what these numbers mean?
with .bat file Screen: 256 257 (113,113,113), inorm = 1, mov_frame = 0 Anat: (128 126 127) ( 0.0 -1.0 2.0) 25.0000 32.7 Func: ( 31 32 21) ( 4.2 3.1 1.4) 756.0000 112.5
with .mat file Screen: 257 257 (175,175,175), inorm = 1, mov_frame = 0 Anat: (128 126 127) ( 0.0 -1.0 2.0) 25.0000 28.3 Func: ( 31 32 21) ( 4.2 3.1 1.4) 756.0000 106.2
Thanks,
Xin
-----Original Message----- From: Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] Sent: Mon 1/12/2009 4:02 PM To: Wang, Xin Cc: analysis-bugs@nmr.mgh.harvard.edu Subject: Re: [Freesurfer] reg-feat2anat failed
reg-feat2anat calls fslregister, so they should produce the same result. There is no need for an "intermediate" volume since you are registering from the subject's EPI to the subject's structure. Does the registration not look good?
Wang, Xin wrote:
Thank you, Dr. Greve. It seems work ok. what is the difference between reg-feat2anat and fslregister? although both commands are working for me, I don't think either of them serve my propose. Freesurfer does not use initial_highres to improve the reg of example_func to highres, but FSL/FEAT uses this inter-mediate step. I try to use registration.mat files of FSL/FEAT step-wise registrations to improve the reg. I think flag --fsl allow me to use a fsl.mat file as reg file. How to make it work in the way I need?
Thank you again,
Xin
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 3:29 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
when you say everything looked ok, do you mean that the orientation was correct? If so, try running this:
fslregister --s subject --mov example_func.nii.gz --reg newreg.dat
then
tkregister2 --mov example_func.nii.gz --reg newreg.dat --surfs
Wang, Xin wrote:
Sorry, Dr. Greve. I copied addtional parts after I killed the tkmedit. The following is on the screen when I saw the image.
[]$ tkmedit -f Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Reading /net/dysthymia/freesurfer/lib/tcl/tkm_common.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkm_wrappers.tcl Reading /net/dysthymia/freesurfer/lib/tcl/fsgdfPlot.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkUtils.tcl %
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 3:10 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
I don't understand. If it segfaulted how did you look at the images?
Wang, Xin wrote:
Thank you, Dr. Greve. This time tkmedit read the image, and the image looks ok to me. But following information appeared.
[]$ tkmedit -f Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Reading /net/dysthymia/freesurfer/lib/tcl/tkm_common.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkm_wrappers.tcl Reading /net/dysthymia/freesurfer/lib/tcl/fsgdfPlot.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkUtils.tcl % Killed
=================================== ERROR: A segfault has occurred. This is not your fault, : but is most likely an unrecoverable error and has : made the program unstable. : : Please send the contents of the file .xdebug_tkmedit : that should be in this directory to analysis-bugs@nmr.mgh.harvard.edu mailto:analysis-bugs@nmr.mgh.harvard.edu : : Now exiting... : []$ cat .xdebug_tkmedit tkmedit started: Mon Jan 12 15:14:52 2009 tkmedit.bin -f Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz $Id: tkmedit.c,v 1.320.2.5 2008/03/10 14:02:35 nicks Exp $ $Name: stable4 $ Set user home dir to /net/data4/CCMB08/PTSD/Thickness Set subject home dir to Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Using interface file /net/dysthymia/freesurfer/lib/tcl/tkmedit.tcl Tcl: Successfully parsed tkmedit.tcl Tcl: Successfully parsed tkm_functional.tcl Segfault Entering main loop xDebug stack (length: 2) 01: main() 01: Entering main loop 00: 00:
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 2:55 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
what is your tkmedit cmd?
It should be
tkmedit -f example_func.nii.gz
Wang, Xin wrote:
Hello, Dr. Greve, tkmedit can not open the example_func.nii.gzI attached the
header of
example_func.nii.gz (after mri_convert), and the contents of .xdebug_tkmedit file
[]$ fslhd
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
filename Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz sizeof_hdr 348 data_type FLOAT32 dim0 3 dim1 64 dim2 64 dim3 40 dim4 1 dim5 1 dim6 1 dim7 1 vox_units mm time_units s datatype 16 nbyper 4 bitpix 32 pixdim0 0.0000000000 pixdim1 3.4375000000 pixdim2 3.4375000000 pixdim3 3.0000000000 pixdim4 1.0000000000 pixdim5 1.0000000000 pixdim6 1.0000000000 pixdim7 1.0000000000 vox_offset 352 cal_max 0.0000 cal_min 0.0000 scl_slope 0.000000 scl_inter 0.000000 phase_dim 0 freq_dim 0 slice_dim 0 slice_name Unknown slice_code 0 slice_start 0 slice_end 0 slice_duration 0.000000 time_offset 0.000000 intent Unknown intent_code 0 intent_name intent_p1 0.000000 intent_p2 0.000000 intent_p3 0.000000 qform_name Scanner Anat qform_code 1 qto_xyz:1 -3.437500 0.000000 -0.000000 220.000000 qto_xyz:2 0.000000 3.437500 -0.000000 0.000000 qto_xyz:3 0.000000 0.000000 3.000000 0.000000 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 -3.437500 0.000000 0.000000 220.000000 sto_xyz:2 0.000000 3.437500 0.000000 0.000000 sto_xyz:3 0.000000 0.000000 3.000000 0.000000 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 file_type NIFTI-1+ file_code 1 descrip FreeSurfer Jun 14 2008 aux_file .xdebug_tkmedit tkmedit started: Mon Jan 12 15:05:46 2009 tkmedit.bin Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz $Id: tkmedit.c,v 1.320.2.5 2008/03/10 14:02:35 nicks Exp $ $Name: stable4 $ Set user home dir to /net/data4/CCMB08/PTSD/Thickness ERROR: Parsing arguments Subject and image not declared Fatal error in parsing command line args. Segfault Copying argv[1] xDebug stack (length: 3) 02: ParseCmdLineArgs( argc=2, argv=tkmedit.bin ) 02: Copying argv[1] 01: main() 01: Parsing command line arguments 00: 00:
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 2:38 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
If the orientation of the example func in tkmedit is wrong,
then the
reg-feat2anat is destined to fail. tkmedit (usually) reads the
nifti
header correctly. How do you know the header is right?
Wang, Xin wrote:
My problem about tkregister2 is that the flag -fsl example_func2highres.mat does not work properly. The tkregister2 catastrophically failed to register two brains. I submit the bugreport of tkregister2 (please see the COMMAND
3). The
two early steps (mri_convert and reg-feat2anat) are included for
your
references.
Thanks,
Xin
FREESURFER_HOME: /net/dysthymia/freesurfer
Build stamp: freesurfer-Linux-centos4_x86_64-stable-pub-v4.0.5
RedHat release: Red Hat Enterprise Linux Client release 5.2
(Tikanga)
Kernel info: Linux 2.6.18-92.1.1.el5 x86_64
Subject name: PT01
COMMAND 1: []$ mri_convert Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz mri_convert Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz $Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ reading from
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz...
TR=1000.00, TE=0.00, TI=0.00, flip angle=0.00 i_ras = (-1, 0, 0) j_ras = (0, 1, 0) k_ras = (0, 0, 1) writing to
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz...
COMMAND 2: []$ reg-feat2anat --feat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat
--subject PT01 FeatDir is Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat template volume is Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz log file is
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/reg-feat2anat.log
Mon Jan 12 14:08:56 CST 2009 /net/data4/CCMB08/PTSD/Thickness /net/dysthymia/freesurfer/bin/reg-feat2anat --feat Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat --subject
PT01
Linux schizo.psych.med.umich.edu 2.6.18-92.1.1.el5 #1 SMP Thu
May 22
09:01:47 EDT 2008 x86_64 x86_64 x86_64 GNU/Linux example_func ras_good_flag 1
Initializing exf2anat with header tkregister2_cmdl --targ /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.init
--fslregout
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
--regheader --noedit target volume
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.init
LoadVol 0 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 1, float2int = 0 Computing reg from header (and possibly input matrix) ---- Input registration matrix (computed) -------- 1.000 0.000 0.000 -110.507; 0.000 0.000 1.000 -41.354; 0.000 -1.000 0.000 93.531; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 1.000 0.000 0.000 -110.507; 0.000 0.000 1.000 -41.354; 0.000 -1.000 0.000 93.531; 0.000 0.000 0.000 1.000; subject = subject-unknown RegMat --------------------------- 1.000 0.000 0.000 -110.507; 0.000 0.000 1.000 -41.354; 0.000 -1.000 0.000 93.531; 0.000 0.000 0.000 1.000; register: file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.init
written FSLOUTPUTTYPE NIFTI_GZ tkreg2FSL: mov det = -35.4492, ref det = -1 fslregister --s PT01 --reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--mov
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--dof 6 --bins 256 --cost corratio --fslmat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--fsvol brainmask --maxangle 90 --initfslmat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
--tmp
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp
--out
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
Log file is
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.fslregister.log
Mon Jan 12 14:08:56 CST 2009 --s PT01 --reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--mov
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--dof 6 --bins 256 --cost corratio --fslmat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--fsvol brainmask --maxangle 90 --initfslmat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
--tmp
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp
--out
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
$Id: fslregister,v 1.16 2007/07/26 16:52:54 greve Exp $ schizo.psych.med.umich.edu Linux schizo.psych.med.umich.edu 2.6.18-92.1.1.el5 #1 SMP Thu
May 22
09:01:47 EDT 2008 x86_64 x86_64 x86_64 GNU/Linux
/net/data4/CCMB08/PTSD/Thickness mri_convert
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii
mri_convert
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii
$Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ reading from
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz...
TR=12.27, TE=5.21, TI=650.00, flip angle=9.00 i_ras = (-1, 0, 0) j_ras = (0, 0, -1) k_ras = (0, 1, 0) writing to
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii...
/net/data4/CCMB08/PTSD/Thickness mri_convert Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
--frame 0 mri_convert Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
--frame 0 $Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ reading from
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz...
TR=1000.00, TE=0.00, TI=0.00, flip angle=0.00 i_ras = (-1, 0, 0) j_ras = (0, 1, 0) k_ras = (0, 0, 1) keeping frame 0 writing to
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii...
Mon Jan 12 14:09:00 CST 2009 /net/data4/CCMB08/PTSD/Thickness bet
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
-f 0.1 Mon Jan 12 14:09:04 CST 2009 /net/data4/CCMB08/PTSD/Thickness flirt -ref
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii
-in
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
-omat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
-cost corratio -dof 6 -searchrx -90 90 -searchry -90 90
-searchrz -90
90 -init
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
-o
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii
Mon Jan 12 14:09:20 CST 2009 /net/data4/CCMB08/PTSD/Thickness mri_convert
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
mri_convert
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
$Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ reading from
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii...
TR=1000.00, TE=0.00, TI=0.00, flip angle=0.00 i_ras = (-1, 0, 0) j_ras = (0, 0, -1) k_ras = (0, 1, 0) writing to
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz...
tkregister2_cmdl --s PT01 --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--noedit ---- FSL registration matrix -------- 0.995 -0.035 0.091 20.763; 0.093 0.066 -0.994 171.738; 0.028 0.997 0.069 11.368; 0.000 0.000 0.000 1.000;
INFO: no target volume specified, assuming FreeSurfer orig
volume.
target volume orig movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
LoadVol 0 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/orig.mgz
Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 FSLOUTPUTTYPE NIFTI fsl2TkReg: mov det = -35.4492, ref det = -1 ---- Input registration matrix (computed) -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; subject = PT01 RegMat --------------------------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; register: file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
written (standard_in) 1: illegal character: P (standard_in) 1: illegal character: T
Started at Mon Jan 12 14:08:57 CST 2009 Ended at Mon Jan 12 14:09:24 CST 2009
fslregister Done
To check results, run: tkregister2 --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--surf orig
tkregister2_cmdl --targ /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz --fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/example_func2standard.mat
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2exf.register.dat
--noedit ---- FSL registration matrix -------- 1.122 0.029 0.006 -34.123; -0.061 1.041 0.128 -3.403; -0.010 -0.119 1.224 25.844; 0.000 0.000 0.000 1.000;
target volume /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2exf.register.dat
LoadVol 0 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target
/net/misc/fsl/etc/standard/avg152T1_brain.nii.gz
INFO: target does not conform to COR format, so I'm going to reslice to COR. This will not affect the final registration. Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 FSLOUTPUTTYPE NIFTI_GZ fsl2TkReg: mov det = -35.4492, ref det = -8 ---- Input registration matrix (computed) -------- 0.890 0.025 0.002 1.505; -0.013 0.092 0.807 4.483; 0.051 -0.947 0.099 3.604; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 0.890 0.025 0.002 1.505; -0.013 0.092 0.807 4.483; 0.051 -0.947 0.099 3.604; 0.000 0.000 0.000 1.000; subject = subject-unknown RegMat --------------------------- 0.890 0.002 -0.025 1.505; -0.013 0.807 -0.092 4.483; 0.051 0.099 0.947 3.604; 0.000 0.000 0.000 1.000; register: file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2exf.register.dat
written mri_matrix_multiply -fsl -im
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
-iim
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/example_func2standard.mat
-om
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2anat.fsl.mat
tkregister2_cmdl --s PT01 --targ /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz --mov /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz --reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2std.register.dat
--fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2anat.fsl.mat
--noedit ---- FSL registration matrix -------- 0.885 -0.049 0.075 48.869; 0.074 -0.031 -0.809 195.041; 0.077 0.950 -0.044 18.348; 0.000 0.000 0.000 1.000;
target volume
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
movable volume /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2std.register.dat
LoadVol 0 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable
/net/misc/fsl/etc/standard/avg152T1_brain.nii.gz
Tmov: -------------------- -2.000 0.000 0.000 91.000; 0.000 0.000 2.000 -91.000; 0.000 -2.000 0.000 109.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 FSLOUTPUTTYPE NIFTI_GZ fsl2TkReg: mov det = -8, ref det = -1 ---- Input registration matrix (computed) -------- 1.116 -0.061 0.100 2.757; -0.105 -0.035 1.225 -4.398; -0.085 -1.046 -0.064 -3.213; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 1.116 -0.061 0.100 2.757; -0.105 -0.035 1.225 -4.398; -0.085 -1.046 -0.064 -3.213; 0.000 0.000 0.000 1.000; subject = PT01 RegMat --------------------------- 1.116 -0.061 0.100 2.757; -0.105 -0.035 1.225 -4.398; -0.085 -1.046 -0.064 -3.213; 0.000 0.000 0.000 1.000; register: file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2std.register.dat
written
To visually check your results, run: tkregister2_cmdl --s PT01 --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--surf orig --tag
Mon Jan 12 14:09:25 CST 2009 reg-feat2anat done
COMMAND 3: []$ tkregister2 --s PT01 --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
call/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--surf orig --tag --fsl
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/example_func2highres.mat
---- FSL registration matrix -------- 0.995 -0.035 0.091 20.763; 0.093 0.066 -0.994 171.738; 0.028 0.997 0.069 11.368; 0.000 0.000 0.000 1.000;
surfname set to orig ---- FSL registration matrix -------- 1.043 -0.038 0.042 18.354; 0.020 1.036 0.060 9.413; -0.046 -0.068 1.128 70.358; 0.000 0.000 0.000 1.000;
INFO: no target volume specified, assuming FreeSurfer orig
volume.
target volume orig movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
LoadVol 1 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/orig.mgz
INFO: changing target type to float Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 FSLOUTPUTTYPE NIFTI_GZ fsl2TkReg: mov det = -35.4492, ref det = -1 ---- Input registration matrix (computed) -------- 0.956 0.037 0.032 3.452; -0.038 0.882 -0.059 1.969; -0.021 0.050 0.961 1.159; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 0.956 0.037 0.032 3.452; -0.038 0.882 -0.059 1.969; -0.021 0.050 0.961 1.159; 0.000 0.000 0.000 1.000; subject = PT01 Reading lh surface orig Done reading surface Reading rh surface orig Done reading surface Zoom Factor = 2 FOV = 256 Opening window PT01 Setting scale Tagging mov volume tkregister2: interface:
/net/dysthymia/freesurfer/lib/tcl/tkregister2.tcl
tkregister.tcl: startup done tkregister.tcl: default macro interface (to change:
macro,mini,micro)
tkregister.tcl: or: setenv tkregisterinterface
{macro,mini,micro}
%
-----Original Message----- From: Doug Greve [mailto:greve@nmr.mgh.harvard.edu] Sent: Tue 1/6/2009 12:30 PM To: Wang, Xin Cc: freesurfer Subject: Re: [Freesurfer] reg-feat2anat failed
Hi Xin, I'm not sure what's going wrong here, I think I need
more
info.
Can you follow the steps in surfer.nmr.mgh.harvard.edu/fswiki/BugReporting?
doug
Wang, Xin wrote:
> hello, Freesurfer group, > > I try to use registration.mat files of FSL/FEAT routines,
instead of
> anat2example_func.bat, to register the orig.mgz and > example_func.nii.gz with the thinking that using
initial_highres in
> FEAT may improve the reg. However, tkregister2
catastrophically
failed
> to register two brains when I use --fsl flag. Modifying
header of
> example_func with mri_convert does not solve the problem.
I will
> appreciate any suggestion on using .mat file for registration. > > second question: what is the best registration of
example_func and
> orig.mgz? In another word, what should I check besides things
in the
> FS tutorial when I check/modify the registration in
tkregister2? Is
> there golden reference points I can use? > > Thank you in advance for any suggestion. > > Xin wang > > > -----Original Message----- > From: Doug Greve [mailto:greve@nmr.mgh.harvard.edu] > Sent: Mon 12/15/2008 1:26 PM > To: Wang, Xin > Cc: freesurfer > Subject: Re: [Freesurfer] reg-feat2anat failed > > There is a flag in the nifti header saying whether the
qform or
sform
> are valid, and it looks like your scripts do not set this
flag.
You can
> use mri_convert (the freesurfer program). This will create
valid
files
> that can be read into any program. > > doug > > Wang, Xin wrote: > > > Thank you very much for your quick reply, Dr. Greve. I
asked our
> > institutional MRI center for correct information on
qform and
sform
> > since the header of nifti files are created by their
scripts.
But I do
> > not know what they can do to fix this problem. I will
appreciate if
> > you have any further suggestion on how to do the
registration
without
> > the information on qform and sform in case I can not get
them.
Does
> > convert to ANALYZE format or manually correct in tkregister2
work?
> > > > Thank you again, > > > > Xin > > > > > > -----Original Message----- > > From: Doug Greve [mailto:greve@nmr.mgh.harvard.edu] > > Sent: Mon 12/15/2008 1:09 PM > > To: Wang, Xin > > Cc: freesurfer > > Subject: Re: [Freesurfer] reg-feat2anat failed > > > > Hi Xin, the problem is that neither the sform nor the
qform are
valid.
> > Did the message below not appear when you ran tkmedit? > > > > WARNING: neither NIfTI-1 qform or sform are valid > > WARNING: your volume will probably be incorrectly oriented > > > > Fix that, and everything will work fine. > > > > doug > > > > > > Wang, Xin wrote: > > > > > Hello, Freesurfer group, > > > I am registering the fMRI results to surface using
reg-feat2anat (v
> > > 1.26.2.1 2007/08/15) and tkregister2. The automatic
registration
> > > catastrophically failed in the subject space, but worked
fine
in the
> > > standard space. The orientations of example_func.nii.gz
in the
subject > > > space are flipped in any view. I use the tkmedit to
view the
> > > example_func, and found the orientation is wrong. It seems Freesurfer > > > can not read nifti header correctly. I attach the
reg-feat2anat log
> > > file and an example_func.nii.gz. > > > I found the following message from Freesurfer email list. > > > >
http://www.mail-archive.com/freesurfer@nmr.mgh.harvard.edu/msg05573.html
> > > Does Freesurfer have a solution for this type of
problems by
now?
> > > > > > Thank you in advance, > > > > > > Xin > > > > > >
> > > > > >_______________________________________________ > > >Freesurfer mailing list > > >Freesurfer@nmr.mgh.harvard.edu > >
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
> > > > > > > -- > > Douglas N. Greve, Ph.D. > > MGH-NMR Center > > greve@nmr.mgh.harvard.edu > > Phone Number: 617-724-2358 > > Fax: 617-726-7422 > > > > In order to help us help you, please follow the steps in: > > surfer.nmr.mgh.harvard.edu/fswiki/BugReporting > > > > > > > > -- > Douglas N. Greve, Ph.D. > MGH-NMR Center > greve@nmr.mgh.harvard.edu > Phone Number: 617-724-2358 > Fax: 617-726-7422 > > In order to help us help you, please follow the steps in: > surfer.nmr.mgh.harvard.edu/fswiki/BugReporting > > >
-- Douglas N. Greve, Ph.D. MGH-NMR Center greve@nmr.mgh.harvard.edu Phone Number: 617-724-2358 Fax: 617-726-7422
In order to help us help you, please follow the steps in: surfer.nmr.mgh.harvard.edu/fswiki/BugReporting
no, that's right. Does the example_func have a positive determinant?
Wang, Xin wrote:
Hello, Dr. Greve, I used brain.mgz of freesurfer after mri_converted it to nii.gz as highres in feat registration with the thinking that the brain.mgz is the final product of freesurfer pre-processing. Using scalp-striped brain.mgz should be more comparable between fsl and FS than using T1.mgz or orig.mgz as I guess. Correct me if I am wrong.
Xin
-----Original Message----- From: Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] Sent: Tue 1/13/2009 11:27 AM To: Wang, Xin Cc: analysis-bugs@nmr.mgh.harvard.edu; freesurfer Subject: Re: [Freesurfer] reg-feat2anat failed
what did you use as the highres volume in feat? If you want that reg to work, it has to be a "freesurfer anatomical volume", meaning 256^3, 1mm3
doug
Wang, Xin wrote:
Hello, Freesurfer group, I registered the example_func.nii.gz to brain.mgz in tkregister2 using FS/anat2exf.register.dat, and --fslregout fsl.feat/reg/example_func2highres.mat. I have a couple of questions.
- could anybody confirm that using--fslregout does apply .mat file
for registration based on the following information on the screen? surfname set to orig target volume PT01/mri/brain.mgz movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
LoadVol 1 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 ---- Input registration matrix -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; float2int = 0
INFO: loading target PT01/mri/brain.mgz INFO: changing target type to float Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 ---- Input registration matrix -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; subject = PT01 Reading lh surface orig Done reading surface Reading rh surface orig Done reading surface Zoom Factor = 2 FOV = 256 Opening window PT01 NVIDIA: could not open the device file /dev/nvidiactl (Permission
denied).
NVIDIA: Direct rendering failed; attempting indirect rendering. Setting scale Tagging mov volume tkregister2: interface:
/net/dysthymia/freesurfer/lib/tcl/tkregister2.tcl
tkregister.tcl: startup done tkregister.tcl: default macro interface (to change: macro,mini,micro) tkregister.tcl: or: setenv tkregisterinterface {macro,mini,micro} %
- The results are quite the same (and good) in the tkregister2 with a
slightly difference as shown below. Could anyone please tell me what these numbers mean?
with .bat file Screen: 256 257 (113,113,113), inorm = 1, mov_frame = 0 Anat: (128 126 127) ( 0.0 -1.0 2.0) 25.0000 32.7 Func: ( 31 32 21) ( 4.2 3.1 1.4) 756.0000 112.5
with .mat file Screen: 257 257 (175,175,175), inorm = 1, mov_frame = 0 Anat: (128 126 127) ( 0.0 -1.0 2.0) 25.0000 28.3 Func: ( 31 32 21) ( 4.2 3.1 1.4) 756.0000 106.2
Thanks,
Xin
-----Original Message----- From: Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] Sent: Mon 1/12/2009 4:02 PM To: Wang, Xin Cc: analysis-bugs@nmr.mgh.harvard.edu Subject: Re: [Freesurfer] reg-feat2anat failed
reg-feat2anat calls fslregister, so they should produce the same result. There is no need for an "intermediate" volume since you are registering from the subject's EPI to the subject's structure. Does the registration not look good?
Wang, Xin wrote:
Thank you, Dr. Greve. It seems work ok. what is the difference between reg-feat2anat and fslregister? although both commands are working for me, I don't think either of them serve my propose. Freesurfer does not use initial_highres to improve the reg of example_func to highres, but FSL/FEAT uses this inter-mediate step. I try to use registration.mat files of FSL/FEAT step-wise registrations to improve the reg. I think flag --fsl allow me to use a fsl.mat file as reg file. How to make it work in the way I need?
Thank you again,
Xin
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 3:29 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
when you say everything looked ok, do you mean that the
orientation was
correct? If so, try running this:
fslregister --s subject --mov example_func.nii.gz --reg newreg.dat
then
tkregister2 --mov example_func.nii.gz --reg newreg.dat --surfs
Wang, Xin wrote:
Sorry, Dr. Greve. I copied addtional parts after I killed the tkmedit. The following is on the screen when I saw the image.
[]$ tkmedit -f Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Reading /net/dysthymia/freesurfer/lib/tcl/tkm_common.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkm_wrappers.tcl Reading /net/dysthymia/freesurfer/lib/tcl/fsgdfPlot.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkUtils.tcl %
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 3:10 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
I don't understand. If it segfaulted how did you look at the images?
Wang, Xin wrote:
Thank you, Dr. Greve. This time tkmedit read the image, and the image looks ok to
me. But
following information appeared.
[]$ tkmedit -f Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Reading /net/dysthymia/freesurfer/lib/tcl/tkm_common.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkm_wrappers.tcl Reading /net/dysthymia/freesurfer/lib/tcl/fsgdfPlot.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkUtils.tcl % Killed
=================================== ERROR: A segfault has occurred. This is not your fault, : but is most likely an unrecoverable error and has : made the program unstable. : : Please send the contents of the file .xdebug_tkmedit : that should be in this directory to analysis-bugs@nmr.mgh.harvard.edu mailto:analysis-bugs@nmr.mgh.harvard.edu : : Now exiting... : []$ cat .xdebug_tkmedit tkmedit started: Mon Jan 12 15:14:52 2009 tkmedit.bin -f Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz $Id: tkmedit.c,v 1.320.2.5 2008/03/10 14:02:35 nicks Exp $ $Name: stable4 $ Set user home dir to /net/data4/CCMB08/PTSD/Thickness Set subject home dir to Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Using interface file /net/dysthymia/freesurfer/lib/tcl/tkmedit.tcl Tcl: Successfully parsed tkmedit.tcl Tcl: Successfully parsed tkm_functional.tcl Segfault Entering main loop xDebug stack (length: 2) 01: main() 01: Entering main loop 00: 00:
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 2:55 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
what is your tkmedit cmd?
It should be
tkmedit -f example_func.nii.gz
Wang, Xin wrote:
Hello, Dr. Greve, tkmedit can not open the example_func.nii.gzI attached the
header of
example_func.nii.gz (after mri_convert), and the contents of .xdebug_tkmedit file
[]$ fslhd
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
filename Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz sizeof_hdr 348 data_type FLOAT32 dim0 3 dim1 64 dim2 64 dim3 40 dim4 1 dim5 1 dim6 1 dim7 1 vox_units mm time_units s datatype 16 nbyper 4 bitpix 32 pixdim0 0.0000000000 pixdim1 3.4375000000 pixdim2 3.4375000000 pixdim3 3.0000000000 pixdim4 1.0000000000 pixdim5 1.0000000000 pixdim6 1.0000000000 pixdim7 1.0000000000 vox_offset 352 cal_max 0.0000 cal_min 0.0000 scl_slope 0.000000 scl_inter 0.000000 phase_dim 0 freq_dim 0 slice_dim 0 slice_name Unknown slice_code 0 slice_start 0 slice_end 0 slice_duration 0.000000 time_offset 0.000000 intent Unknown intent_code 0 intent_name intent_p1 0.000000 intent_p2 0.000000 intent_p3 0.000000 qform_name Scanner Anat qform_code 1 qto_xyz:1 -3.437500 0.000000 -0.000000 220.000000 qto_xyz:2 0.000000 3.437500 -0.000000 0.000000 qto_xyz:3 0.000000 0.000000 3.000000 0.000000 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 -3.437500 0.000000 0.000000 220.000000 sto_xyz:2 0.000000 3.437500 0.000000 0.000000 sto_xyz:3 0.000000 0.000000 3.000000 0.000000 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 file_type NIFTI-1+ file_code 1 descrip FreeSurfer Jun 14 2008 aux_file .xdebug_tkmedit tkmedit started: Mon Jan 12 15:05:46 2009 tkmedit.bin Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz $Id: tkmedit.c,v 1.320.2.5 2008/03/10 14:02:35 nicks Exp $
$Name:
stable4 $ Set user home dir to /net/data4/CCMB08/PTSD/Thickness ERROR: Parsing arguments Subject and image not declared Fatal error in parsing command line args. Segfault Copying argv[1] xDebug stack (length: 3) 02: ParseCmdLineArgs( argc=2, argv=tkmedit.bin ) 02: Copying argv[1] 01: main() 01: Parsing command line arguments 00: 00:
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 2:38 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
If the orientation of the example func in tkmedit is wrong,
then the
reg-feat2anat is destined to fail. tkmedit (usually) reads the
nifti
header correctly. How do you know the header is right?
Wang, Xin wrote: > > My problem about tkregister2 is that the flag -fsl > example_func2highres.mat does not work properly. The
tkregister2
> catastrophically failed to register two brains. > I submit the bugreport of tkregister2 (please see the COMMAND
3). The
> two early steps (mri_convert and reg-feat2anat) are
included for
your
> references. > > Thanks, > > Xin > >
> > FREESURFER_HOME: /net/dysthymia/freesurfer > > Build stamp: freesurfer-Linux-centos4_x86_64-stable-pub-v4.0.5 > > RedHat release: Red Hat Enterprise Linux Client release 5.2
(Tikanga)
> > Kernel info: Linux 2.6.18-92.1.1.el5 x86_64 > >
> Subject name: PT01 > > COMMAND 1: > []$ mri_convert >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> mri_convert >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> $Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ > reading from >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz...
> TR=1000.00, TE=0.00, TI=0.00, flip angle=0.00 > i_ras = (-1, 0, 0) > j_ras = (0, 1, 0) > k_ras = (0, 0, 1) > writing to >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz...
> > COMMAND 2: > []$ reg-feat2anat --feat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat
> --subject PT01 > FeatDir is Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat > template volume is >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> log file is >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/reg-feat2anat.log
> Mon Jan 12 14:08:56 CST 2009 > /net/data4/CCMB08/PTSD/Thickness > /net/dysthymia/freesurfer/bin/reg-feat2anat > --feat Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat --subject
PT01
> Linux schizo.psych.med.umich.edu 2.6.18-92.1.1.el5 #1 SMP Thu
May 22
> 09:01:47 EDT 2008 x86_64 x86_64 x86_64 GNU/Linux > example_func ras_good_flag 1 > ------------------------------------------------------- > Initializing exf2anat with header > tkregister2_cmdl --targ > /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz --mov >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.init
> --fslregout >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
> --regheader --noedit > target volume
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
> movable volume >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> reg file >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.init
> LoadVol 0 > ZeroCRAS 0 > $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ > Diagnostic Level -1 > INFO: loading target > /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz > Ttarg: -------------------- > -1.000 0.000 0.000 128.000; > 0.000 0.000 1.000 -128.000; > 0.000 -1.000 0.000 128.000; > 0.000 0.000 0.000 1.000; > INFO: loading movable >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> Tmov: -------------------- > -3.438 0.000 0.000 110.000; > 0.000 0.000 3.000 -60.000; > 0.000 -3.438 0.000 110.000; > 0.000 0.000 0.000 1.000; > mkheaderreg = 1, float2int = 0 > Computing reg from header (and possibly input matrix) > ---- Input registration matrix (computed) -------- > 1.000 0.000 0.000 -110.507; > 0.000 0.000 1.000 -41.354; > 0.000 -1.000 0.000 93.531; > 0.000 0.000 0.000 1.000; > --------------------------------------- > ---- Input registration matrix -------- > 1.000 0.000 0.000 -110.507; > 0.000 0.000 1.000 -41.354; > 0.000 -1.000 0.000 93.531; > 0.000 0.000 0.000 1.000; > subject = subject-unknown > RegMat --------------------------- > 1.000 0.000 0.000 -110.507; > 0.000 0.000 1.000 -41.354; > 0.000 -1.000 0.000 93.531; > 0.000 0.000 0.000 1.000; > register: file >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.init
> written > FSLOUTPUTTYPE NIFTI_GZ > tkreg2FSL: mov det = -35.4492, ref det = -1 > fslregister --s PT01 --reg >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
> --mov
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> --dof 6 --bins 256 --cost corratio --fslmat >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
> --fsvol brainmask --maxangle 90 --initfslmat >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
> --tmp
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp
> --out >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
> > Log file is >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.fslregister.log
> > Mon Jan 12 14:08:56 CST 2009 > --s PT01 --reg >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
> --mov
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> --dof 6 --bins 256 --cost corratio --fslmat >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
> --fsvol brainmask --maxangle 90 --initfslmat >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
> --tmp
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp
> --out >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
> $Id: fslregister,v 1.16 2007/07/26 16:52:54 greve Exp $ > schizo.psych.med.umich.edu > Linux schizo.psych.med.umich.edu 2.6.18-92.1.1.el5 #1 SMP Thu
May 22
> 09:01:47 EDT 2008 x86_64 x86_64 x86_64 GNU/Linux > -------------------------------------- > /net/data4/CCMB08/PTSD/Thickness > mri_convert
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii
> mri_convert
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii
> $Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ > reading from
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz...
> TR=12.27, TE=5.21, TI=650.00, flip angle=9.00 > i_ras = (-1, 0, 0) > j_ras = (0, 0, -1) > k_ras = (0, 1, 0) > writing to >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii...
> -------------------------------------- > /net/data4/CCMB08/PTSD/Thickness > mri_convert >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
> --frame 0 > mri_convert >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
> --frame 0 > $Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ > reading from >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz...
> TR=1000.00, TE=0.00, TI=0.00, flip angle=0.00 > i_ras = (-1, 0, 0) > j_ras = (0, 1, 0) > k_ras = (0, 0, 1) > keeping frame 0 > writing to >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii...
> Mon Jan 12 14:09:00 CST 2009 > /net/data4/CCMB08/PTSD/Thickness > bet >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
> -f 0.1 > Mon Jan 12 14:09:04 CST 2009 > /net/data4/CCMB08/PTSD/Thickness > flirt -ref >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii
> -in >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
> -omat >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
> -cost corratio -dof 6 -searchrx -90 90 -searchry -90 90
-searchrz -90
> 90 -init >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
> -o >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii
> Mon Jan 12 14:09:20 CST 2009 > /net/data4/CCMB08/PTSD/Thickness > mri_convert >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
> mri_convert >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
> $Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ > reading from >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii...
> TR=1000.00, TE=0.00, TI=0.00, flip angle=0.00 > i_ras = (-1, 0, 0) > j_ras = (0, 0, -1) > k_ras = (0, 1, 0) > writing to >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz...
> tkregister2_cmdl --s PT01 --mov >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
> --fslreg >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
> --noedit > ---- FSL registration matrix -------- > 0.995 -0.035 0.091 20.763; > 0.093 0.066 -0.994 171.738; > 0.028 0.997 0.069 11.368; > 0.000 0.000 0.000 1.000; > --------------------------------------- > INFO: no target volume specified, assuming FreeSurfer orig
volume.
> target volume orig > movable volume >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> reg file >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
> LoadVol 0 > ZeroCRAS 0 > $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ > Diagnostic Level -1 > INFO: loading target
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/orig.mgz
> Ttarg: -------------------- > -1.000 0.000 0.000 128.000; > 0.000 0.000 1.000 -128.000; > 0.000 -1.000 0.000 128.000; > 0.000 0.000 0.000 1.000; > INFO: loading movable >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> Tmov: -------------------- > -3.438 0.000 0.000 110.000; > 0.000 0.000 3.000 -60.000; > 0.000 -3.438 0.000 110.000; > 0.000 0.000 0.000 1.000; > mkheaderreg = 0, float2int = 0 > FSLOUTPUTTYPE NIFTI > fsl2TkReg: mov det = -35.4492, ref det = -1 > ---- Input registration matrix (computed) -------- > 0.995 -0.028 0.093 4.032; > -0.091 0.069 0.994 1.194; > -0.035 -0.997 0.066 0.264; > 0.000 0.000 0.000 1.000; > --------------------------------------- > ---- Input registration matrix -------- > 0.995 -0.028 0.093 4.032; > -0.091 0.069 0.994 1.194; > -0.035 -0.997 0.066 0.264; > 0.000 0.000 0.000 1.000; > subject = PT01 > RegMat --------------------------- > 0.995 -0.028 0.093 4.032; > -0.091 0.069 0.994 1.194; > -0.035 -0.997 0.066 0.264; > 0.000 0.000 0.000 1.000; > register: file >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
> written > (standard_in) 1: illegal character: P > (standard_in) 1: illegal character: T > > Started at Mon Jan 12 14:08:57 CST 2009 > Ended at Mon Jan 12 14:09:24 CST 2009 > > fslregister Done > > To check results, run: > tkregister2 --mov >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
> --surf orig > > tkregister2_cmdl --targ > /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz --mov >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> --fslreg >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/example_func2standard.mat
> --reg >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2exf.register.dat
> --noedit > ---- FSL registration matrix -------- > 1.122 0.029 0.006 -34.123; > -0.061 1.041 0.128 -3.403; > -0.010 -0.119 1.224 25.844; > 0.000 0.000 0.000 1.000; > --------------------------------------- > target volume
/net/misc/fsl/etc/standard/avg152T1_brain.nii.gz
> movable volume >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> reg file >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2exf.register.dat
> LoadVol 0 > ZeroCRAS 0 > $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ > Diagnostic Level -1 > INFO: loading target
/net/misc/fsl/etc/standard/avg152T1_brain.nii.gz
> INFO: target does not conform to COR format, so I'm going to > reslice to COR. This will not affect the final registration. > Ttarg: -------------------- > -1.000 0.000 0.000 128.000; > 0.000 0.000 1.000 -128.000; > 0.000 -1.000 0.000 128.000; > 0.000 0.000 0.000 1.000; > INFO: loading movable >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> Tmov: -------------------- > -3.438 0.000 0.000 110.000; > 0.000 0.000 3.000 -60.000; > 0.000 -3.438 0.000 110.000; > 0.000 0.000 0.000 1.000; > mkheaderreg = 0, float2int = 0 > FSLOUTPUTTYPE NIFTI_GZ > fsl2TkReg: mov det = -35.4492, ref det = -8 > ---- Input registration matrix (computed) -------- > 0.890 0.025 0.002 1.505; > -0.013 0.092 0.807 4.483; > 0.051 -0.947 0.099 3.604; > 0.000 0.000 0.000 1.000; > --------------------------------------- > ---- Input registration matrix -------- > 0.890 0.025 0.002 1.505; > -0.013 0.092 0.807 4.483; > 0.051 -0.947 0.099 3.604; > 0.000 0.000 0.000 1.000; > subject = subject-unknown > RegMat --------------------------- > 0.890 0.002 -0.025 1.505; > -0.013 0.807 -0.092 4.483; > 0.051 0.099 0.947 3.604; > 0.000 0.000 0.000 1.000; > register: file >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2exf.register.dat
> written > mri_matrix_multiply -fsl -im >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
> -iim >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/example_func2standard.mat
> -om >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2anat.fsl.mat
> ------------------------------------------------------- > tkregister2_cmdl --s PT01 --targ > /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz --mov > /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz --reg >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2std.register.dat
> --fslreg >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2anat.fsl.mat
> --noedit > ---- FSL registration matrix -------- > 0.885 -0.049 0.075 48.869; > 0.074 -0.031 -0.809 195.041; > 0.077 0.950 -0.044 18.348; > 0.000 0.000 0.000 1.000; > --------------------------------------- > target volume
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
> movable volume
/net/misc/fsl/etc/standard/avg152T1_brain.nii.gz
> reg file >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2std.register.dat
> LoadVol 0 > ZeroCRAS 0 > $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ > Diagnostic Level -1 > INFO: loading target > /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz > Ttarg: -------------------- > -1.000 0.000 0.000 128.000; > 0.000 0.000 1.000 -128.000; > 0.000 -1.000 0.000 128.000; > 0.000 0.000 0.000 1.000; > INFO: loading movable
/net/misc/fsl/etc/standard/avg152T1_brain.nii.gz
> Tmov: -------------------- > -2.000 0.000 0.000 91.000; > 0.000 0.000 2.000 -91.000; > 0.000 -2.000 0.000 109.000; > 0.000 0.000 0.000 1.000; > mkheaderreg = 0, float2int = 0 > FSLOUTPUTTYPE NIFTI_GZ > fsl2TkReg: mov det = -8, ref det = -1 > ---- Input registration matrix (computed) -------- > 1.116 -0.061 0.100 2.757; > -0.105 -0.035 1.225 -4.398; > -0.085 -1.046 -0.064 -3.213; > 0.000 0.000 0.000 1.000; > --------------------------------------- > ---- Input registration matrix -------- > 1.116 -0.061 0.100 2.757; > -0.105 -0.035 1.225 -4.398; > -0.085 -1.046 -0.064 -3.213; > 0.000 0.000 0.000 1.000; > subject = PT01 > RegMat --------------------------- > 1.116 -0.061 0.100 2.757; > -0.105 -0.035 1.225 -4.398; > -0.085 -1.046 -0.064 -3.213; > 0.000 0.000 0.000 1.000; > register: file >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2std.register.dat
> written > > To visually check your results, run: > tkregister2_cmdl --s PT01 --mov >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
> --fslreg >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
> --surf orig --tag > > > Mon Jan 12 14:09:25 CST 2009 > reg-feat2anat done > > COMMAND 3: > []$ tkregister2 --s PT01 --mov >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
>
call/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
> --fslreg >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
> --surf orig --tag --fsl >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/example_func2highres.mat
> ---- FSL registration matrix -------- > 0.995 -0.035 0.091 20.763; > 0.093 0.066 -0.994 171.738; > 0.028 0.997 0.069 11.368; > 0.000 0.000 0.000 1.000; > --------------------------------------- > surfname set to orig > ---- FSL registration matrix -------- > 1.043 -0.038 0.042 18.354; > 0.020 1.036 0.060 9.413; > -0.046 -0.068 1.128 70.358; > 0.000 0.000 0.000 1.000; > --------------------------------------- > INFO: no target volume specified, assuming FreeSurfer orig
volume.
> target volume orig > movable volume >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> reg file >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
> LoadVol 1 > ZeroCRAS 0 > $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ > Diagnostic Level -1 > INFO: loading target
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/orig.mgz
> INFO: changing target type to float > Ttarg: -------------------- > -1.000 0.000 0.000 128.000; > 0.000 0.000 1.000 -128.000; > 0.000 -1.000 0.000 128.000; > 0.000 0.000 0.000 1.000; > INFO: loading movable >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> Tmov: -------------------- > -3.438 0.000 0.000 110.000; > 0.000 0.000 3.000 -60.000; > 0.000 -3.438 0.000 110.000; > 0.000 0.000 0.000 1.000; > mkheaderreg = 0, float2int = 0 > FSLOUTPUTTYPE NIFTI_GZ > fsl2TkReg: mov det = -35.4492, ref det = -1 > ---- Input registration matrix (computed) -------- > 0.956 0.037 0.032 3.452; > -0.038 0.882 -0.059 1.969; > -0.021 0.050 0.961 1.159; > 0.000 0.000 0.000 1.000; > --------------------------------------- > ---- Input registration matrix -------- > 0.956 0.037 0.032 3.452; > -0.038 0.882 -0.059 1.969; > -0.021 0.050 0.961 1.159; > 0.000 0.000 0.000 1.000; > subject = PT01 > Reading lh surface orig > Done reading surface > Reading rh surface orig > Done reading surface > Zoom Factor = 2 > FOV = 256 > Opening window PT01 > Setting scale > Tagging mov volume > tkregister2: interface: /net/dysthymia/freesurfer/lib/tcl/tkregister2.tcl > tkregister.tcl: startup done > tkregister.tcl: default macro interface (to change:
macro,mini,micro)
> tkregister.tcl: or: setenv tkregisterinterface
{macro,mini,micro}
> % > > > > -----Original Message----- > From: Doug Greve [mailto:greve@nmr.mgh.harvard.edu] > Sent: Tue 1/6/2009 12:30 PM > To: Wang, Xin > Cc: freesurfer > Subject: Re: [Freesurfer] reg-feat2anat failed > > Hi Xin, I'm not sure what's going wrong here, I think I need
more
info.
> Can you follow the steps in > surfer.nmr.mgh.harvard.edu/fswiki/BugReporting? > > doug > > > Wang, Xin wrote: > > > hello, Freesurfer group, > > > > I try to use registration.mat files of FSL/FEAT routines,
instead of
> > anat2example_func.bat, to register the orig.mgz and > > example_func.nii.gz with the thinking that using
initial_highres in
> > FEAT may improve the reg. However, tkregister2
catastrophically
failed
> > to register two brains when I use --fsl flag. Modifying
header of
> > example_func with mri_convert does not solve the problem.
I will
> > appreciate any suggestion on using .mat file for
registration.
> > > > second question: what is the best registration of
example_func and
> > orig.mgz? In another word, what should I check besides
things
in the
> > FS tutorial when I check/modify the registration in
tkregister2? Is
> > there golden reference points I can use? > > > > Thank you in advance for any suggestion. > > > > Xin wang > > > > > > -----Original Message----- > > From: Doug Greve [mailto:greve@nmr.mgh.harvard.edu] > > Sent: Mon 12/15/2008 1:26 PM > > To: Wang, Xin > > Cc: freesurfer > > Subject: Re: [Freesurfer] reg-feat2anat failed > > > > There is a flag in the nifti header saying whether the
qform or
sform
> > are valid, and it looks like your scripts do not set this
flag.
You can > > use mri_convert (the freesurfer program). This will create
valid
files
> > that can be read into any program. > > > > doug > > > > Wang, Xin wrote: > > > > > Thank you very much for your quick reply, Dr. Greve. I
asked our
> > > institutional MRI center for correct information on
qform and
sform
> > > since the header of nifti files are created by their
scripts.
But I do > > > not know what they can do to fix this problem. I will
appreciate if
> > > you have any further suggestion on how to do the
registration
without > > > the information on qform and sform in case I can not get
them.
Does
> > > convert to ANALYZE format or manually correct in
tkregister2
work?
> > > > > > Thank you again, > > > > > > Xin > > > > > > > > > -----Original Message----- > > > From: Doug Greve [mailto:greve@nmr.mgh.harvard.edu] > > > Sent: Mon 12/15/2008 1:09 PM > > > To: Wang, Xin > > > Cc: freesurfer > > > Subject: Re: [Freesurfer] reg-feat2anat failed > > > > > > Hi Xin, the problem is that neither the sform nor the
qform are
valid. > > > Did the message below not appear when you ran tkmedit? > > > > > > WARNING: neither NIfTI-1 qform or sform are valid > > > WARNING: your volume will probably be incorrectly oriented > > > > > > Fix that, and everything will work fine. > > > > > > doug > > > > > > > > > Wang, Xin wrote: > > > > > > > Hello, Freesurfer group, > > > > I am registering the fMRI results to surface using reg-feat2anat (v > > > > 1.26.2.1 2007/08/15) and tkregister2. The automatic
registration
> > > > catastrophically failed in the subject space, but worked
fine
in the > > > > standard space. The orientations of example_func.nii.gz
in the
> subject > > > > space are flipped in any view. I use the tkmedit to
view the
> > > > example_func, and found the orientation is wrong. It
seems
> Freesurfer > > > > can not read nifti header correctly. I attach the reg-feat2anat log > > > > file and an example_func.nii.gz. > > > > I found the following message from Freesurfer email
list.
> > > > > >
http://www.mail-archive.com/freesurfer@nmr.mgh.harvard.edu/msg05573.html
> > > > Does Freesurfer have a solution for this type of
problems by
now?
> > > > > > > > Thank you in advance, > > > > > > > > Xin > > > > > > > > > >
> > > > > > > >_______________________________________________ > > > >Freesurfer mailing list > > > >Freesurfer@nmr.mgh.harvard.edu > > >
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
> > > > > > > > > > -- > > > Douglas N. Greve, Ph.D. > > > MGH-NMR Center > > > greve@nmr.mgh.harvard.edu > > > Phone Number: 617-724-2358 > > > Fax: 617-726-7422 > > > > > > In order to help us help you, please follow the steps in: > > > surfer.nmr.mgh.harvard.edu/fswiki/BugReporting > > > > > > > > > > > > > -- > > Douglas N. Greve, Ph.D. > > MGH-NMR Center > > greve@nmr.mgh.harvard.edu > > Phone Number: 617-724-2358 > > Fax: 617-726-7422 > > > > In order to help us help you, please follow the steps in: > > surfer.nmr.mgh.harvard.edu/fswiki/BugReporting > > > > > > > > -- > Douglas N. Greve, Ph.D. > MGH-NMR Center > greve@nmr.mgh.harvard.edu > Phone Number: 617-724-2358 > Fax: 617-726-7422 > > In order to help us help you, please follow the steps in: > surfer.nmr.mgh.harvard.edu/fswiki/BugReporting > > > >
an additional question about tkregister2: can I move both targ and mov together when I zoomed in to a magnified view? Thanks,
Xin
-----Original Message----- From: Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] Sent: Tue 1/13/2009 11:27 AM To: Wang, Xin Cc: analysis-bugs@nmr.mgh.harvard.edu; freesurfer Subject: Re: [Freesurfer] reg-feat2anat failed
what did you use as the highres volume in feat? If you want that reg to work, it has to be a "freesurfer anatomical volume", meaning 256^3, 1mm3
doug
Wang, Xin wrote:
Hello, Freesurfer group, I registered the example_func.nii.gz to brain.mgz in tkregister2 using FS/anat2exf.register.dat, and --fslregout fsl.feat/reg/example_func2highres.mat. I have a couple of questions.
- could anybody confirm that using--fslregout does apply .mat file
for registration based on the following information on the screen? surfname set to orig target volume PT01/mri/brain.mgz movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat LoadVol 1 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 ---- Input registration matrix -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; float2int = 0
INFO: loading target PT01/mri/brain.mgz INFO: changing target type to float Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 ---- Input registration matrix -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; subject = PT01 Reading lh surface orig Done reading surface Reading rh surface orig Done reading surface Zoom Factor = 2 FOV = 256 Opening window PT01 NVIDIA: could not open the device file /dev/nvidiactl (Permission denied). NVIDIA: Direct rendering failed; attempting indirect rendering. Setting scale Tagging mov volume tkregister2: interface: /net/dysthymia/freesurfer/lib/tcl/tkregister2.tcl tkregister.tcl: startup done tkregister.tcl: default macro interface (to change: macro,mini,micro) tkregister.tcl: or: setenv tkregisterinterface {macro,mini,micro} %
- The results are quite the same (and good) in the tkregister2 with a
slightly difference as shown below. Could anyone please tell me what these numbers mean?
with .bat file Screen: 256 257 (113,113,113), inorm = 1, mov_frame = 0 Anat: (128 126 127) ( 0.0 -1.0 2.0) 25.0000 32.7 Func: ( 31 32 21) ( 4.2 3.1 1.4) 756.0000 112.5
with .mat file Screen: 257 257 (175,175,175), inorm = 1, mov_frame = 0 Anat: (128 126 127) ( 0.0 -1.0 2.0) 25.0000 28.3 Func: ( 31 32 21) ( 4.2 3.1 1.4) 756.0000 106.2
Thanks,
Xin
-----Original Message----- From: Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] Sent: Mon 1/12/2009 4:02 PM To: Wang, Xin Cc: analysis-bugs@nmr.mgh.harvard.edu Subject: Re: [Freesurfer] reg-feat2anat failed
reg-feat2anat calls fslregister, so they should produce the same result. There is no need for an "intermediate" volume since you are registering from the subject's EPI to the subject's structure. Does the registration not look good?
Wang, Xin wrote:
Thank you, Dr. Greve. It seems work ok. what is the difference between reg-feat2anat and fslregister? although both commands are working for me, I don't think either of them serve my propose. Freesurfer does not use initial_highres to improve the reg of example_func to highres, but FSL/FEAT uses this inter-mediate step. I try to use registration.mat files of FSL/FEAT step-wise registrations to improve the reg. I think flag --fsl allow me to use a fsl.mat file as reg file. How to make it work in the way I need?
Thank you again,
Xin
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 3:29 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
when you say everything looked ok, do you mean that the orientation was correct? If so, try running this:
fslregister --s subject --mov example_func.nii.gz --reg newreg.dat
then
tkregister2 --mov example_func.nii.gz --reg newreg.dat --surfs
Wang, Xin wrote:
Sorry, Dr. Greve. I copied addtional parts after I killed the tkmedit. The following is on the screen when I saw the image.
[]$ tkmedit -f Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Reading /net/dysthymia/freesurfer/lib/tcl/tkm_common.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkm_wrappers.tcl Reading /net/dysthymia/freesurfer/lib/tcl/fsgdfPlot.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkUtils.tcl %
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 3:10 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
I don't understand. If it segfaulted how did you look at the images?
Wang, Xin wrote:
Thank you, Dr. Greve. This time tkmedit read the image, and the image looks ok to me. But following information appeared.
[]$ tkmedit -f Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Reading /net/dysthymia/freesurfer/lib/tcl/tkm_common.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkm_wrappers.tcl Reading /net/dysthymia/freesurfer/lib/tcl/fsgdfPlot.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkUtils.tcl % Killed
=================================== ERROR: A segfault has occurred. This is not your fault, : but is most likely an unrecoverable error and has : made the program unstable. : : Please send the contents of the file .xdebug_tkmedit : that should be in this directory to analysis-bugs@nmr.mgh.harvard.edu mailto:analysis-bugs@nmr.mgh.harvard.edu : : Now exiting... : []$ cat .xdebug_tkmedit tkmedit started: Mon Jan 12 15:14:52 2009 tkmedit.bin -f Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz $Id: tkmedit.c,v 1.320.2.5 2008/03/10 14:02:35 nicks Exp $ $Name: stable4 $ Set user home dir to /net/data4/CCMB08/PTSD/Thickness Set subject home dir to Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Using interface file /net/dysthymia/freesurfer/lib/tcl/tkmedit.tcl Tcl: Successfully parsed tkmedit.tcl Tcl: Successfully parsed tkm_functional.tcl Segfault Entering main loop xDebug stack (length: 2) 01: main() 01: Entering main loop 00: 00:
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 2:55 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
what is your tkmedit cmd?
It should be
tkmedit -f example_func.nii.gz
Wang, Xin wrote:
Hello, Dr. Greve, tkmedit can not open the example_func.nii.gzI attached the
header of
example_func.nii.gz (after mri_convert), and the contents of .xdebug_tkmedit file
[]$ fslhd
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
filename Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz sizeof_hdr 348 data_type FLOAT32 dim0 3 dim1 64 dim2 64 dim3 40 dim4 1 dim5 1 dim6 1 dim7 1 vox_units mm time_units s datatype 16 nbyper 4 bitpix 32 pixdim0 0.0000000000 pixdim1 3.4375000000 pixdim2 3.4375000000 pixdim3 3.0000000000 pixdim4 1.0000000000 pixdim5 1.0000000000 pixdim6 1.0000000000 pixdim7 1.0000000000 vox_offset 352 cal_max 0.0000 cal_min 0.0000 scl_slope 0.000000 scl_inter 0.000000 phase_dim 0 freq_dim 0 slice_dim 0 slice_name Unknown slice_code 0 slice_start 0 slice_end 0 slice_duration 0.000000 time_offset 0.000000 intent Unknown intent_code 0 intent_name intent_p1 0.000000 intent_p2 0.000000 intent_p3 0.000000 qform_name Scanner Anat qform_code 1 qto_xyz:1 -3.437500 0.000000 -0.000000 220.000000 qto_xyz:2 0.000000 3.437500 -0.000000 0.000000 qto_xyz:3 0.000000 0.000000 3.000000 0.000000 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 -3.437500 0.000000 0.000000 220.000000 sto_xyz:2 0.000000 3.437500 0.000000 0.000000 sto_xyz:3 0.000000 0.000000 3.000000 0.000000 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 file_type NIFTI-1+ file_code 1 descrip FreeSurfer Jun 14 2008 aux_file .xdebug_tkmedit tkmedit started: Mon Jan 12 15:05:46 2009 tkmedit.bin Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz $Id: tkmedit.c,v 1.320.2.5 2008/03/10 14:02:35 nicks Exp $ $Name: stable4 $ Set user home dir to /net/data4/CCMB08/PTSD/Thickness ERROR: Parsing arguments Subject and image not declared Fatal error in parsing command line args. Segfault Copying argv[1] xDebug stack (length: 3) 02: ParseCmdLineArgs( argc=2, argv=tkmedit.bin ) 02: Copying argv[1] 01: main() 01: Parsing command line arguments 00: 00:
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 2:38 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
If the orientation of the example func in tkmedit is wrong,
then the
reg-feat2anat is destined to fail. tkmedit (usually) reads the
nifti
header correctly. How do you know the header is right?
Wang, Xin wrote:
My problem about tkregister2 is that the flag -fsl example_func2highres.mat does not work properly. The tkregister2 catastrophically failed to register two brains. I submit the bugreport of tkregister2 (please see the COMMAND
3). The
two early steps (mri_convert and reg-feat2anat) are included for
your
references.
Thanks,
Xin
FREESURFER_HOME: /net/dysthymia/freesurfer
Build stamp: freesurfer-Linux-centos4_x86_64-stable-pub-v4.0.5
RedHat release: Red Hat Enterprise Linux Client release 5.2
(Tikanga)
Kernel info: Linux 2.6.18-92.1.1.el5 x86_64
Subject name: PT01
COMMAND 1: []$ mri_convert Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz mri_convert Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz $Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ reading from
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz...
TR=1000.00, TE=0.00, TI=0.00, flip angle=0.00 i_ras = (-1, 0, 0) j_ras = (0, 1, 0) k_ras = (0, 0, 1) writing to
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz...
COMMAND 2: []$ reg-feat2anat --feat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat
--subject PT01 FeatDir is Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat template volume is Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz log file is
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/reg-feat2anat.log
Mon Jan 12 14:08:56 CST 2009 /net/data4/CCMB08/PTSD/Thickness /net/dysthymia/freesurfer/bin/reg-feat2anat --feat Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat --subject
PT01
Linux schizo.psych.med.umich.edu 2.6.18-92.1.1.el5 #1 SMP Thu
May 22
09:01:47 EDT 2008 x86_64 x86_64 x86_64 GNU/Linux example_func ras_good_flag 1
Initializing exf2anat with header tkregister2_cmdl --targ /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.init
--fslregout
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
--regheader --noedit target volume
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.init
LoadVol 0 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 1, float2int = 0 Computing reg from header (and possibly input matrix) ---- Input registration matrix (computed) -------- 1.000 0.000 0.000 -110.507; 0.000 0.000 1.000 -41.354; 0.000 -1.000 0.000 93.531; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 1.000 0.000 0.000 -110.507; 0.000 0.000 1.000 -41.354; 0.000 -1.000 0.000 93.531; 0.000 0.000 0.000 1.000; subject = subject-unknown RegMat --------------------------- 1.000 0.000 0.000 -110.507; 0.000 0.000 1.000 -41.354; 0.000 -1.000 0.000 93.531; 0.000 0.000 0.000 1.000; register: file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.init
written FSLOUTPUTTYPE NIFTI_GZ tkreg2FSL: mov det = -35.4492, ref det = -1 fslregister --s PT01 --reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--mov
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--dof 6 --bins 256 --cost corratio --fslmat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--fsvol brainmask --maxangle 90 --initfslmat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
--tmp
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp
--out
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
Log file is
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.fslregister.log
Mon Jan 12 14:08:56 CST 2009 --s PT01 --reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--mov
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--dof 6 --bins 256 --cost corratio --fslmat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--fsvol brainmask --maxangle 90 --initfslmat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
--tmp
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp
--out
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
$Id: fslregister,v 1.16 2007/07/26 16:52:54 greve Exp $ schizo.psych.med.umich.edu Linux schizo.psych.med.umich.edu 2.6.18-92.1.1.el5 #1 SMP Thu
May 22
09:01:47 EDT 2008 x86_64 x86_64 x86_64 GNU/Linux
/net/data4/CCMB08/PTSD/Thickness mri_convert
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii
mri_convert
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii
$Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ reading from
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz...
TR=12.27, TE=5.21, TI=650.00, flip angle=9.00 i_ras = (-1, 0, 0) j_ras = (0, 0, -1) k_ras = (0, 1, 0) writing to
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii...
/net/data4/CCMB08/PTSD/Thickness mri_convert Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
--frame 0 mri_convert Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
--frame 0 $Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ reading from
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz...
TR=1000.00, TE=0.00, TI=0.00, flip angle=0.00 i_ras = (-1, 0, 0) j_ras = (0, 1, 0) k_ras = (0, 0, 1) keeping frame 0 writing to
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii...
Mon Jan 12 14:09:00 CST 2009 /net/data4/CCMB08/PTSD/Thickness bet
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
-f 0.1 Mon Jan 12 14:09:04 CST 2009 /net/data4/CCMB08/PTSD/Thickness flirt -ref
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii
-in
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
-omat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
-cost corratio -dof 6 -searchrx -90 90 -searchry -90 90
-searchrz -90
90 -init
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
-o
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii
Mon Jan 12 14:09:20 CST 2009 /net/data4/CCMB08/PTSD/Thickness mri_convert
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
mri_convert
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
$Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ reading from
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii...
TR=1000.00, TE=0.00, TI=0.00, flip angle=0.00 i_ras = (-1, 0, 0) j_ras = (0, 0, -1) k_ras = (0, 1, 0) writing to
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz...
tkregister2_cmdl --s PT01 --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--noedit ---- FSL registration matrix -------- 0.995 -0.035 0.091 20.763; 0.093 0.066 -0.994 171.738; 0.028 0.997 0.069 11.368; 0.000 0.000 0.000 1.000;
INFO: no target volume specified, assuming FreeSurfer orig
volume.
target volume orig movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
LoadVol 0 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/orig.mgz
Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 FSLOUTPUTTYPE NIFTI fsl2TkReg: mov det = -35.4492, ref det = -1 ---- Input registration matrix (computed) -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; subject = PT01 RegMat --------------------------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; register: file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
written (standard_in) 1: illegal character: P (standard_in) 1: illegal character: T
Started at Mon Jan 12 14:08:57 CST 2009 Ended at Mon Jan 12 14:09:24 CST 2009
fslregister Done
To check results, run: tkregister2 --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--surf orig
tkregister2_cmdl --targ /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz --fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/example_func2standard.mat
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2exf.register.dat
--noedit ---- FSL registration matrix -------- 1.122 0.029 0.006 -34.123; -0.061 1.041 0.128 -3.403; -0.010 -0.119 1.224 25.844; 0.000 0.000 0.000 1.000;
target volume /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2exf.register.dat
LoadVol 0 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target
/net/misc/fsl/etc/standard/avg152T1_brain.nii.gz
INFO: target does not conform to COR format, so I'm going to reslice to COR. This will not affect the final registration. Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 FSLOUTPUTTYPE NIFTI_GZ fsl2TkReg: mov det = -35.4492, ref det = -8 ---- Input registration matrix (computed) -------- 0.890 0.025 0.002 1.505; -0.013 0.092 0.807 4.483; 0.051 -0.947 0.099 3.604; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 0.890 0.025 0.002 1.505; -0.013 0.092 0.807 4.483; 0.051 -0.947 0.099 3.604; 0.000 0.000 0.000 1.000; subject = subject-unknown RegMat --------------------------- 0.890 0.002 -0.025 1.505; -0.013 0.807 -0.092 4.483; 0.051 0.099 0.947 3.604; 0.000 0.000 0.000 1.000; register: file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2exf.register.dat
written mri_matrix_multiply -fsl -im
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
-iim
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/example_func2standard.mat
-om
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2anat.fsl.mat
tkregister2_cmdl --s PT01 --targ /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz --mov /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz --reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2std.register.dat
--fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2anat.fsl.mat
--noedit ---- FSL registration matrix -------- 0.885 -0.049 0.075 48.869; 0.074 -0.031 -0.809 195.041; 0.077 0.950 -0.044 18.348; 0.000 0.000 0.000 1.000;
target volume
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
movable volume /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2std.register.dat
LoadVol 0 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable
/net/misc/fsl/etc/standard/avg152T1_brain.nii.gz
Tmov: -------------------- -2.000 0.000 0.000 91.000; 0.000 0.000 2.000 -91.000; 0.000 -2.000 0.000 109.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 FSLOUTPUTTYPE NIFTI_GZ fsl2TkReg: mov det = -8, ref det = -1 ---- Input registration matrix (computed) -------- 1.116 -0.061 0.100 2.757; -0.105 -0.035 1.225 -4.398; -0.085 -1.046 -0.064 -3.213; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 1.116 -0.061 0.100 2.757; -0.105 -0.035 1.225 -4.398; -0.085 -1.046 -0.064 -3.213; 0.000 0.000 0.000 1.000; subject = PT01 RegMat --------------------------- 1.116 -0.061 0.100 2.757; -0.105 -0.035 1.225 -4.398; -0.085 -1.046 -0.064 -3.213; 0.000 0.000 0.000 1.000; register: file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2std.register.dat
written
To visually check your results, run: tkregister2_cmdl --s PT01 --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--surf orig --tag
Mon Jan 12 14:09:25 CST 2009 reg-feat2anat done
COMMAND 3: []$ tkregister2 --s PT01 --mov Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
call/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
--fslreg
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
--surf orig --tag --fsl
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/example_func2highres.mat
---- FSL registration matrix -------- 0.995 -0.035 0.091 20.763; 0.093 0.066 -0.994 171.738; 0.028 0.997 0.069 11.368; 0.000 0.000 0.000 1.000;
surfname set to orig ---- FSL registration matrix -------- 1.043 -0.038 0.042 18.354; 0.020 1.036 0.060 9.413; -0.046 -0.068 1.128 70.358; 0.000 0.000 0.000 1.000;
INFO: no target volume specified, assuming FreeSurfer orig
volume.
target volume orig movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
LoadVol 1 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 INFO: loading target
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/orig.mgz
INFO: changing target type to float Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 FSLOUTPUTTYPE NIFTI_GZ fsl2TkReg: mov det = -35.4492, ref det = -1 ---- Input registration matrix (computed) -------- 0.956 0.037 0.032 3.452; -0.038 0.882 -0.059 1.969; -0.021 0.050 0.961 1.159; 0.000 0.000 0.000 1.000;
---- Input registration matrix -------- 0.956 0.037 0.032 3.452; -0.038 0.882 -0.059 1.969; -0.021 0.050 0.961 1.159; 0.000 0.000 0.000 1.000; subject = PT01 Reading lh surface orig Done reading surface Reading rh surface orig Done reading surface Zoom Factor = 2 FOV = 256 Opening window PT01 Setting scale Tagging mov volume tkregister2: interface:
/net/dysthymia/freesurfer/lib/tcl/tkregister2.tcl
tkregister.tcl: startup done tkregister.tcl: default macro interface (to change:
macro,mini,micro)
tkregister.tcl: or: setenv tkregisterinterface
{macro,mini,micro}
%
-----Original Message----- From: Doug Greve [mailto:greve@nmr.mgh.harvard.edu] Sent: Tue 1/6/2009 12:30 PM To: Wang, Xin Cc: freesurfer Subject: Re: [Freesurfer] reg-feat2anat failed
Hi Xin, I'm not sure what's going wrong here, I think I need
more
info.
Can you follow the steps in surfer.nmr.mgh.harvard.edu/fswiki/BugReporting?
doug
Wang, Xin wrote:
> hello, Freesurfer group, > > I try to use registration.mat files of FSL/FEAT routines,
instead of
> anat2example_func.bat, to register the orig.mgz and > example_func.nii.gz with the thinking that using
initial_highres in
> FEAT may improve the reg. However, tkregister2
catastrophically
failed
> to register two brains when I use --fsl flag. Modifying
header of
> example_func with mri_convert does not solve the problem.
I will
> appreciate any suggestion on using .mat file for registration. > > second question: what is the best registration of
example_func and
> orig.mgz? In another word, what should I check besides things
in the
> FS tutorial when I check/modify the registration in
tkregister2? Is
> there golden reference points I can use? > > Thank you in advance for any suggestion. > > Xin wang > > > -----Original Message----- > From: Doug Greve [mailto:greve@nmr.mgh.harvard.edu] > Sent: Mon 12/15/2008 1:26 PM > To: Wang, Xin > Cc: freesurfer > Subject: Re: [Freesurfer] reg-feat2anat failed > > There is a flag in the nifti header saying whether the
qform or
sform
> are valid, and it looks like your scripts do not set this
flag.
You can
> use mri_convert (the freesurfer program). This will create
valid
files
> that can be read into any program. > > doug > > Wang, Xin wrote: > > > Thank you very much for your quick reply, Dr. Greve. I
asked our
> > institutional MRI center for correct information on
qform and
sform
> > since the header of nifti files are created by their
scripts.
But I do
> > not know what they can do to fix this problem. I will
appreciate if
> > you have any further suggestion on how to do the
registration
without
> > the information on qform and sform in case I can not get
them.
Does
> > convert to ANALYZE format or manually correct in tkregister2
work?
> > > > Thank you again, > > > > Xin > > > > > > -----Original Message----- > > From: Doug Greve [mailto:greve@nmr.mgh.harvard.edu] > > Sent: Mon 12/15/2008 1:09 PM > > To: Wang, Xin > > Cc: freesurfer > > Subject: Re: [Freesurfer] reg-feat2anat failed > > > > Hi Xin, the problem is that neither the sform nor the
qform are
valid.
> > Did the message below not appear when you ran tkmedit? > > > > WARNING: neither NIfTI-1 qform or sform are valid > > WARNING: your volume will probably be incorrectly oriented > > > > Fix that, and everything will work fine. > > > > doug > > > > > > Wang, Xin wrote: > > > > > Hello, Freesurfer group, > > > I am registering the fMRI results to surface using
reg-feat2anat (v
> > > 1.26.2.1 2007/08/15) and tkregister2. The automatic
registration
> > > catastrophically failed in the subject space, but worked
fine
in the
> > > standard space. The orientations of example_func.nii.gz
in the
subject > > > space are flipped in any view. I use the tkmedit to
view the
> > > example_func, and found the orientation is wrong. It seems Freesurfer > > > can not read nifti header correctly. I attach the
reg-feat2anat log
> > > file and an example_func.nii.gz. > > > I found the following message from Freesurfer email list. > > > >
http://www.mail-archive.com/freesurfer@nmr.mgh.harvard.edu/msg05573.html
> > > Does Freesurfer have a solution for this type of
problems by
now?
> > > > > > Thank you in advance, > > > > > > Xin > > > > > >
> > > > > >_______________________________________________ > > >Freesurfer mailing list > > >Freesurfer@nmr.mgh.harvard.edu > >
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
> > > > > > > -- > > Douglas N. Greve, Ph.D. > > MGH-NMR Center > > greve@nmr.mgh.harvard.edu > > Phone Number: 617-724-2358 > > Fax: 617-726-7422 > > > > In order to help us help you, please follow the steps in: > > surfer.nmr.mgh.harvard.edu/fswiki/BugReporting > > > > > > > > -- > Douglas N. Greve, Ph.D. > MGH-NMR Center > greve@nmr.mgh.harvard.edu > Phone Number: 617-724-2358 > Fax: 617-726-7422 > > In order to help us help you, please follow the steps in: > surfer.nmr.mgh.harvard.edu/fswiki/BugReporting > > >
-- Douglas N. Greve, Ph.D. MGH-NMR Center greve@nmr.mgh.harvard.edu Phone Number: 617-724-2358 Fax: 617-726-7422
In order to help us help you, please follow the steps in: surfer.nmr.mgh.harvard.edu/fswiki/BugReporting
yes, though you might have to click on the iamge window
Wang, Xin wrote:
an additional question about tkregister2: can I move both targ and mov together when I zoomed in to a magnified view? Thanks,
Xin
-----Original Message----- From: Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] Sent: Tue 1/13/2009 11:27 AM To: Wang, Xin Cc: analysis-bugs@nmr.mgh.harvard.edu; freesurfer Subject: Re: [Freesurfer] reg-feat2anat failed
what did you use as the highres volume in feat? If you want that reg to work, it has to be a "freesurfer anatomical volume", meaning 256^3, 1mm3
doug
Wang, Xin wrote:
Hello, Freesurfer group, I registered the example_func.nii.gz to brain.mgz in tkregister2 using FS/anat2exf.register.dat, and --fslregout fsl.feat/reg/example_func2highres.mat. I have a couple of questions.
- could anybody confirm that using--fslregout does apply .mat file
for registration based on the following information on the screen? surfname set to orig target volume PT01/mri/brain.mgz movable volume Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz reg file
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
LoadVol 1 ZeroCRAS 0 $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ Diagnostic Level -1 ---- Input registration matrix -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; float2int = 0
INFO: loading target PT01/mri/brain.mgz INFO: changing target type to float Ttarg: -------------------- -1.000 0.000 0.000 128.000; 0.000 0.000 1.000 -128.000; 0.000 -1.000 0.000 128.000; 0.000 0.000 0.000 1.000; INFO: loading movable Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Tmov: -------------------- -3.438 0.000 0.000 110.000; 0.000 0.000 3.000 -60.000; 0.000 -3.438 0.000 110.000; 0.000 0.000 0.000 1.000; mkheaderreg = 0, float2int = 0 ---- Input registration matrix -------- 0.995 -0.028 0.093 4.032; -0.091 0.069 0.994 1.194; -0.035 -0.997 0.066 0.264; 0.000 0.000 0.000 1.000; subject = PT01 Reading lh surface orig Done reading surface Reading rh surface orig Done reading surface Zoom Factor = 2 FOV = 256 Opening window PT01 NVIDIA: could not open the device file /dev/nvidiactl (Permission
denied).
NVIDIA: Direct rendering failed; attempting indirect rendering. Setting scale Tagging mov volume tkregister2: interface:
/net/dysthymia/freesurfer/lib/tcl/tkregister2.tcl
tkregister.tcl: startup done tkregister.tcl: default macro interface (to change: macro,mini,micro) tkregister.tcl: or: setenv tkregisterinterface {macro,mini,micro} %
- The results are quite the same (and good) in the tkregister2 with a
slightly difference as shown below. Could anyone please tell me what these numbers mean?
with .bat file Screen: 256 257 (113,113,113), inorm = 1, mov_frame = 0 Anat: (128 126 127) ( 0.0 -1.0 2.0) 25.0000 32.7 Func: ( 31 32 21) ( 4.2 3.1 1.4) 756.0000 112.5
with .mat file Screen: 257 257 (175,175,175), inorm = 1, mov_frame = 0 Anat: (128 126 127) ( 0.0 -1.0 2.0) 25.0000 28.3 Func: ( 31 32 21) ( 4.2 3.1 1.4) 756.0000 106.2
Thanks,
Xin
-----Original Message----- From: Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] Sent: Mon 1/12/2009 4:02 PM To: Wang, Xin Cc: analysis-bugs@nmr.mgh.harvard.edu Subject: Re: [Freesurfer] reg-feat2anat failed
reg-feat2anat calls fslregister, so they should produce the same result. There is no need for an "intermediate" volume since you are registering from the subject's EPI to the subject's structure. Does the registration not look good?
Wang, Xin wrote:
Thank you, Dr. Greve. It seems work ok. what is the difference between reg-feat2anat and fslregister? although both commands are working for me, I don't think either of them serve my propose. Freesurfer does not use initial_highres to improve the reg of example_func to highres, but FSL/FEAT uses this inter-mediate step. I try to use registration.mat files of FSL/FEAT step-wise registrations to improve the reg. I think flag --fsl allow me to use a fsl.mat file as reg file. How to make it work in the way I need?
Thank you again,
Xin
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 3:29 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
when you say everything looked ok, do you mean that the
orientation was
correct? If so, try running this:
fslregister --s subject --mov example_func.nii.gz --reg newreg.dat
then
tkregister2 --mov example_func.nii.gz --reg newreg.dat --surfs
Wang, Xin wrote:
Sorry, Dr. Greve. I copied addtional parts after I killed the tkmedit. The following is on the screen when I saw the image.
[]$ tkmedit -f Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Reading /net/dysthymia/freesurfer/lib/tcl/tkm_common.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkm_wrappers.tcl Reading /net/dysthymia/freesurfer/lib/tcl/fsgdfPlot.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkUtils.tcl %
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 3:10 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
I don't understand. If it segfaulted how did you look at the images?
Wang, Xin wrote:
Thank you, Dr. Greve. This time tkmedit read the image, and the image looks ok to
me. But
following information appeared.
[]$ tkmedit -f Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Reading /net/dysthymia/freesurfer/lib/tcl/tkm_common.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkm_wrappers.tcl Reading /net/dysthymia/freesurfer/lib/tcl/fsgdfPlot.tcl Reading /net/dysthymia/freesurfer/lib/tcl/tkUtils.tcl % Killed
=================================== ERROR: A segfault has occurred. This is not your fault, : but is most likely an unrecoverable error and has : made the program unstable. : : Please send the contents of the file .xdebug_tkmedit : that should be in this directory to analysis-bugs@nmr.mgh.harvard.edu mailto:analysis-bugs@nmr.mgh.harvard.edu : : Now exiting... : []$ cat .xdebug_tkmedit tkmedit started: Mon Jan 12 15:14:52 2009 tkmedit.bin -f Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz $Id: tkmedit.c,v 1.320.2.5 2008/03/10 14:02:35 nicks Exp $ $Name: stable4 $ Set user home dir to /net/data4/CCMB08/PTSD/Thickness Set subject home dir to Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz Using interface file /net/dysthymia/freesurfer/lib/tcl/tkmedit.tcl Tcl: Successfully parsed tkmedit.tcl Tcl: Successfully parsed tkm_functional.tcl Segfault Entering main loop xDebug stack (length: 2) 01: main() 01: Entering main loop 00: 00:
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 2:55 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
what is your tkmedit cmd?
It should be
tkmedit -f example_func.nii.gz
Wang, Xin wrote:
Hello, Dr. Greve, tkmedit can not open the example_func.nii.gzI attached the
header of
example_func.nii.gz (after mri_convert), and the contents of .xdebug_tkmedit file
[]$ fslhd
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
filename Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz sizeof_hdr 348 data_type FLOAT32 dim0 3 dim1 64 dim2 64 dim3 40 dim4 1 dim5 1 dim6 1 dim7 1 vox_units mm time_units s datatype 16 nbyper 4 bitpix 32 pixdim0 0.0000000000 pixdim1 3.4375000000 pixdim2 3.4375000000 pixdim3 3.0000000000 pixdim4 1.0000000000 pixdim5 1.0000000000 pixdim6 1.0000000000 pixdim7 1.0000000000 vox_offset 352 cal_max 0.0000 cal_min 0.0000 scl_slope 0.000000 scl_inter 0.000000 phase_dim 0 freq_dim 0 slice_dim 0 slice_name Unknown slice_code 0 slice_start 0 slice_end 0 slice_duration 0.000000 time_offset 0.000000 intent Unknown intent_code 0 intent_name intent_p1 0.000000 intent_p2 0.000000 intent_p3 0.000000 qform_name Scanner Anat qform_code 1 qto_xyz:1 -3.437500 0.000000 -0.000000 220.000000 qto_xyz:2 0.000000 3.437500 -0.000000 0.000000 qto_xyz:3 0.000000 0.000000 3.000000 0.000000 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 -3.437500 0.000000 0.000000 220.000000 sto_xyz:2 0.000000 3.437500 0.000000 0.000000 sto_xyz:3 0.000000 0.000000 3.000000 0.000000 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 file_type NIFTI-1+ file_code 1 descrip FreeSurfer Jun 14 2008 aux_file .xdebug_tkmedit tkmedit started: Mon Jan 12 15:05:46 2009 tkmedit.bin Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz $Id: tkmedit.c,v 1.320.2.5 2008/03/10 14:02:35 nicks Exp $
$Name:
stable4 $ Set user home dir to /net/data4/CCMB08/PTSD/Thickness ERROR: Parsing arguments Subject and image not declared Fatal error in parsing command line args. Segfault Copying argv[1] xDebug stack (length: 3) 02: ParseCmdLineArgs( argc=2, argv=tkmedit.bin ) 02: Copying argv[1] 01: main() 01: Parsing command line arguments 00: 00:
*From:* Douglas N Greve [mailto:greve@nmr.mgh.harvard.edu] *Sent:* Mon 1/12/2009 2:38 PM *To:* Wang, Xin *Cc:* analysis-bugs@nmr.mgh.harvard.edu *Subject:* Re: [Freesurfer] reg-feat2anat failed
If the orientation of the example func in tkmedit is wrong,
then the
reg-feat2anat is destined to fail. tkmedit (usually) reads the
nifti
header correctly. How do you know the header is right?
Wang, Xin wrote: > > My problem about tkregister2 is that the flag -fsl > example_func2highres.mat does not work properly. The
tkregister2
> catastrophically failed to register two brains. > I submit the bugreport of tkregister2 (please see the COMMAND
3). The
> two early steps (mri_convert and reg-feat2anat) are
included for
your
> references. > > Thanks, > > Xin > >
> > FREESURFER_HOME: /net/dysthymia/freesurfer > > Build stamp: freesurfer-Linux-centos4_x86_64-stable-pub-v4.0.5 > > RedHat release: Red Hat Enterprise Linux Client release 5.2
(Tikanga)
> > Kernel info: Linux 2.6.18-92.1.1.el5 x86_64 > >
> Subject name: PT01 > > COMMAND 1: > []$ mri_convert >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> mri_convert >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> $Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ > reading from >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz...
> TR=1000.00, TE=0.00, TI=0.00, flip angle=0.00 > i_ras = (-1, 0, 0) > j_ras = (0, 1, 0) > k_ras = (0, 0, 1) > writing to >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz...
> > COMMAND 2: > []$ reg-feat2anat --feat
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat
> --subject PT01 > FeatDir is Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat > template volume is >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> log file is >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/reg-feat2anat.log
> Mon Jan 12 14:08:56 CST 2009 > /net/data4/CCMB08/PTSD/Thickness > /net/dysthymia/freesurfer/bin/reg-feat2anat > --feat Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat --subject
PT01
> Linux schizo.psych.med.umich.edu 2.6.18-92.1.1.el5 #1 SMP Thu
May 22
> 09:01:47 EDT 2008 x86_64 x86_64 x86_64 GNU/Linux > example_func ras_good_flag 1 > ------------------------------------------------------- > Initializing exf2anat with header > tkregister2_cmdl --targ > /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz --mov >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.init
> --fslregout >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
> --regheader --noedit > target volume
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
> movable volume >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> reg file >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.init
> LoadVol 0 > ZeroCRAS 0 > $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ > Diagnostic Level -1 > INFO: loading target > /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz > Ttarg: -------------------- > -1.000 0.000 0.000 128.000; > 0.000 0.000 1.000 -128.000; > 0.000 -1.000 0.000 128.000; > 0.000 0.000 0.000 1.000; > INFO: loading movable >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> Tmov: -------------------- > -3.438 0.000 0.000 110.000; > 0.000 0.000 3.000 -60.000; > 0.000 -3.438 0.000 110.000; > 0.000 0.000 0.000 1.000; > mkheaderreg = 1, float2int = 0 > Computing reg from header (and possibly input matrix) > ---- Input registration matrix (computed) -------- > 1.000 0.000 0.000 -110.507; > 0.000 0.000 1.000 -41.354; > 0.000 -1.000 0.000 93.531; > 0.000 0.000 0.000 1.000; > --------------------------------------- > ---- Input registration matrix -------- > 1.000 0.000 0.000 -110.507; > 0.000 0.000 1.000 -41.354; > 0.000 -1.000 0.000 93.531; > 0.000 0.000 0.000 1.000; > subject = subject-unknown > RegMat --------------------------- > 1.000 0.000 0.000 -110.507; > 0.000 0.000 1.000 -41.354; > 0.000 -1.000 0.000 93.531; > 0.000 0.000 0.000 1.000; > register: file >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.init
> written > FSLOUTPUTTYPE NIFTI_GZ > tkreg2FSL: mov det = -35.4492, ref det = -1 > fslregister --s PT01 --reg >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
> --mov
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> --dof 6 --bins 256 --cost corratio --fslmat >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
> --fsvol brainmask --maxangle 90 --initfslmat >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
> --tmp
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp
> --out >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
> > Log file is >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat.fslregister.log
> > Mon Jan 12 14:08:56 CST 2009 > --s PT01 --reg >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
> --mov
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> --dof 6 --bins 256 --cost corratio --fslmat >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
> --fsvol brainmask --maxangle 90 --initfslmat >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
> --tmp
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp
> --out >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
> $Id: fslregister,v 1.16 2007/07/26 16:52:54 greve Exp $ > schizo.psych.med.umich.edu > Linux schizo.psych.med.umich.edu 2.6.18-92.1.1.el5 #1 SMP Thu
May 22
> 09:01:47 EDT 2008 x86_64 x86_64 x86_64 GNU/Linux > -------------------------------------- > /net/data4/CCMB08/PTSD/Thickness > mri_convert
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii
> mri_convert
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii
> $Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ > reading from
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz...
> TR=12.27, TE=5.21, TI=650.00, flip angle=9.00 > i_ras = (-1, 0, 0) > j_ras = (0, 0, -1) > k_ras = (0, 1, 0) > writing to >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii...
> -------------------------------------- > /net/data4/CCMB08/PTSD/Thickness > mri_convert >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
> --frame 0 > mri_convert >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
> --frame 0 > $Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ > reading from >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz...
> TR=1000.00, TE=0.00, TI=0.00, flip angle=0.00 > i_ras = (-1, 0, 0) > j_ras = (0, 1, 0) > k_ras = (0, 0, 1) > keeping frame 0 > writing to >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii...
> Mon Jan 12 14:09:00 CST 2009 > /net/data4/CCMB08/PTSD/Thickness > bet >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
> -f 0.1 > Mon Jan 12 14:09:04 CST 2009 > /net/data4/CCMB08/PTSD/Thickness > flirt -ref >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/refvol.fslregister.nii
> -in >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/movvol.fslregister.nii
> -omat >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
> -cost corratio -dof 6 -searchrx -90 90 -searchry -90 90
-searchrz -90
> 90 -init >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.init.fsl.mat
> -o >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii
> Mon Jan 12 14:09:20 CST 2009 > /net/data4/CCMB08/PTSD/Thickness > mri_convert >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
> mri_convert >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz
> $Id: mri_convert.c,v 1.146.2.2 2008/03/02 02:53:20 nicks Exp $ > reading from >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/outvol.fslregister.nii...
> TR=1000.00, TE=0.00, TI=0.00, flip angle=0.00 > i_ras = (-1, 0, 0) > j_ras = (0, 0, -1) > k_ras = (0, 1, 0) > writing to >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/tmp/exf-in-anat.nii.gz...
> tkregister2_cmdl --s PT01 --mov >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
> --fslreg >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
> --noedit > ---- FSL registration matrix -------- > 0.995 -0.035 0.091 20.763; > 0.093 0.066 -0.994 171.738; > 0.028 0.997 0.069 11.368; > 0.000 0.000 0.000 1.000; > --------------------------------------- > INFO: no target volume specified, assuming FreeSurfer orig
volume.
> target volume orig > movable volume >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> reg file >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
> LoadVol 0 > ZeroCRAS 0 > $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ > Diagnostic Level -1 > INFO: loading target
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/orig.mgz
> Ttarg: -------------------- > -1.000 0.000 0.000 128.000; > 0.000 0.000 1.000 -128.000; > 0.000 -1.000 0.000 128.000; > 0.000 0.000 0.000 1.000; > INFO: loading movable >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> Tmov: -------------------- > -3.438 0.000 0.000 110.000; > 0.000 0.000 3.000 -60.000; > 0.000 -3.438 0.000 110.000; > 0.000 0.000 0.000 1.000; > mkheaderreg = 0, float2int = 0 > FSLOUTPUTTYPE NIFTI > fsl2TkReg: mov det = -35.4492, ref det = -1 > ---- Input registration matrix (computed) -------- > 0.995 -0.028 0.093 4.032; > -0.091 0.069 0.994 1.194; > -0.035 -0.997 0.066 0.264; > 0.000 0.000 0.000 1.000; > --------------------------------------- > ---- Input registration matrix -------- > 0.995 -0.028 0.093 4.032; > -0.091 0.069 0.994 1.194; > -0.035 -0.997 0.066 0.264; > 0.000 0.000 0.000 1.000; > subject = PT01 > RegMat --------------------------- > 0.995 -0.028 0.093 4.032; > -0.091 0.069 0.994 1.194; > -0.035 -0.997 0.066 0.264; > 0.000 0.000 0.000 1.000; > register: file >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
> written > (standard_in) 1: illegal character: P > (standard_in) 1: illegal character: T > > Started at Mon Jan 12 14:08:57 CST 2009 > Ended at Mon Jan 12 14:09:24 CST 2009 > > fslregister Done > > To check results, run: > tkregister2 --mov >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
> --surf orig > > tkregister2_cmdl --targ > /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz --mov >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> --fslreg >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/example_func2standard.mat
> --reg >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2exf.register.dat
> --noedit > ---- FSL registration matrix -------- > 1.122 0.029 0.006 -34.123; > -0.061 1.041 0.128 -3.403; > -0.010 -0.119 1.224 25.844; > 0.000 0.000 0.000 1.000; > --------------------------------------- > target volume
/net/misc/fsl/etc/standard/avg152T1_brain.nii.gz
> movable volume >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> reg file >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2exf.register.dat
> LoadVol 0 > ZeroCRAS 0 > $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ > Diagnostic Level -1 > INFO: loading target
/net/misc/fsl/etc/standard/avg152T1_brain.nii.gz
> INFO: target does not conform to COR format, so I'm going to > reslice to COR. This will not affect the final registration. > Ttarg: -------------------- > -1.000 0.000 0.000 128.000; > 0.000 0.000 1.000 -128.000; > 0.000 -1.000 0.000 128.000; > 0.000 0.000 0.000 1.000; > INFO: loading movable >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> Tmov: -------------------- > -3.438 0.000 0.000 110.000; > 0.000 0.000 3.000 -60.000; > 0.000 -3.438 0.000 110.000; > 0.000 0.000 0.000 1.000; > mkheaderreg = 0, float2int = 0 > FSLOUTPUTTYPE NIFTI_GZ > fsl2TkReg: mov det = -35.4492, ref det = -8 > ---- Input registration matrix (computed) -------- > 0.890 0.025 0.002 1.505; > -0.013 0.092 0.807 4.483; > 0.051 -0.947 0.099 3.604; > 0.000 0.000 0.000 1.000; > --------------------------------------- > ---- Input registration matrix -------- > 0.890 0.025 0.002 1.505; > -0.013 0.092 0.807 4.483; > 0.051 -0.947 0.099 3.604; > 0.000 0.000 0.000 1.000; > subject = subject-unknown > RegMat --------------------------- > 0.890 0.002 -0.025 1.505; > -0.013 0.807 -0.092 4.483; > 0.051 0.099 0.947 3.604; > 0.000 0.000 0.000 1.000; > register: file >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2exf.register.dat
> written > mri_matrix_multiply -fsl -im >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
> -iim >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/example_func2standard.mat
> -om >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2anat.fsl.mat
> ------------------------------------------------------- > tkregister2_cmdl --s PT01 --targ > /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz --mov > /net/misc/fsl/etc/standard/avg152T1_brain.nii.gz --reg >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2std.register.dat
> --fslreg >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/std2anat.fsl.mat
> --noedit > ---- FSL registration matrix -------- > 0.885 -0.049 0.075 48.869; > 0.074 -0.031 -0.809 195.041; > 0.077 0.950 -0.044 18.348; > 0.000 0.000 0.000 1.000; > --------------------------------------- > target volume
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz
> movable volume
/net/misc/fsl/etc/standard/avg152T1_brain.nii.gz
> reg file >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2std.register.dat
> LoadVol 0 > ZeroCRAS 0 > $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ > Diagnostic Level -1 > INFO: loading target > /net/data4/CCMB08/PTSD/Thickness/PT01/mri/brainmask.mgz > Ttarg: -------------------- > -1.000 0.000 0.000 128.000; > 0.000 0.000 1.000 -128.000; > 0.000 -1.000 0.000 128.000; > 0.000 0.000 0.000 1.000; > INFO: loading movable
/net/misc/fsl/etc/standard/avg152T1_brain.nii.gz
> Tmov: -------------------- > -2.000 0.000 0.000 91.000; > 0.000 0.000 2.000 -91.000; > 0.000 -2.000 0.000 109.000; > 0.000 0.000 0.000 1.000; > mkheaderreg = 0, float2int = 0 > FSLOUTPUTTYPE NIFTI_GZ > fsl2TkReg: mov det = -8, ref det = -1 > ---- Input registration matrix (computed) -------- > 1.116 -0.061 0.100 2.757; > -0.105 -0.035 1.225 -4.398; > -0.085 -1.046 -0.064 -3.213; > 0.000 0.000 0.000 1.000; > --------------------------------------- > ---- Input registration matrix -------- > 1.116 -0.061 0.100 2.757; > -0.105 -0.035 1.225 -4.398; > -0.085 -1.046 -0.064 -3.213; > 0.000 0.000 0.000 1.000; > subject = PT01 > RegMat --------------------------- > 1.116 -0.061 0.100 2.757; > -0.105 -0.035 1.225 -4.398; > -0.085 -1.046 -0.064 -3.213; > 0.000 0.000 0.000 1.000; > register: file >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2std.register.dat
> written > > To visually check your results, run: > tkregister2_cmdl --s PT01 --mov >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
>
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
> --fslreg >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
> --surf orig --tag > > > Mon Jan 12 14:09:25 CST 2009 > reg-feat2anat done > > COMMAND 3: > []$ tkregister2 --s PT01 --mov >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
--reg
>
call/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
> --fslreg >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/exf2anat.fsl.mat
> --surf orig --tag --fsl >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/example_func2highres.mat
> ---- FSL registration matrix -------- > 0.995 -0.035 0.091 20.763; > 0.093 0.066 -0.994 171.738; > 0.028 0.997 0.069 11.368; > 0.000 0.000 0.000 1.000; > --------------------------------------- > surfname set to orig > ---- FSL registration matrix -------- > 1.043 -0.038 0.042 18.354; > 0.020 1.036 0.060 9.413; > -0.046 -0.068 1.128 70.358; > 0.000 0.000 0.000 1.000; > --------------------------------------- > INFO: no target volume specified, assuming FreeSurfer orig
volume.
> target volume orig > movable volume >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> reg file >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/reg/freesurfer/anat2exf.register.dat
> LoadVol 1 > ZeroCRAS 0 > $Id: tkregister2.c,v 1.86.2.2 2008/03/10 14:02:35 nicks Exp $ > Diagnostic Level -1 > INFO: loading target
/net/data4/CCMB08/PTSD/Thickness/PT01/mri/orig.mgz
> INFO: changing target type to float > Ttarg: -------------------- > -1.000 0.000 0.000 128.000; > 0.000 0.000 1.000 -128.000; > 0.000 -1.000 0.000 128.000; > 0.000 0.000 0.000 1.000; > INFO: loading movable >
Recall/SM5DF1212/PT01_Recall_SM5DF1212.feat/example_func.nii.gz
> Tmov: -------------------- > -3.438 0.000 0.000 110.000; > 0.000 0.000 3.000 -60.000; > 0.000 -3.438 0.000 110.000; > 0.000 0.000 0.000 1.000; > mkheaderreg = 0, float2int = 0 > FSLOUTPUTTYPE NIFTI_GZ > fsl2TkReg: mov det = -35.4492, ref det = -1 > ---- Input registration matrix (computed) -------- > 0.956 0.037 0.032 3.452; > -0.038 0.882 -0.059 1.969; > -0.021 0.050 0.961 1.159; > 0.000 0.000 0.000 1.000; > --------------------------------------- > ---- Input registration matrix -------- > 0.956 0.037 0.032 3.452; > -0.038 0.882 -0.059 1.969; > -0.021 0.050 0.961 1.159; > 0.000 0.000 0.000 1.000; > subject = PT01 > Reading lh surface orig > Done reading surface > Reading rh surface orig > Done reading surface > Zoom Factor = 2 > FOV = 256 > Opening window PT01 > Setting scale > Tagging mov volume > tkregister2: interface: /net/dysthymia/freesurfer/lib/tcl/tkregister2.tcl > tkregister.tcl: startup done > tkregister.tcl: default macro interface (to change:
macro,mini,micro)
> tkregister.tcl: or: setenv tkregisterinterface
{macro,mini,micro}
> % > > > > -----Original Message----- > From: Doug Greve [mailto:greve@nmr.mgh.harvard.edu] > Sent: Tue 1/6/2009 12:30 PM > To: Wang, Xin > Cc: freesurfer > Subject: Re: [Freesurfer] reg-feat2anat failed > > Hi Xin, I'm not sure what's going wrong here, I think I need
more
info.
> Can you follow the steps in > surfer.nmr.mgh.harvard.edu/fswiki/BugReporting? > > doug > > > Wang, Xin wrote: > > > hello, Freesurfer group, > > > > I try to use registration.mat files of FSL/FEAT routines,
instead of
> > anat2example_func.bat, to register the orig.mgz and > > example_func.nii.gz with the thinking that using
initial_highres in
> > FEAT may improve the reg. However, tkregister2
catastrophically
failed
> > to register two brains when I use --fsl flag. Modifying
header of
> > example_func with mri_convert does not solve the problem.
I will
> > appreciate any suggestion on using .mat file for
registration.
> > > > second question: what is the best registration of
example_func and
> > orig.mgz? In another word, what should I check besides
things
in the
> > FS tutorial when I check/modify the registration in
tkregister2? Is
> > there golden reference points I can use? > > > > Thank you in advance for any suggestion. > > > > Xin wang > > > > > > -----Original Message----- > > From: Doug Greve [mailto:greve@nmr.mgh.harvard.edu] > > Sent: Mon 12/15/2008 1:26 PM > > To: Wang, Xin > > Cc: freesurfer > > Subject: Re: [Freesurfer] reg-feat2anat failed > > > > There is a flag in the nifti header saying whether the
qform or
sform
> > are valid, and it looks like your scripts do not set this
flag.
You can > > use mri_convert (the freesurfer program). This will create
valid
files
> > that can be read into any program. > > > > doug > > > > Wang, Xin wrote: > > > > > Thank you very much for your quick reply, Dr. Greve. I
asked our
> > > institutional MRI center for correct information on
qform and
sform
> > > since the header of nifti files are created by their
scripts.
But I do > > > not know what they can do to fix this problem. I will
appreciate if
> > > you have any further suggestion on how to do the
registration
without > > > the information on qform and sform in case I can not get
them.
Does
> > > convert to ANALYZE format or manually correct in
tkregister2
work?
> > > > > > Thank you again, > > > > > > Xin > > > > > > > > > -----Original Message----- > > > From: Doug Greve [mailto:greve@nmr.mgh.harvard.edu] > > > Sent: Mon 12/15/2008 1:09 PM > > > To: Wang, Xin > > > Cc: freesurfer > > > Subject: Re: [Freesurfer] reg-feat2anat failed > > > > > > Hi Xin, the problem is that neither the sform nor the
qform are
valid. > > > Did the message below not appear when you ran tkmedit? > > > > > > WARNING: neither NIfTI-1 qform or sform are valid > > > WARNING: your volume will probably be incorrectly oriented > > > > > > Fix that, and everything will work fine. > > > > > > doug > > > > > > > > > Wang, Xin wrote: > > > > > > > Hello, Freesurfer group, > > > > I am registering the fMRI results to surface using reg-feat2anat (v > > > > 1.26.2.1 2007/08/15) and tkregister2. The automatic
registration
> > > > catastrophically failed in the subject space, but worked
fine
in the > > > > standard space. The orientations of example_func.nii.gz
in the
> subject > > > > space are flipped in any view. I use the tkmedit to
view the
> > > > example_func, and found the orientation is wrong. It
seems
> Freesurfer > > > > can not read nifti header correctly. I attach the reg-feat2anat log > > > > file and an example_func.nii.gz. > > > > I found the following message from Freesurfer email
list.
> > > > > >
http://www.mail-archive.com/freesurfer@nmr.mgh.harvard.edu/msg05573.html
> > > > Does Freesurfer have a solution for this type of
problems by
now?
> > > > > > > > Thank you in advance, > > > > > > > > Xin > > > > > > > > > >
> > > > > > > >_______________________________________________ > > > >Freesurfer mailing list > > > >Freesurfer@nmr.mgh.harvard.edu > > >
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
> > > > > > > > > > -- > > > Douglas N. Greve, Ph.D. > > > MGH-NMR Center > > > greve@nmr.mgh.harvard.edu > > > Phone Number: 617-724-2358 > > > Fax: 617-726-7422 > > > > > > In order to help us help you, please follow the steps in: > > > surfer.nmr.mgh.harvard.edu/fswiki/BugReporting > > > > > > > > > > > > > -- > > Douglas N. Greve, Ph.D. > > MGH-NMR Center > > greve@nmr.mgh.harvard.edu > > Phone Number: 617-724-2358 > > Fax: 617-726-7422 > > > > In order to help us help you, please follow the steps in: > > surfer.nmr.mgh.harvard.edu/fswiki/BugReporting > > > > > > > > -- > Douglas N. Greve, Ph.D. > MGH-NMR Center > greve@nmr.mgh.harvard.edu > Phone Number: 617-724-2358 > Fax: 617-726-7422 > > In order to help us help you, please follow the steps in: > surfer.nmr.mgh.harvard.edu/fswiki/BugReporting > > > >
freesurfer@nmr.mgh.harvard.edu