Error while using python layer

149 views
Skip to first unread message

Xin Guo

unread,
Mar 24, 2017, 9:33:32 PM3/24/17
to Caffe Users
Hi, guys,

I would really appreciate it if someone can help. I built a python layer and used it as a module in my prototxt file. I can make sure there is no problem with my prototxt and python layer file because it worked fine on my old computer with Ubuntu 14 + cuda 7.5 + anaconda2. However, it has the following error while running on my new computer with Ubuntu 16 + cuda8 + defaulted python. All the caffe make all, make runtest works fine on my new computer, even extracting features from a pretrained caffemodel using python file works perfect. 

I0324 21:18:29.194118  7581 net.cpp:367] bn1 -> ip1 (in-place)
I0324
21:18:29.194247  7581 net.cpp:122] Setting up bn1
I0324
21:18:29.194252  7581 net.cpp:129] Top shape: 64 500 (32000)
I0324
21:18:29.194253  7581 net.cpp:137] Memory required for data: 5167360
I0324
21:18:29.194260  7581 layer_factory.hpp:77] Creating layer relu_sqrt_1
*** Aborted at 1490404709 (unix time) try "date -d @1490404709" if you are using GNU date ***
PC
: @     0x7f9409650873 std::_Hashtable<>::clear()
*** SIGSEGV (@0x9) received by PID 7581 (TID 0x7f943bad5ac0) from PID 9; stack trace: ***
   
@     0x7f9438d274b0 (unknown)
   
@     0x7f9409650873 std::_Hashtable<>::clear()
   
@     0x7f9409642346 google::protobuf::DescriptorPool::FindFileByName()
   
@     0x7f9409620ac8 google::protobuf::python::cdescriptor_pool::AddSerializedFile()
   
@     0x7f94393907d0 PyEval_EvalFrameEx
   
@     0x7f94394b901c PyEval_EvalCodeEx
   
@     0x7f943940f3dd (unknown)
   
@     0x7f94393e21e3 PyObject_Call
   
@     0x7f9439402ae5 (unknown)
   
@     0x7f9439399123 (unknown)
   
@     0x7f94393e21e3 PyObject_Call
   
@     0x7f943938d13c PyEval_EvalFrameEx
   
@     0x7f94394b901c PyEval_EvalCodeEx
   
@     0x7f9439387b89 PyEval_EvalCode
   
@     0x7f943941c1b4 PyImport_ExecCodeModuleEx
   
@     0x7f943941cb8f (unknown)
   
@     0x7f943941e300 (unknown)
   
@     0x7f943941e5c8 (unknown)
   
@     0x7f943941f6db PyImport_ImportModuleLevel
   
@     0x7f9439396698 (unknown)
   
@     0x7f94393e21e3 PyObject_Call
   
@     0x7f94394b8447 PyEval_CallObjectWithKeywords
   
@     0x7f943938b5c6 PyEval_EvalFrameEx
   
@     0x7f94394b901c PyEval_EvalCodeEx
   
@     0x7f9439387b89 PyEval_EvalCode
   
@     0x7f943941c1b4 PyImport_ExecCodeModuleEx
   
@     0x7f943941cb8f (unknown)
   
@     0x7f943941e300 (unknown)
   
@     0x7f943941e5c8 (unknown)
   
@     0x7f943941f6db PyImport_ImportModuleLevel
   
@     0x7f9439396698 (unknown)
   
@     0x7f94393e21e3 PyObject_Call
Done.

I tried to use cmake to build caffe and also tied to use Anaconda, but still has this problem. I am guess it's not about caffe itself, it's probably because protobuf. I have tried protobuf 2.6.1 which is the version of using 'apt-get install protobuf-compiler', I have also tried protobuf 3.2.0, which is the current version available, but I still got this problem. Does anything have an idea? Thanks a lot for the help.

Best,
Cindy

Xin Guo

unread,
Mar 24, 2017, 10:37:32 PM3/24/17
to Caffe Users
I got help from nbarriga and now problem is solved,  please check the link if someone has the same 

Reply all
Reply to author
Forward
0 new messages