[Mrtrix-discussion] empty FA images and streamtrack questions

Kerstin Pannek k.pannek1 at uq.edu.au
Tue Oct 28 15:39:14 PDT 2008


Good morning!
Setting the first 6 bvals to 0 helped! Thanks.
The images were acquired on a Siemens Sonata 1.5T.
Cheers
Kerstin



Donald Tournier wrote:
> Hello again,
>
> Just having a look at your encoding file: the b=0 "directions" (i.e.
> the first 6 volumes) have a b-value set to 1200 (the last column), and
> the direction vector set to zero. MRtrix assumes the b-values in the
> last column are correct, which in this case they are not - these first
> 6 should be set to zero.
>
> Try modifying the encoding file by hand, by setting the first 6
> b-values to zero. Save the file, and analyse with the command:
>
>   
>> dwi2tensor dwi.mif -grad encoding.b dt.mif
>>     
>
> In fact, any command that makes use of the encoding information will
> need to have the new encoding file supplied in this way to override
> the incorrect one in the header. This includes estimate_response and
> csdeconv. That should sort out the problem.
>
> To avoid having this problem happen again, it might be wise to fix up
> the code that was used to generate that incorrect DW scheme. Did you
> convert those images straight from DICOM? What scanner were the images
> acquired on? I'll see if there's an easy way to avoid this kind of
> issue for the next release.
>
> Cheers,
>
> Donald.
>
>
> On Tue, Oct 28, 2008 at 4:56 PM, Kerstin Pannek <k.pannek1 at uq.edu.au> wrote:
>   
>> Hi
>> I have attached the output of mrinfo (xxx-ed patient name and DOB), and
>> encoding.b for this person, along with bvecs, which was generated using
>> dcm2nii. bvecs and encoding.b are the same (just the sign of the x-values
>> changed). I am guessing that this is not causing the problem...
>> Another difference between other datasets and this one is that the data is
>> not in mosaic format. Could that have anything to do with it?
>> I could probably put the dwi data onto our website, but I will need to
>> figure out how to do that...
>> Cheers
>> Kerstin
>>
>>
>>
>> Donald Tournier wrote:
>>     
>>> Hi again,
>>>
>>> About the empty FA/DT image: the only thing I can think of is an
>>> incorrect DW encoding file. Can you send me the output of the
>>> following command, along with the "encoding.b" file it will produce:
>>>
>>>
>>>       
>>>> mrinfo dwi.mif -grad encoding.b
>>>>
>>>>         
>>> Otherwise, I guess there's nothing I can do really without having a
>>> look at the data themselves. If that last step doesn't give us a good
>>> clue, is there any way you can send me the DW data?
>>>
>>> Cheers,
>>>
>>> Donald.
>>>
>>>
>>> On Tue, Oct 28, 2008 at 10:09 AM, Kerstin Pannek <k.pannek1 at uq.edu.au>
>>> wrote:
>>>
>>>       
>>>> Hi Donald
>>>>
>>>> I follow the instructions in the documentation to get the fa. The tensor
>>>> image I get is also empty.
>>>>
>>>> For streamtrack, I use a binary brain mask (generated using FSL bet, then
>>>> eroded by 2 voxels) to terminate tracking. I found that segmentation
>>>> faults
>>>> occur more often (but not only) when I use the -include option. I guess
>>>> this
>>>> is simply because a larger number of streamlines has to be generated
>>>> then,
>>>> increasing chances to see a segfault, and does not actually have anything
>>>> to
>>>> do with -include itself.
>>>> This is the command I ran:
>>>> $ streamtrack SD_PROB CSD/csd.mif -seed AC-seed.mif -include
>>>> AC-target.mif
>>>> -number 100 -mask data/mask-ero2.mif AC-targets.tck
>>>>
>>>> This is the output of the debugger:
>>>>
>>>> $ gdb --args streamtrack SD_PROB CSD/csd.mif -seed AC-seed.mif -include
>>>> AC-target.mif -mask data/mask-ero2.mif AC-targets.tckGNU gdb 6.8-debian
>>>>
>>>> Copyright (C) 2008 Free Software Foundation, Inc.
>>>> License GPLv3+: GNU GPL version 3 or later
>>>> <http://gnu.org/licenses/gpl.html>
>>>> This is free software: you are free to change and redistribute it.
>>>> There is NO WARRANTY, to the extent permitted by law.  Type "show
>>>> copying"
>>>> and "show warranty" for details.
>>>> This GDB was configured as "x86_64-linux-gnu"...
>>>> (gdb) run
>>>> Starting program: /data/home/kerstin/bin/mrtrix/bin/streamtrack SD_PROB
>>>> CSD/csd.mif -seed AC-seed.mif -include AC-target.mif -mask
>>>> data/mask-ero2.mif AC-targets.tck
>>>> [Thread debugging using libthread_db enabled]
>>>> [New Thread 0x7f5b155f2780 (LWP 30061)]
>>>>  9096 generated,      537 selected    [ 53%]
>>>> Program received signal SIGSEGV, Segmentation fault.
>>>> [Switching to Thread 0x7f5b155f2780 (LWP 30061)]
>>>> 0x0000000000410404 in MR::DWI::SH::value_precomputed ()
>>>> Current language:  auto; currently asm
>>>> (gdb) bt full
>>>> #0  0x0000000000410404 in MR::DWI::SH::value_precomputed ()
>>>> No locals.
>>>> #1  0x000000000043066b in
>>>> MR::DWI::Tractography::Tracker::SDProb::next_point
>>>> ()
>>>> No locals.
>>>> #2  0x0000000000423b48 in MR::DWI::Tractography::Tracker::Base::next ()
>>>> No locals.
>>>> #3  0x00000000004094c9 in MyApp::execute ()
>>>> No locals.
>>>> #4  0x00000000004057c0 in main ()
>>>> No locals.
>>>>
>>>>
>>>> Thanks for your help!
>>>> Cheers
>>>> Kerstin
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>> Donald Tournier wrote:
>>>>
>>>>         
>>>>> Hi Kerstin,
>>>>>
>>>>> I'm a bit surprised that you're having problem with the tensor
>>>>> analysis. Are you generating the tensor image (i.e. the dt.mif file)
>>>>> first with dwi2tensor, and then feeding that through tensor2FA? Does
>>>>> the tensor image look OK?
>>>>>
>>>>>
>>>>> About your other questions:
>>>>>
>>>>> 1) the -initdirection option format is -initdirection 0,0.5,1 (i.e. a
>>>>> comma-separated list of floating point values, no spaces). The
>>>>> direction is relative to the usual coordinate system (in the
>>>>> documentation: General Information => Overview).
>>>>>
>>>>> 2) Any segmentation fault is A Bad Thing. Could you post the entire
>>>>> command that you actually type? I would also be interested to know
>>>>> whether you use a mask image that allows the tracks to reach the edge
>>>>> of the data set: maybe the program crashes if the track wonders
>>>>> outside the image data set. In any case, there's a bug and it needs to
>>>>> be fixed...
>>>>>
>>>>> If you're feeling particularly adventurous, maybe you can run the
>>>>> tracking within the debugger? That way, if it crashes you would be
>>>>> able to attach the full debugging information when/if it crashes. It's
>>>>> quite simple to do that. If the command you normally run is:
>>>>>
>>>>>
>>>>>
>>>>>           
>>>>>> streamtrack SD_PROB some_image.mif track.tck -some_option etc
>>>>>>
>>>>>>
>>>>>>             
>>>>> then just insert "gdb --args" at the beginning, and then type "run" at
>>>>> the GDB prompt:
>>>>>
>>>>>
>>>>>
>>>>>           
>>>>>> gdb --args streamtrack SD_PROB some_image.mif track.tck -some_option
>>>>>> etc
>>>>>>
>>>>>>
>>>>>>             
>>>>> GNU gdb 6.8-debian
>>>>> Copyright (C) 2008 Free Software Foundation, Inc.
>>>>> License GPLv3+: GNU GPL version 3 or later
>>>>> <http://gnu.org/licenses/gpl.html>
>>>>> This is free software: you are free to change and redistribute it.
>>>>> There is NO WARRANTY, to the extent permitted by law.  Type "show
>>>>> copying"
>>>>> and "show warranty" for details.
>>>>> This GDB was configured as "i486-linux-gnu"...
>>>>> (gdb) run
>>>>>
>>>>> If the program crashes it will display something like "SIGSEGV
>>>>> exception occurred" or something. If that happens, then type "bt full"
>>>>> at the prompt, and copy/paste all of the session into an email so I
>>>>> can have a good look at what went wrong.
>>>>>
>>>>> By the way, this is only for debugging. There is a performance penalty
>>>>> for running within the debugger, and it can be significant. I wouldn't
>>>>> recommend doing this routinely...
>>>>>
>>>>> Cheers!
>>>>>
>>>>> Donald.
>>>>>
>>>>>
>>>>>
>>>>> On Fri, Oct 24, 2008 at 4:38 PM, Kerstin Pannek <k.pannek1 at uq.edu.au>
>>>>> wrote:
>>>>>
>>>>>
>>>>>           
>>>>>> Hello again everyone,
>>>>>>
>>>>>> Donald, thank you for fixing find_SH_peaks. Unfortunately I did not
>>>>>> quite
>>>>>> get around to really playing with it yet.
>>>>>>
>>>>>> I was just trying to analyze some DTI data that had not been optimized
>>>>>> for
>>>>>> CSD and tractography (b value 1200; slice gap...). When running
>>>>>> tensor2FA, I
>>>>>> get only an empty image. Image conversion from DICOM works, i.e. I get
>>>>>> a
>>>>>> non-empty dwi.mif and encoding - just a warning about the slice gap, no
>>>>>> error message. What might be causing this problem?
>>>>>>
>>>>>> Some more question about streamtrack:
>>>>>> 1) When I want to use the option -initdirection <dir>, what format
>>>>>> should
>>>>>> <dir> be?
>>>>>> 2) I do get segmentation faults fairly frequently using streamtrack
>>>>>> SD_PROB.
>>>>>> I did get segmentation faults using fslview in the past, making me
>>>>>> think
>>>>>> that this was a hardware problem at my end. With the new version of FSL
>>>>>> and
>>>>>> a different video card, the fslview segmentation fault issue has been
>>>>>> resolved, but the streamtrack segmentation fault remains. Any thoughts
>>>>>> on
>>>>>> what this problem might be related to? I case it is important, I get
>>>>>> some
>>>>>> "failed to converge" messages from csdeconv.
>>>>>>
>>>>>> Thanks for your help.
>>>>>> Kerstin
>>>>>> _______________________________________________
>>>>>> Mrtrix-discussion mailing list
>>>>>> Mrtrix-discussion at www.nitrc.org
>>>>>> http://www.nitrc.org/mailman/listinfo/mrtrix-discussion
>>>>>>
>>>>>>
>>>>>>
>>>>>>             
>>>>>
>>>>>           
>>>>         
>>>
>>>
>>>       
>> ************************************************
>> Image:               "dwi.mif"
>> ************************************************
>>  Format:            MRtrix
>>  Dimensions:        128 x 128 x 42 x 56
>>  Voxel size:        1.79688 x 1.79688 x 2.75 x 2.75
>>  Dimension labels:  0. left->right (mm)
>>                     1. posterior->anterior (mm)
>>                     2. inferior->superior (mm)
>>                     3. sequence (?)
>>  Data type:         unsigned 16 bit integer (little endian)
>>  Data layout:       [ -0 -1 +2 +3 ]
>>  Data scaling:      offset = 0, multiplier = 1
>>  Comments:          xxx [MR] ep2d_DTI_27H50_56_68
>>                     study: Research Head
>>                     DOB: xxx
>>                     DOS: 19/07/2007 11:30:47
>>  Transform:                    1           0          -0      -113.2
>>                                0           1          -0      -92.19
>>                               -0          -0           1      -26.54
>>                                0           0           0           1
>>  DW scheme:         56 x 4
>>
>>
>>
>>     
>
>
>
>   



More information about the Mrtrix-discussion mailing list