|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.rapidminer.tools.AbstractObservable<Operator>
com.rapidminer.operator.Operator
com.rapidminer.operator.learner.AbstractLearner
com.rapidminer.operator.learner.functions.kernel.AbstractKernelBasedLearner
com.rapidminer.operator.learner.functions.kernel.LibSVMLearner
public class LibSVMLearner
Applies the libsvm learner by Chih-Chung Chang and Chih-Jen
Lin. The SVM is a powerful method for both classification and regression. This operator supports the SVM types
C-SVC and nu-SVC for classification tasks and epsilon-SVR and
nu-SVR for regression tasks. Supports also multiclass learning and probability estimation based on Platt
scaling for proper confidence values after applying the learned model on a classification data set.
| Field Summary | |
|---|---|
static java.lang.String[] |
KERNEL_TYPES
The different kernel types implemented by the LibSVM package. |
static java.lang.String |
PARAMETER_C
The parameter name for "The cost parameter C for c_svc, epsilon_svr, and nu_svr. |
static java.lang.String |
PARAMETER_CACHE_SIZE
The parameter name for "Cache size in Megabyte. |
static java.lang.String |
PARAMETER_CALCULATE_CONFIDENCES
The parameter name for "Indicates if proper confidence values should be calculated. |
static java.lang.String |
PARAMETER_CLASS_WEIGHTS
The parameter name for "The weights w for all classes (first column: class name, second column: weight), i.e. set the parameters C of each class w * C (empty: using 1 for all classes where the weight was not defined). |
static java.lang.String |
PARAMETER_COEF0
The parameter name for "The parameter coef0 for polynomial and sigmoid kernel functions. |
static java.lang.String |
PARAMETER_CONFIDENCE_FOR_MULTICLASS
The parameter name for "Indicates if proper confidence values should be calculated. |
static java.lang.String |
PARAMETER_DEGREE
The parameter name for "The degree for a polynomial kernel function. |
static java.lang.String |
PARAMETER_EPSILON
The parameter name for "Tolerance of termination criterion. |
static java.lang.String |
PARAMETER_GAMMA
The parameter name for "The parameter gamma for polynomial, rbf, and sigmoid kernel functions (0 means 1/#attributes). |
static java.lang.String |
PARAMETER_KERNEL_TYPE
The parameter name for "The type of the kernel functions" |
static java.lang.String |
PARAMETER_NU
The parameter name for "The parameter nu for nu_svc, one_class, and nu_svr. |
static java.lang.String |
PARAMETER_ONECLASS_CLASSIFICATION
The parameter name for "Indicates if the traditional libsvm one-class classification behavior should be used. |
static java.lang.String |
PARAMETER_P
The parameter name for "Tolerance of loss function of epsilon-SVR. |
static java.lang.String |
PARAMETER_SHRINKING
The parameter name for "Whether to use the shrinking heuristics. |
static java.lang.String |
PARAMETER_SVM_TYPE
The parameter name for "SVM for classification (C-SVC, nu-SVC), regression (epsilon-SVR, nu-SVR) and distribution estimation (one-class)" |
static int |
SVM_TYPE_C_SVC
|
static int |
SVM_TYPE_EPS_SVR
|
static int |
SVM_TYPE_NU_SVC
|
static int |
SVM_TYPE_NU_SVR
|
static int |
SVM_TYPE_ONE_CLASS
|
static java.lang.String[] |
SVM_TYPES
The different SVM types implemented by the LibSVM package. |
| Fields inherited from interface com.rapidminer.operator.learner.CapabilityProvider |
|---|
PROPERTY_RAPIDMINER_GENERAL_CAPABILITIES_WARN |
| Constructor Summary | |
|---|---|
LibSVMLearner(OperatorDescription description)
|
|
| Method Summary | |
|---|---|
java.util.List<ParameterType> |
getParameterTypes()
Returns a list of ParameterTypes describing the parameters of this operator. |
ResourceConsumptionEstimator |
getResourceConsumptionEstimator()
Subclasses can override this method if they are able to estimate the consumed resources (CPU time and memory), based on their input. |
Model |
learn(ExampleSet exampleSet)
Learns a new SVM model with the LibSVM package. |
protected static libsvm.svm_node[] |
makeNodes(Example e,
FastExample2SparseTransform ripper)
Creates a data node row for the LibSVM (sparse format, i.e. each node keeps the index and the value if not default). |
boolean |
supportsCapability(OperatorCapability lc)
Checks for Learner capabilities. |
| Methods inherited from class com.rapidminer.operator.learner.functions.kernel.AbstractKernelBasedLearner |
|---|
getModelClass |
| Methods inherited from class com.rapidminer.operator.learner.AbstractLearner |
|---|
canCalculateWeights, canEstimatePerformance, doWork, doWork, getEstimatedPerformance, getExampleSetInputPort, getOptimizationPerformance, getWeightCalculationError, getWeights, getWeights, onlyWarnForNonSufficientCapabilities, shouldAutoConnect, shouldCalculateWeights, shouldDeliverOptimizationPerformance, shouldEstimatePerformance |
| Methods inherited from class com.rapidminer.tools.AbstractObservable |
|---|
addObserver, addObserverAsFirst, fireUpdate, removeObserver |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface com.rapidminer.operator.learner.Learner |
|---|
getName |
| Field Detail |
|---|
public static final java.lang.String PARAMETER_SVM_TYPE
public static final java.lang.String PARAMETER_KERNEL_TYPE
public static final java.lang.String PARAMETER_DEGREE
public static final java.lang.String PARAMETER_GAMMA
public static final java.lang.String PARAMETER_COEF0
public static final java.lang.String PARAMETER_C
public static final java.lang.String PARAMETER_NU
public static final java.lang.String PARAMETER_CACHE_SIZE
public static final java.lang.String PARAMETER_EPSILON
public static final java.lang.String PARAMETER_P
public static final java.lang.String PARAMETER_CLASS_WEIGHTS
public static final java.lang.String PARAMETER_SHRINKING
public static final java.lang.String PARAMETER_CALCULATE_CONFIDENCES
public static final java.lang.String PARAMETER_ONECLASS_CLASSIFICATION
public static final java.lang.String PARAMETER_CONFIDENCE_FOR_MULTICLASS
public static final java.lang.String[] SVM_TYPES
public static final int SVM_TYPE_C_SVC
public static final int SVM_TYPE_NU_SVC
public static final int SVM_TYPE_ONE_CLASS
public static final int SVM_TYPE_EPS_SVR
public static final int SVM_TYPE_NU_SVR
public static final java.lang.String[] KERNEL_TYPES
| Constructor Detail |
|---|
public LibSVMLearner(OperatorDescription description)
| Method Detail |
|---|
public boolean supportsCapability(OperatorCapability lc)
CapabilityProvider
protected static libsvm.svm_node[] makeNodes(Example e,
FastExample2SparseTransform ripper)
public Model learn(ExampleSet exampleSet)
throws OperatorException
OperatorExceptionpublic java.util.List<ParameterType> getParameterTypes()
Operator
getParameterTypes in interface ParameterHandlergetParameterTypes in class Operatorpublic ResourceConsumptionEstimator getResourceConsumptionEstimator()
Operator
getResourceConsumptionEstimator in interface ResourceConsumergetResourceConsumptionEstimator in class Operator
|
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||