第八轮:monitor 状态三项被注释吞掉的 bug;R9 改判稳态 planWarmP99 + 运动中饥饿 + 认证超时占比;APG steps 8000(batch 48 保持总任务量);r4 不再静默退回 CDN;自检副本含未跟踪文件;显存文案按 19–20 GB;审查文档精简为实测/判据/待数据/三段训练
This commit is contained in:
@@ -72,7 +72,7 @@ async function boot() {
|
||||
latency: () => { const p = (a, x) => { const s = a.slice().sort((u, v) => u - v); return s.length ? s[Math.min(s.length - 1, Math.floor(s.length * x))] : null; };
|
||||
const st = runner.stats;
|
||||
return { inferP50: p(st.inferMs, .5), inferP99: p(st.inferMs, .99), safetyP50: p(st.safetyMs, .5), safetyP99: p(st.safetyMs, .99),
|
||||
lookaheadP99: p(st.lookaheadMs, .99), planP50: p(st.planMs, .5), planP99: p(st.planMs, .99), certQP99: p(st.certQ, .99),
|
||||
lookaheadP99: p(st.lookaheadMs, .99), planP50: p(st.planMs, .5), planP99: p(st.planMs, .99), planWarmP99: p(st.planWarmMs, .99), planColdP99: p(st.planColdMs, .99), coldPlans: st.planColdMs.length, certQP99: p(st.certQ, .99),
|
||||
tickGapP99: p(TICKS.gaps, .99), tickGapMax: TICKS.gaps.length ? Math.max(...TICKS.gaps) : null, starve: TICKS.starve, ticks: TICKS.n,
|
||||
threads: ort.env.wasm.numThreads, ep: ep[0], proxy, encOnce: !!meta.enc_once, featDyn: !!meta.feat_dyn, probe }; }
|
||||
};
|
||||
@@ -118,7 +118,8 @@ function onTick() {
|
||||
if (!running) return;
|
||||
const tn = performance.now(); if (TICKS.last) TICKS.gaps.push(tn - TICKS.last); TICKS.last = tn; TICKS.n++;
|
||||
if (TICKS.gaps.length > 20000) TICKS.gaps.splice(0, 10000);
|
||||
if (!runner.queue.length && !runner.done && runner.goal) TICKS.starve++;
|
||||
/* 第八轮:冷启动(静止起步、首次规划含前瞻)时队列本就为空、机械臂没在动,不算丢步;只统计运动中断粮 */
|
||||
if (!runner.queue.length && !runner.done && runner.goal && !runner.cold) TICKS.starve++;
|
||||
if (runner.needPlan()) runner.plan().catch(e => { console.error(e); stop(); say('策略推理出错:' + e.message, 'badb'); });
|
||||
const q = runner.tick();
|
||||
if (q) window.IK.setJoints(q, false);
|
||||
|
||||
@@ -184,7 +184,7 @@ class Runner {
|
||||
this.rng = makeRng(this.o.seed);
|
||||
/* 2026-10-18 第六轮(审查 B-1/B-2):耗时拆开记——inferMs 主推理、lookaheadMs 前瞻(第二次推理 + 8 份特征)、safetyMs 只含认证、
|
||||
planMs 整次规划(R9 口径:必须 < 60 ms 周期);certQ 每次规划新增的距离查询数,certHit 记忆命中数,certWhy 认证失败原因计数 */
|
||||
this.stats = { plans: 0, inferMs: [], lookaheadMs: [], safetyMs: [], planMs: [], certQ: [], certHit: 0, certWhy: {}, brakes: 0, refine: 0, lookahead: 0, locks: 0, projected: 0 };
|
||||
this.stats = { plans: 0, inferMs: [], lookaheadMs: [], safetyMs: [], planMs: [], planWarmMs: [], planColdMs: [], certQ: [], certHit: 0, certWhy: {}, brakes: 0, refine: 0, lookahead: 0, locks: 0, projected: 0 };
|
||||
this.reset(null);
|
||||
}
|
||||
reset(q0) {
|
||||
@@ -238,11 +238,11 @@ class Runner {
|
||||
async plan() {
|
||||
if (!this.needPlan()) return;
|
||||
this.planning = true;
|
||||
const t = now(), c0 = this.cert.counters();
|
||||
const t = now(), c0 = this.cert.counters(), wasCold = this.cold; // 第八轮:冷启动(含前瞻)与稳态分开记,R9 判稳态
|
||||
try { await this._plan(); } finally {
|
||||
this.planning = false; this._until = undefined;
|
||||
const c1 = this.cert.counters();
|
||||
this.stats.planMs.push(now() - t); this.stats.certQ.push(c1.queries - c0.queries); this.stats.certHit += c1.hits - c0.hits;
|
||||
const dt = now() - t; this.stats.planMs.push(dt); (wasCold ? this.stats.planColdMs : this.stats.planWarmMs).push(dt); this.stats.certQ.push(c1.queries - c0.queries); this.stats.certHit += c1.hits - c0.hits;
|
||||
}
|
||||
}
|
||||
async _plan() {
|
||||
|
||||
Reference in New Issue
Block a user