diff --git a/dlib/svm/svm_c_ekm_trainer.h b/dlib/svm/svm_c_ekm_trainer.h index bd8c4fc5f..01fcb225d 100644 --- a/dlib/svm/svm_c_ekm_trainer.h +++ b/dlib/svm/svm_c_ekm_trainer.h @@ -35,7 +35,7 @@ namespace dlib ekm_stale = true; initial_basis_size = 5; - basis_size_increment = 5; + basis_size_increment = 10; max_basis_size = 300; } @@ -57,7 +57,7 @@ namespace dlib ekm_stale = true; initial_basis_size = 5; - basis_size_increment = 5; + basis_size_increment = 10; max_basis_size = 300; } @@ -181,6 +181,8 @@ namespace dlib ); max_basis_size = max_basis_size_; + if (initial_basis_size > max_basis_size) + initial_basis_size = max_basis_size; } unsigned long get_initial_basis_size ( @@ -202,6 +204,9 @@ namespace dlib ); initial_basis_size = initial_basis_size_; + + if (initial_basis_size > max_basis_size) + max_basis_size = initial_basis_size; } unsigned long get_basis_size_increment ( diff --git a/dlib/svm/svm_c_ekm_trainer_abstract.h b/dlib/svm/svm_c_ekm_trainer_abstract.h index 5e89f6e84..baedff181 100644 --- a/dlib/svm/svm_c_ekm_trainer_abstract.h +++ b/dlib/svm/svm_c_ekm_trainer_abstract.h @@ -46,7 +46,7 @@ namespace dlib - #get_epsilon() == 0.001 - #basis_loaded() == false - #get_initial_basis_size() == 5 - - #get_basis_size_increment() == 5 + - #get_basis_size_increment() == 10 - #get_max_basis_size() == 300 - this object will not be verbose unless be_verbose() is called !*/ @@ -66,7 +66,7 @@ namespace dlib - #get_epsilon() == 0.001 - #basis_loaded() == false - #get_initial_basis_size() == 5 - - #get_basis_size_increment() == 5 + - #get_basis_size_increment() == 10 - #get_max_basis_size() == 300 - this object will not be verbose unless be_verbose() is called !*/ @@ -192,7 +192,7 @@ namespace dlib - max_basis_size > 0 ensures - #get_max_basis_size() == max_basis_size - - if (get_initial_basis_size() < max_basis_size) then + - if (get_initial_basis_size() > max_basis_size) then - #get_initial_basis_size() == max_basis_size !*/