smoothing icon indicating copy to clipboard operation
smoothing copied to clipboard

No clamp for input after Gaussian data augumentation?

Open xinghua-qu opened this issue 3 years ago • 1 comments

# augment inputs with noise
inputs = inputs + torch.randn_like(inputs, device='cuda') * noise_sd

Line 109 in train.py.

If there is no torch.clamp() after line 109, it is possible that the input image will exceed its allowed pixel value range (i.e., [0,1])

xinghua-qu avatar May 04 '22 02:05 xinghua-qu

I have the same question. Why the implementation of this approach does not clip the image within the range [0,1]. Without clarification, I think it is a pitfall. When using torch.clamp(), the results of the paper are incorrect.

vietvo89 avatar Mar 08 '24 00:03 vietvo89