ml: 第二轮审查 B-1~B-8 处置 + 一键训练控制台

- B-1 运行时投影护栏恢复 5 mm;老师轨迹按认证最小间隙 < 3 mm 剔除(stats/build_dataset,gapDrop)
- B-2 APG 端点+中点 hinge 取均值;B-3 check_r2 空匹配保护、5000×50000、分块 256,pass=false 时 prep 停下
- B-4 R7 按全部 B/C 题统计;B-5 r8 起点贴柱;B-7 pipeline r4(export_onnx --random,训练前测延迟)
- B-8 起步失败 ≤0.2%、column_gap 分块、pipefail、门禁结果先写 .tmp
- 训练控制台:ml/console.bat|sh → ml/monitor.py(开始/停止/进度/日志接口)+ monitor.html;
  pipeline.sh all 支持 FROM/TO,阶段状态写 ml/runs/pipeline.json(ml/pstate.py);训练/APG 日志加 total、t
- 文档:README 一键运行与训练控制台;审查文档追加第三轮处置;方案余量决策与 R4 时点
This commit is contained in:
Hark
2026-10-18 06:40:24 +08:00
committed by cbb
parent 5348bc6f6f
commit 5591adb39a
21 changed files with 1465 additions and 57 deletions
+6 -3
View File
@@ -33,9 +33,12 @@ def straight_blocked(kin, a, b, n=24):
return (min_gap_chunked(kin, pts) <= 0).view(a.shape[0], n).any(-1)
def column_gap(kin, q):
gm = kin.gaps(q, 40)['gm']
return torch.stack([gm[:, g] for g in (2, 3, 4, 5, 6)], -1).min(-1).values # 组 0(立柱/底座)× 组 2..6
def column_gap(kin, q, chunk=256):
out = []
for s in range(0, q.shape[0], chunk): # 与 min_gap_chunked 一样分块防 OOM
gm = kin.gaps(q[s:s + chunk], 40)['gm']
out.append(torch.stack([gm[:, g] for g in (2, 3, 4, 5, 6)], -1).min(-1).values) # 组 0(立柱/底座)× 组 2..6
return torch.cat(out)
@torch.no_grad()