(options = {})
| 11 | |
| 12 | export default class RNN { |
| 13 | constructor(options = {}) { |
| 14 | const defaults = this.constructor.defaults; |
| 15 | |
| 16 | Object.assign(this, defaults, options); |
| 17 | |
| 18 | this.stepCache = {}; |
| 19 | this.runs = 0; |
| 20 | this.totalCost = null; |
| 21 | this.ratioClipped = null; |
| 22 | this.model = null; |
| 23 | |
| 24 | this.inputLookup = null; |
| 25 | this.outputLookup = null; |
| 26 | |
| 27 | if (options.json) { |
| 28 | this.fromJSON(options.json); |
| 29 | } |
| 30 | } |
| 31 | |
| 32 | initialize() { |
| 33 | this.model = { |
no test coverage detected