build_synthetic_mnist_dataloader#
- composer.datasets.build_synthetic_mnist_dataloader(global_batch_size, is_train=True, drop_last=True, shuffle=True, num_unique_samples=100, device='cpu', memory_format=MemoryFormat.CONTIGUOUS_FORMAT, **dataloader_kwargs)[source]#
Builds a synthetic MNIST dataset.
- Parameters
global_batch_size (int) โ Global batch size.
is_train (bool) โ Whether to load the training data or validation data. Default:
True
.drop_last (bool) โ Drop remainder samples. Default:
True
.shuffle (bool) โ Shuffle the dataset. Default:
True
.num_unique_samples (int) โ number of unique samples in synthetic dataset. Default:
100
.device (str) โ device with which to load the dataset. Default:
cpu
.memory_format (
composer.core.MemoryFormat
) โ memory format of the tensors. Default:CONTIGUOUS_FORMAT
.**dataloader_kwargs (Any) โ Additional settings for the dataloader (e.g. num_workers, etc.)