@tscircuit/capacity-autorouter 0.0.61 → 0.0.62
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +1 -0
- package/dist/index.js +19 -6
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -704,6 +704,7 @@ declare class HyperSingleIntraNodeSolver extends HyperParameterSupervisorSolver<
|
|
|
704
704
|
constructorParams: ConstructorParameters<typeof IntraNodeRouteSolver>[0];
|
|
705
705
|
solvedRoutes: HighDensityIntraNodeRoute$1[];
|
|
706
706
|
nodeWithPortPoints: NodeWithPortPoints;
|
|
707
|
+
connMap?: ConnectivityMap;
|
|
707
708
|
constructor(opts: ConstructorParameters<typeof IntraNodeRouteSolver>[0]);
|
|
708
709
|
getCombinationDefs(): string[][];
|
|
709
710
|
getHyperParameterDefs(): ({
|
package/dist/index.js
CHANGED
|
@@ -3897,7 +3897,12 @@ var IntraNodeRouteSolver = class extends BaseSolver {
|
|
|
3897
3897
|
y: points[points.length - 1].y,
|
|
3898
3898
|
z: points[points.length - 1].z
|
|
3899
3899
|
},
|
|
3900
|
-
obstacleRoutes: this.solvedRoutes
|
|
3900
|
+
obstacleRoutes: this.connMap ? this.solvedRoutes.filter(
|
|
3901
|
+
(sr) => !this.connMap.areIdsConnected(
|
|
3902
|
+
sr.connectionName,
|
|
3903
|
+
connectionName
|
|
3904
|
+
)
|
|
3905
|
+
) : this.solvedRoutes,
|
|
3901
3906
|
futureConnections: this.unsolvedConnections,
|
|
3902
3907
|
layerCount: 2,
|
|
3903
3908
|
hyperParameters: this.hyperParameters,
|
|
@@ -8837,9 +8842,11 @@ var HyperSingleIntraNodeSolver = class extends HyperParameterSupervisorSolver {
|
|
|
8837
8842
|
constructorParams;
|
|
8838
8843
|
solvedRoutes = [];
|
|
8839
8844
|
nodeWithPortPoints;
|
|
8845
|
+
connMap;
|
|
8840
8846
|
constructor(opts) {
|
|
8841
8847
|
super();
|
|
8842
8848
|
this.nodeWithPortPoints = opts.nodeWithPortPoints;
|
|
8849
|
+
this.connMap = opts.connMap;
|
|
8843
8850
|
this.constructorParams = opts;
|
|
8844
8851
|
this.MAX_ITERATIONS = 25e4;
|
|
8845
8852
|
this.GREEDY_MULTIPLIER = 5;
|
|
@@ -8983,6 +8990,7 @@ var HyperSingleIntraNodeSolver = class extends HyperParameterSupervisorSolver {
|
|
|
8983
8990
|
if (hyperParameters.MULTI_HEAD_POLYLINE_SOLVER) {
|
|
8984
8991
|
return new MultiHeadPolyLineIntraNodeSolver3({
|
|
8985
8992
|
nodeWithPortPoints: this.nodeWithPortPoints,
|
|
8993
|
+
connMap: this.connMap,
|
|
8986
8994
|
hyperParameters
|
|
8987
8995
|
});
|
|
8988
8996
|
}
|
|
@@ -9071,7 +9079,7 @@ var HighDensitySolver = class extends BaseSolver {
|
|
|
9071
9079
|
if (this.failedSolvers.length > 0) {
|
|
9072
9080
|
this.solved = false;
|
|
9073
9081
|
this.failed = true;
|
|
9074
|
-
this.error = `Failed to solve ${this.failedSolvers.length} nodes, ${this.failedSolvers.slice(0, 5).map((fs) => fs.nodeWithPortPoints.capacityMeshNodeId)}
|
|
9082
|
+
this.error = `Failed to solve ${this.failedSolvers.length} nodes, ${this.failedSolvers.slice(0, 5).map((fs) => fs.nodeWithPortPoints.capacityMeshNodeId)}. err0: ${this.failedSolvers[0].error}.`;
|
|
9075
9083
|
return;
|
|
9076
9084
|
}
|
|
9077
9085
|
this.solved = true;
|
|
@@ -13236,13 +13244,18 @@ var CapacityPathingMultiSectionSolver = class extends BaseSolver {
|
|
|
13236
13244
|
OPTIMIZATION_SCHEDULE = [
|
|
13237
13245
|
{
|
|
13238
13246
|
MAX_ATTEMPTS_PER_NODE: 1,
|
|
13239
|
-
MAX_EXPANSION_DEGREES:
|
|
13240
|
-
MINIMUM_PROBABILITY_OF_FAILURE_TO_OPTIMIZE: 0.
|
|
13247
|
+
MAX_EXPANSION_DEGREES: 3,
|
|
13248
|
+
MINIMUM_PROBABILITY_OF_FAILURE_TO_OPTIMIZE: 0.05
|
|
13241
13249
|
},
|
|
13242
13250
|
{
|
|
13243
13251
|
MAX_ATTEMPTS_PER_NODE: 2,
|
|
13244
|
-
MAX_EXPANSION_DEGREES:
|
|
13245
|
-
MINIMUM_PROBABILITY_OF_FAILURE_TO_OPTIMIZE: 0.
|
|
13252
|
+
MAX_EXPANSION_DEGREES: 5,
|
|
13253
|
+
MINIMUM_PROBABILITY_OF_FAILURE_TO_OPTIMIZE: 0.2
|
|
13254
|
+
},
|
|
13255
|
+
{
|
|
13256
|
+
MAX_ATTEMPTS_PER_NODE: 3,
|
|
13257
|
+
MAX_EXPANSION_DEGREES: 7,
|
|
13258
|
+
MINIMUM_PROBABILITY_OF_FAILURE_TO_OPTIMIZE: 0.3
|
|
13246
13259
|
}
|
|
13247
13260
|
];
|
|
13248
13261
|
get currentSchedule() {
|