Print

Print


So, there is no problem with the two different kind of dm4 from the tow
data? 31 and 62 for running TBSS?

Thank you for your patience,

Rosalia.

2015-10-06 20:54 GMT+02:00 Daniel Kim <[log in to unmask]>:

> Looks good.
> dim4 on the concatenated data simply indicates that now there are 62
> volumes instead of 31 - doubled because of the concatenation.
>
>
> On 2015-10-06, at 11:37 AM, Rosalia Dacosta Aguayo wrote:
>
> Hi Daniel,
>
> This is the report of the data of one of my patients I had no problems
> with DTIFIT
>
> rosalia@rosalia-PORTEGE-Z930:~$ cd
> /home/rosalia/Desktop/ESTUDIO_DTI_BIOMARCADORES/PATIENTS/adp_p3
> rosalia@rosalia-PORTEGE-Z930:~/Desktop/ESTUDIO_DTI_BIOMARCADORES/PATIENTS/adp_p3$
> fslsize data.nii.gz
> dim1           122
> dim2           122
> dim3           65
> dim4           31
> pixdim1        1.967213
> pixdim2        1.967213
> pixdim3        2.000000
> pixdim4        1.000000
> rosalia@rosalia-PORTEGE-Z930
> :~/Desktop/ESTUDIO_DTI_BIOMARCADORES/PATIENTS/adp_p3
>
> And this is the information after doing the new
> approach...concatenation....just the steps you describe:
>
> rosalia@rosalia-PORTEGE-Z930:~$ cd
> /home/rosalia/Desktop/ESTUDIO_DTI_BIOMARCADORES/PATIENTS/jmsb_p3
> rosalia@rosalia-PORTEGE-Z930:~/Desktop/ESTUDIO_DTI_BIOMARCADORES/PATIENTS/jmsb_p3$
> fslsize data.nii.gz
> dim1           122
> dim2           122
> dim3           65
> dim4          * 62*
> pixdim1        1.967213
> pixdim2        1.967213
> pixdim3        2.000000
> pixdim4        1.000000
> rosalia@rosalia-PORTEGE-Z930:~/Desktop/ESTUDIO_DTI_BIOMARCADORES/PATIENTS/jmsb_p3$
>
>
> Should I be worried with this difference in dim4?
>
> Rosalia.
>
> 2015-10-06 20:30 GMT+02:00 Daniel Kim <[log in to unmask]>:
>
>> Hmm... that does not sound good.
>> Maybe start from the beginning.
>> - Convert raw data using dcm2nii and obtain two raw dti nii.gz files:
>> name them dti1.nii.gz dti2.nii.gz
>> - concatenate nii.gz files to form one nii.gz file: fslmerge -t
>> dti_merged.nii.gz dti1.nii.gz dti2.nii.gz
>> - check dti_merged.nii.gz dimensions: fslsize dti_merged.nii.gz > this
>> should give you same x,y,z dimensions as dti1 and dti2 but a larger t
>> dimensions (if that's not the case, check dti1 and dti2 to make sure
>> nothing was corrupted during conversion).
>> - concatenate bvals and bvecs files (as mentioned before)
>> - run eddy_correct on dti_merged.nii.gz: eddy_correct dti_merged.nii.gz
>> data 0
>> - get brain mask from eddy corrected data.nii.gz: fslroi data nodif 0 1;
>> bet nodif nodif_brain -m
>> - run dtifit using concatenated bvals and bvecs on data.nii.gz
>>
>> hope that helps
>>
>> Danny Kim
>> On 2015-10-06, at 11:22 AM, Rosalia Dacosta Aguayo wrote:
>>
>> Hi Danny,
>>
>> Now, doing eddy_correct of my concatenated data I see that I have the
>> double of slices...I was used to average my two data sets...and now it
>> worries me that my ofther files have less directions that those two ones....
>>
>> Rosalia.
>>
>> 2015-10-06 20:18 GMT+02:00 Daniel Kim <[log in to unmask]>:
>>
>>> No worries.
>>> It's also a good practice to look at the data before running dtifit and
>>> remove directions that are heavily corrupted with motion or artifacts.
>>>
>>> Good luck!
>>>
>>> Danny Kim
>>>
>>>
>>> On 2015-10-06, at 11:07 AM, Rosalia Dacosta Aguayo wrote:
>>>
>>> Thanks Daniel,
>>>
>>> This is more clear for me...when you have never done this before you
>>> feel very unsure about how to do it. Now it is perfect clear: paste 1 colum
>>> of first bvec with the first column of the second bvec and so on..with
>>> second and third columns...
>>>
>>> Thank you a lot.
>>>
>>> Now I feel more relieve.
>>>
>>> Warm regards,
>>>
>>> Rosalia
>>>
>>> 2015-10-06 19:58 GMT+02:00 Daniel Kim <[log in to unmask]>:
>>>
>>>> Hi Rosalia
>>>>
>>>> Concatenating bvals and bvecs:
>>>>
>>>> Let's say bvals from DTI1: b11 b12 b13 b14 b15 ... b1n
>>>> and bvals from DTI2: b21 b22 b23 b24 b25 .... b2n
>>>>
>>>> then use a text editor to copy and paste DTI2's bvals to form a new
>>>> concatenated bvals: b11 b12 b13 ... b1n b21 b22 b23 ... b2n
>>>>
>>>> Same with bvecs - bvecs from DTI1:
>>>> v111 v112 v113 v114 v115 ... v11n
>>>> v121 v122 v123 v124 v125 ... v12n
>>>> v131 v132 v133 v134 v135 ... v13n
>>>>
>>>> And bvecs from DTI2:
>>>> v211 v212 v213 v214 v215 ... v21n
>>>> v221 v222 v223 v224 v225 ... v22n
>>>> v231 v232 v233 v234 v235 ... v23n
>>>>
>>>> Then use a text editor to concatenate bvecs to look like this:
>>>> v111 v112 v113 v114 v115 ... v11n v211 v212 v213 v214 v215 ... v21n
>>>> v121 v122 v123 v124 v125 ... v12n v221 v222 v223 v224 v225 ... v22n
>>>> v131 v132 v133 v134 v135 ... v13n v231 v232 v233 v234 v235 ... v23n
>>>>
>>>> Hope that helps.
>>>>
>>>> Danny Kim
>>>>
>>>> On 2015-10-06, at 10:41 AM, Rosalia Dacosta Aguayo wrote:
>>>>
>>>> I have concatenated first...but still with doubts regarding bvals and
>>>> bvecs files...please which is the next step? could you help me, please?
>>>>
>>>> 2015-10-06 19:18 GMT+02:00 Tibor Auer <[log in to unmask]>:
>>>>
>>>>> I call data the output of the merge (before eddy_correct).
>>>>>
>>>>>
>>>>>
>>>>> If you concatenate, then concatenation is the first step!
>>>>>
>>>>>
>>>>>
>>>>> Vale,
>>>>>
>>>>>
>>>>>
>>>>> Auer, Tibor M.D. Ph.D.
>>>>>
>>>>> MRC Cognition and Brain Sciences Unit
>>>>> 15 Chaucer Road
>>>>> Cambridge
>>>>> CB2 7EF
>>>>>
>>>>> United Kingdom
>>>>>
>>>>> Phone/Work: +44-(0)1223-273613
>>>>>
>>>>> Mail: [log in to unmask]
>>>>>
>>>>>
>>>>>
>>>>> *From:* FSL - FMRIB's Software Library [mailto:[log in to unmask]] *On
>>>>> Behalf Of *Rosalia Dacosta Aguayo
>>>>> *Sent:* Tuesday, October 06, 2015 6:16 PM
>>>>>
>>>>> *To:* [log in to unmask]
>>>>> *Subject:* Re: [FSL] Having problems with DTIFIT with only two
>>>>> subjects...
>>>>>
>>>>>
>>>>>
>>>>> Just to know if we are speaking about the same:
>>>>>
>>>>> I call data to the results of first apply eddy_correct to dti_1 and
>>>>> dti_2 and then averaging the results with fslmaths.....
>>>>>
>>>>>
>>>>>
>>>>> 2015-10-06 19:13 GMT+02:00 Tibor Auer <[log in to unmask]>:
>>>>>
>>>>> fslmerge *–t* data data_1 data_2
>>>>>
>>>>> should merge data_1 and data_2, so data will contain volumes of both
>>>>> both data_1 and data_2.
>>>>>
>>>>> fslsize data à dim4 should be fslsize data_1 à dim4 + fslsize data_2 à
>>>>> dim4
>>>>>
>>>>> Vale,
>>>>>
>>>>>
>>>>>
>>>>> Auer, Tibor M.D. Ph.D.
>>>>>
>>>>> MRC Cognition and Brain Sciences Unit
>>>>> 15 Chaucer Road
>>>>> Cambridge
>>>>> CB2 7EF
>>>>>
>>>>> United Kingdom
>>>>>
>>>>> Phone/Work: +44-(0)1223-273613
>>>>>
>>>>> Mail: [log in to unmask]
>>>>>
>>>>>
>>>>>
>>>>> *From:* FSL - FMRIB's Software Library [mailto:[log in to unmask]] *On
>>>>> Behalf Of *Rosalia Dacosta Aguayo
>>>>> *Sent:* Tuesday, October 06, 2015 6:03 PM
>>>>>
>>>>>
>>>>> *To:* [log in to unmask]
>>>>> *Subject:* Re: [FSL] Having problems with DTIFIT with only two
>>>>> subjects...
>>>>>
>>>>>
>>>>>
>>>>> data or dti_1 and dti_2??
>>>>>
>>>>>
>>>>>
>>>>> 2015-10-06 18:40 GMT+02:00 Tibor Auer <[log in to unmask]>:
>>>>>
>>>>> fslmerge *–t* data data_1 data_2
>>>>>
>>>>>
>>>>>
>>>>> Vale,
>>>>>
>>>>>
>>>>>
>>>>> Auer, Tibor M.D. Ph.D.
>>>>>
>>>>> MRC Cognition and Brain Sciences Unit
>>>>> 15 Chaucer Road
>>>>> Cambridge
>>>>> CB2 7EF
>>>>>
>>>>> United Kingdom
>>>>>
>>>>> Phone/Work: +44-(0)1223-273613
>>>>>
>>>>> Mail: [log in to unmask]
>>>>>
>>>>>
>>>>>
>>>>> *From:* FSL - FMRIB's Software Library [mailto:[log in to unmask]] *On
>>>>> Behalf Of *Rosalia Dacosta Aguayo
>>>>> *Sent:* Tuesday, October 06, 2015 4:58 PM
>>>>> *To:* [log in to unmask]
>>>>>
>>>>>
>>>>> *Subject:* Re: [FSL] Having problems with DTIFIT with only two
>>>>> subjects...
>>>>>
>>>>>
>>>>>
>>>>> Dear FSL experts and Michel,
>>>>>
>>>>>
>>>>> Sorry, when I try fslmerge to concatenate the two datasets acquired
>>>>> for the same subject in the same scanner.... I write:
>>>>>
>>>>> fslmerge data dti_1.nii.gz dti_2.nii.gz and nothing happens
>>>>>
>>>>> It tells the following I do not understand well:
>>>>>
>>>>> Usage: fslmerge <-x/y/z/t/a/tr> <output> <file1 file2 .......> [tr
>>>>> value in seconds]
>>>>>
>>>>>      -t : concatenate images in time
>>>>>      -x : concatenate images in the x direction
>>>>>      -y : concatenate images in the y direction
>>>>>      -z : concatenate images in the z direction
>>>>>      -a : auto-choose: single slices -> volume, volumes -> 4D (time
>>>>> series)
>>>>>      -tr : concatenate images in time and set the output image tr to
>>>>> the final option value
>>>>>
>>>>> I guess I should use -t option but I am not sure...any one of you
>>>>> could help me with this?
>>>>>
>>>>> Thanks a lot,
>>>>>
>>>>> Rosalia.
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> 2015-10-06 16:05 GMT+02:00 Rosalia Dacosta Aguayo <[log in to unmask]
>>>>> >:
>>>>>
>>>>> Hi Michael,
>>>>>
>>>>>
>>>>>
>>>>> Thank you very much for your reply.
>>>>>
>>>>>
>>>>>
>>>>> I will try this option too. There are remaining two new subjects and I
>>>>> would like to run TBSS as soon as possible.
>>>>>
>>>>>
>>>>>
>>>>> Yours sincerely,
>>>>>
>>>>>
>>>>>
>>>>> Rosalia.
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> 2015-10-06 15:50 GMT+02:00 Harms, Michael <[log in to unmask]>:
>>>>>
>>>>>
>>>>>
>>>>> Instead of coregistering/averaging maps after DTIFIT, the more typical
>>>>> approach would be to simply concatenate ('fslmerge') the two original runs,
>>>>> concatenate the bvals/bvecs files, and then just run eddy_correct and
>>>>> dtifit using those concatenated files (i.e., as if all the data was
>>>>> collected in a single run in the first place).
>>>>>
>>>>>
>>>>>
>>>>> cheers,
>>>>>
>>>>> -MH
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>>
>>>>> Michael Harms, Ph.D.
>>>>>
>>>>> -----------------------------------------------------------
>>>>>
>>>>> Conte Center for the Neuroscience of Mental Disorders
>>>>>
>>>>> Washington University School of Medicine
>>>>>
>>>>> Department of Psychiatry, Box 8134
>>>>>
>>>>> 660 South Euclid Ave. Tel: 314-747-6173
>>>>>
>>>>> St. Louis, MO  63110 Email: [log in to unmask]
>>>>>
>>>>>
>>>>>
>>>>> *From: *Tibor Auer <[log in to unmask]>
>>>>> *Reply-To: *FSL - FMRIB's Software Library <[log in to unmask]>
>>>>> *Date: *Tuesday, October 6, 2015 5:38 AM
>>>>> *To: *FSL - FMRIB's Software Library <[log in to unmask]>
>>>>> *Subject: *Re: [FSL] Having problems with DTIFIT with only two
>>>>> subjects...
>>>>>
>>>>>
>>>>>
>>>>> Dear Rosalia,
>>>>>
>>>>>
>>>>>
>>>>> How did you actually averaged the imagesin step e)? Are you sure there
>>>>> was no dimension reduction? Have you checked whether the output data.nii.gz
>>>>> is actually a 4D dataset with same amount of volumes as the number of
>>>>> entries in the bvals/bvecs.
>>>>>
>>>>>
>>>>>
>>>>> However, there are some more conceptual issues:
>>>>>
>>>>> 1.       In step d), you first registered data_1 to data_2* and*
>>>>> data_2 to data_1. So at the end, they are not aligned at all!
>>>>>
>>>>> 2.       Which bvals/bvecs have you used? The set from data_1 or from
>>>>> data_2?
>>>>>
>>>>>
>>>>>
>>>>> And more importantly:
>>>>>
>>>>> It is not advised to register raw DTI images, because then you disrupt
>>>>> the consistency between the geometry of the images and the geometry of the
>>>>> bvecs. One solution is to transform the bvecs, as well; but it is also
>>>>> suboptimal.
>>>>>
>>>>> My recommendation is to analyse the two datasets separately without
>>>>> any registration, and coregister+average the metric images (e.g. FA maps)
>>>>> after DTIFIT.
>>>>>
>>>>>
>>>>>
>>>>> Vale,
>>>>>
>>>>>
>>>>>
>>>>> Auer, Tibor M.D. Ph.D.
>>>>>
>>>>> MRC Cognition and Brain Sciences Unit
>>>>> 15 Chaucer Road
>>>>> Cambridge
>>>>> CB2 7EF
>>>>>
>>>>> United Kingdom
>>>>>
>>>>> Phone/Work: +44-(0)1223-273613
>>>>>
>>>>> Mail: [log in to unmask]
>>>>>
>>>>>
>>>>>
>>>>> *From:* Rosalia Dacosta Aguayo [mailto:[log in to unmask]
>>>>> <[log in to unmask]>]
>>>>> *Sent:* Tuesday, October 06, 2015 11:05 AM
>>>>> *To:* FSL - FMRIB's Software Library <[log in to unmask]>
>>>>> *Subject:* Having problems with DTIFIT with only two subjects...
>>>>>
>>>>>
>>>>>
>>>>> Dear FSL team,
>>>>>
>>>>> I must be doing something wrong but I can not guess where is the
>>>>> problem. I have two groups of 12 subjects.
>>>>>
>>>>> 1. I have two DTI acquisitions (dti_1 and dti_2) from the same subject
>>>>> in the same scanner (the last two subjects to include in the study). And I
>>>>> did the following steps in order to prepare my two subjects.
>>>>>
>>>>> a) From DICOM to NIFTI (dcm2nii)
>>>>>
>>>>> b) eddy_correct dti_1 data_1 0
>>>>>
>>>>> c) eddy_correct dti_2 data_2 0
>>>>>
>>>>> d) Here I thing there is the problem...but I do not know to manage
>>>>> with them in order to ensure that both images are well aligned. I did the
>>>>> following for co-registration of the two images.
>>>>>
>>>>>
>>>>> - flirt -in data_2.nii.gz -ref data_1.nii.gz -out data_2_registered
>>>>> -bins 256 -cost corratio -searchrx 0 0 -searchry 0 0 -searchrz 0 0 -dof 6
>>>>> -interp trilinear
>>>>>
>>>>> - flirt -in data_1.nii.gz -ref data_2_registered.nii.gz -out
>>>>> data_1_registered -bins 256 -cost corratio -searchrx 0 0 -searchry 0 0
>>>>> -searchrz 0 0 -dof 6 -interp trilinear
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> e) Averaging of data_1_registered and data_2_registered  -out = data
>>>>>
>>>>> f) Creation of the nodif.nii.gz with fslroi from data
>>>>>
>>>>> g)Creation of nodif_brain_mask with BET
>>>>>
>>>>> h) FSL --> DTIFIT Reconstruct diffusion tensors --> specify files
>>>>> manually (data, nodif_brain_mask, bvecs and bvals).
>>>>>
>>>>> *I get the following error message: Erros: Erro: data and bvals /
>>>>> bvecs do not contain the same number of entries *
>>>>>
>>>>>
>>>>>
>>>>> *I hope I have explained well all I have done in order to facilitate
>>>>> the finding of my error...*
>>>>>
>>>>>  With my best regards,
>>>>>
>>>>> Rosalia.
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> ------------------------------
>>>>>
>>>>> The materials in this message are private and may contain Protected
>>>>> Healthcare Information or other information of a sensitive nature. If you
>>>>> are not the intended recipient, be advised that any unauthorized use,
>>>>> disclosure, copying or the taking of any action in reliance on the contents
>>>>> of this information is strictly prohibited. If you have received this email
>>>>> in error, please immediately notify the sender via telephone or return mail.
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>>
>>>
>>>
>>
>>
>
>