-
Notifications
You must be signed in to change notification settings - Fork 664
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Hi,
The probability of GaussBlur function seems to be inverted.
class GaussianBlur(v2.RandomApply):
"""
Apply Gaussian Blur to the PIL image.
"""
def __init__(self, *, p: float = 0.5, radius_min: float = 0.1, radius_max: float = 2.0):
# NOTE: torchvision is applying 1 - probability to return the original image
keep_p = 1 - p
transform = v2.GaussianBlur(kernel_size=9, sigma=(radius_min, radius_max))
super().__init__(transforms=[transform], p=keep_p)While
class RandomApply(Transform):
"""Apply randomly a list of transformations with a given probability.
Args:
transforms (sequence or torch.nn.Module): list of transformations
p (float): probability of applying the list of transforms
"""I just came across this on DINOv2 and it seems like you are using the same base.
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working