pyoptflow icon indicating copy to clipboard operation
pyoptflow copied to clipboard

Partial time derivative in Horn Schunck method

Open stefanieberger opened this issue 4 years ago • 2 comments

Hi,

I have a question regarding the HornSchunck method and the partial time derivative:

ft = im2 - im1

ft = filter2(im1, kernelT) + filter2(im2, -kernelT)

with kernelT = np.ones((2, 2))*.25

If my understanding is correct, you substract the values from the second image from the ones in the first image. In the Horn und Schunck paper I understood that you are supposed to do it the other way around.

Could you maybe tell me, if I understood it wrong or what the reasoning is to put this the other way around?

I also tried implementing the method myself, and exactly this issue seems to be my problem. If I implemented this with the minus sign in the im2 kernel, my directions are correct. I just donot understand why that is the case.

Thank you and greetings!

stefanieberger avatar Mar 09 '20 16:03 stefanieberger

This may be a mistake on my part, I will have to look into it. Thanks!

scivision avatar Mar 09 '20 20:03 scivision

I compared results with a couple different image pairs between 3 implementations, using matlab/RunHornSchunck.m.

This includes Matlab Computer Vision toolbox.

The plots appear similar qualitatively.

scivision avatar Oct 18 '21 06:10 scivision