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

Explain on the fly transforms for PyTorch #2513

Merged
merged 4 commits into from
Oct 14, 2023
Merged

Conversation

adam-narozniak
Copy link
Member

Issue

So far, immediate transforms have been used to create PyTorch DataLoader from datasets.Dataset. It is not how the typically downloaded Dataset from PyTorch torchvision behaves. The transforms applied to it execute at the access time. The difference might bring confusion to users or introduce unexpected behavior.

Proposal

Explain how to do the transforms on-the-fly that strictly resembles the PyTorch way of doing it (which users are probably familiar with and expect).
The instant transform to all the dataset still exist in the documentation but the difference in the behavior is explained. Also, it's explained after the on-the-fly transforms.

@danieljanes danieljanes enabled auto-merge (squash) October 14, 2023 10:23
@danieljanes danieljanes merged commit e27fe76 into main Oct 14, 2023
29 checks passed
@danieljanes danieljanes deleted the fds-improve-pytorch branch October 14, 2023 18:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants