MRPT  2.0.1
List of all members | Public Member Functions | Private Attributes
mrpt::vision::pnp::lhm Class Reference

Detailed Description

Author
Chandra Mangipudi
Date
10/08/16

Definition at line 39 of file lhm.h.

#include <pnp/lhm.h>

Public Member Functions

 lhm (Eigen::MatrixXd obj_pts_, Eigen::MatrixXd img_pts_, Eigen::MatrixXd cam_, int n0)
 Number of 2d/3d correspondences. More...
 
bool compute_pose (Eigen::Ref< Eigen::Matrix3d > R_, Eigen::Ref< Eigen::Vector3d > t_)
 Function to compute pose using LHM PnP algorithm. More...
 
void absKernel ()
 Function to compute pose during an iteration. More...
 
void estimate_t ()
 Function to estimate translation given an estimated rotation matrix. More...
 
void xform ()
 Transform object points in Body frame (Landmark Frame) to estimated Camera Frame. More...
 
Eigen::Matrix4d qMatQ (Eigen::VectorXd q)
 Iternal Function of quaternion. More...
 
Eigen::Matrix4d qMatW (Eigen::VectorXd q)
 Iternal Function of quaternion. More...
 

Private Attributes

Eigen::MatrixXd obj_pts
 
Eigen::MatrixXd img_pts
 Object points in Camera Co-ordinate system. More...
 
Eigen::MatrixXd cam_intrinsic
 Image points in pixel co-ordinates. More...
 
Eigen::MatrixXd P
 Camera intrinsic matrix. More...
 
Eigen::MatrixXd Q
 Trnaspose of Object points . More...
 
Eigen::Matrix3d R
 Transpose of Image points . More...
 
Eigen::Matrix3d G
 Matrix for internal computations. More...
 
Eigen::Vector3d t
 Rotation Matrix. More...
 
std::vector< Eigen::Matrix3d > F
 Translation Vector. More...
 
double err
 Storage matrix for each point. More...
 
double err2
 Error variable for convergence selection. More...
 
int n
 Error variable for convergence selection. More...
 

Constructor & Destructor Documentation

◆ lhm()

lhm::lhm ( Eigen::MatrixXd  obj_pts_,
Eigen::MatrixXd  img_pts_,
Eigen::MatrixXd  cam_,
int  n0 
)

Number of 2d/3d correspondences.

Constructor for the LHM class

Definition at line 22 of file lhm.cpp.

References cam_intrinsic, img_pts, n, obj_pts, P, Q, and t.

Member Function Documentation

◆ absKernel()

void lhm::absKernel ( )

Function to compute pose during an iteration.

Definition at line 74 of file lhm.cpp.

References err2, estimate_t(), F, n, P, Q, qMatQ(), qMatW(), R, and xform().

Referenced by compute_pose().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ compute_pose()

bool lhm::compute_pose ( Eigen::Ref< Eigen::Matrix3d >  R_,
Eigen::Ref< Eigen::Vector3d >  t_ 
)

Function to compute pose using LHM PnP algorithm.

Parameters
R_Rotation matrix
t_Trnaslation Vector
Returns
Success flag

Definition at line 187 of file lhm.cpp.

References absKernel(), EPSILON_LHM, err, err2, F, G, n, P, Q, R, t, and TOL_LHM.

Referenced by mrpt::vision::pnp::CPnP::lhm().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ estimate_t()

void lhm::estimate_t ( )

Function to estimate translation given an estimated rotation matrix.

Definition at line 41 of file lhm.cpp.

References F, G, n, P, R, and t.

Referenced by absKernel().

Here is the caller graph for this function:

◆ qMatQ()

Eigen::Matrix4d lhm::qMatQ ( Eigen::VectorXd  q)

Iternal Function of quaternion.

Parameters
qQuaternion
Returns

Definition at line 54 of file lhm.cpp.

Referenced by absKernel().

Here is the caller graph for this function:

◆ qMatW()

Eigen::Matrix4d lhm::qMatW ( Eigen::VectorXd  q)

Iternal Function of quaternion.

Parameters
qQuaternion
Returns

Definition at line 64 of file lhm.cpp.

Referenced by absKernel().

Here is the caller graph for this function:

◆ xform()

void lhm::xform ( )

Transform object points in Body frame (Landmark Frame) to estimated Camera Frame.

Definition at line 49 of file lhm.cpp.

References n, P, Q, R, and t.

Referenced by absKernel().

Here is the caller graph for this function:

Member Data Documentation

◆ cam_intrinsic

Eigen::MatrixXd mrpt::vision::pnp::lhm::cam_intrinsic
private

Image points in pixel co-ordinates.

Definition at line 43 of file lhm.h.

Referenced by lhm().

◆ err

double mrpt::vision::pnp::lhm::err
private

Storage matrix for each point.

Definition at line 52 of file lhm.h.

Referenced by compute_pose().

◆ err2

double mrpt::vision::pnp::lhm::err2
private

Error variable for convergence selection.

Definition at line 53 of file lhm.h.

Referenced by absKernel(), and compute_pose().

◆ F

std::vector<Eigen::Matrix3d> mrpt::vision::pnp::lhm::F
private

Translation Vector.

Definition at line 51 of file lhm.h.

Referenced by absKernel(), compute_pose(), and estimate_t().

◆ G

Eigen::Matrix3d mrpt::vision::pnp::lhm::G
private

Matrix for internal computations.

Definition at line 48 of file lhm.h.

Referenced by compute_pose(), and estimate_t().

◆ img_pts

Eigen::MatrixXd mrpt::vision::pnp::lhm::img_pts
private

Object points in Camera Co-ordinate system.

Definition at line 42 of file lhm.h.

Referenced by lhm().

◆ n

int mrpt::vision::pnp::lhm::n
private

Error variable for convergence selection.

Definition at line 55 of file lhm.h.

Referenced by absKernel(), compute_pose(), estimate_t(), lhm(), and xform().

◆ obj_pts

Eigen::MatrixXd mrpt::vision::pnp::lhm::obj_pts
private

Definition at line 41 of file lhm.h.

Referenced by lhm().

◆ P

Eigen::MatrixXd mrpt::vision::pnp::lhm::P
private

Camera intrinsic matrix.

Definition at line 44 of file lhm.h.

Referenced by absKernel(), compute_pose(), estimate_t(), lhm(), and xform().

◆ Q

Eigen::MatrixXd mrpt::vision::pnp::lhm::Q
private

Trnaspose of Object points .

Definition at line 45 of file lhm.h.

Referenced by absKernel(), compute_pose(), lhm(), and xform().

◆ R

Eigen::Matrix3d mrpt::vision::pnp::lhm::R
private

Transpose of Image points .

Definition at line 47 of file lhm.h.

Referenced by absKernel(), compute_pose(), estimate_t(), and xform().

◆ t

Eigen::Vector3d mrpt::vision::pnp::lhm::t
private

Rotation Matrix.

Definition at line 49 of file lhm.h.

Referenced by compute_pose(), estimate_t(), lhm(), and xform().




Page generated by Doxygen 1.8.14 for MRPT 2.0.1 Git: 0fef1a6d7 Fri Apr 3 23:00:21 2020 +0200 at vie abr 3 23:20:28 CEST 2020