-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
tf-head: Fix undefined symbols by linking libtensorflow_cc.so.2 #3755
Conversation
This fixes the problem for me. Verified locally: $ pip install -U tf-nightly-cpu==2.12.0.dev20221024
$ pip install -U git+https://github.com/horovod/horovod.git@refs/pull/3755/head
$ python -c 'import horovod.tensorflow' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for keeping HEADs green, LGTM!
New packages
https://buildkite.com/horovod/horovod/builds/8583#01840f11-bd37-4c4e-a85f-4ef0e12838d9 |
(I verified locally that this still works with |
I am not sure if we should keep this while head version does not require this. We do not intent to support head versions older than today (head of head only if you will). |
@@ -25,6 +25,11 @@ if (LEN EQUAL "4") | |||
if (Tensorflow_VERSION VERSION_GREATER_EQUAL "2.6") | |||
# XLA implementations and helpers for resource variables are in _pywrap_tensorflow_internal.so | |||
set(Tensorflow_LIBRARIES "${Tensorflow_LIBRARIES} ${Tensorflow_LIB_PATH}/python/_pywrap_tensorflow_internal.so") | |||
set(lib_tensorflow_cc_so_path "${Tensorflow_LIB_PATH}/libtensorflow_cc.so.2") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what does the .2
stand for?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I hope that stands for TensorFlow 2.x, but I have not dived into the build system to confirm. The main library in that path is libtensorflow_framework.so.2
. We get the latter via tf.sysconfig.get_link_flags()
, but I couldn't find an API to resolve the new libtensorflow_cc.so.2
.
Agreed. We can always merge this after the rollback of that TensorFlow PR is reverted (comments in tensorflow/tensorflow#55941). |
The TF refactoring that motivated the fix in this PR appears to be active again: tensorflow/tensorflow#58734 Presumably Horovod CI will soon fail for tf-head again. Then we should rebase this PR to master, and confirm that it fixes the problem. |
Signed-off-by: Max H. Gerlach <git@maxgerlach.de>
Signed-off-by: Max H. Gerlach <git@maxgerlach.de>
2968c27
to
241ff9a
Compare
Undefined symbol errors returned to master for tf-head:
https://github.com/horovod/horovod/actions/runs/3650378067/jobs/6171827788 |
OK, this PR still fixes the unknown symbols errors. There's another problem with tf-head / Keras though (edit: tracked at #3795). I'd suggest to merge this PR and address the other problem separately.
|
Checklist before submitting
Description
Fixes #3754
For context see tensorflow/tensorflow#58281
Review process to land