metallic.data

Dataloaders

class metallic.data.dataloader.MetaDataLoader(dataset: metallic.data.datasets.base.MetaDataset, batch_size: int = 1, shuffle: bool = True, sampler: Optional[torch.utils.data.sampler.Sampler] = None, batch_sampler: Optional[torch.utils.data.sampler.Sampler] = None, num_workers: int = 0, pin_memory: bool = False, drop_last: bool = False, timeout: float = 0.0, worker_init_fn=typing.Callable[[int], NoneType])[source]

Bases: torch.utils.data.dataloader.DataLoader

Samplers

class metallic.data.sampler.MetaRandomSampler(data_source: metallic.data.datasets.base.MetaDataset)[source]

Bases: torch.utils.data.sampler.RandomSampler

class metallic.data.sampler.MetaSequentialSampler(data_source: metallic.data.datasets.base.MetaDataset)[source]

Bases: torch.utils.data.sampler.SequentialSampler