Ask Your Question
1

ROS Kinetic OpenCV3.2.0 Contrib and CUDA

asked 2017-04-01 14:00:22 -0500

mondi gravatar image

updated 2017-04-01 14:12:41 -0500

Hallo community,

I working currently on a vision problem and want to use cuda to fulfill some real-time contraints. To solve the vision problem I want to utilize ROS Kinetic and OpenCV.

My question is now is it possible to replace the opencv version which is delivered with ROS Kinectic (OpenCV3.2.0) with the same opencv version with enabled CUDA?

The most information how to setup and compile the correct opencv version can be found on the ROS wiki page for the opencv3 package I guess (wiki.ros.org/opencv3 section 5. Build the package). Here is described how to checkout the right repos and modify the CMAKE file in the right way. For CUDA I have to add the -DWITH_CUDA flag. Everthing right until now?

Now the complex part: Which software have to be uninstalled before installing the own compiled version and where I have to install it, so ROS can work with it naturally like with the opencv libs which are delivered with ROS Kinetic?

My second question is motivated by a statement which I also have found on the wiki page from ROS opencv3 package. There is stated that with opencv 3.2.0 it is now possible to build opencv contrib with installed opencv. This seems interesting for me because I want to modify or better add functionality to a algorithm which is implemented in opencv contrib rgbd.

Is it possible to build only the opencv contrib rgbd package as debug and working on it? At the moment I have no idea how to do it, so will be great when you can help me out.

When you have some question on your side, feel free to ask.

System: Ubuntu 16.04, CUDA8.0, ROS Kinetic, OpenCV 3.2.0

best regards,

Manuel

edit retag flag offensive close merge delete

Comments

What I would do:

  • on Ubuntu, uninstall the OpenCV version shipped by ROS using Synaptic
  • compile from source OpenCV with the appropriate options
  • link the ROS packages that need OpenCV with this version of OpenCV
Eduardo gravatar imageEduardo ( 2017-04-03 04:18:38 -0500 )edit

Did you get how to solve it, this is a good question.

waschbaer gravatar imagewaschbaer ( 2018-03-16 13:21:51 -0500 )edit

@waschbaer, please do not post an answer here, if you have a question or a comment, thank you !

berak gravatar imageberak ( 2018-03-16 13:26:26 -0500 )edit

1 answer

Sort by ยป oldest newest most voted
0

answered 2017-04-06 11:04:22 -0500

Vincent Rabaud gravatar image

You should probably ask that question on http://answers.ros.org/questions/ Build OpenCV like you would for any source package in ROS using http://wiki.ros.org/kinetic/Installat... (but have the rosinstall_generator only mention opencv3.

For creating one lib in debug only, I don't think it's feasible through CMake. You can still build OpenCV in Release and Debug mode and copy the files over, I believe that should work.

edit flag offensive delete link more
Login/Signup to Answer

Question Tools

2 followers

Stats

Asked: 2017-04-01 14:00:22 -0500

Seen: 1,895 times

Last updated: Mar 16