MCPcopy Create free account
hub / github.com/Xtra-Computing/thundersvm / SvmParam

Class SvmParam

include/thundersvm/svmparam.h:13–66  ·  view source on GitHub ↗

* @brief params for ThunderSVM */

Source from the content-addressed store, hash-verified

11 * @brief params for ThunderSVM
12 */
13struct SvmParam {
14 SvmParam() {
15 svm_type = C_SVC;
16 kernel_type = RBF;
17 C = 1;
18 gamma = 0;
19 p = 0.1f;
20 epsilon = 0.001f;
21 nu = 0.5;
22 probability = false;
23 nr_weight = 0;
24 degree = 3;
25 coef0 = 0;
26 max_mem_size = static_cast<size_t>(8192) << 20;
27 }
28
29 /// SVM type
30 enum SVM_TYPE {
31 C_SVC, NU_SVC, ONE_CLASS, EPSILON_SVR, NU_SVR
32 };
33 /// kernel function type
34 enum KERNEL_TYPE {
35 LINEAR, POLY, RBF, SIGMOID, PRECOMPUTED
36 };
37 SVM_TYPE svm_type;
38 KERNEL_TYPE kernel_type;
39
40 ///regularization parameter
41 float_type C;
42 ///for RBF kernel
43 float_type gamma;
44 ///for regression
45 float_type p;
46 ///for \f$\nu\f$-SVM
47 float_type nu;
48 ///stopping criteria
49 float_type epsilon;
50 ///degree for polynomial kernel
51 int degree;
52 ///for polynomial/sigmoid kernel
53 float_type coef0;
54 ///for SVC
55 int nr_weight;
56 ///for SVC
57 int *weight_label;
58 ///for SVC
59 float_type *weight;
60 ///do probability estimates
61 int probability;
62 ///maximum memory size
63 size_t max_mem_size;
64 static const char *kernel_type_name[6];
65 static const char *svm_type_name[6];
66};
67#endif //THUNDERSVM_SVMPARAM_H

Callers 2

SetUpMethod · 0.85
read_cmdMethod · 0.85

Calls

no outgoing calls

Tested by 2

SetUpMethod · 0.68
read_cmdMethod · 0.68