ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
1

vision_opencv can't be found by ROS but it's installed

asked 2014-08-26 11:16:44 -0500

Metalzero2 gravatar image

I was trying to make a package using the catkin_create_pkg but later it gives me an error for a package I have.

My command was:

 catkin_create_pkg opencv_ros sensor_msgs cv_bridge roscpp std_msgs vision_opencv

and it says that is was successful, after I run this command:

rospack depends1 opencv_ros

and I get this error:

[rospack] Error: package 'opencv_ros' depends on non-existent package 'vision_opencv' and rosdep claims that it is not a system dependency. Check the ROS_PACKAGE_PATH or try calling 'rosdep update'

the problem is that the package exist. If I run the command:

roscd vision_opencv

it takes me to this location

/opt/ros/indigo/share/vision_opencv

and the folder of the package is next to all the other packages. The only thing that looked weird is that the folder has only a package.xml file in it.

What I want to be able to is use opencv in ROS. Say that I only want to use opencv functions with out moving images form one node to the other (all the loading and processing in one file) what else do I need except vision_opencv package (and making changes in the CMakeList.txt and pagkage.xml) ? I am using ubuntu 14.04 64bit with ROS indigo. I use the catkin system.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
2

answered 2014-08-26 11:41:53 -0500

The essential problem is that vision_opencv is a metapackage, not a package. A package should never depend, actually, it cannot depend on a metapackage. There is a great discussion about why this is the case here.

In your package, depending on cv_bridge should be enough. Note that the package.xml in cv_bridge adds a bunch of system dependencies (such as libopencv-dev).

edit flag offensive delete link more

Comments

@jarvisschultz Yes, now I see the problem. Now when I was building some simple code it works fine (by using cv_brinde only) but when I try to put some other code with Surf or Sift (from openCV) it gives me error. Where do I need to look to solve this problem (I mean in what file)?

Metalzero2 gravatar image Metalzero2  ( 2014-08-27 03:25:36 -0500 )edit

I'm guessing that your issue is related Surf and Sift moving to a "nonfree" module that doesn't seem to be installed with the apt-get packages on 14.04. See this question/answer

jarvisschultz gravatar image jarvisschultz  ( 2014-08-27 11:11:09 -0500 )edit

@jarvisschultz The same code works fine when I run it in "Code::Blocks" and the "nonfree" header is in my openCV folder. Will it make a difference if I build ROS from source instead of installing it the recommended way (according to the tutorials) ?

Metalzero2 gravatar image Metalzero2  ( 2014-08-27 12:06:42 -0500 )edit

Question Tools

1 follower

Stats

Asked: 2014-08-26 11:16:44 -0500

Seen: 2,440 times

Last updated: Aug 26 '14