How to combine multiple criterions to a loss function? 
  
  
    I;m building recursive neural nets, so I’ll have a variable list of criterions. I want to sum them up and backpropagate error. 
All the errors are single float values and of same scale. So the total loss is the sum of individual losses 
To understand this, I crystallized this problem. It’s for another classification project. 
I wrote this code and it works 
def loss_calc(data,targets):
  data = Variable(torch.FloatTensor(data)).cuda()
  targets = Variable(torch.LongTensor(targets)).cuda()
  outp…