public class MIOptimalBall
extends weka.classifiers.AbstractClassifier
implements weka.core.OptionHandler, weka.core.WeightedInstancesHandler, weka.core.MultiInstanceCapabilitiesHandler, weka.core.TechnicalInformationHandler
@inproceedings{Auer2004,
author = {Peter Auer and Ronald Ortner},
booktitle = {15th European Conference on Machine Learning},
note = {LNAI 3201},
pages = {63-74},
publisher = {Springer},
title = {A Boosting Approach to Multiple Instance Learning},
year = {2004}
}
Valid options are:
-N <num> Whether to 0=normalize/1=standardize/2=neither. (default 0=normalize)
| Modifier and Type | Field and Description |
|---|---|
static int |
FILTER_NONE
No normalization/standardization
|
static int |
FILTER_NORMALIZE
Normalize training data
|
static int |
FILTER_STANDARDIZE
Standardize training data
|
static weka.core.Tag[] |
TAGS_FILTER
The filter to apply to the training data
|
| Constructor and Description |
|---|
MIOptimalBall() |
| Modifier and Type | Method and Description |
|---|---|
void |
buildClassifier(weka.core.Instances data)
Builds the classifier
|
void |
calculateDistance(weka.core.Instances train)
calculate the distances from each instance in a positive bag to each bag.
|
double[] |
distributionForInstance(weka.core.Instance newBag)
Computes the distribution for a given multiple instance
|
java.lang.String |
filterTypeTipText()
Returns the tip text for this property
|
void |
findRadius(weka.core.Instances train)
Find the maximum radius for the optimal ball.
|
weka.core.Capabilities |
getCapabilities()
Returns default capabilities of the classifier.
|
weka.core.SelectedTag |
getFilterType()
Gets how the training data will be transformed.
|
weka.core.Capabilities |
getMultiInstanceCapabilities()
Returns the capabilities of this multi-instance classifier for the
relational data.
|
java.lang.String[] |
getOptions()
Gets the current settings of the classifier.
|
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[] argv)
Main method for testing this class.
|
double |
minBagDistance(weka.core.Instance center,
weka.core.Instance bag)
Calculate the distance from one data point to a bag
|
void |
setFilterType(weka.core.SelectedTag newType)
Sets how the training data will be transformed.
|
void |
setOptions(java.lang.String[] options)
Parses a given list of options.
|
double[] |
sortArray(double[] distance)
Sort the array.
|
batchSizeTipText, classifyInstance, debugTipText, distributionsForInstances, doNotCheckCapabilitiesTipText, forName, getBatchSize, getDebug, getDoNotCheckCapabilities, getNumDecimalPlaces, implementsMoreEfficientBatchPrediction, makeCopies, makeCopy, numDecimalPlacesTipText, postExecution, preExecution, run, runClassifier, setBatchSize, setDebug, setDoNotCheckCapabilities, setNumDecimalPlacespublic static final int FILTER_NORMALIZE
public static final int FILTER_STANDARDIZE
public static final int FILTER_NONE
public static final weka.core.Tag[] TAGS_FILTER
public java.lang.String globalInfo()
public weka.core.TechnicalInformation getTechnicalInformation()
getTechnicalInformation in interface weka.core.TechnicalInformationHandlerpublic weka.core.Capabilities getCapabilities()
getCapabilities in interface weka.classifiers.ClassifiergetCapabilities in interface weka.core.CapabilitiesHandlergetCapabilities in class weka.classifiers.AbstractClassifierpublic weka.core.Capabilities getMultiInstanceCapabilities()
getMultiInstanceCapabilities in interface weka.core.MultiInstanceCapabilitiesHandlerCapabilitiespublic void buildClassifier(weka.core.Instances data)
throws java.lang.Exception
buildClassifier in interface weka.classifiers.Classifierdata - the training data to be used for generating the boosted
classifier.java.lang.Exception - if the classifier could not be built successfullypublic void calculateDistance(weka.core.Instances train)
train - the multi-instance dataset (with relational attribute)public double minBagDistance(weka.core.Instance center,
weka.core.Instance bag)
center - the data point in instance spacebag - the bagpublic void findRadius(weka.core.Instances train)
train - the multi-instance datapublic double[] sortArray(double[] distance)
distance - the array need to be sortedpublic double[] distributionForInstance(weka.core.Instance newBag)
throws java.lang.Exception
distributionForInstance in interface weka.classifiers.ClassifierdistributionForInstance in class weka.classifiers.AbstractClassifiernewBag - the instance for which distribution is computedjava.lang.Exception - if the distribution can't be computed successfullypublic java.util.Enumeration<weka.core.Option> listOptions()
listOptions in interface weka.core.OptionHandlerlistOptions in class weka.classifiers.AbstractClassifierpublic java.lang.String[] getOptions()
getOptions in interface weka.core.OptionHandlergetOptions in class weka.classifiers.AbstractClassifierpublic void setOptions(java.lang.String[] options)
throws java.lang.Exception
-N <num> Whether to 0=normalize/1=standardize/2=neither. (default 0=normalize)
setOptions in interface weka.core.OptionHandlersetOptions in class weka.classifiers.AbstractClassifieroptions - the list of options as an array of stringsjava.lang.Exception - if an option is not supportedpublic java.lang.String filterTypeTipText()
public void setFilterType(weka.core.SelectedTag newType)
newType - the new filtering modepublic weka.core.SelectedTag getFilterType()
public java.lang.String getRevision()
getRevision in interface weka.core.RevisionHandlergetRevision in class weka.classifiers.AbstractClassifierpublic static void main(java.lang.String[] argv)
argv - should contain the command line arguments to the scheme (see
Evaluation)