Skip to content

refactor: generated CDR navigation search and costmaps - #4674

Closed
TomCC7 wants to merge 2 commits into
cc/feat/cdr-voxel-streamfrom
cc/feat/cdr-navigation-planning
Closed

TomCC7 wants to merge 2 commits into
cc/feat/cdr-voxel-streamfrom
cc/feat/cdr-navigation-planning

Conversation

@TomCC7

@TomCC7 TomCC7 commented Oct 20, 2026

Copy link
Copy Markdown
Member

A* accepts generated OccupancyGrid and returns generated Path without reconstructing source timestamps through floats. The existing Python search works on numeric cells; the existing compiled C++ extension uses the same boundary. Legacy callers retain legacy Path output while the remaining navigation consumers migrate. Both navigation-map strategies preserve generated metadata.

Parent: #4673. Project: https://linear.app/dimensional/project/message-encoding-refactor-05a3ddb4af3e/overview

Category Files Change
Planning boundary 1 Shared numeric search and generated/legacy path construction
Navigation costmaps 1 Retain input value identity through existing operations
Tests 1 Both actual backends, obstacle/unknown routes, origin rotation, exact metadata and ownership
CI 1 Installed-wheel provenance and focused checks

After installing this commit, run this offline example (defaults to the main wheel's compiled C++ A*):

import numpy as np
from dimos.messages.std_msgs.msg import Header
from dimos.msgs.occupancy import occupancy_from_array
from dimos.msgs.time import time_from_nanoseconds, to_nanoseconds
from dimos.navigation.go2.replanning_a_star.min_cost_astar import min_cost_astar

stamp = 1700000000123456789
costmap = occupancy_from_array(
    np.zeros((5, 5), dtype=np.int8), resolution=1.0,
    header=Header(frame_id="map", stamp=time_from_nanoseconds(stamp)),
)
path = min_cost_astar(costmap, goal=(4, 4), start=(0, 0))
assert path is not None
assert path.poses[-1].pose.position.x == 4
assert to_nanoseconds(path.header.stamp) == stamp

Validation: 20 focused source and 20 installed-wheel tests; 4 existing A* and 2 navigation-map golden regressions; strict typing of two production files; applicable hooks; normal main wheel build; full runtime pip check (198 packages). Exact snippet above passes against installed main wheel. Six project fixtures were SHA256/size verified before safe extraction. The legacy timed Python/C++ comparison test was deliberately not run under the benchmark pause. No performance, hardware or GitHub CI result is claimed. This layer does not yet migrate the GlobalPlanner/controller ports or remove legacy value types.

@TomCC7 TomCC7 closed this Oct 20, 2026
@TomCC7
TomCC7 deleted the cc/feat/cdr-navigation-planning branch October 20, 2026 18:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant