We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c06274e commit 4002c0dCopy full SHA for 4002c0d
timm/data/transforms.py
@@ -179,8 +179,12 @@ def transforms_imagenet_train(
179
transforms.RandomHorizontalFlip()
180
]
181
if auto_augment:
182
+ if isinstance(img_size, tuple):
183
+ img_size_min = min(img_size)
184
+ else:
185
+ img_size_min = img_size
186
aa_params = dict(
- translate_const=img_size[-1] // 2 - 1,
187
+ translate_const=int(img_size_min * 0.45),
188
img_mean=tuple([min(255, round(255 * x)) for x in mean]),
189
)
190
if interpolation and interpolation != 'random':
0 commit comments