#include <ViterbiAccum.h>


Public Member Functions | |
| void | addState (Mixture &m) |
| real_t & | logTransition (unsigned long i1, unsigned long i2) |
| real_t | logTransition (unsigned long i1, unsigned long i2) const |
| Mixture & | getState (unsigned long i) const |
| unsigned long | getStateCount () const |
| void | reset () |
| void | computeAndAccumulate (const Feature &f, double llkW=0) |
| void | computeAndAccumulate (FeatureServer &fs, unsigned long start, unsigned long count, double fudge) |
| void | computeAndAccumulate (FeatureServer &fs, DoubleVector &llk, unsigned long start, unsigned long count) |
| void | computeAndAccumulate (const Feature &f, double fudge, double penality) |
| unsigned long | getFeatureCount () const |
| const ULongVector & | getPath () |
| real_t | getLlp () const |
| virtual String | getClassName () const |
| virtual String | toString () const |
| virtual | ~ViterbiAccum () |
Static Public Member Functions | |
| static ViterbiAccum & | create (StatServer &, const Config &, const K &) |
Private Member Functions | |
| lk_t | computeStateLLK (unsigned long stateIndex, const Feature &) const |
| ViterbiAccum (StatServer &, const Config &) | |
| ViterbiAccum (const ViterbiAccum &) | |
| const ViterbiAccum & | operator= (const ViterbiAccum &c) |
| bool | operator== (const ViterbiAccum &c) const |
| bool | operator!= (const ViterbiAccum &c) const |
Private Attributes | |
| const Config * | _pConfig |
| RefVector< Mixture > | _stateVect |
| DoubleVector | _transMatrix |
| DoubleVector | _llpVect |
| DoubleVector | _tmpLLKVect |
| DoubleVector | _tmpllpVect |
| ULongVector | _tmpTab |
| unsigned long | _featureCount |
| ULongVector | _path |
| bool | _pathDefined |
| real_t | _llp |
| bool | _llpDefined |
| StatServer * | _pStatServer |
Friends | |
| class | TestViterbiAccum |
Class used to determine the Viterbi path. Only the Stat server can create this king of object
<FRANCAIS>Le modele ergodique est sans constrainte : toutes les transitions d'un etat vers l'autre sont possibles
Definition at line 95 of file ViterbiAccum.h.
| ViterbiAccum::~ViterbiAccum | ( | ) | [virtual] |
Definition at line 528 of file ViterbiAccum.cpp.
| ViterbiAccum::ViterbiAccum | ( | StatServer & | ss, |
| const Config & | c | ||
| ) | [private] |
| alize::ViterbiAccum::ViterbiAccum | ( | const ViterbiAccum & | ) | [private] |
| void ViterbiAccum::addState | ( | Mixture & | m ) |
Adds a state (a mixture)
| m | the mixture to add |
Definition at line 83 of file ViterbiAccum.cpp.
References _stateVect, _transMatrix, alize::RefVector< T >::addObject(), alize::RealVector< T >::setSize(), and alize::RefVector< T >::size().
| void ViterbiAccum::computeAndAccumulate | ( | FeatureServer & | fs, |
| unsigned long | start, | ||
| unsigned long | count, | ||
| double | fudge | ||
| ) |
New method from Corinne Fredouille (corinne.fredouille@lia.univ-avignon.fr)
Definition at line 223 of file ViterbiAccum.cpp.
References _featureCount, _llpDefined, _llpVect, _pathDefined, _stateVect, _tmpLLKVect, _tmpllpVect, _tmpTab, alize::ULongVector::addValue(), alize::RealVector< T >::addValue(), alize::RealVector< T >::clear(), computeStateLLK(), logTransition(), alize::FeatureServer::readFeature(), alize::FeatureServer::seekFeature(), and alize::RefVector< T >::size().
| void ViterbiAccum::computeAndAccumulate | ( | FeatureServer & | fs, |
| DoubleVector & | llk, | ||
| unsigned long | start, | ||
| unsigned long | count | ||
| ) |
New method from Corinne Fredouille (corinne.fredouille@lia.univ-avignon.fr)
Definition at line 163 of file ViterbiAccum.cpp.
References _featureCount, _llpDefined, _llpVect, _pathDefined, _stateVect, _tmpLLKVect, _tmpllpVect, _tmpTab, alize::ULongVector::addValue(), alize::RealVector< T >::addValue(), alize::RealVector< T >::clear(), computeStateLLK(), logTransition(), alize::FeatureServer::readFeature(), alize::FeatureServer::seekFeature(), and alize::RefVector< T >::size().
| void ViterbiAccum::computeAndAccumulate | ( | const Feature & | f, |
| double | fudge, | ||
| double | penality | ||
| ) |
New method from Corinne Fredouille (corinne.fredouille@lia.univ-avignon.fr)
Definition at line 409 of file ViterbiAccum.cpp.
References _featureCount, _llpDefined, _llpVect, _pathDefined, _stateVect, _tmpLLKVect, _tmpllpVect, _tmpTab, alize::ULongVector::addValue(), alize::RealVector< T >::addValue(), alize::RealVector< T >::clear(), computeStateLLK(), logTransition(), and alize::RefVector< T >::size().
| void ViterbiAccum::computeAndAccumulate | ( | const Feature & | f, |
| double | llkW = 0 |
||
| ) |
Updates the internal accumulators with the feature
| f | the feature |
| llkW | new parameter : contact corinne.fredouille@lia.univ-avignon.fr |
Definition at line 123 of file ViterbiAccum.cpp.
References _featureCount, _llpDefined, _llpVect, _pathDefined, _stateVect, _tmpLLKVect, _tmpllpVect, _tmpTab, alize::ULongVector::addValue(), alize::RealVector< T >::addValue(), alize::RealVector< T >::clear(), computeStateLLK(), logTransition(), and alize::RefVector< T >::size().
Definition at line 489 of file ViterbiAccum.cpp.
References _pStatServer, _stateVect, alize::StatServer::computeLLK(), and alize::RefVector< T >::getObject().
Referenced by computeAndAccumulate().
| ViterbiAccum & ViterbiAccum::create | ( | StatServer & | ss, |
| const Config & | c, | ||
| const K & | |||
| ) | [static] |
Definition at line 75 of file ViterbiAccum.cpp.
References alize::Object::assertMemoryIsAllocated(), and ViterbiAccum().
| String ViterbiAccum::getClassName | ( | ) | const [virtual] |
Returns the name of the class
Implements alize::Object.
Definition at line 499 of file ViterbiAccum.cpp.
| unsigned long ViterbiAccum::getFeatureCount | ( | ) | const |
Returns the number of features accumulated
Definition at line 450 of file ViterbiAccum.cpp.
References _featureCount.
| real_t ViterbiAccum::getLlp | ( | ) | const |
Returns the maximum log-probability value. You must call getPath() beforehand to compute the value
| Exception | if the value is not computed |
Definition at line 482 of file ViterbiAccum.cpp.
References _llp, and _llpDefined.
| const ULongVector & ViterbiAccum::getPath | ( | ) |
Computes and returns the Viterbi path
Definition at line 452 of file ViterbiAccum.cpp.
References _featureCount, _llp, _llpDefined, _llpVect, _path, _pathDefined, _stateVect, _tmpTab, alize::Object::max(), alize::ULongVector::setSize(), and alize::RefVector< T >::size().
| Mixture & ViterbiAccum::getState | ( | unsigned long | i ) | const |
Returns the state (Mixture object) of index i
| i | index |
| IndexOutOfBoundException |
Definition at line 103 of file ViterbiAccum.cpp.
References _stateVect, and alize::RefVector< T >::getObject().
| unsigned long ViterbiAccum::getStateCount | ( | ) | const |
Returns the number of states
Definition at line 106 of file ViterbiAccum.cpp.
References _stateVect, and alize::RefVector< T >::size().
Referenced by toString().
| real_t & ViterbiAccum::logTransition | ( | unsigned long | i1, |
| unsigned long | i2 | ||
| ) |
Sets or gets a log-probability transition between two states
| i1 | index of the first state |
| i2 | index of the second state |
| IndexOutOfBoundException |
Definition at line 90 of file ViterbiAccum.cpp.
References _stateVect, _transMatrix, and alize::RefVector< T >::size().
Referenced by computeAndAccumulate(), logTransition(), and toString().
| real_t ViterbiAccum::logTransition | ( | unsigned long | i1, |
| unsigned long | i2 | ||
| ) | const |
Definition at line 100 of file ViterbiAccum.cpp.
References logTransition().
| bool alize::ViterbiAccum::operator!= | ( | const ViterbiAccum & | c ) | const [private] |
not implemented
| const ViterbiAccum& alize::ViterbiAccum::operator= | ( | const ViterbiAccum & | c ) | [private] |
not implemented
| bool alize::ViterbiAccum::operator== | ( | const ViterbiAccum & | c ) | const [private] |
not implemented
| void ViterbiAccum::reset | ( | ) |
Resets the accumulators
Definition at line 114 of file ViterbiAccum.cpp.
References _featureCount, _llpDefined, _llpVect, _pathDefined, _tmpTab, alize::RealVector< T >::clear(), and alize::ULongVector::clear().
Referenced by ViterbiAccum().
| String ViterbiAccum::toString | ( | ) | const [virtual] |
This method is frequently overridden in the derived classes. If it is not, it returns the name of the class of the object and the address of the object
Reimplemented from alize::Object.
Definition at line 501 of file ViterbiAccum.cpp.
References _featureCount, _llp, _llpDefined, _path, _pathDefined, getStateCount(), logTransition(), and alize::String::valueOf().
friend class TestViterbiAccum [friend] |
Definition at line 97 of file ViterbiAccum.h.
unsigned long alize::ViterbiAccum::_featureCount [private] |
Definition at line 198 of file ViterbiAccum.h.
Referenced by computeAndAccumulate(), getFeatureCount(), getPath(), reset(), and toString().
real_t alize::ViterbiAccum::_llp [private] |
Definition at line 202 of file ViterbiAccum.h.
Referenced by getLlp(), getPath(), and toString().
bool alize::ViterbiAccum::_llpDefined [private] |
Definition at line 203 of file ViterbiAccum.h.
Referenced by computeAndAccumulate(), getLlp(), getPath(), reset(), and toString().
DoubleVector alize::ViterbiAccum::_llpVect [private] |
Definition at line 194 of file ViterbiAccum.h.
Referenced by computeAndAccumulate(), getPath(), and reset().
ULongVector alize::ViterbiAccum::_path [private] |
Definition at line 200 of file ViterbiAccum.h.
Referenced by getPath(), and toString().
bool alize::ViterbiAccum::_pathDefined [private] |
Definition at line 201 of file ViterbiAccum.h.
Referenced by computeAndAccumulate(), getPath(), reset(), and toString().
const Config* alize::ViterbiAccum::_pConfig [private] |
Definition at line 189 of file ViterbiAccum.h.
StatServer* alize::ViterbiAccum::_pStatServer [private] |
Definition at line 204 of file ViterbiAccum.h.
Referenced by computeStateLLK().
RefVector<Mixture> alize::ViterbiAccum::_stateVect [private] |
Definition at line 191 of file ViterbiAccum.h.
Referenced by addState(), computeAndAccumulate(), computeStateLLK(), getPath(), getState(), getStateCount(), and logTransition().
DoubleVector alize::ViterbiAccum::_tmpLLKVect [private] |
Definition at line 195 of file ViterbiAccum.h.
Referenced by computeAndAccumulate().
DoubleVector alize::ViterbiAccum::_tmpllpVect [private] |
Definition at line 196 of file ViterbiAccum.h.
Referenced by computeAndAccumulate().
ULongVector alize::ViterbiAccum::_tmpTab [private] |
Definition at line 197 of file ViterbiAccum.h.
Referenced by computeAndAccumulate(), getPath(), and reset().
Definition at line 192 of file ViterbiAccum.h.
Referenced by addState(), and logTransition().
1.7.2