Skip to content
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

Problem with Makefile #8

Open
Firyuza opened this issue Mar 23, 2018 · 12 comments
Open

Problem with Makefile #8

Firyuza opened this issue Mar 23, 2018 · 12 comments

Comments

@Firyuza
Copy link

Firyuza commented Mar 23, 2018

Hello!
I did make and in terminal I just saw the warnings, no errors. But when I tried to debug train.py I get such error:
tensorflow.python.framework.errors_impl.NotFoundError: ~/nms_net/roi_pooling_layer/roi_pooling.so: undefined symbol: _ZN10tensorflow7strings6StrCatB5cxx11ERKNS0_8AlphaNumE

Thanks!

@Firyuza Firyuza changed the title Problem with MakeFile Problem with Makefile Mar 23, 2018
@hosang
Copy link
Owner

hosang commented Mar 24, 2018

Sounds like you have linking problems. Can you double check you're linking to the tensorflow you're running it in?

@Firyuza
Copy link
Author

Firyuza commented Mar 24, 2018

I changed this variable TF_INC="/home/firiuza/anaconda3/envs/yad2k/lib/python3.6/site-packages/tensorflow/include" in Makefile. So I think I have the right link.

Thanks!

@EkaterinaPogodina
Copy link

@Firyuza Did you fix the problem?

@Firyuza
Copy link
Author

Firyuza commented May 14, 2018

@EkaterinaPogodina Unfortunately, I couldn't fix it. But I converted this C++ code that requires build into Tensorflow.

@hosang
Copy link
Owner

hosang commented May 28, 2018

You did the matching with tf ops? Sounds great! Can you share that?

@gudovskiy
Copy link

I had to compile roi pooling layer with "-D_GLIBCXX_USE_CXX11_ABI=0" parameter due to GCC version >= 5 to avoid this issue.

@Firyuza
Copy link
Author

Firyuza commented Jun 4, 2018

@hosang I'm not sure that I did right conversion, but I tested it and it works. Hope you will understand my code, because it's not so easy to read :(

matching loss

find the ground truth box for each detection that has maximum IoU

max_ious = tf.reduce_max(self.det_anno_iou, axis=1)
iou_threshold = tf.fill(tf.shape(max_ious), 0.5)

add extra item at the end of tensor for labels and weights

gt_crowd_added = tf.concat([tf.expand_dims(self.gt_crowd, 1), tf.expand_dims([tf.constant(False)], 1)],
                           axis=0)
gt_crowd_added = tf.reshape(gt_crowd_added, [-1])

save indices of ground truth that match to detections

no_matched =  tf.fill(tf.shape(max_ious), tf.constant(-1, dtype=tf.int64))
self.det_gt_matching = tf.where(tf.greater(max_ious, iou_threshold),
                                tf.argmax(self.det_anno_iou, axis=1),
                                no_matched)

add extra item at the end of tensor for labels and weights

extra_ids = tf.fill(tf.shape(max_ious),
                                         tf.cast(tf.shape(self.gt_crowd)[0], dtype=tf.int64))
det_gt_matching_added = tf.where(tf.greater(max_ious, iou_threshold),
                                 tf.argmax(self.det_anno_iou, axis=1),
                                 extra_ids)
self.labels = tf.where(tf.not_equal(det_gt_matching_added, extra_ids),
                       tf.ones_like(max_ious, dtype=tf.float32),
                       tf.zeros_like(max_ious, dtype=tf.float32))
self.weights = tf.where(tf.gather(gt_crowd_added, det_gt_matching_added),
                        tf.zeros_like(max_ious),
                        tf.ones_like(max_ious))

@AshStuff
Copy link

@hosang is there any dependency on the Tensorflow version ?

@amsword
Copy link

amsword commented Dec 16, 2018

I use the following tf version, which fixes a lot of issues. FYI.
pip install tensorflow-gpu==0.12.1

@symechar
Copy link

@hosang I also have the same error. Is there any dependency on the Tensorflow version?

@SchroeterJulien
Copy link

If it is of any help, here is what worked for me (TensorFlow 1.14) Issue #12 .

@UpCoder
Copy link

UpCoder commented Aug 17, 2020

@SchroeterJulien Please see #14, I successfully run the code (TF 1.12.0)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants