nip.scenario_base.data.NestedArrayDictDataLoader#
- class nip.scenario_base.data.NestedArrayDictDataLoader(dataset: NestedArrayDictDataset, batch_size: int | None = 1, shuffle: bool = False, drop_last: bool = False, generator: Generator | None = None, initial_skip: int = 0, **kwargs)[source]#
Dataloader class for NestedArrayDict datasets.
- Parameters:
dataset (NestedArrayDictDataset) – The dataset to load.
batch_size (int, default=1) – How many samples per batch to load.
shuffle (bool, default=False) – Set to True to have the data reshuffled at every epoch.
drop_last (bool, default=False) – Set to True to drop the last incomplete batch, if the dataset size is not divisible by the batch size.
generator (torch.Generator | None, default=None) – Generator used for the random sampling.
initial_skip (int, default=0) – Number of initial samples to skip.
Methods Summary
__init__
(dataset[, batch_size, shuffle, ...])Attributes
_auto_collation
_index_sampler
multiprocessing_context
dataset
batch_size
num_workers
pin_memory
drop_last
timeout
sampler
pin_memory_device
prefetch_factor
Methods