Basic Image AlgorithmS Library  2.8.0
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
BIAS::Parametrization Class Reference

This class is used for parametrizing F- and H-matrices, generally for optimization purposes. More...

#include <Geometry/Parametrization.hh>

+ Collaboration diagram for BIAS::Parametrization:

Public Member Functions

bool FMatrixToParams (const BIAS::FMatrix &Mat, std::vector< double > &Params)
 parametizes an F-matrix to seven parameters More...
 
double GetFScaling ()
 
double GetHScaling ()
 
bool HMatrixToParams (const BIAS::HMatrix &Mat, std::vector< double > &Params)
 parametizes an H-matrix to eight parameters More...
 
 Parametrization ()
 
bool ParamsToFMatrix (BIAS::FMatrix &Mat, const std::vector< double > &Params)
 composes an F-matrix from the seven given parameters The deparametrization only works with the previously parametized values of 'FMatrixToParams', because some internally stored parameters are important for the correct composition. More...
 
bool ParamsToHMatrix (BIAS::HMatrix &Mat, const std::vector< double > &Params)
 composes an H-matrix from the seven given parameters More...
 
 ~Parametrization ()
 

Static Public Member Functions

static bool EMatrixToParams (BIAS::EMatrix &Mat, Vector< double > &Params, std::vector< BIAS::HomgPoint2D > &inlier1, std::vector< BIAS::HomgPoint2D > &inlier2, bool UseQuaternion=false)
 parametizes an essential-matrix to five parameters More...
 
static bool ParamsToEMatrix (BIAS::EMatrix &Mat, const Vector< double > &Params, bool UseQuaternion=false)
 composes an essential-matrix from the five given parameters More...
 

Protected Member Functions

double GetBiggestAbsEntry ()
 Find the biggest absolute entry of the upper left 2x2 submatrix of the internally stored F matrix member. More...
 

Protected Attributes

BIAS::FMatrix F_
 
int Fcol_
 
std::vector< double > FParams_
 
int Frow_
 
double Fscale_
 
BIAS::HMatrix H_
 
std::vector< double > HParams_
 
double Hscale_
 

Detailed Description

This class is used for parametrizing F- and H-matrices, generally for optimization purposes.

Be sure to use one and the same instance of this class for parametrization and deparametrization of your matrix!!! This parametrization is needed during the MotionModelSelection which is part of my diploma thesis.

Author
Matthias Dunda
Date
09 2003

Definition at line 50 of file Parametrization.hh.

Constructor & Destructor Documentation

Parametrization::Parametrization ( )

Definition at line 36 of file Parametrization.cpp.

Parametrization::~Parametrization ( )

Definition at line 37 of file Parametrization.cpp.

Member Function Documentation

bool Parametrization::EMatrixToParams ( BIAS::EMatrix Mat,
Vector< double > &  Params,
std::vector< BIAS::HomgPoint2D > &  inlier1,
std::vector< BIAS::HomgPoint2D > &  inlier2,
bool  UseQuaternion = false 
)
static
bool Parametrization::FMatrixToParams ( const BIAS::FMatrix Mat,
std::vector< double > &  Params 
)

parametizes an F-matrix to seven parameters

Returns
true on success, false on error
Author
mdunda 09 2003

Definition at line 39 of file Parametrization.cpp.

References BIAS::HomgPoint2D::Homogenize(), BIAS::Matrix3x3< T >::IsZero(), and BIAS::Matrix3x3< T >::Scale().

Referenced by BIAS::FMatrixEstimation::Optimize().

double Parametrization::GetBiggestAbsEntry ( )
protected

Find the biggest absolute entry of the upper left 2x2 submatrix of the internally stored F matrix member.

The position of this element is stored internally and used for the composition of the F matrix in ParamsToFMatrix.

Returns
value of the entry with biggest absolute value
Author
mdunda 09 2003

Definition at line 236 of file Parametrization.cpp.

double BIAS::Parametrization::GetFScaling ( )
inline

Definition at line 99 of file Parametrization.hh.

double BIAS::Parametrization::GetHScaling ( )
inline

Definition at line 100 of file Parametrization.hh.

bool Parametrization::HMatrixToParams ( const BIAS::HMatrix Mat,
std::vector< double > &  Params 
)

parametizes an H-matrix to eight parameters

Returns
true on success, false on error
Author
mdunda 09 2003

Definition at line 164 of file Parametrization.cpp.

References BIAS::Matrix3x3< T >::IsZero().

Referenced by BIAS::HMatrixEstimation::Optimize().

bool Parametrization::ParamsToEMatrix ( BIAS::EMatrix Mat,
const Vector< double > &  Params,
bool  UseQuaternion = false 
)
static

composes an essential-matrix from the five given parameters

Returns
true on success, false on error
Author
frahm 03 2004

Definition at line 301 of file Parametrization.cpp.

References BIAS::Vector3< T >::CoordSphereToEuclidean(), BIAS::Matrix3x3< T >::NormFrobenius(), BIAS::Vector3< T >::NormL2(), BIAS::FMatrixBase::Set(), BIAS::RMatrixBase::Set(), BIAS::RMatrixBase::SetFromQuaternion(), BIAS::Vector< T >::Size(), and TNT::Vector< T >::size().

bool Parametrization::ParamsToFMatrix ( BIAS::FMatrix Mat,
const std::vector< double > &  Params 
)

composes an F-matrix from the seven given parameters The deparametrization only works with the previously parametized values of 'FMatrixToParams', because some internally stored parameters are important for the correct composition.

Returns
true on success, false on error
Author
mdunda 09 2003

Definition at line 101 of file Parametrization.cpp.

bool Parametrization::ParamsToHMatrix ( BIAS::HMatrix Mat,
const std::vector< double > &  Params 
)

composes an H-matrix from the seven given parameters

Returns
true on success, false on error
Author
mdunda 09 2003

Definition at line 202 of file Parametrization.cpp.

Referenced by BIAS::HMatrixEstimation::HErrorFunction_(), and BIAS::HMatrixEstimation::Optimize().

Member Data Documentation

BIAS::FMatrix BIAS::Parametrization::F_
protected

Definition at line 104 of file Parametrization.hh.

int BIAS::Parametrization::Fcol_
protected

Definition at line 109 of file Parametrization.hh.

std::vector<double> BIAS::Parametrization::FParams_
protected

Definition at line 105 of file Parametrization.hh.

int BIAS::Parametrization::Frow_
protected

Definition at line 109 of file Parametrization.hh.

double BIAS::Parametrization::Fscale_
protected

Definition at line 123 of file Parametrization.hh.

BIAS::HMatrix BIAS::Parametrization::H_
protected

Definition at line 112 of file Parametrization.hh.

std::vector<double> BIAS::Parametrization::HParams_
protected

Definition at line 113 of file Parametrization.hh.

double BIAS::Parametrization::Hscale_
protected

Definition at line 124 of file Parametrization.hh.


The documentation for this class was generated from the following files: