Closed dlbolshov closed 1 year ago
Hi, your installation was indeed probably not successful. Can you please give the entire output of install.sh?
I am also having the same issue. After trying to run the bash install script on I get the following output:
Looking in indexes: https://pypi.org/simple, https://us-python.pkg.dev/colab-wheels/public/simple/
Requirement already satisfied: pyyaml in /usr/local/lib/python3.8/dist-packages (from -r requirements.txt (line 1)) (6.0)
Collecting torch==1.10.1
Downloading torch-1.10.1-cp38-cp38-manylinux1_x86_64.whl (881.9 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╸ 881.9/881.9 MB 120.7 MB/s eta 0:00:01tcmalloc: large alloc 1102397440 bytes == 0x36f0c000 @ 0x7fbc2fb09615 0x5d6f4c 0x51edd1 0x51ef5b 0x4f750a 0x4997a2 0x55cd91 0x5d8941 0x4997a2 0x55cd91 0x5d8941 0x4997a2 0x55cd91 0x5d8941 0x4997a2 0x55cd91 0x5d8941 0x4997a2 0x55cd91 0x5d8941 0x4997a2 0x5d8868 0x4997a2 0x55cd91 0x5d8941 0x49abe4 0x55cd91 0x5d8941 0x4997a2 0x55cd91 0x5d8941
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 881.9/881.9 MB 1.9 MB/s eta 0:00:00
Collecting torchvision==0.11.2
Downloading torchvision-0.11.2-cp38-cp38-manylinux1_x86_64.whl (23.3 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 23.3/23.3 MB 56.9 MB/s eta 0:00:00
Requirement already satisfied: numpy in /usr/local/lib/python3.8/dist-packages (from -r requirements.txt (line 4)) (1.21.6)
Requirement already satisfied: matplotlib in /usr/local/lib/python3.8/dist-packages (from -r requirements.txt (line 5)) (3.2.2)
Collecting brewer2mpl
Downloading brewer2mpl-1.4.1-py2.py3-none-any.whl (24 kB)
ERROR: Could not find a version that satisfies the requirement opencv-python==4.0.1.23 (from versions: 3.4.0.14, 3.4.8.29, 3.4.9.31, 3.4.9.33, 3.4.10.35, 3.4.10.37, 3.4.11.39, 3.4.11.41, 3.4.11.43, 3.4.11.45, 3.4.13.47, 3.4.14.51, 3.4.14.53, 3.4.15.55, 3.4.16.57, 3.4.16.59, 3.4.17.61, 3.4.17.63, 3.4.18.65, 4.1.2.30, 4.2.0.32, 4.2.0.34, 4.3.0.36, 4.3.0.38, 4.4.0.40, 4.4.0.42, 4.4.0.44, 4.4.0.46, 4.5.1.48, 4.5.2.52, 4.5.2.54, 4.5.3.56, 4.5.4.58, 4.5.4.60, 4.5.5.62, 4.5.5.64, 4.6.0.66, 4.7.0.68)
ERROR: No matching distribution found for opencv-python==4.0.1.23
install.sh: line 2: cd: third_party/progressive-x/graph-cut-ransac/build: No such file or directory
CMake Error: The source directory "/content/drive/MyDrive" does not appear to contain CMakeLists.txt.
Specify --help for usage, or press the help button on the CMake GUI.
make: *** No targets specified and no makefile found. Stop.
install.sh: line 3: cd: third_party/progressive-x/build: No such file or directory
CMake Error: The source directory "/" does not appear to contain CMakeLists.txt.
Specify --help for usage, or press the help button on the CMake GUI.
make: *** No targets specified and no makefile found. Stop.
ERROR: third_party/progressive-x is not a valid editable requirement. It should either be a path to a local project or a VCS URL (beginning with bzr+http, bzr+https, bzr+ssh, bzr+sftp, bzr+ftp, bzr+lp, bzr+file, git+http, git+https, git+ssh, git+git, git+file, hg+file, hg+http, hg+https, hg+ssh, hg+static-http, svn+ssh, svn+http, svn+https, svn+svn, svn+file).
install.sh: line 5: cd: third_party/afm_lib/afm_op: No such file or directory
python3: can't open file 'setup.py': [Errno 2] No such file or directory
Looking in indexes: https://pypi.org/simple, https://us-python.pkg.dev/colab-wheels/public/simple/
Obtaining file:///
ERROR: file:/// does not appear to be a Python project: neither 'setup.py' nor 'pyproject.toml' found.
ERROR: line_refinement is not a valid editable requirement. It should either be a path to a local project or a VCS URL (beginning with bzr+http, bzr+https, bzr+ssh, bzr+sftp, bzr+ftp, bzr+lp, bzr+file, git+http, git+https, git+ssh, git+git, git+file, hg+file, hg+http, hg+https, hg+ssh, hg+static-http, svn+ssh, svn+http, svn+https, svn+svn, svn+file).
ERROR: third_party/homography_est is not a valid editable requirement. It should either be a path to a local project or a VCS URL (beginning with bzr+http, bzr+https, bzr+ssh, bzr+sftp, bzr+ftp, bzr+lp, bzr+file, git+http, git+https, git+ssh, git+git, git+file, hg+file, hg+http, hg+https, hg+ssh, hg+static-http, svn+ssh, svn+http, svn+https, svn+svn, svn+file).
Looking in indexes: https://pypi.org/simple, https://us-python.pkg.dev/colab-wheels/public/simple/
Obtaining file:///
ERROR: file:/// does not appear to be a Python project: neither 'setup.py' nor 'pyproject.toml' found.
And importing line_optim is failing as follows:
[/content/drive/MyDrive/DeepLSD/deeplsd/models/deeplsd.py](https://localhost:8080/#) in <module>
15 from ..utils.tensor import preprocess_angle
16 from pytlsd import lsd
---> 17 from line_refinement import line_optim
18
19
ImportError: cannot import name 'line_optim' from 'line_refinement' (unknown location)
I suppose you did not install the submodules as specified in the ReadMe: git clone --recurse-submodules git@github.com:cvg/DeepLSD.git
I also pushed a small fix for opencv, because the specific version "4.0.1.23" is actually not necessary I think. Hopefully it should work better for you now.
Yep, you're right I missed that line. However now that I am running it, I get the following error:
!git clone --recurse-submodules git@github.com:cvg/DeepLSD.git
Cloning into 'DeepLSD'...
Host key verification failed.
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
Is this an issue on my end ?
Are you using SSH to connect to a Github repo? Is your SSH key correct? Because the repo is public, so you should have the correct access rights...
Otherwise, you can also try to clone with https: git clone --recurse-submodules https://github.com/cvg/DeepLSD.git
I already tried that to be honest. It gave the following output
Cloning into 'DeepLSD'...
remote: Enumerating objects: 113, done.
remote: Counting objects: 100% (113/113), done.
remote: Compressing objects: 100% (93/93), done.
remote: Total 113 (delta 22), reused 100 (delta 16), pack-reused 0
Receiving objects: 100% (113/113), 7.10 MiB | 4.99 MiB/s, done.
Resolving deltas: 100% (22/22), done.
Submodule 'line_refinement/pybind11' ([git@github.com](mailto:git@github.com):pybind/pybind11.git) registered for path 'line_refinement/pybind11'
Submodule 'third_party/homography_est' ([git@github.com](mailto:git@github.com):rpautrat/homography_est.git) registered for path 'third_party/homography_est'
Submodule 'third_party/progressive-x' ([git@github.com](mailto:git@github.com):danini/progressive-x.git) registered for path 'third_party/progressive-x'
Submodule 'third_party/pytlbd' ([git@github.com](mailto:git@github.com):iago-suarez/pytlbd.git) registered for path 'third_party/pytlbd'
Submodule 'third_party/pytlsd' ([git@github.com](mailto:git@github.com):rpautrat/pytlsd.git) registered for path 'third_party/pytlsd'
Cloning into '/content/DeepLSD/line_refinement/pybind11'...
Host key verification failed.
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
fatal: clone of '[git@github.com](mailto:git@github.com):pybind/pybind11.git' into submodule path '/content/DeepLSD/line_refinement/pybind11' failed
Failed to clone 'line_refinement/pybind11'. Retry scheduled
Cloning into '/content/DeepLSD/third_party/homography_est'...
Host key verification failed.
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
fatal: clone of '[git@github.com](mailto:git@github.com):rpautrat/homography_est.git' into submodule path '/content/DeepLSD/third_party/homography_est' failed
Failed to clone 'third_party/homography_est'. Retry scheduled
Cloning into '/content/DeepLSD/third_party/progressive-x'...
Host key verification failed.
fatal: Could not read from remote repository.
Did you try cloning each submodule separately, e.g. for the first one failing:
cd line_refinement
git clone git@github.com:pybind/pybind11.git
Ok I ran the following, each line denoting a separate cell.
!cd line_refinement && git clone https://github.com/pybind/pybind11.git
!cd third_party/homography_est && git clone https://github.com/rpautrat/homography_est.git
!cd third_party/progressive-x && git clone https://github.com/danini/progressive-x.git
!cd third_party/pytlsd && git clone https://github.com/iago-suarez/pytlbd.git
!cd third_party/pytlbd && git clone https://github.com/rpautrat/pytlsd.git
All of these ran successfully. However this is the output of the install.sh script (Starting from the point where it fails)
install.sh: line 3: cd: third_party/progressive-x/graph-cut-ransac/build: No such file or directory
CMake Error: The source directory "/content" does not appear to contain CMakeLists.txt.
Specify --help for usage, or press the help button on the CMake GUI.
make: *** No targets specified and no makefile found. Stop.
install.sh: line 4: cd: third_party/progressive-x/build: No such file or directory
CMake Error: The source directory "/" does not appear to contain CMakeLists.txt.
Specify --help for usage, or press the help button on the CMake GUI.
make: *** No targets specified and no makefile found. Stop.
ERROR: third_party/progressive-x is not a valid editable requirement. It should either be a path to a local project or a VCS URL (beginning with bzr+http, bzr+https, bzr+ssh, bzr+sftp, bzr+ftp, bzr+lp, bzr+file, git+http, git+https, git+ssh, git+git, git+file, hg+file, hg+http, hg+https, hg+ssh, hg+static-http, svn+ssh, svn+http, svn+https, svn+svn, svn+file).
install.sh: line 6: cd: third_party/afm_lib/afm_op: No such file or directory
python3: can't open file 'setup.py': [Errno 2] No such file or directory
Looking in indexes: https://pypi.org/simple, https://us-python.pkg.dev/colab-wheels/public/simple/
Obtaining file:///
ERROR: file:/// does not appear to be a Python project: neither 'setup.py' nor 'pyproject.toml' found.
ERROR: line_refinement is not a valid editable requirement. It should either be a path to a local project or a VCS URL (beginning with bzr+http, bzr+https, bzr+ssh, bzr+sftp, bzr+ftp, bzr+lp, bzr+file, git+http, git+https, git+ssh, git+git, git+file, hg+file, hg+http, hg+https, hg+ssh, hg+static-http, svn+ssh, svn+http, svn+https, svn+svn, svn+file).
ERROR: third_party/homography_est is not a valid editable requirement. It should either be a path to a local project or a VCS URL (beginning with bzr+http, bzr+https, bzr+ssh, bzr+sftp, bzr+ftp, bzr+lp, bzr+file, git+http, git+https, git+ssh, git+git, git+file, hg+file, hg+http, hg+https, hg+ssh, hg+static-http, svn+ssh, svn+http, svn+https, svn+svn, svn+file).
Looking in indexes: https://pypi.org/simple, https://us-python.pkg.dev/colab-wheels/public/simple/
Obtaining file:///
ERROR: file:/// does not appear to be a Python project: neither 'setup.py' nor 'pyproject.toml' found.
graph-cut-ransac is a submodule of progressive_x, so you either need to clone progressive_x with recurse-submodules, or manually clone the submodule yourself if the first option doesn't work.
The build folder in graph-cut-ransac and progressive_x should already exist after cloning the two repos, I can see them on Github. If this is not the case, something went wrong with your cloning.
Similarly, third_party/afm_lib/afm_op
should exist after cloning DeepLSD, it is not even a submodule.
Overall, it seems you have a lot of issues with paths not found, while they should be available after cloning. You can maybe try the install.sh line by line, and understand why the paths are missing each time. But I don't think I can help more than that, because everything works out of the box on my side...
I have also tried to run this line on my personal machine now, not Google Colab:
testing100> git clone --recurse-submodules git@github.com:cvg/DeepLSD.git
Cloning into 'DeepLSD'...
Warning: Permanently added the RSA host key for IP address '140.82.121.4' to the list of known hosts.
git@github.com: Permission denied (publickey).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
If it's an issue from my end I'll investigate further, but it's quite strange how it happens from whichever machine I try to use.
Hi, your installation was indeed probably not successful. Can you please give the entire output of install.sh?
Hello, thank you for your attention! In my case it seems that all submodules are installed. I'm bad in C++ and cmake, so I really appreciate any help. This is all errors I have during execute install.sh line by line:
line 2
pip install -r requirements.txt # Install the requirements
when execute
pip install torch==1.10.1
get this:
ERROR: Could not find a version that satisfies the requirement torch==1.10.1 (from versions: 1.11.0, 1.12.0, 1.12.1, 1.13.0, 1.13.1)
ERROR: No matching distribution found for torch==1.10.1
UPD: Resolved this problem - just nedeed python 3.8 instead of 3.10 but other problems still remain
line 3
cd third_party/progressive-x/graph-cut-ransac/build; cmake ..; make -j8; cd ../../../.. # Install the C++ library Graph Cut RANSAC
There are some problems with opencv2:
CMake Warning at CMakeLists.txt:12 (find_package):
By not providing "FindOpenCV.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "OpenCV", but
CMake did not find one.
Could not find a package configuration file provided by "OpenCV" with any
of the following names:
OpenCVConfig.cmake
opencv-config.cmake
Add the installation prefix of "OpenCV" to CMAKE_PREFIX_PATH or set
"OpenCV_DIR" to a directory containing one of the above files. If "OpenCV"
provides a separate development package or SDK, be sure it has been
installed.
-- Could NOT find OpenMP_CXX (missing: OpenMP_CXX_FLAGS OpenMP_CXX_LIB_NAMES) -- Could NOT find OpenMP (missing: OpenMP_CXX_FOUND) -- pybind11 v2.1.1 -- Configuring done -- Generating done -- Build files have been written to: /Users/david/Documents/DeepLSD/third_party/progressive-x/graph-cut-ransac/build [ 4%] Building CXX object CMakeFiles/GraphCutRANSAC.dir/src/pygcransac/include/relative_pose/bundle.cpp.o [ 9%] Building CXX object CMakeFiles/GraphCutRANSAC.dir/src/pygcransac/include/relative_pose/essential.cpp.o [ 13%] Building CXX object CMakeFiles/pygcransac.dir/src/pygcransac/src/gcransac_python.cpp.o [ 18%] Building CXX object CMakeFiles/pygcransac.dir/src/pygcransac/include/relative_pose/bundle.cpp.o [ 22%] Building CXX object CMakeFiles/pygcransac.dir/src/pygcransac/include/relative_pose/essential.cpp.o In file included from /Users/david/Documents/DeepLSD/third_party/progressive-x/graph-cut-ransac/src/pygcransac/src/gcransac_python.cpp:4: /Users/david/Documents/DeepLSD/third_party/progressive-x/graph-cut-ransac/src/pygcransac/include/utils.h:42:10: fatal error: 'opencv2/core/core.hpp' file not found
^~~~~~~~~~~~~~~~~~~~~~~
In file included from /Users/david/Documents/DeepLSD/third_party/progressive-x/graph-cut-ransac/src/pygcransac/include/relative_pose/bundle.cpp:1: /Users/david/Documents/DeepLSD/third_party/progressive-x/graph-cut-ransac/src/pygcransac/include/relative_pose/bundle.h:6:10: fatal error: 'opencv2/core.hpp' file not found
^~~~~~~~~~~~~~~~~~
In file included from /Users/david/Documents/DeepLSD/third_party/progressive-x/graph-cut-ransac/src/pygcransac/include/relative_pose/bundle.cpp:1: /Users/david/Documents/DeepLSD/third_party/progressive-x/graph-cut-ransac/src/pygcransac/include/relative_pose/bundle.h:6:10: fatal error: 'opencv2/core.hpp' file not found
^~~~~~~~~~~~~~~~~~
1 error generated. 1 error generated. make[2]: [CMakeFiles/pygcransac.dir/src/pygcransac/include/relative_pose/bundle.cpp.o] Error 1 make[2]: Waiting for unfinished jobs.... In file included from /Users/david/Documents/DeepLSD/third_party/progressive-x/graph-cut-ransac/src/pygcransac/include/relative_pose/essential.cpp:29: In file included from /Users/david/Documents/DeepLSD/third_party/progressive-x/graph-cut-ransac/src/pygcransac/include/relative_pose/essential.h:33: /Users/david/Documents/DeepLSD/third_party/progressive-x/graph-cut-ransac/src/pygcransac/include/relative_pose/bundle.h:6:10: fatal error: 'opencv2/core.hpp' file not found
^~~~~~~~~~~~~~~~~~
make[2]: [CMakeFiles/GraphCutRANSAC.dir/src/pygcransac/include/relative_pose/bundle.cpp.o] Error 1 make[2]: Waiting for unfinished jobs.... 1 error generated. In file included from /Users/david/Documents/DeepLSD/third_party/progressive-x/graph-cut-ransac/src/pygcransac/include/relative_pose/essential.cpp:29: In file included from /Users/david/Documents/DeepLSD/third_party/progressive-x/graph-cut-ransac/src/pygcransac/include/relative_pose/essential.h:33: /Users/david/Documents/DeepLSD/third_party/progressive-x/graph-cut-ransac/src/pygcransac/include/relative_pose/bundle.h:6:10: fatal error: 'opencv2/core.hpp' file not found
^~~~~~~~~~~~~~~~~~
make[2]: [CMakeFiles/GraphCutRANSAC.dir/src/pygcransac/include/relative_pose/essential.cpp.o] Error 1 1 error generated. make[1]: [CMakeFiles/GraphCutRANSAC.dir/all] Error 2 make[1]: Waiting for unfinished jobs.... make[2]: [CMakeFiles/pygcransac.dir/src/pygcransac/include/relative_pose/essential.cpp.o] Error 1 1 error generated. make[2]: [CMakeFiles/pygcransac.dir/src/pygcransac/src/gcransac_python.cpp.o] Error 1 make[1]: [CMakeFiles/pygcransac.dir/all] Error 2 make: *** [all] Error 2
3. line 4
`cd third_party/progressive-x/build; cmake ..; make -j8; cd ../../.. # Install the C++ library Progressive-X`
Some problems in cmake configuration for opencv maybe:
CMake Warning at CMakeLists.txt:36 (find_package): By not providing "FindOpenCV.cmake" in CMAKE_MODULE_PATH this project has asked CMake to find a package configuration file provided by "OpenCV", but CMake did not find one.
Could not find a package configuration file provided by "OpenCV" with any of the following names:
OpenCVConfig.cmake
opencv-config.cmake
Add the installation prefix of "OpenCV" to CMAKE_PREFIX_PATH or set "OpenCV_DIR" to a directory containing one of the above files. If "OpenCV" provides a separate development package or SDK, be sure it has been installed.
Found Gflags 2.2.2 -- > GFLAGS_INCLUDE_DIR: /opt/homebrew/include -- > GFLAGS_LIBRARIES: gflags_shared -- Could NOT find OpenMP_CXX (missing: OpenMP_CXX_FLAGS OpenMP_CXX_LIB_NAMES) -- Could NOT find OpenMP (missing: OpenMP_CXX_FOUND) CMake Error at CMakeLists.txt:104 (message): OPENMP not found.
-- Configuring incomplete, errors occurred! See also "/Users/david/Documents/DeepLSD/third_party/progressive-x/build/CMakeFiles/CMakeOutput.log". See also "/Users/david/Documents/DeepLSD/third_party/progressive-x/build/CMakeFiles/CMakeError.log". make: *** No targets specified and no makefile found. Stop.
4. line 5
`pip install -e third_party/progressive-x # Install the Python bindings of Progressive-X for VP estimation`
Obtaining file:///Users/david/Documents/DeepLSD/third_party/progressive-x Preparing metadata (setup.py) ... done Installing collected packages: pyprogressivex Running setup.py develop for pyprogressivex error: subprocess-exited-with-error
× python setup.py develop did not run successfully.
│ exit code: 1
╰─> [65 lines of output]
running develop
running egg_info
writing src/pyprogressivex.egg-info/PKG-INFO
writing dependency_links to src/pyprogressivex.egg-info/dependency_links.txt
writing top-level names to src/pyprogressivex.egg-info/top_level.txt
adding license file 'LICENSE'
writing manifest file 'src/pyprogressivex.egg-info/SOURCES.txt'
running build_ext
CMake Warning at CMakeLists.txt:36 (find_package):
By not providing "FindOpenCV.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "OpenCV", but
CMake did not find one.
Could not find a package configuration file provided by "OpenCV" with any
of the following names:
OpenCVConfig.cmake
opencv-config.cmake
Add the installation prefix of "OpenCV" to CMAKE_PREFIX_PATH or set
"OpenCV_DIR" to a directory containing one of the above files. If "OpenCV"
provides a separate development package or SDK, be sure it has been
installed.
Found Gflags 2.2.2
-- > GFLAGS_INCLUDE_DIR: /opt/homebrew/include
-- > GFLAGS_LIBRARIES: gflags_shared
-- Could NOT find OpenMP_CXX (missing: OpenMP_CXX_FLAGS OpenMP_CXX_LIB_NAMES)
-- Could NOT find OpenMP (missing: OpenMP_CXX_FOUND)
CMake Error at CMakeLists.txt:104 (message):
OPENMP not found.
-- Configuring incomplete, errors occurred!
See also "/Users/david/Documents/DeepLSD/third_party/progressive-x/build/temp.macosx-10.9-universal2-3.10/CMakeFiles/CMakeOutput.log".
See also "/Users/david/Documents/DeepLSD/third_party/progressive-x/build/temp.macosx-10.9-universal2-3.10/CMakeFiles/CMakeError.log".
Traceback (most recent call last):
File "<string>", line 2, in <module>
File "<pip-setuptools-caller>", line 34, in <module>
File "/Users/david/Documents/DeepLSD/third_party/progressive-x/setup.py", line 94, in <module>
setup(
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/setuptools/__init__.py", line 153, in setup
return distutils.core.setup(**attrs)
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/core.py", line 148, in setup
dist.run_commands()
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/dist.py", line 966, in run_commands
self.run_command(cmd)
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/setuptools/command/develop.py", line 34, in run
self.install_for_development()
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/setuptools/command/develop.py", line 114, in install_for_development
self.run_command('build_ext')
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/Users/david/Documents/DeepLSD/third_party/progressive-x/setup.py", line 38, in run
self.build_extension(ext)
File "/Users/david/Documents/DeepLSD/third_party/progressive-x/setup.py", line 66, in build_extension
subprocess.check_call(['cmake', ext.sourcedir] + cmake_args,
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 369, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', '/Users/david/Documents/DeepLSD/third_party/progressive-x', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/Users/david/Documents/DeepLSD/third_party/progressive-x/src/pyprogressivex', '-DPYTHON_EXECUTABLE=/usr/local/bin/python3', '-DCMAKE_BUILD_TYPE=Release']' returned non-zero exit status 1.
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error
× python setup.py develop did not run successfully. │ exit code: 1 ╰─> [65 lines of output] running develop running egg_info writing src/pyprogressivex.egg-info/PKG-INFO writing dependency_links to src/pyprogressivex.egg-info/dependency_links.txt writing top-level names to src/pyprogressivex.egg-info/top_level.txt adding license file 'LICENSE' writing manifest file 'src/pyprogressivex.egg-info/SOURCES.txt' running build_ext CMake Warning at CMakeLists.txt:36 (find_package): By not providing "FindOpenCV.cmake" in CMAKE_MODULE_PATH this project has asked CMake to find a package configuration file provided by "OpenCV", but CMake did not find one.
Could not find a package configuration file provided by "OpenCV" with any
of the following names:
OpenCVConfig.cmake
opencv-config.cmake
Add the installation prefix of "OpenCV" to CMAKE_PREFIX_PATH or set
"OpenCV_DIR" to a directory containing one of the above files. If "OpenCV"
provides a separate development package or SDK, be sure it has been
installed.
Found Gflags 2.2.2
-- > GFLAGS_INCLUDE_DIR: /opt/homebrew/include
-- > GFLAGS_LIBRARIES: gflags_shared
-- Could NOT find OpenMP_CXX (missing: OpenMP_CXX_FLAGS OpenMP_CXX_LIB_NAMES)
-- Could NOT find OpenMP (missing: OpenMP_CXX_FOUND)
CMake Error at CMakeLists.txt:104 (message):
OPENMP not found.
-- Configuring incomplete, errors occurred!
See also "/Users/david/Documents/DeepLSD/third_party/progressive-x/build/temp.macosx-10.9-universal2-3.10/CMakeFiles/CMakeOutput.log".
See also "/Users/david/Documents/DeepLSD/third_party/progressive-x/build/temp.macosx-10.9-universal2-3.10/CMakeFiles/CMakeError.log".
Traceback (most recent call last):
File "<string>", line 2, in <module>
File "<pip-setuptools-caller>", line 34, in <module>
File "/Users/david/Documents/DeepLSD/third_party/progressive-x/setup.py", line 94, in <module>
setup(
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/setuptools/__init__.py", line 153, in setup
return distutils.core.setup(**attrs)
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/core.py", line 148, in setup
dist.run_commands()
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/dist.py", line 966, in run_commands
self.run_command(cmd)
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/setuptools/command/develop.py", line 34, in run
self.install_for_development()
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/setuptools/command/develop.py", line 114, in install_for_development
self.run_command('build_ext')
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/Users/david/Documents/DeepLSD/third_party/progressive-x/setup.py", line 38, in run
self.build_extension(ext)
File "/Users/david/Documents/DeepLSD/third_party/progressive-x/setup.py", line 66, in build_extension
subprocess.check_call(['cmake', ext.sourcedir] + cmake_args,
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 369, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', '/Users/david/Documents/DeepLSD/third_party/progressive-x', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/Users/david/Documents/DeepLSD/third_party/progressive-x/src/pyprogressivex', '-DPYTHON_EXECUTABLE=/usr/local/bin/python3', '-DCMAKE_BUILD_TYPE=Release']' returned non-zero exit status 1.
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
5. line 7
`pip install -e line_refinement # Install the Python bindings to optimize lines wrt a distance/angle field`
Obtaining file:///Users/david/Documents/DeepLSD/line_refinement Preparing metadata (setup.py) ... done Installing collected packages: line-refinement Running setup.py develop for line-refinement error: subprocess-exited-with-error
× python setup.py develop did not run successfully.
│ exit code: 1
╰─> [76 lines of output]
running develop
running egg_info
writing line_refinement.egg-info/PKG-INFO
writing dependency_links to line_refinement.egg-info/dependency_links.txt
writing top-level names to line_refinement.egg-info/top_level.txt
writing manifest file 'line_refinement.egg-info/SOURCES.txt'
running build_ext
-- Found AMD headers in: /opt/homebrew/include
-- Found AMD library: /opt/homebrew/lib/libamd.dylib
-- Found CAMD headers in: /opt/homebrew/include
-- Found CAMD library: /opt/homebrew/lib/libcamd.dylib
-- Found CCOLAMD headers in: /opt/homebrew/include
-- Found CCOLAMD library: /opt/homebrew/lib/libccolamd.dylib
-- Found CHOLMOD headers in: /opt/homebrew/include
-- Found CHOLMOD library: /opt/homebrew/lib/libcholmod.dylib
-- Found COLAMD headers in: /opt/homebrew/include
-- Found COLAMD library: /opt/homebrew/lib/libcolamd.dylib
-- Found SPQR headers in: /opt/homebrew/include
-- Found SPQR library: /opt/homebrew/lib/libspqr.dylib
-- Found Config headers in: /opt/homebrew/include
-- Found Config library: /opt/homebrew/lib/libsuitesparseconfig.dylib
-- Found Intel Thread Building Blocks (TBB) library (2021.7 / ) include location: . Assuming SuiteSparseQR was compiled with TBB.
-- Could not find librt, but found SuiteSparse_config, assuming that SuiteSparse was compiled without timing.
-- Found required Ceres dependency: Eigen version 3.4.0 in /opt/homebrew/share/eigen3/cmake
-- Found required Ceres dependency: glog
-- Found required Ceres dependency: gflags
-- Found Ceres version: 2.1.0 installed in: /opt/homebrew with components: [EigenSparse, SparseLinearAlgebraLibrary, LAPACK, SuiteSparse, CXSparse, AccelerateSparse, SchurSpecializations, Multithreading]
CMake Error at CMakeLists.txt:8 (find_package):
By not providing "FindOpenCV.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "OpenCV", but
CMake did not find one.
Could not find a package configuration file provided by "OpenCV" with any
of the following names:
OpenCVConfig.cmake
opencv-config.cmake
Add the installation prefix of "OpenCV" to CMAKE_PREFIX_PATH or set
"OpenCV_DIR" to a directory containing one of the above files. If "OpenCV"
provides a separate development package or SDK, be sure it has been
installed.
-- Configuring incomplete, errors occurred!
See also "/Users/david/Documents/DeepLSD/line_refinement/build/temp.macosx-10.9-universal2-3.10/CMakeFiles/CMakeOutput.log".
See also "/Users/david/Documents/DeepLSD/line_refinement/build/temp.macosx-10.9-universal2-3.10/CMakeFiles/CMakeError.log".
Traceback (most recent call last):
File "<string>", line 2, in <module>
File "<pip-setuptools-caller>", line 34, in <module>
File "/Users/david/Documents/DeepLSD/line_refinement/setup.py", line 62, in <module>
setup(
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/setuptools/__init__.py", line 153, in setup
return distutils.core.setup(**attrs)
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/core.py", line 148, in setup
dist.run_commands()
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/dist.py", line 966, in run_commands
self.run_command(cmd)
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/setuptools/command/develop.py", line 34, in run
self.install_for_development()
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/setuptools/command/develop.py", line 114, in install_for_development
self.run_command('build_ext')
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/Users/david/Documents/DeepLSD/line_refinement/setup.py", line 32, in run
self.build_extension(ext)
File "/Users/david/Documents/DeepLSD/line_refinement/setup.py", line 59, in build_extension
subprocess.check_call(['cmake', ext.sourcedir] + cmake_args, cwd=self.build_temp, env=env)
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 369, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', '/Users/david/Documents/DeepLSD/line_refinement', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/Users/david/Documents/DeepLSD/line_refinement', '-DPYTHON_EXECUTABLE=/usr/local/bin/python3', '-DCMAKE_BUILD_TYPE=Release']' returned non-zero exit status 1.
['cmake', '/Users/david/Documents/DeepLSD/line_refinement', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/Users/david/Documents/DeepLSD/line_refinement', '-DPYTHON_EXECUTABLE=/usr/local/bin/python3', '-DCMAKE_BUILD_TYPE=Release']
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error
× python setup.py develop did not run successfully. │ exit code: 1 ╰─> [76 lines of output] running develop running egg_info writing line_refinement.egg-info/PKG-INFO writing dependency_links to line_refinement.egg-info/dependency_links.txt writing top-level names to line_refinement.egg-info/top_level.txt writing manifest file 'line_refinement.egg-info/SOURCES.txt' running build_ext -- Found AMD headers in: /opt/homebrew/include -- Found AMD library: /opt/homebrew/lib/libamd.dylib -- Found CAMD headers in: /opt/homebrew/include -- Found CAMD library: /opt/homebrew/lib/libcamd.dylib -- Found CCOLAMD headers in: /opt/homebrew/include -- Found CCOLAMD library: /opt/homebrew/lib/libccolamd.dylib -- Found CHOLMOD headers in: /opt/homebrew/include -- Found CHOLMOD library: /opt/homebrew/lib/libcholmod.dylib -- Found COLAMD headers in: /opt/homebrew/include -- Found COLAMD library: /opt/homebrew/lib/libcolamd.dylib -- Found SPQR headers in: /opt/homebrew/include -- Found SPQR library: /opt/homebrew/lib/libspqr.dylib -- Found Config headers in: /opt/homebrew/include -- Found Config library: /opt/homebrew/lib/libsuitesparseconfig.dylib -- Found Intel Thread Building Blocks (TBB) library (2021.7 / ) include location: . Assuming SuiteSparseQR was compiled with TBB. -- Could not find librt, but found SuiteSparse_config, assuming that SuiteSparse was compiled without timing. -- Found required Ceres dependency: Eigen version 3.4.0 in /opt/homebrew/share/eigen3/cmake -- Found required Ceres dependency: glog -- Found required Ceres dependency: gflags -- Found Ceres version: 2.1.0 installed in: /opt/homebrew with components: [EigenSparse, SparseLinearAlgebraLibrary, LAPACK, SuiteSparse, CXSparse, AccelerateSparse, SchurSpecializations, Multithreading] CMake Error at CMakeLists.txt:8 (find_package): By not providing "FindOpenCV.cmake" in CMAKE_MODULE_PATH this project has asked CMake to find a package configuration file provided by "OpenCV", but CMake did not find one.
Could not find a package configuration file provided by "OpenCV" with any
of the following names:
OpenCVConfig.cmake
opencv-config.cmake
Add the installation prefix of "OpenCV" to CMAKE_PREFIX_PATH or set
"OpenCV_DIR" to a directory containing one of the above files. If "OpenCV"
provides a separate development package or SDK, be sure it has been
installed.
-- Configuring incomplete, errors occurred!
See also "/Users/david/Documents/DeepLSD/line_refinement/build/temp.macosx-10.9-universal2-3.10/CMakeFiles/CMakeOutput.log".
See also "/Users/david/Documents/DeepLSD/line_refinement/build/temp.macosx-10.9-universal2-3.10/CMakeFiles/CMakeError.log".
Traceback (most recent call last):
File "<string>", line 2, in <module>
File "<pip-setuptools-caller>", line 34, in <module>
File "/Users/david/Documents/DeepLSD/line_refinement/setup.py", line 62, in <module>
setup(
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/setuptools/__init__.py", line 153, in setup
return distutils.core.setup(**attrs)
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/core.py", line 148, in setup
dist.run_commands()
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/dist.py", line 966, in run_commands
self.run_command(cmd)
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/setuptools/command/develop.py", line 34, in run
self.install_for_development()
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/setuptools/command/develop.py", line 114, in install_for_development
self.run_command('build_ext')
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/Users/david/Documents/DeepLSD/line_refinement/setup.py", line 32, in run
self.build_extension(ext)
File "/Users/david/Documents/DeepLSD/line_refinement/setup.py", line 59, in build_extension
subprocess.check_call(['cmake', ext.sourcedir] + cmake_args, cwd=self.build_temp, env=env)
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 369, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cmake', '/Users/david/Documents/DeepLSD/line_refinement', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/Users/david/Documents/DeepLSD/line_refinement', '-DPYTHON_EXECUTABLE=/usr/local/bin/python3', '-DCMAKE_BUILD_TYPE=Release']' returned non-zero exit status 1.
['cmake', '/Users/david/Documents/DeepLSD/line_refinement', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/Users/david/Documents/DeepLSD/line_refinement', '-DPYTHON_EXECUTABLE=/usr/local/bin/python3', '-DCMAKE_BUILD_TYPE=Release']
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
All other lines execute successfully.
I have also tried to run this line on my personal machine now, not Google Colab:
testing100> git clone --recurse-submodules git@github.com:cvg/DeepLSD.git Cloning into 'DeepLSD'... Warning: Permanently added the RSA host key for IP address '140.82.121.4' to the list of known hosts. git@github.com: Permission denied (publickey). fatal: Could not read from remote repository. Please make sure you have the correct access rights and the repository exists.
If it's an issue from my end I'll investigate further, but it's quite strange how it happens from whichever machine I try to use.
With the help of @iago-suarez, I think we found the issue for Colab: ssh doesn't work there, and we also need to update the submodules to use https. The fix has been merged now, so hopefully it should work on Colab if you pull the latest version. This doesn't explain why it was not working on your personal machine though...
@dlbolshov , it seems that there were three issues overall:
sudo apt install libopencv-dev
. If OpenCV is already installed and is still not working, it means that it is not found by CMake. Then you should probably follow the advice of the error message: "Add the installation prefix of "OpenCV" to CMAKE_PREFIX_PATH or set "OpenCV_DIR" to a directory containing one of the above files.".sudo apt install libomp-dev
to install it. If it still doesn't work, I recommend following a tutorial on how to install OpenMP and use it with CMake.I compiled it successfully but it can not installed. errors like the fllows:
[ 95%] Built target pygcransac [100%] Linking CXX executable SampleProject [100%] Built target SampleProject -- The CXX compiler identification is GNU 7.5.0 -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Check for working CXX compiler: /usr/bin/c++ - skipped -- Detecting CXX compile features -- Detecting CXX compile features - done -- Found OpenCV: /usr/local (found version "4.0.0") CMake Error at CMakeLists.txt:52 (find_package): By not providing "Findgflags.cmake" in CMAKE_MODULE_PATH this project has asked CMake to find a package configuration file provided by "gflags", but CMake did not find one.
Could not find a package configuration file provided by "gflags" with any of the following names:
gflagsConfig.cmake gflags-config.cmake
Add the installation prefix of "gflags" to CMAKE_PREFIX_PATH or set "gflags_DIR" to a directory containing one of the above files. If "gflags" provides a separate development package or SDK, be sure it has been installed.
-- Configuring incomplete, errors occurred! See also "/home/user/Documents/CODE/DeepLSD/third_party/progressive-x/build/CMakeFiles/CMakeOutput.log". make: *** No targets specified and no makefile found. Stop. Obtaining file:///home/user/Documents/CODE/DeepLSD/third_party/progressive-x Installing collected packages: pyprogressivex Running setup.py develop for pyprogressivex ERROR: Command errored out with exit status 1: command: /home/user/anaconda3/bin/python -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/home/user/Documents/CODE/DeepLSD/third_party/progressive-x/setup.py'"'"'; file='"'"'/home/user/Documents/CODE/DeepLSD/third_party/progressive-x/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' develop --no-deps cwd: /home/user/Documents/CODE/DeepLSD/third_party/progressive-x/ Complete output (74 lines): running develop /home/user/anaconda3/lib/python3.9/site-packages/setuptools/command/easy_install.py:144: EasyInstallDeprecationWarning: easy_install command is deprecated. Use build and pip and other standards-based tools. warnings.warn( /home/user/anaconda3/lib/python3.9/site-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools. warnings.warn( running egg_info creating src/pyprogressivex.egg-info writing src/pyprogressivex.egg-info/PKG-INFO writing dependency_links to src/pyprogressivex.egg-info/dependency_links.txt writing top-level names to src/pyprogressivex.egg-info/top_level.txt writing manifest file 'src/pyprogressivex.egg-info/SOURCES.txt' reading manifest file 'src/pyprogressivex.egg-info/SOURCES.txt' adding license file 'LICENSE' writing manifest file 'src/pyprogressivex.egg-info/SOURCES.txt' running build_ext -- The CXX compiler identification is GNU 7.5.0 -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Check for working CXX compiler: /usr/bin/c++ - skipped -- Detecting CXX compile features -- Detecting CXX compile features - done -- Found OpenCV: /usr/local (found version "4.0.0") CMake Error at CMakeLists.txt:52 (find_package): By not providing "Findgflags.cmake" in CMAKE_MODULE_PATH this project has asked CMake to find a package configuration file provided by "gflags", but CMake did not find one.
Could not find a package configuration file provided by "gflags" with any of the following names: gflagsConfig.cmake gflags-config.cmake Add the installation prefix of "gflags" to CMAKE_PREFIX_PATH or set "gflags_DIR" to a directory containing one of the above files. If "gflags" provides a separate development package or SDK, be sure it has been installed. -- Configuring incomplete, errors occurred! See also "/home/user/Documents/CODE/DeepLSD/third_party/progressive-x/build/temp.linux-x86_64-cpython-39/CMakeFiles/CMakeOutput.log". Traceback (most recent call last): File "<string>", line 1, in <module> File "/home/user/Documents/CODE/DeepLSD/third_party/progressive-x/setup.py", line 94, in <module> setup( File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/__init__.py", line 87, in setup return distutils.core.setup(**attrs) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/core.py", line 185, in setup return run_commands(dist) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/core.py", line 201, in run_commands dist.run_commands() File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/dist.py", line 968, in run_commands self.run_command(cmd) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/dist.py", line 1217, in run_command super().run_command(command) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/dist.py", line 987, in run_command cmd_obj.run() File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/command/develop.py", line 34, in run self.install_for_development() File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/command/develop.py", line 114, in install_for_development self.run_command('build_ext') File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/cmd.py", line 319, in run_command self.distribution.run_command(command) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/dist.py", line 1217, in run_command super().run_command(command) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/dist.py", line 987, in run_command cmd_obj.run() File "/home/user/Documents/CODE/DeepLSD/third_party/progressive-x/setup.py", line 38, in run self.build_extension(ext) File "/home/user/Documents/CODE/DeepLSD/third_party/progressive-x/setup.py", line 66, in build_extension subprocess.check_call(['cmake', ext.sourcedir] + cmake_args, File "/home/user/anaconda3/lib/python3.9/subprocess.py", line 373, in check_call raise CalledProcessError(retcode, cmd) subprocess.CalledProcessError: Command '['cmake', '/home/user/Documents/CODE/DeepLSD/third_party/progressive-x', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/home/user/Documents/CODE/DeepLSD/third_party/progressive-x/src/pyprogressivex', '-DPYTHON_EXECUTABLE=/home/user/anaconda3/bin/python', '-DCMAKE_BUILD_TYPE=Release']' returned non-zero exit status 1. ----------------------------------------
ERROR: Command errored out with exit status 1: /home/user/anaconda3/bin/python -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/home/user/Documents/CODE/DeepLSD/third_party/progressive-x/setup.py'"'"'; file='"'"'/home/user/Documents/CODE/DeepLSD/third_party/progressive-x/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' develop --no-deps Check the logs for full command output. /home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/extension.py:134: UserWarning: Unknown Extension options: 'defined_macros' warnings.warn(msg) running build_ext building 'CUDA' extension creating /home/user/Documents/CODE/DeepLSD/third_party/afm_lib/afm_op/build creating /home/user/Documents/CODE/DeepLSD/third_party/afm_lib/afm_op/build/temp.linux-x86_64-cpython-39 creating /home/user/Documents/CODE/DeepLSD/third_party/afm_lib/afm_op/build/temp.linux-x86_64-cpython-39/cuda Emitting ninja build file /home/user/Documents/CODE/DeepLSD/third_party/afm_lib/afm_op/build/temp.linux-x86_64-cpython-39/build.ninja... Compiling objects... Allowing ninja to set a default number of workers... (overridable by setting the environment variable MAX_JOBS=N) [1/2] /usr/local/cuda/bin/nvcc -I. -I/home/user/.local/lib/python3.9/site-packages/torch/include -I/home/user/.local/lib/python3.9/site-packages/torch/include/torch/csrc/api/include -I/home/user/.local/lib/python3.9/site-packages/torch/include/TH -I/home/user/.local/lib/python3.9/site-packages/torch/include/THC -I/usr/local/cuda/include -I/home/user/anaconda3/include/python3.9 -c -c /home/user/Documents/CODE/DeepLSD/third_party/afm_lib/afm_op/cuda/afm.cu -o /home/user/Documents/CODE/DeepLSD/third_party/afm_lib/afm_op/build/temp.linux-x86_64-cpython-39/cuda/afm.o -DCUDA_NO_HALF_OPERATORS -DCUDA_NO_HALF_CONVERSIONS -DCUDA_NO_BFLOAT16_CONVERSIONS -DCUDA_NO_HALF2_OPERATORS --expt-relaxed-constexpr --compiler-options ''"'"'-fPIC'"'"'' -DTORCH_API_INCLUDE_EXTENSION_H '-DPYBIND11_COMPILER_TYPE="_gcc"' '-DPYBIND11_STDLIB="_libstdcpp"' '-DPYBIND11_BUILD_ABI="_cxxabi1011"' -DTORCH_EXTENSION_NAME=CUDA -D_GLIBCXX_USE_CXX11_ABI=0 -gencode=arch=compute_86,code=compute_86 -gencode=arch=compute_86,code=sm_86 -std=c++14 FAILED: /home/user/Documents/CODE/DeepLSD/third_party/afm_lib/afm_op/build/temp.linux-x86_64-cpython-39/cuda/afm.o /usr/local/cuda/bin/nvcc -I. -I/home/user/.local/lib/python3.9/site-packages/torch/include -I/home/user/.local/lib/python3.9/site-packages/torch/include/torch/csrc/api/include -I/home/user/.local/lib/python3.9/site-packages/torch/include/TH -I/home/user/.local/lib/python3.9/site-packages/torch/include/THC -I/usr/local/cuda/include -I/home/user/anaconda3/include/python3.9 -c -c /home/user/Documents/CODE/DeepLSD/third_party/afm_lib/afm_op/cuda/afm.cu -o /home/user/Documents/CODE/DeepLSD/third_party/afm_lib/afm_op/build/temp.linux-x86_64-cpython-39/cuda/afm.o -DCUDA_NO_HALF_OPERATORS -DCUDA_NO_HALF_CONVERSIONS -DCUDA_NO_BFLOAT16_CONVERSIONS -DCUDA_NO_HALF2_OPERATORS --expt-relaxed-constexpr --compiler-options ''"'"'-fPIC'"'"'' -DTORCH_API_INCLUDE_EXTENSION_H '-DPYBIND11_COMPILER_TYPE="_gcc"' '-DPYBIND11_STDLIB="_libstdcpp"' '-DPYBIND11_BUILD_ABI="_cxxabi1011"' -DTORCH_EXTENSION_NAME=CUDA -D_GLIBCXX_USE_CXX11_ABI=0 -gencode=arch=compute_86,code=compute_86 -gencode=arch=compute_86,code=sm_86 -std=c++14 /home/user/Documents/CODE/DeepLSD/third_party/afm_lib/afm_op/cuda/afm.cu:4:10: fatal error: THC/THC.h: No such file or directory
include <THC/THC.h>
^~~~~~~~~~~
compilation terminated. [2/2] c++ -MMD -MF /home/user/Documents/CODE/DeepLSD/third_party/afm_lib/afm_op/build/temp.linux-x86_64-cpython-39/vision.o.d -pthread -B /home/user/anaconda3/compiler_compat -Wno-unused-result -Wsign-compare -DNDEBUG -O2 -Wall -fPIC -O2 -isystem /home/user/anaconda3/include -I/home/user/anaconda3/include -fPIC -O2 -isystem /home/user/anaconda3/include -fPIC -I. -I/home/user/.local/lib/python3.9/site-packages/torch/include -I/home/user/.local/lib/python3.9/site-packages/torch/include/torch/csrc/api/include -I/home/user/.local/lib/python3.9/site-packages/torch/include/TH -I/home/user/.local/lib/python3.9/site-packages/torch/include/THC -I/usr/local/cuda/include -I/home/user/anaconda3/include/python3.9 -c -c /home/user/Documents/CODE/DeepLSD/third_party/afm_lib/afm_op/vision.cpp -o /home/user/Documents/CODE/DeepLSD/third_party/afm_lib/afm_op/build/temp.linux-x86_64-cpython-39/vision.o -DTORCH_API_INCLUDE_EXTENSION_H '-DPYBIND11_COMPILER_TYPE="_gcc"' '-DPYBIND11_STDLIB="_libstdcpp"' '-DPYBIND11_BUILD_ABI="_cxxabi1011"' -DTORCH_EXTENSION_NAME=CUDA -D_GLIBCXX_USE_CXX11_ABI=0 -std=c++14 ninja: build stopped: subcommand failed. Traceback (most recent call last): File "/home/user/.local/lib/python3.9/site-packages/torch/utils/cpp_extension.py", line 1740, in _run_ninja_build subprocess.run( File "/home/user/anaconda3/lib/python3.9/subprocess.py", line 528, in run raise CalledProcessError(retcode, process.args, subprocess.CalledProcessError: Command '['ninja', '-v']' returned non-zero exit status 1.
The above exception was the direct cause of the following exception:
Traceback (most recent call last): File "/home/user/Documents/CODE/DeepLSD/third_party/afm_lib/afm_op/setup.py", line 35, in
setup( File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/init.py", line 87, in setup return distutils.core.setup(**attrs) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/core.py", line 185, in setup return run_commands(dist) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/core.py", line 201, in run_commands dist.run_commands() File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/dist.py", line 968, in run_commands self.run_command(cmd) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/dist.py", line 1217, in run_command super().run_command(command) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/dist.py", line 987, in run_command cmd_obj.run() File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/command/build_ext.py", line 84, in run _build_ext.run(self) File "/home/user/anaconda3/lib/python3.9/site-packages/Cython/Distutils/old_build_ext.py", line 186, in run _build_ext.build_ext.run(self) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/command/build_ext.py", line 346, in run self.build_extensions() File "/home/user/.local/lib/python3.9/site-packages/torch/utils/cpp_extension.py", line 741, in build_extensions build_ext.build_extensions(self) File "/home/user/anaconda3/lib/python3.9/site-packages/Cython/Distutils/old_build_ext.py", line 195, in build_extensions _build_ext.build_ext.build_extensions(self) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/command/build_ext.py", line 466, in build_extensions self._build_extensions_serial() File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/command/build_ext.py", line 492, in _build_extensions_serial self.build_extension(ext) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/command/build_ext.py", line 246, in build_extension _build_ext.build_extension(self, ext) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/command/build_ext.py", line 547, in build_extension objects = self.compiler.compile( File "/home/user/.local/lib/python3.9/site-packages/torch/utils/cpp_extension.py", line 562, in unix_wrap_ninja_compile _write_ninja_file_and_compile_objects( File "/home/user/.local/lib/python3.9/site-packages/torch/utils/cpp_extension.py", line 1419, in _write_ninja_file_and_compile_objects _run_ninja_build( File "/home/user/.local/lib/python3.9/site-packages/torch/utils/cpp_extension.py", line 1756, in _run_ninja_build raise RuntimeError(message) from e RuntimeError: Error compiling objects for extension Obtaining file:///home/user/Documents/CODE/DeepLSD/third_party/afm_lib Installing collected packages: afm-op Running setup.py develop for afm-op Successfully installed afm-op-0.0 Obtaining file:///home/user/Documents/CODE/DeepLSD/line_refinement Installing collected packages: line-refinement Running setup.py develop for line-refinement ERROR: Command errored out with exit status 1: command: /home/user/anaconda3/bin/python -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/home/user/Documents/CODE/DeepLSD/line_refinement/setup.py'"'"'; file='"'"'/home/user/Documents/CODE/DeepLSD/line_refinement/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' develop --no-deps cwd: /home/user/Documents/CODE/DeepLSD/line_refinement/ Complete output (79 lines): running develop /home/user/anaconda3/lib/python3.9/site-packages/setuptools/command/easy_install.py:144: EasyInstallDeprecationWarning: easy_install command is deprecated. Use build and pip and other standards-based tools. warnings.warn( /home/user/anaconda3/lib/python3.9/site-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools. warnings.warn( running egg_info creating line_refinement.egg-info writing line_refinement.egg-info/PKG-INFO writing dependency_links to line_refinement.egg-info/dependency_links.txt writing top-level names to line_refinement.egg-info/top_level.txt writing manifest file 'line_refinement.egg-info/SOURCES.txt' reading manifest file 'line_refinement.egg-info/SOURCES.txt' writing manifest file 'line_refinement.egg-info/SOURCES.txt' running build_ext -- The C compiler identification is GNU 7.5.0 -- The CXX compiler identification is GNU 7.5.0 -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Check for working C compiler: /usr/bin/cc - skipped -- Detecting C compile features -- Detecting C compile features - done -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Check for working CXX compiler: /usr/bin/c++ - skipped -- Detecting CXX compile features -- Detecting CXX compile features - done CMake Error at CMakeLists.txt:7 (find_package): By not providing "FindCeres.cmake" in CMAKE_MODULE_PATH this project has asked CMake to find a package configuration file provided by "Ceres", but CMake did not find one. Could not find a package configuration file provided by "Ceres" with any of the following names: CeresConfig.cmake ceres-config.cmake Add the installation prefix of "Ceres" to CMAKE_PREFIX_PATH or set "Ceres_DIR" to a directory containing one of the above files. If "Ceres" provides a separate development package or SDK, be sure it has been installed. -- Configuring incomplete, errors occurred! See also "/home/user/Documents/CODE/DeepLSD/line_refinement/build/temp.linux-x86_64-cpython-39/CMakeFiles/CMakeOutput.log". Traceback (most recent call last): File "<string>", line 1, in <module> File "/home/user/Documents/CODE/DeepLSD/line_refinement/setup.py", line 62, in <module> setup( File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/__init__.py", line 87, in setup return distutils.core.setup(**attrs) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/core.py", line 185, in setup return run_commands(dist) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/core.py", line 201, in run_commands dist.run_commands() File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/dist.py", line 968, in run_commands self.run_command(cmd) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/dist.py", line 1217, in run_command super().run_command(command) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/dist.py", line 987, in run_command cmd_obj.run() File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/command/develop.py", line 34, in run self.install_for_development() File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/command/develop.py", line 114, in install_for_development self.run_command('build_ext') File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/cmd.py", line 319, in run_command self.distribution.run_command(command) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/dist.py", line 1217, in run_command super().run_command(command) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/dist.py", line 987, in run_command cmd_obj.run() File "/home/user/Documents/CODE/DeepLSD/line_refinement/setup.py", line 32, in run self.build_extension(ext) File "/home/user/Documents/CODE/DeepLSD/line_refinement/setup.py", line 59, in build_extension subprocess.check_call(['cmake', ext.sourcedir] + cmake_args, cwd=self.build_temp, env=env) File "/home/user/anaconda3/lib/python3.9/subprocess.py", line 373, in check_call raise CalledProcessError(retcode, cmd) subprocess.CalledProcessError: Command '['cmake', '/home/user/Documents/CODE/DeepLSD/line_refinement', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/home/user/Documents/CODE/DeepLSD/line_refinement', '-DPYTHON_EXECUTABLE=/home/user/anaconda3/bin/python', '-DCMAKE_BUILD_TYPE=Release']' returned non-zero exit status 1. ['cmake', '/home/user/Documents/CODE/DeepLSD/line_refinement', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/home/user/Documents/CODE/DeepLSD/line_refinement', '-DPYTHON_EXECUTABLE=/home/user/anaconda3/bin/python', '-DCMAKE_BUILD_TYPE=Release'] ----------------------------------------
ERROR: Command errored out with exit status 1: /home/user/anaconda3/bin/python -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/home/user/Documents/CODE/DeepLSD/line_refinement/setup.py'"'"'; file='"'"'/home/user/Documents/CODE/DeepLSD/line_refinement/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' develop --no-deps Check the logs for full command output. Obtaining file:///home/user/Documents/CODE/DeepLSD/third_party/homography_est Installing collected packages: homography-est Running setup.py develop for homography-est ERROR: Command errored out with exit status 1: command: /home/user/anaconda3/bin/python -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/home/user/Documents/CODE/DeepLSD/third_party/homography_est/setup.py'"'"'; file='"'"'/home/user/Documents/CODE/DeepLSD/third_party/homography_est/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' develop --no-deps cwd: /home/user/Documents/CODE/DeepLSD/third_party/homography_est/ Complete output (80 lines): running develop /home/user/anaconda3/lib/python3.9/site-packages/setuptools/command/easy_install.py:144: EasyInstallDeprecationWarning: easy_install command is deprecated. Use build and pip and other standards-based tools. warnings.warn( /home/user/anaconda3/lib/python3.9/site-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools. warnings.warn( running egg_info creating homography_est.egg-info writing homography_est.egg-info/PKG-INFO writing dependency_links to homography_est.egg-info/dependency_links.txt writing top-level names to homography_est.egg-info/top_level.txt writing manifest file 'homography_est.egg-info/SOURCES.txt' reading manifest file 'homography_est.egg-info/SOURCES.txt' adding license file 'LICENSE' writing manifest file 'homography_est.egg-info/SOURCES.txt' running build_ext -- The C compiler identification is GNU 7.5.0 -- The CXX compiler identification is GNU 7.5.0 -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Check for working C compiler: /usr/bin/cc - skipped -- Detecting C compile features -- Detecting C compile features - done -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Check for working CXX compiler: /usr/bin/c++ - skipped -- Detecting CXX compile features -- Detecting CXX compile features - done CMake Error at CMakeLists.txt:6 (find_package): By not providing "FindCeres.cmake" in CMAKE_MODULE_PATH this project has asked CMake to find a package configuration file provided by "Ceres", but CMake did not find one.
Could not find a package configuration file provided by "Ceres" with any of the following names: CeresConfig.cmake ceres-config.cmake Add the installation prefix of "Ceres" to CMAKE_PREFIX_PATH or set "Ceres_DIR" to a directory containing one of the above files. If "Ceres" provides a separate development package or SDK, be sure it has been installed. -- Configuring incomplete, errors occurred! See also "/home/user/Documents/CODE/DeepLSD/third_party/homography_est/build/temp.linux-x86_64-cpython-39/CMakeFiles/CMakeOutput.log". Traceback (most recent call last): File "<string>", line 1, in <module> File "/home/user/Documents/CODE/DeepLSD/third_party/homography_est/setup.py", line 62, in <module> setup( File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/__init__.py", line 87, in setup return distutils.core.setup(**attrs) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/core.py", line 185, in setup return run_commands(dist) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/core.py", line 201, in run_commands dist.run_commands() File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/dist.py", line 968, in run_commands self.run_command(cmd) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/dist.py", line 1217, in run_command super().run_command(command) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/dist.py", line 987, in run_command cmd_obj.run() File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/command/develop.py", line 34, in run self.install_for_development() File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/command/develop.py", line 114, in install_for_development self.run_command('build_ext') File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/cmd.py", line 319, in run_command self.distribution.run_command(command) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/dist.py", line 1217, in run_command super().run_command(command) File "/home/user/anaconda3/lib/python3.9/site-packages/setuptools/_distutils/dist.py", line 987, in run_command cmd_obj.run() File "/home/user/Documents/CODE/DeepLSD/third_party/homography_est/setup.py", line 32, in run self.build_extension(ext) File "/home/user/Documents/CODE/DeepLSD/third_party/homography_est/setup.py", line 59, in build_extension subprocess.check_call(['cmake', ext.sourcedir] + cmake_args, cwd=self.build_temp, env=env) File "/home/user/anaconda3/lib/python3.9/subprocess.py", line 373, in check_call raise CalledProcessError(retcode, cmd) subprocess.CalledProcessError: Command '['cmake', '/home/user/Documents/CODE/DeepLSD/third_party/homography_est', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/home/user/Documents/CODE/DeepLSD/third_party/homography_est', '-DPYTHON_EXECUTABLE=/home/user/anaconda3/bin/python', '-DCMAKE_BUILD_TYPE=Release']' returned non-zero exit status 1. ['cmake', '/home/user/Documents/CODE/DeepLSD/third_party/homography_est', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/home/user/Documents/CODE/DeepLSD/third_party/homography_est', '-DPYTHON_EXECUTABLE=/home/user/anaconda3/bin/python', '-DCMAKE_BUILD_TYPE=Release'] ----------------------------------------
ERROR: Command errored out with exit status 1: /home/user/anaconda3/bin/python -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/home/user/Documents/CODE/DeepLSD/third_party/homography_est/setup.py'"'"'; file='"'"'/home/user/Documents/CODE/DeepLSD/third_party/homography_est/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' develop --no-deps Check the logs for full command output. Obtaining file:///home/user/Documents/CODE/DeepLSD Installing collected packages: deeplsd Attempting uninstall: deeplsd Found existing installation: deeplsd 0.0 Uninstalling deeplsd-0.0: Successfully uninstalled deeplsd-0.0 Running setup.py develop for deeplsd Successfully installed deeplsd-0.0
when I run the notebook code,it raised the error:
ImportError Traceback (most recent call last) /home/user/Documents/CODE/userDeepLSD/notebooks/demo_line_detection.ipynb Cell 1 in <cell line: 11>() 8 import h5py 10 from deeplsd.utils.tensor import batch_to_device ---> 11 from deeplsd.models.deeplsd import DeepLSD 12 from deeplsd.geometry.viz_2d import plot_images, plot_lines
File ~/Documents/CODE/userDeepLSD/deeplsd/models/deeplsd.py:17, in
15 from ..utils.tensor import preprocess_angle 16 from pytlsd import lsd ---> 17 from line_refinement import line_optim 20 class DeepLSD(BaseModel): 21 default_conf = { 22 'tiny': False, 23 'sharpen': True, (...) 43 }, 44 } ImportError: cannot import name 'line_optim' from 'line_refinement' (unknown location)
How to solve that?
Hi, the compilation was not successful, as stated in the error messages. It seems that you are missing the Ceres library and Gflags, or at least that they are not found by CMake. You should first fix this before trying to use any notebook.
Hello everyone! Is there a working google colab notebook example? I still can't solve
ImportError: cannot import name 'line_optim' from 'line_refinement' (unknown location)
would be much appreciated
Hello everyone! Is there a working google colab notebook example? I still can't solve
ImportError: cannot import name 'line_optim' from 'line_refinement' (unknown location)
would be much appreciated
Hi! Today I just solve this problem. First you should check the log after bash install.sh
. If the lib line_refinement
is not installed successfully, it will output the errors. In my computer, the errors are caused by the version of ceres. I change the ceres to 2.0.0 (except to default version 2.1.0), the lib line_refinement
could be bulit well.
Hope my experience can help you.
But why is line_optim still missing from my project? This is missing after me run bash install.sh,the lib line_refinement could be bulit well.
But why is line_optim still missing from my project? This is missing after me run bash install.sh,the lib line_refinement could be bulit well.
Hi, what is the output of the command pip install -e line_refinement
?
(deeplsd) zzg@ol-97468d8b-946b-451e-8dbd-1227a88f330b-deploy-7fb6b64b67-f6klp:~/project/DeepLSD$ pip install -e line_refinement Obtaining file:///home/zzg/project/DeepLSD/line_refinement Preparing metadata (setup.py) ... done Installing collected packages: line-refinement Running setup.py develop for line-refinement Successfully installed line-refinement-0.0.0
I don't even have line_optim in my line_refinement folder. I really appreciate it if you could help me. I want to use it to optimize my initial lsd algorithm. I've just commented out all the design up to this point, and it works.But I would love to try out line_optim, I have cere,glog, etc. compiled successfully, and ceres version 2.0.0
According to our experiments, DeepLSD cannot help to refine LSD (see Table 6 of the appendix of the paper). LSD is already very accurate, so the resolution of the distance field map of DeepLSD is too large to improve it.
But if you really want to try, again, what is the output your installation with pip install -e line_refinement
? If you can't import line_optim, it means that something went wrong there. line_optim is defined in the file line_refinement/line_vp_optim.cpp
if you are looking for it.
Thanks,You guys do a really good job!Thank you for your answer!
You are welcome :)
Has anyone encountered a similar problem? I tried to install on mac os and windows. Here is the traceback from jupyter:
ImportError
Traceback (most recent call last) Input In [1], in <cell line: 11>() 8 import h5py 10 from deeplsd.utils.tensor import batch_to_device ---> 11 from deeplsd.models.deeplsd import DeepLSD 12 from deeplsd.geometry.viz_2d import plot_images, plot_lines
File ~/Documents/DeepLSD/deeplsd/models/deeplsd.py:17, in
15 from ..utils.tensor import preprocess_angle
16 from pytlsd import lsd
---> 17 from line_refinement import line_optim
20 class DeepLSD(BaseModel):
21 default_conf = {
22 'tiny': False,
23 'sharpen': True,
(...)
43 },
44 }
ImportError: cannot import name 'line_optim' from 'line_refinement' (unknown location)
There was a lot of errors in the process of execution install.sh. If necessary, I will also leave the entire output when executing install.sh