-
Notifications
You must be signed in to change notification settings - Fork 7k
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
Remove deprecated path parameter to VideoReader and made src mandatory #8125
Conversation
torchvision/io/video_reader.py
Outdated
src = path | ||
warnings.warn("path is deprecated and will be removed in 0.17. Please use src instead") | ||
if isinstance(src, str) and not src: | ||
raise ValueError("src cannot be empty") |
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.
This isn't strictly needed, we could just rely on the error from the backend. This line just makes that error consistent across backends and thus is easier to test. If we remove this line, I'll just remove the test.
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.
LGTM
Co-authored-by: vfdev <vfdev.5@gmail.com>
… elajnaelfjnaelfjn
… mandatory (#8125) Summary: Co-authored-by: vfdev <vfdev.5@gmail.com> Reviewed By: vmoens Differential Revision: D52538998 fbshipit-source-id: a94116a744de3180bf9eea3fbfc02202a681cdd0
plus some minimal input check tests.