Keras: How is the optimization loss estimated for a network with multiple output levels?

I am using the functional API in Keras to create a neural network model with multiple output layers. I was wondering how the loss when updating weights is estimated during optimization (when executing a back-prop). Assuming the same loss function is used, is the average loss of all outputs used to minimize the cost function, or is each outcome evaluated separately to update the weights?

Thanks in advance!

+3


source to share


1 answer


There is always only one loss, which is used for backpropagate errors, when the model has multiple outputs, then each output is associated with one loss, and then a "global" loss is created by weighting the losses for each output. You can set a weight for each loss when compiling the model.



+2


source







All Articles