You can merge them, that’s ok. And both in technical and mathematics,  it’s work.
But adding them together is a simple way, you can add learning variable a to self-learning the “biased” of that two different loss.
a = torch.tensor(0.5, requires_grad=True)
loss = (1-a)*loss_reg + a*loss_clf