def transform_tr(self, sample):
    if (len(sample) == 2):
        composed_transforms = transforms.Compose([tr.RandomHorizontalFlip(), tr.RandomScaleCrop(base_size=self.args.base_size, crop_size=self.args.crop_size), tr.RandomGaussianBlur(), tr.Normalize(mean=(0.485, 0.456, 0.406), std=(0.229, 0.224, 0.225)), tr.ToTensor()])
        return composed_transforms(sample)
    else:
        composed_transforms = transforms.Compose([tr_sp.RandomHorizontalFlip(), tr_sp.RandomScaleCrop(base_size=self.args.base_size, crop_size=self.args.crop_size), tr_sp.RandomGaussianBlur(), tr_sp.Normalize(mean=(0.485, 0.456, 0.406), std=(0.229, 0.224, 0.225)), tr_sp.ToTensor()])
        return composed_transforms(sample)
def transform_tr(self, sample):
    if (len(sample) == 2):
        composed_transforms = transforms.Compose([tr.RandomHorizontalFlip(), tr.RandomScaleCrop(base_size=self.args.base_size, crop_size=self.args.crop_size), tr.RandomGaussianBlur(), tr.Normalize(mean=(0.485, 0.456, 0.406), std=(0.229, 0.224, 0.225)), tr.ToTensor()])
        return composed_transforms(sample)
    else:
        composed_transforms = transforms.Compose([tr_sp.RandomHorizontalFlip(), tr_sp.RandomScaleCrop(base_size=self.args.base_size, crop_size=self.args.crop_size), tr_sp.RandomGaussianBlur(), tr_sp.Normalize(mean=(0.485, 0.456, 0.406), std=(0.229, 0.224, 0.225)), tr_sp.ToTensor()])
        return composed_transforms(sample)