What is a loss function?

A loss function is a function that calculates the difference between an estimate and the true value of some data. In machine learning, it is often called the “cost function” – a calculation of the cost of the prediction of a machine learning algorithm from some target value. It is used in optimization problems where the goal is to minimize the loss so that the accuracy of the model is maximized. The loss represents the penalty of making an incorrect prediction.

%d bloggers like this: