data/collect — Random‑sweep dataset capture¶
Move servos in a random circular pattern and capture synchronized camera frames
from the HTTP stream server, writing a StructuredDataset to disk.
Usage¶
# Capture 100 frames at radius 5.0, move to a waypoint before capture
s6 data collect -n 100 -r 5.0 --waypoint center -o data/random_dataset
# List available waypoints (no capture)
s6 data collect --wps
How it works¶
Connects to the robotic RPC via
PathDriver(host/port from args or stream server) and optionally moves to--waypoint.Iterates a random path (
driver.random) within the given radius; for each pose, fetches a composite frame from the FastAPI stream server and splits it into per-camera images vias6.utils.take_snapshot.Reorders camera images deterministically with
CameraIDIdentifierArucoand writes records intos6.utils.StructuredDatasetwith servo positions and images.
Key flags¶
-n/--frame-count— number of samples to capture (default 100)-r/--radius— random sweep radius--waypoint— named waypoint to move to before capture-o/--output— output dataset directory--stream-server— host of the FastAPI video stream server--rpc-host,--rpc-port,--rpc-serialization— robotic RPC settings--wps— list waypoints and exit