Public Member Functions | Protected Member Functions | Protected Attributes

CDomainAdaptationSVM Class Reference

Detailed Description

class DomainAdaptationSVM

Definition at line 25 of file DomainAdaptationSVM.h.

Inheritance diagram for CDomainAdaptationSVM:
Inheritance graph

List of all members.

Public Member Functions

 CDomainAdaptationSVM ()
 CDomainAdaptationSVM (float64_t C, CKernel *k, CLabels *lab, CSVM *presvm, float64_t B)
virtual ~CDomainAdaptationSVM ()
void init (CSVM *presvm, float64_t B)
virtual EClassifierType get_classifier_type ()
virtual CLabelsapply (CFeatures *data)
virtual CSVMget_presvm ()
virtual float64_t get_B ()
virtual float64_t get_train_factor ()
virtual void set_train_factor (float64_t factor)
virtual const char * get_name () const

Protected Member Functions

virtual bool is_presvm_sane ()
virtual bool train_machine (CFeatures *data=NULL)

Protected Attributes

float64_t B
float64_t train_factor

Constructor & Destructor Documentation

default constructor

Definition at line 22 of file DomainAdaptationSVM.cpp.

CDomainAdaptationSVM ( float64_t  C,
CKernel k,
CLabels lab,
CSVM presvm,
float64_t  B 


C cost constant C
k kernel
lab labels
presvm trained SVM to regularize against
B trade-off constant B

Definition at line 26 of file DomainAdaptationSVM.cpp.

~CDomainAdaptationSVM (  )  [virtual]


Definition at line 32 of file DomainAdaptationSVM.cpp.

Member Function Documentation

CLabels * apply ( CFeatures data  )  [virtual]

classify objects

data (test)data to be classified
classified labels

Reimplemented from CKernelMachine.

Definition at line 148 of file DomainAdaptationSVM.cpp.

float64_t get_B (  )  [virtual]

getter for regularization parameter B

regularization parameter B

Definition at line 130 of file DomainAdaptationSVM.cpp.

virtual EClassifierType get_classifier_type (  )  [virtual]

get classifier type

classifier type

Reimplemented from CSVMLight.

Definition at line 56 of file DomainAdaptationSVM.h.

virtual const char* get_name (  )  const [virtual]
object name

Reimplemented from CSVMLight.

Definition at line 89 of file DomainAdaptationSVM.h.

CSVM * get_presvm (  )  [virtual]

returns SVM that is used as prior information


Definition at line 123 of file DomainAdaptationSVM.cpp.

float64_t get_train_factor (  )  [virtual]

getter for train_factor


Definition at line 136 of file DomainAdaptationSVM.cpp.

void init ( CSVM presvm,
float64_t  B 

init SVM

presvm trained SVM to regularize against
B trade-off constant B

Definition at line 39 of file DomainAdaptationSVM.cpp.

bool is_presvm_sane (  )  [protected, virtual]

check sanity of presvm

true if sane, throws SG_ERROR otherwise

Definition at line 55 of file DomainAdaptationSVM.cpp.

void set_train_factor ( float64_t  factor  )  [virtual]

setter for train_factor

Definition at line 142 of file DomainAdaptationSVM.cpp.

bool train_machine ( CFeatures data = NULL  )  [protected, virtual]

train SVM classifier

data training data (parameter can be avoided if distance or kernel-based classifiers are used and distance/kernels are initialized with train data)
whether training was successful

Reimplemented from CSVMLight.

Definition at line 81 of file DomainAdaptationSVM.cpp.

Member Data Documentation

float64_t B [protected]

regularization parameter B

Definition at line 118 of file DomainAdaptationSVM.h.

CSVM* presvm [protected]

SVM to regularize against

Definition at line 115 of file DomainAdaptationSVM.h.

float64_t train_factor [protected]

flag to switch off regularization in training

Definition at line 121 of file DomainAdaptationSVM.h.

The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

SHOGUN Machine Learning Toolbox - Documentation