Skip to content

feat(relative_map): routing-based local planning without HD maps#226

Draft
Copilot wants to merge 2 commits into
mainfrom
copilot/implement-local-planning
Draft

feat(relative_map): routing-based local planning without HD maps#226
Copilot wants to merge 2 commits into
mainfrom
copilot/implement-local-planning

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 25, 2026

RelativeMapComponent had no way to receive a routing destination — it relied entirely on pre-recorded navigation lines from Dreamview. This meant destination-driven autonomous navigation required HD map support.

Changes

RelativeMapComponent — subscribe to routing

  • Adds reader for /apollo/routing_request; wires it to RelativeMap::OnRoutingRequest()

RelativeMap — routing ingestion + destination lifecycle

  • OnRoutingRequest() extracts the last waypoint's ENU pose and calls NavigationLane::SetDestination()
  • Per-cycle destination-reached check (FLAGS_destination_reached_threshold, default 5 m) clears the goal on arrival

NavigationLane — goal-directed path generation

New public API: SetDestination(), ClearDestination(), HasDestination(), IsDestinationReached(threshold)

Modified GeneratePath() fallback (when no pre-recorded navigation lines):

  • Destination set + lane markers visibleConvertLaneMarkerToPath() for lane-keeping (lateral position from perception)
  • Destination set, no lane markers → new GenerateDestinationBearingPath(): converts ENU delta to FLU via Vec2d{dx,dy}.Rotate(-heading) (same convention as ConvertNavigationLineToPath), emits a straight path along the bearing
// ENU → FLU bearing path toward destination
auto flu_dir = Vec2d{dx, dy}.Rotate(-original_pose_.heading());
const double bearing_angle = std::atan2(flu_dir.y(), flu_dir.x());
const double flu_ux = flu_dir.x() / dist_to_dest;
const double flu_uy = flu_dir.y() / dist_to_dest;

BUILD + gflags

  • Adds routing_cc_proto dependency to relative_map_lib and relative_map_component_lib
  • Adds --destination_reached_threshold flag (default 5.0 m)

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • releases.bazel.build
    • Triggering command: /usr/local/lib/node_modules/@bazel/bazelisk/bazelisk-linux_amd64 /usr/local/lib/node_modules/@bazel/bazelisk/bazelisk-linux_amd64 build //modules/world_model/relative_map:relative_map_component_lib (dns block)

If you need me to access, download, or install something from one of these locations, you can either:

Original prompt

relative_map中如果实现局部规划目前能够最快的实现跑起来吗?例如我想实现通过routing发送目的地之后,RelativeMapComponent能够根据局部地图进行规划,并且最终到达目的地,给出详细的分析和建议,记住你需要保证的是不依赖高精度地图,而是实时感知的结果进行规划,参考业界优秀实践,对现有模块给出改进建议,以及如何快速跑通产品原型

Created from VS Code.


📱 Kick off Copilot coding agent tasks wherever you are with GitHub Mobile, available on iOS and Android.

- Subscribe RelativeMapComponent to /apollo/routing_request
- Add RelativeMap::OnRoutingRequest() to extract destination from last
  waypoint and call NavigationLane::SetDestination()
- Add NavigationLane destination API: SetDestination, ClearDestination,
  HasDestination, IsDestinationReached
- Add NavigationLane::GenerateDestinationBearingPath(): straight path
  in FLU coordinates toward destination using ENU->FLU rotation
- Modify GeneratePath() fallback: prefer destination path when routing
  destination is set, blending with lane markers when available
- Add destination-reached check (configurable via FLAGS) that clears
  the destination when vehicle is within threshold distance
- Add destination_reached_threshold gflag (default: 5.0m)
- Add routing_cc_proto dependency to relative_map_lib and
  relative_map_component_lib in BUILD

Co-authored-by: daohu527 <10419854+daohu527@users.noreply.github.com>
Agent-Logs-Url: https://github.com/wheelos/apollo-lite/sessions/855d3bbd-b98d-44ff-ab04-7db4ddfb6f3a
Copilot AI changed the title [WIP] Implement local planning in relative_map using routing feat(relative_map): routing-based local planning without HD maps Mar 25, 2026
Copilot AI requested a review from daohu527 March 25, 2026 14:44
@daohu527 daohu527 added the draft label Apr 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants