Wednesday, May 10, 2017

computer vision - Obtain motion between image features by means of the homography matrix


I have been reading several really good answers about how to obtain camera pose (rotation, translation, etc), such as this one and this one, but I am not sure how this applies to my problem.



  • My problem: I have two images of a planar scene (terrain image from above), and I want find the motion that the camera has experienced between the two images $(dx, dy)$.


  • What I have done: I have image1 and image2 of a terrain with their features matched, and obtained its homography via OpenCV's C++ function:


    cv::Mat H = cv::findHomography(image1points, image2points, CV_RANSAC);

    Which looks like it is indeed an affine transformation: $$\pmatrix{a&b&c\\d&e&f\\0&0&1}$$





  • What I need help with:



    1. In this matrix, I don't know what is the reference frame of the $dx$, $dy$ parameters. $(dx, dy) = (c, f)$

    2. How can I extract the rotation angle and scaling factor between the 2D axes of the two images. (Right now I am using this suggestion, but results don't seem reliable).

    3. Once I have all the four parameters: $dx$, $dy$, rotation angle, scaling. How can I actually compute the motion of the camera (between the images) using the first image's axes as my reference frame.






No comments:

Post a Comment

periodic trends - Comparing radii in lithium, beryllium, magnesium, aluminium and sodium ions

Apparently the of last four, $\ce{Mg^2+}$ is closest in radius to $\ce{Li+}$. Is this true, and if so, why would a whole larger shell ($\ce{...