added stream specification option to read_video#1222
added stream specification option to read_video#1222CCareaga wants to merge 6 commits intopytorch:mainfrom
Conversation
Codecov Report
@@ Coverage Diff @@
## master #1222 +/- ##
==========================================
- Coverage 65.64% 65.63% -0.02%
==========================================
Files 74 74
Lines 5784 5788 +4
Branches 884 886 +2
==========================================
+ Hits 3797 3799 +2
- Misses 1723 1725 +2
Partials 264 264
Continue to review full report at Codecov.
|
bjuncek
left a comment
There was a problem hiding this comment.
Looks good to me - neat fix
fmassa
left a comment
There was a problem hiding this comment.
Thanks for the PR!
I think this is a good feature to have, but I'm not yet sure about how it should be handled.
I wonder if we can have multiple video / audio streams in a video? In which case, the proposed solution wouldn't be enough.
|
@fmassa Interesting, do you have a scenario in mind where a video might have multiple streams of a certain modality? Also, would the |
|
@CCareaga some video formats supports an arbitrary number of streams per type, see e.g., https://video.stackexchange.com/questions/20933/can-video-have-multiple-streams-like-it-has-2-audio-streams
One possible scenario I'd imagine would be having stereo video (for example for augmented reality with headsets). Still, the current API of torchvision does not support that, as we return a single In this case, I'd say it would be ok for now to assume that we can specify it in the way you proposed. |
fmassa
left a comment
There was a problem hiding this comment.
This looks good to me, thanks a lot!
I have only one more comment, which relates to the default empty type and shapes.
|
@fmassa Oh okay, that totally seems like a valuable feature. With the current read video function it would probably require a decent overhaul. |
Added functionality described in issue #1220