feat(simulation): add Worker AI polygon runtime and terrain navigation
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
"""Apply one explicit adapter patch to the pinned CMU selector; fail on drift."""
|
||||
from pathlib import Path
|
||||
|
||||
path = Path("/opt/cmu/src/local_planner/src/localPlanner.cpp")
|
||||
source = path.read_text()
|
||||
needle = " maxScore = clearPathPerGroupScore[i];\n selectedGroupID = i;"
|
||||
replacement = """\
|
||||
if (!missioncoreFootprintClear(*plannerCloudCrop, *startPaths[i % groupNum],
|
||||
rotAng, pathScale, std::min(pathRange, relativeGoalDis),
|
||||
vehicleLength, vehicleWidth, obstacleHeightThre, twoWayDrive)) continue;
|
||||
maxScore = clearPathPerGroupScore[i];
|
||||
selectedGroupID = i;"""
|
||||
assert source.count(needle) == 1, "CMU selector source changed"
|
||||
path.write_text('#include "missioncore_footprint.hpp"\n' + source.replace(needle, replacement))
|
||||
Reference in New Issue
Block a user