Skip to content

Fix bugreport1, use better force calculation using nearest-point-on-segment #127

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
May 14, 2025

Conversation

seveibar
Copy link
Contributor

  • new endpoint force calculation approach
  • update to endpoint force approach
  • add boundary padding for hdpolyline

Copy link

vercel bot commented May 14, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
capacity-node-autorouter ✅ Ready (Inspect) Visit Preview 💬 Add feedback May 14, 2025 10:47pm

Comment on lines +472 to +473
const baseForceMargin = this.viaDiameter / 2
const forceMargin = baseForceMargin + this.BOUNDARY_PADDING
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The MultiHeadPolyLineIntraNodeSolver2 class is using this.BOUNDARY_PADDING but this property isn't declared or initialized in this class. Since this class extends MultiHeadPolyLineIntraNodeSolver, it should properly declare and initialize this property.

Please add:

BOUNDARY_PADDING: number

as a class property, and initialize it in the constructor with:

this.BOUNDARY_PADDING = params.hyperParameters?.BOUNDARY_PADDING ?? 0.05

This matches the implementation in the parent class and ensures consistent behavior.

Spotted by Diamond

Is this helpful? React 👍 or 👎 to let us know.

@seveibar seveibar merged commit 76a2b5a into main May 14, 2025
6 checks passed
@seveibar seveibar deleted the bugreport branch May 14, 2025 23:30
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