Skip to content

Throws a NaN even though dataset / output are just numbers. #169

@digi0ps

Description

@digi0ps

A GIF or MEME to give some spice of the internet

What is wrong?

Getting {"error": null, "iterations": 20000} even though training dataset are just numbers.

Where does it happen?

When brain.js trains data in my sample website running in Chrome 65 on Mac

How do we replicate the issue?

Input data: https://gist.github.com/digi0ps/65bebf027876f85b42ab7b4dd2ba49bf
Code:

 let net = new brain.NeuralNetwork();
 net.train(encoded);
 trained  = net.toFunction()

How important is this (1-5)?

  1. Just trying to learn. But I'm curious as to why it's not working

Expected behavior (i.e. solution)

Error shouldn't have been NaN. When I run net.run with an input I get
{english: NaN, tanglish: NaN}
instead of values inside them.

Other Comments

Here is the NeuralNetwork object:
https://gist.github.com/digi0ps/53292e8c55c31b7de8de9dcb06ea22e5

Can you help?
Regards,
Sriram.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions