Aggregate: optimizer build, TRW-S, lazy costs, and split-dim seed - #519
Draft
AlbedoWang wants to merge 5 commits into
Draft
Aggregate: optimizer build, TRW-S, lazy costs, and split-dim seed#519AlbedoWang wants to merge 5 commits into
AlbedoWang wants to merge 5 commits into
Conversation
AlbedoWang
force-pushed
the
kaijian/final_optimize
branch
2 times, most recently
from
July 24, 2026 06:09
b5ebbeb to
6023876
Compare
AlbedoWang
force-pushed
the
kaijian/final_optimize
branch
from
July 27, 2026 03:03
6023876 to
3f897d0
Compare
This was referenced Jul 27, 2026
AlbedoWang
force-pushed
the
kaijian/final_optimize
branch
from
July 27, 2026 03:12
3f897d0 to
0d9ee3d
Compare
AlbedoWang
force-pushed
the
kaijian/final_optimize
branch
2 times, most recently
from
July 28, 2026 02:33
e2b379f to
bfbe4fb
Compare
Preserve ILP behavior while skipping duplicate redistribution work, compacting cluster links, and pruning invalid decision edges. Authored with Claude.
Keep ILP as the default while supporting integral LP extraction and lower-bound certificates on the same optimizer problem. Authored with Claude.
Build a pairwise factor graph from the existing optimizer costs and constraints, then solve it with TRW-S and constrained local-search polish. Authored with Claude.
Skip PuLP and eager edge-cost materialization for the approximate solver, derive constraint topology directly, and compute memoized factor costs on demand. Authored with Claude.
Solve each mesh dimension independently, preserve its fabric topology, and project local_map contracts onto the active dimension before restricting the final search. Authored with Claude.
AlbedoWang
force-pushed
the
kaijian/final_optimize
branch
from
July 28, 2026 03:23
bfbe4fb to
b374f7f
Compare
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.
Review stack
local_mapprojection.This Draft keeps the complete top-of-stack diff and profiling context in one place. Its head mirrors #523. The four stacked PRs are the merge targets.
Final-tree policy
The stack was rebuilt from this PR's final implementation rather than replaying PR484/PR511/PR513 wholesale. This preserves the selected main+PR511 propagation behavior and excludes abandoned PR484 annotation/DP/min-sum paths.
Compared with the previous aggregate head, implementation files are unchanged except for the direct-LP objective fix. Additional differences remove machine-local configuration and unrelated artifacts, update tests for node-level cluster links, and add a fast-build equivalence regression.
PR514 remains the source of truth for 3+D MoE
local_map, flattened EP groups, efsdp boundary placements, and backward-gradient duality.Validation
The five new failures from the previous aggregate CI are resolved: LP constraint feasibility, export JSON cluster links, both repeated-subgraph dtype constraints, and direct split-seed LP objective initialization.
Corrected MoE profiles
Profiles use fake tensors and a fake process group; they measure search latency and host RSS, not distributed execution. Each result is one deterministic run; variance is unavailable.
(8,8)uses direct unseeded lazy TRW-S, not split-dim: 33.05s versus 37.02s full-cost TRW-S, with identical objective45680.5744and placement.(2,4,8)corrected split + lazy TRW-S: 111.15s, objective44260.3021,+1.698%versus unrestricted full/lazy43521.3868. The unrestricted solution lies inside radius 2; the delta is compute0, communication+675.915, transition+63.(8,2,2,2)corrected split + lazy TRW-S: 201.41s, objective47952.1351, peak RSS 3.44 GiB. Unrestricted eager and lazy searches exceeded 20 minutes, so no objective gap or speedup is claimed. No 4D sampling experiment was run.Authored with Claude.
Inherited base checks
PR514 currently has the same unrelated repo-wide mypy failure in
autoparallel/tools/overlap_simulator/run.py:404and the same TorchTitan upstream config-registry failure. The stack does not include unrelated fixes for either path.