L2regularizáció
L2 regularization, also known as ridge regression, is a technique used in machine learning and statistics to prevent overfitting by adding a penalty to the loss function. This penalty is proportional to the square of the magnitude of the coefficients, which encourages the model to keep the coefficients small. The regularization term is typically added to the ordinary least squares loss function, resulting in a modified loss function that the model aims to minimize.
The L2 regularization term is defined as the sum of the squares of the coefficients, multiplied by
L2 regularization is particularly useful when dealing with multicollinearity, which occurs when predictor variables in a
In summary, L2 regularization is a powerful tool for improving the performance and generalization of machine