提交 fc7d0ca1 编写于 作者: F fengjiayi

fix errors

上级 b05c253c
...@@ -158,11 +158,9 @@ def _append_backward_ops_(target, ...@@ -158,11 +158,9 @@ def _append_backward_ops_(target,
op_type="fill_constant", op_type="fill_constant",
inputs={}, inputs={},
outputs={"Out": [grad_target_name]}, outputs={"Out": [grad_target_name]},
attrs={ attrs={"shape": [1],
"shape": [1], "value": 1.0,
"value": 1.0, "dtype": target.dtype}))
"dtype": core.DataType.FP32
}))
for op_desc in grad_op_descs: for op_desc in grad_op_descs:
new_op_desc = target_block.desc.append_op() new_op_desc = target_block.desc.append_op()
new_op_desc.copy_from(op_desc) new_op_desc.copy_from(op_desc)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册