Environment Class Reference

Environment class. More...

#include <Beobot/Environment.H>

Collaboration diagram for Environment:
Collaboration graph
[legend]

List of all members.

Public Member Functions

Constructors, assignment, and Destructors

 Environment (std::string envFName=std::string(""))
 Constructor: generate a blank environment if file does not exist.
bool isBlank ()
 return true if environment has no segments
bool load (std::string fName)
 load the .env file
bool save (std::string fName, std::string envPrefix)
 save the main environment to a file
bool save (std::string fName, std::string tfName, std::string envPrefix)
 save the main and the just build environment
 ~Environment ()
 Destructor.
void setWindow (rutz::shared_ptr< XWinManaged > win)
 set the window to view results
void resetNumSegment (uint nSegment)
 reset the number of segments in the environment
void setCurrentSegment (uint currSegNum)
 set the current
Access functions

uint getNumSegment ()
 get the number of segments
rutz::shared_ptr< HistogramgetSegmentHistogram ()
 get the segment histogram
rutz::shared_ptr< TopologicalMapgetTopologicalMap ()
 get the topological map
rutz::shared_ptr< LandmarkDBgetLandmarkDB ()
 get the visual landmark database
Point2D< int > getLocation (uint cseg, float ltrav)
 get Point2D<int> location of the (segnum, ltrav) descriptor
void getLocationFloat (uint cseg, float ltrav, float &x, float &y)
 get Point2D<int> location (in float) of the (segnum, ltrav) descriptor
Compute functions

rutz::shared_ptr< HistogramclassifySegNum (Image< double > cgist)
 classify segment number from the input gist
void build (std::vector< rutz::shared_ptr< VisualObject > > &inputVO, std::vector< Point2D< int > > &objOffset, uint fNum, rutz::shared_ptr< VisualObject > scene)
 initialize a new landmarkDB to be build
void startBuild ()
void finishBuild (std::string prefix, std::string path, uint rframe)
 finish building the landmarkDB - has all the ending procedure

Detailed Description

Environment class.

Definition at line 54 of file Environment.H.


Constructor & Destructor Documentation

Environment::Environment ( std::string  envFName = std::string("")  ) 

Constructor: generate a blank environment if file does not exist.

Definition at line 48 of file Environment.C.

References load().

Environment::~Environment (  ) 

Destructor.

Definition at line 317 of file Environment.C.


Member Function Documentation

void Environment::build ( std::vector< rutz::shared_ptr< VisualObject > > &  inputVO,
std::vector< Point2D< int > > &  objOffset,
uint  fNum,
rutz::shared_ptr< VisualObject scene 
)

initialize a new landmarkDB to be build

Definition at line 358 of file Environment.C.

rutz::shared_ptr< Histogram > Environment::classifySegNum ( Image< double >  cgist  ) 

classify segment number from the input gist

Definition at line 322 of file Environment.C.

References FFNtrainInfo::isPCA, and matrixMult().

void Environment::finishBuild ( std::string  prefix,
std::string  path,
uint  rframe 
)

finish building the landmarkDB - has all the ending procedure

Definition at line 369 of file Environment.C.

References sformat(), and Raster::waitForKey().

rutz::shared_ptr< LandmarkDB > Environment::getLandmarkDB (  )  [inline]

get the visual landmark database

Definition at line 193 of file Environment.H.

Point2D< int > Environment::getLocation ( uint  cseg,
float  ltrav 
) [inline]

get Point2D<int> location of the (segnum, ltrav) descriptor

Definition at line 204 of file Environment.H.

void Environment::getLocationFloat ( uint  cseg,
float  ltrav,
float &  x,
float &  y 
) [inline]

get Point2D<int> location (in float) of the (segnum, ltrav) descriptor

Definition at line 210 of file Environment.H.

uint Environment::getNumSegment (  )  [inline]

get the number of segments

Definition at line 183 of file Environment.H.

rutz::shared_ptr< Histogram > Environment::getSegmentHistogram (  )  [inline]

get the segment histogram

Definition at line 178 of file Environment.H.

rutz::shared_ptr< TopologicalMap > Environment::getTopologicalMap (  )  [inline]

get the topological map

Definition at line 188 of file Environment.H.

bool Environment::isBlank (  ) 

return true if environment has no segments

Definition at line 71 of file Environment.C.

bool Environment::load ( std::string  fName  ) 

load the .env file

Definition at line 77 of file Environment.C.

References Timer::get(), Timer::reset(), resetNumSegment(), and sformat().

Referenced by Environment().

void Environment::resetNumSegment ( uint  nSegment  ) 

reset the number of segments in the environment

Definition at line 204 of file Environment.C.

Referenced by load().

bool Environment::save ( std::string  fName,
std::string  tfName,
std::string  envPrefix 
)

save the main and the just build environment

Definition at line 221 of file Environment.C.

bool Environment::save ( std::string  fName,
std::string  envPrefix 
)

save the main environment to a file

Definition at line 229 of file Environment.C.

void Environment::setCurrentSegment ( uint  currSegNum  ) 

set the current

Definition at line 211 of file Environment.C.

References ASSERT.

void Environment::setWindow ( rutz::shared_ptr< XWinManaged win  )  [inline]

set the window to view results

Definition at line 198 of file Environment.H.

void Environment::startBuild (  ) 

build the landmarkDB from the current run keep calling this every frame

Definition at line 349 of file Environment.C.

References rutz::shared_ptr< T >::reset().


The documentation for this class was generated from the following files:
Generated on Sun May 8 08:21:28 2011 for iLab Neuromorphic Vision Toolkit by  doxygen 1.6.3