public class TLC
extends weka.classifiers.SingleClassifierEnhancer
implements weka.core.TechnicalInformationHandler, weka.core.MultiInstanceCapabilitiesHandler
BibTeX:
@inproceedings{Weidmann2003, author = {Nils Weidmann and Eibe Frank and Bernhard Pfahringer}, booktitle = {Fourteenth European Conference on Machine Learning}, pages = {468-479}, publisher = {Springer}, title = {A two-level learning method for generalized multi-instance problems}, year = {2003} }
@inproceedings{FrankAndPfahringer203, author = {Eibe Frank and Bernhard Pfahringer}, booktitle = {AI 2013: Advances in Artificial Intelligence}, pages = {362-373}, publisher = {Springer}, title = {Propositionalisation of Multi-instance Data Using Random Forests}, year = {2013} }Valid options are:
-P "<name and options of partition generator>" Partition generator to use, including options. Quotes are needed when options are specified. (default: weka.classifiers.trees.J48)
-D If set, classifier is run in debug mode and may output additional info to the console
-W Full name of base classifier. (default: weka.classifiers.meta.LogitBoost)
Options specific to classifier weka.classifiers.meta.LogitBoost:
-Q Use resampling instead of reweighting for boosting.
-P <percent> Percentage of weight mass to base training on. (default 100, reduce to around 90 speed up)
-F <num> Number of folds for internal cross-validation. (default 0 -- no cross-validation)
-R <num> Number of runs for internal cross-validation. (default 1)
-L <num> Threshold on the improvement of the likelihood. (default -Double.MAX_VALUE)
-H <num> Shrinkage parameter. (default 1)
-S <num> Random number seed. (default 1)
-I <num> Number of iterations. (default 10)
-D If set, classifier is run in debug mode and may output additional info to the console
-W Full name of base classifier. (default: weka.classifiers.trees.DecisionStump)
Options specific to classifier weka.classifiers.trees.DecisionStump:
-D If set, classifier is run in debug mode and may output additional info to the console
Options specific to partition generator weka.classifiers.trees.J48:
-U Use unpruned tree.
-O Do not collapse tree.
-C <pruning confidence> Set confidence threshold for pruning. (default 0.25)
-M <minimum number of instances> Set minimum number of instances per leaf. (default 2)
-R Use reduced error pruning.
-N <number of folds> Set number of folds for reduced error pruning. One fold is used as pruning set. (default 3)
-B Use binary splits only.
-S Don't perform subtree raising.
-L Do not clean up after the tree has been built.
-A Laplace smoothing for predicted probabilities.
-J Do not use MDL correction for info gain on numeric attributes.
-Q <seed> Seed for random data shuffling (default 1).
Constructor and Description |
---|
TLC()
Constructor that sets default base learner.
|
Modifier and Type | Method and Description |
---|---|
void |
buildClassifier(weka.core.Instances data)
Builds the classifier from the given training data.
|
double[] |
distributionForInstance(weka.core.Instance inst)
Returns class probabilities for the given instance.
|
weka.core.Capabilities |
getCapabilities()
Returns the Capabilities of this filter.
|
weka.core.Capabilities |
getMultiInstanceCapabilities()
Returns the capabilities of this multi-instance filter for the relational
data (i.e., the bags).
|
java.lang.String[] |
getOptions()
Gets the current settings of the filter.
|
weka.core.PartitionGenerator |
getPartitionGenerator()
Get the generator used by this filter
|
java.lang.String |
getRevision()
Returns the revision string.
|
weka.core.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.
|
java.lang.String |
globalInfo()
Returns a string describing this filter
|
java.util.Enumeration<weka.core.Option> |
listOptions()
Returns an enumeration describing the available options.
|
static void |
main(java.lang.String[] options)
Main method for running this class from the command-line.
|
java.lang.String |
partitionGeneratorTipText()
Returns a description of this option suitable for display as a tip text in
the gui.
|
void |
setOptions(java.lang.String[] options)
Parses a given list of options.
|
void |
setPartitionGenerator(weka.core.PartitionGenerator newPartitionGenerator)
Set the generator for use in filtering
|
java.lang.String |
toString()
Returns a description of the classifier as a string.
|
classifierTipText, getClassifier, postExecution, preExecution, setClassifier
batchSizeTipText, classifyInstance, debugTipText, distributionsForInstances, doNotCheckCapabilitiesTipText, forName, getBatchSize, getDebug, getDoNotCheckCapabilities, getNumDecimalPlaces, implementsMoreEfficientBatchPrediction, makeCopies, makeCopy, numDecimalPlacesTipText, run, runClassifier, setBatchSize, setDebug, setDoNotCheckCapabilities, setNumDecimalPlaces
public java.lang.String globalInfo()
public weka.core.TechnicalInformation getTechnicalInformation()
getTechnicalInformation
in interface weka.core.TechnicalInformationHandler
public java.lang.String partitionGeneratorTipText()
public void setPartitionGenerator(weka.core.PartitionGenerator newPartitionGenerator)
newPartitionGenerator
- the generator to usepublic weka.core.PartitionGenerator getPartitionGenerator()
public java.util.Enumeration<weka.core.Option> listOptions()
listOptions
in interface weka.core.OptionHandler
listOptions
in class weka.classifiers.SingleClassifierEnhancer
public void setOptions(java.lang.String[] options) throws java.lang.Exception
-P "<name and options of partition generator>" Partition generator to use, including options. Quotes are needed when options are specified. (default: weka.classifiers.trees.J48)
-W Full name of base classifier. (default: weka.classifiers.meta.LogitBoost)
Options specific to classifier weka.classifiers.meta.LogitBoost:
-Q Use resampling instead of reweighting for boosting.
-P <percent> Percentage of weight mass to base training on. (default 100, reduce to around 90 speed up)
-F <num> Number of folds for internal cross-validation. (default 0 -- no cross-validation)
-R <num> Number of runs for internal cross-validation. (default 1)
-L <num> Threshold on the improvement of the likelihood. (default -Double.MAX_VALUE)
-H <num> Shrinkage parameter. (default 1)
-S <num> Random number seed. (default 1)
-I <num> Number of iterations. (default 10)
-W Full name of base classifier. (default: weka.classifiers.trees.DecisionStump)
Options specific to classifier weka.classifiers.trees.DecisionStump:
-D If set, classifier is run in debug mode and may output additional info to the console
Options specific to partition generator weka.classifiers.trees.J48:
-U Use unpruned tree.
-O Do not collapse tree.
-C <pruning confidence> Set confidence threshold for pruning. (default 0.25)
-M <minimum number of instances> Set minimum number of instances per leaf. (default 2)
-R Use reduced error pruning.
-N <number of folds> Set number of folds for reduced error pruning. One fold is used as pruning set. (default 3)
-B Use binary splits only.
-S Don't perform subtree raising.
-L Do not clean up after the tree has been built.
-A Laplace smoothing for predicted probabilities.
-J Do not use MDL correction for info gain on numeric attributes.
-Q <seed> Seed for random data shuffling (default 1).Options after the -- are passed on to the clusterer.
setOptions
in interface weka.core.OptionHandler
setOptions
in class weka.classifiers.SingleClassifierEnhancer
options
- the list of options as an array of stringsjava.lang.Exception
- if an option is not supportedpublic java.lang.String[] getOptions()
getOptions
in interface weka.core.OptionHandler
getOptions
in class weka.classifiers.SingleClassifierEnhancer
public void buildClassifier(weka.core.Instances data) throws java.lang.Exception
buildClassifier
in interface weka.classifiers.Classifier
java.lang.Exception
public java.lang.String toString()
toString
in class java.lang.Object
public double[] distributionForInstance(weka.core.Instance inst) throws java.lang.Exception
distributionForInstance
in interface weka.classifiers.Classifier
distributionForInstance
in class weka.classifiers.AbstractClassifier
java.lang.Exception
public java.lang.String getRevision()
getRevision
in interface weka.core.RevisionHandler
getRevision
in class weka.classifiers.AbstractClassifier
public weka.core.Capabilities getCapabilities()
getCapabilities
in interface weka.classifiers.Classifier
getCapabilities
in interface weka.core.CapabilitiesHandler
getCapabilities
in class weka.classifiers.SingleClassifierEnhancer
Capabilities
public weka.core.Capabilities getMultiInstanceCapabilities()
getMultiInstanceCapabilities
in interface weka.core.MultiInstanceCapabilitiesHandler
Capabilities
public static void main(java.lang.String[] options)