brain icon indicating copy to clipboard operation
brain copied to clipboard

Segmented options

Open christopherdebeer opened this issue 13 years ago • 3 comments

Hi, this post is more discussion than issue. It's related to what was said before on issue #13.

Currently brains, when created take options hiddenLayers & learningRate :

var net = new NeuralNetwork({
   hiddenLayers: [4],
   learningRate: 0.6
});

And when trained, take data and options errorThresh, iterations, log & logPeriod :

net.train(data, {
   errorThresh: 0.004,  
   iterations: 20000,
   log: true,
   logPeriod: 10
});

What I'm asking is this, given that one cannot iteratively train a these neural networks, why are there 2 points at which different options are provided to the neural network?

Does it not make sense to declare all options/setting in one place, ie on creation of the neural network?

Perhaps something like:

var net = new NeuralNetwork({
   hiddenLayers: [4],
   learningRate: 0.6,
   errorThresh: 0.004,  
   iterations: 20000,
   log: true,
   logPeriod: 10
});

net.train(data);

Chris

christopherdebeer avatar May 30 '12 12:05 christopherdebeer

I would like to see brain one day be able to train multiple times instead of just once. If that were to happen, it would make sense to keep the settings as they currently are.

tlhunter avatar Jun 05 '12 15:06 tlhunter

@christopherdebeer good point. I think more of them should actually move to the train() call, with maybe the hiddenLayers option sticking with the network initialization.

harthur avatar Jun 06 '12 00:06 harthur

@tlhunter see: https://github.com/harthur/brain/pull/63

robertleeplummerjr avatar Dec 21 '16 14:12 robertleeplummerjr