Artificial neural network - weights & biases

2 views (last 30 days)
Hi everybody, I have used net = newff(F, T,[],{},'traingdx') in MATLAB R2012a version where F is a 2x4601 input matrix and T is 1x4601 target row matrix. After choosing epochs, goal, min_grad and performFcn, i train the net with net1=train(net,F,T); After training weights and biases are as follows: w1 = [ 0.427926451246563 -0.185905577940879] and b = -0.248424844054488. Then I calculate T_net = sim(net1, F) and I compare T with respect to T_net. My question is: How can I obtain the same results of T_net by using the input matrix F, weights w1 and bias b? I've tryed T_calc = b + w1 * F; but it doesn't work. Is there a missing normalization? Can anyone explain me what's wrong?

Accepted Answer

Greg Heath
Greg Heath on 25 Sep 2015
1. newff automatically normalizes F and T to [-1,1] and then unnormalizes the net output to obtain Tnet
2. The default transformation between the normalized variables is
Tn = b2 + tansig( b1 + w1*Fn )
Hope this helps.
Thank you for formally accepting my answer
Greg

More Answers (0)

Categories

Find more on Deep Learning Toolbox in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!