<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Ramesh Kumar on Medium]]></title>
        <description><![CDATA[Stories by Ramesh Kumar on Medium]]></description>
        <link>https://medium.com/@rameshkjes?source=rss-5b479d11f866------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*0n0SygTtJEQWGoFQJF3ZAw.jpeg</url>
            <title>Stories by Ramesh Kumar on Medium</title>
            <link>https://medium.com/@rameshkjes?source=rss-5b479d11f866------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Mon, 30 Nov 2026 20:35:59 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@rameshkjes/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Overfitting and Regularization in Neural Networks]]></title>
            <link>https://medium.com/@rameshkjes/overfitting-and-regularization-in-neural-networks-d3d996e33c3?source=rss-5b479d11f866------2</link>
            <guid isPermaLink="false">https://medium.com/p/d3d996e33c3</guid>
            <category><![CDATA[neural-networks]]></category>
            <category><![CDATA[regularization]]></category>
            <category><![CDATA[overfitting]]></category>
            <category><![CDATA[machine-learning]]></category>
            <dc:creator><![CDATA[Ramesh Kumar]]></dc:creator>
            <pubDate>Fri, 27 Jul 2018 08:52:43 GMT</pubDate>
            <atom:updated>2018-07-27T13:58:48.330Z</atom:updated>
            <content:encoded><![CDATA[<p>This article explains overfitting and regularization in a simplest way. We will look what is overfitting, why it happens, consequences of overfitting, how to determine whether model is overfitting, and the ways to avoid the overfitting using regularization.</p><h3><strong>Overfitting</strong></h3><p>Overfitting is when the trained model memorizes the undesirable patterns or noise from the training data-set. This is due to too much training or learning capacity(too many hidden layers or neurons in each layer). The consequence of overfitting is that, model cannot generalize to samples outside its training set, which overall reduces the performance of the model. To determine whether the model is overfitting, during the training, compare the loss value on the training and testing set. If the <strong>loss on the test set is much larger than in the training set</strong>, then the model is <strong>overfitting</strong>, specially if the training loss is low. However, it is also normal that the test loss is slightly larger than training loss.</p><p>In order to prevent overfitting there are various ways such as: reduce model learning capacity, use a different model, use regularization or methods that combat overfitting, etc.</p><h3>Regularization</h3><p>Now, we will discuss about regularization and its different techniques. Mind map shows few techniques that comes under regularization.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/560/1*zYfwoRcih4jzyDP3j3aVmQ.png" /></figure><p>Regularization is a way of providing the additional information to the machine learning model to reduce the overfitting and improve generalization.</p><p><strong>1. Data Augmentation:</strong> This is the simplest way to regularize a model by training with more data. Since capturing and labeling of data is usually expensive, therefore new data is generated from existing data, with the help of image rotations, flips (up down, left right), brightness changes, scaling, rotation, translation, and so on.</p><p><strong>2. Early Stopping:</strong> Usually machine learning models use iterative methods for training. Then the number of iterations (or epochs) is the tunable hyper-parameter. Early stopping is just the process of stopping training right before the validation loss starts to increase.</p><p><strong>3. LP Regularization (Tikhonov’s):</strong> This is the most common regularization method. It consists of introducing a penalty that considers the norm of the model parameters (weights):</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/333/1*CheaxwF_oHiSDsHu-0OTmA.png" /></figure><p>The sum is over all trainable model parameters. Lambda is a tunable regularization coefficient that defines the strength of regularization. p is the norm dimensionality, if it is set to 1, then regularization is considered as <strong>LASSO</strong>, if it is set to, then regularization is <strong>weight decay</strong></p><p><strong>4. Dropout:</strong> It is another way to prevent neural networks from overfitting. Researchers have noticed that Neural networks over-fit due to “co-adaption” between neurons. Co-adaption occurs when two or more neurons in the network begins to detect the same feature repeatedly, which means network isn’t utilizing its full capacity efficiently. This shows, it is wasting computational resources by computing the activation for redundant neurons that are all doing the same thing.<br> In order to break the co-adaption, noise is introduced in the network during training. Each output from a layer is randomly set to zero with some probability p. Figure shows difference between the standard neural network and network after applying dropout.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/579/1*bV_Q6eg7PhNQoRZuxawodQ.png" /></figure><p><strong>5. Batch Normalization:</strong> It is way of normalizing the inputs by adjusting and scaling the activations (for more details <a href="https://towardsdatascience.com/batch-normalization-in-neural-networks-1ac91516821c">Batch Normalization in Neural Networks</a>). It is necessary when values of features are in different ranges. Furthermore, Google researchers noticed that by normalizing inputs, training is faster (less iterations) and it also introduces a small degree of regularization.</p><p><strong>References:</strong></p><p><a href="https://www.quora.com/What-does-co-adaptation-of-neurons-in-a-Neural-network-mean">https://www.quora.com/What-does-co-adaptation-of-neurons-in-a-Neural-network-mean</a></p><p>Dropout: A Simple Way to Prevent Neural Networks from Overfitting by Nitish Srivastava, Geoffrey Hinton, Alex Krizhevsky, Ilya Sutskever, Ruslan Salakhutdinov, 2014.</p><p>Batch Normalization: Accelerating Deep Network Training b y Reducing Internal Covariate Shift by Sergey Ioffe and Christian Szegedy</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d3d996e33c3" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>