ECOCPAK v0.9
|
ecocpak namespace More...
Data Structures | |
class | ClassData |
class | Classifier |
class | Threshold |
class | op_kmeans |
class | Classifier_ncc |
class | Classifier_flda |
class | Classifier_svm |
class | Classifier_weak |
class | Classifier_adaBoost |
class | Classifier_ls |
class | Classifier_custom |
Typedefs | |
typedef struct svm_node ** | sparse_mat |
Enumerations | |
enum | { ONE_VS_ONE, ONE_VS_ALL, DECOC, SUBDECOC, DENSE_RANDOM, SPARSE_RANDOM, ECOC_ONE, FOREST_ECOC, CUSTOM_CODING } |
enum | { HAMMING, EUCLIDEAN, LAPLACIAN, HAMMING_ATTENUATED, EUCLIDEAN_ATTENUATED, LINEAR_LOSS_WEIGHTED_DECODING, EXPONENTIAL_LOSS_WEIGHTED_DECODING, LINEAR_LOSS_BASED_DECODING, EXPONENTIAL_LOSS_BASED_DECODING, BETA_DENSITY_DECODING, PROBABILISTIC_BASED_DECODING, INVERSE_HAMMING_DECODING, CUSTOM_DECODING } |
enum | { FQMI, FLDR, CUSTOM_CRITERION } |
enum | { PAIR, ALL_CLASSES } |
enum | { NCC, FLDA, SVM, ADABOOST, LEAST_SQUARES, CUSTOM_CLASSIFIER } |
enumeration for classifier's type More... | |
enum | { NCC, FLDA, SVM, ADABOOST, LEAST_SQUARES, CUSTOM_CLASSIFIER } |
enumeration for classifier's type More... | |
enum | { NCC, FLDA, SVM, ADABOOST, LEAST_SQUARES, CUSTOM_CLASSIFIER } |
enumeration for classifier's type More... | |
enum | { NCC, FLDA, SVM, ADABOOST, LEAST_SQUARES, CUSTOM_CLASSIFIER } |
enumeration for classifier's type More... | |
enum | { NCC, FLDA, SVM, ADABOOST, LEAST_SQUARES, CUSTOM_CLASSIFIER } |
enumeration for classifier's type More... | |
enum | { NCC, FLDA, SVM, ADABOOST, LEAST_SQUARES, CUSTOM_CLASSIFIER } |
enumeration for classifier's type More... | |
enum | { NCC, FLDA, SVM, ADABOOST, LEAST_SQUARES, CUSTOM_CLASSIFIER } |
enumeration for classifier's type More... | |
Functions | |
bool | contains (const ucolvec &A, const u32 n, const u32 i) |
ucolvec | complement (const ucolvec &A, const u32 sizeU) |
vector< ClassData > | create_class_vector (const mat &samples, const icolvec &labels) |
mat | create_samples_matrix (const vector< ClassData > &v) |
void | create_samples_matrix (const vector< ClassData > &v, mat &samples, icolvec &labels) |
void | create_samples_matrix (const ClassData &first_class, const ClassData &second_class, mat &samples, icolvec &labels) |
void | create_samples_matrix (const vector< ClassData > &v, mat &samples, icolvec &labels, ucolvec &n_per_class) |
ClassData | merge_classes_vector (const vector< ClassData > &v) |
ClassData | merge_selected_classes (const vector< ClassData > &v, const ucolvec &s) |
vector< ClassData > | split_class (const ClassData &c, const ucolvec &indices, const ucolvec &samples_per_cluster, const int are_valid) |
ucolvec | complement_sffs (const ucolvec &A, const u32 curSubsetSize) |
u32 | linear_loss_weighted_decoding (const vector< Classifier * > &classifiers_vector, const vector< ClassData > &classes_vector, const imat &ecoc_matrix, const mat &test_set_samples, const uvec &test_set_labels, uvec &results, umat &confussion) |
u32 | exponential_loss_weighted_decoding (const vector< Classifier * > &classifiers_vector, const vector< ClassData > &classes_vector, const imat &ecoc_matrix, const mat &test_set_samples, const uvec &test_set_labels, uvec &results, umat &confussion) |
double | custom_metric (rowvec test_code, rowvec class_code) |
u32 | custom_decoding (const vector< Classifier * > &classifiers_vector, const vector< ClassData > &classes_vector, const imat &coding_matrix, const mat &test_samples, const ucolvec &test_set_labels, uvec &predictions, umat &confussion) |
void | sigmoid_training (double &A, double &B, const vec f, const u32 n_pos, const u32 n_neg) |
u32 | probabilistic_decoding (const vector< Classifier * > &classifiers_vector, const vector< ClassData > &classes_vector, const imat &coding_matrix, const mat &test_samples, const ucolvec &test_set_labels, uvec &predictions, umat &confussion) |
irowvec | sign (const rowvec &A) |
irowvec | sign (const rowvec &A, const irowvec &B) |
double | beta_density_metric (const irowvec &test_code, const irowvec &class_code, const double u=0.333333, const u32 n_points=201) |
u32 | decode_codeword (const rowvec &codeword, const imat &coding_matrix, const int decoding_strategy) |
void | decode (const mat &Xt, const uvec <, const imat &coding_matrix, const vector< Classifier * > &classifiers_vector, const vector< ClassData > &classes_vector, const int decoding_option, uvec &predictions, u32 &n_missed, double &error, umat &confussion) |
Decoding procedure. | |
sparse_mat | dense_to_sparse (const mat &X) |
void | delete_sparse_matrix (sparse_mat A, const u32 n_rows) |
void | delete_sparse_matrix (sparse_mat A, const u32 n_rows, const struct svm_model *model) |
svm_model | modelcpy (svm_model *m) |
mat | sparse_to_dense (struct svm_node **const X, const u32 n_rows, const u32 n_cols) |
template<typename eT1 , typename eT2 > | |
Col< u32 > | process_labels (const Mat< eT1 > &labels, Col< eT2 > &n_samples_each_class, u32 &n_classes) |
template<typename eT1 > | |
Col< u32 > | process_labels (const Mat< eT1 > &labels, u32 &n_classes) |
template<typename eT1 > | |
Col< u32 > | process_labels (const Mat< eT1 > &labels) |
template<typename T1 > | |
void | kmeans (Col< u32 > &indices_out, Col< u32 > &ranks_out, Mat< typename T1::elem_type > ¢roids_out, const Base< typename T1::elem_type, T1 > &X, const u32 k, const typename T1::pod_type lr=0.01) |
mat | subClasses (ucolvec &inds, ucolvec &ranks, const mat &samples) |
Classifier * | construct_classifier (const mat &A, const mat &B, const int classifiers_type) |
double | compute_sigma (const vector< ClassData > &classes_vector) |
template<typename T1 , typename T2 > | |
T1::elem_type | fqmi (const Base< typename T1::elem_type, T1 > &X, const Base< typename T2::elem_type, T2 > &Y, const typename T1::elem_type sigma) |
template<typename T1 > | |
T1::elem_type | fldr (const Base< typename T1::elem_type, T1 > &X, const Base< typename T1::elem_type, T1 > &Y) |
double | criterion_custom (const vector< ClassData > &classes_vector, const ucolvec &indexPtr, const u32 curSubsetSize) |
double | criterion_fqmi (const vector< ClassData > &classes_vector, const ucolvec &indexPtr, const u32 curSubsetSize, const double sigma) |
double | criterion_fldr (const vector< ClassData > &classes_vector, const ucolvec &indexPtr, const u32 curSubsetSize) |
double | criterion (const vector< ClassData > &class_vector, const ucolvec &indexPtr, const u32 curSubSetSize, const u32 criterion_option, const double sigma) |
ucolvec | sffs (const vector< ClassData > &classes_vector, const u32 crit) |
Classifier * | create_classifier (const ClassData &A, const ClassData &B, const u32 classifiers_option, double &training_error) |
Classifier * | create_classifier (const ClassData &A, const ClassData &B, const u32 classifiers_option) |
Classifier * | create_classifier (const mat &A, const mat &B, const u32 classifiers_option) |
void | coding_matrix_update (imat &coding_matrix, const vector< ClassData > &class_vector, vector< ClassData > &split_classes_vector, u32 indx) |
void | update_class_tracker (vector< colvec > &class_tracker, const vector< ClassData > &class_vector, const u32 indx, vector< ClassData > &split_classes_vector, vector< ClassData > &classes_created_vector) |
bool | save_classifier (Classifier *c, const vector< ClassData > &class_vector, const ucolvec &best_set_indices, const ucolvec &complement_set_indices, vector< Classifier * > &classifiers_vector) |
bool | save_classifier (Classifier *c, const vector< ClassData > &class_vector, vector< Classifier * > &classifiers_vector) |
bool | contain_same_classes (const ucolvec &A, const vector< ClassData > &B) |
void | direct_subclass_encoding (const vector< ClassData > &class_vector, const Threshold &thres, const int criterion_option, const int classifiers_option, imat &coding_matrix, vector< Classifier * > &classifiers_vector, vector< ClassData > &classes_created_vector, vector< colvec > &class_tracker, vector< ucolvec > &problem_tracker) |
void | subclass_encoding (const mat &samples, const icolvec &labels, const Threshold &thres, const int criterion_option, const int classifiers_option, imat &coding_matrix, vector< Classifier * > &classifiers_vector, vector< ClassData > &classes_created_vector) |
void | direct_decoc_encoding (const vector< ClassData > &class_vector, const int criterion_option, const int classifiers_option, vector< Classifier * > &classifiers_vector) |
void | decoc_coding (const vector< ClassData > &class_vector, const int criterion_option, const int classifiers_option, imat &coding_matrix, vector< Classifier * > &classifiers_vector) |
u32 | one_vs_one (const mat &training_samples, const icolvec &training_labels, const mat &testing_samples, const icolvec &testing_labels, const int decoding_strategy, const int classifiers_type, const bool verbose, ofstream &verbose_output, double &execution_time) |
u32 | one_vs_all (const mat &training_samples, const icolvec &training_labels, const mat &testing_samples, const icolvec &testing_labels, const int decoding_strategy, const int classifiers_type, const bool verbose, ofstream &verbose_output, double &execution_time) |
u32 | decoc (const mat &training_samples, const icolvec &training_labels, const mat &testing_samples, const icolvec &testing_labels, const int decoding_strategy, const int classifiers_option, const int criterion_option, const bool verbose, ofstream &verbose_output, double &execution_time) |
Discriminant Error Correcting Output Codes (DECOC) training and testing procedure. | |
u32 | subdecoc (const mat &training_samples, const icolvec &training_labels, const mat &testing_samples, const icolvec &testing_labels, const Threshold &thres, const int decoding_strategy, const int classifiers_type, const int criterion_option, const bool verbose, imat &coding_matrix, ofstream &verbose_output, double &execution_time) |
Discriminant Error Correcting Output Codes with subclasses (SUBDECOC) training and testing procedure . | |
imat | create_dense_matrix_from_rand (const double *random_matrix, const u32 n_rows, const u32 n_cols) |
bool | identical_columns_dense (const imat &coding_matrix) |
imat | create_dense_random_matrix (const u32 n_classes, const u32 n_classifiers, const u32 n_matrices) |
u32 | dense_random_ecoc (const mat &training_samples, const icolvec &training_labels, const mat &testing_samples, const icolvec &testing_labels, const int decoding_strategy, const int classifiers_type, const u32 n_matrices, const u32 n_desired_classifiers, const bool verbose, ofstream &verbose_output, double &execution_time) |
imat | create_sparse_matrix_from_rand (const double *random_matrix, const u32 n_rows, const u32 n_cols) |
bool | identical_columns_sparse (const imat &coding_matrix) |
imat | create_sparse_random_matrix (const u32 n_classes, const u32 n_classifiers, const u32 n_matrices) |
u32 | sparse_random_ecoc (const mat &training_samples, const icolvec &training_labels, const mat &testing_samples, const icolvec &testing_labels, const int decoding_strategy, const int classifiers_type, const u32 n_matrices, const u32 n_desired_classifiers, const bool verbose, ofstream &verbose_output, double &execution_time) |
void | one_vs_all_ecocone (vector< ClassData > &classes_vector, const int classifiers_type, imat &coding_matrix, vector< Classifier * > &classifiers_vector) |
void | one_vs_one_ecocone (vector< ClassData > &classes_vector, const int classifiers_type, imat &coding_matrix, vector< Classifier * > &classifiers_vector) |
void | decoc_ecocone (vector< ClassData > &classes_vector, const int classifiers_type, const int criterion_option, imat &coding_matrix, vector< Classifier * > &classifiers_vector) |
void | subdecoc_ecocone (vector< ClassData > &classes_vector, const int classifiers_type, const int criterion_option, const Threshold &thres, imat &coding_matrix, vector< Classifier * > &classifiers_vector) |
void | dense_random_ecocone (vector< ClassData > &classes_vector, const int classifiers_type, const u32 n_matrices, const u32 n_desired_classifiers, imat &coding_matrix, vector< Classifier * > &classifiers_vector) |
void | sparse_random_ecocone (vector< ClassData > &classes_vector, const int classifiers_type, const u32 n_matrices, const u32 n_desired_classifiers, imat &coding_matrix, vector< Classifier * > &classifiers_vector) |
u32 | ecoc_one (const mat &training_samples, const icolvec &training_labels, const mat &testing_samples, const icolvec &testing_labels, const Threshold &thres, const int decoding_strategy, const int classifiers_type, const int criterion_option, const u32 n_matrices, const u32 n_desired_classifiers, const double validation, const int init_coding_strategy, const int ecocone_mode, const u32 max_iter, const double epsilon, const double wv, const bool verbose, ofstream &verbose_output, double &elapsed_time) |
ECOC One training and testing procedure. | |
imat | permvec (const ivec &A) |
Creates permutation vectors of input binary vector. | |
void | append_tree (const vector< ClassData > &classes_vector, const ivec &root, const int criterion_option, const int classifiers_type, imat &M, vector< Classifier * > &classifiers_vector) |
Appends tree structure to coding matrix M. | |
u32 | forest_ecoc (const mat &training_samples, const icolvec &training_labels, const mat &testing_samples, const icolvec &testing_labels, const int decoding_strategy, const int classifiers_type, const int criterion_option, const u32 n_forests, const bool verbose, ofstream &verbose_output, double &elapsed_time) |
Forest ECOC training and testing procedure. | |
void | group_classes (const ivec &labels, int *nr_class_ret, int **label_ret, int **start_ret, int **count_ret, int *perm) |
double | cross_validation (const mat &samples, const icolvec &labels, const imat &codmat, const Threshold &thres, const u32 n_folds, const u32 n_classes, const u32 criterion_option, const u32 classifier_option, const int coding_strategy, const int decoding_strategy, const u32 n_matrices, const u32 n_desired_classifers, const double validation, const int init_coding_strategy, const int ecocone_mode, const u32 max_iter, const double epsilon, const double wvalidation, const bool verbose, double &mean_rows, double &mean_cols, double &elapsed_time, ofstream &output) |
double | cvonesvsone (const mat &samples, const icolvec &labels, const u32 n_folds, const u32 n_classes, const u32 classifier_option, const int decoding_strategy, const bool verbose, double &elapsed_time, ofstream &output) |
double | cvonesvsall (const mat &samples, const icolvec &labels, const u32 n_folds, const u32 n_classes, const u32 classifier_option, const int decoding_strategy, const bool verbose, double &elapsed_time, ofstream &output) |
double | cvdecoc (const mat &samples, const icolvec &labels, const u32 n_folds, const u32 n_classes, const u32 classifier_option, const int decoding_strategy, const u32 criterion_option, const bool verbose, double &elapsed_time, ofstream &output) |
double | cvsubdecoc (const mat &samples, const icolvec &labels, const u32 n_folds, const u32 n_classes, const u32 classifier_option, const int decoding_strategy, const u32 criterion_option, const Threshold &thres, const bool verbose, double &mr, double &mc, double &elapsed_time, ofstream &output) |
double | cvsparserand (const mat &samples, const icolvec &labels, const u32 n_folds, const u32 n_classes, const u32 classifier_option, const int decoding_strategy, const u32 n_matrices, const u32 n_desired_classifers, const bool verbose, double &elapsed_time, ofstream &output) |
double | cvdenserand (const mat &samples, const icolvec &labels, const u32 n_folds, const u32 n_classes, const u32 classifier_option, const int decoding_strategy, const u32 n_matrices, const u32 n_desired_classifers, const bool verbose, double &elapsed_time, ofstream &output) |
double | cvecocone (const mat &samples, const icolvec &labels, const u32 n_folds, const u32 n_classes, const u32 classifier_option, const int decoding_strategy, const double validation, const int init_coding_strategy, const int ecocone_mode, const u32 max_iter, const double epsilon, const double wvalidation, const bool verbose, double &elapsed_time, ofstream &output) |
double | cvforest (const mat &samples, const icolvec &labels, const u32 n_folds, const u32 n_classes, const u32 classifier_option, const int decoding_strategy, const u32 n_trees, const bool verbose, double &elapsed_time, ofstream &output) |
double | cvcustom (const mat &samples, const icolvec &labels, const u32 n_folds, const u32 n_classes, const u32 classifier_option, const int decoding_strategy, const imat &codmat, const bool verbose, double &elapsed_time, ofstream &output) |
void | uci_glass (mat &samples, ucolvec &labels) |
mat | uci_glass () |
void | uci_iris (mat &samples, ucolvec &labels) |
mat | uci_iris () |
void | load_dataset_from_file (const char *filename, mat &samples, icolvec &labels, u32 &n_classes) |
void | load_dataset_from_file (const char *filename, mat &samples, icolvec &labels) |
ecocpak namespace
anonymous enum |
anonymous enum |