Ask Your Question
0

Unable to run cameracalibration: module cv2 not found

asked 2011-08-08 08:04:08 -0500

avin111 gravatar image

updated 2014-01-28 17:10:10 -0500

ngrennan gravatar image

I am trying to run the camera calibration for my videre stereo camera's.I built the camera calibration package and it did nt give any errors.But when i am trying the camera calibrator node it is givving erors like "no module cv2 found".I tried to find find cv2.so but i found only cv.so.So i commented out import cv2 and just used import cv.Also i changed everywhere in the code where there is cv2 to cv.Now when i am trying to run the node i am getting the following errors.

Exception in thread Thread-4:

Traceback (most recent call last):

File "/usr/lib/python2.6/threading.py", line 532, in __bootstrap_inner

self.run()

File "/home/srik/ros/image_pipeline/camera_calibration/nodes/cameracalibrator.py", line 73,

in run

self.function(m)

File "/home/srik/ros/image_pipeline/camera_calibration/nodes/cameracalibrator.py", line

146, in handle_stereo

self.redraw_stereo(drawable)

File "/home/srik/ros/image_pipeline/camera_calibration/nodes/cameracalibrator.py", line

292, in redraw_stereo

if len(drawable.params) != 0:

TypeError: object of type 'NoneType' has no len()

I am stuck at this point.I dont know how to proceed from here.Any suggestions would be greatly appreciated.Thanking you

edit retag flag offensive close merge delete

Comments

Are you running against Diamondback or E-Turtle beta or trunk?
Eric Perko gravatar image Eric Perko  ( 2011-08-08 08:06:35 -0500 )edit
I am running ros diamondback on Ubuntu 10.04..
avin111 gravatar image avin111  ( 2011-08-08 08:11:26 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
1

answered 2011-08-08 08:37:12 -0500

Eric Perko gravatar image

This looks like you have mismatched versions of code. The Diamondback version of camera_calibration does an import cv, not an import cv2 (source is here). However, trunk (i.e. E-Turtle development) does do an import cv2 (source is here). So if you were running all Diamondback code, there shouldn't have been an import cv2 in the first place. The rest of your errors likely follow from E-Turtle using a newer version of OpenCV than Diamondback.

Make sure that all of your code is checked out from Diamondback tags or branches and not image_pipeline trunk.

edit flag offensive delete link more

Comments

Really thanks for the quick reply...It worked.....Thank you
avin111 gravatar image avin111  ( 2011-08-08 09:16:41 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2011-08-08 08:04:08 -0500

Seen: 689 times

Last updated: Aug 08 '11