Complete feasible stress layouts with verified routing fallbacks
This commit is contained in:
parent
d9f0e78330
commit
a2dfb73c33
1 changed files with 1022 additions and 76 deletions
|
|
@ -28,6 +28,7 @@ from inire.tests.routing_benchmarks import (
|
|||
FALLBACK_BENCHMARK_CASES,
|
||||
VALIDATION_BENCHMARK_CASES,
|
||||
)
|
||||
from inire.tests.stress_routing_benchmarks import STRESS_BENCHMARK_CASES
|
||||
from inire.tests.terminal_bench_scenario import LENGTH_COST
|
||||
|
||||
if TYPE_CHECKING:
|
||||
|
|
@ -294,7 +295,8 @@ def _geometry_json(value: object) -> dict:
|
|||
|
||||
def main() -> None:
|
||||
broader = (*VALIDATION_BENCHMARK_CASES, *FALLBACK_BENCHMARK_CASES, *EXTERNAL_BENCHMARK_CASES)
|
||||
case_groups = {case.name: (case,) for case in (*BENCHMARK_CASES, *broader, *CROSSING_BENCHMARK_CASES)}
|
||||
corpus = (*BENCHMARK_CASES, *broader, *CROSSING_BENCHMARK_CASES, *STRESS_BENCHMARK_CASES)
|
||||
case_groups = {case.name: (case,) for case in corpus}
|
||||
case_groups.update(
|
||||
{
|
||||
"all": BENCHMARK_CASES,
|
||||
|
|
@ -304,6 +306,8 @@ def main() -> None:
|
|||
"external": EXTERNAL_BENCHMARK_CASES,
|
||||
"broad": broader,
|
||||
"crossings": CROSSING_BENCHMARK_CASES,
|
||||
"stress": STRESS_BENCHMARK_CASES,
|
||||
"corpus": corpus,
|
||||
}
|
||||
)
|
||||
defaults = RoutingOptions()
|
||||
|
|
@ -313,7 +317,7 @@ def main() -> None:
|
|||
"--case",
|
||||
choices=tuple(case_groups),
|
||||
action="append",
|
||||
help="Select a case or suite. The broad suite includes the holdout, fallback, and external suites.",
|
||||
help="Select a case or suite. Use 'corpus' to select all boards.",
|
||||
)
|
||||
parser.add_argument("--list", action="store_true", help="List the available cases.")
|
||||
parser.add_argument(
|
||||
|
|
@ -337,12 +341,14 @@ def main() -> None:
|
|||
parser.add_argument("--json", type=Path, help="Write options and individual runs to this file.")
|
||||
args = parser.parse_args()
|
||||
if args.list:
|
||||
print("All boards (--case corpus)")
|
||||
for group, title in (
|
||||
("all", "Core corpus"),
|
||||
("holdout", "Held-out boards"),
|
||||
("fallback", "Fallback cases"),
|
||||
("external", "External cases"),
|
||||
("crossings", "Preplaced crossings"),
|
||||
("stress", "Stress cases"),
|
||||
):
|
||||
print(f"{title} (--case {group})")
|
||||
for case in case_groups[group]:
|
||||
|
|
|
|||
Loading…
Reference in a new issue