Basic Image AlgorithmS Library
2.8.0
|
class encapsulating the transfromations between different pose parametrizations More...
#include <Base/Geometry/PoseParametrizationCovariance.hh>
Public Types | |
typedef const T * | const_iterator |
typedef const T & | const_reference |
typedef T | element_type |
typedef T * | iterator |
typedef T * | pointer |
typedef T & | reference |
typedef Subscript | size_type |
typedef T | value_type |
Public Member Functions | |
void | AbsIP () |
absolute values of all elements of the matrix (in place) More... | |
Matrix< POSECOVARIANCE_TYPE > | Adjoint () const |
computes the adjoint matrix More... | |
void | Clear () |
Subscript | dim (Subscript d) const |
void | GaussJordan () |
use the Gauss Jordan Algrithm to transform the matrix to reduced row echelon form. More... | |
Matrix3x3< POSECOVARIANCE_TYPE > | GetCovC () const |
Matrix4x4< POSECOVARIANCE_TYPE > | GetCovQ () const |
Matrix< POSECOVARIANCE_TYPE > | GetMax (Matrix< POSECOVARIANCE_TYPE > &m) |
returns an matrix the same size as the matrix n and m with the largest elements taken from n or m More... | |
Matrix< POSECOVARIANCE_TYPE > | GetMin (Matrix< POSECOVARIANCE_TYPE > &m) |
returns an matrix the same size as the matrix n and m with the smallest elements taken from n or m More... | |
initialize (M, N) | |
bool | IsIdentity (double eps=0.0) const |
Checks if the matrix a an identity. More... | |
bool | IsZero (double eps=0.0) const |
Checks if the matrix is a null matrix. More... | |
void | Kronecker (Matrix< POSECOVARIANCE_TYPE > const B, Matrix< POSECOVARIANCE_TYPE > &dest) const |
Kronecker-product with matrix, result in dest. More... | |
Subscript | lbound () const |
Matrix< T > & | newsize (Subscript M, Subscript N) |
Subscript | num_cols () const |
Subscript | num_rows () const |
reference | operator() (Subscript i) |
const_reference | operator() (Subscript i) const |
reference | operator() (Subscript i, Subscript j) |
const_reference | operator() (Subscript i, Subscript j) const |
T * | operator[] (Subscript i) |
const T * | operator[] (Subscript i) const |
PoseParametrizationCovariance (MatrixInitType T) | |
PoseParametrizationCovariance () | |
PoseParametrizationCovariance (const Matrix< POSECOVARIANCE_TYPE > &T) | |
PoseParametrizationCovariance (const TNT::Matrix< POSECOVARIANCE_TYPE > &T) | |
std::ostream & | Print (std::ostream &s, const int width, const int precision, bool scientific=true) const |
std::ostream & | Print (std::ostream &s, const bool intCastOutput=false, const bool binaryOutput=false, const bool forceFullPrecision=false) const |
std::ostream & | PrintPretty (std::ostream &s, const std::string &name="", const int width=8, const bool alignLeft=true) const |
std::istream & | Read (std::istream &s, const bool intCastInput=false, const bool binaryInput=false) |
JW. More... | |
set (value) | |
Subscript | size () const |
void | SwapRows (const int i, const int r) |
swaps two rows More... | |
void | Transform (const Matrix4x4< double > &transf) |
Given a 6D pose (position and euler angles) and its associated covariance, the function transforms the covaruiance into pose and quaternion parametrization. More... | |
Matrix< POSECOVARIANCE_TYPE > | Transpose () const |
transpose function, storing data destination matrix More... | |
void | Vec (Vector< POSECOVARIANCE_TYPE > &dest) const |
vec-operator returns the elements of the matrix columwise as vector More... | |
~PoseParametrizationCovariance () | |
Get Functions | |
POSECOVARIANCE_TYPE | GetMax () const |
Returns the maximum value of the matrix elements. More... | |
POSECOVARIANCE_TYPE | GetMin () const |
Returns the minimum value of the matrix elements. More... | |
POSECOVARIANCE_TYPE * | GetData () |
get the pointer to the data array of the matrix (for faster direct memeory access) More... | |
const POSECOVARIANCE_TYPE * | GetData () const |
const POSECOVARIANCE_TYPE ** | GetDataArray () const |
returns zero based arry for data access More... | |
POSECOVARIANCE_TYPE ** | GetDataArray () |
POSECOVARIANCE_TYPE ** | GetDataArray1 () const |
returns 1 based array to data access More... | |
unsigned int | GetRows () const |
unsigned int | GetCols () const |
const POSECOVARIANCE_TYPE * | GetDataLast () const |
Get a pointer to the last data element Do not use this on unitilized matrices with <= on pointers because on an unitilized matrix GetData() will be NULL and last Element < (typically FFFFF8) We don't want an if here for performance reasons of the innerst loop. More... | |
POSECOVARIANCE_TYPE * | GetDataLast () |
Vector< POSECOVARIANCE_TYPE > | GetRow (const int &row) const |
return a copy of row "row" of this matrix, zero based counting More... | |
Vector< POSECOVARIANCE_TYPE > | GetCol (const int &col) const |
return a copy of column "col", zero based counting More... | |
void | GetSubMatrix (const size_t startRow, const size_t startCol, const size_t numRows, const size_t numCols, Matrix< POSECOVARIANCE_TYPE > &submatrix) const |
return a submatrix from this. More... | |
void | GetSubMatrix (const Vector< int > &rows, const Vector< int > &cols, Matrix< POSECOVARIANCE_TYPE > &submatrix) const |
return a submatrix from this. More... | |
Matrix< POSECOVARIANCE_TYPE > | GetSubMatrix (const Vector< int > &rows, const Vector< int > &cols) const |
return a submatrix from this. More... | |
void | SetSubMatrix (const size_t startRowInThis, const size_t startColInThis, const Matrix< POSECOVARIANCE_TYPE > &submatrix, const size_t startRowInSub, const size_t startColInSub, const size_t numRows, const size_t numCols) |
sets a submatrix in this. More... | |
void | SetSubMatrix (const size_t startRowInThis, const size_t startColInThis, const Matrix3x3< POSECOVARIANCE_TYPE > &submatrix) |
sets a 3x3 submatrix in this. More... | |
void | SetSubMatrix (const size_t startRowInThis, const size_t startColInThis, const Vector3< POSECOVARIANCE_TYPE > &subvector) |
sets a 3x1 submatrix in this. More... | |
void | SetRow (const int row, const Vector< POSECOVARIANCE_TYPE > &data) |
set a row of matrix from vector More... | |
void | SetCol (const int row, const Vector< POSECOVARIANCE_TYPE > &data) |
set a col of matrix from vector More... | |
void | Set (const int row, const int col, const Matrix< POSECOVARIANCE_TYPE > &data) |
Copies the contents of data into this at the position indicated by row and col. More... | |
void | Set (const int row, const int col, const Vector< POSECOVARIANCE_TYPE > &data) |
Copies the contents of data into this at the position indicated by row and col. More... | |
void | SetTranspose (const int row, const int col, const Vector< POSECOVARIANCE_TYPE > &data) |
Copies the contents of data into this at the position indicated by row and col. More... | |
int | GetNumElements () const |
Returns the total number of elements. More... | |
void | GetMaxMin (POSECOVARIANCE_TYPE &max, POSECOVARIANCE_TYPE &min) const |
return biggest and smallest entry More... | |
void | GetAbsMaxMin (POSECOVARIANCE_TYPE &max, POSECOVARIANCE_TYPE &min) const |
return biggest and smallest absolute values More... | |
POSECOVARIANCE_TYPE | GetMean () const |
Returns the mean value of the matrix elements. More... | |
POSECOVARIANCE_TYPE | NormL1 () const |
Return the L1 norm: |a| + |b| + |c| + ... More... | |
double | NormL2 () const |
Return the L2 norm: a^2 + b^2 + c^2 + ... More... | |
double | NormFrobenius () const |
Return Frobenius norm = sqrt(trace(A^t * A)). More... | |
POSECOVARIANCE_TYPE | Trace () const |
POSECOVARIANCE_TYPE | DetSquare () const |
Arithmetic | |
void | AddIP (const POSECOVARIANCE_TYPE &scalar) |
in place addition function More... | |
void | AddIP (const Matrix< POSECOVARIANCE_TYPE > &arg) |
Adds arg to this. More... | |
void | SubIP (const Matrix< POSECOVARIANCE_TYPE > &arg) |
Subtracts arg from this this -= arg. More... | |
void | SubIP (const POSECOVARIANCE_TYPE &scalar) |
in place subtraction function More... | |
void | Add (const POSECOVARIANCE_TYPE &scalar, Matrix< POSECOVARIANCE_TYPE > &dest) const |
addition function, storing data destination matrix More... | |
void | Sub (const POSECOVARIANCE_TYPE &scalar, Matrix< POSECOVARIANCE_TYPE > &dest) const |
substraction function, storing data destination matrix More... | |
void | MultiplyIP (const POSECOVARIANCE_TYPE &scalar) |
in place multiplication function More... | |
void | Multiply (const POSECOVARIANCE_TYPE &scalar, Matrix< POSECOVARIANCE_TYPE > &dest) const |
multiplication function, storing data destination matrix More... | |
void | Mult (const Matrix< POSECOVARIANCE_TYPE > &arg, Matrix< POSECOVARIANCE_TYPE > &result) const |
matrix multiplication, result is not allocated More... | |
void | Mult (const Matrix< POSECOVARIANCE_TYPE > &arg) |
in Place matrix multiplication this is equal to M = M * arg, but faster More... | |
void | Mult (const Vector< POSECOVARIANCE_TYPE > &arg, Vector< POSECOVARIANCE_TYPE > &result) const |
matrix vector multiplication, result is not allocated More... | |
void | MultLeft (const Matrix< POSECOVARIANCE_TYPE > &arg) |
in Place matrix multiplication this is equal to M = arg*M, but faster More... | |
void | MultLeft (const Vector< POSECOVARIANCE_TYPE > &arg, Vector< POSECOVARIANCE_TYPE > &result) const |
vector matrix multiplication result=arg*this. More... | |
void | MultiplyWithTransposeOf (const Matrix< POSECOVARIANCE_TYPE > &arg, Matrix< POSECOVARIANCE_TYPE > &result) const |
matrix matrix multiplication for multiplication with the transpose of the given matrix, result=this*arg^T. More... | |
void | DivideIP (const POSECOVARIANCE_TYPE &scalar) |
in place division function More... | |
void | Divide (const POSECOVARIANCE_TYPE &scalar, Matrix< POSECOVARIANCE_TYPE > &dest) const |
division function, storing data destination matrix More... | |
void | DivideElementwise (const Matrix< POSECOVARIANCE_TYPE > &arg) |
elementwise division function in place More... | |
void | GetSystemMatrix (Matrix< POSECOVARIANCE_TYPE > &dest) const |
compute square system matrix dest = A^T * A More... | |
Set Functions | |
void | SetZero () |
Sets all values to zero. More... | |
void | MakeSymmetric () |
componentwise: this = 0.5(this + this^T) yields symmetric matrix only allowed for square shaped matrices More... | |
virtual void | clear () |
stl conform interface destroys Matrix JW More... | |
void | SetIdentity () |
Converts matrix to identity matrix. More... | |
void | Fill (const POSECOVARIANCE_TYPE &scalar) |
Takes the elements of a Vector and put them as diagonal elements into a matrix. More... | |
Scaling and Normalization | |
void | NormalizeColsToOne (const int norm_row_index) |
divides each column of the matrix through the element norm_row_index. More... | |
void | NormalizeRowsToOne (const int norm_col_index) |
divides each row of the matrix through the element norm_col_index. More... | |
void | NormalizeRows () |
Normalizes each row to L2 norm one. More... | |
void | NormalizeCols () |
Normalizes each coloumn to L_2 norm one. More... | |
POSECOVARIANCE_TYPE | Normalize () |
Normalizes the matrix by the entry with the biggest absolute value by dividing all elements with this one. More... | |
void | ScaleRow (int NoRow, POSECOVARIANCE_TYPEscale) |
Scales row NoRow with scale. More... | |
void | ScaleCol (int NoCol, POSECOVARIANCE_TYPEscale) |
Scales column NoCol with scale. More... | |
Input / Output | |
bool | Load (const std::string &filename) |
method to load directly from a given filename. More... | |
bool | Save (const std::string &filename) const |
method to save directly to a given filename. More... | |
int | WriteMatlab (std::ostream &ostr, const std::string &name) const |
Write the matrix in Matlab format to the given stream. More... | |
bool | BinRead (const char *filename) const |
This method reads a matrix from a given file in binary format. More... | |
bool | BinWrite (const char *filename) const |
This method writes a matrix to a given file in binary format. More... | |
Protected Member Functions | |
void | copy (const T *v) |
void | destroy () |
void | initialize (Subscript M, Subscript N) |
void | set (const T &val) |
Protected Attributes | |
Subscript | m_ |
Subscript | mn_ |
Subscript | n_ |
T ** | row_ |
T ** | rowm1_ |
T * | v_ |
T * | vm1_ |
Related Functions | |
(Note that these are not member functions.) | |
template<class T > | |
Matrix< T > | operator* (const Matrix< T > &A, const Matrix< T > &B) |
template<class T > | |
Vector< T > | operator* (const Matrix< T > &A, const Vector< T > &x) |
template<class T > | |
Matrix< T > | operator+ (const Matrix< T > &A, const Matrix< T > &B) |
template<class T > | |
Matrix< T > | operator- (const Matrix< T > &A, const Matrix< T > &B) |
std::ostream & | operator<< (std::ostream &s, const Matrix< char > &A) |
std::ostream & | operator<< (std::ostream &s, const Matrix< unsigned char > &A) |
template<class T > | |
std::ostream & | operator<< (std::ostream &s, const Matrix< T > &A) |
std::istream & | operator>> (std::istream &s, Matrix< unsigned char > &A) |
std::istream & | operator>> (std::istream &s, Matrix< char > &A) |
template<class T > | |
std::istream & | operator>> (std::istream &s, Matrix< T > &A) |
class encapsulating the transfromations between different pose parametrizations
This class represents the covariance of a camerpose with translation and rotation. The pose is assumed to be tx,ty,tz,q1,q2,q3,q4 with translation t and rotation q as quaternion. The covariance therefore must be 7x7.
Definition at line 49 of file PoseParametrizationCovariance.hh.
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
inline |
Definition at line 53 of file PoseParametrizationCovariance.hh.
PoseParametrizationCovariance::PoseParametrizationCovariance | ( | ) |
Definition at line 12 of file PoseParametrizationCovariance.cpp.
|
inlineexplicit |
Definition at line 58 of file PoseParametrizationCovariance.hh.
|
inline |
Definition at line 61 of file PoseParametrizationCovariance.hh.
PoseParametrizationCovariance::~PoseParametrizationCovariance | ( | ) |
Definition at line 17 of file PoseParametrizationCovariance.cpp.
|
inherited |
absolute values of all elements of the matrix (in place)
|
inlineinherited |
addition function, storing data destination matrix
implementation
|
inlineinherited |
|
inlineinherited |
Adds arg to this.
|
inlineinherited |
computes the adjoint matrix
|
inherited |
This method reads a matrix from a given file in binary format.
The file is not human read-/editable but provides full precision. A dimension check is performed.
|
inherited |
This method writes a matrix to a given file in binary format.
The file is not human read-/editable but provides full precision.
|
inline |
Definition at line 70 of file PoseParametrizationCovariance.hh.
|
inlinevirtualinherited |
|
inlineprotectedinherited |
Definition at line 122 of file cmat.h.
Referenced by TNT::Matrix< BIAS::BIAS::Vector< int > >::Matrix(), and TNT::Matrix< BIAS::BIAS::Vector< int > >::operator=().
|
inlineprotectedinherited |
Definition at line 181 of file cmat.h.
Referenced by TNT::Matrix< BIAS::BIAS::Vector< int > >::newsize(), TNT::Matrix< BIAS::BIAS::Vector< int > >::operator=(), and TNT::Matrix< BIAS::BIAS::Vector< int > >::~Matrix().
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
division function, storing data destination matrix
|
inlineinherited |
elementwise division function in place
|
inlineinherited |
|
inherited |
Takes the elements of a Vector and put them as diagonal elements into a matrix.
The size of this Vector must be exactly min( matrix.width, matrix.height). Optionally all other elements may be set to zero
zero_others | Must be true, if all non-diagonal elements shall be set to zero |
|
inherited |
use the Gauss Jordan Algrithm to transform the matrix to reduced row echelon form.
|
inherited |
return biggest and smallest absolute values
|
inherited |
return a copy of column "col", zero based counting
|
inlineinherited |
Matrix3x3< POSECOVARIANCE_TYPE > PoseParametrizationCovariance::GetCovC | ( | ) | const |
Definition at line 22 of file PoseParametrizationCovariance.cpp.
Matrix4x4< POSECOVARIANCE_TYPE > PoseParametrizationCovariance::GetCovQ | ( | ) | const |
Definition at line 34 of file PoseParametrizationCovariance.cpp.
|
inlineinherited |
get the pointer to the data array of the matrix (for faster direct memeory access)
the order of the data is linewise, which means an elemnt sequence of e.g. [0] = M(0,0) [1] = M(0,1) [2] = M(0,2) [3] = M(1,0) // next line [4] = M(1,1) ...
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
Get a pointer to the last data element Do not use this on unitilized matrices with <= on pointers because on an unitilized matrix GetData() will be NULL and last Element < (typically FFFFF8) We don't want an if here for performance reasons of the innerst loop.
|
inlineinherited |
|
inherited |
returns an matrix the same size as the matrix n and m with the largest elements taken from n or m
|
inherited |
Returns the maximum value of the matrix elements.
|
inherited |
return biggest and smallest entry
|
inherited |
Returns the mean value of the matrix elements.
|
inherited |
returns an matrix the same size as the matrix n and m with the smallest elements taken from n or m
|
inherited |
Returns the minimum value of the matrix elements.
|
inlineinherited |
|
inherited |
return a copy of row "row" of this matrix, zero based counting
|
inlineinherited |
|
inherited |
return a submatrix from this.
Start index is [startRow][startCol] end index is [startRow+numRows-1][startCol+numCols-1]. submatrix is resized to numRows/numCols if necessary.
|
inherited |
return a submatrix from this.
Similar to matlab notation (except indexing, starts with 0 of course!). Vectors rows = '1 3' and cols = '1 2' for matrix: / 1 2 3 \ | 4 5 6 | \ 7 8 9 / results in: / 1 2 \ \ 7 8 / Matrix has to be initialized!!!
|
inherited |
return a submatrix from this.
Similar to matlab notation (except indexing, starts with 0 of course!), see GetSubMatrix(const Vector<int> &rows, const Vector<int> &cols, Matrix<T> &submatrix)
|
inlineinherited |
compute square system matrix dest = A^T * A
dest | holds result of this->Transpose * this |
If you want to solve A * x = b, where A has more rows than columns, a common technique is to solve x = (A^T * A)^-1 * A^T * b. This function provides a fast way to compute A^T*A from A.
|
inlineprotectedinherited |
Definition at line 95 of file cmat.h.
Referenced by TNT::Matrix< BIAS::BIAS::Vector< int > >::Matrix(), TNT::Matrix< BIAS::BIAS::Vector< int > >::newsize(), and TNT::Matrix< BIAS::BIAS::Vector< int > >::operator=().
|
inherited |
|
inherited |
Checks if the matrix a an identity.
I.e. all elements with index i==j are equal 1 and all others are zero.
|
inherited |
Checks if the matrix is a null matrix.
|
inherited |
Kronecker-product with matrix, result in dest.
Kronecker-product with matrix B, result in dest.
|
inlineinherited |
|
inherited |
method to load directly from a given filename.
internally using stream operator
|
inlineinherited |
|
inlineinherited |
matrix multiplication, result is not allocated
|
inlineinherited |
in Place matrix multiplication this is equal to M = M * arg, but faster
|
inlineinherited |
matrix vector multiplication, result is not allocated
|
inlineinherited |
multiplication function, storing data destination matrix
|
inlineinherited |
|
inlineinherited |
matrix matrix multiplication for multiplication with the transpose of the given matrix, result=this*arg^T.
|
inlineinherited |
in Place matrix multiplication this is equal to M = arg*M, but faster
|
inlineinherited |
vector matrix multiplication result=arg*this.
|
inlineinherited |
Definition at line 269 of file cmat.h.
Referenced by BIAS::Matrix< T >::Add(), BIAS::RegionMatcher::BilinearRegion(), BIAS::RegionMatcher::BilinearRegionColor3(), BIAS::ComputeCovariance(), BIAS::LDA::ComputeReductionMatrix(), BIAS::PCA::ComputeReductionMatrix(), BIAS::ContourBSplineShapeMatrix::ComputeRegularisationMatrix(), BIAS::ContourBSplineData::ComputeSplineMetricMatrix_(), BIAS::Matrix< T >::Conv(), BIAS::CamPoseCalib::CreateSecDMatrix_(), BIAS::Matrix< T >::Divide(), Eigenproblem_quadratic_matrix(), BIAS::CamPoseCalib::Estimate(), BIAS::TrackerBaseAffine< StorageType >::EvaluateResult_(), BIAS::TrackerBaseAffine2< StorageType >::EvaluateResult_(), BIAS::TrackerBaseInterface< StorageType >::EvaluateResult_(), BIAS::TrackerBaseInterface< StorageType >::Filter_ByMask(), BIAS::TrackerBaseInterface< StorageType >::Filter_BySeparableMask(), BIAS::TrackerBaseInterface< StorageType >::Filter_GradXSobel3x3(), BIAS::TrackerBaseInterface< StorageType >::Filter_GradYSobel3x3(), BIAS::TrackerBaseInterface< StorageType >::FilterLowpass_Binomial3x3(), BIAS::TrackerBaseInterface< StorageType >::FilterLowpass_ByMask(), BIAS::TrackerBaseInterface< StorageType >::FilterLowpass_BySeparableMask(), Fortran_Matrix_to_Matrix(), generalised_eigenvalue_matrix_solve(), BIAS::LDA::GenerateRandomTestData(), BIAS::SparseMatrix::GetAsDense(), BIAS::Random::GetMeanAndCovariance(), BIAS::PMatrixLinear::GetPEstSystemHom(), BIAS::PMatrixLinear::GetPEstSystemInHom(), BIAS::Matrix< T >::GetSystemMatrix(), BIAS::Kalman::Init(), BIAS::IteratedExtendedKalman::Init(), BIAS::SparseMatrix::Invert(), BIAS::SparseMatrix::InvertAndSolve(), BIAS::Matrix< T >::Kronecker(), Lapack_Cholesky_SymmetricPositiveDefinit(), BIAS::RegionMatcher::LinearRegionX(), BIAS::LevenbergMarquardtBase::LM_Compute(), BIAS::LevenbergMarquardtBase::LM_ComputeWithoutJacobian(), TNT::matmult(), BIAS::Matrix< T >::Mult(), BIAS::Matrix< T >::Multiply(), BIAS::Matrix< T >::MultiplyWithTransposeOf(), BIAS::MxArrToBIASMatrix(), BIAS::Matrix3x4< T >::newsize(), BIAS::Matrix4x4< T >::newsize(), BIAS::TextureTransformHomography::ParameterInversionJacobian(), BIAS::TextureTransformAffine::ParameterInversionJacobian(), BIAS::TextureTransformDisparity::ParameterInversionJacobian(), BIAS::TextureTransformDisplacement::ParameterInversionJacobian(), BIAS::TextureTransformRotation::ParameterInversionJacobian(), BIAS::TextureTransformEuclidian::ParameterInversionJacobian(), BIAS::TextureTransformAffine::ParameterJacobianBackward(), BIAS::TextureTransformHomography::ParameterJacobianBackward(), BIAS::TextureTransformDisparity::ParameterJacobianBackward(), BIAS::TextureTransformDisplacement::ParameterJacobianBackward(), BIAS::TextureTransformRotation::ParameterJacobianBackward(), BIAS::TextureTransformEuclidian::ParameterJacobianBackward(), BIAS::TextureTransformSimilar::ParameterJacobianBackward(), BIAS::TextureTransform::ParameterJacobianBackward(), BIAS::TextureTransformAffine::ParameterJacobianForward(), BIAS::TextureTransformHomography::ParameterJacobianForward(), BIAS::TextureTransformDisparity::ParameterJacobianForward(), BIAS::TextureTransformDisplacement::ParameterJacobianForward(), BIAS::TextureTransformRotation::ParameterJacobianForward(), BIAS::TextureTransformEuclidian::ParameterJacobianForward(), BIAS::TextureTransformSimilar::ParameterJacobianForward(), BIAS::TextureTransform::ParameterJacobianForward(), BIAS::IteratedExtendedKalman::Predict(), BIAS::Covariance3Dto2D::Project(), BIAS::Covariance3Dto2DHomg::Project(), BIAS::QRFrac(), BIAS::RegionMatcher::RegionMatcher(), BIAS::ContourBSplineShapeMatrix::SetShapeSpaceEuclidian(), BIAS::ContourBSplineShapeMatrix::SetShapeSpaceIdentity(), BIAS::ContourBSplineShapeMatrix::SetShapeSpaceMatrix(), BIAS::ContourBSplineShapeMatrix::SetShapeSpacePlanarAffin(), BIAS::ContourBSplineShapeMatrix::SetSubShapeSpaceZero(), BIAS::Matrix< T >::Sub(), BIAS::TrackerBaseAffine< StorageType >::TrackAffine_(), BIAS::MonteCarloTransform::Transform(), BIAS::UnscentedTransform::Transform(), BIAS::IteratedExtendedKalman::Update(), and BIAS::Tracker< StorageType, CalculationType >::Vector2FilterMask_().
|
inherited |
Normalizes the matrix by the entry with the biggest absolute value by dividing all elements with this one.
|
inherited |
Normalizes each coloumn to L_2 norm one.
Attention each column is normaized by its own scale!
|
inherited |
divides each column of the matrix through the element norm_row_index.
index runs [0..num_rows-1] for example: 2 3 4 5 normalized with row '1' will be 2/4 3/5 1 1
|
inherited |
Normalizes each row to L2 norm one.
Attention each row is normaized by its own scale!
|
inherited |
divides each row of the matrix through the element norm_col_index.
index runs [0..num_cols-1] for example: 2 3 4 5 normalized with row '1' will be 2/3 1 4/5 1
|
inlineinherited |
Return Frobenius norm = sqrt(trace(A^t * A)).
this method is deprecated because it is equivalent to NormL2
This function is deprecated, because it is equivalent to NormL2.
|
inlineinherited |
Return the L1 norm: |a| + |b| + |c| + ...
|
inlineinherited |
Return the L2 norm: a^2 + b^2 + c^2 + ...
|
inlineinherited |
Definition at line 320 of file cmat.h.
Referenced by BIAS::Matrix< T >::Add(), BIAS::Matrix< T >::AddIP(), BIAS::ImageAlignment::Align(), BIAS::CamPoseCalib::ApplyCoVariances_(), BIAS::ImageAlignment::AutoAlign(), BIAS::TFTensorEstimation::Compute(), BIAS::SVD3x3::Compute(), BIAS::GaussHelmert::ComputeNormalSystem_(), BIAS::LDA::ComputeReductionMatrix(), BIAS::PCA::ComputeReductionMatrix(), BIAS::ContourBSplineShapeMatrix::ComputeRegularisationMatrix(), BIAS::PCA::ComputeScatter(), BIAS::UnscentedTransform::ComputeSigmaPoints_(), BIAS::LDA::ComputeWithinAndInterClassCovs(), BIAS::Matrix< T >::Conv(), BIAS::Matrix< T >::Divide(), BIAS::Matrix< T >::DivideElementwise(), Eigenproblem_quadratic_matrix(), Eigenvalue_solve(), BIAS::CamPoseCalib::Estimate(), Fortran_Matrix_to_Matrix(), General_singular_value_decomposition(), generalised_eigenvalue_matrix_solve(), BIAS::CamPoseCalib::GetCov(), BIAS::CamPoseCalib::GetCoVarMatrix(), BIAS::SVD::GetNullvector(), BIAS::Matrix< T >::Kronecker(), Lapack_Cholesky_SymmetricPositiveDefinit(), Lapack_LLS_QR_linear_solve(), Lapack_LU_linear_solve(), Lapack_WLLS_solve(), TNT::matmult(), BIAS::Matrix2x2< T >::Matrix2x2(), BIAS::Matrix3x3< T >::Matrix3x3(), BIAS::Matrix4x4< T >::Matrix4x4(), BIAS::Matrix< T >::Mult(), TNT::mult_element(), BIAS::Matrix< T >::Multiply(), BIAS::Matrix< T >::MultiplyWithTransposeOf(), TNT::Matrix< BIAS::BIAS::Vector< int > >::newsize(), BIAS::TrackerBaseInterface< StorageType >::NormalizeRegion_(), BIAS::Vector< T >::operator*(), BIAS::Vector3< T >::operator*(), BIAS::Vector4< T >::operator*(), TNT::Matrix< T >::operator+(), TNT::Matrix< T >::operator-(), BIAS::Matrix3x4< T >::operator=(), BIAS::Matrix4x4< T >::operator=(), BIAS::PMatrix::PMatrix(), BIAS::PMatrixBase::PMatrixBase(), BIAS::CovTransformPose::PoseEulerZYXToQuat(), BIAS::CovTransformPose::PoseQuatToEulerZYX(), BIAS::IteratedExtendedKalman::Predict(), BIAS::Covariance3Dto2DHomg::Project(), BIAS::RMatrix::RMatrix(), BIAS::RMatrixBase::RMatrixBase(), BIAS::Matrix< T >::Set(), BIAS::RParametrization::SetCovarianceMatrix(), BIAS::PoseParametrization::SetCovarianceMatrix(), BIAS::EParametrization::SetCovarianceMatrix(), BIAS::LocalAffineFrame::SetFromMatrix(), BIAS::IteratedExtendedKalman::SetProcessCov(), BIAS::ContourBSplineShapeMatrix::SetShapeSpaceMatrix(), BIAS::IteratedExtendedKalman::SetState(), BIAS::ContourBSplineShapeMatrix::SetSubShapeSpaceZero(), BIAS::GaussHelmert::Solve(), BIAS::LeastSquaresSVD::Solve(), BIAS::SVD::Solve(), BIAS::CamPoseCalib::SolveLM_(), BIAS::ImageAlignment::StrictPyramidAlign(), BIAS::Matrix< T >::Sub(), BIAS::Matrix< T >::SubIP(), BIAS::SymmetricMatrix3x3< T >::SymmetricMatrix3x3(), BIAS::TrackerBaseAffine< StorageType >::TrackAffine_(), BIAS::MonteCarloTransform::Transform(), BIAS::UnscentedTransform::Transform(), BIAS::CovTransformPose::TransformPoint3D(), BIAS::CovTransformPose::TransformPose(), TNT::transpose(), BIAS::Kalman::Update(), BIAS::IteratedExtendedKalman::Update(), and Upper_symmetric_eigenvalue_solve().
|
inlineinherited |
Definition at line 319 of file cmat.h.
Referenced by BIAS::Matrix< T >::Add(), BIAS::Matrix< T >::AddIP(), BIAS::ImageAlignment::Align(), BIAS::ImageAlignment::AutoAlign(), BIAS::SVD3x3::Compute(), BIAS::ImageBlender::ComputeCylCamGeometry(), BIAS::ImageBlenderIncremental::ComputeCylCamGeometry_(), BIAS::LDA::ComputeReductionMatrix(), BIAS::PCA::ComputeReductionMatrix(), BIAS::ContourBSplineShapeMatrix::ComputeRegularisationMatrix(), BIAS::PCA::ComputeScatter(), BIAS::UnscentedTransform::ComputeSigmaPoints_(), BIAS::LDA::ComputeWithinAndInterClassCovs(), BIAS::Matrix< T >::Conv(), BIAS::Matrix< T >::Divide(), BIAS::Matrix< T >::DivideElementwise(), Eigenproblem_quadratic_matrix(), Eigenvalue_solve(), BIAS::CamPoseCalib::Estimate(), Fortran_Matrix_to_Matrix(), General_singular_value_decomposition(), generalised_eigenvalue_matrix_solve(), BIAS::CamPoseCalib::GetCov(), BIAS::CamPoseCalib::GetCoVarMatrix(), BIAS::SVD::GetLeftNullvector(), BIAS::Kalman::Init(), BIAS::IteratedExtendedKalman::Init(), BIAS::Matrix< T >::Kronecker(), Lapack_Cholesky_SymmetricPositiveDefinit(), Lapack_LLS_QR_linear_solve(), Lapack_LU_linear_solve(), Lapack_WLLS_solve(), TNT::matmult(), BIAS::Matrix2x2< T >::Matrix2x2(), BIAS::Matrix3x3< T >::Matrix3x3(), BIAS::Matrix4x4< T >::Matrix4x4(), BIAS::Matrix< T >::Mult(), TNT::mult_element(), BIAS::Matrix< T >::Multiply(), BIAS::Matrix< T >::MultiplyWithTransposeOf(), BIAS::Matrix< T >::MultLeft(), TNT::Matrix< BIAS::BIAS::Vector< int > >::newsize(), BIAS::TrackerBaseInterface< StorageType >::NormalizeRegion_(), BIAS::Vector< T >::operator*(), BIAS::Vector3< T >::operator*(), BIAS::Vector4< T >::operator*(), TNT::Matrix< T >::operator+(), TNT::Matrix< T >::operator-(), BIAS::Matrix3x4< T >::operator=(), BIAS::Matrix4x4< T >::operator=(), BIAS::PMatrix::PMatrix(), BIAS::PMatrixBase::PMatrixBase(), BIAS::CovTransformPose::PoseEulerZYXToQuat(), BIAS::CovTransformPose::PoseQuatToEulerZYX(), BIAS::IteratedExtendedKalman::Predict(), BIAS::RMatrix::RMatrix(), BIAS::RMatrixBase::RMatrixBase(), BIAS::Matrix< T >::Set(), BIAS::RParametrization::SetCovarianceMatrix(), BIAS::PoseParametrization::SetCovarianceMatrix(), BIAS::EParametrization::SetCovarianceMatrix(), BIAS::LocalAffineFrame::SetFromMatrix(), BIAS::IteratedExtendedKalman::SetProcessCov(), BIAS::ContourBSplineShapeMatrix::SetShapeSpaceMatrix(), BIAS::IteratedExtendedKalman::SetState(), BIAS::ContourBSplineShapeMatrix::SetSubShapeSpaceZero(), BIAS::GaussHelmert::Solve(), BIAS::LeastSquaresSVD::Solve(), BIAS::SVD::Solve(), BIAS::CamPoseCalib::SolveLM_(), SquaredMahalanobisDistance(), BIAS::ImageAlignment::StrictPyramidAlign(), BIAS::Matrix< T >::Sub(), BIAS::Matrix< T >::SubIP(), BIAS::SymmetricMatrix3x3< T >::SymmetricMatrix3x3(), BIAS::TrackerBaseAffine2< StorageType >::TrackAffine_(), BIAS::MonteCarloTransform::Transform(), BIAS::UnscentedTransform::Transform(), BIAS::CovTransformPose::TransformPoint3D(), BIAS::CovTransformPose::TransformPose(), TNT::transpose(), BIAS::Kalman::Update(), BIAS::IteratedExtendedKalman::Update(), Upper_symmetric_eigenvalue_solve(), and BIAS::LeastSquaresLapack::WeightedSolve().
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
|
inherited |
method to save directly to a given filename.
internally using stream operator
|
inherited |
Scales column NoCol with scale.
|
inherited |
Scales row NoRow with scale.
|
inlineprotectedinherited |
Definition at line 152 of file cmat.h.
Referenced by TNT::Matrix< BIAS::BIAS::Vector< int > >::operator=().
|
inherited |
|
inherited |
Copies the contents of data into this at the position indicated by row and col.
The size of *this must be big enought to carry data
|
inherited |
Copies the contents of data into this at the position indicated by row and col.
The size of *this must be big enought to carry data. Data i interpreted as column vector
|
inherited |
set a col of matrix from vector
|
inherited |
Converts matrix to identity matrix.
Even if the matrix is not quadratic, the diagonal values starting with the upper left element are set to 1. Example:
1 0 0 1 0 0 0 0 1 0 or 0 1 0 0 0 0 1 0 0 1 0 0 0 0
|
inherited |
set a row of matrix from vector
|
inherited |
sets a submatrix in this.
Start index in this is [startRowInThis][startColInThis] end index is [startRowInThis+numRows-1][startColInThis+numCols-1]. Entries copyed from submatrix beginning at [startRowInSub][startColInSub] and stop at [startRowInSub+numRows-1][startColInSub+numCols-1]
|
inherited |
sets a 3x3 submatrix in this.
Start index in this is [startRowInThis][startColInThis] end index is [startRowInThis+2][startColInThis+2].
|
inherited |
sets a 3x1 submatrix in this.
Start index in this is [startRowInThis][startColInThis] end index is [startRowInThis+2][startColInThis].
|
inherited |
Copies the contents of data into this at the position indicated by row and col.
The size of *this must be big enought to carry data. Data is interpreted as row vector.
|
inlineinherited |
Sets all values to zero.
|
inlineinherited |
Definition at line 212 of file cmat.h.
Referenced by Eigenproblem_quadratic_matrix(), BIAS::Random::GetMeanAndCovariance(), BIAS::Matrix< T >::operator==(), and BIAS::IteratedExtendedKalman::SetState().
|
inlineinherited |
substraction function, storing data destination matrix
|
inlineinherited |
Subtracts arg from this
this -= arg.
|
inlineinherited |
|
inherited |
swaps two rows
|
inlineinherited |
void PoseParametrizationCovariance::Transform | ( | const Matrix4x4< double > & | transf | ) |
Given a 6D pose (position and euler angles) and its associated covariance, the function transforms the covaruiance into pose and quaternion parametrization.
matlab code:
alpha = sym('alpha'); beta = sym('beta'); gamma = sym('gamma'); % compute rotation matrix from euler angles R_gamma = [ cos(gamma) -sin(gamma) 0 sin(gamma) cos(gamma) 0 0 0 1]; R_beta = [ cos(beta) 0 sin(beta) 0 1 0 -sin(beta) 0 cos(beta) ]; R_alpha = [ 1 0 0 0 cos(alpha) -sin(alpha) 0 sin(alpha) cos(alpha) ]; R = R_gamma * R_beta * R_alpha; % compute quaternion q from rotation matrix q = [ 1/2 * sqrt(R(1,1) + R(2,2) + R(3,3) + 1) (R(3,2)-R(2,3))/(2*sqrt(R(1,1) + R(2,2) + R(3,3) + 1)) (R(1,3)-R(3,1))/(2*sqrt(R(1,1) + R(2,2) + R(3,3) + 1)) (R(2,1)-R(1,2))/(2*sqrt(R(1,1) + R(2,2) + R(3,3) + 1)) ]; % compute jacobian j = jacobian(q, [alpha, beta, gamma]); disp('J[0][0] = '); disp(j(1,1)); disp('J[1][0] = '); disp(j(2,1)); disp('J[2][0] = '); disp(j(3,1)); disp('J[3][0] = '); disp(j(4,1)); disp('J[0][1] = '); disp(j(1,2)); disp('J[1][1] = '); disp(j(2,2)); disp('J[2][1] = '); disp(j(3,2)); disp('J[3][1] = '); disp(j(4,2)); disp('J[0][2] = '); disp(j(1,3)); disp('J[1][2] = '); disp(j(2,3)); disp('J[2][2] = '); disp(j(3,3)); disp('J[3][2] = '); disp(j(4,3));
The 1st 3 entries of the 6D pose must be the euclidean position coordinates and the last 3 entries must be the Euler angles [Ax, Ay, Az] such that the final rotation matrix is composed from Rz * Ry * Rx. Where Rx denotes the rotation matrix describing the rotation around the x axis, ....
The seven dimensional pose p is transformed nonlinearily as follows
f_(0..2) (p) = T[0..2][0..2] * p[0..2] f_3 (p) = 0 f_(4..6) (p) = T[0..2][0..2] * 1/sin(acos(p[3])) * p[4..6] explanation: The pose is composed of the position (p[0..2]) and the orientation parametrized as a quaternion (p[3..6]). The transformation of the position is straight forward, i.e. by multiplying with T. The Jacobian of this transformation is aequivalent to the upper left 3x3 matrix of T. The union quaternion representing a rotation about the axis [x, y, z]' with angle a can be interpreted as q = [ cos(a/2), x* sin(*a/2), y*sin(a/2), z*sin(a/2)]' and the transformation of the quaternion is aequivalent to the transf. of the axis [x, y, z] = 1/(sin(acos(q[0])) * q[1..3]) hint: d/dx (1/(sin(acos(x))) = x/(1-x^2)^3/2
Definition at line 150 of file PoseParametrizationCovariance.cpp.
References BIAS::Equal(), BIAS::Matrix3x3< T >::GetColumn(), BIAS::RMatrixBase::GetQuaternion(), BIAS::Quaternion< T >::GetQuaternionMultMatrixLeft(), BIAS::MatrixZero, BIAS::Vector3< T >::Normalize(), BIAS::Matrix3x3< T >::SetColumn(), and BIAS::Matrix< T >::Transpose().
Referenced by BIAS::Pose::TransformToNewGlobalBy().
|
inlineinherited |
transpose function, storing data destination matrix
|
inherited |
vec-operator returns the elements of the matrix columwise as vector
vec-operator returns the elements of the matrix columnwise as vector
|
inherited |
Write the matrix in Matlab format to the given stream.
name | Is the name of the Matlab variable |
Definition at line 842 of file cmat.h.
References TNT::matmult().
Definition at line 915 of file cmat.h.
References TNT::matmult().
Definition at line 730 of file cmat.h.
References TNT::Matrix< T >::num_cols(), and TNT::Matrix< T >::num_rows().
Definition at line 752 of file cmat.h.
References TNT::Matrix< T >::num_cols(), and TNT::Matrix< T >::num_rows().
|
related |
|
related |
|
related |
|
related |
Definition at line 703 of file cmat.h.
References TNT::Matrix< T >::Read().
|
related |
Definition at line 711 of file cmat.h.
References TNT::Matrix< T >::Read().
|
related |
Definition at line 719 of file cmat.h.
References TNT::Matrix< T >::Read().
|
protectedinherited |
Definition at line 84 of file cmat.h.
Referenced by TNT::Matrix< BIAS::BIAS::Vector< int > >::copy(), TNT::Matrix< BIAS::BIAS::Vector< int > >::destroy(), TNT::Matrix< BIAS::BIAS::Vector< int > >::dim(), TNT::Matrix< BIAS::BIAS::Vector< int > >::initialize(), TNT::Matrix< BIAS::BIAS::Vector< int > >::Matrix(), TNT::Matrix< BIAS::BIAS::Vector< int > >::num_rows(), TNT::Matrix< BIAS::BIAS::Vector< int > >::operator()(), TNT::Matrix< BIAS::BIAS::Vector< int > >::operator=(), TNT::Matrix< BIAS::BIAS::Vector< int > >::operator[](), and TNT::Matrix< BIAS::BIAS::Vector< int > >::set().
|
protectedinherited |
Definition at line 86 of file cmat.h.
Referenced by TNT::Matrix< BIAS::BIAS::Vector< int > >::destroy(), TNT::Matrix< BIAS::BIAS::Vector< int > >::initialize(), TNT::Matrix< BIAS::BIAS::Vector< int > >::operator()(), and TNT::Matrix< BIAS::BIAS::Vector< int > >::size().
|
protectedinherited |
Definition at line 85 of file cmat.h.
Referenced by TNT::Matrix< BIAS::BIAS::Vector< int > >::copy(), TNT::Matrix< BIAS::BIAS::Vector< int > >::destroy(), TNT::Matrix< BIAS::BIAS::Vector< int > >::dim(), TNT::Matrix< BIAS::BIAS::Vector< int > >::initialize(), TNT::Matrix< BIAS::BIAS::Vector< int > >::Matrix(), TNT::Matrix< BIAS::BIAS::Vector< int > >::num_cols(), TNT::Matrix< BIAS::BIAS::Vector< int > >::operator()(), TNT::Matrix< BIAS::BIAS::Vector< int > >::operator=(), and TNT::Matrix< BIAS::BIAS::Vector< int > >::set().
|
protectedinherited |
Definition at line 88 of file cmat.h.
Referenced by TNT::Matrix< BIAS::BIAS::Vector< int > >::destroy(), TNT::Matrix< BIAS::BIAS::Vector< int > >::initialize(), TNT::Matrix< BIAS::BIAS::Vector< int > >::Matrix(), BIAS::PMatrix::Normalize(), and TNT::Matrix< BIAS::BIAS::Vector< int > >::operator[]().
|
protectedinherited |
Definition at line 90 of file cmat.h.
Referenced by TNT::Matrix< BIAS::BIAS::Vector< int > >::destroy(), TNT::Matrix< BIAS::BIAS::Vector< int > >::initialize(), and TNT::Matrix< BIAS::BIAS::Vector< int > >::operator()().
|
protectedinherited |
Definition at line 87 of file cmat.h.
Referenced by TNT::Matrix< BIAS::BIAS::Vector< int > >::copy(), TNT::Matrix< BIAS::BIAS::Vector< int > >::destroy(), TNT::Matrix< BIAS::BIAS::Vector< int > >::initialize(), TNT::Matrix< BIAS::BIAS::Vector< int > >::Matrix(), BIAS::AffineTransf::Mult(), BIAS::AffineTransf::operator=(), TNT::Matrix< BIAS::BIAS::Vector< int > >::operator=(), TNT::Matrix< BIAS::BIAS::Vector< int > >::set(), and BIAS::AffineTransf::SetAsRotationMatrix().
|
protectedinherited |
Definition at line 89 of file cmat.h.
Referenced by TNT::Matrix< BIAS::BIAS::Vector< int > >::initialize(), and TNT::Matrix< BIAS::BIAS::Vector< int > >::operator()().