public class MEKAClassifier extends AbstractMultiLabelLearner implements MultiTargetRegressor, Serializable
Modifier and Type | Field and Description |
---|---|
WEKAClassOption |
baseLearnerOption |
protected weka.classifiers.Classifier |
classifier |
protected SamoaToWekaInstanceConverter |
instanceConverter |
protected weka.core.Instances |
instancesBuffer |
protected boolean |
isClassificationEnabled |
classifierRandom, downSampleRatio, modelContext, randomSeed, randomSeedOption, trainingWeightSeenByModel
config
Constructor and Description |
---|
MEKAClassifier() |
Modifier and Type | Method and Description |
---|---|
void |
createWekaClassifier(String[] options) |
void |
getModelDescription(StringBuilder out,
int indent)
Returns a string representation of the model.
|
protected Measurement[] |
getModelMeasurementsImpl()
Gets the current measurements of this classifier.
The reason for ...Impl methods: ease programmer burden by not requiring them to remember calls to super in overridden methods. |
Prediction |
getPredictionForInstance(MultiLabelInstance samoaInstance) |
String |
getPurposeString()
Dictionary with option texts and objects
|
double[] |
getVotesForInstance(Instance samoaInstance)
Predicts the class memberships for a given instance.
|
boolean |
isRandomizable()
Gets whether this learner needs a random seed.
|
void |
resetLearningImpl()
Resets this classifier.
|
void |
trainOnInstanceImpl(MultiLabelInstance samoaInstance) |
getPredictionForInstance, getPredictionForInstance, trainOnInstanceImpl
contextIsCompatible, copy, correctlyClassifies, getAttributeNameString, getAWTRenderer, getClassLabelString, getClassNameString, getDescription, getDownSampleRatio, getModel, getModelContext, getModelMeasurements, getNominalValueString, getSubClassifiers, getSublearners, getVotesForInstance, modelAttIndexToInstanceAttIndex, modelAttIndexToInstanceAttIndex, prepareForUseImpl, resetLearning, setModelContext, setRandomSeed, trainingHasStarted, trainingWeightSeenByModel, trainOnInstance, trainOnInstance, updateDownSampleRatio
getCLICreationString, getOptions, getPreparedClassOption, prepareClassOptions, prepareForUse, prepareForUse
copy, measureByteSize, measureByteSize, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
copy, correctlyClassifies, getPredictionForInstance, getSubClassifiers, trainOnInstance
getModel, getModelContext, getModelMeasurements, getPredictionForInstance, getSublearners, getVotesForInstance, resetLearning, setModelContext, setRandomSeed, trainingHasStarted, trainingWeightSeenByModel, trainOnInstance
getCLICreationString, getOptions, prepareForUse, prepareForUse
getDescription, measureByteSize
getAWTRenderer
protected SamoaToWekaInstanceConverter instanceConverter
public WEKAClassOption baseLearnerOption
protected weka.classifiers.Classifier classifier
protected weka.core.Instances instancesBuffer
protected boolean isClassificationEnabled
public String getPurposeString()
AbstractOptionHandler
getPurposeString
in interface OptionHandler
getPurposeString
in class AbstractClassifier
public void resetLearningImpl()
AbstractClassifier
resetLearningImpl
in class AbstractClassifier
public void trainOnInstanceImpl(MultiLabelInstance samoaInstance)
trainOnInstanceImpl
in interface MultiLabelLearner
trainOnInstanceImpl
in class AbstractMultiLabelLearner
public double[] getVotesForInstance(Instance samoaInstance)
Classifier
getVotesForInstance
in interface Classifier
getVotesForInstance
in class AbstractMultiLabelLearner
samoaInstance
- the instance to be classifiedpublic Prediction getPredictionForInstance(MultiLabelInstance samoaInstance)
getPredictionForInstance
in interface MultiLabelLearner
getPredictionForInstance
in class AbstractMultiLabelLearner
protected Measurement[] getModelMeasurementsImpl()
AbstractClassifier
getModelMeasurementsImpl
in class AbstractClassifier
public boolean isRandomizable()
Learner
isRandomizable
in interface Learner<Example<Instance>>
public void getModelDescription(StringBuilder out, int indent)
AbstractClassifier
getModelDescription
in class AbstractClassifier
out
- the stringbuilder to add the descriptionindent
- the number of characters to indentCopyright © 2019 University of Waikato, Hamilton, NZ. All Rights Reserved.