Merge pull request #12981 from chenwhql/sequence_erase_op_infershape_note_polish

Doc: unified infershape format
revert-13637-optimize-opyreader
Tao Luo 6 years ago committed by GitHub
commit 49cd43000c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -24,9 +24,9 @@ class SequenceEraseOp : public framework::OperatorWithKernel {
void InferShape(framework::InferShapeContext* ctx) const override {
PADDLE_ENFORCE(ctx->HasInput("X"),
"Input(X) of SequenceEraseOp should not be null.");
"Input(X) of SequenceErase operator should not be null.");
PADDLE_ENFORCE(ctx->HasOutput("Out"),
"Output(Out) of SequenceEraseOp should not be null.");
"Output(Out) of SequenceErase operator should not be null.");
auto x_dims = ctx->GetInputDim("X");
PADDLE_ENFORCE(x_dims.size() == 2 && x_dims[1] == 1,
"Input(X) of SequenceEraseOp should be a 2-D LoDTensor "

Loading…
Cancel
Save