Created
October 14, 2021 16:04
-
-
Save fepegar/5d9e66d8302a110975efa932cd1ab2a0 to your computer and use it in GitHub Desktop.
TorchIO Resize demo
i may miss the point, but why not using resample, that will keep the ratio unchanged (even for a picture, it is better that having a deformed image ... no?
I have, say, 800x600 videos and I want them to be, say, 200x200. I could resample and crop or pad, or I could just resize, if I don't mind the distortion.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This is the standard resizing transform found in other frameworks for (2D) augmentation, like imgaug, TorchVision, etc. I added a usage example in the PR: TorchIO-project/torchio#642
I am planning to use it for augmentation of short video clips, because I don't mind that they look slightly distorted.
Maybe it was never a good idea to add it. I recently added a warning to the docs. Hopefully that will make things clear enough.