marf.Classification
Interface IClassification

All Known Implementing Classes:
ChebyshevDistance, Classification, CosineSimilarityMeasure, DiffDistance, Distance, EuclideanDistance, HammingDistance, MahalanobisDistance, Markov, MaxProbabilityClassifier, MinkowskiDistance, NeuralNetwork, RandomClassification, Stochastic, ZipfLaw

public interface IClassification

Classification Interface.

$Id: IClassification.java,v 1.6 2006/07/31 02:19:13 mokhov Exp $

Since:
0.3.0.3
Version:
$Revision: 1.6 $
Author:
Serguei Mokhov

Field Summary
static java.lang.String MARF_INTERFACE_CODE_REVISION
          Interface source code revision.
 
Method Summary
 boolean classify()
          Generic classification routine.
 boolean classify(double[] padFeatureVector)
          Generic classification routine.
 IFeatureExtraction getFeatureExtraction()
          Retrieves the features source.
 Result getResult()
          Retrieves the likely classification result.
 ResultSet getResultSet()
          Retrieves the enclosed result set.
 void setFeatureExtraction(IFeatureExtraction poFeatureExtraction)
          Allows setting the features source.
 boolean train()
          Generic training routine for building/updating mean vectors in the training set.
 boolean train(double[] padFeatureVector)
          Generic training routine for building/updating mean vectors in the training set.
 

Field Detail

MARF_INTERFACE_CODE_REVISION

static final java.lang.String MARF_INTERFACE_CODE_REVISION
Interface source code revision.

See Also:
Constant Field Values
Method Detail

classify

boolean classify()
                 throws ClassificationException
Generic classification routine. Assumes presence of a valid, non-null IFeatureExtraction module.

Returns:
true if classification was successful; false otherwise
Throws:
ClassificationException - if there was an error while classifying

train

boolean train()
              throws ClassificationException
Generic training routine for building/updating mean vectors in the training set. Assumes presence of a valid, non-null IFeatureExtraction module.

Returns:
true if training was successful; false otherwise
Throws:
ClassificationException - if there was a problem while training

classify

boolean classify(double[] padFeatureVector)
                 throws ClassificationException
Generic classification routine.

Parameters:
padFeatureVector - vector of features to compare with the stored ones
Returns:
true if classification was successful; false otherwise
Throws:
ClassificationException - if there was an error while classifying
Since:
0.3.0.6

train

boolean train(double[] padFeatureVector)
              throws ClassificationException
Generic training routine for building/updating mean vectors in the training set.

Parameters:
padFeatureVector - vector of features to train on
Returns:
true if training was successful; false otherwise
Throws:
ClassificationException - if there was a problem while training
Since:
0.3.0.6

getResult

Result getResult()
Retrieves the likely classification result. If there were many, this will return the result with the highest statistical score or probability. The decision of whether to retrieve a maximum result (with maximum probability) or minimum result (with minimum distance) from the sample is left to be made by concrete implementations.

Returns:
Result object

getResultSet

ResultSet getResultSet()
Retrieves the enclosed result set.

Returns:
the enclosed ResultSet object

getFeatureExtraction

IFeatureExtraction getFeatureExtraction()
Retrieves the features source.

Returns:
returns the FeatureExtraction reference
Since:
0.3.0.4

setFeatureExtraction

void setFeatureExtraction(IFeatureExtraction poFeatureExtraction)
Allows setting the features source.

Parameters:
poFeatureExtraction - the FeatureExtraction object to set
Since:
0.3.0.4


SourceForge Logo