未验证 提交 2242136a 编写于 作者: J Jiabin Yang 提交者: GitHub

Add more dy2st ut2 (#49881)

* add test for composite with dy2st

* add more log
上级 3fdc105f
......@@ -88,6 +88,7 @@ class ElementwiseMulGradCompositeOpMaker
static_cast<int>(this->Attr<int>("axis")),
x_grad_p,
y_grad_p);
VLOG(3) << "Runing mul_grad composite func";
this->RecoverOutputName(x_grad, x_grad_name);
this->RecoverOutputName(y_grad, y_grad_name);
}
......
......@@ -206,6 +206,7 @@ class ExpandV2GradCompositeOpMaker : public prim::GradCompositeOpMakerBase {
auto shape = this->Attr<std::vector<int>>("shape");
prim::expand_grad<prim::DescTensor>(
x, out_grad, paddle::experimental::IntArray(shape), x_grad_p);
VLOG(3) << "Runing expand_v2 composite func";
this->RecoverOutputName(x_grad, x_grad_name);
}
};
......
......@@ -84,7 +84,7 @@ class ReduceSumCompositeGradOpMaker : public prim::GradCompositeOpMakerBase {
// get output orginal name
std::string x_grad_name = this->GetOutputName(x_grad_t);
VLOG(3) << "Runing sum_grad composite func";
// call composite backward func
prim::sum_grad<prim::DescTensor>(
x, out_grad, axis, keep_dim, reduce_all, x_grad);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册