Public Member Functions | Friends | List of all members
DBoW2::BowVector Class Reference

Vector of words to represent images. More...

#include <BowVector.h>

Inheritance diagram for DBoW2::BowVector:
Inheritance graph
[legend]

Public Member Functions

void addIfNotExist (WordId id, WordValue v)
 
void addWeight (WordId id, WordValue v)
 
 BowVector (void)
 
void normalize (LNorm norm_type)
 
void saveM (const std::string &filename, size_t W) const
 
 ~BowVector (void)
 

Friends

std::ostream & operator<< (std::ostream &out, const BowVector &v)
 

Detailed Description

Vector of words to represent images.

Definition at line 56 of file BowVector.h.

Constructor & Destructor Documentation

DBoW2::BowVector::BowVector ( void  )

Constructor

Definition at line 22 of file BowVector.cpp.

DBoW2::BowVector::~BowVector ( void  )

Destructor

Definition at line 28 of file BowVector.cpp.

Member Function Documentation

void DBoW2::BowVector::addIfNotExist ( WordId  id,
WordValue  v 
)

Adds a word with a value to the vector only if this does not exist yet

Parameters
idword id to look for
vvalue to give to the word if this does not exist

Definition at line 50 of file BowVector.cpp.

void DBoW2::BowVector::addWeight ( WordId  id,
WordValue  v 
)

Adds a value to a word value existing in the vector, or creates a new word with the given value

Parameters
idword id to look for
vvalue to create the word with, or to add to existing word

Definition at line 34 of file BowVector.cpp.

void DBoW2::BowVector::normalize ( LNorm  norm_type)

L1-Normalizes the values in the vector

Parameters
norm_typenorm used

Definition at line 62 of file BowVector.cpp.

void DBoW2::BowVector::saveM ( const std::string &  filename,
size_t  W 
) const

Saves the bow vector as a vector in a matlab file

Parameters
filename
Wnumber of words in the vocabulary

Definition at line 105 of file BowVector.cpp.

Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  out,
const BowVector v 
)
friend

Prints the content of the bow vector

Parameters
outstream
v

Definition at line 88 of file BowVector.cpp.


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


orb_slam2_ros
Author(s):
autogenerated on Wed Apr 21 2021 02:53:05