home/ atoms/ diffusion-data-augmentation

Random horizontal flipping during training improves sample quality in image diffusion models

The DDPM paper found that applying random horizontal flips to training images slightly improved sample quality for CIFAR-10. This is a simple data augmentation that effectively doubles the training data by presenting mirror-image versions of each sample. For the Fashion-MNIST tutorial, horizontal flips are also applied via transforms.RandomHorizontalFlip(). This is an example of domain-appropriate augmentation: horizontal flips are realistic (a T-shirt looks the same mirrored), unlike vertical flips which would be unrealistic for clothing or natural scenes.

Examples

PyTorch transform: transforms.RandomHorizontalFlip(). Applied within dataset.with_transform() so augmentation happens on-the-fly during training, not stored.

Assessment

Explain why horizontal flip augmentation is appropriate for CIFAR-10 and Fashion-MNIST but might not be appropriate for other datasets. How does on-the-fly augmentation differ from pre-augmenting the dataset?

“random horizontal flips during training for CIFAR10; we tried training both with and without flips, and found flips to improve sample quality slightly”
corpus · the-annotated-diffusion-model-hugging-face-ddpm-in-pytorch-s · chunk 11