Research Group on Visual Computation

Generalized Pose Estimation from Line Correspondences with Known Vertical Direction

Icon of project Related projects: Line-based absolute pose with known vertical direction

Description

This page contains the code for an absolute pose solver in case of a generalized camera using Line Correspondences. We assume that the vertical direction of the camera system (e.g. a gravity vector) is available.

Files

All the codes are released under the GNU General Public License.
  • gPnLup

    The code contains the methods described in our [1] publication, you can download the full test environment here: code. The optimal solution is obtained as the first solution in the returned list of the poses sorted based on the line backprojection error.

    Call the function as: [Pose] = gPnLup(input,camNum,lineNum)

    Example input: gPnLup input 1, data for 3 cameras (2 perspective + Omnidirectional) and 60 2D-3D line correspondances

    Example input: gPnLup input 2, data for 3 cameras (2 Omnidirectional + perspective) and 60 2D-3D line correspondances

    Input parameters: a structure input with

    1. input.Camera(:).Line2D.start = normalized coordinates of the image line segment's startpoint on the unit sphere (nx3)
    2. input.Camera(:).Line2D.end = normalized coordinates of the image line segment's endpoint on the unit sphere (nx3)
    3. input.Camera(:).line3D.start = start points of the 3D line segments in the world coordinate system (nx3)
    4. input.Camera(:).line3D.end = end points of the 3D line segments in the world coordinate system (nx3)
    5. input.vertical_direction = known vertical direction angles
    6. camNum= number of camera
    7. lineNum= number of 2D-3D line pairs to be used

    Note that the algorithm expects normalized coordinates on the unit sphere. If our camera is a calibrated perspective camera and we have a matrix \mx{I} of size 3xn which contains the corresponding 2D measurements with homogenous coordinate representation in the image plane then we transform the measurements using K calibration matrix:
    temp = inv(K) * I;
    I_norms = sqrt(sum(temp.*temp));
    I_normalized = temp ./ repmat(I_norms,3,1);

    Output:
    poses: a list of 4*4 matrix acts from the world coordinate system to the reference camera ('Absolute pose'). The optimal pose is ranked as the first solution in the returned list based on the line backprojection error.

    Please cite our [1] publication whenever you use the implementation.

Publications to cite:
  1. Nora Horanyi, Zoltan Kato, Generalized Pose Estimation from Line Correspondences with Known Vertical Direction, In Proceedings of International Conference on 3D Vision, IEEE, Qingdao, China, pp. 1-10, 2017. [bibtex]

Hichem Abdellali has been awarded the Doctor of Philosophy (PhD.) degree...

2022-04-30


Hichem Abdellali has been awarded the KÉPAF Kuba Attila prize...

2021-06-24