Cannot open rosbags with multiarrays.
- Distro: kinetic
- OS: Ubuntu 16.04
- Program: Matlab and python
Hello, I've encountered this problem in matlab R2018a (it works fine in R2017b) and in python. When trying to open a rosbag with any of these programs. I've attached the file I'm trying to open and the errors i get. (As i cannot attach files I've uploaded it here: https://we.tl/QvCoqIqhd1 )
Matlab R2018a
>>rosbag('10.bag')
No definition for MultiArrayLayout
Message def:
# Please look at the MultiArrayLayout message definition for
# documentation on all multiarrays.
MultiArrayLayout layout # specification of data layout
float64[] data # array of data
Python 2.7
>>> import rosbag
>>> bag = rosbag.Bag('10.bag')
>>> for topic,msg,t in bag.read_messages():
... print(msg)
File "<stdin>", line 1, in <module> (and another bunch of tracebacks)
genmsg.msg_loader.MsgNotFound: Cannot locate message [MultiArrayLayout]: unknown package [std_msgs] on search path [{}]
I've searched online and I can't find an answer.
I get the same error as you even with
rosbag check
on both Indigo and Kinetic. Searching for this issue reveals multiple people with this problem specifically when using ROS Java. Is ROS Java involved in creating this Bag file in any way?If it is (and with Matlab in the mix it's highly likely), see whether rosjava/rosjava_bootstrap#16 provides some more insight. And perhaps try the tool linked at the end of that issue.
I should also mention that I do not have this issue when creating my own bag file that contains random 3x3
std_msgs/Float64MultiArray
messages.No, the rosbags are all generated with "rosbag record -e -q "/visualcom/(.*)" from console.
But do any of the publishers use rosjava? Note: the Matlab ROS integration uses rosjava under the hood.