|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object mulan.classifier.MultiLabelLearnerBase mulan.classifier.neural.MMPLearner
public class MMPLearner
Implementation of Multiclass Multilabel Perceptrons learner. For more information, see
Koby Crammer, Yoram Singer (2003). A Family of Additive Online Algorithms for Category Ranking.. Journal of Machine Learning Research. 3(6):1025-1058.
@article{KobyCrammer2003, author = {Koby Crammer, Yoram Singer}, journal = {Journal of Machine Learning Research}, pages = {1025-1058}, title = {A Family of Additive Online Algorithms for Category Ranking.}, volume = {3(6)}, year = {2003} }
Field Summary |
---|
Fields inherited from class mulan.classifier.MultiLabelLearnerBase |
---|
featureIndices, labelIndices, numLabels |
Constructor Summary | |
---|---|
MMPLearner()
Default constructor using RankingLoss and uniform update |
|
MMPLearner(RankingLossFunction lossMeasure,
MMPUpdateRuleType modelUpdateRule)
Creates a new instance of MMPLearner . |
|
MMPLearner(RankingLossFunction lossMeasure,
MMPUpdateRuleType modelUpdateRule,
long randomnessSeed)
Creates a new instance of MMPLearner . |
Method Summary | |
---|---|
protected void |
buildInternal(MultiLabelInstances trainingSet)
Learner specific implementation of building the model from MultiLabelInstances
training data set. |
boolean |
getConvertNominalToBinary()
Gets a value indication whether conversion of nominal attributes from input data set to binary takes place prior to learning (and respectively making a prediction). |
TechnicalInformation |
getTechnicalInformation()
Returns an instance of a TechnicalInformation object, containing detailed information about the technical background of this class, e.g., paper reference or book this class is based on. |
int |
getTrainingEpochs()
Gets number of training epochs. |
String |
globalInfo()
Returns a string describing the multi-label learner. |
boolean |
isUpdatable()
Returns value indicating if learner is updatable, so if learner is able to perform on-line learning. |
MultiLabelOutput |
makePredictionInternal(Instance instance)
Learner specific implementation for predicting on specified data based on trained model. |
void |
setConvertNominalToBinary(boolean convert)
Sets whether nominal attributes from input data set has to be converted to binary prior to learning (and respectively making a prediction). |
void |
setTrainingEpochs(int epochs)
Sets the number of training epochs. |
Methods inherited from class mulan.classifier.MultiLabelLearnerBase |
---|
build, debug, getDebug, isModelInitialized, makeCopy, makePrediction, setDebug |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public MMPLearner()
public MMPLearner(RankingLossFunction lossMeasure, MMPUpdateRuleType modelUpdateRule)
MMPLearner
.
lossMeasure
- the loss measure to be used when judging
ranking performance in learning processmodelUpdateRule
- public MMPLearner(RankingLossFunction lossMeasure, MMPUpdateRuleType modelUpdateRule, long randomnessSeed)
MMPLearner
.
lossMeasure
- the loss measure to be used when judging
ranking performance in learning processmodelUpdateRule
- randomnessSeed
- the seed value for pseudo-random generatorMethod Detail |
---|
public void setTrainingEpochs(int epochs)
epochs
- the number of training epochs
IllegalArgumentException
- if passed value is invalidpublic int getTrainingEpochs()
public void setConvertNominalToBinary(boolean convert)
convert
- flag indicating whether conversion should take placepublic boolean getConvertNominalToBinary()
public boolean isUpdatable()
MultiLabelLearner
MultiLabelLearner.build(MultiLabelInstances)
method.false
is returned, each call of the
MultiLabelLearner.build(MultiLabelInstances)
will initialize the learner from
the scratch, removing any potential knowledge built by previously entered training data.
When true
is returned, then on the first call of the
MultiLabelLearner.build(MultiLabelInstances)
the learner is initialized
with the passed training data. All other calls contribute to the existing learner's
model with new data.
isUpdatable
in interface MultiLabelLearner
isUpdatable
in class MultiLabelLearnerBase
true
if learner is updatable (on-line), false
otherwise.protected void buildInternal(MultiLabelInstances trainingSet) throws Exception
MultiLabelLearnerBase
MultiLabelInstances
training data set. This method is called from MultiLabelLearnerBase.build(MultiLabelInstances)
method,
where behavior common across all learners is applied.
buildInternal
in class MultiLabelLearnerBase
trainingSet
- the training data set
Exception
- if learner model was not created successfullypublic MultiLabelOutput makePredictionInternal(Instance instance) throws InvalidDataException
MultiLabelLearnerBase
MultiLabelLearnerBase.makePrediction(weka.core.Instance)
which guards for model
initialization and apply common handling/behavior.
makePredictionInternal
in class MultiLabelLearnerBase
instance
- the data instance to predict on
InvalidDataException
- if specified instance data is invalid and can not be processed by the learnerpublic TechnicalInformation getTechnicalInformation()
MultiLabelLearnerBase
getTechnicalInformation
in interface TechnicalInformationHandler
getTechnicalInformation
in class MultiLabelLearnerBase
public String globalInfo()
MultiLabelLearnerBase
globalInfo
in class MultiLabelLearnerBase
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |