meta-pytorch / meta-pytorch/torchcodec
Create unit tests based on variable FPS video
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 1.2k
- Forks
- 125
- Avg merge
- 22h 47m
- Merged PRs (30d)
- 54
Description
VideoDecoder can handle variable FPS videos in some scenarios, but doesn't handle them well in other scenarios. We should have some unit tests which use a variable FPS video. We should create a small variable FPS video and check it in. A command that can create one:
ffmpeg -i video.mp4 -vf "setpts=PTS*if((gt(N\,30))\,1\,2)+1/TB" -c:v libx264 -bf 0 var_fps_video.mp4
I think it's fine to use one of the kinds of videos FFmpeg can generate on-the-fly, such as testsrc or mandelbrot.
Everything in VideoDecoder should work in exact seeking mode. It will probably fail in approximate mode.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the VideoDecoder entry point and review how exact and approximate seeking are tested. Generate a small variable-FPS fixture with the provided FFmpeg command or a testsrc/mandelbrot source, then add coverage for exact seeking and document the approximate-mode behavior; done means the tests exercise the variable-FPS video and expose the expected result.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- audio-video-rtc, testing-qa
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100