edu.cmu.minorthird.classify.sequential
Class GenericCollinsLearner
java.lang.Object
edu.cmu.minorthird.classify.sequential.GenericCollinsLearner
- All Implemented Interfaces:
- BatchSequenceClassifierLearner, SequenceClassifierLearner, SequenceConstants
public class GenericCollinsLearner
- extends java.lang.Object
- implements BatchSequenceClassifierLearner, SequenceConstants
'Generic' version of Collin's voted perceptron learner.
As of May 9, 2004, this is a different algorithm, which is much
more like Collin's original method. The 'old' implementation is in
GenericCollinsLearnerV1.
- Author:
- William Cohen
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
GenericCollinsLearner
public GenericCollinsLearner()
GenericCollinsLearner
public GenericCollinsLearner(OnlineClassifierLearner innerLearner)
GenericCollinsLearner
public GenericCollinsLearner(int epochs)
GenericCollinsLearner
public GenericCollinsLearner(OnlineClassifierLearner innerLearner,
int epochs)
GenericCollinsLearner
public GenericCollinsLearner(OnlineClassifierLearner innerLearner,
int historySize,
int epochs)
setSchema
public void setSchema(ExampleSchema schema)
- Specified by:
setSchema
in interface SequenceClassifierLearner
getInnerLearner
public OnlineClassifierLearner getInnerLearner()
setInnerLearner
public void setInnerLearner(OnlineClassifierLearner newInnerLearner)
getHistorySize
public int getHistorySize()
- Description copied from interface:
SequenceClassifierLearner
- Return the number of previous predictions used as features in
learning.
- Specified by:
getHistorySize
in interface SequenceClassifierLearner
setHistorySize
public void setHistorySize(int newHistorySize)
getNumberOfEpochs
public int getNumberOfEpochs()
setNumberOfEpochs
public void setNumberOfEpochs(int newNumberOfEpochs)
batchTrain
public SequenceClassifier batchTrain(SequenceDataset dataset)
- Specified by:
batchTrain
in interface BatchSequenceClassifierLearner