paddle.fluid.core.EnforceNotMet: ptr_ should not be null
Created by: liuguolian
在gpu环境执行获取embedding的脚本报错如下: Traceback (most recent call last): File "ernie_encoder.py", line 187, in main(args) File "ernie_encoder.py", line 163, in main return_numpy=False) File "/home/slurm/job/tmp/job-120971/python/lib/python2.7/site-packages/paddle/fluid/executor.py", line 470, in run self.executor.run(program.desc, scope, 0, True, True) paddle.fluid.core.EnforceNotMet: ptr_ should not be null Insufficient GPU memory to allocation. at [/paddle/paddle/fluid/framework/tensor.h:180] PaddlePaddle Call Stacks: 0 0x7f9e8e8bad06p paddle::platform::EnforceNotMet::EnforceNotMet(std::exception_ptr::exception_ptr, char const*, int) + 486 1 0x7f9e8fec262cp paddle::framework::Tensor::mutable_data(boost::variant<paddle::platform::CUDAPlace, paddle::platform::CPUPlace, paddle::platform::CUDAPinnedPlace, boost::detail::variant::void, boost::detail::variant::void, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_>, std::type_index, unsigned long) + 2428 2 0x7f9e8edc1641p paddle::operators::GPUDropoutKernel<paddle::platform::CUDADeviceContext, float>::Compute(paddle::framework::ExecutionContext const&) const + 225 3 0x7f9e8edc1cd3p std::Function_handler<void (paddle::framework::ExecutionContext const&), paddle::framework::OpKernelRegistrarFunctor<paddle::platform::CUDAPlace, false, 0ul, paddle::operators::GPUDropoutKernel<paddle::platform::CUDADeviceContext, float>, paddle::operators::GPUDropoutKernel<paddle::platform::CUDADeviceContext, paddle::platform::float16>, paddle::operators::GPUDropoutKernel<paddle::platform::CUDADeviceContext, double> >::operator()(char const*, char const*) const::{lambda(paddle::framework::ExecutionContext const&)#1}>::M_invoke(std::Any_data const&, paddle::framework::ExecutionContext const&) + 35 4 0x7f9e8fe44bbcp paddle::framework::OperatorWithKernel::RunImpl(paddle::framework::Scope const&, boost::variant<paddle::platform::CUDAPlace, paddle::platform::CPUPlace, paddle::platform::CUDAPinnedPlace, boost::detail::variant::void, boost::detail::variant::void, boost::detail::variant::void, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_> const&) const + 492 5 0x7f9e8fe413ffp paddle::framework::OperatorBase::Run(paddle::framework::Scope const&, boost::variant<paddle::platform::CUDAPlace, paddle::platform::CPUPlace, paddle::platform::CUDAPinnedPlace, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_, boost::detail::variant::void_> const&) + 463 6 0x7f9e8e9889cbp paddle::framework::Executor::RunPreparedContext(paddle::framework::ExecutorPrepareContext*, paddle::framework::Scope*, bool, bool, bool) + 219 7 0x7f9e8e989620p paddle::framework::Executor::Run(paddle::framework::ProgramDesc const&, paddle::framework::Scope*, int, bool, bool) + 128 8 0x7f9e8e89dfedp 9 0x7f9e8e8d1414p pybind11::cpp_function::dispatcher(_object*, _object*, _object*) + 2596 10 0x7f9eeffa855fp PyEval_EvalFrameEx + 29855 11 0x7f9eeffaa86dp PyEval_EvalCodeEx + 2061 12 0x7f9eeffa79fcp PyEval_EvalFrameEx + 26940 13 0x7f9eeffaa86dp PyEval_EvalCodeEx + 2061 14 0x7f9eeffa79fcp PyEval_EvalFrameEx + 26940 15 0x7f9eeffaa86dp PyEval_EvalCodeEx + 2061 16 0x7f9eeffaa9a2p PyEval_EvalCode + 50 17 0x7f9eeffd3782p PyRun_FileExFlags + 146 18 0x7f9eeffd4af9p PyRun_SimpleFileExFlags + 217 19 0x7f9eeffea82dp Py_Main + 3149 20 0x7f9eef1e7bd5p __libc_start_main + 245 21 0x4007a1p