Reputation: 37
Is there a way where I can import both opencv2 and rospy successfully in python3. Because right now I get an error.
Traceback (most recent call last): File "", line 1, in ImportError: /opt/ros/kinetic/lib/python2.7/dist-packages/cv2.so: undefined symbol: PyCObject_Type
removing the line "source /opt/ros/kinetic/setup.bash" from my bash file solves the problem of importing opencv but now I cant import rospy
Upvotes: 0
Views: 2247
Reputation: 101
This happens since ROS creates its own open cv ,which is compatible with python2 only.To solve this
Upvotes: 0