[Doc] Add data ingestion clarification for AIR converting existing pytorch code example - #32058
Merged
amogkam merged 4 commits intoFeb 13, 2023
Conversation
Signed-off-by: Yunxuan Xiao <yunxuanx@Yunxuans-MBP.local.meter>
woshiyyya
force-pushed
the
doc/clarify_pytorch_demo_data_ingest
branch
from
January 30, 2023 19:50
e62c7c3 to
55e066b
Compare
woshiyyya
marked this pull request as ready for review
January 30, 2023 22:32
woshiyyya
requested review from
a team,
Yard1,
amogkam,
gjoliver,
krfricke,
matthewdeng,
maxpumperla,
richardliaw and
xwjiang2010
as code owners
January 30, 2023 22:32
amogkam
reviewed
Jan 30, 2023
amogkam
left a comment
Contributor
There was a problem hiding this comment.
Thanks @woshiyyya! Left a comment
| "Then we download the data:" | ||
| "Then we download the data: \n", | ||
| "\n", | ||
| "Assumption for this tutorial: your existing code is using the `torchvision.datasets` native to PyTorch. This tutorial continues to use `torchvision.datasets` to allow you to make as few code changes as possible. **Everything in this tutorial is also possible if you choose to use Ray Data, and you will also get the benefits of efficient preprocessing and multi-worker batch prediction.** See [here](train-datasets) for resources to get started with Ray Data." |
Contributor
There was a problem hiding this comment.
- It can be any PyTorch DataLoader, not necessarily torchvision datasets
- The benefit is for parallel preprocessing-- you can still use Ray Data for batch prediction without using for training (as this tutorial already does)
- Maybe link to this tutorial instead: https://docs.ray.io/en/latest/ray-air/examples/torch_image_example.html?
Member
Author
There was a problem hiding this comment.
Thanks for the points! I have modified the description accordingly.
Signed-off-by: Yunxuan Xiao <yunxuanx@Yunxuans-MBP.local.meter>
angelinalg
reviewed
Feb 1, 2023
…ay_air.ipynb Co-authored-by: angelinalg <122562471+angelinalg@users.noreply.github.com> Signed-off-by: Yunxuan Xiao <xiaoyunxuan1998@gmail.com>
edoakes
pushed a commit
to edoakes/ray
that referenced
this pull request
Mar 22, 2023
…torch code example (ray-project#32058) The example under Ray AI Runtime/Example section directly used native PyTorch datasets for data loading. It's good to clarify that the current approach is for simplicity, the more recommended approach is to use the Ray dataset. Signed-off-by: Yunxuan Xiao <yunxuanx@Yunxuans-MBP.local.meter> Signed-off-by: Yunxuan Xiao <xiaoyunxuan1998@gmail.com> Co-authored-by: Yunxuan Xiao <yunxuanx@Yunxuans-MBP.local.meter> Co-authored-by: angelinalg <122562471+angelinalg@users.noreply.github.com> Co-authored-by: Yunxuan Xiao <yunxuanx@Yunxuans-MacBook-Pro.local> Signed-off-by: Edward Oakes <ed.nmi.oakes@gmail.com>
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why are these changes needed?
The example under Ray AI Runtime/Example section directly used native PyTorch datasets for data loading. It's good to clarify that the current approach is for simplicity, the more recommended approach is to use the Ray dataset.
Related issue number
Checks
git commit -s) in this PR.scripts/format.shto lint the changes in this PR.