I'm aware of tensorflow.js, but what really struck me with brain.js was this snippet from the very beginning of the readme file:
how to approximate the XOR function using brain.js
const net = new brain.NeuralNetwork(config);
net.train([{input: [0, 0], output: [0]},
{input: [0, 1], output: [1]},
{input: [1, 0], output: [1]},
{input: [1, 1], output: [0]}]);
const output = net.run([1, 0]); // [0.987]
This is how you win over newcomers -- quick, accessible demonstrations of the product/library's capabilities. A sample is worth a thousand words. Tensorflow may have a lot of great, detailed examples, but its documentation fails in this regard.
how to approximate the XOR function using brain.js
This is how you win over newcomers -- quick, accessible demonstrations of the product/library's capabilities. A sample is worth a thousand words. Tensorflow may have a lot of great, detailed examples, but its documentation fails in this regard.