class BayesClassifierMachine

BayesClassifierMachine is the machine used by the BayesClassifier trainer to perform a Bayes Classification using different distributions.

Inheritance:


Public Fields

[more]int n_trainers
the number of classes corresponds to the number of Trainer
[more]int n_outputs
the number of outputs in this machine
[more]EMTrainer** trainers
the actual trainers (EMTrainer since we are training distributions)
[more]real* log_priors
the log_prior probabilities of each class.
[more]Sequence* log_probabilities
it contains the log posterior probability plus the log prior of the class
[more]bool allocated_log_priors
used to know if log_priors where given or allocated
[more]ClassFormat* class_format
the class format of the output
[more]MeasurerList** trainers_measurers
the measurers for each individual trainer

Public Methods

[more] BayesClassifierMachine( EMTrainer**, int n_trainers_, MeasurerList** trainers_measurers_, ClassFormat* class_format_, real* log_priors_=NULL)
creates a machine for BayesClassifier trainers, given a vector of trainers (one per class), an associate measurer for each trainer, a class_format that explains how the classes are coded, and an eventual vector (of size n_trainers_) containing the log of the class priors
[more]virtual void forward(Sequence* inputs)
definition of virtual functions of Machine


Inherited from Machine:

Public Fields

oSequence* outputs

Public Methods

ovirtual void reset()
ovirtual void setDataSet(DataSet* dataset_)


Inherited from Object:

Public Fields

oAllocator* allocator

Public Methods

ovoid addOption(const char* name, int size, void* ptr, const char* help="")
ovoid addIOption(const char* name, int* ptr, int init_value, const char* help="")
ovoid addROption(const char* name, real* ptr, real init_value, const char* help="")
ovoid addBOption(const char* name, bool* ptr, bool init_value, const char* help="")
ovoid addOOption(const char* name, Object** ptr, Object* init_value, const char* help="")
ovoid setOption(const char* name, void* ptr)
ovoid setIOption(const char* name, int option)
ovoid setROption(const char* name, real option)
ovoid setBOption(const char* name, bool option)
ovoid setOOption(const char* name, Object* option)
ovirtual void loadXFile(XFile* file)
ovirtual void saveXFile(XFile* file)
ovoid load(const char* filename)
ovoid save(const char* filename)
ovoid* operator new(size_t size, Allocator* allocator_=NULL)
ovoid* operator new(size_t size, Allocator* allocator_, void* ptr_)
ovoid operator delete(void* ptr)


Documentation

BayesClassifierMachine is the machine used by the BayesClassifier trainer to perform a Bayes Classification using different distributions. The output corresponds to the class that is the most probable (using prior AND posterior information).

oint n_trainers
the number of classes corresponds to the number of Trainer

oint n_outputs
the number of outputs in this machine

oEMTrainer** trainers
the actual trainers (EMTrainer since we are training distributions)

oreal* log_priors
the log_prior probabilities of each class. default: log_priors are taken as the log of the proportions in the training set.

oSequence* log_probabilities
it contains the log posterior probability plus the log prior of the class

obool allocated_log_priors
used to know if log_priors where given or allocated

oClassFormat* class_format
the class format of the output

oMeasurerList** trainers_measurers
the measurers for each individual trainer

o BayesClassifierMachine( EMTrainer**, int n_trainers_, MeasurerList** trainers_measurers_, ClassFormat* class_format_, real* log_priors_=NULL)
creates a machine for BayesClassifier trainers, given a vector of trainers (one per class), an associate measurer for each trainer, a class_format that explains how the classes are coded, and an eventual vector (of size n_trainers_) containing the log of the class priors

ovirtual void forward(Sequence* inputs)
definition of virtual functions of Machine


This class has no child classes.
Author:
Samy Bengio (bengio@idiap.ch) Bison Ravi (francois.belisle@idiap.ch)

Alphabetic index HTML hierarchy of classes or Java



This page was generated with the help of DOC++.