Sitemap
Level Up Coding

Coding tutorials and news. The developer homepage gitconnected.com && skilled.dev && levelup.dev

Member-only story

Regularization in Machine Learning

6 min readSep 17, 2024

--

Press enter or click to view image in full size
Photo by Tingey Injury Law Firm on Unsplash

You have decided to buy a product. You have started researching about different brands and their features and have learned the features of the product from many sources. However, you cannot decide which features are more important to you and which brand to buy. We have all been in this situation at least once, right? The best decision is to prioritize the features that are most important to us and ignore the others. This is basically what regularization in machine learning does.

What is regularization?

While training machine learning models, we have all encountered overfitting, where the model has high training accuracy but low validation or testing accuracy. This is similar to a student who memorizes previously asked questions but gets a bad grade on an exam. We want the model to learn the pattern in the data, not the data itself. Regularization is a technique used to prevent overfitting in machine learning models and improve model performance.

Press enter or click to view image in full size
overfitting, underfitting

--

--