-
Notifications
You must be signed in to change notification settings - Fork 64
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Randomization of transforms per image per batch #231
Conversation
Changes look fine to me for rand_color_jitter. Performance can be improved by doing some sort of kernel aggregation and selective image level filtering within the kernel. Once we have proved that rand_color_jitter is good for model accuracy/froc scores, can look into optimizing performance for this. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me.
Have some minor suggestions.
np_output = spt.rand_image_flip(arr_batch, prob=1.0, spatial_axis=(2, 3)) | ||
np_output = spt.rand_image_flip(arr_batch, | ||
prob=1.0, | ||
spatial_axis=(2, 3), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Parameter input is not consistent. Here it uses (2, 3)
, but below code, it uses [2, 3]
.
@@ -130,7 +131,8 @@ def image_rotate_90( | |||
def rand_image_flip( | |||
img: Any, | |||
spatial_axis: tuple(), | |||
prob: float = 0.1 | |||
prob: float = 0.1, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What would be the good default value for this?
Having 0.5
for the default value looks more useful here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will update it.
Co-authored-by: Gigon Bae <[email protected]>
Generally seems reasonable. Do we want to test Edit: Filed issue ( #259 ) to track this. |
@gpucibot merge |
Can one of the admins verify this patch? |
As per #225
Randomness updated to be applied to per image in the batch. Existing functionality of applying randomness on entire batch at once is unchanged.