footstep_plan — DRIVE locomotion op

• 資料種類:mask → table

• 呼叫: import fullseye as fs; fs.ledger.footstep_plan(mask, cell, start, goal_col, step_max, width_min, width_max, deviation_weight: 'float' = 0.1, extent=None) -> 'dict'(要直接呼叫實作,import locomotion; locomotion.footstep_plan(mask, cell, start, goal_col, step_max, width_min, width_max, deviation_weight: 'float' = 0.1, extent=None) -> 'dict';從台帳取用則 opsdrive.get("footstep_plan"))

• GPU:無(僅 CPU 參考實作)

用法

在落腳點遮罩上的左右交替腳步序列(精確最短路徑)。

> 以下的詳細說明為原文 —— 摘要與標題已翻譯。

足場の候補の mask と、歩幅・歩隔の制約から、左右交互の着地点の列を出す。

格子の約束は terrain.elevation_map と同じ(行 i = y、列 j = x、セル辺 cell [m])。進行方向は +x(列が増える向き)、左足は y が大きい側(行が大きい)。

• 状態 = (いま立っている足のセル, その足が左か右か, 反対の足がゴールを越えているか)。次の一歩は反対の足を、mask が True のセル c に置く:

歩幅 0 ≤ (x_c − x_stance) ≤ step_max [m]、歩隔

width_min ≤ (y_left − y_right) ≤ width_max [m] (左右が入れ替わる交差を許さない)。

• 一歩の費用 = 1 + deviation_weight·[((x_c − x_s − step_max)/step_max)² + ((w − w_mid)/w_half)²](w_mid・w_half は歩隔の幅の中央と半幅、半幅が 0 のときは 2 項目を 0)。第 1 項 1 が歩数を数え、残りは最大の歩幅・中央の歩隔へ寄せる(平地では規則的に交互に並ぶ)。

• ゴール = 最後の 2 歩(左右 1 歩ずつ)の両方が列 goal_col 以上。

• 解法: 状態の上の Dijkstra(費用は非負)= 厳密な最小費用。小さな格子では総当たりの最小と一致する(tests の門)。

start は ((行, 列) の左足, (行, 列) の右足)。どちらの足から踏み出すかも探索が決める。返り値 {"reached", "steps": [{"side": "L"/"R", "cell": (i, j), "xy"(extent があるとき)}], "cost", "n_steps", "expanded"}。届かないときは reached = False・ steps 空・cost = inf(risk_aware_path と同じ約束)。

★roverslip.risk_aware_path は再利用しなかった: あちらの状態は 1 セル、辺は 8 近傍の(8, H, W) の費用で、左右交互・歩幅の窓・歩隔の窓(反対の足との相対位置)を持てない。空の入力(mask が 0 要素)は ValueError で拒否する。

English: exact Dijkstra over (stance cell, side, other-foot-past-goal) states; a step puts the other foot on a True cell within the step-length window [0, step_max] and the step-width window [width_min, width_max] (left foot on the larger-y side). Unreachable goals return reached = False and cost = inf.

參考(範例資料、文獻)

• 範例資料目錄(下載 URL / 授權) —— 2-D 用 skimage.data(BSD/公有領域)加合成圖,3-D 給出真實資料源(Stanford/PDS 等)的下載 URL。

• 運算子來歷與參考文獻 —— 該運算子族所依據的研究/方法出處。

• 演算法的正典(作者、年份)與用途見上面的族使用指南。

可執行的範例(實際呼叫該運算子並已驗證的樣例)

• walking_ops_tour — py -3.11 examples/walking_ops_tour.py

型別可銜接的下一個運算子(可接受 table 作為輸入)

course_layout · course_occupancy · course_contains · world_build · world_camera · world_move · lidar_scan · rss_longitudinal_same

同類別(locomotion)

contact_points · com_from_silhouette · support_polygon · com_support_margin · gait_phase · support_line_margin · lipm_capture_point · capture_margin


*Provenance: locomotion.py — DRIVE 運算子登記表。本條目由 tools/opdocs.py md 自動產生(請勿手動編輯)。*

© 2026 Kazufumi Furuse — Fullseye operator documentation. Licensed under Apache-2.0.