munkres-tensorflow icon indicating copy to clipboard operation
munkres-tensorflow copied to clipboard

Some errors after compiling

Open maestrojeong opened this issue 7 years ago • 2 comments

Hey, I got success on compiling with this command as commented in https://github.com/Russell91/TensorBox/issues/60.

g++ -std=c++11 -D_GLIBCXX_USE_CXX11_ABI=0 -shared hungarian.cc -o hungarian.so -fPIC -I $TF_INC

But, the same error comes out

tensorflow.python.framework.errors_impl.NotFoundError: ./hungarian.so: undefined symbol: _ZTIN10tensorflow8OpKernelE

My spec is same as follows.

Ubuntu 16.04
tensorflow=1.4
python=3.5
gcc=5.4.0

I don't know the way to solve this. Do you have any idea?

maestrojeong avatar Jan 10 '18 13:01 maestrojeong

It seems a linking problem when executing, so maybe you have some environment variables not properly defined?

mbaradad avatar Jan 11 '18 14:01 mbaradad

using the following commands from https://www.tensorflow.org/extend/adding_an_op TF_INC=$(python -c 'import tensorflow as tf; print(tf.sysconfig.get_include())') TF_LIB=$(python -c 'import tensorflow as tf; print(tf.sysconfig.get_lib())') g++ -std=c++11 -shared hungarian.cc -o hungarian.so -fPIC -I$TF_INC -I$TF_INC/external/nsync/public -L$TF_LIB -ltensorflow_framework -O2

yifangfu avatar Jan 24 '18 04:01 yifangfu