Predict age from brain grey matter (regression) using Deep Learning. Aging is associated with grey matter (GM) atrophy. Each year, an adult lose 0.1% of GM. We will try to learn a predictor of the chronological age (true age) using GM measurements on a population of healthy control participants.
Such a predictor provides the expected brain age of a subject. Deviation from this expected brain age indicates acceleration or slowdown of the aging process which may be associated with a pathological neurobiological process or protective factor of aging.
There are 357 samples in the training set and 90 samples in the test set.
Voxel-based_morphometry VBM using cat12 software which provides:
-
Regions Of Interest (
rois
) of Grey Matter (GM) scaled for the Total Intracranial Volume (TIV):[train|test]_rois.csv
284 features. -
VBM GM 3D maps or images (
vbm3d
) of voxels in the MNI space:[train|test]_vbm.npz
contains 3D images of shapes (121, 145, 121). This npz contains also the 3D mask and the affine transformation to MNI referential. Masking the brain provides flat 331 695 input features (masked voxels) for each participant.
By default problem.get_[train|test]_data()
return the concatenation of 284 ROIs of
Grey Matter (GM) features with 331 695 features (voxels) within a brain mask.
Those two blocks are higly redundant.
To select only rois
features do:
X[:, :284]
To select only vbm
features do:
X[:, 284:]
The target can be found in [test|train]_participants.csv
files, selecting the
age
column for regression problem.
The main Evaluation metrics is the Root-mean-square deviation RMSE. We will also look at the R-squared R2.
This starting kit requires Python and the following dependencies:
numpy
scipy
pandas
scikit-learn
matplolib
seaborn
jupyter
torch
ramp-workflow
You can install the dependencies with the following command-line:
pip install -U -r requirements.txt
If you are using conda, we provide an environment.yml file for similar usage.
conda env create -n brain_age -f environment.yml
Then, you can activate/deasactivate the conda environment using:
conda activate brain_age
conda deactivate
- Download the data
python download_data.py
The train/test data will be available in the data
directory.
- Execute the jupyter notebook
jupyter notebook brain_age_starting_kit.ipynb
Play with this notebook to create your new model.
- Test Submission
The submissions need to be located in the submissions
folder.
For instance to create a linear_regression_rois
submission, start by
copying the starting kit
cp -r submissions/submissions/strating_kit submissions/submissions/linear_regression_rois.
Tune the estimator in thesubmissions/submissions/linear_regression_rois/estimator.py
file.
This file must contain a function get_estimator()
that returns a scikit learn Pipeline.
Then, test your submission locally:
ramp-test --submission linear_regression_rois
- Submission on N4H RAMP
Connect to your N4H RAMP account, select the brain_age_deep
event, and submit your estimator in the
sandbox section. x
Note that no training will be performed on the server side.
You thus need to join the weights of the model in a file called weights.pth
.