MATLAB: Neural Network tool box

Deep Learning Toolboxduplicate postneural network

my pattern P size is 180*15 and target T size is 15*15.
Create a network : mynet=newff(P,T,[80],{'logsig' 'logsig'},'traingdx');
train it : mynet=train(mynet,P,T);
However I get different result at different time of executing the script. is it the nature of neural network???

Best Answer

Default trn/val/tst data division and initial weights are random. To duplicate runs you have to initialize the RNG to the same initial state as before
help rng
doc rng
WARNING: YOUR PROBLEM IS VERY, VERY ILL-POSED
[ I N ] = size(P ) % [ 180 15 ]
[ O N ] = size(T) % [ 15 15 ]
Ntrn = N -2*round(0.15*N) % DEFAULT: 11 training (2 validation and 2 test) examples
Ntrneq = Ntrn*O % 165 training equations
H = 80 % 80 hidden nodes
Nw = (I+1)*H+(H+1)*O % 181*80+81*15 = 15,695 unknown weights
1. You are trying to define an I= 180 dimensional space with only Ntrn = 11 training examples. 11 examples define at most a 10 dimensional space. Even if you used all 15 examples for training, you could only define, at most, a 14 dimensional space.
2. It is desirable to have MANY MORE training examples than twice the dimensionality of the input space. SUGGESTION: Get more examples and/or reduce the dimensionality of your input by projecting your inputs onto a smaller dimensional basis.
3. You are seeking accurate estimates of 15,695 unknown weights with only 165 training equations.
4. Ideally
a. N >> I,O
b. Ntrneq >> Nw <==> H << Hub = -1+ceil((Ntrneq-O)/(I+O+1))
If you explain in more detail P,I, T and O, perhaps we can give you better advice and relevant references.
Hope this helps.
Thank you for formally accepting my answer
Greg