megatron.data.autoaugment.ImageNetPolicy#
- class megatron.data.autoaugment.ImageNetPolicy(fillcolor=(128, 128, 128))#
Bases:
object
Definition of an ImageNetPolicy.
Implements a fixed AutoAugment data augmentation policy targeted at ImageNet training by randomly applying at runtime one of the 25 pre-defined data augmentation sub-policies provided in Reference [1].
Usage example as a Pytorch Transform: >>> transform=transforms.Compose([transforms.Resize(256), >>> ImageNetPolicy(), >>> transforms.ToTensor()])
- __call__(img)#
Define call method for ImageNetPolicy class.
- __repr__()#
Define repr method for ImageNetPolicy class.