Last active
November 7, 2018 21:14
-
-
Save DanielTakeshi/bae674deb74bced22fdc3ca39c4fe3aa to your computer and use it in GitHub Desktop.
PyTorch transforms. See this for saving images: https://gist.github.com/DanielTakeshi/bbaf432347aafa2e9878e93fd6982fd7
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
I am testing different PyTorch transforms on my data, and saving sample | |
images as they are loaded during training. See examples below. |
transforms.Resize(256)
transforms.RandomResizedCrop(224)
By default, the random resized crop might have an initial crop as small as 8 percent of the original image, as you can see by some of the "zoomed in" stuff. And from the other one we did earlier (the Resize just made this 256x256 here before applying the RandomResizedCrop).
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
https://pytorch.org/docs/stable/torchvision/transforms.html#torchvision.transforms.RandomResizedCrop