Updated README with examples of usage of the MIT stata center dataset based on jfr2018 paper. #1350

This commit is contained in:
matlabbe
2025-09-18 04:43:24 +00:00
parent f601fd43bf
commit f9ad71a7af
12 changed files with 324 additions and 121 deletions
@@ -4,13 +4,13 @@ import sys
from tf.msg import tfMessage
if len(sys.argv) < 2:
print 'Usage: $ python extract_rgbd.py "2012-01-25-12-14-25"'
print('Usage: $ python extract_rgbd.py "2012-01-25-12-14-25"')
sys.exit(0)
bagName = sys.argv[1]
with rosbag.Bag(bagName + '_rgbd.bag', 'w') as outbag:
print 'Processing ' + bagName + '.bag...'
print(f'Processing {bagName}.bag...')
for topic, msg, t in rosbag.Bag(bagName + '.bag').read_messages():
if topic == "/tf" or topic == "/camera/depth/image_raw" or topic == "/camera/rgb/camera_info" or topic == "/camera/rgb/image_raw":
outbag.write(topic, msg, t)
print 'Output: ' + bagName + '_out.bag'
print(f'Output: {bagName}_rgbd.bag')