提交 7432c040 编写于 作者: myq406450149's avatar myq406450149

fix format. test=develop

上级 c9877bee
......@@ -211,7 +211,7 @@ class ArrayToLoDTensorInferShape : public framework::InferShapeBase {
PADDLE_ENFORCE_EQ(
context->HasInput("X"), true,
platform::errors::NotFound("Input(X) of BmmOp should not be null"));
PADDLE_ENFORCE_EQ(context->HasInput("RankTable", true),
PADDLE_ENFORCE_EQ(context->HasInput("RankTable"), true,
platform::errors::NotFound(
"Input(RankTable) of BmmOp should not be null"));
// For compile-time, the first dim of input X and output Out should be -1.
......
......@@ -108,9 +108,10 @@ class LoDTensorToArrayOp : public framework::OperatorBase {
auto max_seq_len = items[0].length;
auto rank_level = rank_table.level();
PADDLE_ENFORCE_LT(rank_level, x.lod().size(),
PADDLE_ENFORCE_LT(
rank_level, x.lod().size(),
platform::errors::InvalidArgument(
`"Input should be a LoDTensor, and its lod_level should be at "
"Input should be a LoDTensor, and its lod_level should be at "
"least %d",
rank_level + 1));
out.resize(max_seq_len);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册