negative values in the output of the neural network

2 次查看(过去 30 天)
Hello everyone, I generated a neural network using the "neural net fitting" app with Bayesian regularization. There are 6 input columns (6 different wavelengths of light) and the output gives me a water parameter. However, there are no negative values in the input values and this output parameter cannot have negative results. Unfortunately this is not what happened, on average 0.05% of the data calculated with this generated neural network are generating negative values for me. Does anyone have a way to resolve or a way in which I can find out the range of these input parameters that are generating negative values?

回答(1 个)

Milan Bansal
Milan Bansal 2024-9-9
Hi Álvaro
Improving the performance of your neural network in MATLAB when using nntraintool can involves several strategies. Here are some suggestions to help you achieve better convergence and performance:
Data Preprocessing:
  • Normalization: Ensure your input and target data are normalized. This can help the network learn more effectively.
  • Data Quality: Check for outliers or errors in your dataset that could be affecting learning.
Network Architecture:
  • Hidden Layers and Neurons: Experiment with different numbers of hidden layers and neurons. More complex models might require deeper networks, but be cautious of overfitting.
  • Activation Functions: Try different activation functions for hidden layers, such as ReLU, sigmoid, or tanh, to see which works best for your problem.
Validation and Early Stopping:
  • Validation Set: Ensure your validation set is representative of your data. Consider using cross-validation to get a more reliable estimate of the network's performance.
  • Early Stopping Patience: Increase the number of validation checks before stopping to give the network more chances to improve.
Initialization:
  • Weight Initialization: Use a different weight initialization strategy, such as Xavier or He initialization, which can help with better convergence.
Increase Epochs:
  • Maximum Epochs: If the network is stopping due to reaching the maximum number of epochs, consider increasing this limit.
By systematically experimenting with these strategies and monitoring the results, you should be able to improve the performance of your neural network for solving your dynamic economic model.
Hope this helps!

类别

Help CenterFile Exchange 中查找有关 Networks 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by