33#ifndef ROOT_TMVA_MethodSVM
34#define ROOT_TMVA_MethodSVM
50#ifndef ROOT_TMVA_TVectorD
59 class SVKernelFunction;
66 const TString& theOption =
"" );
77 std::vector<TMVA::SVKernelFunction::EKernelType>
MakeKernelList(std::string multiKernels,
TString kernel);
115 void GetMGamma(
const std::vector<float> & gammas);
#define ClassDef(name, id)
A ROOT file is a suite of consecutive data records (TKey instances) with a well defined format.
Class that contains all the data information.
Virtual base Class for all MVA method.
virtual void ReadWeightsFromStream(std::istream &)=0
SMO Platt's SVM classifier with Keerthi & Shavade improvements.
Double_t getLoss(TString lossFunction)
getLoss Calculates loss for testing dataset.
virtual void SetTuneParameters(std::map< TString, Double_t > tuneParameters)
Set the tuning parameters according to the argument.
void SetKappa(Double_t k)
Double_t GetMvaValue(Double_t *err=0, Double_t *errUpper=0)
returns MVA value for given event
void DeclareOptions()
declare options available for this method
std::vector< TString > fVarNames
void WriteWeightsToStream(TFile &fout) const
TODO write IT write training sample (TTree) to file.
void SetMGamma(std::string &mg)
Takes as input a string of values for multigaussian gammas and splits it, filling the gamma vector re...
virtual Bool_t HasAnalysisType(Types::EAnalysisType type, UInt_t numberClasses, UInt_t numberTargets)
SVM can handle classification with 2 classes and regression with one regression-target.
SVKernelFunction * fSVKernelFunction
void ReadWeightsFromStream(std::istream &istr)
virtual std::map< TString, Double_t > OptimizeTuningParameters(TString fomType="ROCIntegral", TString fitType="Minuit")
Optimize Tuning Parameters This is used to optimise the kernel function parameters and cost.
Float_t fDoubleSigmaSquared
void GetMGamma(const std::vector< float > &gammas)
Produces GammaList string for multigaussian kernel to be written to xml file.
void AddWeightsXMLTo(void *parent) const
write configuration to xml file
void SetTheta(Double_t t)
void SetGamma(Double_t g)
std::vector< TMVA::SVEvent * > * fSupportVectors
void SetOrder(Double_t o)
std::map< TString, std::vector< Double_t > > GetTuningOptions()
GetTuningOptions Function to allow for ranges and number of steps (for scan) when optimising kernel f...
void ReadWeightsFromXML(void *wghtnode)
std::vector< Float_t > fmGamma
void ProcessOptions()
option post processing (if necessary)
void Train(void)
Train SVM.
const Ranking * CreateRanking()
std::vector< TMVA::SVEvent * > * fInputData
void Init(void)
default initialisation
void MakeClassSpecific(std::ostream &, const TString &) const
write specific classifier response
virtual ~MethodSVM(void)
destructor
std::string fMultiKernels
const std::vector< Float_t > & GetRegressionValues()
void GetHelpMessage() const
get help message text
std::vector< TMVA::SVKernelFunction::EKernelType > MakeKernelList(std::string multiKernels, TString kernel)
MakeKernelList Function providing string manipulation for product or sum of kernels functions to take...
void DeclareCompatibilityOptions()
options that are used ONLY for the READER to ensure backward compatibility
Ranking for variables in method (implementation)
Kernel for Support Vector Machine.
Working class for Support Vector Machine.
create variable transformations