feat(blueprint): click-to-navigate for Go2 via rerun viewer#1392
Closed
spomichter wants to merge 8 commits intodevfrom
Closed
feat(blueprint): click-to-navigate for Go2 via rerun viewer#1392spomichter wants to merge 8 commits intodevfrom
spomichter wants to merge 8 commits intodevfrom
Conversation
adds geometry_msgs.PointStamped following the PoseStamped pattern: - inherits from dimos_lcm PointStamped + Timestamped mixin - lcm_encode/lcm_decode for binary roundtrip - to_rerun() → rr.Points3D - to_pose_stamped() → PoseStamped with identity orientation - plum.dispatch constructors (x/y/z, Vector3, list, kwargs) - conforms to DimosMsg protocol - 30 unit tests enables the rerun viewer click-to-navigate pipeline: viewer publishes PointStamped to /clicked_point via LCM, any module subscribes via LCMTransport and converts to PoseStamped for navigation. DIM-643
- replace multi-dispatch constructors with single __init__(x, y, z, ts, frame_id) - inherit from Point(LCMPoint) instead of Vector3(LCMVector3) - add Point wrapper class for geometry_msgs.Point - simplify tests to focus on LCM roundtrip per review feedback addresses review comments from leshy on PR #1388
3 focused tests: lcm roundtrip, Point inheritance, PoseStamped conversion
Point is a separate LCM message type, should have its own file like Vector3, Quaternion, Pose, etc.
Wire Rerun viewer /clicked_point (PointStamped via LCM) to the ReplanningAStarPlanner's goal_request stream (PoseStamped). The conversion happens at the transport layer via ClickedPointTransport, which subscribes to /clicked_point LCM, calls PointStamped.to_pose_stamped(), and delivers PoseStamped to stream subscribers. No new DimOS Module needed. New files: - _clicked_point_transport.py: PubSubTransport that bridges PointStamped → PoseStamped - unitree_go2_click_nav.py: Blueprint wiring basic + mapping + planner + click transport - test_clicked_point_transport.py: 4 unit tests (all passing) Closes DIM-643
Contributor
Author
|
slop |
Contributor
Greptile SummaryImplements click-to-navigate for Unitree Go2 by bridging Rerun viewer clicks to the planner's goal input. The PR adds:
The implementation is clean and follows existing codebase patterns. All tests pass (4/4 for transport, 3/3 for PointStamped). The type conversion lives entirely at the transport layer, avoiding the need for a bridge module. Confidence Score: 5/5
Important Files Changed
Sequence DiagramsequenceDiagram
participant User
participant Rerun as Rerun Viewer
participant LCM as LCM Bus
participant Transport as ClickedPointTransport
participant Planner as ReplanningAStarPlanner
participant Robot as Go2 Robot
User->>Rerun: Click on map
Rerun->>LCM: Publish PointStamped<br/>/clicked_point
LCM->>Transport: Receive PointStamped(x, y, z)
Transport->>Transport: to_pose_stamped()<br/>(add identity quaternion)
Transport->>Planner: PoseStamped via goal_request
Planner->>Planner: Plan path to goal
Planner->>Robot: Navigate to clicked location
Last reviewed commit: b161663 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
wires rerun viewer
/clicked_point(PointStamped via LCM) → plannergoal_request(PoseStamped) with zero new modules.what
ClickedPointTransport— aPubSubTransport[PoseStamped]that subscribes to/clicked_pointPointStamped LCM, calls.to_pose_stamped(), and delivers PoseStamped to stream subscribers. the conversion lives entirely at the transport layer.unitree_go2_click_navblueprint — basic robot + voxel mapper + cost mapper + replanning a* planner, with the click transport ongoal_request. click in rerun → robot navigates.why
we explicitly decided no bridge module for this. LCM transport was chosen to avoid exactly that. the type conversion is one method call — a custom transport handles it cleanly.
files
_clicked_point_transport.py— the converting transport (~30 lines of logic)unitree_go2_click_nav.py— blueprint definitiontest_clicked_point_transport.py— 4 unit tests, all passingtests
note
depends on #1388 (
feat/pointstamped-msg— PointStamped type +to_pose_stamped())also: the planner has both
goal_requestandtargetasIn[PoseStamped]feeding the same handler. an alternative is to wire clicks totargetinstead, which lets you keep frontier exploration + click nav simultaneously viaunitree_go2.transports({("target", PoseStamped): ClickedPointTransport()}). went withgoal_requestfor now as a standalone click-nav blueprint.