How can I improve my neural network output?

조회 수: 2 (최근 30일)
Alexandru Vasile
Alexandru Vasile 2015년 5월 8일
댓글: Alexandru Vasile 2015년 5월 8일
Hello,
I have a prediction problem with 6x365 inputs( 6 represent, for example, the temperature for last six hours since now of every day from my database registrations) and 1x365 targets(I want to predict the next hour temperature). I don't how to choose the number of hidden layers, the number of nodes, the training algorithm, the transfer function.
That's my code now and the output is not very desirable:
net1 = newff(minmax(Input_temp),[20 1],{'tansig' 'purelin'},'traincgb','learngd');
net1.trainParam.epochs = 5000;
[net1,pr] = train(net1,Input_temp,Target_temp);
Output_temp = net1(Sample_temp)
Thank you for your time, Have a good day!

채택된 답변

Greg Heath
Greg Heath 2015년 5월 8일
"Not very desirable" is not very helpful. Need a numerical measure. For example
NMSE = mse(target-output)/var(target,1) % Normalized mean-square-error
NEWFF with the (minmax ... syntax has been obsolete for 10 yrs or so.
NEWFF with the (input,target,... syntax has been obsolete for 5 yrs or so.
What version of the NNToolbox are you using? Do you have FITNET?
[I N ] = size(input) % [ 6 365 ]
[O N ] = size(target) % [ 1 365 ]
Ntrn = N-2*round(0.15*N) % 255 (default 70% training examples)
Ntrneq = Ntrn*O % 255 training equations
% Nw = (I+1)*H + (H+1)*O % Number of unknown weights
% Ntrneq > Nw <==> H <= Hub % "u"pper "b"ound
Hub = -1+ceil((Ntrneq-O)/(I+O+1)) % 31
Try 10 or more multiple designs with H as small as possible (H << Hub is highly desirable but not necessary). For each value of H create 10 designs with different random initial weights and data divisions.
For many, many examples search the NEWSGROUP and ANSWERS using
greg Hmin:dH:Hmax Ntrials
Hope this helps.
Thank you for formally accepting my answer
Greg

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Deep Learning Toolbox에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by