SHOGUN  v1.1.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
List of all members | Public Member Functions
CMulticlassAccuracy Class Reference

Detailed Description

The class MulticlassAccuracy used to compute accuracy of multiclass classification.

Formally, for multiclass labels $L,R, |L|=|R|$ multiclass accuracy is estimated as

\[ \frac{\sum_{i=1}^{|L|} [L_i=R_i]}{|L|} \]

Definition at line 34 of file MulticlassAccuracy.h.

Inheritance diagram for CMulticlassAccuracy:
Inheritance graph
[legend]

Public Member Functions

 CMulticlassAccuracy ()
virtual ~CMulticlassAccuracy ()
virtual float64_t evaluate (CLabels *predicted, CLabels *ground_truth)
EEvaluationDirection get_evaluation_direction ()
virtual const char * get_name () const
- Public Member Functions inherited from CEvaluation
 CEvaluation ()
virtual ~CEvaluation ()
- Public Member Functions inherited from CSGObject
 CSGObject ()
 CSGObject (const CSGObject &orig)
virtual ~CSGObject ()
virtual bool is_generic (EPrimitiveType *generic) const
template<class T >
void set_generic ()
void unset_generic ()
virtual void print_serializable (const char *prefix="")
virtual bool save_serializable (CSerializableFile *file, const char *prefix="")
virtual bool load_serializable (CSerializableFile *file, const char *prefix="")
void set_global_io (SGIO *io)
SGIOget_global_io ()
void set_global_parallel (Parallel *parallel)
Parallelget_global_parallel ()
void set_global_version (Version *version)
Versionget_global_version ()
SGVector< char * > get_modelsel_names ()
char * get_modsel_param_descr (const char *param_name)
index_t get_modsel_param_index (const char *param_name)

Additional Inherited Members

- Public Attributes inherited from CSGObject
SGIOio
Parallelparallel
Versionversion
Parameterm_parameters
Parameterm_model_selection_parameters
- Protected Member Functions inherited from CSGObject
virtual void load_serializable_pre () throw (ShogunException)
virtual void load_serializable_post () throw (ShogunException)
virtual void save_serializable_pre () throw (ShogunException)
virtual void save_serializable_post () throw (ShogunException)

Constructor & Destructor Documentation

constructor

Definition at line 38 of file MulticlassAccuracy.h.

virtual ~CMulticlassAccuracy ( )
virtual

destructor

Definition at line 41 of file MulticlassAccuracy.h.

Member Function Documentation

float64_t evaluate ( CLabels predicted,
CLabels ground_truth 
)
virtual

evaluate accuracy

Parameters
predictedlabels for evaluating
ground_truthlabels assumed to be correct
Returns
accuracy

Implements CEvaluation.

Definition at line 17 of file MulticlassAccuracy.cpp.

EEvaluationDirection get_evaluation_direction ( )
virtual
Returns
whether criterium has to be maximized or minimized

Implements CEvaluation.

Definition at line 50 of file MulticlassAccuracy.h.

virtual const char* get_name ( ) const
virtual

get name

Implements CSGObject.

Definition at line 56 of file MulticlassAccuracy.h.


The documentation for this class was generated from the following files:

SHOGUN Machine Learning Toolbox - Documentation