CEBL  2.1
Public Member Functions | Friends
RealTimeClassification Class Reference

#include <RealTimeClassification.hpp>

Public Member Functions

 RealTimeClassification (CEBLModel *)
 ~RealTimeClassification ()
bool isReady () const
bool isClassifying () const
 check whether data is currently being classified
bool lastTrainFailed () const
std::vector< int > readClassificationQueue ()
 reads queue of classified sequences and clears the queue
std::vector< int > peekClassificationQueue () const
 reads queue of classified sequences without clearing the queue
std::vector< double > getClassProportions ()
int getSelectedClass () const
void clearSelectedClass ()
void clearClassificationQueue ()
void trainClassifier ()
void trainClassifierThreaded ()
bool isTrainingClassifier ()
void trainClassifierHalt ()
void startClassifying ()
void stopClassifying ()
void timeoutFunction ()
- Public Member Functions inherited from TimeoutThread
 TimeoutThread ()
virtual ~TimeoutThread ()
bool isHalted ()
bool isStarted ()
double getTimeoutLength ()
 get length of timeout in milliseconds
void setTimeoutLength (double l)
 set length of timeotu in milliseconds

Friends

void runTrainClassifier (RealTimeClassification *)
 friend function to run trainClassifier

Additional Inherited Members

- Protected Member Functions inherited from TimeoutThread
void timeoutStart ()
 start the thread
void haltAndJoin ()
 halt the thread and wait for it to finish
void sleep (double stime)
 sleep for stime in milliseconds
- Protected Attributes inherited from TimeoutThread
boost::thread * updater_thread
 the thread object
bool is_started
 flag to indicate whether or not the thread is started
bool halt
 flag to order thread to halt on next iteration
bool halted
 flag to indicate whether or not thread has hlated
boost::mutex thread_lock
 mutex to lock the thread
double timeout_length
 how often updater is called

Detailed Description

Definition at line 36 of file RealTimeClassification.hpp.


Constructor & Destructor Documentation

RealTimeClassification::RealTimeClassification ( CEBLModel model)

RealTimeClassification.cpp

Author:
Jeshua Bratman

Controls real-time classifying.

Definition at line 17 of file RealTimeClassification.cpp.

References TimeoutThread::timeout_length.

RealTimeClassification::~RealTimeClassification ( )

Definition at line 28 of file RealTimeClassification.cpp.


Member Function Documentation

void RealTimeClassification::clearClassificationQueue ( )
void RealTimeClassification::clearSelectedClass ( )
inline

Definition at line 67 of file RealTimeClassification.hpp.

Referenced by CEBLModel::realtimeClearSelectedClass().

std::vector<double> RealTimeClassification::getClassProportions ( )
inline

Definition at line 65 of file RealTimeClassification.hpp.

Referenced by CEBLModel::realtimeGetClassProportions().

int RealTimeClassification::getSelectedClass ( ) const
inline

Definition at line 66 of file RealTimeClassification.hpp.

Referenced by CEBLModel::realtimeGetSelectedClass().

bool RealTimeClassification::isClassifying ( ) const

check whether data is currently being classified

Definition at line 39 of file RealTimeClassification.cpp.

Referenced by CEBLModel::realtimeIsClassifying().

bool RealTimeClassification::isReady ( ) const
bool RealTimeClassification::isTrainingClassifier ( )

Definition at line 260 of file RealTimeClassification.cpp.

Referenced by CEBLModel::realtimeIsTrainingClassifier().

bool RealTimeClassification::lastTrainFailed ( ) const
inline

Definition at line 62 of file RealTimeClassification.hpp.

Referenced by CEBLModel::realtimeLastTrainFailed().

std::vector< int > RealTimeClassification::peekClassificationQueue ( ) const

reads queue of classified sequences without clearing the queue

Definition at line 52 of file RealTimeClassification.cpp.

Referenced by CEBLModel::realtimePeekClassificationQueue().

std::vector< int > RealTimeClassification::readClassificationQueue ( )

reads queue of classified sequences and clears the queue

Definition at line 44 of file RealTimeClassification.cpp.

References clearClassificationQueue().

Referenced by CEBLModel::realtimeReadClassificationQueue().

void RealTimeClassification::startClassifying ( )
void RealTimeClassification::stopClassifying ( )
void RealTimeClassification::timeoutFunction ( )
virtual
void RealTimeClassification::trainClassifier ( )
void RealTimeClassification::trainClassifierHalt ( )
void RealTimeClassification::trainClassifierThreaded ( )

Friends And Related Function Documentation

void runTrainClassifier ( RealTimeClassification obj)
friend

friend function to run trainClassifier

Definition at line 265 of file RealTimeClassification.cpp.

Referenced by trainClassifierThreaded().


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