chaoyuaw/pytorch-coviar

About counting frames

sjtuxcx opened this issue · 2 comments

I find the value of function get_num_frames is 1 less than actual video length. I use 100 frames to create a video but only get 99 decoded frames. I find the missing frame is the last one. Can you help me out? Thanks very much!

Hi, sorry I cannot quite see what's going on, and don't have a good explanation for this. Would it help if you add a dummy frame at the end to construct a 101-frame video as a temporary solution?

@chaoyuaw Yes, I did add a dummy frame as a temporary solution.Thank you for the advise. Here is an another little question about motion vector. Is the first channel and second channel of motion vector(shape is [h,w,2]) means pixel movement on X-axis and Y-axis(or Y-axis and X-axis)? Thanks!