Skip to content
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

batch transforms for vision are slow #5

Open
butchland opened this issue Jul 19, 2020 · 4 comments
Open

batch transforms for vision are slow #5

butchland opened this issue Jul 19, 2020 · 4 comments
Labels
no stale Not exactly a wont fix, but can't close either, it will remain open just not worked on yet

Comments

@butchland
Copy link
Owner

butchland commented Jul 19, 2020

Confirming that batch transforms are slow
Same notebook without batch tfms - each epoch runs at 1:34 to 2:25 mins
For exact same notebook with batch tfms

@butchland
Copy link
Owner Author

Focusing on affine transforms (zoom, warp, rotate) + random resize crop GPU - they seem to cause much of the slowdown.
Normalize and lighting (contrast and brightness) transforms dont seem to slow it down.

Will start narrowing where the slowdown is and do some profiling on the specific tensor operations where its slow.

@butchland
Copy link
Owner Author

Will monitoring this issue filed with the pytorch-xla team as resolving it requires an update to pytorch-xla itself.

@butchland butchland added the no stale Not exactly a wont fix, but can't close either, it will remain open just not worked on yet label Aug 8, 2020
@butchland
Copy link
Owner Author

butchland commented Dec 14, 2020

Update: as of 2020/12/14, using updated Pytorch 1.7 XLA and latest fastai (2.1.8) and fastai_xla_extensions (0.0.4) packages, training with batch transforms is still slower than training without batch transforms.

@butchland
Copy link
Owner Author

Partially mitigated by this enhancement: #11

Leaving it open awaiting final action for additional lowerings in Pytorch XLA to support batch transforms

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
no stale Not exactly a wont fix, but can't close either, it will remain open just not worked on yet
Projects
None yet
Development

No branches or pull requests

1 participant