Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

OpenCV Kalman Filter used for position/orientation tracking: wrong results

Hi, I am following the Kalman Filter tutorial mentioned in the [Real time pose estimation tutorial] on OpenCV 2.4.11, but in my case, it is the camera that moves with respect to a certain origin in the world.

When I solve the iterative PNP problem for my scene, I get R and T matrices that looks quite good in terms of accuracy. But when I pass them on to the Kalman Filter (transition and measurement matrices were used as mentioned in the tutorial), the prediction matrix comes out to be all zeros, and the corrected R matrix is very close to the input R matrix, and the corrected T matrix almost in all cases looks something like this.

[4.7072399e+35; -0.33483902; -5.4207187e-33]

Whereas the input T from PNP is

[-196.0274563197073; 2.626786046055864; 0.9834547400622746]

Am I missing some sort of change I need to make from the tutorial? Because it is still a pose estimation problem, I figured I did not have to change much code-wise: although my process noise and measurement noise would be different, I just wanted to test for some initial idea of how the KF is working. Any suggestions/pointers would be very helpful.

OpenCV Kalman Filter used for position/orientation tracking: wrong results

Hi, I am following the Kalman Filter tutorial mentioned in the [Real Real time pose estimation tutorial] tutorial on OpenCV 2.4.11, but in my case, it is the camera that moves with respect to a certain origin in the world.

When I solve the iterative PNP problem for my scene, I get R and T matrices that looks quite good in terms of accuracy. But when I pass them on to the Kalman Filter (transition and measurement matrices were used as mentioned in the tutorial), the prediction matrix comes out to be all zeros, and the corrected R matrix is very close to the input R matrix, and the corrected T matrix almost in all cases looks something like this.

[4.7072399e+35; -0.33483902; -5.4207187e-33]

Whereas the input T from PNP is

[-196.0274563197073; 2.626786046055864; 0.9834547400622746]

Am I missing some sort of change I need to make from the tutorial? Because it is still a pose estimation problem, I figured I did not have to change much code-wise: although my process noise and measurement noise would be different, I just wanted to test for some initial idea of how the KF is working. Any suggestions/pointers would be very helpful.