declare net of neural network in matlab

6 visualizaciones (últimos 30 días)
Tulips
Tulips el 10 de Oct. de 2012
hi, I'd assigned this variable in matlab net = newff(minmax(input),Target,Hiddenlayer,'logsig','logsig'},'traingdx');'
I have 5 testing different images and 20 training images(4 sample for each of images). my question is to set the input and target, the matrix must be in dimension/matrix values or just simply in vector values? in my research, the problem is nnet does not gives accurate result. the performance always keep on changing when I run nnet.Why is that.. and can someone described me does the neural network values not fixed. is it changes every time we run the nnet?thanks in advance!

Respuesta aceptada

Greg Heath
Greg Heath el 12 de Oct. de 2012
% declare net of neural network in matlab
% Asked by Tulips on 10 Oct 2012 at 10:49
% hi, I'd assigned this variable in matlab
% net = newff(minmax(input),Target,Hiddenlayer,'logsig','logsig'},'traingdx');'
Invalid syntax for BOTH OBSOLETE versions of newff.
Which version are you using?
Is this regression or classification?
If the latter, use columns of eye(5) for target columns.
Make sure inputs are standardized (zscore or mapstd) and use tansig as the hidden node activation function.
[ I N ] = size(input)
[O N ] = size(target)
net = newff(mimax(input), [H O],{'tansig' 'logsig'); % Obsolete
net = newff(input, target, H, {'tansig' 'logsig'} ) ;% Less Obsolete
% I have 5 testing different images and 20 training images(4 sample for % each of images). my question is to set the input and target, the matrix % must be in dimension/matrix values or just simply in vector values? in my % research, the problem is nnet does not gives accurate result. the % performance always keep on changing when I run nnet.Why is that.. and can % someone described me does the neural network values not fixed. is it % changes every time we run the nnet?thanks in advance!
Each call of newff loads random weights. To repeat a previous run reinitialize the RNG to the same initial state.
Sample code is available by searhing the newsgroup using some subset of
heath newff close clear Neq Nw Ntrials
Hope this helps.
Thank you for formally accepting my answer.
Greg
  6 comentarios
Tulips
Tulips el 18 de Oct. de 2012
sir can you explain me.for instance I have:- input = 200 x 20,[R,C]=size(input) target= 5 x20, [S2,Q]=size(target) output= 5 hiddenlayer =150 can to use patternet syntax to declare the above values? does patternnet same with newff?if I used for of them should I declare the value for bias or weight?or they are already built in with matlab.thanks for your answer.
Tulips
Tulips el 18 de Oct. de 2012
can I know from the confusion table if I used patternnet.if it display NaN value at the confusion table, does it means our data is wrong?

Iniciar sesión para comentar.

Más respuestas (0)

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by