MCPcopy
hub / github.com/BrainJS/brain.js / constructor

Method constructor

src/recurrent/rnn.js:13–30  ·  view source on GitHub ↗
(options = {})

Source from the content-addressed store, hash-verified

11
12export 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 = {

Callers 2

browser.min.jsFile · 0.45
browser.jsFile · 0.45

Calls 1

fromJSONMethod · 0.95

Tested by

no test coverage detected