If so, how to apply different optimizers to the two different branches? I mean, branch 1 with loss_1, branch 2 with loss_2,
loss = 2*loss_1 + 3 *loss_2
loss.backward()
optimizer.step()
how to wrap the two branches into one optimizer,while this optimizer contains actually two optim methods(Adam–>branch_1 and SGD–>branch_2)?