提交 3fc9be90 编写于 作者: 0 0x45f

Polish code

上级 c8cb78fb
......@@ -123,7 +123,7 @@ inline void run_program_ad_func(
// Set Attributes
grad_node->SetAttrMap(attrs);
// Set TensorWrappers
auto* forward_global_block = PADDLE_GET_CONST(
paddle::framework::BlockDesc*, attrs.at("forward_global_block"));
auto* backward_global_block = PADDLE_GET_CONST(
......@@ -131,6 +131,7 @@ inline void run_program_ad_func(
// Clear unused x vars
auto filter_x =
filter_unused_input_var_in_backward(x, backward_global_block);
// Set TensorWrappers
grad_node->SetFwdX(filter_x);
// Clear unused out vars
clear_unused_out_var_in_backward(out, backward_global_block, step_scope[0]);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册
新手
引导
客服 返回
顶部