Hi, all
Recently I implement a customized loss function, within a batch, there are positive sample loss and negative sample loss, my overall loss will sum these positive and negative loss over a batch, I want minimize the positive sample loss and the negative loss, in other words, the absolute value of negative loss will go higher as optimization proceeds.
An obvious solution would be to set the batch size 1,  decreasing speed dramatically, so, is there any better solution or a hint ?