From 86e692d24f8e244dc31d5aac94038cd4771f4137 Mon Sep 17 00:00:00 2001 From: Phil Wang Date: Wed, 4 May 2022 11:52:24 -0700 Subject: [PATCH] fix random crop probability --- dalle2_pytorch/dalle2_pytorch.py | 2 +- setup.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dalle2_pytorch/dalle2_pytorch.py b/dalle2_pytorch/dalle2_pytorch.py index a9c853f..710fdcf 100644 --- a/dalle2_pytorch/dalle2_pytorch.py +++ b/dalle2_pytorch/dalle2_pytorch.py @@ -1808,7 +1808,7 @@ class Decoder(BaseGaussianDiffusion): image = resize_image_to(image, target_image_size) if exists(random_crop_size): - aug = K.RandomCrop((random_crop_size, random_crop_size)) + aug = K.RandomCrop((random_crop_size, random_crop_size), p = 1.) # make sure low res conditioner and image both get augmented the same way # detailed https://kornia.readthedocs.io/en/latest/augmentation.module.html?highlight=randomcrop#kornia.augmentation.RandomCrop diff --git a/setup.py b/setup.py index c8bb013..1410cb4 100644 --- a/setup.py +++ b/setup.py @@ -10,7 +10,7 @@ setup( 'dream = dalle2_pytorch.cli:dream' ], }, - version = '0.0.97', + version = '0.0.98', license='MIT', description = 'DALL-E 2', author = 'Phil Wang',