DeepLearnToolbox icon indicating copy to clipboard operation
DeepLearnToolbox copied to clipboard

Issue with the file nnff.m

Open bnaman50 opened this issue 9 years ago • 2 comments

I was using this toolbox for implementing a simple neural network. But I have a doubt. The way you are calculating the output of the hidden layers is ( nn.a{i} = sigm(nn.a{i - 1} * nn.W{i - 1}'); ), ignoring the bias term 'b'. Can you help me out with that or tell me if it's required or not.

bnaman50 avatar Jul 15 '15 00:07 bnaman50

Bias term is simulated by having one of the inputs 1 all time. Then bias corresponds to weight of this item. These lines in the start of nnff.m implement it:

x = [ones(m,1) x];
nn.a{1} = x;

tambetm avatar Jul 15 '15 07:07 tambetm

Thanks a lot for your help.

bnaman50 avatar Jul 15 '15 18:07 bnaman50