How can I improve generalization for my Neural Network?

Technical Source
2 min readJun 28, 2021

--

How can I improve generalization for my Neural Network?

I have a network that is trained with very low error but it does not perform well with new data sets. Is there something more that can be done to have a network with low error that can also generalize with new situatio

ANSWER

Matlabsolutions.com provide latest MatLab Homework Help,MatLab Assignment Help for students, engineers and researchers in Multiple Branches like ECE, EEE, CSE, Mechanical, Civil with 100% output.Matlab Code for B.E, B.Tech,M.E,M.Tech, Ph.D. Scholars with 100% privacy guaranteed. Get MATLAB projects with source code for your learning and research.

When training a Neural Network, generalization is an important feature to maintain in order to avoid overfitting. This can occur when the error on the training set is forced to a very small value. The network will perform very well for that particular training set because it has memorized the training examples but it can not learn to adapt to new situations. In other words it is not generalized.

There are several methods in which one can improve the generalization of the Neural Network without sacrificing accuracy.

Specifying a network which is just large enough to provide an adequate fit is highly recommended. Not only will it improve generalization but it will speed up training. The drawback to this is that you have to know beforehand how many neurons are adequate for a particular application. This can become quite difficult.

There are two other methods which are implemented in the Neural Network Toolbox.

1) The first method is known as Regularization. This invloves a modification of the performance function which is, by default, the mean sum of squares of the network errors (MSE). Generalization can be improved by modifying this performance function as follows:

MSEREG=g*MSE +(1-g)*MSW

where g is a performance ratio and MSW is the mean sum of sqaures of the network weights and biases. To set this in MATLAB please see the following example:

SEE COMPLETE ANSWER CLICK THE LINK

--

--

Technical Source
Technical Source

Written by Technical Source

Simple! That is me, a simple person. I am passionate about knowledge and reading. That’s why I have decided to write and share a bit of my life and thoughts to.

No responses yet