-
Notifications
You must be signed in to change notification settings - Fork 665
Torchvsion API documentation page update #6313
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
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [Minor — line ~104, Also the wording "return-type hint for
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fixed
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [Nit, optional — line ~132,
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fixed
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [Minor — line ~223, regenerated stderr cell] The new cell output contains an absolute path from the developer's machine: Two issues:
Easiest fix: re-execute the notebook in the official build container (where this warning doesn't fire), or wrap the matplotlib import in
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fixed |
Large diffs are not rendered by default.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[Bug — incorrect description, line ~109]
ToPureTensoris not about "PIL.Image→torch.Tensorconversion". Perdali/python/nvidia/dali/experimental/torchvision/v2/totensor.py, it"Signals the pipeline to return a torch.Tensor instead of the default output type"and is a no-op marker — it works on any pipeline (HWC or CHW); typical use is on a CHW pipeline where the input is already atorch.Tensorand you want to force a plain-tensor return regardless of pipeline default. There is no PIL involvement.Also, torchvision's own
v2.ToPureTensorsemantically convertstv_tensorsback to plaintorch.Tensor, so linking it from a row whose description talks about PIL conversion is doubly confusing for users coming from torchvision.Suggested rewrite:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed