Conversation
|
Do you have any reason to believe that codec 844516695 is always misread? |
|
Actually no, that's the only metadata I could find to tell apart my non-accurately readable videos from those that work flawlessly. So for now, I would hold off and not apply this PR. But maybe leave a message somewhere about the possibility for some videos not to work properly in OpenCV even though you dont recieve any warning. |
|
I added a note to the troubleshooting tips wiki: https://github.com/AlexEMG/DeepLabCut/wiki/Troubleshooting-Tips |
|
Hi. Are there any plans to reconcile this branch? |
|
I think this specific fix, is not generally useful for users. Does 844516695 happen to be your fourcc number? |
|
@catubc could you check if your video fourcc code is the same one I was reporting? |
|
we did add a more robust frame reader for some issues actually; You can set |
|
Indeed, sometimes the metadata is incorrect with respect to the actual data. Then one solution, as linked by @MMathisLab is to first iterate over the frames (to count how many there are) and then use that. For the create labeled video steps one can also pass the target frame rate (if I am not mistaken) |
|
@AlexEMG you can pass the argument |
|
Hey everyone, so for me the issue was a 2-step issue:
The solution that worked for me was to explicitly specify frame rate during the ffmpeg conversion process using -r 15 (in my case the vids had 15Hz).
So now DLC reports the correct frame rates. |
|
@auesro no worries! - |
|
Dear @MMathisLab , |
Following issue #475 , I modified slightly
video_processor.py.Picking up FPS correctly from the original video is essential to obtain a labeled video of correct duration. Both openCV and ffmpeg implementations depend on OpenCV to read this tag from the header in the original video file.
At least one type of file (that with fourcc code
844516695) is read by OpenCV as to have 1000 fps (being original 30 fps), which gives rise to a labeled video 33.33 times shorter than the original.If other file types were found to have the same problem, the
ifcondition could be easily expanded to include them.