Class MultiClassRbfTrainer
java.lang.Object
org.tweetyproject.machinelearning.svm.MultiClassRbfTrainer
- All Implemented Interfaces:
- Trainer<DefaultObservation,- DoubleCategory> 
public class MultiClassRbfTrainer
extends Object
implements Trainer<DefaultObservation,DoubleCategory> 
Trains a standard multi-class RBF support vector machine.
- Author:
- Matthias Thimm
- 
Field SummaryFieldsModifier and TypeFieldDescriptionstatic final TrainingParameterThe c parameter for learningstatic final TrainingParameterThe gamma parameter for learning
- 
Constructor SummaryConstructorsConstructorDescriptionInitializes the trainer with the default parameters.MultiClassRbfTrainer(double c, double gamma) Initializes the trainer with the given parameters.
- 
Method SummaryModifier and TypeMethodDescriptionReturns the set of parameters for this trainer.booleansetParameterSet(ParameterSet params) Sets the parameters for this trainer (calling this method must ensure that the next timetrain(TrainingSet<S,T> trainingSet)is used it uses these parameters.toString()train(TrainingSet<DefaultObservation, DoubleCategory> trainingSet) Trains a classifier on the given training set.train(TrainingSet<DefaultObservation, DoubleCategory> trainingSet, ParameterSet params) Trains a classifier on the given training set with the given parameters
- 
Field Details- 
C_PARAMETERThe c parameter for learning
- 
GAMMA_PARAMETERThe gamma parameter for learning
 
- 
- 
Constructor Details- 
MultiClassRbfTrainerpublic MultiClassRbfTrainer()Initializes the trainer with the default parameters.
- 
MultiClassRbfTrainerpublic MultiClassRbfTrainer(double c, double gamma) Initializes the trainer with the given parameters.- Parameters:
- c- the c parameter for learning
- gamma- the gamma parameter for learning
 
 
- 
- 
Method Details- 
trainDescription copied from interface:TrainerTrains a classifier on the given training set.- Specified by:
- trainin interface- Trainer<DefaultObservation,- DoubleCategory> 
- Parameters:
- trainingSet- some training set.
- Returns:
- a classifier
 
- 
trainpublic SupportVectorMachine train(TrainingSet<DefaultObservation, DoubleCategory> trainingSet, ParameterSet params) Description copied from interface:TrainerTrains a classifier on the given training set with the given parameters- Specified by:
- trainin interface- Trainer<DefaultObservation,- DoubleCategory> 
- Parameters:
- trainingSet- some training set.
- params- parameters for the training.
- Returns:
- a classifier
 
- 
getParameterSetDescription copied from interface:TrainerReturns the set of parameters for this trainer.- Specified by:
- getParameterSetin interface- Trainer<DefaultObservation,- DoubleCategory> 
- Returns:
- the set of parameters for this trainer.
 
- 
setParameterSetDescription copied from interface:TrainerSets the parameters for this trainer (calling this method must ensure that the next timetrain(TrainingSet<S,T> trainingSet)is used it uses these parameters.- Specified by:
- setParameterSetin interface- Trainer<DefaultObservation,- DoubleCategory> 
- Parameters:
- params- a parameter set.
- Returns:
- true if the operation was successful.
 
- 
toString
 
-