#loss function vs cost function

6 messages · Page 1 of 1 (latest)

fallow notch
#

Hello, can someone explain the difference between a loss and a cost function please. I know that loss function is used to optimize our parameters using optimization techniques like gradient descent. But when does this occur, in each hidden layer? or at the output node?

What about a cost function pls

misty elbow
#

This one also confused me when i was learning ML think as simple … you use loss function when you measure the predicted output with actual on a** singlr sample**

And in cost function you take the average loss of thr overall dataset we use cost function to find the overall loss so then we can use gradient decent to minimise that losss….

fallow notch
#

Question though, why do we need both?

misty elbow
#

How would you calculate calculate the average error of each batch when you dont know the individual one??

fallow notch
#

no but why can't we just have the loss function which is the error of each batch