... | ... | @@ -3,13 +3,13 @@ |
|
|
An implementation of linear SVM for multiclass classification.
|
|
|
|
|
|
```prolog
|
|
|
:- use_module('path/to/.../src/methods/hoeffding_tree/hoeffding_tree.pl').
|
|
|
:- use_module('path/to/.../src/methods/linear_SVM/linear_SVM.pl').
|
|
|
|
|
|
%% usage example
|
|
|
TrainData = [5.1,3.5,1.4, 4.9,3.0,1.4, 4.7,3.2,1.3, 4.6,3.1,1.5],
|
|
|
TestData = [3,2,0, 5,1,4, 0,0,4, 3,3,5, 0,5,5, 2,5,5],
|
|
|
hoeffding_tree_initAndBuildModel(gini_hoeffding, TrainData, 3, [0,1,0,1], 2, 0, 0.95, 5000, 100, 100, 10, 100),
|
|
|
hoeffding_tree_classify(TestData, 3, PredicList, ProbsList).
|
|
|
linear_SVM_initModelWithTrain(TrainData, 3, [0,1,0,1], 2, 0.0001, 1.0, 0, lbfgs),
|
|
|
linear_SVM_classify(TestData, 3, LabelsList, ScoresList, _).
|
|
|
```
|
|
|
|
|
|
# Available Predicates
|
... | ... | |