Schould be able to set a callback the rate

Esse commit está contido em:
Borut
2016-07-12 22:38:14 +02:00
commit 533d77aaea
2 arquivos alterados com 8 adições e 0 exclusões
+4
Ver Arquivo
@@ -1988,6 +1988,10 @@
var currentBucket = Math.floor(iterations / bucketSize);
currentRate = this.rate[currentBucket] || currentRate;
}
if(typeof this.rate === 'function') {
currentRate = this.rate(iterations, error);
}
if (crossValidate) {
this._trainSet(trainSet, currentRate, cost);
+4
Ver Arquivo
@@ -86,6 +86,10 @@ Trainer.prototype = {
var currentBucket = Math.floor(iterations / bucketSize);
currentRate = this.rate[currentBucket] || currentRate;
}
if(typeof this.rate === 'function') {
currentRate = this.rate(iterations, error);
}
if (crossValidate) {
this._trainSet(trainSet, currentRate, cost);