#include <Distrib.h>


Public Member Functions | |
| Distrib (unsigned long vectSize) | |
| virtual const Distrib & | operator= (const Distrib &d)=0 |
| virtual bool | operator== (const Distrib &d) const =0 |
| bool | operator!= (const Distrib &d) const |
| virtual | ~Distrib () |
| Distrib & | duplicate (const K &) const |
| virtual void | reset ()=0 |
| unsigned long | getVectSize () const |
| real_t | getMean (unsigned long index) const |
| DoubleVector & | getMeanVect () |
| const DoubleVector & | getMeanVect () const |
| void | setMean (real_t value, unsigned long index) |
| void | setMeanVect (const DoubleVector &v) |
| virtual lk_t | computeLK (const Feature &) const =0 |
| virtual lk_t | computeLK (const Feature &, unsigned long idx) const =0 |
| real_t | getCst () const |
| real_t | getDet () const |
| virtual void | computeAll ()=0 |
| virtual String | getClassName () const =0 |
| virtual String | toString () const =0 |
| void | setDet (const K &, const real_t v) |
| void | setCst (const K &, const real_t v) |
| unsigned long & | dictIndex (const K &) |
| unsigned long & | refCounter (const K &) |
Static Public Member Functions | |
| static Distrib & | create (const K &, const DistribType, unsigned long vectSize) |
Protected Attributes | |
| const unsigned long | _vectSize |
| real_t | _det |
| real_t | _cst |
| DoubleVector | _meanVect |
Private Member Functions | |
| virtual Distrib & | clone () const =0 |
Private Attributes | |
| unsigned long | _refCounter |
| unsigned long | _dictIndex |
Friends | |
| class | TestDistribGD |
| class | TestDistribGF |
| class | TestMixtureGD |
| class | TestMixtureGF |
| class | TestMixtureServer |
| class | TestDistribRefVector |
Abstract base class for all distribution classes.
Definition at line 81 of file Distrib.h.
| D::Distrib | ( | unsigned long | vectSize ) |
Definition at line 67 of file Distrib.cpp.
| D::~Distrib | ( | ) | [virtual] |
Definition at line 99 of file Distrib.cpp.
| virtual Distrib& alize::Distrib::clone | ( | ) | const [private, pure virtual] |
Implemented in alize::DistribGD, and alize::DistribGF.
| virtual void alize::Distrib::computeAll | ( | ) | [pure virtual] |
Computes internal data (determinant of the matrix, inverse covariance and a constante used for likelihood computation)
Implemented in alize::DistribGD, and alize::DistribGF.
Compute the likelihood between this distribution and a Feature object. The algorithm is implemented in the derived classes.
Implemented in alize::DistribGD, and alize::DistribGF.
Implemented in alize::DistribGD, and alize::DistribGF.
| Distrib & D::create | ( | const K & | , |
| const DistribType | type, | ||
| unsigned long | vectSize | ||
| ) | [static] |
Definition at line 101 of file Distrib.cpp.
References alize::DistribGF::create(), alize::DistribGD::create(), alize::DistribType_GD, alize::DistribType_GF, and alize::K::k.
| unsigned long & D::dictIndex | ( | const K & | ) |
Definition at line 97 of file Distrib.cpp.
Reimplemented in alize::DistribGD, and alize::DistribGF.
Definition at line 73 of file Distrib.cpp.
| String D::getClassName | ( | ) | const [pure virtual] |
Returns the name of the class
Implements alize::Object.
Implemented in alize::DistribGD, and alize::DistribGF.
Definition at line 132 of file MixtureDict.cpp.
| real_t D::getCst | ( | ) | const |
Returns the constante used to compute likelihood.
Definition at line 89 of file Distrib.cpp.
| real_t D::getDet | ( | ) | const |
Returns the determinant of the matrix.
Definition at line 87 of file Distrib.cpp.
| real_t D::getMean | ( | unsigned long | index ) | const |
get a value in the mean vector
| index | position in the array |
| IndexOutOfBoundsException |
Definition at line 77 of file Distrib.cpp.
| DoubleVector & D::getMeanVect | ( | ) |
Returns a reference to the mean vector
Definition at line 79 of file Distrib.cpp.
| const DoubleVector & D::getMeanVect | ( | ) | const |
Returns a constant reference to the mean vector
Definition at line 81 of file Distrib.cpp.
| unsigned long D::getVectSize | ( | ) | const |
Returns the size of the vectors/matrices
Definition at line 75 of file Distrib.cpp.
Referenced by alize::MixtureGF::addDistrib(), alize::MixtureGD::addDistrib(), alize::DistribGD::operator=(), alize::MixtureGF::setDistrib(), and alize::MixtureGD::setDistrib().
| bool D::operator!= | ( | const Distrib & | d ) | const |
Tests whether this distribution content is different from the d distribution content. This method uses the method operator=().
| d | the distribution to compare with this one |
Definition at line 71 of file Distrib.cpp.
Copy data members of a distribution in this distribution.
| d | the distribution source |
| Exception | see sub-classes |
Implemented in alize::DistribGD, and alize::DistribGF.
| virtual bool alize::Distrib::operator== | ( | const Distrib & | d ) | const [pure virtual] |
Tests whether this distribution content is equal to the d distribution content. To know the meaning of "equals", see the same method in the derived classes.
| d | the distribution to compare with this one |
Implemented in alize::DistribGD, and alize::DistribGF.
| unsigned long & D::refCounter | ( | const K & | ) |
Definition at line 95 of file Distrib.cpp.
Referenced by alize::DistribRefVector::addDistrib(), alize::DistribRefVector::clear(), alize::DistribRefVector::deleteUnreferencedDistribs(), and alize::DistribRefVector::setDistrib().
| virtual void alize::Distrib::reset | ( | ) | [pure virtual] |
Reset the distribution. This is a pure virtual method. To know the exact meaning of 'reset', look at the overriden method in the derived classes
Implemented in alize::DistribGD, and alize::DistribGF.
Sets the constante (internal usage)
| v | value of the constante |
Definition at line 93 of file Distrib.cpp.
Sets the determinant (internal usage)
| v | value of the determinant |
Definition at line 91 of file Distrib.cpp.
| void D::setMean | ( | real_t | value, |
| unsigned long | index | ||
| ) |
Sets a value in the mean vector.
| value | value to set |
| index | position in the array |
| IndexOutOfBoundsException |
Definition at line 83 of file Distrib.cpp.
| void D::setMeanVect | ( | const DoubleVector & | v ) |
Sets all the values in the mean vector.
| v | the vector |
| Exception | if size of v is not equal to size of mean vector |
Definition at line 85 of file Distrib.cpp.
| String D::toString | ( | ) | const [pure 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.
Implemented in alize::DistribGD, and alize::DistribGF.
Definition at line 134 of file MixtureDict.cpp.
References alize::Mixture::getId(), alize::Object::toString(), and alize::String::valueOf().
friend class TestDistribGD [friend] |
Reimplemented in alize::DistribGD.
friend class TestDistribGF [friend] |
Reimplemented in alize::DistribGF.
friend class TestMixtureGD [friend] |
Reimplemented in alize::DistribGD.
friend class TestMixtureGF [friend] |
Reimplemented in alize::DistribGF.
real_t alize::Distrib::_cst [protected] |
constante
Reimplemented in alize::DistribGF.
Definition at line 206 of file Distrib.h.
Referenced by alize::DistribGD::computeAll(), alize::DistribGD::computeLK(), alize::DistribGD::DistribGD(), alize::DistribGD::operator=(), and alize::DistribGD::toString().
real_t alize::Distrib::_det [protected] |
determinant
Definition at line 205 of file Distrib.h.
Referenced by alize::DistribGF::computeAll(), alize::DistribGD::computeAll(), alize::DistribGD::DistribGD(), alize::DistribGF::DistribGF(), alize::DistribGF::operator=(), alize::DistribGD::operator=(), alize::DistribGF::toString(), and alize::DistribGD::toString().
unsigned long alize::Distrib::_dictIndex [private] |
DoubleVector alize::Distrib::_meanVect [protected] |
mean vector
Definition at line 207 of file Distrib.h.
Referenced by alize::DistribGF::computeLK(), alize::DistribGD::computeLK(), alize::DistribGD::DistribGD(), alize::DistribGF::DistribGF(), alize::DistribGF::operator=(), alize::DistribGD::operator=(), alize::DistribGF::operator==(), alize::DistribGD::operator==(), alize::DistribGD::reset(), alize::DistribGF::toString(), and alize::DistribGD::toString().
unsigned long alize::Distrib::_refCounter [private] |
const unsigned long alize::Distrib::_vectSize [protected] |
dimension of the distribution
Definition at line 204 of file Distrib.h.
Referenced by alize::DistribGF::computeAll(), alize::DistribGD::computeAll(), alize::DistribGF::computeLK(), alize::DistribGD::computeLK(), alize::DistribGF::getCov(), alize::DistribGD::getCovVect(), alize::DistribGF::operator=(), alize::DistribGD::operator=(), alize::DistribGD::reset(), alize::DistribGF::setCov(), alize::DistribGF::toString(), and alize::DistribGD::toString().
1.7.2