Robotics StackExchange | Archived questions

reading a ROS Image

Hi, we are facing the issue of

ImportError: /lib/x8664-linux-gnu/libp11-kit.so.0: undefined symbol: ffitypepointer, version LIBFFIBASE_7.0

when trying to use the cvbridge function depthcv = self.cvbridge.imgmsgtocv2(depth) .

So we instead switched to converting ROS Images into numpy arrays using

depthcv = np.frombuffer(depth.data, dtype=np.uint8).reshape(depth.height, depth.width, -1) imgray = cv2.cvtColor(im, cv2.COLOR_RGB2GRAY)

It now returns the data as array of NaN. Any suggestion to correctly read the images.

Asked by 07hokagw on 2023-06-07 22:18:25 UTC

Comments

Answers