Jafar
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Classes | Public Member Functions | Private Member Functions | Private Attributes | Friends
jafar::sams::BackgroundAnalysis Class Reference

This class provide methods to analysis image background. More...


Detailed Description

This class provide methods to analysis image background.

Definition at line 23 of file background.hpp.

#include <background.hpp>

List of all members.

Classes

struct  Bkg
class  Params
 BackgroundAnalysis parameters class. More...

Public Member Functions

 BackgroundAnalysis (Params params_=Params())
 default constructor
 ~BackgroundAnalysis ()
 constructor from file
std::vector< std::string > getLabels () const
 load data from file
void learnNewBackground (std::string const &label_, std::vector< jafar::image::Image > const &vImg_)
 learn new background
void updateBackground (std::string const &label_, jafar::image::Image const &img_)
 update background
bool checkSimilarity (jafar::image::Image const &img_) const
 check the image is similar to a known background

Private Member Functions

template<class Archive >
void serialize (Archive &ar, const unsigned int version)
jblas::vec img2vec (jafar::image::Image const &img_) const
jafar::image::Imagevec2img (jblas::vec const &vec_) const

Private Attributes

Params params
 parameters
std::map< std::string, Bkgbackgrounds
 map of backgrounds models

Friends

class boost::serialization::access

Constructor & Destructor Documentation

constructor from file

Parameters:
fname_path to data file

Definition at line 65 of file background.hpp.

References backgrounds.


Member Function Documentation

check the image is similar to a known background

Returns:
true if a similarity is found
std::vector<std::string> jafar::sams::BackgroundAnalysis::getLabels ( ) const [inline]

load data from file

Parameters:
fname_path to data file save data to file
fname_path to data file
Returns:
the backgrounds label

Definition at line 83 of file background.hpp.

References backgrounds.

void jafar::sams::BackgroundAnalysis::learnNewBackground ( std::string const &  label_,
std::vector< jafar::image::Image > const &  vImg_ 
)

learn new background

Parameters:
label_background label
vImg_a vector of images
void jafar::sams::BackgroundAnalysis::updateBackground ( std::string const &  label_,
jafar::image::Image const &  img_ 
)

update background

Parameters:
label_background label
img_new image

The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on Wed Oct 15 2014 00:37:47 for Jafar by doxygen 1.7.6.1
LAAS-CNRS