TCKDFC question

#1

Hi All,

I am new to MRtrix.

mrtrix.readthedocs.io/en/latest/reference/commands/tckdfc.html

describes the new tool tckdfc but says only that preprocessed fmri data should be given as input.

Can anyone please clarify what kind of preprocessed fmri data is acceptable?

i.e., should it be standard space?
Is preprocessed data from any pipeline okay (e.g., fmriprep)?
Should it be volumetric *.nii files or will cifti files work?

Thanks,

Dianne

#2

Here’s what I figured out about my own question. Perhaps it will help someone else:

Input images:

  • tract file: any *.tck file (including specific tracts extracted from the giant mass of streamlines).
  • bold image: A preprocessed 4D functional image registered into the space of the B0 images.

The smaller the track image, the faster it runs.

static is WAY faster than dynamic (dynamic with the BATMAN tutorial data, a million streamlines and the T1 template took roughly 30 minutes on my Mac Pro)

BOLD image

I used a 4d volumetric fmriprep output with 250 timepoints as my bold image. I coregistered the bold image to the B0 image as suggested by the Calamante 2017 paper:

Create transform matrix:
flirt -in bold.nii.gz -ref mean_b0_preprocessed.nii.gz -out bold2b0.mat

Generate coregistered image (bold coregistered to B0):

flirt -in bold.nii.gz -applyxfm -init bold2b0.mat -out bold_coreg.nii.gz -paddingsize 0.0 -interp trilinear -ref mean_b0_preprocessed.nii.gz

Create mif image (I don’t think I have to, but I wanted to try):

mrconvert bold_coreg.nii.gz bold_coreg.mif

TKDFC Requirements

You must specify:

  • -static or -dynamic
  • the template file (the space the output should be in),
  • the tck file (you can actually choose any *.tck file you want)
  • the coregistered bold image
  • the output name

Here’s a minimal tckdfc command that does not complain:

tckdfc -static -template T1_coreg.mif sift_1mio.tck bold_coreg.mif tdfc_out.mif

I also tried a different tck file generated during the Batman tutorial. It worked fine:

tckdfc -static -template T1_coreg.mif cst.tck bold_coreg.mif tdfc_cst.mif

The result is anatomically constrained to the WM (makes sense, so is the tck file in the Batman tutorial).

If you choose dynamic, you must supply a shape and number of steps for the sliding window:

  • Valid shape choices are: rectangle, triangle, cosine, hann, hamming and lanczos.
  • A number of steps (size of sliding time window. I bet bigger values run faster but produce more course time results). Really, I chose at random for the following test:

tckdfc -dynamic hamming 3 -template T1_coreg.mif sift_1mio.tck bold_coreg.mif tdfc_dynamic.mif

The resulting dynamic output file has the same number of time points as the input fmri file. Careful, these dynamic files can be REALLY big (mine in this example was 10 GB). You can zip up a mif file…and save a lot of space (in my case, down to 761 MB). However, it would probably have been better to use a lower resolution template image.