How to specify the transfer function for the hidden and output layer?

I am using feedforwardnet to create a neural network. But this function takes only two arguments: the hidden layer sizes and the training function. I want to specify the transfer functions for each layer.

 채택된 답변

Greg Heath
Greg Heath 2014년 10월 8일
Use fitnet for regression/curve-fitting or patternnet for classification/pattern-recognition. Both call feedforwardnet.
2 layers are sufficient: 1 hidden + 1 output
Standardize(0-mean/unit-variance via zscore or mapstd) inputs and regression outputs.
Remove or modify outliers
Convert classification targets to 0-1 unit vectors via ind2vec
Accept the fitnet default transfer functions tansig/purelin
For classification the default tansig/softmax transfers are the better choice
The best way to choose initial weights and number of hidden nodes is via trial and error.
I have posted many double for loop examples. Search the NEWSGROUP and ANSWERS
greg fitnet Ntrials % for regression
greg patternnet Ntrials % for classification
Hope this helps.
Thank you for formally accepting my answer
Greg

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Deep Learning Toolbox에 대해 자세히 알아보기

질문:

2014년 10월 7일

답변:

2014년 10월 8일

Community Treasure Hunt

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

Start Hunting!

Translated by