feat: capture head and waist RGB-D data

This commit is contained in:
2026-08-10 16:40:00 +08:00
parent 4ba0f63758
commit d02b99d2aa
8 changed files with 388 additions and 16 deletions

View File

@@ -40,7 +40,36 @@ import sys
import tomllib
with open(sys.argv[1], "rb") as stream:
tomllib.load(stream)
document = tomllib.load(stream)
section = document["data_collection"]
topics = set(section["topics"])
required = set(section["required_topics"])
head_rgbd = {
"/ob_camera_head/color/image_raw/compressed",
"/ob_camera_head/color/camera_info",
"/ob_camera_head/depth/image_raw/compressedDepth",
"/ob_camera_head/depth/camera_info",
}
waist_rgbd = {
"/ob_camera_waist/color/image_raw/compressed",
"/ob_camera_waist/color/camera_info",
"/ob_camera_waist/depth/image_raw/compressedDepth",
"/ob_camera_waist/depth/camera_info",
}
assert head_rgbd <= topics, "head RGB-D topics must stay in the recording whitelist"
assert waist_rgbd <= topics, "waist RGB-D topics must stay in the recording whitelist"
assert waist_rgbd <= required, "live waist RGB-D topics must stay required"
assert head_rgbd.isdisjoint(required), "inactive head RGB-D must not block recording"
assert {
"/ob_camera_waist/color/metadata",
"/ob_camera_waist/depth/metadata",
"/tf_static",
} <= required
assert section["minimum_topic_rates_hz"] == {
"/ob_camera_waist/color/image_raw/compressed": 20.0,
"/ob_camera_waist/depth/image_raw/compressedDepth": 20.0,
}
assert section["minimum_free_gib"] >= 100.0
print("config.toml parse passed")
PY