-
Notifications
You must be signed in to change notification settings - Fork 416
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Undefined symbol: _ZTIN10tensorflow8OpKernelE #108
Comments
tensorflow/tensorflow#13607 |
I encountered exactly this error too. |
I have downloaded roi_pooling.so from https://github.com/CharlesShang/TFFRCNN/blob/roi_pooling/lib/roi_pooling_layer/roi_pooling.so and replaced my compiled roi_pooling.so according to @CharlesShang . |
I finally downgraded tensorflow from 1.4 to 1.3 and added |
where to add -D_GLIBCXX_USE_CXX11_ABI=0? `#!/usr/bin/env bash CUDA_PATH=/usr/local/cuda/ cd roi_pooling_layer nvcc -std=c++11 -c -o roi_pooling_op.cu.o roi_pooling_op_gpu.cu.cc if you install tf using already-built binary, or gcc version 4.x, uncomment the two lines below#g++ -std=c++11 -shared -D_GLIBCXX_USE_CXX11_ABI=0 -o roi_pooling.so roi_pooling_op.cc \ roi_pooling_op.cu.o -I $TF_INC -fPIC -lcudart -L $CUDA_PATH/lib64for gcc5-built tfg++ -std=c++11 -shared -o roi_pooling.so roi_pooling_op.cc add building psroi_pooling layercd psroi_pooling_layer g++ -std=c++11 -shared -o psroi_pooling.so psroi_pooling_op.cc if you install tf using already-built binary, or gcc version 4.x, uncomment the two lines below#g++ -std=c++11 -shared -D_GLIBCXX_USE_CXX11_ABI=0 -o psroi_pooling.so psroi_pooling_op.cc \ psroi_pooling_op.cu.o -I $TF_INC -fPIC -lcudart -L $CUDA_PATH/lib64cd ..` |
I don't know which places need to be annotated, and those places need to be modified.please help me @Kongsea |
Downgrade your tensorflow to r1.3. Try to modify this line to
|
It doesn't have to downgrade to 1.3. I am using 1.4 with gcc 5.4. |
@selinachenxi TF_INC=$(python -c 'import tensorflow as tf; print(tf.sysconfig.get_include())') #adding by zw TF_INC=$(python -c 'import tensorflow as tf; print(tf.sysconfig.get_include())') #adding by zw CUDA_PATH=/usr/local/cuda/ if [[ "$OSTYPE" =~ ^darwin ]]; then cd roi_pooling_layer if [ -d "$CUDA_PATH" ]; then
else cd .. |
This bash works:
|
I had similar problem because of namespace. I changed my "new_op.cu.cc" from
to
and it is fixed. |
THX so much |
hi, where is this file? i cannot find it. |
I ran into similar issue, the problem was I manually compiled TF and tries to load another TF operator library. The problem is due two the two E.g.,
|
Adding this linking option works for me: Reference: https://stackoverflow.com/questions/48189818/undefined-symbol-ztin10tensorflow8opkernele |
I just avoid this issue in change version of g++, gcc, TF, and CUDA. Ubuntu 18.04.5 LTS And "-D_GLIBCXX_USE_CXX11_ABI=0" in the "tf_xxxx_complie.sh" should be deleted |
My current environment is |
@Brunda02 : List: And "-D_GLIBCXX_USE_CXX11_ABI=0" in the "tf_xxxx_complie.sh" should be deleted |
@FeiDao7943 what is tf_xxxx_complie.sh? |
@Brunda02 tf_xxxx_complie.sh total 3 files. In location: And "-D_GLIBCXX_USE_CXX11_ABI=0" in the |
Hi, I am running the master trunk and encounter the error when do training. Could anyone help on this? Thanks.
File "./faster_rcnn/../lib/roi_pooling_layer/roi_pooling_op.py", line 5, in
_roi_pooling_module = tf.load_op_library(filename)
File "/usr/local/anaconda2/lib/python2.7/site-packages/tensorflow/python/framework/load_library.py", line 56, in load_op_library
lib_handle = py_tf.TF_LoadLibrary(library_filename, status)
File "/usr/local/anaconda2/lib/python2.7/site-packages/tensorflow/python/framework/errors_impl.py", line 473, in exit
c_api.TF_GetCode(self.status.status))
tensorflow.python.framework.errors_impl.NotFoundError: ./faster_rcnn/../lib/roi_pooling_layer/roi_pooling.so: undefined symbol: _ZTIN10tensorflow8OpKernelE
The ./lib/make.sh is as following:
!/usr/bin/env bash
TF_INC=$(python -c 'import tensorflow as tf; print(tf.sysconfig.get_include())')
echo $TF_INC
CUDA_PATH=/usr/local/cuda-8.0/
cd roi_pooling_layer
nvcc -std=c++11 -c -o roi_pooling_op.cu.o roi_pooling_op_gpu.cu.cc
-I $TF_INC -D GOOGLE_CUDA=1 -x cu -Xcompiler -fPIC -arch=sm_60
if you install tf using already-built binary, or gcc version 4.x, uncomment the two lines below
g++ -std=c++11 -shared -D_GLIBCXX_USE_CXX11_ABI=0 -o roi_pooling.so roi_pooling_op.cc
roi_pooling_op.cu.o -I $TF_INC -fPIC -lcudart -L $CUDA_PATH/lib64
for gcc5-built tf
#g++ -std=c++11 -shared -D_GLIBCXX_USE_CXX11_ABI=1 -o roi_pooling.so roi_pooling_op.cc \
roi_pooling_op.cu.o -I $TF_INC -fPIC -lcudart -L $CUDA_PATH/lib64
cd ..
add building psroi_pooling layer
cd psroi_pooling_layer
nvcc -std=c++11 -c -o psroi_pooling_op.cu.o psroi_pooling_op_gpu.cu.cc
-I $TF_INC -D GOOGLE_CUDA=1 -x cu -Xcompiler -fPIC -arch=sm_60
#g++ -std=c++11 -shared -o psroi_pooling.so psroi_pooling_op.cc \
psroi_pooling_op.cu.o -I $TF_INC -fPIC -lcudart -L $CUDA_PATH/lib64
if you install tf using already-built binary, or gcc version 4.x, uncomment the two lines below
g++ -std=c++11 -shared -D_GLIBCXX_USE_CXX11_ABI=0 -o psroi_pooling.so psroi_pooling_op.cc
psroi_pooling_op.cu.o -I $TF_INC -fPIC -lcudart -L $CUDA_PATH/lib64
cd ..
The text was updated successfully, but these errors were encountered: