feat: add SameNetTraceLineMergeSolver to merge collinear same-net traces#133
Open
HarshadaGawas05 wants to merge 1 commit intotscircuit:mainfrom
Open
feat: add SameNetTraceLineMergeSolver to merge collinear same-net traces#133HarshadaGawas05 wants to merge 1 commit intotscircuit:mainfrom
HarshadaGawas05 wants to merge 1 commit intotscircuit:mainfrom
Conversation
Fixes tscircuit#34 /claim tscircuit#34 - New SameNetTraceLineMergeSolver post-processing step after TraceOverlapShiftSolver - Groups segments by net, buckets by axis coordinate within 0.01 tolerance - Greedy interval merge collapses overlapping collinear segments to one - Wired into SchematicTracePipelineSolver; all downstream solvers read mergedTraceMap - Visual repro page: site/issue-34-repro.page.tsx (before/after side by side) - 7 unit tests with exact coordinate assertions - 1 integration snapshot test - All 57 existing tests pass, zero TS errors, zero lint errors
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Author
|
@seveibar this is ready for review — all checks passing, includes before/after visual repro, 7 unit tests, and 1 integration snapshot test. Happy to make any changes requested. |
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.
Fixes #34 — Merge same-net trace lines on same X or Y axis
/claim #34
Problem
Trace segments on the same net that landed at nearly the same Y (horizontal)
or same X (vertical) coordinate after overlap shifting were rendered as
separate parallel lines instead of one clean line.
Solution
Added
SameNetTraceLineMergeSolver— a new post-processing step that runsimmediately after
TraceOverlapShiftSolver. It groups segments by net,buckets them by axis coordinate within a 0.01 tolerance, and
greedy-merges overlapping intervals into single segments.
Before
After
Full view
Files changed
lib/solvers/SameNetTraceLineMergeSolver/SameNetTraceLineMergeSolver.ts— new solverlib/solvers/SchematicTracePipelineSolver/SchematicTracePipelineSolver.ts— wired in after TraceOverlapShiftSolversite/issue-34-repro.page.tsx— before/after visual reproduction pagesite/issue-34-input.ts— shared circuit input for repro + teststests/functions/merge-same-net-trace-lines.test.ts— 7 unit tests (exact coordinate assertions)tests/examples/example-issue34.test.ts— integration snapshot testChecklist
bun test— 57 pass, 5 skip, 0 failnpx tsc --noEmit— zero errorsnpx biome check— zero errorsSchematicTracePipelineSolver.tsmodified among existing solvers