LTI-Lib latest version v1.9 - last update 10 Apr 2010

lti::unsupervisedClassifier Class Reference

Abstract class, parent of all unsupervised classifiers. More...

#include <ltiUnsupervisedClassifier.h>

Inheritance diagram for lti::unsupervisedClassifier:
Inheritance graph
[legend]
Collaboration diagram for lti::unsupervisedClassifier:
Collaboration graph
[legend]

List of all members.

Classes

class  parameters
 the parameters for the class unsupervisedClassifier are the same as for classifier, except that the default value of mulipleMode is changed to outputTemplate::Ignore. More...

Public Member Functions

 unsupervisedClassifier ()
 unsupervisedClassifier (const unsupervisedClassifier &other)
virtual const char * getTypeName () const
unsupervisedClassifiercopy (const unsupervisedClassifier &other)
const parametersgetParameters () const
virtual bool train (const dmatrix &input)=0
virtual bool train (const dmatrix &input, ivector &ids)
virtual bool classify (const dvector &feature, outputVector &result) const =0

Protected Member Functions

bool selectRandomPoints (const dmatrix &data, int numberOfPoints, dmatrix &randomPoints)

Detailed Description

Abstract class, parent of all unsupervised classifiers.

This class defines the interface for all unsupervised train methods.


Constructor & Destructor Documentation

lti::unsupervisedClassifier::unsupervisedClassifier (  ) 

default constructor

lti::unsupervisedClassifier::unsupervisedClassifier ( const unsupervisedClassifier other  ) 

copy constructor

Parameters:
other the object to be copied

Member Function Documentation

virtual bool lti::unsupervisedClassifier::classify ( const dvector feature,
outputVector result 
) const [pure virtual]

Classification.

Classifies the feature and returns the outputVector with the classification result.

Parameters:
feature the vector to be classified
result the result of the classification
Returns:
false if an error occurred during classification else true

Implemented in lti::centroidClustering, lti::DBScan< T >, lti::MSTClustering< U >, lti::SOFM, and lti::SOFM2D.

unsupervisedClassifier& lti::unsupervisedClassifier::copy ( const unsupervisedClassifier other  ) 

copy data of "other" functor.

Parameters:
other the functor to be copied
Returns:
a reference to this functor object

Reimplemented from lti::classifier.

Reimplemented in lti::adaptiveKMeans, lti::centroidClustering, lti::clustering, lti::competitiveAgglomeration, lti::DBScan< T >, lti::fuzzyCMeans, lti::kMeansClustering, lti::MSTClustering< U >, lti::SOFM, and lti::SOFM2D.

const parameters& lti::unsupervisedClassifier::getParameters (  )  const
virtual const char* lti::unsupervisedClassifier::getTypeName (  )  const [virtual]
bool lti::unsupervisedClassifier::selectRandomPoints ( const dmatrix data,
int  numberOfPoints,
dmatrix randomPoints 
) [protected]

Randomly selects numberOfPoints points (rows) from the data matrix.

If nubmerOfPoints is greater than the number of points in data, points will be multiply selected.

Parameters:
data contains points to select from in rows
numberOfPoints number of points expected as result
randomPoints the points randomly selected from data
Returns:
false if something went wrong, else true
virtual bool lti::unsupervisedClassifier::train ( const dmatrix input,
ivector ids 
) [virtual]

Unsupervised training.

The vectors in the input matrix will be put into groups according to the training algorithm. Additionally, an integer indicating the class each point belongs to is returned.

By default this method uses the other train method (see train(const dmatrix&)) and then calls classifier::classify(const dvector&) to get the ids for each train-vector. These ids are then returned.

Parameters:
input the matrix with the input vectors (each row is a training vector)
ids vector of class ids for each input point
Returns:
true if successful, false otherwise. (if false you can check the error message with getStatusString())

Reimplemented in lti::adaptiveKMeans, lti::centroidClustering, lti::clustering, lti::competitiveAgglomeration, lti::DBScan< T >, lti::fuzzyCMeans, lti::kMeansClustering, lti::MSTClustering< U >, lti::SOFM, and lti::SOFM2D.

virtual bool lti::unsupervisedClassifier::train ( const dmatrix input  )  [pure virtual]

Unsupervised training.

The vectors in the input matrix will be clustered using each specific method.

Parameters:
input the matrix with the input vectors (each row is a training vector)
Returns:
true if successful, false otherwise. (if false you can check the error message with getStatusString())

Implemented in lti::adaptiveKMeans, lti::centroidClustering, lti::clustering, lti::competitiveAgglomeration, lti::DBScan< T >, lti::fuzzyCMeans, lti::kMeansClustering, lti::MSTClustering< U >, lti::SOFM, and lti::SOFM2D.


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

Generated on Sat Apr 10 15:27:01 2010 for LTI-Lib by Doxygen 1.6.1