未验证 提交 c693a027 编写于 作者: C ccrrong 提交者: GitHub

fix bug (#44875)

上级 4922376c
......@@ -2085,6 +2085,12 @@ bool OpTeller::Tell(const framework::ir::Node* node,
#if !IS_TRT_VERSION_GE(7000)
return false;
#endif
if (!(desc.HasAttr("in_dtype") && desc.HasAttr("out_dtype"))) {
VLOG(3) << "the " << op_type
<< " does not have attr (in_dtype or "
"out_dtype)";
return false;
}
int in_dtype = PADDLE_GET_CONST(int, desc.GetAttr("in_dtype"));
int out_dtype = PADDLE_GET_CONST(int, desc.GetAttr("out_dtype"));
if ((in_dtype == 4 || in_dtype == 5) && out_dtype == 4) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册