Deep learning for NeuroImaging in Python.
Note
This page is a reference documentation. It only explains the class signature, and not how to use it. Please refer to the gallery for the big picture.
- class surfify.datasets._generic.GenericSurfDataset(root, patterns, subject_in_patterns, ico_order, targets, target_mapping=None, split='train', transforms=None, mask=None, contrastive=False, patch=False, n_max=None, withdraw_subjects=None, target_ico_order=None, size=3)[source]¶
A scalable neuroimaging dataset.
- Parameters:
root : str
the location where are stored the data.
patterns : str or list of str
the regex that can be used to retrieve the images of interest or any data that can be retrieved by nibabel.load.
subject_in_patterns : int or list of int
the folder level where the subject identifiers can be retrieved.
ico_order : int
the input data ico order.
targets : str or list of str
the dataset will also return these tabular data. A ‘participants.tsv’ file containing subject information (including the requested targets) is expected at the root.
target_mapping : dict, default None
optionaly, define a dictionary specifying different replacement values for different existing values. See pandas DataFrame.replace documentation for more information.
split : str, default ‘train’
define the split to be considered. A ‘<split>.tsv’ file containg the subject to include us expected at the root.
transforms : callable or list of callable, default None
a function that can be called to augment the input images.
mask : array, default None
optionnaly, mask the input image.
contrastive : bool, default False
optionaly, create a contrastive dataset that will return a pair of augmented images.
patch : bool, default False
optionaly, return triangular patches.
n_max : int, default None
optionaly, keep only a subset of subjects (for debuging purposes).
withdraw_subjects : list of str, default None
optionaly, provide a list of subjects to remove from the dataset.
target_ico_order : int, default None
the desired ico order (data will be downsample to this resolution).
size : int, default 3
the patch size.
Follow us