Randomize blur effect

This commit is contained in:
James Betker 2020-05-24 12:35:41 -06:00
parent 27a548c019
commit cc4571eb8d

View File

@ -143,7 +143,8 @@ class LQGTDataset(data.Dataset):
self.opt['use_rot'])
if self.opt['use_blurring']:
img_LQ = cv2.GaussianBlur(img_LQ, (3, 3), 10)
blur_sig = int(random.randrange(0, 10))
img_LQ = cv2.GaussianBlur(img_LQ, (3, 3), blur_sig)
if self.opt['color']: # change color space if necessary
img_LQ = util.channel_convert(C, self.opt['color'],