build_synthetic_ade20k_dataloader#

composer.datasets.build_synthetic_ade20k_dataloader(global_batch_size, *, split='train', drop_last=True, shuffle=True, final_size=512, num_unique_samples=100, device='cpu', memory_format=MemoryFormat.CONTIGUOUS_FORMAT, **dataloader_kwargs)[source]#

Builds a synthetic ADE20k dataloader.

Parameters
  • batch_size (int) โ€“ Global batch size.

  • split (str) โ€“ The dataset split to use either โ€˜trainโ€™, โ€˜valโ€™, or โ€˜testโ€™. Default: 'train`.

  • drop_last (bool) โ€“ Whether to drop last samples. Default: True.

  • shuffle (bool) โ€“ Whether to shuffle the dataset. Default: True.

  • final_size (int) โ€“ The final size of the image and target. Default: 512.

  • 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 (Dict[str, Any]) โ€“ Additional settings for the dataloader (e.g. num_workers, etc.)