Using CUDA after building with CMake

asked 2018-03-04 00:11:46 -0600

nicksoto24 gravatar image

updated 2018-03-04 21:23:52 -0600

Hello guys,

I've just finished using CMake to download all the files including the CUDA files which is what I really want to use. How am I actually able to use CUDA in my projects? I've tried including the header that one of the examples had, but that header isn't coming up so the "gpu"s aren't coming up either.

All help is appreciated!

edit retag flag offensive close merge delete

Comments

1

I don't understand your question. if you build opencv with cuda you must now call cuda function that's all.

All cuda functions are in modules cudaarithm to cudev

LBerger gravatar imageLBerger ( 2018-03-04 03:01:17 -0600 )edit

Sorry that my question wasn't very clear. I'm trying to do image processing and in the documentation there's the gpu module but I can't seem to call to them or get access to that namespace. The cuda one does come up though, I didn't even realize. Thank you for that, but I'm not sure why the gpu module isn't showing.

nicksoto24 gravatar imagenicksoto24 ( 2018-03-04 03:43:27 -0600 )edit
1

"there's the gpu module" -- which opencv version is it ? 2.4 had a "gpu" module, 3.x does not. (more like cudaxxx now)

please use current docs , and try again

berak gravatar imageberak ( 2018-03-04 03:59:53 -0600 )edit

Oh, okay. So it's just an older module then. Thank you for the answer!

nicksoto24 gravatar imagenicksoto24 ( 2018-03-04 13:09:05 -0600 )edit

please add the cmake output to your question

berak gravatar imageberak ( 2018-03-04 13:49:13 -0600 )edit

I'm not sure what you mean by my output. The #include functions for cuda aren't showing up. Is there something that I should be putting in my projects?

nicksoto24 gravatar imagenicksoto24 ( 2018-03-04 17:31:29 -0600 )edit

did it build with any support for cuda ? you had to run cmake to configure it before make. show us the console output, it will contain some hints !

berak gravatar imageberak ( 2018-03-04 19:14:09 -0600 )edit

I added it with support for CUDA. I can't share the text files/log files because the post only allows picture extensions. The cuda module seems to be enabled, but the #include options for the extra functions aren't showing up when I try to include them. I'm not sure if I have to add them into my project library.

nicksoto24 gravatar imagenicksoto24 ( 2018-03-04 21:28:54 -0600 )edit
1

please edit your question, paste the output into it.

berak gravatar imageberak ( 2018-03-05 02:27:28 -0600 )edit