Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

OpenCV python bindings in cturtle

Hi.

I'm trying to get the OpenCV python bindings up and running in CTurtle (on Ubuntu 10.04). I have the ros-cturtle-vision-opencv package installed but that only seems to set up the C++ API correctly.

I see that there is a /opt/ros/cturtle/stacks/vision_opencv/opencv2/opencv/lib/python2.6/site-packages/ directory in the package but that directory is empty.

Now, there is an python-opencv package that I can see in aptitude but as far as I understand, that package depends on the official opencv packages from the Ubuntu repository which means that installing that would result in me having two versions of OpenCV installed (one from the ros package which the C++ stuff would link against and then also the official ones from the Ubuntu repository which should then work for Python). I don't really like that idea! Nevertheless I tried installing it but I still couldn't load the cv module in Python. It turns out that I had to manually add '/usr/share/pyshared/opencv' to my Python path?!

I also found a PPA repository for OpenCV 2.1 (http://opencv.willowgarage.com/wiki/Ubuntu_Packages) but basically that has the same problem. It does provide a newer version of OpenCV than the one in the official Ubuntu repository but it's still a different version than the one from the ROS package.

So my question is basically, how can I enable the Python bindings for the OpenCV that comes with ROS CTurtle? In other words, how and with what do I populate the /opt/ros/cturtle/stacks/vision_opencv/opencv2/opencv/lib/python2.6/site-packages/ directory?

Kind regards, Stefán Freyr.

OpenCV python bindings in cturtle

Hi.

I'm trying to get the OpenCV python bindings up and running in CTurtle (on Ubuntu 10.04). I have the ros-cturtle-vision-opencv package installed but that only seems to set up the C++ API correctly.

I see that there is a /opt/ros/cturtle/stacks/vision_opencv/opencv2/opencv/lib/python2.6/site-packages/ directory in the package but that directory is empty.

Now, there is an python-opencv package that I can see in aptitude but as far as I understand, that package depends on the official opencv packages from the Ubuntu repository which means that installing that would result in me having two versions of OpenCV installed (one from the ros package which the C++ stuff would link against and then also the official ones from the Ubuntu repository which should then work for Python). I don't really like that idea! Nevertheless I tried installing it but I still couldn't load the cv module in Python. It turns out that I had to manually add '/usr/share/pyshared/opencv' to my Python path?!

I also found a PPA repository for OpenCV 2.1 (http://opencv.willowgarage.com/wiki/Ubuntu_Packages) but basically that has the same problem. It does provide a newer version of OpenCV than the one in the official Ubuntu repository but it's still a different version than the one from the ROS package.

So my question is basically, how can I enable the Python bindings for the OpenCV that comes with ROS CTurtle? In other words, how and with what do I populate the /opt/ros/cturtle/stacks/vision_opencv/opencv2/opencv/lib/python2.6/site-packages/ directory?

Kind regards, Stefán Freyr.

OpenCV python bindings in cturtle

Hi.

I'm trying to get the OpenCV python bindings up and running in CTurtle (on Ubuntu 10.04). I have the ros-cturtle-vision-opencv package installed but that only seems to set up the C++ API correctly.

I see that there is a /opt/ros/cturtle/stacks/vision_opencv/opencv2/opencv/lib/python2.6/site-packages/ directory in the package but that directory is empty.

Now, there is an python-opencv package that I can see in aptitude but as far as I understand, that package depends on the official opencv packages from the Ubuntu repository which means that installing that would result in me having two versions of OpenCV installed (one from the ros package which the C++ stuff would link against and then also the official ones from the Ubuntu repository which should then work for Python). I don't really like that idea! Nevertheless I tried installing it but I still couldn't load the cv module in Python. It turns out that I had to manually add '/usr/share/pyshared/opencv' to my Python path?!

I also found a PPA repository for OpenCV 2.1 (http://opencv.willowgarage.com/wiki/Ubuntu_Packages) but basically that has the same problem. It does provide a newer version of OpenCV than the one in the official Ubuntu repository but it's still a different version than the one from the ROS package.

So my question is basically, how can I enable the Python bindings for the OpenCV that comes with ROS CTurtle? In other words, how and with what do I populate the /opt/ros/cturtle/stacks/vision_opencv/opencv2/opencv/lib/python2.6/site-packages/ directory?

Kind regards, Stefán Freyr.