zoom.data_loader.load_gii

zoom.data_loader.load_gii(gii: PathLike | tuple | nibabel.gifti.gifti.GiftiImage, atlas: str, density: str, hemi: str) numpy.ndarray[source]

Load GIFTI image.

Parameters:
  • gii (path_like str, tuple or nib.gifti.gifti.GiftiImage) –

    Recognized GIFTI image - If hemi in [‘L’,’lh’,’left’]:

    • path_like str: Filepaths to .gii

    • nib.gifti.gifti.GiftiImage

    • Otherwise, use both hemisphere:
      • tuple: must be organized as L/R pair
        • (str, str): Filepaths to .gii

        • (GiftiImage, GiftiImage)

  • atlas ({'fsaverage', 'fSLR'} optional,) – Name of surface atlas on which gii is defined.

  • density (str, optional) – Density of surface mesh on which gii is defined. Must becompatible with specified atlas.

  • hemi ({'L','lh','left','both'} optional,) – Hemisphere used to perform downstream analyses.

Returns:

gii_data – Data extracted from given GIFTI image.

Return type:

np.ndarray