fix paddle enforce check

enforce_failed
wanghaoshuang 8 years ago
parent a03c6849e7
commit 355e35fecd

@ -95,7 +95,6 @@ class PadOpGrad : public framework::OperatorWithKernel {
"Input(Out@GRAD) should not be null"); "Input(Out@GRAD) should not be null");
auto x_dims = ctx.Input<Tensor>("X")->dims(); auto x_dims = ctx.Input<Tensor>("X")->dims();
auto *x_grad = ctx.Output<Tensor>(framework::GradVarName("X")); auto *x_grad = ctx.Output<Tensor>(framework::GradVarName("X"));
PADDLE_ENFORCE_NOT_NULL(x_grad, "Output(X@GRAD) should not be null");
x_grad->Resize(x_dims); x_grad->Resize(x_dims);
} }

Loading…
Cancel
Save