Topic: Predicted motion using algo 1 or 2 is not linear

I'm experimenting with the algorithms and there's an issue with the interpolated frames. In the picture you can see three frames, whereby the first and the third frames are original and the second is interpolated with algorithm 1. The axe is moving up with a constant speed which means that the position of the axe in the second frame should be between those of frame one and three. But, the predicted position of the axe is much closer to the third frame (almost indentical) than it is to the first. This is more like frame doubling instead of interpolation.

Also, algorithm 2 renders exactly the same frame as algorithm 1. Though, if I increase threefold the frame number (num:3 instead of num:2), there is a difference between algorightms 1 and 2. But even then I can see that the axe in the interpolated frames is too close to the original frames 1 and 4 and there is a huge jump of the axe between the two interpolated frames 2 and 3.

Is there a way to fix it?

Here's my script:
**************************************************************************************
SetMemoryMax(1024)
LoadPlugin("C:\Program Files (x86)\AviSynth 2.5\plugins\svpflow1.dll")
LoadPlugin("C:\Program Files (x86)\AviSynth 2.5\plugins\svpflow2.dll")

threads=8
SetMTMode(3,6)
DirectShowSource(FILENAME).ConvertToYV12()
SetMTMode(2)

# All parameters set to defaults which means high quality frame doubling
super=SVSuper("{gpu:1}")
vectors=SVAnalyse(super, "{}")

SVSmoothFps(super, vectors, "{rate:{num:2, den:1, abs:false}, algo: 2}", url="www.svp-team.com", mt=threads)
# algo:
#       1 - sharp picture without any blending, moves pixels by motion vectors from next frame to current. Requires only backward motion vectors ("analyse.vectors: 2") so it's the fastest possible method.
#       2 - like 1st but moves pixels from the nearest (in terms of time) frame so it uses both backward and forward vectors. Recommended for 2D animations.
#      11 - time weighted blend of forward and backward partial motion compensations.
#      13 - same as 11th but with dynamic median added. Produces minimum artifacts but with noticeable halos around moving objects.
#      21 - 11th plus additional cover/uncover masking to minimize halos and improve frame edges.
#      23 - 21th plus extra vectors from adjacent frames for further decreasing of halos, can be less smooth than 21th.

#AssumeFPS(20)
#Levels(0, 1.3, 255, 0, 255)
**************************************************************************************

Post's attachments

algo1_num2.jpg 337.3 kb, 178 downloads since 2014-09-15 

Re: Predicted motion using algo 1 or 2 is not linear

max_pla3
Is there a way to fix it?
Yes. You need to use scene.mode=0 (see details here). In you case The scene with axe is hard to interpolation algorithms. Scene.mode=3 is used by default to get artifact-safe position of objects instead of true position.
Change line in your script:

SVSmoothFps(super, vectors, "{rate:{num:2, den:1, abs:false}, algo: 2, scene:{mode:0}}", url="www.svp-team.com", mt=threads)

Re: Predicted motion using algo 1 or 2 is not linear

do you know the algorithms used in this program? are there some detailed descriptions of them somewhere?
is there a source matlab code or something?

Re: Predicted motion using algo 1 or 2 is not linear

yonatan
Yes. What kind of description do you ask about? User manual or SVPFlow description? Source code is available under GPL license.