Menu

Package that provides tools for brain MRI Deep Learning pre-processing.

Note

This page is a reference documentation. It only explains the function signature, and not how to use it. Please refer to the gallery for the big picture.

brainprep.workflow.fsreconall.brainprep_fsreconall(subjid, anatomical, outdir, template_dir, do_lgi=False, wm=None)[source]

Define the FreeSurfer recon-all pre-processing workflow.

Parameters:

subjid : str

the subject identifier.

anatomical : str

path to the anatomical T1w Nifti file.

outdir : str

the destination folder.

template_dir : str

path to the ‘fsaverage_sym’ template.

do_lgi : bool

optionally perform the Local Gyrification Index (LGI) ” computation (requires Matlab).

wm : str

optionally give a path to the custom white matter mask (we assume you have run recon-all at least upto wm.mgz creation). It has to be in the subject’s FreeSurfer space (1mm iso + aligned with brain.mgz) with values in [0, 1] (i.e. probability of being white matter). For example, it can be the ‘brain_pve_2.nii.gz” white matter probability map created by FSL Fast.

Follow us

© 2025, brainprep developers