Note

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

nilearn.datasets.fetch_atlas_schaefer_2018#

nilearn.datasets.fetch_atlas_schaefer_2018(n_rois=400, yeo_networks=7, resolution_mm=1, data_dir=None, base_url=None, resume=True, verbose=1)[source]#

Download and return file names for the Schaefer 2018 parcellation.

New in version 0.5.1.

This function returns a Deterministic atlas, and the provided images are in MNI152 space.

For more information on this dataset, see 1, 2, and 3.

Parameters
n_rois{100, 200, 300, 400, 500, 600, 700, 800, 900, 1000}, optional

Number of regions of interest. Default=400.

yeo_networks{7, 17}, optional

ROI annotation according to yeo networks. Default=7.

resolution_mm{1, 2}, optional

Spatial resolution of atlas image in mm. Default=1mm.

data_dirpathlib.Path or str, optional

Path where data should be downloaded. By default, files are downloaded in home directory.

base_urlstr, optional

Base URL of files to download (None results in default base_url).

resumebool, optional

Whether to resume download of a partly-downloaded file. Default=True.

verboseint, optional

Verbosity level (0 means no message). Default=1.

Returns
datasklearn.utils.Bunch

Dictionary-like object, contains:

  • ‘maps’: str, path to nifti file containing the 3D Nifti1Image (its shape is (182, 218, 182)). The values are consecutive integers between 0 and n_rois which can be interpreted as indices in the list of labels.

  • ‘labels’: numpy.ndarray of str, array containing the ROI labels including Yeo-network annotation.

    Warning

    The list of labels does not contain ‘Background’ by default. To have proper indexing, you should either manually add ‘Background’ to the list of labels:

    # Prepend background label
    data.labels = np.insert(data.labels, 0, 'Background')
    

    Or be careful that the indexing should be offset by one:

    # Get region ID of label '7Networks_LH_Vis_3' when
    # 'Background' was not added to the list of labels:
    # idx should be equal to 3:
    idx = np.where(
        data.labels == b'7Networks_LH_Vis_3'
    )[0] + 1
    
  • ‘description’: str, short description of the atlas and some references.

Notes

Release v0.14.3 of the Schaefer 2018 parcellation is used by default. Versions prior to v0.14.3 are known to contain erroneous region label names. For more details, see https://github.com/ThomasYeoLab/CBIG/blob/master/stable_projects/brain_parcellation/Schaefer2018_LocalGlobal/Parcellations/Updates/Update_20190916_README.md

Licence: MIT.

References

1

Schaefer 2018 parcellation. https://github.com/ThomasYeoLab/CBIG/tree/v0.14.3-Update_Yeo2011_Schaefer2018_labelname/stable_projects/brain_parcellation/Schaefer2018_LocalGlobal/Parcellations. Accessed: 2021-05-19.

2

Alexander Schaefer, Ru Kong, Evan M Gordon, Timothy O Laumann, Xi-Nian Zuo, Avram J Holmes, Simon B Eickhoff, and B T Thomas Yeo. Local-Global Parcellation of the Human Cerebral Cortex from Intrinsic Functional Connectivity MRI. Cerebral Cortex, 28(9):3095–3114, 07 2017. URL: https://doi.org/10.1093/cercor/bhx179, arXiv:https://academic.oup.com/cercor/article-pdf/28/9/3095/25696344/bhx179\_schaeferfullsupp.pdf, doi:10.1093/cercor/bhx179.

3

B. T. Thomas Yeo, Fenna M. Krienen, Jorge Sepulcre, Mert R. Sabuncu, Danial Lashkari, Marisa Hollinshead, Joshua L. Roffman, Jordan W. Smoller, Lilla Zöllei, Jonathan R. Polimeni, Bruce Fischl, Hesheng Liu, and Randy L. Buckner. The organization of the human cerebral cortex estimated by intrinsic functional connectivity. Journal of Neurophysiology, 106(3):1125–1165, 2011. PMID: 21653723. URL: https://doi.org/10.1152/jn.00338.2011, arXiv:https://doi.org/10.1152/jn.00338.2011, doi:10.1152/jn.00338.2011.