필터 지우기
필터 지우기

BACK PROPAGATION WITH 2 HIDDEN LAYERS

조회 수: 4 (최근 30일)
NAYANA KAMAL
NAYANA KAMAL 2014년 6월 17일
댓글: Greg Heath 2014년 6월 20일
I need to train a neural network with 2 hidden layers.please post the matlab code for 2 hidden layers. In neural network,nntool i can only change the no. of hidden nodes how can i change the no. of hidden layers.
  댓글 수: 3
NAYANA KAMAL
NAYANA KAMAL 2014년 6월 18일
YES, i need the code for 2 hidden layers.please help me.
NAYANA KAMAL
NAYANA KAMAL 2014년 6월 18일
My guide told me to use 2 hidden layers to reduce the mean square error

댓글을 달려면 로그인하십시오.

채택된 답변

Greg Heath
Greg Heath 2014년 6월 18일
My recommendation is to FIRST use one hidden layer and try to minimize the number of hidden nodes while achieving an adjusted R-square >= 0.99. For more advice, I need more information re number and dimensions of input/target examples as well as an explanation of what you are trying to model.
I have posted tens of examples. Search on
greg fitnet % for regression/curve-fitting
greg patternnet % for classification/pattern-recognition
Once a single hidden layer solution is found, you can find a double hidden layer solution by changing fitnet(H) to fitnet([H1,H2]). I explain how to choose H. You are on your own with [H1,H2] except I have heard that, typically, H1+H2 < H. However, I don't believe a proof exists.
Hope this helps.
Thank you for formally accepting my answer
Greg
  댓글 수: 2
NAYANA KAMAL
NAYANA KAMAL 2014년 6월 18일
thank you for your reply.I am doing a rainfall estimation model using the cloud temperature and rainfall data,so i have 80 input values(temperature) and 80 target values(rainfall ).when i use 1 hidden layer the MSE is very high, so i need to test with 2 hidden layers.
Greg Heath
Greg Heath 2014년 6월 20일
Again, 1 hidden layer is sufficient for minimizing MSE. Using more hidden layers does not guarantee a better result. You just need to increase the number of hidden nodes, H, AND try multiple (e.g., 10) cases of initial weights for each value of H.
See my examples. Search using
greg fitnet Ntrials

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Sequence and Numeric Feature Data Workflows에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by