Say I have a batch of examples, each examples represent a state:

[0.1, 0.2, 0.5] #1st example
[0.4, 0.0, 0.3] #2nd example 
[0.1, 0.1, 0.1] #16th example

I feed through the NN, and then the NN predict the following class:

[move up]   #1st example
[move down] #2nd example
[move left] #16th example

And then I take the square loss (which calculated to be 0.1 after taking average over 16 examples), and do backward propagation.

So, can I assume that each of these examples will assign (or contribute) to a 0.1 loss?


This would mean that there is only one gradient update on your dataset of 16 samples. If you are taking the mean of all the squared errors ( mse ), then the loss of each sample is contributing to the 0.1 loss.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.