You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Traceback (most recent call last):
File "run_ernie_classifier.py", line 402, in
main(args)
File "run_ernie_classifier.py", line 303, in main
main_program=test_prog)
File "/data/yuting/models-release-1.7/PaddleNLP/emotion_detection/utils.py", line 37, in init_checkpoint
fluid.load(main_program, init_checkpoint_path, exe)
File "/home/ant/.conda/envs/text_analysis/lib/python3.6/site-packages/paddle/fluid/io.py", line 1779, in load
optimizer_var_list, global_scope(), executor._default_executor)
paddle.fluid.core_avx.EnforceNotMet:
Error: When calling this method, the Tensor's numel must be equal or larger than zero. Please check Tensor::dims, or Tenso
r::Resize has been called first. The Tensor's shape is [-1, 768] now [Hint: Expected numel() >= 0, but received numel():-768 < 0:0.] at (/paddle/paddle/fluid/framework/tensor.cc:45)
The text was updated successfully, but these errors were encountered:
将开源ernie模型进行sh run_ernie train微调,源码报错,这个修改了ernie函数中的fluid.data,改成fluid.layers.data就能成功进行train。可在进行sh run_ernie.sh infer时,出现如下错误,这个是哪里有问题呢
Traceback (most recent call last):
File "run_ernie_classifier.py", line 402, in
main(args)
File "run_ernie_classifier.py", line 303, in main
main_program=test_prog)
File "/data/yuting/models-release-1.7/PaddleNLP/emotion_detection/utils.py", line 37, in init_checkpoint
fluid.load(main_program, init_checkpoint_path, exe)
File "/home/ant/.conda/envs/text_analysis/lib/python3.6/site-packages/paddle/fluid/io.py", line 1779, in load
optimizer_var_list, global_scope(), executor._default_executor)
paddle.fluid.core_avx.EnforceNotMet:
C++ Call Stacks (More useful to developers):
0 std::string paddle::platform::GetTraceBackString<std::string const&>(std::string const&, char const*, int)
1 paddle::platform::EnforceNotMet::EnforceNotMet(std::string const&, char const*, int)
2 paddle::framework::Tensor::mutable_data(paddle::platform::Place const&, paddle::framework::proto::VarType_Type, unsign
ed long)
Error Message Summary:
Error: When calling this method, the Tensor's numel must be equal or larger than zero. Please check Tensor::dims, or Tenso
r::Resize has been called first. The Tensor's shape is [-1, 768] now [Hint: Expected numel() >= 0, but received numel():-768 < 0:0.] at (/paddle/paddle/fluid/framework/tensor.cc:45)
The text was updated successfully, but these errors were encountered: