提交 9811a09e 编写于 作者: L LDOUBLEV

fix combined loss

上级 48898ac3
......@@ -53,8 +53,9 @@ class CombinedLoss(nn.Layer):
for key in loss:
if key == "loss":
loss_all += loss[key] * weight
# else:
# loss[f"{key}_{idx}"] = loss[key]
else:
loss["{}_{}".format(key, idx)] = loss[key]
# loss[f"{key}_{idx}"] = loss[key]
loss_dict.update(loss)
loss_dict["loss"] = loss_all
return loss_dict
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册