Set lod level of sequence_unpad's output to 1 in compile time (#20068)

* Set lod level of sequence_unpad's output to 1 in compile time
fix-python-transpose
Li Fuchen 6 years ago committed by GitHub
parent 425279a57b
commit 5365cd2f14
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -57,6 +57,11 @@ class SequenceUnpadOp : public framework::OperatorWithKernel {
}
}
ctx->SetOutputDim("Out", framework::make_ddim(out_dims_vec));
if (!ctx->IsRuntime()) {
framework::VarDesc* out_desc =
boost::get<framework::VarDesc*>(ctx->GetOutputVarPtrs("Out")[0]);
out_desc->SetLoDLevel(1);
}
}
protected:

Loading…
Cancel
Save