Skip to content

Latest commit

 

History

History
31 lines (19 loc) · 3.63 KB

README.md

File metadata and controls

31 lines (19 loc) · 3.63 KB

Towards Deep Learning for Connectome Mapping: A Block Decomposition Framework

We are delighted to provide the neuroscience community with a new Block Decomposition and Stitching (BDS) framework for mapping connectomes using a diffusion-weighted Magnetic Resonance Imaging (dMRI) data. This repository provides the code that could be used to map connectomes using the two variants of the proposed BDS algorithm, namely deterministic and probabilistic versions.

The rest of this document is sectioned according to folders and scripts in this repository.

Data: The folder contains a sample phantom for testing the algorithm.

  • nii (dMRI data)
  • nii (white-matter mask for ground.nii.gz)
  • txt (diffusion-weight gradients and b-value used for simulating ground.nii)
  • tck (5000 streamlines generated for ground.nii using Deterministic CSD with default parameters. The minimum and maximum streamline length for the generated streamlines was 10 and 50 mm respectively)
  • block_image.mat (block-image generated from ground.tck using demo_BI.m, explained below)

demo_BI.m: provides a demonstration of generating a block-image directly from a tractogram (set of streamlines generated for a dMRI dataset) specified either in “.tck” or “.trk” format. A tractogram can be generated using any tractography algorithm. The code generates block images using a stride of 1, given that we found this stride length yielded better performance in comparison to higher strides (>1).

This script generates a block-image .mat file for a dMRI with dimension X x Y x Z (ignoring the number of gradients) using a block size of NNN with an intra-block connectivity matrix M x M. The output file is a 2d matrix with the following dimensions

((X-N+1) x (Y-N+1) x (Z-N+1), number of elements in the upper triangle of M x M)

When mapping the streamlines to block, the 3d coordinate locations of the block are converted into linear indices. The simple case of generating block-image using 2d block (NN) is demonstrated in the figure below. The same methodology is followed for converting subscripts to linear indices in MATLAB (sub2ind)

alt text

Auxiliary functions are stored in the strm_to_block folder. This folder should be added to your MATLAB path.

demo_BDS.m provides a demonstration of the BDS algorithm (both deterministic and probabilistic variants). It requires two input files: block-image generated using the process demonstrated in the above figure and the cortical parcellation.

Auxiliary functions are stored in the BDS folder. This folder should be added to your MATLAB path.

Note: Many streamlines connect the same pair of regions in a block. So for computational efficiency, a tractogram with millions of streamline are not recommended for generating a block-image. In Demo_BI.m, the input streamlines are normalized i.e. streamlines are divided by voxel size. This is done to ensure that the 'mm' streamlines maps to the dMRI spatial domain. If the input tractogram/streamlines are already normalized, then change the voxel size to 1 in the demo_BI.m (info.info.PixelDimensions(1)=1)