Skip to content

Commit

Permalink
Revert Augmentation Change
Browse files Browse the repository at this point in the history
This caused significant degradation in performance. Reverting it for original behavior unless proved to be better
  • Loading branch information
Eve-ning committed Jun 19, 2024
1 parent e9cb00a commit fd6ca40
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions tests/model_tests/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
RandomRotation,
RandomApply,
Resize,
RandomResizedCrop,
)
from torchvision.transforms.v2 import RandomHorizontalFlip

Expand Down Expand Up @@ -54,9 +53,8 @@ def rand_weak_aug(size: int):
[
ToImage(),
ToDtype(torch.float32, scale=True),
RandomResizedCrop(
size, scale=(0.08, 1.0), ratio=(0.95, 1.05), antialias=True
),
Resize(size, antialias=True),
CenterCrop(size),
RandomHorizontalFlip(),
RandomVerticalFlip(),
RandomApply([RandomRotation((90, 90))], p=0.5),
Expand All @@ -80,9 +78,8 @@ def rand_strong_aug(size: int):
[
ToImage(),
ToDtype(torch.float32, scale=True),
RandomResizedCrop(
size, scale=(0.08, 1.0), ratio=(0.9, 1.1), antialias=True
),
Resize(size, antialias=True),
RandomCrop(size, pad_if_needed=False),
RandomHorizontalFlip(),
RandomVerticalFlip(),
RandomApply([RandomRotation((90, 90))], p=0.5),
Expand Down

0 comments on commit fd6ca40

Please sign in to comment.