ethnhe / FFB6D

[CVPR2021 Oral] FFB6D: A Full Flow Bidirectional Fusion Network for 6D Pose Estimation.
MIT License
295 stars 72 forks source link

normalSpeed compile error #15

Closed small-beebee closed 3 years ago

small-beebee commented 3 years ago

First of all, congratulations on your excellent work, but I encountered a compilation error when using your open source code. I hope you can help. For this, I am grateful.

root@6ff4287af8c0:/mnt/txf/codes/FFB6D/normalSpeed/normalSpeed# python setup.py install --user running install running bdist_egg running egg_info writing normalSpeed.egg-info/PKG-INFO writing dependency_links to normalSpeed.egg-info/dependency_links.txt writing top-level names to normalSpeed.egg-info/top_level.txt reading manifest file 'normalSpeed.egg-info/SOURCES.txt' writing manifest file 'normalSpeed.egg-info/SOURCES.txt' installing library code to build/bdist.linux-x86_64/egg running install_lib running build_ext CMake Deprecation Warning at CMakeLists.txt:1 (cmake_minimum_required): Compatibility with CMake < 2.8.12 will be removed from a future version of CMake.

Update the VERSION argument value or use a ... suffix to tell CMake that the project does not need compatibility with older versions.

CMake Deprecation Warning at Cmake/FindNumPy.cmake:6 (cmake_minimum_required): Compatibility with CMake < 2.8.12 will be removed from a future version of CMake.

Update the VERSION argument value or use a ... suffix to tell CMake that the project does not need compatibility with older versions. Call Stack (most recent call first): CMakeLists.txt:14 (include)

-- Configuring done -- Generating done -- Build files have been written to: /mnt/txf/codes/FFB6D/normalSpeed/normalSpeed/build/temp.linux-x86_64-3.6 [ 25%] Building CXX object CMakeFiles/normalSpeed.dir/pybind11.cpp.o [ 50%] Building CXX object CMakeFiles/normalSpeed.dir/normal.cpp.o In file included from /mnt/txf/codes/FFB6D/normalSpeed/normalSpeed/normal.cpp:1:0: /mnt/txf/codes/FFB6D/normalSpeed/normalSpeed/normal.hpp:5:28: fatal error: opencv2/rgbd.hpp: No such file or directory

include <opencv2/rgbd.hpp>

                        ^

compilation terminated. In file included from /mnt/txf/codes/FFB6D/normalSpeed/normalSpeed/pybind11.cpp:4:0: /mnt/txf/codes/FFB6D/normalSpeed/normalSpeed/normal.hpp:5:28: fatal error: opencv2/rgbd.hpp: No such file or directory

include <opencv2/rgbd.hpp>

                        ^

compilation terminated. CMakeFiles/normalSpeed.dir/build.make:75: recipe for target 'CMakeFiles/normalSpeed.dir/normal.cpp.o' failed make[2]: [CMakeFiles/normalSpeed.dir/normal.cpp.o] Error 1 make[2]: Waiting for unfinished jobs.... CMakeFiles/normalSpeed.dir/build.make:89: recipe for target 'CMakeFiles/normalSpeed.dir/pybind11.cpp.o' failed make[2]: [CMakeFiles/normalSpeed.dir/pybind11.cpp.o] Error 1 CMakeFiles/Makefile2:82: recipe for target 'CMakeFiles/normalSpeed.dir/all' failed make[1]: [CMakeFiles/normalSpeed.dir/all] Error 2 Makefile:90: recipe for target 'all' failed make: * [all] Error 2 Traceback (most recent call last): File "setup.py", line 67, in zip_safe=False, File "/usr/local/lib/python3.6/dist-packages/setuptools/init.py", line 129, in setup return distutils.core.setup(attrs) File "/usr/lib/python3.6/distutils/core.py", line 148, in setup dist.run_commands() File "/usr/lib/python3.6/distutils/dist.py", line 955, in run_commands self.run_command(cmd) File "/usr/lib/python3.6/distutils/dist.py", line 974, in run_command cmd_obj.run() File "/usr/local/lib/python3.6/dist-packages/setuptools/command/install.py", line 67, in run self.do_egg_install() File "/usr/local/lib/python3.6/dist-packages/setuptools/command/install.py", line 109, in do_egg_install self.run_command('bdist_egg') File "/usr/lib/python3.6/distutils/cmd.py", line 313, in run_command self.distribution.run_command(command) File "/usr/lib/python3.6/distutils/dist.py", line 974, in run_command cmd_obj.run() File "/usr/local/lib/python3.6/dist-packages/setuptools/command/bdist_egg.py", line 172, in run cmd = self.call_command('install_lib', warn_dir=0) File "/usr/local/lib/python3.6/dist-packages/setuptools/command/bdist_egg.py", line 158, in call_command self.run_command(cmdname) File "/usr/lib/python3.6/distutils/cmd.py", line 313, in run_command self.distribution.run_command(command) File "/usr/lib/python3.6/distutils/dist.py", line 974, in run_command cmd_obj.run() File "/usr/local/lib/python3.6/dist-packages/setuptools/command/install_lib.py", line 11, in run self.build() File "/usr/lib/python3.6/distutils/command/install_lib.py", line 109, in build self.run_command('build_ext') File "/usr/lib/python3.6/distutils/cmd.py", line 313, in run_command self.distribution.run_command(command) File "/usr/lib/python3.6/distutils/dist.py", line 974, in run_command cmd_obj.run() File "setup.py", line 33, in run self.build_extension(ext) File "setup.py", line 58, in build_extension subprocess.check_call(['cmake', '--build', '.'] + build_args, cwd=self.build_temp) File "/usr/lib/python3.6/subprocess.py", line 311, in check_call raise CalledProcessError(retcode, cmd) subprocess.CalledProcessError: Command '['cmake', '--build', '.', '--config', 'Release', '--', '-j2']' returned non-zero exit status 2.

small-beebee commented 3 years ago

I have solved this problem, after I recompile and install opencv and opencv_contrib.

small-beebee commented 3 years ago

But I have a new problem. After I have successfully compiled and installed normalSpeed0.0.1, the following error occurred when I run the program: Traceback (most recent call last): File "train_lm.py", line 33, in from utils.pvn3d_eval_utils_kpls import TorchEval File "/mnt/txf/codes/FFB6D/ffb6d/utils/pvn3d_eval_utils_kpls.py", line 10, in from utils.basic_utils import Basic_Utils File "/mnt/txf/codes/FFB6D/ffb6d/utils/basic_utils.py", line 9, in import normalSpeed ModuleNotFoundError: No module named 'normalSpeed' Is this because of the version of the dependent library or the version of normalSpeed?

small-beebee commented 3 years ago

After I uninstalled and deleted the installed normalSpeed library, re-downloading and installing normalSpeed solved the problem.

0xinit commented 3 years ago

What version of opencv have you installed? And using pip?

litleWY commented 2 months ago

What version of opencv have you installed? And using pip?

https://github.com/ethnhe/FFB6D/issues/23#issuecomment-907598982

52THANOS commented 2 months ago

After I uninstalled and deleted the installed normalSpeed library, re-downloading and installing normalSpeed solved the problem.

how did you uninstalled the library? there is no library to uninstall. i have the same problem. succeed in building but failed to import. 90179e81ac2d32778dac8d301381dc7