Skip to content

utils_templateflow

Module to fetch a population average template from TemplateFlow.

Keywords : template, population average, reference


Format : tuple path(template), val(res), val(cohort)

TypeDescriptionMandatoryPattern
templatefileTemplateFlow template name. e.g. MNI152NLin2009cAsym Refer to the TemplateFlow documentation for available templates. https://www.templateflow.org/browse/True
resintegerResolution of the template. This is optional, but will be used to fetch the template at the specified resolution and make it accessible in the output channels.False
cohortintegerCohort of the template. This is optional, but will be used to fetch the template for the specified cohort and make it accessible in the output channels.False

Format : path(tpl-${template})

TypeDescriptionMandatoryPattern
tpl-${template}directoryDirectory containing the requested template, with all available resolutions and masks/maps.True

Format : path(*T1w.nii.gz)

TypeDescriptionMandatoryPattern
*T1w.nii.gzfileT1w image of the requested template.True

Format : path(*T2w.nii.gz)

TypeDescriptionMandatoryPattern
*T2w.nii.gzfileT2w image of the requested template.True

Format : path(*desc-brain_mask.nii.gz)

TypeDescriptionMandatoryPattern
*desc-brain_mask.nii.gzfileBrain mask of the requested template.True

Format : path(*label-CSF_probseg.nii.gz)

TypeDescriptionMandatoryPattern
*label-CSF_probseg.nii.gzfileCSF probability map of the requested template.True

Format : path(*label-GM_probseg.nii.gz)

TypeDescriptionMandatoryPattern
*label-GM_probseg.nii.gzfileGM probability map of the requested template.True

Format : path(*label-WM_probseg.nii.gz)

TypeDescriptionMandatoryPattern
*label-WM_probseg.nii.gzfileWM probability map of the requested template.True

Format : path(${template}_metadata.json)

TypeDescriptionMandatoryPattern
${template}_metadata.jsonfileMetadata file containing information about the template.True*.json

Format : path(${template}_citations.bib)

TypeDescriptionMandatoryPattern
${template}_citations.bibfileFile containing citations for the template.True*.bib

Format : path(versions.yml)

TypeDescriptionMandatoryPattern
versions.ymlfileFile containing software versionsTrueversions.yml

DescriptionDOI
TemplateFlowTemplateFlow is a modular, version-controlled resource that allows researchers to use templates “off-the-shelf”.10.1038/s41592-022-01681-2


Last updated : 2025-10-30