edu.cmu.minorthird.classify
Class BatchVersion

java.lang.Object
  extended by edu.cmu.minorthird.classify.BatchClassifierLearner
      extended by edu.cmu.minorthird.classify.BatchVersion
All Implemented Interfaces:
ClassifierLearner, java.lang.Cloneable
Direct Known Subclasses:
BinaryBatchVersion, Recommended.VotedPerceptronLearner

public class BatchVersion
extends BatchClassifierLearner

Batch version of an OnlineClassifierLearner.

Author:
William Cohen

Field Summary
 
Fields inherited from class edu.cmu.minorthird.classify.BatchClassifierLearner
classifier, dataset
 
Constructor Summary
BatchVersion()
           
BatchVersion(OnlineClassifierLearner innerLearner)
           
BatchVersion(OnlineClassifierLearner innerLearner, int numberOfEpochs)
           
 
Method Summary
 Classifier batchTrain(Dataset dataset)
          subclasses should use this method to implement a batch supervised learning algorithm.
 OnlineClassifierLearner getInnerLearner()
           
 int getNumberOfEpochs()
           
 ExampleSchema getSchema()
          Returns the ExampleSchema - constraints on what the Examples will be.
 void setInnerLearner(OnlineClassifierLearner learner)
           
 void setNumberOfEpochs(int n)
           
 void setSchema(ExampleSchema schema)
          Accept an ExampleSchema - constraints on what the Examples will be.
 
Methods inherited from class edu.cmu.minorthird.classify.BatchClassifierLearner
addExample, completeTraining, copy, getClassifier, hasNextQuery, nextQuery, reset, setInstancePool
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BatchVersion

public BatchVersion(OnlineClassifierLearner innerLearner,
                    int numberOfEpochs)

BatchVersion

public BatchVersion(OnlineClassifierLearner innerLearner)

BatchVersion

public BatchVersion()
Method Detail

getNumberOfEpochs

public int getNumberOfEpochs()

setNumberOfEpochs

public void setNumberOfEpochs(int n)

getInnerLearner

public OnlineClassifierLearner getInnerLearner()

setInnerLearner

public void setInnerLearner(OnlineClassifierLearner learner)

setSchema

public final void setSchema(ExampleSchema schema)
Description copied from interface: ClassifierLearner
Accept an ExampleSchema - constraints on what the Examples will be.


getSchema

public final ExampleSchema getSchema()
Description copied from interface: ClassifierLearner
Returns the ExampleSchema - constraints on what the Examples will be.


batchTrain

public Classifier batchTrain(Dataset dataset)
Description copied from class: BatchClassifierLearner
subclasses should use this method to implement a batch supervised learning algorithm.

Specified by:
batchTrain in class BatchClassifierLearner