Open gurubac opened 1 year ago
As far as I understand the num frames parameter, you can use it to specify the number of frames you want to have in the end. So if you have a 5-second video with 24 fps you have 5*24=120 frames in the beginning.
If you want to interpolate from 24 to 480 fps it means you increase your number of frames by a factor of 20. So you have to multiply your initial frames by this factor to find out how many frames you will require in the end: 120*20=2400
However, there seems to be a bug. Somehow the interpolation is wrong and the second half is always the final frame. You should be able to circumvent the bug by increasing the num frames by 2 and deleting the second half of the interpolated frames... Maybe it is easier to fix the bug, which should be somewhere around this line:
https://github.com/nihui/rife-ncnn-vulkan/blob/master/src/main.cpp#L713
EDIT: IMHO changing that line to the following produces much better results:
double scale = (double)(count - 1.0) / (numframe - 1.0);
i knew there was abug! what up devs!!! are you sleeping or what ? Do You have it compiled with that fix ?
I have this code which is trying to interpolate to 480 fps then render to 60 fps. (Ignore the comments they are from the sample code)
I keep getting the error [image2 @ 0x157f05860] Could find no file with path 'output_frames/%08d.png' and index in the range 0-4 output_frames/%08d.png: No such file or directory
If i take out the frames argument it works fine, and does the default of multiplying by 2. I have also tried doing -n 8, which does not work either.
Here is the full log.