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.cortical.recon_all_longitudinal(fsdirs, sid, outdir, timepoints=None)[source]

Assuming you have run recon-all for all timepoints of a given subject, and that the results are stored in one subject directory per timepoint, this function will:

  • create a template for the subject and process it with recon-all

  • rerun recon-all for all timepoints of the subject using the template

Parameters:

fsdirs : list of str

the FreeSurfer working directory where to find the the subject associated timepoints.

sid : str

the current subject identifier.

outdir : str

destination folder.

timepoints : list of str, default None

the timepoint names in the same order as the subjfsdirs. Used to create the subject longitudinal IDs. By default timepoints are “1”, “2”…

Returns:

template_id : str

ID of the subject template.

long_sids : list of str

longitudinal IDs of the subject for all the timepoints.

Follow us

© 2025, brainprep developers