I tried to add it randomly and used the following code:
transforms.RandomApply(AddGaussianNoise(args.mean, args.std), p=0.5)
But I received an error:
assert isinstance(transforms, (list, tuple))
AssertionError
Is there anything wrong with my code? Thank you!