Package moa.classifiers.meta
Class ADACC
- java.lang.Object
-
- moa.AbstractMOAObject
-
- moa.options.AbstractOptionHandler
-
- moa.classifiers.AbstractClassifier
-
- moa.classifiers.meta.DACC
-
- moa.classifiers.meta.ADACC
-
- All Implemented Interfaces:
Configurable
,Serializable
,CapabilitiesHandler
,Classifier
,MultiClassClassifier
,AWTRenderable
,Learner<Example<Instance>>
,MOAObject
,OptionHandler
public class ADACC extends DACC implements MultiClassClassifier
Anticipative and Dynamic Adaptation to Concept Changes. Ensemble method for data streams that adapts to concept changes and deals with concept recurrence. Reference: JABER, G., CORNUEJOLS, A., and TARROUX, P. A New On-Line Learning Method for Coping with Recurring Concepts: The ADACC System. In : Neural Information Processing. Springer Berlin Heidelberg, 2013. p. 595-604.- Author:
- Ghazal Jaber (ghazal.jaber@gmail.com)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected int
addedPermanent
Number of added snapshotsFloatOption
equivIndexSizeOption
Threshold for concept equivalenceprotected double
index
Current stability indexprotected static int
MAXPERMANENT
Maximum number of snapshots (copies of classifiers kept in case of recurrence)protected Instances
recentChunk
Last chunk of data of size (tau_size) to compute the stability indexFloatOption
stabIndexSizeOption
Threshold for the stability indexprotected int
tau_size
Size of the evaluation window to compute the stability indexIntOption
tauSizeOption
Evaluation window for the stability index computationprotected double
theta_diff
Threshold values for the stability index and concept equivalenceprotected double
theta_stab
Threshold values for the stability index and concept equivalence-
Fields inherited from class moa.classifiers.meta.DACC
combinationOption, ensemble, ensembleAges, ensembleWeights, ensembleWindows, evaluationSizeOption, learnerOption, maturityOption, memberCountOption, nbInstances
-
Fields inherited from class moa.classifiers.AbstractClassifier
classifierRandom, modelContext, randomSeed, randomSeedOption, trainingWeightSeenByModel
-
Fields inherited from class moa.options.AbstractOptionHandler
config
-
-
Constructor Summary
Constructors Constructor Description ADACC()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description 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.protected int
getNbActiveClassifiers()
Returns the number of classifiers used for prediction which includes the adaptive learners and the snapshots in ADACCprotected int
getNbAdaptiveClassifiers()
Returns the number of adaptive classifiers in the ensemble which excludes the static snapshots in ADACCString
getPurposeString()
Dictionary with option texts and objectsprotected void
initVariables()
Initializes the method variablesvoid
trainOnInstanceImpl(Instance inst)
Trains this classifier incrementally using the given instance.
The reason for ...Impl methods: ease programmer burden by not requiring them to remember calls to super in overridden methods.-
Methods inherited from class moa.classifiers.meta.DACC
discardModel, getHalf, getMAXIndexes, getSubClassifiers, getVotesForInstance, getWVDIndexes, isRandomizable, resetLearningImpl, trainAndClassify, updateEvaluationWindow
-
Methods inherited from class moa.classifiers.AbstractClassifier
contextIsCompatible, copy, correctlyClassifies, defineImmutableCapabilities, getAttributeNameString, getAWTRenderer, getClassLabelString, getClassNameString, getDescription, getModel, getModelContext, getModelMeasurements, getNominalValueString, getPredictionForInstance, getPredictionForInstance, getSublearners, getVotesForInstance, modelAttIndexToInstanceAttIndex, modelAttIndexToInstanceAttIndex, prepareForUseImpl, resetLearning, setModelContext, setRandomSeed, trainingHasStarted, trainingWeightSeenByModel, trainOnInstance, trainOnInstance
-
Methods inherited from class moa.options.AbstractOptionHandler
getCLICreationString, getOptions, getPreparedClassOption, prepareClassOptions, prepareForUse, prepareForUse
-
Methods inherited from class moa.AbstractMOAObject
copy, measureByteSize, measureByteSize, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface moa.capabilities.CapabilitiesHandler
getCapabilities
-
Methods inherited from interface moa.MOAObject
measureByteSize
-
Methods inherited from interface moa.options.OptionHandler
getCLICreationString, getOptions, prepareForUse, prepareForUse
-
-
-
-
Field Detail
-
tauSizeOption
public IntOption tauSizeOption
Evaluation window for the stability index computation
-
stabIndexSizeOption
public FloatOption stabIndexSizeOption
Threshold for the stability index
-
equivIndexSizeOption
public FloatOption equivIndexSizeOption
Threshold for concept equivalence
-
tau_size
protected int tau_size
Size of the evaluation window to compute the stability index
-
recentChunk
protected Instances recentChunk
Last chunk of data of size (tau_size) to compute the stability index
-
theta_stab
protected double theta_stab
Threshold values for the stability index and concept equivalence
-
theta_diff
protected double theta_diff
Threshold values for the stability index and concept equivalence
-
index
protected double index
Current stability index
-
MAXPERMANENT
protected static final int MAXPERMANENT
Maximum number of snapshots (copies of classifiers kept in case of recurrence)- See Also:
- Constant Field Values
-
addedPermanent
protected int addedPermanent
Number of added snapshots
-
-
Method Detail
-
getPurposeString
public String getPurposeString()
Description copied from class:AbstractOptionHandler
Dictionary with option texts and objects- Specified by:
getPurposeString
in interfaceOptionHandler
- Overrides:
getPurposeString
in classDACC
- Returns:
- the string with the purpose of this object
-
initVariables
protected void initVariables()
Description copied from class:DACC
Initializes the method variables- Overrides:
initVariables
in classDACC
-
trainOnInstanceImpl
public void trainOnInstanceImpl(Instance inst)
Description copied from class:AbstractClassifier
Trains this classifier incrementally using the given instance.
The reason for ...Impl methods: ease programmer burden by not requiring them to remember calls to super in overridden methods. Note that this will produce compiler errors if not overridden.- Overrides:
trainOnInstanceImpl
in classDACC
- Parameters:
inst
- the instance to be used for training
-
getModelDescription
public void getModelDescription(StringBuilder out, int indent)
Description copied from class:AbstractClassifier
Returns a string representation of the model.- Overrides:
getModelDescription
in classDACC
- Parameters:
out
- the stringbuilder to add the descriptionindent
- the number of characters to indent
-
getModelMeasurementsImpl
protected Measurement[] getModelMeasurementsImpl()
Description copied from class:AbstractClassifier
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. Note that this will produce compiler errors if not overridden.- Overrides:
getModelMeasurementsImpl
in classDACC
- Returns:
- an array of measurements to be used in evaluation tasks
-
getNbActiveClassifiers
protected int getNbActiveClassifiers()
Description copied from class:DACC
Returns the number of classifiers used for prediction which includes the adaptive learners and the snapshots in ADACC- Overrides:
getNbActiveClassifiers
in classDACC
- Returns:
- the number of classifiers used for prediction
-
getNbAdaptiveClassifiers
protected int getNbAdaptiveClassifiers()
Description copied from class:DACC
Returns the number of adaptive classifiers in the ensemble which excludes the static snapshots in ADACC- Overrides:
getNbAdaptiveClassifiers
in classDACC
- Returns:
- the number of adaptive classifiers
-
-