Skip to content
This repository has been archived by the owner on Jan 23, 2024. It is now read-only.

Error when compiling on computers with Nvidia GPU #8

Open
gocarlos opened this issue Jan 12, 2017 · 6 comments
Open

Error when compiling on computers with Nvidia GPU #8

gocarlos opened this issue Jan 12, 2017 · 6 comments

Comments

@gocarlos
Copy link
Collaborator

gocarlos commented Jan 12, 2017

On some computers with NVIDIA GPU there is an error when compiling.
On a workstation with a Quadro K2100M it works, on another with a GTX 670 it does not.
Both have CUDA installed as seen when run the compilation with "-v". On both Ubuntu 14.04.05.
It works if compiled without CUDA support.

`
CMake Error at /home/gocarlos/catkin_ws/src/perception_packages/infinitam/InfiniTAM/cmake/CUDACheckCompute.cmake:10 (try_run): Attempt at a recursive or nested TRY_COMPILE in directory

/home/gocarlos/catkin_ws/build/infinitam

Call Stack (most recent call first): ITMLib/CMakeLists.txt:211 (include)

CMake Error: TRY_COMPILE attempt to remove -rf directory that does not contain CMakeTmp:/home/gocarlos/catkin_ws/build/infinitam
CMake Error at /home/gocarlos/catkin_ws/src/perception_packages/infinitam/InfiniTAM/ITMLib/CMakeLists.txt:214 (string):
string sub-command REPLACE requires at least four arguments.

INFOOpenNI found: FALSE
make: *** [cmake_check_build_system] Error 1
cd /home/gocarlos/catkin_ws/build/infinitam; catkin build --get-env infinitam | catkin env -si /usr/bin/make cmake_check_build_system; cd -
`

@gocarlos
Copy link
Collaborator Author

Eventually it would be a good thing to make the tests on a machine capable of CUDA.

@gocarlos
Copy link
Collaborator Author

On the computer, which has problems with CUDA, this script runs fine.

@arpit15
Copy link

arpit15 commented Feb 26, 2017

@gocarlos A simple hack is to put the following line just before cuda_compute_capability check which could be easily found by checking your GPU compute capability(which was 3.5 in my case).
set(CUDA_COMPUTE_CAPABILITY 3.5)

Still I receive the following error
string sub-command REPLACE requires at least four arguments.

which I think is because the in string function is empty. So to make it work I did another hack of using CUDA_ARCH instead of CUDA_ARCH_LIST in the following for loop.
My CMakeLists.txt after making changes is as this. It would be great if you could make the pull request with your permanent fix to such problem.

@gocarlos
Copy link
Collaborator Author

gocarlos commented Mar 4, 2017

@arpit15 I didn't find a solution for that problem so far, currently I'm using Infinitam without CUDA (#set(WITH_CUDA FALSE) in CMakeLists.txt) .

is your solution working then with CUDA? have you seen if its using CUDA when you start it?

@wk738126046
Copy link

Hi @gocarlos did you solve the problem when its using CUDA?

@gocarlos
Copy link
Collaborator Author

humm, this was 3 years ago... I don't remember if I had a solution...
I'm not working in robotics anymore...

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

No branches or pull requests

3 participants