Hello everyone!
Why losses combined as
loss_dict = model(images, targets) losses = sum(loss for loss in loss_dict.values()) optimizer.zero_grad() losses.backward() but never as
losses = sum(loss_dict.values()) ? Is it the same ?