Consider a network (i) -> (h) -> (o) where i, h, o, are input, hidden, and output layers, respectively.
I would like to associate a loss Lh and a loss Lo to layers h and o, respectively. However, I wish to backpropagate Lh only from layer h, backward, and loss Lo from layer o backward.
Could anyone please point me through the right direction to do so?
Many thanks