Beginner: Connectome pipeline (Updated)

I may or may not have been writing an automated connectome generation pipeline this week… :ghost:

A few suggestions:

A. DWI processing

  • Run dwidenoise as your very first step. So far this appear to perform extremely well.

  • Run dwibiascorrect after dwipreproc. Getting rid of the B1 bias field will help with the brain masking, improve the tracking, and improve the SIFT results.

  • Dilate the brain mask and feed the dilated version to dwi2fod. Since ACT is responsible for terminating streamlines, you don’t want an erroneous DWI brain mask cutting into the brain and causing streamlines to terminate in WM; so dilating it beforehand just gives a bit of an error margin, given DWI brain masking can still be a little off at times. You could equally just run dwi2fod without a mask, and it’d just take a while longer.

B. T1 Processing

5ttgen fsl T1.nii.gz 5TT.mif
QNs: Can I use Freesufer outputs here? Where does intra-individual DTI-T1 registration take place in this workflow?

You can: simply use 5ttgen freesurfer instead of 5ttgen fsl. But have a close look at the resulting 5TT image to decide whether or not you actually want to use it…

labelconvert aparc+aseg.nii.gz FreeSurferColorLUT.txt fs_default.txt nodes.mif
QN: This is assuming that I am using the Desikan atlas, right?

The LUT file fs_default.txt is extracting the grey matter parcels from the aparc+aseg image, which is the Desikan-Killiany atlas. You can equivalently use LUT file fs_a2009s.txt to extract the grey matter parcels from the aparc.a2009s+aseg image, which would give you the Destrieux atlas, or design an appropriate LUT file to extract and order parcels from a custom cortical atlas. There’s supposed to be a documentation page explaining in more detail what this command is doing, but looks like it got lost during software updates; once I restore it it should appear here.

labelsgmfix nodes.mif T1.nii.gz fs_default.txt nodes_fixSGM.mif -premasked
QN: Why is this recommended in the tutorial?

Unfortunately this result got lost in supplementary material when it should have been appendix data… It’s associated with this paper. Basically you get reduced scan-rescan variability in your connectome, because the FIRST sub-cortical segmentations have less scan-rescan variability than the FreeSurfer ones.

C. Connectome generation

  • Your tckgen call isn’t using the ACT data in any way; so it’ll be tracking using the diffusion image data only. It’s also generally not necessary to use the -mask option in tckgen if using ACT.

  • You’re generating 1 million streamlines with tckgen, then asking tcksift to terminate when there are ‘only’ 10 million streamlines remaining. This is obviously not going to do as requested, since SIFT can only remove streamlines.

tck2connectome ${i}SIFT.tck nodesfixSGM.mif connectome.csv
QN: How can I extract other metrics for weighted networks such as the mean FA between 2 regions?

Check out the help page for the tck2connectome command; there’s a few mechanisms available for influencing this quantification. Specifically for calculating the mean FA between regions, take a look at this FAQ entry*.

*an updated FAQ article can be found in this wiki post

2 Likes