def transforms(self): train_transforms = Compose([ # RandomScale(scale=self.scale), Resize(size=self.size), # RandomCrop(crop_size=self.size), RandomFlip() ]) val_transforms = Compose([Resize(size=self.size)]) return train_transforms, val_transforms
def transforms(self): train_transforms = Compose([ Resize(size=self.size), Normalize() if self.normalize else Tensorize() ]) val_transforms = Compose([ Resize(size=self.size), Normalize() if self.normalize else Tensorize() ]) return train_transforms, val_transforms
def transforms(self): train_transforms = Compose([ RandomScale(scale=self.scale), RandomCrop(crop_size=self.size, ignore_idx=self.ignore_idx), Resize(size=self.size), RandomFlip(), Normalize() if self.normalize else Tensorize() ]) val_transforms = Compose([ Resize(size=self.size), Normalize() if self.normalize else Tensorize() ]) return train_transforms, val_transforms
def transforms(self): train_transforms = Compose([ # RandomScale(scale=self.scale), # RandomCrop(crop_size=(self.size[1], self.size[0])), Resize(size=(self.size[1], self.size[0])), RandomFlip(), Normalize() if self.normalize else Tensorize() # ]) val_transforms = Compose([ Resize(size=self.size), Normalize() if self.normalize else Tensorize() #Tensorize() ]) return train_transforms, val_transforms