@@ -21,11 +21,11 @@ the lib, please do not use it in a browser.
21
21
22
22
- #### Classification algorithms
23
23
- [ LogisticRegressor] ( https://github.com/gyrdym/ml_algo/blob/master/lib/src/classifier/logistic_regressor/logistic_regressor.dart ) .
24
- A class that performs linear binary classification of data. To use this kind of classifier your data have to be
24
+ A class that performs linear binary classification of data. To use this kind of classifier your data has to be
25
25
[ linearly separable] ( https://en.wikipedia.org/wiki/Linear_separability ) .
26
26
27
27
- [ SoftmaxRegressor] ( https://github.com/gyrdym/ml_algo/blob/master/lib/src/classifier/softmax_regressor/softmax_regressor.dart ) .
28
- A class that performs linear multiclass classification of data. To use this kind of classifier your data have to be
28
+ A class that performs linear multiclass classification of data. To use this kind of classifier your data has to be
29
29
[ linearly separable] ( https://en.wikipedia.org/wiki/Linear_separability ) .
30
30
31
31
- [ DecisionTreeClassifier] ( https://github.com/gyrdym/ml_algo/blob/master/lib/src/classifier/decision_tree_classifier/decision_tree_classifier.dart )
@@ -121,7 +121,7 @@ final createClassifier = (DataFrame samples) =>
121
121
optimizerType: LinearOptimizerType.gradient,
122
122
iterationsLimit: 90,
123
123
learningRateType: LearningRateType.decreasingAdaptive,
124
- batchSize: trainSamples .rows.length,
124
+ batchSize: samples .rows.length,
125
125
probabilityThreshold: 0.7,
126
126
);
127
127
```
@@ -134,7 +134,7 @@ be run this amount of times
134
134
- ` learningRateType ` - a strategy for learning rate update. In our case the learning rate will decrease after every
135
135
iteration
136
136
- ` batchSize ` - size of data (in rows) that will be used per each iteration. As we have a really small dataset we may use
137
- full-batch gradient ascent, that's why we used ` trainSamples .rows.length` here - the total amount of data.
137
+ full-batch gradient ascent, that's why we used ` samples .rows.length` here - the total amount of data.
138
138
- ` probabilityThreshold ` - lower bound for positive label probability
139
139
140
140
If we want to evaluate the learning process more thoroughly, we may pass ` collectLearningData ` argument to the classifier
@@ -247,7 +247,7 @@ void main() async {
247
247
optimizerType: LinearOptimizerType.gradient,
248
248
iterationsLimit: 90,
249
249
learningRateType: LearningRateType.decreasingAdaptive,
250
- batchSize: trainSamples .rows.length,
250
+ batchSize: samples .rows.length,
251
251
probabilityThreshold: 0.7,
252
252
);
253
253
final scores = await validator.evaluate(createClassifier, MetricType.accuracy);
0 commit comments