ethz-asl / segmap

A map representation based on 3D segments
BSD 3-Clause "New" or "Revised" License
1.06k stars 394 forks source link

Build tensorflow_ros_cpp failed #133

Open killyseason opened 5 years ago

killyseason commented 5 years ago

Hello,when I build tensorflow_ros_cpp the error is: segmap_ws catkin build tensorflow_ros_cpp --cmake-args -DFORCE_TF_PIP_SEARCH="ON" \ -DTF_PYTHON_VERSION="python2.7" \
-DTF_PIP_PATH="$HOME/segmappyenv/lib/python2.7/site-packages/tensorflow" \ -DTF_PIP_EXECUTABLE="$HOME/segmappyenv/bin/pip" \ -DTF_PYTHON_LIBRARY="/usr/lib/x86_64-linux-gnu/libpython2.7.so"

Profile: default Extending: [cached] /home/sariel/loam_kitti/devel:/home/sariel/catkin_velodyne/devel:/home/sariel/lego_loam/devel:/home/sariel/loam/devel:/opt/ros/kinetic Workspace: /home/sariel/segmap_ws

Source Space: [exists] /home/sariel/segmap_ws/src Log Space: [exists] /home/sariel/segmap_ws/logs Build Space: [exists] /home/sariel/segmap_ws/build Devel Space: [exists] /home/sariel/segmap_ws/devel Install Space: [unused] /home/sariel/segmap_ws/install DESTDIR: [unused] None

Devel Space Layout: merged Install Space Layout: None

Additional CMake Args: -DCMAKE_BUILD_TYPE=Debug -DFORCE_TF_PIP_SEARCH=ON -DTF_PYTHON_VERSION=python2.7 -DTF_PIP_PATH=/home/sariel/segmappyenv/lib/python2.7/site-packages/tensorflow -DTF_PIP_EXECUTABLE=/home/sariel/segmappyenv/bin/pip -DTF_PYTHON_LIBRARY=/usr/lib/x86_64-linux-gnu/libpython2.7.so Additional Make Args: None Additional catkin Make Args: None Internal Make Job Server: True Cache Job Environments: False

Whitelisted Packages: None Blacklisted Packages: None

Workspace configuration appears valid.

NOTE: Forcing CMake to run for each package.

[build] Found '31' packages in 0.0 seconds.
[build] Package table is up to date.
Starting >>> tensorflow_ros_cpp


Warnings << tensorflow_ros_cpp:cmake /home/sariel/segmap_ws/logs/tensorflow_ros_cpp/build.cmake.003.log -- tensorflow_ros_cpp is probing the system -- - The system uses C++11 ABI, the use of tensorflow from pip is possible, but problematic; consider compiling tensorflow yourself -- - Trying to find Tensorflow installed by pip -- -- Found user-specified tensorflow pip directory: /home/sariel/segmappyenv/lib/python2.7/site-packages/tensorflow -- -- Using Tensorflow library /home/sariel/segmappyenv/lib/python2.7/site-packages/tensorflow/python/_pywrap_tensorflow_internal.so -- -- Created tensorflow library link /home/sariel/segmappyenv/lib/python2.7/site-packages/tensorflow/python/_pywrap_tensorflow_internal.so -> /home/sariel/segmap_ws/devel/lib/lib_pywrap_tensorflow.so. -- -- Created tensorflow library link /home/sariel/segmappyenv/lib/python2.7/site-packages/tensorflow/python/_pywrap_tensorflow_internal.so -> /home/sariel/segmap_ws/devel/lib/_pywrap_tensorflow_internal.so. -- -- The Tensorflow library is compiled with CUDA support. -- -- Created tensorflow library link /home/sariel/segmappyenv/lib/python2.7/site-packages/tensorflow/libtensorflow_framework.so -> /home/sariel/segmap_ws/devel/lib/libtensorflow_framework.so. -- -- Using Pythonpython2.7 development library from /usr/lib/x86_64-linux-gnu/libpython2.7.so CMake Warning at /home/sariel/segmap_ws/src/tensorflow_ros_cpp/cmake/detect_tf_pip.cmake:211 (message): -- -- Tensorflow library and system C++ ABI differ. You should consider building Tensorflow yourself. In case you still want to use the python TF library, itcan only be used from targets that do not link to any system libraries that have a C++ API (e.g. a method with std::string argument). Your library using Tensorflow must expose all methods using a C API, or a limited C++ API with only primitive data types (numerics, arrays, chars, but not std::vectors or std::strings). See the kinetic-devel branch of github.com/tradr-project/tensorflow_ros_test for an example. Call Stack (most recent call first): CMakeLists.txt:69 (include)

-- - Trying to find Tensorflow compiled by bazel CMake Warning at /home/sariel/segmap_ws/src/tensorflow_ros_cpp/cmake/detect_tf_bazel.cmake:21 (message): Bazel-compiled Tensorflow library /home/sariel/tensorflow/bazel-bin/tensorflow/libtensorflow_cc.so not found. Call Stack (most recent call first): CMakeLists.txt:89 (include)

-- - Not searching for Tensorflow from tensorflow_catkin since Tensorflow has already been found. Set FORCE_TF_CATKIN_SEARCH to force the search. -- Using Tensorflow library found by pip -- The found Tensorflow library uses C++03 ABI. -- The found Tensorflow library is compiled with CUDA support. cd /home/sariel/segmap_ws/build/tensorflow_ros_cpp; catkin build --get-env tensorflow_ros_cpp | catkin env -si /home/sariel/cmake-3.9.1-Linux-x86_64/bin/cmake /home/sariel/segmap_ws/src/tensorflow_ros_cpp --no-warn-unused-cli -DCATKIN_DEVEL_PREFIX=/home/sariel/segmap_ws/devel -DCMAKE_INSTALL_PREFIX=/home/sariel/segmap_ws/install -DCMAKE_BUILD_TYPE=Debug -DFORCE_TF_PIP_SEARCH=ON -DTF_PYTHON_VERSION=python2.7 -DTF_PIP_PATH=/home/sariel/segmappyenv/lib/python2.7/site-packages/tensorflow -DTF_PIP_EXECUTABLE=/home/sariel/segmappyenv/bin/pip -DTF_PYTHON_LIBRARY=/usr/lib/x86_64-linux-gnu/libpython2.7.so; cd - ............................................................................... Finished <<< tensorflow_ros_cpp [ 0.7 seconds ]
[build] Summary: All 1 packages succeeded!
[build] Ignored: 30 packages were skipped or are blacklisted.
[build] Warnings: 1 packages succeeded with warnings.
[build] Abandoned: None.
[build] Failed: None.
[build] Runtime: 0.8 seconds total.

I have tried the FAQ method ,but also failed. The first time I install the tensorflow 1.8.0 and it succeed,but the segmapper can't build,so I install tensorflow 1.9.0 but also failed.Then I re-install the tensorflow 1.8.0 and the problem is as above.What can I do? Thanks in advance.

shenyanqing1105 commented 3 years ago

You install tensorflow 1.8.0 by pip or source code?