未验证 提交 a60893f6 编写于 作者: L lidanqing 提交者: GitHub

correct the allowed dimension size (#30326)

上级 c8c8f205
......@@ -94,8 +94,10 @@ void eltwise_forward(const framework::ExecutionContext &ctx,
}
PADDLE_ENFORCE(
x->dims().size() == 2 || x->dims().size() == 3 || x->dims().size() == 4,
platform::errors::Unimplemented("Input dim must be with 2, 3 or 4"));
x->dims().size() >= 1 || x->dims().size() <= 6,
platform::errors::Unimplemented("Input dimension size can be 1, 2, 3, 4, "
"5, or 6, but now the dimension size is",
x->dims().size()));
auto src_tz = framework::vectorize<int64_t>(x->dims());
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册