why does I-H-O neural network predict constant values?

3 views (last 30 days)
my neural network was working reasonably, except for the prediction of negative values sometimes which is impossible physically since I am trying to predict concentrations in the sewer system based on 5 relevant parameters. Therefore, I tried the suggestion proposed by Greg in the following thread:
namely "Use 'tansig' for hidden and 'logsig' for output."
however, when I implement this, all the predicted values go to a constant value (which is about halve of the maximum) and the optimizaion process stops. I thought it might be a problem of rescaling my data (maximum is now around 300), but after rescaling such that the maximum is one, the problem still remains, now converging all results to 0.5
what am I doing wrong? Is there another possibility of making sure my NN does not predict negative values?
hiddenLayerSize = 20;
net = fitnet(hiddenLayerSize);
net.layers{1}.transferFcn = 'tansig'; % hidden layer
net.layers{2}.transferFcn = 'logsig'; % output layer
[net,tr] = train(net,inputs,targets);
  5 Comments
Greg Heath
Greg Heath on 31 Jul 2015
Insufficient information.
Post your code (your data in *.m or *.txt would also help)

Sign in to comment.

Answers (0)

Categories

Find more on Graphics Performance in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!