Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ---------------------------------------------------------------------------
- ImportError Traceback (most recent call last)
- <ipython-input-38-b165647910bb> in <module>
- 13 with rosbag.Bag('images.bag', 'r') as image_bag:
- 14 for topic, image_message, t in image_bag.read_messages():
- ---> 15 cv_image = bridge.imgmsg_to_cv2(image_message, "bgr8")
- 16 cv2.imshow("image", cv_image)
- 17 break
- /opt/ros/melodic/lib/python2.7/dist-packages/cv_bridge/core.py in imgmsg_to_cv2(self, img_msg, desired_encoding)
- 161 import cv2
- 162 import numpy as np
- --> 163 dtype, n_channels = self.encoding_to_dtype_with_channels(img_msg.encoding)
- 164 dtype = np.dtype(dtype)
- 165 dtype = dtype.newbyteorder('>' if img_msg.is_bigendian else '<')
- /opt/ros/melodic/lib/python2.7/dist-packages/cv_bridge/core.py in encoding_to_dtype_with_channels(self, encoding)
- 97
- 98 def encoding_to_dtype_with_channels(self, encoding):
- ---> 99 return self.cvtype2_to_dtype_with_channels(self.encoding_to_cvtype2(encoding))
- 100
- 101 def compressed_imgmsg_to_cv2(self, cmprs_img_msg, desired_encoding = "passthrough"):
- /opt/ros/melodic/lib/python2.7/dist-packages/cv_bridge/core.py in encoding_to_cvtype2(self, encoding)
- 89
- 90 def encoding_to_cvtype2(self, encoding):
- ---> 91 from cv_bridge.boost.cv_bridge_boost import getCvType
- 92
- 93 try:
- ImportError: dynamic module does not define module export function (PyInit_cv_bridge_boost)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement