CSD-based tractography using multi-shell data

Skip to first unread message

Arash Aghamohammadi Sereshki

Jul 11, 2022, 9:02:05 PM7/11/22
to ExploreDTI

Hello ExploreDTI users

I'm trying to analyze a DTI dataset with the following parameters using the CSD-based tractography: 

Two diffusion-weighted datasets at b = 900 s/mm2 and 2000 s/mm2, each has 5 b = 0 s/mm2 volumes and 30 gradient directions per volume. 

Following is the procedure I used to acquire CSD-based tractography:

  1. I concatenated both b900 and b2000 mat files using a tool from the Plugins menu (i.e., Concatenate DTI*.mat files (to *.nii).
  2. I used ‘Sort DWI *.nii file(s) wrt b-values’ tool to place the b0 images at the beginning.
  3. Then I converted the nii file to a mat file using Convert raw data to 'DTI *.mat.' As previously explained in this forum, I used 'NaN' for the b-value.
  4. I corrected the subject motion and EC/EPI distortions and acquired both 'native' and 'trafo' files. Both files seem fine. 
  5. Finally, I tried to do the whole-brain tractography using CSD (L-max:8, with Recursive Calibration). 

When I use a Linux OS for the analysis, I get the following error:

Performing CSD tracking (FOD interpolation) for file:


Calculating FOD...

CSD with recursive RF calibration...

Running MS-CSD (beta mode)...

Starting parallel pool (parpool) using the 'local' profile ...

Connected to the parallel pool (number of workers: 6).

Warning: Rank deficient, rank = 27, tol = 1.611383e-05.

 In parallel_function>make_general_channel/channel_general (line 832)

 In remoteParallelFunction (line 67)

Invalid MEX-file '/home/MRI/.mcrCache9.8/MainEx0/MainExploreD/Source/GC/mex_wls.mexa64': liblapack.so.3: cannot open shared object file: No such file or directory

Error in DTI/dt (line 49)

Error in SD.response (line 92)

Error in E_DTI_MS_CSD_deconvolution_MuSh (line 115)

Error in E_DTI_Get_HARDI_CSD_FOD_RC_MuSh (line 41)

Error in E_DTI_Get_HARDI_CSD_FOD_RC (line 52)

Error in WholeBrainTrackingCSD_fast_exe (line 14)

Error in WholeBrainTrackingCSD_fast (line 82)

Error in WholeBrainTrackingCSD_fast (line 25)

Error in MainExploreDTI (line 1630)

Error using waitforallfiguresclosed (line 14)

Error while evaluating Menu Callback.

Also, I did the abovementioned procedure with a Windows OS. In the end, I got the whole brain CSD tractography file which seems not to have all brain tracts; for example, the cingulum bundle is fine, but there was no delineated tract for the corpus callosum. The size of the tractography file was also not as large as I expected (indicating that all brain tracts were not delineated). 

I wondered if anyone could help me to address the abovementioned issue. 

Thank you,



Jul 13, 2022, 2:18:01 AM7/13/22
to ExploreDTI
Looks like there are two things happening, an error and a warning.

For the error on linux, looks like your commputer is missing lib lapack, hence the error

'Invalid MEX-file '/home/MRI/.mcrCache9.8/MainEx0/MainExploreD/Source/GC/mex_wls.mexa64': liblapack.so.3: cannot open shared object file: No such file or directory'

Just make sure you have it already or install it, that should fix it. It probably comes bundled with matlab, but the standalone version does not include some basic stuff like this and some graphical stuff I think. On my computer it resides here for example

samuel@sam-laptop ~> ls /usr/lib/liblapack.so*
lrwxrwxrwx 1 root root      14 16 avr 23:43 /usr/lib/liblapack.so -> liblapack.so.3
lrwxrwxrwx 1 root root      19 16 avr 23:43 /usr/lib/liblapack.so.3 -> liblapack.so.3.10.1
-rwxr-xr-x 1 root root 7104328 16 avr 23:43 /usr/lib/liblapack.so.3.10.1

And you can see I have version 3.10.1, but they all point to the same thing for name resolving, so it may also just be a symlink away for some reason.

For the error and missing tractography, that seems to be data related. In this line

Warning: Rank deficient, rank = 27, tol = 1.611383e-05.

It states your acquisition scheme does not cover the SH order you picked as it is rank deficient I'd guess. Try 4 or 6 for 15 and 2888 parameters) as you have 30 directions per shell, for order 8 you'll need about 45 coefficients, so maybe if your gradients are the same on the two shells that would explain it? It's just guesswork, but lowering the order should remediate it instead of having a degenerate problem.
Reply all
Reply to author
0 new messages