Hi David - Thank you very much for your kind words.
Does the DWI volume for this subject have 65 frames (as many as the entries in bvecs/bvals)? You can check this by running: mri_info dmri/dwi.nii.gz
a.y
On Fri, 16 Aug 2013, David Soto wrote:
hi Anastasia, I am pleased that trac-all has completed and the output looks pretty cool so thanks for this amazing piece of software! Just an issue with one subject, the preprocessing stage is giving an error data and bvals/bvecs do not contain the same number of entries, however I checked the files and do seem to have the same number (all files attached). Related or unrelated to this issue, not all the dlabel/diff output files are generated, only these ... any advise appreciated, cheers - ds anat_brain_mask.bbr.nii.gz lh.cst_AS_avg33_mni_bbr_cpts_6.nii.gz rh.cst_AS_avg33_mni_bbr_cpts_6.nii.gz anat_brain_mask-vent.bbr.nii.gz lh.cst_AS_avg33_mni_bbr_cpts_6_std.txt rh.cst_AS_avg33_mni_bbr_cpts_6_std.txt aparc+aseg+2mm.bbr.nii.gz lh.cst_AS_avg33_mni_bbr_cpts_6.txt rh.cst_AS_avg33_mni_bbr_cpts_6.txt aparc+aseg.bbr.nii.gz lh.ilf_AS_avg33_mni_bbr_cpts_5.nii.gz rh.ilf_AS_avg33_mni_bbr_cpts_5.txt aparc+aseg_mask.bbr.nii.gz lh.ilf_AS_avg33_mni_bbr_cpts_5_std.txt White-Matter.bbr.nii.gz cortex+2mm.bbr.nii.gz lh.ilf_AS_avg33_mni_bbr_cpts_5.txt White-Matter++.bbr.nii.gz cortex+2mm+bs.bbr.nii.gz lowb_brain_mask.nii.gz cortex.bbr.nii.gz notventricles.bbr.nii.gz
http://www1.imperial.ac.uk/medicine/people/d.soto/ On 12/08/13 09:57, David Soto wrote: Thanks Anastasia, understood - the issue is that would be very time consuming at this stage for several reasons.. I found the issue with MRIConverter can be solved just by doing fslmaths on the diffusion output image fslmaths output data This should not change the diffusion image yet is fine for processing in FS cheers d.s. http://www1.imperial.ac.uk/medicine/people/d.soto/
On 10 Aug 2013, at 00:43, Anastasia Yendiki ayendiki@nmr.mgh.harvard.edu wrote:
I didn't mean run mri_convert on the nifti output of another program. I meant run mri_convert directly on the original dicom to convert it to nifti: mri_convert yourimage.dcm yourimage.nii.gz On Fri, 9 Aug 2013, Soto, David wrote: I see - as said the diffusion output.nii from MRIConverter http://lcni.uoregon.edu/~jolinda/MRIConvert/ [to not confound it with mri_converter) is not read by Freeview and mri_converter does not like it either
------------ MD00071523-2:RSDTI_WMGUI/ACH_AMO/diff] dsoto% mri_convert output.nii data.mgz mri_convert output.nii data.mgz $Id: mri_convert.c,v 1.179.2.7 2012/09/05 21:55:16 mreuter Exp $ reading from output.nii... nifti1Read(): unsupported slice timing pattern 5 in /Users/dsoto/Documents/fMRI/RSDTI_WMGUI/ACH_AMO/diff/output.nii No such file or directory
------------ NOW, I find that if I use FSL and run bet with a fractional intensity threshold of 0, I get an output file which is read by Freeview- which should allow me to proceed with all the necessary preprocessing steps in trac-all would this be fine? I dont think the bet I run will affect the image cheers ds http://www1.imperial.ac.uk/medicine/people/d.soto/ ________________________________________ From: Anastasia Yendiki [ayendiki@nmr.mgh.harvard.edu] Sent: 09 August 2013 23:15 To: Soto, David Cc: freesurfer@nmr.mgh.harvard.edu Subject: RE: [Freesurfer] trac-all inquiry When you apply a rotation to the DWIs (as eddy_correct does), you need to apply the same rotation to the corresponding gradient vectors. See for example: Leemans, A., Jones, D. K., Jun 2009. The B-matrix must be rotated when correcting for subject motion in DTI data. Magn Reson Med 61 (6), 1336–49. If you don't want to pass the dicoms to trac-all directly, you can use mri_convert to convert from dicom to nifti. On Fri, 9 Aug 2013, Soto, David wrote: hi - am afraid not because I am feeding to trac-all already eddycorrected images then in the config file I have # Perform registration-based eddy-current compensation? # Default: 1 (yes) set doeddy = 0 # Rotate diffusion gradient vectors to match eddy-current compensation? # Only used if doeddy = 1 # Default: 1 (yes) is this critical?? unfortunately, this is the only way I manage to get it to work as said my diffusion outputs from mriconverter are not read by FS, only through mediation of some FSL operation on the files, then FS likes those. I could start from scratch using dicoms but would prefer not to as the data is already well organised cheers ds http://www1.imperial.ac.uk/medicine/people/d.soto/ ________________________________________ From: Anastasia Yendiki [ayendiki@nmr.mgh.harvard.edu] Sent: 09 August 2013 22:44 To: Soto, David Subject: Re: [Freesurfer] trac-all inquiry Are you rotating the gradient vectors accordingly? This is done in trac-all after running eddy_correct. On Fri, 9 Aug 2013, Soto, David wrote: Hi Anastasia, stuff is running smoothly at last one quick question, is there any 'disadvantage' in using FSL to do the eddy correct and then feed those images to trace-all ? cheers ds http://www1.imperial.ac.uk/medicine/people/d.soto/ On 9 Aug 2013, at 15:33, David Soto <dsoto@imperial.ac.uk> wrote: hi, for some reason FS does not like the nii file from Mriconverter, ( I saw a post about thishttp://www.mail-archive.com/freesurfer@nmr.mgh.harvard.edu/msg19526.ht ml ) but does like the nii.gz outputs from FSL...
I'll try to debug the bepostx error thanks! ds http://www1.imperial.ac.uk/medicine/people/d.soto/ On 09/08/13 14:26, Anastasia Yendiki wrote: There is no reason to conevrt to .mnc. You should use your original .nii, if that shows up correctly in freeview. As for the bedpostx error, this is an Ubuntu issue that has come to my attention very recently. In Ubuntu /bin/sh is not a bash shell any more. To get around this, you'll have to edit the first line of the scripts $FREESURFER_HOME/bin/bedpostx_mgh and $FREESURFER_HOME/bin/fsl_sub_mgh. You'll have to replace "/bin/sh" with "/bin/bash" on the first line of those two scripts. On Fri, 9 Aug 2013, David Soto wrote: hi- I tried to convert from nii to mnc becos that is what i did when I did recon-all but I also tried with nii at the beggining and got the same issues. In fact in my last post (pasted below again)the input was a nii file could you please check the stuff below? thanks! ds Hi, further to my prior email I made some progress. I noted that nii2mnc does not seem to work on the diffusion output.nii that I got from Mriconverter as the output.mnc brain has parts chopped in Freeview. (I think there may be something funny about this, as the recon-all does like the T1 output form Mriconverter) HENCE I tried use the output of eddycorrect from FSL (which I already run for other thing) Then I created a new folder where i placed the output of FSL eddycorrect and in the configuration file I did (i) set dcmlist = (fsleddycorrectoutput.nii.gz) (ii) turned 'set doeddy = 0' then run it trac-all -c traculatest.txt -prep -log trac_from_fsleddy it seemed to complete without errors (log attached)n and I checked the preprocessing outputs in Freeview (FA, masks and aparc+asegs) and all seemed fine. However when I attempt the next stage in trac-all i.e. trac-all -c traculatest.txt -bedp -log trac_from_fsleddy_bedp it fails saying the following /usr/local/freesurfer/bin/bedpostx_mgh: 131: /usr/local/freesurfer/bin/bedpostx_mgh: Syntax error: "(" unexpected the log is also attached. any advise appreciated! cheers ds http://www1.imperial.ac.uk/medicine/people/d.soto/ http://www1.imperial.ac.uk/medicine/people/d.soto/ On 09/08/13 14:02, Anastasia Yendiki wrote: Why are you converting from .nii to .mnc? Why are you not using the .nii directly? On Fri, 9 Aug 2013, David Soto wrote: hi - thanks for the feedback weirdly, the nii2mnc transform of the diffusion data falters, I get a part of the brain chopped have no idea why this is the case, as it worked fine before for the T1 for recon-all...I am using Ubuntu 12.04 anyway am trying to sort this out now, if you have any advise that would much appreciated!! cheers ds http://www1.imperial.ac.uk/medicine/people/d.soto/ On 08/08/13 17:03, Anastasia Yendiki wrote: Hi David - The fact that it's taking so many tries to initialize the left ILF tells me that something has gone wrong with the data, either with the T1 to DWI registration, or with the mask, or something like that. Have you looked at any of the output files of the pre-processing? The FA map, the aparc+aseg, etc? a.y On Wed, 7 Aug 2013, Soto, David wrote: Hi Anastasia, I checked the becs and bvals files, there was a bug in the transposition of the columns into 3 rows in the bvecs. But i still have problems.. I rerun trac-all -prep and seemed fine but ended with a Segmentation fault (core dumped) which however is not present in the last line of the trac-all.log (Attached). Writing output filesto/home/dsoto/Documents/fmri/rsdtianawmg ui/02ST/dlabel/mni/lh.ilf_AS_avg33_mn i_bbr_* Writing spline volume to/home/dsoto/Documents/fmri/rsdtianawmg ui/02ST/dlabel/mni/lh.ilf_AS_avg33_mn i_bbr_cpts_5.nii.gz Segmentation fault (core dumped) Just in case I tried trac-all -bedp complains like these below, any advise appreciated, cheers - ds /home/dsoto/Documents/fmri/rsdtianawmgui /02ST/diffree/tracula02ST.txt -bedp INFO: SUBJECTS_DIR is /home/dsoto/Documents/fmri/rsdtianawmgui
INFO: Diffusion root is/home/dsoto/Documents/fmri/rsdtianawmgui
Actual FREESURFER_HOME /usr/local/freesurfer WARN: Running FSL's bedbost locally - this might take a while WARN: It is recommended to run this step on a cluster bedpostx_mgh -n 2/home/dsoto/Documents/fmri/rsdtianawmgui /02ST/dmri /usr/local/freesurfer/bin/bedpostx_mgh: 131: /usr/local/freesurfer/bin/bedpostx_mgh: Syntax error: "(" unexpected http://www1.imperial.ac.uk/medicine/peop le/d.soto/
________________________________________
From: Anastasia Yendiki [ayendiki@nmr.mgh.harvard.edu] Sent: 07 August 2013 17:22 To: Soto, David Cc: freesurfer@nmr.mgh.harvard.edu Subject: RE: [Freesurfer] trac-all inquiry Hi David - Every time you run trac-all, the results get appended to this file, so you need to look for error messages only in the more recent invocation of trac-all. The first error there seems to be: Error: bvecs and bvals don't have the same number of entries Do you have the same number of b-values and gradient vectors and volumes in your DWI series? a.y On Tue, 6 Aug 2013, Soto, David wrote: hi I upgraded to FS 5.3 but still encountering issues with trac-all prep. The log is attached, things I noted after inspecting it 1) INFO: FreeSurfer build stamps do not match Subject Stamp:freesurfer-Linux-centos4_x86_64-st able-pub-v5.1.0 Current Stamp: freesurfer-Linux-centos4_x86_64-st able-pub-v5.3.0
2) Error: input image/home/dsoto/Documents/fmri/rsdtian awmgui/02ST/dmri/lowb not valid 3) Image Exception : #22 :: ERROR: Could not open image /home/dsoto/Documents/fmri/rsdtian awmgui/02ST/dmri/lowb_brain 4) Image Exception : #22 :: ERROR: Could not open image /home/dsoto/Documents/fmri/rsdtian awmgui/02ST/dlabel/diff/White-Matter++. 5) ERROR: Could not read /home/dsoto/Documents/fmri/rsdtian awmgui/02ST/dmri/dtifit_FA.nii.gz but despite all this it says: trac-preproc finished without error at Tue Aug 6 21:27:30 BST 2013
thanks for your help cheers dshttp://www1.imperial.ac.uk/medicin e/people/d.soto/
__________________________________ ______ From: Anastasia Yendiki [ayendiki@nmr.mgh.harvard.edu] Sent: 06 August 2013 19:30 To: Soto, David Cc: freesurfer@nmr.mgh.harvard.edu Subject: RE: [Freesurfer] trac-all inquiry
I see, you're using the old version of tracula (from freesurfer 5.1). In that version, you had to define the number of low-b images in the configuration file. I strongly recommend updating to freesurfer 5.3. A lot of things have improved in tracula since then. Also, in the future please attach any log files as separate attachments instead of pasting them into the body of your email - this causes the body of the email to exceed the limit allowable on the list. Thanks, a.y The information in this e-mail is intended only for the person to whom it is addressed. If you believe this e-mail was sent to you in error and the e-mail contains patient information, please contact the Partners Compliance HelpLine athttp://www.partners.org/compliance line . If the e-mail was sent to you in error but does not contain patient information, please contact the sender and properly dispose of the e-mail.
hi - yes it as 65 -output pasted below, cheers
dsoto@wmen-dsoto3:~/Documents/fmri/rsdtianawmgui/14AB/dmri$ mri_info dwi.nii.gz Volume information for dwi.nii.gz type: nii dimensions: 96 x 96 x 46 x 65 voxel sizes: 2.3333, 2.3333, 2.2999 type: FLOAT (3) fov: 224.000 dof: 0 xstart: -112.0, xend: 112.0 ystart: -112.0, yend: 112.0 zstart: -52.9, zend: 52.9 TR: 1000.00 msec, TE: 0.00 msec, TI: 0.00 msec, flip angle: 0.00 degrees nframes: 65 PhEncDir: UNKNOWN ras xform present xform info: x_r = -1.0000, y_r = 0.0000, z_r = 0.0000, c_r = 0.0000 : x_a = 0.0000, y_a = 0.9774, z_a = -0.2112, c_a = 2.1015 : x_s = 0.0000, y_s = 0.2112, z_s = 0.9774, c_s = 19.9194 Orientation : LAS Primary Slice Direction: axial
voxel to ras transform: -2.3333 0.0000 0.0000 112.0000 0.0000 2.2807 -0.4858 -96.1994 0.0000 0.4928 2.2480 -55.4405 0.0000 0.0000 0.0000 1.0000
voxel-to-ras determinant -12.5217
ras to voxel transform: -0.4286 0.0000 0.0000 48.0000 -0.0000 0.4189 0.0905 45.3166 -0.0000 -0.0918 0.4250 14.7274 0.0000 0.0000 0.0000 1.0000
http://www1.imperial.ac.uk/medicine/people/d.soto/ On 16/08/13 16:13, Anastasia Yendiki wrote:
mri_info dmri/dwi.nii.gz
Ok, actually the error about the data and bvals/bvecs not having the same size occured the first time you ran trac-all, but it seems to have been fixed the second time you ran it, based on the log file.
I suspect the current problem is caused by poor registration. Have you checked the aparc+aseg and/or the registration from diffusion to anatomical and from anatomical to MNI?
On Fri, 16 Aug 2013, David Soto wrote:
hi - yes it as 65 -output pasted below, cheers
dsoto@wmen-dsoto3:~/Documents/fmri/rsdtianawmgui/14AB/dmri$ mri_info dwi.nii.gz Volume information for dwi.nii.gz type: nii dimensions: 96 x 96 x 46 x 65 voxel sizes: 2.3333, 2.3333, 2.2999 type: FLOAT (3) fov: 224.000 dof: 0 xstart: -112.0, xend: 112.0 ystart: -112.0, yend: 112.0 zstart: -52.9, zend: 52.9 TR: 1000.00 msec, TE: 0.00 msec, TI: 0.00 msec, flip angle: 0.00 degrees nframes: 65 PhEncDir: UNKNOWN ras xform present xform info: x_r = -1.0000, y_r = 0.0000, z_r = 0.0000, c_r = 0.0000 : x_a = 0.0000, y_a = 0.9774, z_a = -0.2112, c_a = 2.1015 : x_s = 0.0000, y_s = 0.2112, z_s = 0.9774, c_s = 19.9194 Orientation : LAS Primary Slice Direction: axial
voxel to ras transform: -2.3333 0.0000 0.0000 112.0000 0.0000 2.2807 -0.4858 -96.1994 0.0000 0.4928 2.2480 -55.4405 0.0000 0.0000 0.0000 1.0000
voxel-to-ras determinant -12.5217
ras to voxel transform: -0.4286 0.0000 0.0000 48.0000 -0.0000 0.4189 0.0905 45.3166 -0.0000 -0.0918 0.4250 14.7274 0.0000 0.0000 0.0000 1.0000
http://www1.imperial.ac.uk/medicine/people/d.soto/ On 16/08/13 16:13, Anastasia Yendiki wrote:
mri_info dmri/dwi.nii.gz
Hi Anastasia:
I wish to echo David's sentiments. Thanks for this great software. I was able to process and extract data for all brains without losing any of the brains. Thanks so much.
best,
Alan
On Fri, Aug 16, 2013 at 12:14 PM, Anastasia Yendiki < ayendiki@nmr.mgh.harvard.edu> wrote:
Ok, actually the error about the data and bvals/bvecs not having the same size occured the first time you ran trac-all, but it seems to have been fixed the second time you ran it, based on the log file.
I suspect the current problem is caused by poor registration. Have you checked the aparc+aseg and/or the registration from diffusion to anatomical and from anatomical to MNI?
On Fri, 16 Aug 2013, David Soto wrote:
hi - yes it as 65 -output pasted below, cheers
dsoto@wmen-dsoto3:~/Documents/fmri/rsdtianawmgui/14AB/dmri$ mri_info dwi.nii.gz Volume information for dwi.nii.gz type: nii dimensions: 96 x 96 x 46 x 65 voxel sizes: 2.3333, 2.3333, 2.2999 type: FLOAT (3) fov: 224.000 dof: 0 xstart: -112.0, xend: 112.0 ystart: -112.0, yend: 112.0 zstart: -52.9, zend: 52.9 TR: 1000.00 msec, TE: 0.00 msec, TI: 0.00 msec, flip angle:
0.00
degrees nframes: 65 PhEncDir: UNKNOWN ras xform present xform info: x_r = -1.0000, y_r = 0.0000, z_r = 0.0000, c_r = 0.0000 : x_a = 0.0000, y_a = 0.9774, z_a = -0.2112, c_a = 2.1015 : x_s = 0.0000, y_s = 0.2112, z_s = 0.9774, c_s = 19.9194 Orientation : LAS Primary Slice Direction: axial
voxel to ras transform: -2.3333 0.0000 0.0000 112.0000 0.0000 2.2807 -0.4858 -96.1994 0.0000 0.4928 2.2480 -55.4405 0.0000 0.0000 0.0000 1.0000
voxel-to-ras determinant -12.5217
ras to voxel transform: -0.4286 0.0000 0.0000 48.0000 -0.0000 0.4189 0.0905 45.3166 -0.0000 -0.0918 0.4250 14.7274 0.0000 0.0000 0.0000 1.0000
http://www1.imperial.ac.uk/medicine/people/d.soto/ On 16/08/13 16:13, Anastasia Yendiki wrote:
mri_info dmri/dwi.nii.gz
Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
The information in this e-mail is intended only for the person to whom it is addressed. If you believe this e-mail was sent to you in error and the e-mail contains patient information, please contact the Partners Compliance HelpLine at http://www.partners.org/complianceline . If the e-mail was sent to you in error but does not contain patient information, please contact the sender and properly dispose of the e-mail.
Great to hear. Thanks, Alan!
On Mon, 19 Aug 2013, Alan Francis wrote:
Hi Anastasia: I wish to echo David's sentiments. Thanks for this great software. I was able to process and extract data for all brains without losing any of the brains. Thanks so much.
best,
Alan
On Fri, Aug 16, 2013 at 12:14 PM, Anastasia Yendiki ayendiki@nmr.mgh.harvard.edu wrote:
Ok, actually the error about the data and bvals/bvecs not having the same size occured the first time you ran trac-all, but it seems to have been fixed the second time you ran it, based on the log file. I suspect the current problem is caused by poor registration. Have you checked the aparc+aseg and/or the registration from diffusion to anatomical and from anatomical to MNI? On Fri, 16 Aug 2013, David Soto wrote:hi - yes it as 65 -output pasted below, cheers
dsoto@wmen-dsoto3:~/Documents/fmri/rsdtianawmgui/14AB/dmri$ mri_info dwi.nii.gz Volume information for dwi.nii.gz type: nii dimensions: 96 x 96 x 46 x 65 voxel sizes: 2.3333, 2.3333, 2.2999 type: FLOAT (3) fov: 224.000 dof: 0 xstart: -112.0, xend: 112.0 ystart: -112.0, yend: 112.0 zstart: -52.9, zend: 52.9 TR: 1000.00 msec, TE: 0.00 msec, TI: 0.00 msec, flip angle: 0.00 degrees nframes: 65 PhEncDir: UNKNOWN ras xform present xform info: x_r = -1.0000, y_r = 0.0000, z_r = 0.0000, c_r = 0.0000 : x_a = 0.0000, y_a = 0.9774, z_a = -0.2112, c_a = 2.1015 : x_s = 0.0000, y_s = 0.2112, z_s = 0.9774, c_s = 19.9194 Orientation : LAS Primary Slice Direction: axial
voxel to ras transform: -2.3333 0.0000 0.0000 112.0000 0.0000 2.2807 -0.4858 -96.1994 0.0000 0.4928 2.2480 -55.4405 0.0000 0.0000 0.0000 1.0000
voxel-to-ras determinant -12.5217
ras to voxel transform: -0.4286 0.0000 0.0000 48.0000 -0.0000 0.4189 0.0905 45.3166 -0.0000 -0.0918 0.4250 14.7274 0.0000 0.0000 0.0000 1.0000
http://www1.imperial.ac.uk/medicine/people/d.soto/ On 16/08/13 16:13, Anastasia Yendiki wrote:
mri_info dmri/dwi.nii.gz
Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
The information in this e-mail is intended only for the person to whom it is addressed. If you believe this e-mail was sent to you in error and the e-mail contains patient information, please contact the Partners Compliance HelpLine at http://www.partners.org/complianceline . If the e-mail was sent to you in error but does not contain patient information, please contact the sender and properly dispose of the e-mail.
freesurfer@nmr.mgh.harvard.edu