Pixel2Mesh icon indicating copy to clipboard operation
Pixel2Mesh copied to clipboard

undefined symbol: _ZTIN10tensorflow8OpKernelE_

Open thanhkien84 opened this issue 6 years ago • 3 comments

While running the demo code: python demo.py --image utils/examples/plane.png

I got this error: Traceback (most recent call last): File "demo.py", line 3, in from pixel2mesh.models import GCN File "build/bdist.linux-x86_64/egg/pixel2mesh/models.py", line 3, in from pixel2mesh.losses import * File "build/bdist.linux-x86_64/egg/pixel2mesh/losses.py", line 2, in from pixel2mesh.cd_dist import * File "build/bdist.linux-x86_64/egg/pixel2mesh/cd_dist.py", line 3, in nn_distance_module=tf.load_op_library('./external/tf_nndistance_so.so') File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/framework/load_library.py", line 60, in load_op_library lib_handle = py_tf.TF_LoadLibrary(library_filename) tensorflow.python.framework.errors_impl.NotFoundError: ./external/tf_nndistance_so.so: undefined symbol: _ZTIN10tensorflow8OpKernelE

Does anyone experience this? My specs: Ubuntu 18.04, CUDA 10.0, CuDNN 7.4, Tensorflow 1.12, OpenCV 3.4.3.

thanhkien84 avatar Nov 26 '18 05:11 thanhkien84

You can refer to this URL:https://www.cnblogs.com/danpe/p/7825357.html, Because the TF_LIB compilation parameter is missing from the makefile,You should modify this file, I add TF_LIB =/usr/local/lib/python2.7/dist-packages/tensorflow I modify :tf_nndistance_so.so: tf_nndistance_g.cu.o tf_nndistance.cpp g++ -std=c++11 tf_nndistance.cpp tf_nndistance_g.cu.o -o tf_nndistance_so.so -shared -fPIC -I $(tensorflow) -lcudart -L $(cudalib) -O2 -L $(TF_LIB) -ltensorflow_framework -D_GLIBCXX_USE_CXX11_ABI=0

rubilin avatar Nov 30 '18 05:11 rubilin

I made the above change and still get the same error. Did anyone find a fix?

nitthilan avatar Jan 19 '19 01:01 nitthilan

I made the above change and still get the same error. Did anyone find a fix?

did you install tensorflow with conda? if so, try to create a new env and install tf with pip, then this issue shall be fixed

hguomin avatar Jan 27 '19 08:01 hguomin