cc.mallet.classify
Class ClassifierEnsemble

java.lang.Object
  extended by cc.mallet.classify.Classifier
      extended by cc.mallet.classify.ClassifierEnsemble
All Implemented Interfaces:
AlphabetCarrying, java.io.Serializable

public class ClassifierEnsemble
extends Classifier

Classifer for an ensemble of classifers, combined with learned weights. The procedure is to obtain the score from each classifier (typically p(y|x)), perform the weighted sum of these scores, then exponentiate the summed score for each class, and re-normalize the resulting per-class scores. In other words, the scores of the ensemble classifiers are treated as input features in a Maximum Entropy classifier.

Author:
Andrew McCallum
See Also:
Serialized Form

Field Summary
 
Fields inherited from class cc.mallet.classify.Classifier
instancePipe
 
Constructor Summary
ClassifierEnsemble(Classifier[] classifiers, double[] weights)
           
 
Method Summary
 Classification classify(Instance instance)
           
 
Methods inherited from class cc.mallet.classify.Classifier
alphabetsMatch, classify, classify, classify, getAccuracy, getAlphabet, getAlphabets, getAverageRank, getF1, getF1, getF1, getFeatureSelection, getInstancePipe, getLabelAlphabet, getPerClassFeatureSelection, getPrecision, getPrecision, getPrecision, getRecall, getRecall, getRecall, print, print
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ClassifierEnsemble

public ClassifierEnsemble(Classifier[] classifiers,
                          double[] weights)
Method Detail

classify

public Classification classify(Instance instance)
Specified by:
classify in class Classifier