tools/elm_bench: ring label experiment — the ring label is NOT learnable
Gate question: can a ring-based label (a 2-D offset from the belief centre to
where a ray ring touches the enemy) be predicted from our own belief state?
extract_ring.py + bench_ring.nim answer it by MERGING the ring label into
samples_realistic.ndjson, so the ring label and the incumbent 1-D aim-error
label are scored on the SAME rows, the SAME features and the SAME round-group
folds. 8119 of 8676 DrussGT shot rows get a ring label.
Verdict: worse, not richer.
* The spike's headline is an artifact. The belief is already accurate to
under 3 px, so a belief-anchored ring touches the enemy on its FIRST ray
step: ringK = 1.0000 for all 172723 extracted events. The "100% at power
<= 1.5, 0.2% at power 3.0" pattern is just whether 1 * bulletSpeed fits
inside the +-18 px belief-error ball. The literal ring label is the 1-tick
belief extrapolation error, clipped to BotRadius.
* Same-tick it scores better than the 1-D label (ELM/const 0.2628 vs 0.3629)
but a single feature, beliefTgtLatVel, already gets -71.8 of the -73.7
points: the model is re-deriving beliefTgtLatVel * age / beliefDist, i.e.
its own inputs.
* Under --prev it collapses to ratio 0.9819 (-1.8%). It depends MORE on the
same-tick assumption than the 1-D label (-63.7% -> -1.0%), not less.
* Repaired (--kintercept: k = round(believed range / bullet speed), mean k 42,
no clipping, 60 px spread) the label is well posed and completely
unpredictable: best feature +0.5%, best ELM -0.4%, best |corr| 0.09.
So: the belief-extrapolation error at intercept time is not a function of what
we believed, it is the opponent's unmodelled acceleration. Do not ship a ring
label. common_libs/guns/waveelm.nim is the right shape for the same idea and
is a different thing: it fires the ring from the SHOOTER, so the ring measures
an interception radius and bearing and the ELM learns a bias correction to it.
This commit is contained in:
+2
-1
@@ -128,4 +128,5 @@ tools/elm_bench/cross_opponent
|
||||
# Generated sample tables. The authoritative copies live in tools/elm_bench/gen/
|
||||
# (committed); the top-level ones are the DrussGT extract, byte-identical.
|
||||
tools/elm_bench/samples*.ndjson
|
||||
tools/elm_bench/ring_*
|
||||
tools/elm_bench/ring_*.ndjson
|
||||
tools/elm_bench/ring_*.ndjson.merged
|
||||
|
||||
@@ -1250,3 +1250,224 @@ variable; it would only buy more capacity to overfit the 40 round-groups.
|
||||
Ship `0.87 × lead`, not a network.
|
||||
|
||||
|
||||
---
|
||||
|
||||
# RING LABEL EXPERIMENT (2025-10-05)
|
||||
|
||||
The gate before the ring was: **is a ring label learnable?** A ring is `N`
|
||||
rays fired simultaneously from a belief centre at bullet speed; the label is the
|
||||
2-D offset between the belief centre and where the ring touches the enemy circle.
|
||||
`tools/ring_spike/spike.py` claimed this works (100% interception at bullet
|
||||
power ≤ 1.5, independent of ray count and ring radius, collapsing to ~0.2% at
|
||||
power 3.0). This section answers the learnability question, and it also shows
|
||||
that the spike's headline number is an artifact.
|
||||
|
||||
**Answer up front: no. The ring label is worse, not richer.** It is either
|
||||
degenerate (same-tick: it is an algebraic restatement of one feature the model
|
||||
is already given) or unpredictable (everything else). It never beats the
|
||||
incumbent 1-D aim-error label on the part that matters.
|
||||
|
||||
## 1. What was measured
|
||||
|
||||
```
|
||||
python3 extract_ring.py ring_drussgt.ndjson ../../data/drussgt_raw --base samples_realistic.ndjson
|
||||
nim c -r --path:../../DevControlBot_garage/DevControlBot bench_ring.nim ring_drussgt.ndjson.merged
|
||||
```
|
||||
|
||||
`extract_ring.py` emits one row per (scan tick, enemy). It imports `collect`
|
||||
and `ring_contact` from `spike.py`, so the ring geometry and the belief
|
||||
reconstruction have exactly one definition. With `--base` it MERGES into an
|
||||
existing `samples_*.ndjson`: every base row keeps its own features untouched
|
||||
and gains `ringK / ringLat / ringRad / ringMag / ringLatAng / ringRadAng`,
|
||||
`label` becomes the ring label and `label1d` keeps the incumbent aim error.
|
||||
`bench_ring.nim` then scores **both labels on the same rows, the same features
|
||||
and the same round-group folds**, so the comparison is row-for-row, not
|
||||
corpus-for-corpus. 8119 of the 8676 DrussGT shot rows get a ring label (93.6%).
|
||||
|
||||
Two variants, both with and without `--prev` (strictly-prior-scan semantics):
|
||||
|
||||
| variant | contact tick `k` |
|
||||
|---|---|
|
||||
| **literal** (the spike's rule) | first `k` where some ray point is within BotRadius of the enemy |
|
||||
| **`--kintercept`** (this section's repair) | `k = round(believed range / bullet speed)`, i.e. the bullet flight time — fully observable |
|
||||
|
||||
`label = atan2(lateral, beliefDist)` in radians, where `lateral` is the
|
||||
component of (enemy true position at contact − belief dead-reckoned to contact)
|
||||
perpendicular to the believed line of sight. Same units and same sign as the
|
||||
incumbent aim-error label, which is what makes the head-to-head fair.
|
||||
|
||||
## 2. Label distribution (rad)
|
||||
|
||||
DrussGT corpus, literal variant, same-tick:
|
||||
|
||||
| column | mean | sd | \|p1\| | \|p50\| | \|p90\| | max\|·\| |
|
||||
|---|---|---|---|---|---|---|
|
||||
| **ring label** | −0.00023 | **0.01044** | 0.0217 | 0.00008 | 0.0148 | 0.0270 |
|
||||
| 1-D aim error | +0.11074 | **1.17266** | 2.9010 | 0.0067 | 1.8073 | 3.1414 |
|
||||
|
||||
In pixels the ring label is `ringLat` mean −0.09 px, sd **4.26 px**, hard
|
||||
clipped to ±8.00 px; `ringMag` mean 5.45 px, sd 2.66 px, **max 8.00 px**.
|
||||
|
||||
Two things stand out. The ring label is **112× smaller in scale** than the
|
||||
incumbent one, and it is **clipped**: sd 4.26 px on a label that saturates at
|
||||
±8 px is a censored distribution, not a well-behaved regression target.
|
||||
|
||||
`--prev`: ring sd 0.01341, `ringLat` sd 5.46 px, range −29.5…+25.2 px.
|
||||
`--kintercept`: ring sd 0.14282, `ringLat` sd 59.5 px (mean `k` = 42.2 ticks).
|
||||
|
||||
**The cause of the clipping is the headline finding of this section.**
|
||||
`ringK = 1.0000` for **all 172 723** extracted scan events, and the spike's own
|
||||
output says why:
|
||||
|
||||
```
|
||||
belief-vs-truth offset px: mean=0.75 std=0.64 p50=0.56 p90=2.00 max=3.00
|
||||
BELIEF 1.0 360 400 100.00% kMean 1.00 | L1 10.00 0.00 | L2 3.19 2.24 | L3 2.10 1.75
|
||||
```
|
||||
|
||||
The belief is already accurate to **under 3 px**, i.e. well inside the 18 px
|
||||
`BotRadius`. A ring anchored at that centre therefore touches the enemy on its
|
||||
very first ray step, at every power the spike recommends. The "100% at power
|
||||
≤ 1.5, 0.2% at power 3.0" pattern is not ray geometry at all: it is simply
|
||||
whether `k·bulletSpeed` for `k = 1` (10 or 15 px) falls inside the ±18 px
|
||||
belief-error ball. At power 3.0 it does not, and no later step ever does either,
|
||||
because the enemy's distance from the anchor barely changes. The spike's
|
||||
"independent of ray count and ring radius" is likewise an artifact: it was never
|
||||
measuring contact.
|
||||
|
||||
So the literal ring label is the **1-tick belief extrapolation error**, clipped
|
||||
to the BotRadius. It is not a richer measurement of anything.
|
||||
|
||||
## 3. Learnability (same rows, same features, same 5 round-group folds)
|
||||
|
||||
Constant baseline, ridge ablation and ELM sweep
|
||||
(H{16,32,64,128} × λ{1e-6,1e-4,1e-2,1,100}, decay 1.0, 20 configs × 5 folds,
|
||||
ALL-21, λ=1e-8 ridge). Ratios are against each label's own constant.
|
||||
|
||||
### literal ring, same-tick
|
||||
|
||||
| model | pooled RMSE | MAE | medAE | vs const |
|
||||
|---|---|---|---|---|
|
||||
| constant | 0.01044 | 0.0083 | 0.0069 | — |
|
||||
| ridge ALL 21 | 0.0026 | 0.0018 | 0.0012 | −75% |
|
||||
| ridge **beliefTgtLatVel alone** | **0.00294** | | | **−71.8%** |
|
||||
| ridge beliefPredErr alone | 0.00803 | | | +23.1% |
|
||||
| **ELM best (H=128, λ=1e-2)** | **0.00274** | 0.00190 | 0.00136 | **ratio 0.2628, −73.7%, 5/5 folds** |
|
||||
|
||||
That looks like a win — until you see that one feature gets 71.8 of the 73.7
|
||||
points, and it gets them for a *tautological* reason. With `k = 1` and scan
|
||||
age ≈ 0, `ringLatAng ≈ beliefTgtLatVel × age / beliefDist` ≈
|
||||
`beliefLosRate`. The network is re-deriving arithmetic on its own inputs. The
|
||||
clipped distribution explains why the RMSE ratio (0.26) is *better* than the 1-D
|
||||
one (0.36): a censored, low-variance target is easier to regress, not more
|
||||
informative.
|
||||
|
||||
### literal ring, `--prev` (the check that matters)
|
||||
|
||||
| model | ring | 1-D aim |
|
||||
|---|---|---|
|
||||
| constant | 0.0134 | 1.1638 |
|
||||
| ridge ALL 21 | 0.0133 (−0.0001) | 1.1500 |
|
||||
| best single feature (beliefTgtLatVel) | +1.04% | — |
|
||||
| **ELM best (H=128, λ=1)** | **ratio 0.9819, −1.8%** | **ratio 0.9899, −1.0%** |
|
||||
|
||||
**The ring label's apparent learnability does not survive `--prev`.** The
|
||||
−73.7% collapses to −1.8%, and every single-feature ridge collapses to ≤ 1%.
|
||||
It depends on the same-tick assumption *more* than the 1-D label does, not
|
||||
less: it is only ever a restatement of a quantity computed from a scan taken in
|
||||
the current tick. The 1-D label's `beliefPredErr` signal degrades too
|
||||
(−63.7% → −1.0%), but that is a documented property of the corpora, not of the
|
||||
label's construction.
|
||||
|
||||
### `--kintercept` (the repaired label, no clipping, mean k = 42)
|
||||
|
||||
| model | ring | 1-D aim |
|
||||
|---|---|---|
|
||||
| constant | 0.1429 | 1.1661 |
|
||||
| ridge ALL 21 | 0.1426 (−0.0002) | 0.4419 |
|
||||
| best single feature (cosRel) | **+0.50%** | — |
|
||||
| **ELM best** | **ratio 0.9956, −0.4%, 4/5 folds** | ratio 0.3632, −63.7% |
|
||||
| ELM best, `--prev` | **ratio 0.9990, −0.1%, 2/5 folds** | ratio 0.9896 |
|
||||
|
||||
This is the honest version of the ring label: no degenerate contact, a real
|
||||
42-tick extrapolation, a 60 px spread. **It is completely unpredictable.** No
|
||||
feature exceeds 0.5%, the network is 0.4% better than a constant, and the best
|
||||
single Pearson correlation between any of the 21 features and the label is
|
||||
**0.09** (`ringK`/`beliefDist`). Under `--prev` it is 0.09 too. A 60 px
|
||||
positional error at intercept time is not a function of what we believed; it is
|
||||
the opponent's unmodelled acceleration, and nothing in our own state carries it.
|
||||
|
||||
## 4. Head-to-head (ELM pooled RMSE ÷ constant pooled RMSE)
|
||||
|
||||
| dataset | ring label | 1-D aim-error label |
|
||||
|---|---|---|
|
||||
| same-tick, literal | **0.2628** | 0.3629 |
|
||||
| `--prev`, literal | 0.9819 | 0.9899 |
|
||||
| same-tick, k-intercept | 0.9956 | 0.3632 |
|
||||
| `--prev`, k-intercept | 0.9990 | 0.9896 |
|
||||
|
||||
## VERDICT
|
||||
|
||||
**The ring label is not richer than the 1-D aim-error label. It is strictly
|
||||
worse, and the one number that made it look better is a bug in the spike.**
|
||||
|
||||
1. **Not richer.** The literal ring label carries *less* information than the
|
||||
incumbent: it is one linear combination of two features the model already
|
||||
has (`beliefTgtLatVel`, `beliefDist`), it is censored at ±8 px, and the ELM
|
||||
adds 1.9 points over that single ridge (−73.7% vs −71.8%). The 1-D label is
|
||||
a genuinely behavioural quantity — the opponent's *decision*, not our own
|
||||
arithmetic — and it is the only one of the two whose structure is still
|
||||
visible after you hand the model everything.
|
||||
2. **The gain is not bigger; it is fake.** Same-tick, the ring label's ratio
|
||||
(0.2628) is nominally better than the 1-D label's (0.3629). That difference
|
||||
is entirely the consequence of a smaller, clipped target: the same ELM, the
|
||||
same features, a label with a hundredth of the spread (sd 0.0104 vs 1.1727). It buys no
|
||||
capability.
|
||||
3. **It depends MORE on the same-tick assumption, not less.** −73.7% → −1.8%
|
||||
under `--prev`, versus −63.7% → −1.0% for the 1-D label. The ring label is
|
||||
built out of the current tick's scan; take that away and there is nothing
|
||||
left.
|
||||
4. **The repaired label is pure noise.** Removing the `k = 1` degeneracy
|
||||
(`--kintercept`) gives a well-posed 60 px, 42-tick-ahead target that **no**
|
||||
feature and **no** ELM can predict (best 0.4%, best |corr| 0.09). This is
|
||||
the actual answer to "is the ring label learnable": the belief-extrapolation
|
||||
error at intercept time is not learnable from the shooter's own state.
|
||||
5. **What to do with it.** Do not ship a ring label. `common_libs/guns/
|
||||
waveelm.nim` is the right shape for the same idea and it is not the same
|
||||
thing: it fires the ring **from the shooter**, not from the belief centre,
|
||||
so the ring measures an interception *radius and bearing* (a real
|
||||
measurement) and the ELM learns a bias correction to it — the ring is the
|
||||
instrument, not the label. That construction is unaffected by the
|
||||
`k = 1` degeneracy above and should be the one benchmarked next.
|
||||
|
||||
### Files (ring experiment)
|
||||
|
||||
```
|
||||
extract_ring.py ring labels per scan tick; --prev, --kintercept,
|
||||
--base (merge into samples_*.ndjson)
|
||||
ring_dist.py distribution + per-feature correlation report
|
||||
bench_ring.nim both labels, same rows/folds: constant, ridge
|
||||
ablation, single-feature ridge, ELM sweep
|
||||
ring_same.log literal ring, same-tick + 1-D on the same rows
|
||||
ring_prev.log literal ring, --prev + 1-D on the same rows
|
||||
ring_ki.log k-intercept ring, same-tick + 1-D
|
||||
ring_ki_prev.log k-intercept ring, --prev + 1-D
|
||||
```
|
||||
|
||||
Rebuild:
|
||||
|
||||
```
|
||||
python3 extract_ring.py ring_drussgt.ndjson ../../data/drussgt_raw --base samples_realistic.ndjson
|
||||
python3 extract_ring.py ring_prev.ndjson ../../data/drussgt_raw --prev --base samples_realistic_prev.ndjson
|
||||
python3 extract_ring.py ring_ki.ndjson ../../data/drussgt_raw --kintercept --base samples_realistic.ndjson
|
||||
python3 extract_ring.py ring_ki_prev.ndjson ../../data/drussgt_raw --kintercept --prev --base samples_realistic_prev.ndjson
|
||||
nim c -r --path:../../DevControlBot_garage/DevControlBot bench_ring.nim ring_*.ndjson.merged
|
||||
```
|
||||
|
||||
`bench_ring.nim` imports the ELM by relative path
|
||||
(`../../DevControlBot_garage/DevControlBot/modules/ELM/elm`) and reads its input
|
||||
path from `paramStr(1)`; run it from `tools/elm_bench`. No project-local import
|
||||
workaround is needed — the ELM module is self-contained (stdlib only), so the
|
||||
project-local loader is only an issue for callers inside the bot.
|
||||
|
||||
`ring_*.ndjson` and the `.merged` files are generated (40 s each) and are
|
||||
gitignored; the four `.log` files are committed.
|
||||
|
||||
@@ -0,0 +1,459 @@
|
||||
=== tanh
|
||||
== activation = tanh ==
|
||||
== dataset (realistic features) ==
|
||||
n = 8676 mean = 0.1136 std = 1.1462 never-scanned rows: 0
|
||||
|
||||
== baselines (5-fold by round-group) ==
|
||||
(a) constant mean : 1.1406 +- 0.0330
|
||||
(b) belief-distance-binned : 1.1409 +- 0.0333
|
||||
(c) ridge on belief base 7 : 0.9339 +- 0.0246
|
||||
pooled const RMSE/MAE/medAE 1.1463 / 0.7958 / 0.4284
|
||||
pooled dist RMSE/MAE/medAE 1.1467 / 0.7967 / 0.4287
|
||||
pooled rdg7 RMSE/MAE/medAE 0.9343 / 0.6226 / 0.3548
|
||||
|
||||
== (A) ridge feature ablation (pooled held-out) ==
|
||||
feature set | RMSE MAE medAE | per-fold RMSE +- sd
|
||||
baseline 6 (belief geometry) | 1.1448 0.7921 0.4428 | 1.1389 +- 0.0331
|
||||
+ scan age | 0.9346 0.6229 0.3564 | 0.9342 +- 0.0242
|
||||
+ believed intercept geom | 0.4379 0.1714 0.1089 | 0.4375 +- 0.0442
|
||||
+ our own state | 0.9347 0.6231 0.3553 | 0.9343 +- 0.0241
|
||||
+ context | 0.9342 0.6228 0.3546 | 0.9338 +- 0.0257
|
||||
+ scan + intercept | 0.4381 0.1715 0.1088 | 0.4377 +- 0.0443
|
||||
ALL 21 | 0.4383 0.1720 0.1089 | 0.4381 +- 0.0444
|
||||
|
||||
-- single-feature ridge (constant = {mean(bConst):.4f}) --
|
||||
predErr RMSE 0.4398
|
||||
tgtLatVel RMSE 0.9358
|
||||
closing RMSE 1.1311
|
||||
tof RMSE 1.1394
|
||||
power RMSE 1.1400
|
||||
tgtSpeed RMSE 1.1403
|
||||
logScan RMSE 1.1404
|
||||
scanAge RMSE 1.1405
|
||||
gunHeat RMSE 1.1406
|
||||
sinRel RMSE 1.1406
|
||||
disp RMSE 1.1406
|
||||
scanGap RMSE 1.1406
|
||||
everScanned RMSE 1.1406
|
||||
dist RMSE 1.1406
|
||||
sinPred RMSE 1.1409
|
||||
cosRel RMSE 1.1409
|
||||
ownSpeed RMSE 1.1411
|
||||
cosPred RMSE 1.1518
|
||||
losRate RMSE 1.2363
|
||||
|
||||
== (B) ELM sweep on realistic features (H x lambda x decay, 5 folds each) ==
|
||||
[ALL21] 15/60 configs, 6.s
|
||||
[ALL21] 30/60 configs, 15.s
|
||||
[ALL21] 45/60 configs, 30.s
|
||||
[ALL21] 60/60 configs, 64.s
|
||||
-- ALL21 top 8 --
|
||||
H= 128 lam= 1.e-02 dec= 1.00 | 0.3582 0.4757 0.4153 0.4277 0.4323 | mean 0.4218
|
||||
H= 128 lam= 1.e-04 dec= 1.00 | 0.3594 0.4766 0.4171 0.4271 0.4334 | mean 0.4227
|
||||
H= 128 lam= 1.e-06 dec= 1.00 | 0.3595 0.4766 0.4171 0.4271 0.4334 | mean 0.4227
|
||||
H= 128 lam= 1.e+00 dec= 1.00 | 0.3609 0.4892 0.4185 0.4426 0.4354 | mean 0.4293
|
||||
H= 64 lam= 1.e-02 dec= 1.00 | 0.3684 0.4965 0.4335 0.4427 0.4373 | mean 0.4357
|
||||
H= 64 lam= 1.e-04 dec= 1.00 | 0.3689 0.4964 0.4339 0.4425 0.4372 | mean 0.4358
|
||||
H= 64 lam= 1.e-06 dec= 1.00 | 0.3689 0.4964 0.4339 0.4425 0.4372 | mean 0.4358
|
||||
H= 64 lam= 1.e+00 dec= 1.00 | 0.3721 0.5035 0.4326 0.4486 0.4431 | mean 0.4400
|
||||
-- ALL21 full ranking tail (worst 3) --
|
||||
H= 16 lam= 1.e-02 dec= 0.95 | mean 3.1346
|
||||
H= 16 lam= 1.e-04 dec= 0.95 | mean 3.2484
|
||||
H= 16 lam= 1.e-06 dec= 0.95 | mean 3.2792
|
||||
[base7] 15/60 configs, 5.s
|
||||
[base7] 30/60 configs, 10.s
|
||||
[base7] 45/60 configs, 21.s
|
||||
[base7] 60/60 configs, 45.s
|
||||
-- base7 top 8 --
|
||||
H= 128 lam= 1.e-06 dec= 1.00 | 0.7657 0.8170 0.7590 0.7457 0.8126 | mean 0.7800
|
||||
H= 128 lam= 1.e-04 dec= 1.00 | 0.7714 0.8244 0.7655 0.7521 0.8149 | mean 0.7856
|
||||
H= 64 lam= 1.e-06 dec= 1.00 | 0.7939 0.8437 0.7921 0.7653 0.8279 | mean 0.8046
|
||||
H= 64 lam= 1.e-04 dec= 1.00 | 0.7946 0.8443 0.7924 0.7674 0.8313 | mean 0.8060
|
||||
H= 128 lam= 1.e-02 dec= 1.00 | 0.8005 0.8526 0.7921 0.7766 0.8465 | mean 0.8136
|
||||
H= 64 lam= 1.e-02 dec= 1.00 | 0.8188 0.8707 0.8089 0.7984 0.8640 | mean 0.8322
|
||||
H= 32 lam= 1.e-04 dec= 1.00 | 0.8250 0.8755 0.8160 0.8077 0.8730 | mean 0.8394
|
||||
H= 32 lam= 1.e-06 dec= 1.00 | 0.8250 0.8755 0.8161 0.8079 0.8729 | mean 0.8395
|
||||
-- base7 full ranking tail (worst 3) --
|
||||
H= 128 lam= 1.e-06 dec= 0.95 | mean 4.1482
|
||||
H= 32 lam= 1.e-06 dec= 0.95 | mean 5.7793
|
||||
H= 64 lam= 1.e-06 dec= 0.95 | mean 6.7607
|
||||
[base6] 15/60 configs, 4.s
|
||||
[base6] 30/60 configs, 10.s
|
||||
[base6] 45/60 configs, 20.s
|
||||
[base6] 60/60 configs, 44.s
|
||||
-- base6 top 8 --
|
||||
H= 128 lam= 1.e-04 dec= 1.00 | 1.1497 1.1605 1.1573 1.0679 1.1194 | mean 1.1310
|
||||
H= 64 lam= 1.e-06 dec= 1.00 | 1.1511 1.1605 1.1556 1.0667 1.1209 | mean 1.1310
|
||||
H= 64 lam= 1.e-04 dec= 1.00 | 1.1509 1.1602 1.1546 1.0697 1.1197 | mean 1.1310
|
||||
H= 64 lam= 1.e-02 dec= 1.00 | 1.1508 1.1613 1.1540 1.0726 1.1209 | mean 1.1319
|
||||
H= 128 lam= 1.e-02 dec= 1.00 | 1.1500 1.1608 1.1556 1.0726 1.1211 | mean 1.1320
|
||||
H= 32 lam= 1.e-04 dec= 1.00 | 1.1508 1.1615 1.1545 1.0729 1.1221 | mean 1.1323
|
||||
H= 128 lam= 1.e-06 dec= 1.00 | 1.1539 1.1615 1.1600 1.0672 1.1192 | mean 1.1324
|
||||
H= 32 lam= 1.e-06 dec= 1.00 | 1.1508 1.1613 1.1550 1.0729 1.1224 | mean 1.1325
|
||||
-- base6 full ranking tail (worst 3) --
|
||||
H= 32 lam= 1.e-06 dec= 0.95 | mean 5.1310
|
||||
H= 16 lam= 1.e-06 dec= 0.95 | mean 6.1210
|
||||
H= 128 lam= 1.e-06 dec= 0.95 | mean 8.8051
|
||||
[scanonly] 15/60 configs, 4.s
|
||||
[scanonly] 30/60 configs, 9.s
|
||||
[scanonly] 45/60 configs, 18.s
|
||||
[scanonly] 60/60 configs, 40.s
|
||||
-- scanonly top 8 --
|
||||
H= 128 lam= 1.e-06 dec= 1.00 | 1.1517 1.1721 1.1609 1.0820 1.1309 | mean 1.1395
|
||||
H= 64 lam= 1.e-06 dec= 1.00 | 1.1517 1.1721 1.1609 1.0820 1.1309 | mean 1.1395
|
||||
H= 32 lam= 1.e-06 dec= 1.00 | 1.1517 1.1721 1.1609 1.0820 1.1309 | mean 1.1395
|
||||
H= 16 lam= 1.e-06 dec= 1.00 | 1.1517 1.1721 1.1609 1.0820 1.1310 | mean 1.1395
|
||||
H= 128 lam= 1.e-04 dec= 1.00 | 1.1518 1.1721 1.1609 1.0821 1.1311 | mean 1.1396
|
||||
H= 64 lam= 1.e-04 dec= 1.00 | 1.1518 1.1721 1.1609 1.0822 1.1312 | mean 1.1396
|
||||
H= 32 lam= 1.e-04 dec= 1.00 | 1.1519 1.1722 1.1609 1.0822 1.1313 | mean 1.1397
|
||||
H= 32 lam= 1.e+00 dec= 1.00 | 1.1526 1.1726 1.1606 1.0812 1.1315 | mean 1.1397
|
||||
-- scanonly full ranking tail (worst 3) --
|
||||
H= 32 lam= 1.e-06 dec= 0.95 | mean 1.1883
|
||||
H= 64 lam= 1.e-06 dec= 0.95 | mean 1.1883
|
||||
H= 128 lam= 1.e-06 dec= 0.95 | mean 1.1884
|
||||
|
||||
== best config, pooled metrics + paired per-fold check ==
|
||||
ALL21 H=128 lam=1.e-02 dec=1.0 mean per-fold RMSE 0.4218 pooled RMSE/MAE/medAE 0.4220/0.1824/0.1095 delta-vs-const -0.7187 (better on 5/5)
|
||||
base7 H=128 lam=1.e-06 dec=1.0 mean per-fold RMSE 0.7800 pooled RMSE/MAE/medAE 0.7815/0.5034/0.3084 delta-vs-const -0.3606 (better on 5/5)
|
||||
base6 H=128 lam=1.e-04 dec=1.0 mean per-fold RMSE 1.1310 pooled RMSE/MAE/medAE 1.1372/0.7854/0.4429 delta-vs-const -0.0096 (better on 5/5)
|
||||
constant pooled RMSE/MAE/medAE 1.1463/0.7958/0.4284 per-fold mean 1.1406
|
||||
|
||||
== fold-shift robustness (offset +3, no reselection) ==
|
||||
ELM 0.4218 const 1.1406 delta -0.7187 per-fold -0.745 -0.653 -0.700 -0.797 -0.699
|
||||
|
||||
== learning curve (held-out = fold 0; ALL21, best cfg) ==
|
||||
train n | RMSE MAE medAE | constant
|
||||
50 | 1.5347 1.1342 0.8692 | 1.1551
|
||||
100 | 0.7637 0.5439 0.3993 | 1.1551
|
||||
200 | 0.5024 0.3062 0.2081 | 1.1551
|
||||
400 | 1.1103 0.7852 0.5333 | 1.1551
|
||||
800 | 0.4537 0.2695 0.1995 | 1.1551
|
||||
1600 | 0.4266 0.2365 0.1498 | 1.1551
|
||||
3200 | 0.3679 0.1819 0.1169 | 1.1551
|
||||
6400 | 0.3600 0.1708 0.1097 | 1.1551
|
||||
6635 | 0.3582 0.1675 0.1054 | 1.1551
|
||||
|
||||
== (E) scan-age conditional analysis (all rows, in-sample conditional stats) ==
|
||||
age is ticks since the SHOOTER last scanned US -- observable to it, not to us.
|
||||
bucketing is on the shooter's staleness, used here as a diagnostic of whether
|
||||
aim error magnitude is driven by belief staleness at all.
|
||||
bucket n frac label mean label sd RMSE(within bucket) medAE(within bucket)
|
||||
(-1.,0] 8444 97.3% 0.1065 1.1515 1.1515 0.4329
|
||||
(0.,1] 232 2.7% 0.3754 0.8939 0.8939 0.4693
|
||||
(1.,2] 0 (too few)
|
||||
(2.,3] 0 (too few)
|
||||
(3.,5] 0 (too few)
|
||||
(5.,8] 0 (too few)
|
||||
(8.,13] 0 (too few)
|
||||
(13.,21] 0 (too few)
|
||||
(21.,inf] 0 (too few)
|
||||
(buckets cover 8676 of 8676 rows; sd within bucket vs global sd 1.1462)
|
||||
|
||||
== (E2) does scan age predict the label? (held-out, bucket-mean predictor) ==
|
||||
scan-age-bucketed mean (held-out RMSE): 1.1458 constant: 1.1406
|
||||
=== relu
|
||||
== activation = relu ==
|
||||
== dataset (realistic features) ==
|
||||
n = 8676 mean = 0.1136 std = 1.1462 never-scanned rows: 0
|
||||
|
||||
== baselines (5-fold by round-group) ==
|
||||
(a) constant mean : 1.1406 +- 0.0330
|
||||
(b) belief-distance-binned : 1.1409 +- 0.0333
|
||||
(c) ridge on belief base 7 : 0.9339 +- 0.0246
|
||||
pooled const RMSE/MAE/medAE 1.1463 / 0.7958 / 0.4284
|
||||
pooled dist RMSE/MAE/medAE 1.1467 / 0.7967 / 0.4287
|
||||
pooled rdg7 RMSE/MAE/medAE 0.9343 / 0.6226 / 0.3548
|
||||
|
||||
== (A) ridge feature ablation (pooled held-out) ==
|
||||
feature set | RMSE MAE medAE | per-fold RMSE +- sd
|
||||
baseline 6 (belief geometry) | 1.1448 0.7921 0.4428 | 1.1389 +- 0.0331
|
||||
+ scan age | 0.9346 0.6229 0.3564 | 0.9342 +- 0.0242
|
||||
+ believed intercept geom | 0.4379 0.1714 0.1089 | 0.4375 +- 0.0442
|
||||
+ our own state | 0.9347 0.6231 0.3553 | 0.9343 +- 0.0241
|
||||
+ context | 0.9342 0.6228 0.3546 | 0.9338 +- 0.0257
|
||||
+ scan + intercept | 0.4381 0.1715 0.1088 | 0.4377 +- 0.0443
|
||||
ALL 21 | 0.4383 0.1720 0.1089 | 0.4381 +- 0.0444
|
||||
|
||||
-- single-feature ridge (constant = {mean(bConst):.4f}) --
|
||||
predErr RMSE 0.4398
|
||||
tgtLatVel RMSE 0.9358
|
||||
closing RMSE 1.1311
|
||||
tof RMSE 1.1394
|
||||
power RMSE 1.1400
|
||||
tgtSpeed RMSE 1.1403
|
||||
logScan RMSE 1.1404
|
||||
scanAge RMSE 1.1405
|
||||
gunHeat RMSE 1.1406
|
||||
sinRel RMSE 1.1406
|
||||
disp RMSE 1.1406
|
||||
scanGap RMSE 1.1406
|
||||
everScanned RMSE 1.1406
|
||||
dist RMSE 1.1406
|
||||
sinPred RMSE 1.1409
|
||||
cosRel RMSE 1.1409
|
||||
ownSpeed RMSE 1.1411
|
||||
cosPred RMSE 1.1518
|
||||
losRate RMSE 1.2363
|
||||
|
||||
== (B) ELM sweep on realistic features (H x lambda x decay, 5 folds each) ==
|
||||
[ALL21] 15/60 configs, 6.s
|
||||
[ALL21] 30/60 configs, 14.s
|
||||
[ALL21] 45/60 configs, 28.s
|
||||
[ALL21] 60/60 configs, 61.s
|
||||
-- ALL21 top 8 --
|
||||
H= 128 lam= 1.e+02 dec= 1.00 | 0.3676 0.4924 0.4280 0.4463 0.4347 | mean 0.4338
|
||||
H= 128 lam= 1.e+00 dec= 1.00 | 0.3673 0.4944 0.4313 0.4455 0.4351 | mean 0.4347
|
||||
H= 128 lam= 1.e-02 dec= 1.00 | 0.3673 0.4948 0.4315 0.4455 0.4353 | mean 0.4349
|
||||
H= 128 lam= 1.e-04 dec= 1.00 | 0.3673 0.4948 0.4316 0.4455 0.4353 | mean 0.4349
|
||||
H= 128 lam= 1.e-06 dec= 1.00 | 0.3673 0.4948 0.4316 0.4455 0.4353 | mean 0.4349
|
||||
H= 64 lam= 1.e+00 dec= 1.00 | 0.3797 0.5135 0.4365 0.4594 0.4544 | mean 0.4487
|
||||
H= 64 lam= 1.e-02 dec= 1.00 | 0.3797 0.5135 0.4367 0.4593 0.4547 | mean 0.4488
|
||||
H= 64 lam= 1.e-04 dec= 1.00 | 0.3797 0.5135 0.4367 0.4593 0.4547 | mean 0.4488
|
||||
-- ALL21 full ranking tail (worst 3) --
|
||||
H= 64 lam= 1.e-04 dec= 0.95 | mean 2.4775
|
||||
H= 128 lam= 1.e-06 dec= 0.95 | mean 2.5727
|
||||
H= 64 lam= 1.e-06 dec= 0.95 | mean 2.7643
|
||||
[base7] 15/60 configs, 4.s
|
||||
[base7] 30/60 configs, 10.s
|
||||
[base7] 45/60 configs, 19.s
|
||||
[base7] 60/60 configs, 42.s
|
||||
-- base7 top 8 --
|
||||
H= 128 lam= 1.e+00 dec= 1.00 | 0.7626 0.8196 0.7610 0.7579 0.8188 | mean 0.7840
|
||||
H= 128 lam= 1.e-02 dec= 1.00 | 0.7628 0.8213 0.7619 0.7579 0.8198 | mean 0.7847
|
||||
H= 128 lam= 1.e-04 dec= 1.00 | 0.7629 0.8214 0.7618 0.7579 0.8203 | mean 0.7849
|
||||
H= 128 lam= 1.e-06 dec= 1.00 | 0.7629 0.8214 0.7618 0.7579 0.8203 | mean 0.7849
|
||||
H= 64 lam= 1.e+00 dec= 1.00 | 0.7843 0.8341 0.7869 0.7683 0.8371 | mean 0.8021
|
||||
H= 64 lam= 1.e-02 dec= 1.00 | 0.7836 0.8335 0.7867 0.7695 0.8379 | mean 0.8022
|
||||
H= 64 lam= 1.e-04 dec= 1.00 | 0.7836 0.8335 0.7867 0.7696 0.8379 | mean 0.8023
|
||||
H= 64 lam= 1.e-06 dec= 1.00 | 0.7836 0.8335 0.7867 0.7696 0.8379 | mean 0.8023
|
||||
-- base7 full ranking tail (worst 3) --
|
||||
H= 64 lam= 1.e-06 dec= 0.95 | mean 6.3628
|
||||
H= 128 lam= 1.e-04 dec= 0.95 | mean 6.4968
|
||||
H= 128 lam= 1.e-06 dec= 0.95 | mean 8.6792
|
||||
[base6] 15/60 configs, 4.s
|
||||
[base6] 30/60 configs, 9.s
|
||||
[base6] 45/60 configs, 18.s
|
||||
[base6] 60/60 configs, 41.s
|
||||
-- base6 top 8 --
|
||||
H= 64 lam= 1.e+00 dec= 1.00 | 1.1489 1.1632 1.1567 1.0663 1.1186 | mean 1.1308
|
||||
H= 64 lam= 1.e-02 dec= 1.00 | 1.1495 1.1656 1.1600 1.0661 1.1177 | mean 1.1318
|
||||
H= 128 lam= 1.e+02 dec= 1.00 | 1.1493 1.1619 1.1551 1.0716 1.1211 | mean 1.1318
|
||||
H= 64 lam= 1.e+02 dec= 1.00 | 1.1496 1.1631 1.1538 1.0718 1.1214 | mean 1.1320
|
||||
H= 64 lam= 1.e-04 dec= 1.00 | 1.1499 1.1656 1.1645 1.0662 1.1179 | mean 1.1328
|
||||
H= 64 lam= 1.e-06 dec= 1.00 | 1.1499 1.1656 1.1650 1.0662 1.1179 | mean 1.1329
|
||||
H= 128 lam= 1.e+00 dec= 1.00 | 1.1500 1.1629 1.1614 1.0691 1.1254 | mean 1.1337
|
||||
H= 32 lam= 1.e+02 dec= 1.00 | 1.1531 1.1656 1.1550 1.0748 1.1229 | mean 1.1343
|
||||
-- base6 full ranking tail (worst 3) --
|
||||
H= 64 lam= 1.e-04 dec= 0.95 | mean 10.6035
|
||||
H= 128 lam= 1.e-06 dec= 0.95 | mean 20.4823
|
||||
H= 64 lam= 1.e-06 dec= 0.95 | mean 23.5729
|
||||
[scanonly] 15/60 configs, 4.s
|
||||
[scanonly] 30/60 configs, 9.s
|
||||
[scanonly] 45/60 configs, 18.s
|
||||
[scanonly] 60/60 configs, 40.s
|
||||
-- scanonly top 8 --
|
||||
H= 128 lam= 1.e-06 dec= 1.00 | 1.1517 1.1721 1.1609 1.0820 1.1309 | mean 1.1395
|
||||
H= 32 lam= 1.e-06 dec= 1.00 | 1.1517 1.1721 1.1609 1.0820 1.1309 | mean 1.1395
|
||||
H= 128 lam= 1.e-04 dec= 1.00 | 1.1517 1.1721 1.1609 1.0820 1.1309 | mean 1.1395
|
||||
H= 32 lam= 1.e-04 dec= 1.00 | 1.1517 1.1721 1.1609 1.0820 1.1309 | mean 1.1395
|
||||
H= 128 lam= 1.e-02 dec= 1.00 | 1.1517 1.1721 1.1609 1.0820 1.1309 | mean 1.1395
|
||||
H= 32 lam= 1.e-02 dec= 1.00 | 1.1517 1.1721 1.1609 1.0820 1.1310 | mean 1.1395
|
||||
H= 32 lam= 1.e+02 dec= 1.00 | 1.1526 1.1726 1.1606 1.0812 1.1315 | mean 1.1397
|
||||
H= 64 lam= 1.e+02 dec= 1.00 | 1.1523 1.1724 1.1607 1.0816 1.1314 | mean 1.1397
|
||||
-- scanonly full ranking tail (worst 3) --
|
||||
H= 64 lam= 1.e-04 dec= 0.95 | mean 1.1884
|
||||
H= 16 lam= 1.e-06 dec= 0.95 | mean 1.1884
|
||||
H= 64 lam= 1.e-06 dec= 0.95 | mean 1.1884
|
||||
|
||||
== best config, pooled metrics + paired per-fold check ==
|
||||
ALL21 H=128 lam=1.e+02 dec=1.0 mean per-fold RMSE 0.4338 pooled RMSE/MAE/medAE 0.4340/0.1845/0.1171 delta-vs-const -0.7068 (better on 5/5)
|
||||
base7 H=128 lam=1.e+00 dec=1.0 mean per-fold RMSE 0.7840 pooled RMSE/MAE/medAE 0.7846/0.5121/0.3204 delta-vs-const -0.3566 (better on 5/5)
|
||||
base6 H=64 lam=1.e+00 dec=1.0 mean per-fold RMSE 1.1308 pooled RMSE/MAE/medAE 1.1372/0.7869/0.4528 delta-vs-const -0.0098 (better on 5/5)
|
||||
constant pooled RMSE/MAE/medAE 1.1463/0.7958/0.4284 per-fold mean 1.1406
|
||||
|
||||
== fold-shift robustness (offset +3, no reselection) ==
|
||||
ELM 0.4338 const 1.1406 delta -0.7068 per-fold -0.733 -0.634 -0.697 -0.787 -0.682
|
||||
|
||||
== learning curve (held-out = fold 0; ALL21, best cfg) ==
|
||||
train n | RMSE MAE medAE | constant
|
||||
50 | 1.2046 0.8918 0.6319 | 1.1551
|
||||
100 | 1.0903 0.7631 0.4248 | 1.1551
|
||||
200 | 0.7931 0.5109 0.2786 | 1.1551
|
||||
400 | 0.7538 0.5090 0.3291 | 1.1551
|
||||
800 | 0.4062 0.2248 0.1560 | 1.1551
|
||||
1600 | 0.3944 0.2083 0.1391 | 1.1551
|
||||
3200 | 0.3768 0.1788 0.1163 | 1.1551
|
||||
6400 | 0.3679 0.1692 0.1111 | 1.1551
|
||||
6635 | 0.3676 0.1685 0.1120 | 1.1551
|
||||
|
||||
== (E) scan-age conditional analysis (all rows, in-sample conditional stats) ==
|
||||
age is ticks since the SHOOTER last scanned US -- observable to it, not to us.
|
||||
bucketing is on the shooter's staleness, used here as a diagnostic of whether
|
||||
aim error magnitude is driven by belief staleness at all.
|
||||
bucket n frac label mean label sd RMSE(within bucket) medAE(within bucket)
|
||||
(-1.,0] 8444 97.3% 0.1065 1.1515 1.1515 0.4329
|
||||
(0.,1] 232 2.7% 0.3754 0.8939 0.8939 0.4693
|
||||
(1.,2] 0 (too few)
|
||||
(2.,3] 0 (too few)
|
||||
(3.,5] 0 (too few)
|
||||
(5.,8] 0 (too few)
|
||||
(8.,13] 0 (too few)
|
||||
(13.,21] 0 (too few)
|
||||
(21.,inf] 0 (too few)
|
||||
(buckets cover 8676 of 8676 rows; sd within bucket vs global sd 1.1462)
|
||||
|
||||
== (E2) does scan age predict the label? (held-out, bucket-mean predictor) ==
|
||||
scan-age-bucketed mean (held-out RMSE): 1.1458 constant: 1.1406
|
||||
=== step
|
||||
== activation = step ==
|
||||
== dataset (realistic features) ==
|
||||
n = 8676 mean = 0.1136 std = 1.1462 never-scanned rows: 0
|
||||
|
||||
== baselines (5-fold by round-group) ==
|
||||
(a) constant mean : 1.1406 +- 0.0330
|
||||
(b) belief-distance-binned : 1.1409 +- 0.0333
|
||||
(c) ridge on belief base 7 : 0.9339 +- 0.0246
|
||||
pooled const RMSE/MAE/medAE 1.1463 / 0.7958 / 0.4284
|
||||
pooled dist RMSE/MAE/medAE 1.1467 / 0.7967 / 0.4287
|
||||
pooled rdg7 RMSE/MAE/medAE 0.9343 / 0.6226 / 0.3548
|
||||
|
||||
== (A) ridge feature ablation (pooled held-out) ==
|
||||
feature set | RMSE MAE medAE | per-fold RMSE +- sd
|
||||
baseline 6 (belief geometry) | 1.1448 0.7921 0.4428 | 1.1389 +- 0.0331
|
||||
+ scan age | 0.9346 0.6229 0.3564 | 0.9342 +- 0.0242
|
||||
+ believed intercept geom | 0.4379 0.1714 0.1089 | 0.4375 +- 0.0442
|
||||
+ our own state | 0.9347 0.6231 0.3553 | 0.9343 +- 0.0241
|
||||
+ context | 0.9342 0.6228 0.3546 | 0.9338 +- 0.0257
|
||||
+ scan + intercept | 0.4381 0.1715 0.1088 | 0.4377 +- 0.0443
|
||||
ALL 21 | 0.4383 0.1720 0.1089 | 0.4381 +- 0.0444
|
||||
|
||||
-- single-feature ridge (constant = {mean(bConst):.4f}) --
|
||||
predErr RMSE 0.4398
|
||||
tgtLatVel RMSE 0.9358
|
||||
closing RMSE 1.1311
|
||||
tof RMSE 1.1394
|
||||
power RMSE 1.1400
|
||||
tgtSpeed RMSE 1.1403
|
||||
logScan RMSE 1.1404
|
||||
scanAge RMSE 1.1405
|
||||
gunHeat RMSE 1.1406
|
||||
sinRel RMSE 1.1406
|
||||
disp RMSE 1.1406
|
||||
scanGap RMSE 1.1406
|
||||
everScanned RMSE 1.1406
|
||||
dist RMSE 1.1406
|
||||
sinPred RMSE 1.1409
|
||||
cosRel RMSE 1.1409
|
||||
ownSpeed RMSE 1.1411
|
||||
cosPred RMSE 1.1518
|
||||
losRate RMSE 1.2363
|
||||
|
||||
== (B) ELM sweep on realistic features (H x lambda x decay, 5 folds each) ==
|
||||
[ALL21] 15/60 configs, 6.s
|
||||
[ALL21] 30/60 configs, 14.s
|
||||
[ALL21] 45/60 configs, 28.s
|
||||
[ALL21] 60/60 configs, 59.s
|
||||
-- ALL21 top 8 --
|
||||
H= 128 lam= 1.e+00 dec= 1.00 | 0.7022 0.7629 0.8141 0.7325 0.7261 | mean 0.7476
|
||||
H= 128 lam= 1.e-02 dec= 1.00 | 0.7023 0.7631 0.8141 0.7327 0.7259 | mean 0.7476
|
||||
H= 128 lam= 1.e-04 dec= 1.00 | 0.7023 0.7631 0.8141 0.7327 0.7259 | mean 0.7476
|
||||
H= 128 lam= 1.e-06 dec= 1.00 | 0.7023 0.7631 0.8141 0.7327 0.7259 | mean 0.7476
|
||||
H= 128 lam= 1.e+02 dec= 1.00 | 0.7077 0.7644 0.8198 0.7320 0.7333 | mean 0.7514
|
||||
H= 64 lam= 1.e+00 dec= 1.00 | 0.7698 0.8136 0.8553 0.7807 0.8002 | mean 0.8039
|
||||
H= 64 lam= 1.e-02 dec= 1.00 | 0.7698 0.8137 0.8553 0.7808 0.8004 | mean 0.8040
|
||||
H= 64 lam= 1.e-04 dec= 1.00 | 0.7698 0.8137 0.8553 0.7808 0.8004 | mean 0.8040
|
||||
-- ALL21 full ranking tail (worst 3) --
|
||||
H= 32 lam= 1.e-06 dec= 0.95 | mean 1.6888
|
||||
H= 128 lam= 1.e-04 dec= 0.95 | mean 2.1397
|
||||
H= 128 lam= 1.e-06 dec= 0.95 | mean 2.3947
|
||||
[base7] 15/60 configs, 4.s
|
||||
[base7] 30/60 configs, 9.s
|
||||
[base7] 45/60 configs, 18.s
|
||||
[base7] 60/60 configs, 40.s
|
||||
-- base7 top 8 --
|
||||
H= 128 lam= 1.e+00 dec= 1.00 | 0.7911 0.8537 0.7960 0.7866 0.8510 | mean 0.8157
|
||||
H= 128 lam= 1.e-02 dec= 1.00 | 0.7914 0.8538 0.7961 0.7868 0.8510 | mean 0.8158
|
||||
H= 128 lam= 1.e-04 dec= 1.00 | 0.7914 0.8538 0.7961 0.7868 0.8510 | mean 0.8158
|
||||
H= 128 lam= 1.e-06 dec= 1.00 | 0.7914 0.8538 0.7961 0.7868 0.8510 | mean 0.8158
|
||||
H= 128 lam= 1.e+02 dec= 1.00 | 0.7921 0.8569 0.7965 0.7852 0.8526 | mean 0.8167
|
||||
H= 64 lam= 1.e+00 dec= 1.00 | 0.8308 0.8795 0.8269 0.8225 0.8959 | mean 0.8511
|
||||
H= 64 lam= 1.e-02 dec= 1.00 | 0.8310 0.8796 0.8270 0.8225 0.8960 | mean 0.8512
|
||||
H= 64 lam= 1.e-04 dec= 1.00 | 0.8310 0.8796 0.8270 0.8225 0.8960 | mean 0.8512
|
||||
-- base7 full ranking tail (worst 3) --
|
||||
H= 128 lam= 1.e-02 dec= 0.95 | mean 1.9066
|
||||
H= 128 lam= 1.e-04 dec= 0.95 | mean 3.3772
|
||||
H= 128 lam= 1.e-06 dec= 0.95 | mean 4.1491
|
||||
[base6] 15/60 configs, 4.s
|
||||
[base6] 30/60 configs, 9.s
|
||||
[base6] 45/60 configs, 18.s
|
||||
[base6] 60/60 configs, 39.s
|
||||
-- base6 top 8 --
|
||||
H= 128 lam= 1.e+02 dec= 1.00 | 1.1489 1.1657 1.1557 1.0731 1.1211 | mean 1.1329
|
||||
H= 64 lam= 1.e+02 dec= 1.00 | 1.1528 1.1651 1.1577 1.0749 1.1234 | mean 1.1348
|
||||
H= 128 lam= 1.e+00 dec= 1.00 | 1.1501 1.1713 1.1602 1.0745 1.1263 | mean 1.1365
|
||||
H= 128 lam= 1.e-02 dec= 1.00 | 1.1502 1.1721 1.1608 1.0755 1.1268 | mean 1.1371
|
||||
H= 128 lam= 1.e-04 dec= 1.00 | 1.1502 1.1722 1.1608 1.0755 1.1268 | mean 1.1371
|
||||
H= 128 lam= 1.e-06 dec= 1.00 | 1.1502 1.1722 1.1608 1.0755 1.1268 | mean 1.1371
|
||||
H= 64 lam= 1.e+00 dec= 1.00 | 1.1540 1.1648 1.1695 1.0736 1.1243 | mean 1.1372
|
||||
H= 32 lam= 1.e+02 dec= 1.00 | 1.1558 1.1688 1.1563 1.0800 1.1256 | mean 1.1373
|
||||
-- base6 full ranking tail (worst 3) --
|
||||
H= 64 lam= 1.e-06 dec= 0.95 | mean 2.0895
|
||||
H= 128 lam= 1.e-04 dec= 0.95 | mean 2.2970
|
||||
H= 128 lam= 1.e-06 dec= 0.95 | mean 2.5287
|
||||
[scanonly] 15/60 configs, 4.s
|
||||
[scanonly] 30/60 configs, 9.s
|
||||
[scanonly] 45/60 configs, 17.s
|
||||
[scanonly] 60/60 configs, 38.s
|
||||
-- scanonly top 8 --
|
||||
H= 32 lam= 1.e+00 dec= 1.00 | 1.1519 1.1722 1.1609 1.0822 1.1313 | mean 1.1397
|
||||
H= 128 lam= 1.e+00 dec= 1.00 | 1.1519 1.1722 1.1609 1.0823 1.1312 | mean 1.1397
|
||||
H= 32 lam= 1.e-02 dec= 1.00 | 1.1518 1.1722 1.1609 1.0823 1.1312 | mean 1.1397
|
||||
H= 128 lam= 1.e-02 dec= 1.00 | 1.1518 1.1722 1.1609 1.0823 1.1312 | mean 1.1397
|
||||
H= 32 lam= 1.e-04 dec= 1.00 | 1.1518 1.1722 1.1609 1.0823 1.1312 | mean 1.1397
|
||||
H= 128 lam= 1.e-04 dec= 1.00 | 1.1518 1.1722 1.1609 1.0823 1.1312 | mean 1.1397
|
||||
H= 32 lam= 1.e-06 dec= 1.00 | 1.1518 1.1722 1.1609 1.0823 1.1312 | mean 1.1397
|
||||
H= 128 lam= 1.e-06 dec= 1.00 | 1.1518 1.1722 1.1609 1.0823 1.1312 | mean 1.1397
|
||||
-- scanonly full ranking tail (worst 3) --
|
||||
H= 128 lam= 1.e-04 dec= 0.95 | mean 1.1882
|
||||
H= 32 lam= 1.e-06 dec= 0.95 | mean 1.1883
|
||||
H= 128 lam= 1.e-06 dec= 0.95 | mean 1.1883
|
||||
|
||||
== best config, pooled metrics + paired per-fold check ==
|
||||
ALL21 H=128 lam=1.e+00 dec=1.0 mean per-fold RMSE 0.7476 pooled RMSE/MAE/medAE 0.7503/0.5181/0.3714 delta-vs-const -0.3930 (better on 5/5)
|
||||
base7 H=128 lam=1.e+00 dec=1.0 mean per-fold RMSE 0.8157 pooled RMSE/MAE/medAE 0.8165/0.5504/0.3636 delta-vs-const -0.3249 (better on 5/5)
|
||||
base6 H=128 lam=1.e+02 dec=1.0 mean per-fold RMSE 1.1329 pooled RMSE/MAE/medAE 1.1388/0.7876/0.4500 delta-vs-const -0.0077 (better on 5/5)
|
||||
constant pooled RMSE/MAE/medAE 1.1463/0.7958/0.4284 per-fold mean 1.1406
|
||||
|
||||
== fold-shift robustness (offset +3, no reselection) ==
|
||||
ELM 0.7476 const 1.1406 delta -0.3930 per-fold -0.346 -0.348 -0.406 -0.453 -0.412
|
||||
|
||||
== learning curve (held-out = fold 0; ALL21, best cfg) ==
|
||||
train n | RMSE MAE medAE | constant
|
||||
50 | 1.1591 0.8658 0.5790 | 1.1551
|
||||
100 | 1.0754 0.7477 0.4081 | 1.1551
|
||||
200 | 1.2494 0.9475 0.7163 | 1.1551
|
||||
400 | 1.1199 0.8282 0.5860 | 1.1551
|
||||
800 | 0.8801 0.6568 0.4981 | 1.1551
|
||||
1600 | 0.7529 0.5370 0.3994 | 1.1551
|
||||
3200 | 0.7151 0.5076 0.3770 | 1.1551
|
||||
6400 | 0.7016 0.4922 0.3573 | 1.1551
|
||||
6635 | 0.7022 0.4925 0.3586 | 1.1551
|
||||
|
||||
== (E) scan-age conditional analysis (all rows, in-sample conditional stats) ==
|
||||
age is ticks since the SHOOTER last scanned US -- observable to it, not to us.
|
||||
bucketing is on the shooter's staleness, used here as a diagnostic of whether
|
||||
aim error magnitude is driven by belief staleness at all.
|
||||
bucket n frac label mean label sd RMSE(within bucket) medAE(within bucket)
|
||||
(-1.,0] 8444 97.3% 0.1065 1.1515 1.1515 0.4329
|
||||
(0.,1] 232 2.7% 0.3754 0.8939 0.8939 0.4693
|
||||
(1.,2] 0 (too few)
|
||||
(2.,3] 0 (too few)
|
||||
(3.,5] 0 (too few)
|
||||
(5.,8] 0 (too few)
|
||||
(8.,13] 0 (too few)
|
||||
(13.,21] 0 (too few)
|
||||
(21.,inf] 0 (too few)
|
||||
(buckets cover 8676 of 8676 rows; sd within bucket vs global sd 1.1462)
|
||||
|
||||
== (E2) does scan age predict the label? (held-out, bucket-mean predictor) ==
|
||||
scan-age-bucketed mean (held-out RMSE): 1.1458 constant: 1.1406
|
||||
@@ -0,0 +1,306 @@
|
||||
#!/usr/bin/env nim c -r
|
||||
# RING-label learnability benchmark.
|
||||
#
|
||||
# run: cd tools/elm_bench
|
||||
# nim c -r --path:../../DevControlBot_garage/DevControlBot bench_ring.nim
|
||||
#
|
||||
# Input is a MERGED file from extract_ring.py --base: one row per (group, tick,
|
||||
# shooter, target) with the ORIGINAL realistic features untouched and TWO
|
||||
# labels: `label` = ring label, atan2(lateral, beliefDist) (rad)
|
||||
# `label1d` = incumbent aim error, ideal - gun (rad)
|
||||
#
|
||||
# The two are scored on the SAME rows, the SAME features and the SAME
|
||||
# round-group folds, so the numbers are directly comparable. decay is fixed at
|
||||
# 1.0 (no forgetting) and the sweep is H{16,32,64,128} x lambda{1e-6..1e2}.
|
||||
|
||||
import std/[json, math, strutils, strformat, algorithm, sequtils, tables, times, os]
|
||||
import ../../DevControlBot_garage/DevControlBot/modules/ELM/elm
|
||||
|
||||
type
|
||||
S = object
|
||||
group: string
|
||||
yRing, yOne, k: float64
|
||||
f: Table[string, float64]
|
||||
|
||||
proc load(path: string): seq[S] =
|
||||
for line in lines(path):
|
||||
if line.len == 0: continue
|
||||
let j = parseJson(line)
|
||||
var s: S
|
||||
s.group = j["group"].getStr
|
||||
s.yRing = j["ringLatAng"].getFloat
|
||||
s.yOne = j["label1d"].getFloat
|
||||
s.k = j["ringK"].getFloat
|
||||
let de = j["beliefDist"].getFloat
|
||||
let age = max(j["beliefScanAge"].getFloat, 0.0)
|
||||
let gap = j["beliefScanGap"].getFloat
|
||||
let tof = j["beliefTof"].getFloat
|
||||
let pred = j["beliefPredRelBearing"].getFloat
|
||||
let rel = j["beliefRelBearing"].getFloat
|
||||
s.f = ({
|
||||
"dist": de / 1000.0,
|
||||
"invDist": 1.0 / (1.0 + de / 100.0),
|
||||
"sinRel": j["beliefSinRelBearing"].getFloat,
|
||||
"cosRel": j["beliefCosRelBearing"].getFloat,
|
||||
"tgtSpeed": j["beliefTgtSpeed"].getFloat / 10.0,
|
||||
"bulletSpd": j["bulletSpeed"].getFloat / 20.0,
|
||||
"scanAge": min(age, 30.0) / 30.0,
|
||||
"logScan": math.ln(1.0 + min(age, 60.0)) / 4.0,
|
||||
"everScanned": j["beliefEverScanned"].getFloat,
|
||||
"scanGap": min(gap, 30.0) / 30.0,
|
||||
"sinPred": math.sin(pred),
|
||||
"cosPred": math.cos(pred),
|
||||
"predErr": j["beliefPredErr"].getFloat / PI,
|
||||
"tgtLatVel": j["beliefTgtLatVel"].getFloat / 10.0,
|
||||
"closing": j["beliefClosing"].getFloat / 10.0,
|
||||
"losRate": j["beliefLosRate"].getFloat,
|
||||
"tof": tof / 30.0,
|
||||
"gunHeat": j["gunHeat"].getFloat / 3.0,
|
||||
"power": j["power"].getFloat / 3.0,
|
||||
"ownSpeed": j["ownSpeed"].getFloat / 10.0,
|
||||
"disp": j["beliefDisp"].getFloat / 100.0,
|
||||
"round": j["round"].getFloat / 10.0,
|
||||
"tick": j["tick"].getFloat / 1000.0,
|
||||
"relSin": math.sin(rel),
|
||||
}).toTable
|
||||
result.add s
|
||||
|
||||
type Metrics = object
|
||||
rmse, mae, medae: float64
|
||||
|
||||
proc metrics(pred: seq[float64], te: seq[int], ys: seq[float64]): Metrics =
|
||||
var s2 = 0.0
|
||||
var s1 = 0.0
|
||||
var ae = newSeq[float64](te.len)
|
||||
for k, i in te:
|
||||
let d = pred[k] - ys[i]
|
||||
s2 += d * d
|
||||
s1 += abs(d)
|
||||
ae[k] = abs(d)
|
||||
result.rmse = sqrt(s2 / float64(te.len))
|
||||
result.mae = s1 / float64(te.len)
|
||||
ae.sort()
|
||||
result.medae = ae[ae.len div 2]
|
||||
|
||||
proc meanSd(v: seq[float64]): string =
|
||||
var m = 0.0
|
||||
for x in v: m += x
|
||||
m /= float64(v.len)
|
||||
var s = 0.0
|
||||
for x in v: s += (x - m) * (x - m)
|
||||
fmt"{m:.4f} +- {sqrt(s/float64(v.len)):.4f}"
|
||||
|
||||
proc mean(v: seq[float64]): float64 =
|
||||
if v.len == 0: return NaN
|
||||
for x in v: result += x
|
||||
result /= float64(v.len)
|
||||
|
||||
proc solveNormal(n1: int, G: var seq[float64], C: var seq[float64],
|
||||
lam: float64, L: int): seq[float64] =
|
||||
for p in 0 ..< n1:
|
||||
G[p * n1 + p] += lam * (if p < L: 1.0 else: 0.0) + 1e-12
|
||||
var M = newSeq[float64](n1 * (n1 + 1))
|
||||
for p in 0 ..< n1:
|
||||
for q in 0 ..< n1: M[p * (n1 + 1) + q] = G[p * n1 + q]
|
||||
M[p * (n1 + 1) + n1] = C[p]
|
||||
for c in 0 ..< n1:
|
||||
var piv = c
|
||||
for r in c + 1 ..< n1:
|
||||
if abs(M[r * (n1 + 1) + c]) > abs(M[piv * (n1 + 1) + c]): piv = r
|
||||
swap(M[c * (n1 + 1)], M[piv * (n1 + 1)])
|
||||
let d = M[c * (n1 + 1) + c]
|
||||
if abs(d) < 1e-300: continue
|
||||
for q in c .. n1: M[c * (n1 + 1) + q] /= d
|
||||
for r in 0 ..< n1:
|
||||
if r != c and M[r * (n1 + 1) + c] != 0.0:
|
||||
let f = M[r * (n1 + 1) + c]
|
||||
for q in c .. n1: M[r * (n1 + 1) + q] -= f * M[c * (n1 + 1) + q]
|
||||
result = newSeq[float64](n1)
|
||||
for p in 0 ..< n1: result[p] = M[p * (n1 + 1) + n1]
|
||||
|
||||
type RidgeFit = object
|
||||
names: seq[string]
|
||||
beta: seq[float64]
|
||||
|
||||
proc fitRidge(tr: seq[int], data: seq[S], ys: seq[float64],
|
||||
names: seq[string], lam: float64): RidgeFit =
|
||||
let L = names.len
|
||||
let n1 = L + 1
|
||||
var G = newSeq[float64](n1 * n1)
|
||||
var C = newSeq[float64](n1)
|
||||
for i in tr:
|
||||
for p in 0 ..< n1:
|
||||
let a = (if p < L: data[i].f[names[p]] else: 1.0)
|
||||
C[p] += a * ys[i]
|
||||
for q in 0 ..< n1:
|
||||
G[p * n1 + q] += a * (if q < L: data[i].f[names[q]] else: 1.0)
|
||||
result = RidgeFit(names: names, beta: solveNormal(n1, G, C, lam, L))
|
||||
|
||||
proc predict(r: RidgeFit, s: S): float64 =
|
||||
for p, n in r.names: result += r.beta[p] * s.f[n]
|
||||
result += r.beta[^1]
|
||||
|
||||
proc vec(s: S, names: seq[string]): array[64, float64] =
|
||||
for p, n in names: result[p] = s.f[n]
|
||||
|
||||
type Cfg = object
|
||||
hid: int
|
||||
pen: float64
|
||||
|
||||
proc evalElm(names: seq[string], c: Cfg, tr, te: seq[int],
|
||||
data: seq[S], ys: seq[float64]): (Metrics, seq[float64]) =
|
||||
let e = initElm(ElmConfig(inputDim: names.len, hiddenDim: c.hid, outputs: 1,
|
||||
seed: 42, lambda: c.pen, decay: 1.0, refitEvery: 0))
|
||||
for i in tr: train(e, vec(data[i], names).toOpenArray(0, names.len - 1), [ys[i]])
|
||||
refit(e)
|
||||
var pred = newSeq[float64](te.len)
|
||||
for k, i in te: pred[k] = infer(e, vec(data[i], names).toOpenArray(0, names.len - 1))[0]
|
||||
(metrics(pred, te, ys), pred)
|
||||
|
||||
let base6 = ["dist", "invDist", "sinRel", "cosRel", "tgtSpeed", "bulletSpd"].toSeq
|
||||
let base7 = ["dist", "invDist", "sinRel", "cosRel", "tgtSpeed", "tgtLatVel", "bulletSpd"].toSeq
|
||||
let scanSet = base7 & @["scanAge", "logScan", "everScanned", "scanGap"]
|
||||
let predSet = base7 & @["sinPred", "cosPred", "predErr", "losRate", "tof", "closing"]
|
||||
let ownSet = base7 & @["gunHeat", "power", "ownSpeed"]
|
||||
let ctxSet = base7 & @["round", "tick", "disp"]
|
||||
let allSet = scanSet & predSet & ownSet & ctxSet
|
||||
|
||||
let subsets: seq[tuple[name: string, feats: seq[string]]] = @[
|
||||
("baseline 6 (belief geometry)", base6),
|
||||
("+ scan age", scanSet),
|
||||
("+ believed intercept geom", predSet),
|
||||
("+ our own state", ownSet),
|
||||
("+ context", ctxSet),
|
||||
("+ scan + intercept", scanSet & predSet),
|
||||
("ALL 21", allSet),
|
||||
]
|
||||
let singles = ["scanAge", "logScan", "everScanned", "scanGap", "sinPred", "cosPred",
|
||||
"predErr", "losRate", "tof", "closing", "tgtLatVel", "gunHeat",
|
||||
"power", "ownSpeed", "disp", "dist", "sinRel", "cosRel", "tgtSpeed"]
|
||||
|
||||
let path = if paramCount() > 0: paramStr(1) else: "ring_drussgt.ndjson.merged"
|
||||
let data = load(path)
|
||||
echo "== dataset: ", path, " =="
|
||||
var labels = initTable[string, seq[float64]]()
|
||||
labels["label"] = newSeq[float64](data.len)
|
||||
labels["label1d"] = newSeq[float64](data.len)
|
||||
var ringK = newSeq[float64](data.len)
|
||||
for i in 0 ..< data.len:
|
||||
labels["label"][i] = data[i].yRing
|
||||
labels["label1d"][i] = data[i].yOne
|
||||
ringK[i] = data[i].k
|
||||
|
||||
var groups: seq[string]
|
||||
for s in data:
|
||||
if s.group notin groups: groups.add s.group
|
||||
const nFold = 5
|
||||
var foldOf = initTable[string, int]()
|
||||
for gi, g in groups: foldOf[g] = gi mod nFold
|
||||
var folds: array[nFold, tuple[tr, te: seq[int]]]
|
||||
for f in 0 ..< nFold:
|
||||
for i, s in data:
|
||||
if foldOf[s.group] == f: folds[f].te.add i else: folds[f].tr.add i
|
||||
|
||||
echo fmt" n = {data.len} groups = {groups.len} k mean = {mean(ringK):.2f}"
|
||||
|
||||
proc statsLine(tag: string, v: seq[float64]) =
|
||||
var m = 0.0
|
||||
for x in v: m += x
|
||||
m /= float64(v.len)
|
||||
var s = 0.0
|
||||
for x in v: s += (x - m) * (x - m)
|
||||
let sd = sqrt(s / float64(v.len))
|
||||
var y = v
|
||||
y.sort()
|
||||
let q = proc(p: float64): float64 = y[min(v.len - 1, max(0, int(p * float64(v.len - 1))))]
|
||||
echo fmt" {tag:<10} mean {m:+.5f} sd {sd:.5f} |p1| {abs(q(0.01)):.5f} |p50| {abs(q(0.5)):.5f} |p90| {abs(q(0.9)):.5f} max|.| {abs(y[^1]):.5f}"
|
||||
|
||||
echo "\n== label distribution (rad, same units for both) =="
|
||||
statsLine("ring", labels["label"])
|
||||
statsLine("1-D aim", labels["label1d"])
|
||||
|
||||
let sweep: seq[Cfg] = (block:
|
||||
var v: seq[Cfg] = @[]
|
||||
for h in [16, 32, 64, 128]:
|
||||
for l in [1e-6, 1e-4, 1e-2, 1e0, 1e2]:
|
||||
v.add Cfg(hid: h, pen: l)
|
||||
v)
|
||||
|
||||
proc run(lbl: string) =
|
||||
let ys = labels[lbl]
|
||||
echo "\n########## LABEL = ", lbl,
|
||||
(if lbl == "label": " (RING lateral aim correction)"
|
||||
else: " (incumbent 1-D aim error)"), " ##########"
|
||||
|
||||
proc evalSubset(names: seq[string]): (seq[float64], Metrics) =
|
||||
var perRmse: seq[float64]
|
||||
var pooled: seq[float64] = @[]
|
||||
var idx: seq[int] = @[]
|
||||
for f in 0 ..< nFold:
|
||||
let r = fitRidge(folds[f].tr, data, ys, names, 1e-8)
|
||||
var pred = newSeq[float64](folds[f].te.len)
|
||||
for k, i in folds[f].te: pred[k] = predict(r, data[i])
|
||||
perRmse.add metrics(pred, folds[f].te, ys).rmse
|
||||
for v in pred: pooled.add v
|
||||
for i in folds[f].te: idx.add i
|
||||
(perRmse, metrics(pooled, idx, ys))
|
||||
|
||||
echo "\n== (a) constant baseline, 5-fold by round-group =="
|
||||
var bConst: seq[float64]
|
||||
var pp: seq[float64] = @[]
|
||||
var piX: seq[int] = @[]
|
||||
for f in 0 ..< nFold:
|
||||
var m = 0.0
|
||||
for i in folds[f].tr: m += ys[i]
|
||||
m /= float64(folds[f].tr.len)
|
||||
var pred = newSeq[float64](folds[f].te.len)
|
||||
for k in 0 ..< folds[f].te.len:
|
||||
pred[k] = m; pp.add m; piX.add folds[f].te[k]
|
||||
bConst.add metrics(pred, folds[f].te, ys).rmse
|
||||
let mConst = metrics(pp, piX, ys)
|
||||
echo fmt" constant per-fold {meanSd(bConst)} pooled RMSE/MAE/medAE {mConst.rmse:.4f}/{mConst.mae:.4f}/{mConst.medae:.4f}"
|
||||
|
||||
echo "\n== (B) ridge feature ablation (pooled held-out) =="
|
||||
echo " feature set | RMSE MAE medAE | per-fold RMSE +- sd | vs const"
|
||||
for st in subsets:
|
||||
let (per, m) = evalSubset(st.feats)
|
||||
echo fmt" {st.name:<28} | {m.rmse:.4f} {m.mae:.4f} {m.medae:.4f} | {meanSd(per)} | {m.rmse - mConst.rmse:+.4f}"
|
||||
|
||||
echo "\n -- single-feature ridge (held-out, sorted) --"
|
||||
var sgl: seq[tuple[n: string, r: float64]]
|
||||
for n in singles: sgl.add (n, mean(evalSubset(@[n])[0]))
|
||||
sgl.sort(proc(a, b: typeof(sgl[0])): int = cmp(a.r, b.r))
|
||||
for s in sgl:
|
||||
echo fmt" {s.n:<12} RMSE {s.r:.5f} (const {mConst.rmse:.5f}, gain {100*(1-s.r/mConst.rmse):+.2f}%)"
|
||||
|
||||
echo "\n== (C) ELM sweep H{16,32,64,128} x lambda{1e-6..1e2}, decay=1.0 (20 cfg x 5 folds) =="
|
||||
type Res = tuple[cfg: Cfg, per: seq[float64], mean: float64]
|
||||
var outs: seq[Res]
|
||||
let t0 = epochTime()
|
||||
for k, c in sweep:
|
||||
var per: seq[float64]
|
||||
for f in 0 ..< nFold: per.add evalElm(allSet, c, folds[f].tr, folds[f].te, data, ys)[0].rmse
|
||||
outs.add (c, per, mean(per))
|
||||
if (k + 1) mod 5 == 0: echo fmt" {k+1}/{sweep.len} configs, {epochTime()-t0:.0f}s"
|
||||
outs.sort(proc(a, b: Res): int = cmp(a.mean, b.mean))
|
||||
echo " top 6 (ALL 21 features), per-fold RMSE | mean"
|
||||
for r in outs[0 .. min(5, outs.len - 1)]:
|
||||
echo fmt" H={r.cfg.hid:>4} lam={r.cfg.pen:>8.0e} | " &
|
||||
r.per.mapIt(fmt"{it:.4f}").join(" ") & fmt" | mean {r.mean:.5f} ({100*(r.mean/mConst.rmse-1):+.1f}% vs const)"
|
||||
let best = outs[0]
|
||||
var p2: seq[float64] = @[]
|
||||
var i2: seq[int] = @[]
|
||||
for f in 0 ..< nFold:
|
||||
let (m, pr) = evalElm(allSet, best.cfg, folds[f].tr, folds[f].te, data, ys)
|
||||
for v in pr: p2.add v
|
||||
for i in folds[f].te: i2.add i
|
||||
let mBest = metrics(p2, i2, ys)
|
||||
var diffs: seq[float64]
|
||||
for f in 0 ..< nFold:
|
||||
diffs.add evalElm(allSet, best.cfg, folds[f].tr, folds[f].te, data, ys)[0].rmse - bConst[f]
|
||||
echo fmt" BEST H={best.cfg.hid} lam={best.cfg.pen:.0e}: pooled RMSE/MAE/medAE {mBest.rmse:.5f}/{mBest.mae:.5f}/{mBest.medae:.5f}" &
|
||||
fmt" delta-vs-const {mean(diffs):+.5f} (better on {diffs.countIt(it<0)}/{nFold})"
|
||||
echo fmt" ELM/const pooled RMSE ratio {mBest.rmse/mConst.rmse:.4f}"
|
||||
|
||||
run("label")
|
||||
run("label1d")
|
||||
@@ -0,0 +1,186 @@
|
||||
#!/usr/bin/env python3
|
||||
"""Extract RING labels for every scan tick per enemy.
|
||||
|
||||
The ring (tools/ring_spike/spike.py) fires N rays simultaneously from the
|
||||
shooter's BELIEF centre at bullet speed and takes the first contact with the
|
||||
enemy circle. The label is the 2-D offset between that contact's enemy position
|
||||
and the belief centre, dead-reckoned to the CONTACT tick:
|
||||
|
||||
Pstar = enemy TRUE position at tick fire+k (observer truth)
|
||||
C = belief centre dead-reckoned to fire+k (what we believed then)
|
||||
R = Pstar - C (px, the ring label)
|
||||
|
||||
decomposed in the shooter's frame at fire time:
|
||||
radial = R . u (u = unit bearing C-S) range error
|
||||
lateral = R . n (n = left of u) aim error
|
||||
label = atan2(lateral, beliefDist) radians -- SAME UNITS AND SIGN
|
||||
as the incumbent 1-D aim-error label, so the two are comparable
|
||||
row-for-row.
|
||||
|
||||
Belief reconstruction and ring geometry are imported from spike.py (one
|
||||
definition, no drift). Default is same-tick semantics (fire_tick = scan tick,
|
||||
last scan with turn <= fire_tick), matching extract_realistic.py's default;
|
||||
--prev is the strictly-prior variant (fire_tick = scan tick + 1, last scan with
|
||||
turn < fire_tick), matching extract_realistic.py --prev.
|
||||
|
||||
usage: extract_ring.py [OUT.ndjson] [ROOT] [--prev] [--base FILE]
|
||||
--base FILE merge into an existing samples_*.ndjson instead of emitting a
|
||||
bare side table: every base row keeps its own features and
|
||||
gains ringK/ringLat/ringRad/ringLatAng, `label` becomes the
|
||||
ring label and `label1d` keeps the incumbent aim error.
|
||||
"""
|
||||
import glob, gzip, json, math, os, sys
|
||||
|
||||
sys.path.insert(0, os.path.dirname(os.path.abspath(__file__)))
|
||||
sys.path.insert(0, os.path.join(REPO0 := os.path.abspath(
|
||||
os.path.join(os.path.dirname(os.path.abspath(__file__)), "..", "..")),
|
||||
"tools", "ring_spike"))
|
||||
from spike import collect, ring_contact, BOT_RADIUS
|
||||
|
||||
REPO = REPO0
|
||||
|
||||
|
||||
def wrap(a):
|
||||
while a > math.pi:
|
||||
a -= TAU
|
||||
while a < -math.pi:
|
||||
a += TAU
|
||||
return a
|
||||
|
||||
|
||||
TAU = 2 * math.pi
|
||||
|
||||
|
||||
def belief_centre(hist, ft, prev):
|
||||
"""Same belief as extract_realistic.py: last two usable scans, then
|
||||
dead-reckon with the two-point velocity to `ft`. Returns (cx, cy, age)."""
|
||||
use = [h for h in hist if (h[0] < ft if prev else h[0] <= ft)]
|
||||
if len(use) < 2:
|
||||
return None
|
||||
(t1, x1, y1), (t0, x0, y0) = use[-1], use[-2]
|
||||
gap = t1 - t0
|
||||
if gap <= 0:
|
||||
return None
|
||||
age = ft - t1
|
||||
if age < 0:
|
||||
return None
|
||||
return (x1 + (x1 - x0) / gap * age, y1 + (y1 - y0) / gap * age, age)
|
||||
|
||||
|
||||
def extract(path, tag, prev, spd, rays, rng, out, kint=False):
|
||||
scans, true, names = collect(path)
|
||||
n = 0
|
||||
for rnd in sorted({k[0] for k in scans}):
|
||||
bots = sorted({k[1] for k in scans if k[0] == rnd} |
|
||||
{k[2] for k in scans if k[0] == rnd})
|
||||
for s in bots:
|
||||
for t in bots:
|
||||
if s == t:
|
||||
continue
|
||||
h = scans.get((rnd, s, t), [])
|
||||
if len(h) < 2:
|
||||
continue
|
||||
track = {turn: xy for (rr, bid, turn), xy in true.items()
|
||||
if rr == rnd and bid == t}
|
||||
for (st, _, _) in h:
|
||||
ft = st + 1 if prev else st
|
||||
bc = belief_centre(h, ft, prev)
|
||||
if bc is None:
|
||||
continue
|
||||
Sp = true.get((rnd, s, ft))
|
||||
if Sp is None:
|
||||
continue
|
||||
res = ring_contact((bc[0], bc[1]), track, ft, spd, rays, rng)
|
||||
if res is None:
|
||||
continue
|
||||
_, k = res
|
||||
Pstar = track.get(ft + k)
|
||||
if Pstar is None:
|
||||
continue
|
||||
los = math.atan2(bc[1] - Sp[1], bc[0] - Sp[0])
|
||||
de = math.hypot(bc[0] - Sp[0], bc[1] - Sp[1])
|
||||
if kint:
|
||||
# INTENDED ring tick: the bullet flight time, i.e. the tick
|
||||
# at which a shot aimed at the belief would land. Fully
|
||||
# observable (round(believed range / bullet speed)); used
|
||||
# because the literal contact search degenerates to k=1
|
||||
# (see README: the belief is already within BotRadius of
|
||||
# the enemy, so ray step 1 always "hits").
|
||||
k = max(1, int(round(de / spd)))
|
||||
Pstar = track.get(ft + k)
|
||||
if Pstar is None:
|
||||
continue
|
||||
ux, uy = math.cos(los), math.sin(los)
|
||||
nx, ny = -uy, ux
|
||||
rx, ry = Pstar[0] - bc[0], Pstar[1] - bc[1]
|
||||
lat = rx * nx + ry * ny
|
||||
rad = rx * ux + ry * uy
|
||||
out.write(json.dumps({
|
||||
"group": f"{tag}:{rnd}", "round": rnd, "tick": ft,
|
||||
"shooter": names.get(s, str(s)),
|
||||
"target": names.get(t, str(t)),
|
||||
"ringK": k, "ringLat": lat, "ringRad": rad,
|
||||
"ringMag": math.hypot(rx, ry),
|
||||
"ringLatAng": math.atan2(lat, max(de, 1.0)),
|
||||
"ringRadAng": math.atan2(rad, max(de, 1.0)),
|
||||
"ringDist": de, "ringAge": bc[2],
|
||||
}) + "\n")
|
||||
n += 1
|
||||
return n
|
||||
|
||||
|
||||
def main():
|
||||
here = os.path.dirname(os.path.abspath(__file__))
|
||||
args = [a for a in sys.argv[1:] if not a.startswith("--")]
|
||||
prev = "--prev" in sys.argv
|
||||
kint = "--kintercept" in sys.argv
|
||||
base = None
|
||||
if "--base" in sys.argv:
|
||||
base = sys.argv[sys.argv.index("--base") + 1]
|
||||
args = [a for a in args if a != base]
|
||||
dest = os.path.join(here, args[0] if args else "ring.ndjson")
|
||||
root = os.path.abspath(args[1]) if len(args) > 1 else os.path.join(REPO, "data", "drussgt_raw")
|
||||
spd = 10.0 # bullet power 1.0 -> 10 px/tick; spike: <=1.5 reaches 100%
|
||||
rays = 360
|
||||
rng = 800.0
|
||||
files = sorted(glob.glob(os.path.join(root, "**", "*.battle.gz"), recursive=True))
|
||||
total = 0
|
||||
with open(dest, "w") as out:
|
||||
for f in files:
|
||||
tag = os.path.relpath(os.path.dirname(f), root).replace(os.sep, ":")
|
||||
k = extract(f, tag, prev, spd, rays, rng, out, kint)
|
||||
total += k
|
||||
print(f"{tag}/{os.path.basename(f)}: {k} ring contacts")
|
||||
print("TOTAL", total, "->", dest)
|
||||
|
||||
if base:
|
||||
bp = os.path.join(here, base)
|
||||
side = {}
|
||||
for line in open(dest):
|
||||
j = json.loads(line)
|
||||
side[(j["group"], j["round"], j["tick"], j["shooter"], j["target"])] = j
|
||||
merged = os.path.join(here, dest + ".merged")
|
||||
hit = 0
|
||||
n = 0
|
||||
with open(bp) as src, open(merged, "w") as out:
|
||||
for line in src:
|
||||
if not line.strip():
|
||||
continue
|
||||
j = json.loads(line)
|
||||
key = (j["group"], j["round"], j["tick"], j["shooter"], j["target"])
|
||||
r = side.get(key)
|
||||
if r is None:
|
||||
continue
|
||||
hit += 1
|
||||
n += 1
|
||||
j["label1d"] = j["label"]
|
||||
j["label"] = r["ringLatAng"]
|
||||
for f in ("ringK", "ringLat", "ringRad", "ringMag",
|
||||
"ringLatAng", "ringRadAng", "ringDist"):
|
||||
j[f] = r[f]
|
||||
out.write(json.dumps(j) + "\n")
|
||||
print(f"MERGED {n} of {sum(1 for _ in open(bp))} base rows -> {merged}")
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
@@ -0,0 +1,57 @@
|
||||
#!/usr/bin/env python3
|
||||
"""Label distribution report for a merged ring dataset.
|
||||
|
||||
python3 ring_dist.py ring_drussgt.ndjson.merged
|
||||
"""
|
||||
import json, math, sys
|
||||
|
||||
|
||||
def stats(x):
|
||||
n = len(x)
|
||||
if not n:
|
||||
return None
|
||||
m = sum(x) / n
|
||||
sd = math.sqrt(sum((a - m) ** 2 for a in x) / (n - 1)) if n > 1 else 0.0
|
||||
y = sorted(x)
|
||||
q = lambda p: y[min(n - 1, max(0, int(round(p / 100 * (n - 1)))))]
|
||||
return m, sd, q(1), q(10), q(25), q(50), q(75), q(90), q(99), y[0], y[-1]
|
||||
|
||||
|
||||
def main():
|
||||
rows = [json.loads(l) for l in open(sys.argv[1]) if l.strip()]
|
||||
print(f"rows {len(rows)} groups {len(set(r['group'] for r in rows))}")
|
||||
cols = ["label", "label1d", "ringLat", "ringRad", "ringMag", "ringLatAng",
|
||||
"ringRadAng", "ringDist", "ringK"]
|
||||
print(f"{'column':<12}{'mean':>10}{'sd':>10}{'p1':>10}{'p10':>10}{'p25':>10}"
|
||||
f"{'p50':>10}{'p75':>10}{'p90':>10}{'p99':>10}{'min':>10}{'max':>10}")
|
||||
for c in cols:
|
||||
s = stats([r[c] for r in rows])
|
||||
print(f"{c:<12}" + "".join(f"{v:>10.4f}" for v in s))
|
||||
|
||||
# correlation between the two labels, and the single best linear feature
|
||||
def corr(a, b):
|
||||
n = len(a)
|
||||
ma, mb = sum(a) / n, sum(b) / n
|
||||
sxy = sum((x - ma) * (y - mb) for x, y in zip(a, b))
|
||||
sxx = sum((x - ma) ** 2 for x in a)
|
||||
syy = sum((y - mb) ** 2 for y in b)
|
||||
return sxy / math.sqrt(sxx * syy) if sxx > 0 and syy > 0 else 0.0
|
||||
|
||||
ring = [r["label"] for r in rows]
|
||||
one = [r["label1d"] for r in rows]
|
||||
print(f"\ncorr(ring label, 1-D aim error) = {corr(ring, one):+.4f}")
|
||||
print("\nper-feature Pearson corr with each label (|corr| descending):")
|
||||
feats = ["beliefPredErr", "beliefScanAge", "beliefTgtSpeed", "beliefTof",
|
||||
"beliefRelBearing", "beliefDist", "beliefDisp", "beliefScanGap",
|
||||
"beliefTgtLatVel", "beliefClosing", "beliefLosRate",
|
||||
"oracleDist", "gunHeat", "power", "ownSpeed", "ringK", "ringDist"]
|
||||
tab = []
|
||||
for f in feats:
|
||||
x = [r[f] for r in rows]
|
||||
tab.append((f, corr(x, ring), corr(x, one)))
|
||||
for f, cr, c1 in sorted(tab, key=lambda t: -abs(t[1])):
|
||||
print(f" {f:<18} ring {cr:+.4f} 1-D {c1:+.4f}")
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
@@ -0,0 +1,108 @@
|
||||
== dataset: ring_ki.ndjson.merged ==
|
||||
n = 8020 groups = 40 k mean = 42.22
|
||||
|
||||
== label distribution (rad, same units for both) ==
|
||||
ring mean -0.00209 sd 0.14282 |p1| 0.37041 |p50| 0.00070 |p90| 0.17191 max|.| 0.63946
|
||||
1-D aim mean +0.11160 sd 1.16585 |p1| 2.90010 |p50| 0.00658 |p90| 1.80194 max|.| 3.14139
|
||||
|
||||
########## LABEL = label (RING lateral aim correction) ##########
|
||||
|
||||
== (a) constant baseline, 5-fold by round-group ==
|
||||
constant per-fold 0.1423 +- 0.0061 pooled RMSE/MAE/medAE 0.1429/0.1111/0.0876
|
||||
|
||||
== (B) ridge feature ablation (pooled held-out) ==
|
||||
feature set | RMSE MAE medAE | per-fold RMSE +- sd | vs const
|
||||
baseline 6 (belief geometry) | 0.1423 0.1107 0.0873 | 0.1416 +- 0.0065 | -0.0006
|
||||
+ scan age | 0.1423 0.1107 0.0874 | 0.1416 +- 0.0065 | -0.0006
|
||||
+ believed intercept geom | 0.1424 0.1108 0.0882 | 0.1417 +- 0.0066 | -0.0004
|
||||
+ our own state | 0.1424 0.1107 0.0874 | 0.1417 +- 0.0065 | -0.0005
|
||||
+ context | 0.1424 0.1107 0.0872 | 0.1417 +- 0.0066 | -0.0005
|
||||
+ scan + intercept | 0.1425 0.1108 0.0879 | 0.1418 +- 0.0065 | -0.0004
|
||||
ALL 21 | 0.1426 0.1109 0.0879 | 0.1419 +- 0.0065 | -0.0002
|
||||
|
||||
-- single-feature ridge (held-out, sorted) --
|
||||
cosRel RMSE 0.14215 (const 0.14287, gain +0.50%)
|
||||
dist RMSE 0.14228 (const 0.14287, gain +0.41%)
|
||||
losRate RMSE 0.14229 (const 0.14287, gain +0.41%)
|
||||
scanAge RMSE 0.14230 (const 0.14287, gain +0.40%)
|
||||
logScan RMSE 0.14230 (const 0.14287, gain +0.40%)
|
||||
everScanned RMSE 0.14230 (const 0.14287, gain +0.40%)
|
||||
scanGap RMSE 0.14230 (const 0.14287, gain +0.40%)
|
||||
disp RMSE 0.14230 (const 0.14287, gain +0.40%)
|
||||
gunHeat RMSE 0.14230 (const 0.14287, gain +0.40%)
|
||||
sinPred RMSE 0.14230 (const 0.14287, gain +0.40%)
|
||||
tgtLatVel RMSE 0.14231 (const 0.14287, gain +0.39%)
|
||||
tgtSpeed RMSE 0.14231 (const 0.14287, gain +0.39%)
|
||||
cosPred RMSE 0.14231 (const 0.14287, gain +0.39%)
|
||||
closing RMSE 0.14231 (const 0.14287, gain +0.39%)
|
||||
sinRel RMSE 0.14231 (const 0.14287, gain +0.39%)
|
||||
predErr RMSE 0.14232 (const 0.14287, gain +0.38%)
|
||||
power RMSE 0.14233 (const 0.14287, gain +0.38%)
|
||||
ownSpeed RMSE 0.14238 (const 0.14287, gain +0.34%)
|
||||
tof RMSE 0.14240 (const 0.14287, gain +0.33%)
|
||||
|
||||
== (C) ELM sweep H{16,32,64,128} x lambda{1e-6..1e2}, decay=1.0 (20 cfg x 5 folds) ==
|
||||
5/20 configs, 2.s
|
||||
10/20 configs, 5.s
|
||||
15/20 configs, 9.s
|
||||
20/20 configs, 19.s
|
||||
top 6 (ALL 21 features), per-fold RMSE | mean
|
||||
H= 128 lam= 1.e+00 | 0.1437 0.1421 0.1499 0.1426 0.1295 | mean 0.14158 (-0.9% vs const)
|
||||
H= 128 lam= 1.e+02 | 0.1435 0.1425 0.1503 0.1422 0.1302 | mean 0.14176 (-0.8% vs const)
|
||||
H= 64 lam= 1.e+00 | 0.1436 0.1427 0.1501 0.1423 0.1301 | mean 0.14178 (-0.8% vs const)
|
||||
H= 32 lam= 1.e+00 | 0.1438 0.1429 0.1504 0.1421 0.1299 | mean 0.14180 (-0.7% vs const)
|
||||
H= 32 lam= 1.e-02 | 0.1442 0.1429 0.1504 0.1420 0.1303 | mean 0.14194 (-0.6% vs const)
|
||||
H= 32 lam= 1.e-04 | 0.1442 0.1429 0.1504 0.1420 0.1303 | mean 0.14195 (-0.6% vs const)
|
||||
BEST H=128 lam=1.e+00: pooled RMSE/MAE/medAE 0.14224/0.11042/0.08885 delta-vs-const -0.00072 (better on 4/5)
|
||||
ELM/const pooled RMSE ratio 0.9956
|
||||
|
||||
########## LABEL = label1d (incumbent 1-D aim error) ##########
|
||||
|
||||
== (a) constant baseline, 5-fold by round-group ==
|
||||
constant per-fold 1.1589 +- 0.0386 pooled RMSE/MAE/medAE 1.1661/0.8208/0.4633
|
||||
|
||||
== (B) ridge feature ablation (pooled held-out) ==
|
||||
feature set | RMSE MAE medAE | per-fold RMSE +- sd | vs const
|
||||
baseline 6 (belief geometry) | 1.1651 0.8186 0.4783 | 1.1578 +- 0.0390 | -0.0009
|
||||
+ scan age | 0.9460 0.6389 0.3752 | 0.9443 +- 0.0246 | -0.2201
|
||||
+ believed intercept geom | 0.4415 0.1713 0.1094 | 0.4394 +- 0.0463 | -0.7245
|
||||
+ our own state | 0.9464 0.6394 0.3738 | 0.9448 +- 0.0242 | -0.2197
|
||||
+ context | 0.9460 0.6390 0.3735 | 0.9444 +- 0.0258 | -0.2201
|
||||
+ scan + intercept | 0.4415 0.1713 0.1098 | 0.4394 +- 0.0463 | -0.7245
|
||||
ALL 21 | 0.4419 0.1721 0.1107 | 0.4399 +- 0.0463 | -0.7242
|
||||
|
||||
-- single-feature ridge (held-out, sorted) --
|
||||
predErr RMSE 0.44207 (const 1.16605, gain +62.09%)
|
||||
tgtLatVel RMSE 0.94572 (const 1.16605, gain +18.90%)
|
||||
closing RMSE 1.15006 (const 1.16605, gain +1.37%)
|
||||
tof RMSE 1.15790 (const 1.16605, gain +0.70%)
|
||||
power RMSE 1.15838 (const 1.16605, gain +0.66%)
|
||||
tgtSpeed RMSE 1.15871 (const 1.16605, gain +0.63%)
|
||||
gunHeat RMSE 1.15887 (const 1.16605, gain +0.62%)
|
||||
disp RMSE 1.15888 (const 1.16605, gain +0.62%)
|
||||
scanAge RMSE 1.15889 (const 1.16605, gain +0.61%)
|
||||
logScan RMSE 1.15889 (const 1.16605, gain +0.61%)
|
||||
everScanned RMSE 1.15889 (const 1.16605, gain +0.61%)
|
||||
scanGap RMSE 1.15889 (const 1.16605, gain +0.61%)
|
||||
dist RMSE 1.15889 (const 1.16605, gain +0.61%)
|
||||
sinRel RMSE 1.15892 (const 1.16605, gain +0.61%)
|
||||
cosRel RMSE 1.15933 (const 1.16605, gain +0.58%)
|
||||
sinPred RMSE 1.15934 (const 1.16605, gain +0.58%)
|
||||
ownSpeed RMSE 1.15943 (const 1.16605, gain +0.57%)
|
||||
cosPred RMSE 1.17038 (const 1.16605, gain -0.37%)
|
||||
losRate RMSE 1.41676 (const 1.16605, gain -21.50%)
|
||||
|
||||
== (C) ELM sweep H{16,32,64,128} x lambda{1e-6..1e2}, decay=1.0 (20 cfg x 5 folds) ==
|
||||
5/20 configs, 2.s
|
||||
10/20 configs, 5.s
|
||||
15/20 configs, 9.s
|
||||
20/20 configs, 19.s
|
||||
top 6 (ALL 21 features), per-fold RMSE | mean
|
||||
H= 128 lam= 1.e-02 | 0.3682 0.4847 0.4027 0.4101 0.4441 | mean 0.42195 (-63.8% vs const)
|
||||
H= 128 lam= 1.e-04 | 0.3696 0.4854 0.4050 0.4099 0.4454 | mean 0.42308 (-63.7% vs const)
|
||||
H= 128 lam= 1.e-06 | 0.3696 0.4854 0.4051 0.4100 0.4454 | mean 0.42310 (-63.7% vs const)
|
||||
H= 128 lam= 1.e+00 | 0.3694 0.5002 0.4082 0.4235 0.4455 | mean 0.42936 (-63.2% vs const)
|
||||
H= 64 lam= 1.e-02 | 0.3775 0.5071 0.4259 0.4227 0.4473 | mean 0.43611 (-62.6% vs const)
|
||||
H= 64 lam= 1.e-04 | 0.3782 0.5068 0.4261 0.4224 0.4473 | mean 0.43617 (-62.6% vs const)
|
||||
BEST H=128 lam=1.e-02: pooled RMSE/MAE/medAE 0.42349/0.18269/0.11082 delta-vs-const -0.73693 (better on 5/5)
|
||||
ELM/const pooled RMSE ratio 0.3632
|
||||
@@ -0,0 +1,108 @@
|
||||
== dataset: ring_ki_prev.ndjson.merged ==
|
||||
n = 8308 groups = 40 k mean = 42.26
|
||||
|
||||
== label distribution (rad, same units for both) ==
|
||||
ring mean -0.00248 sd 0.15031 |p1| 0.39813 |p50| 0.00149 |p90| 0.17493 max|.| 0.65861
|
||||
1-D aim mean +0.11862 sd 1.15723 |p1| 2.89396 |p50| 0.01136 |p90| 1.80170 max|.| 3.14139
|
||||
|
||||
########## LABEL = label (RING lateral aim correction) ##########
|
||||
|
||||
== (a) constant baseline, 5-fold by round-group ==
|
||||
constant per-fold 0.1502 +- 0.0046 pooled RMSE/MAE/medAE 0.1504/0.1151/0.0895
|
||||
|
||||
== (B) ridge feature ablation (pooled held-out) ==
|
||||
feature set | RMSE MAE medAE | per-fold RMSE +- sd | vs const
|
||||
baseline 6 (belief geometry) | 0.1501 0.1146 0.0889 | 0.1499 +- 0.0052 | -0.0003
|
||||
+ scan age | 0.1500 0.1146 0.0890 | 0.1499 +- 0.0051 | -0.0003
|
||||
+ believed intercept geom | 0.1503 0.1147 0.0888 | 0.1502 +- 0.0051 | -0.0000
|
||||
+ our own state | 0.1500 0.1147 0.0891 | 0.1499 +- 0.0050 | -0.0003
|
||||
+ context | 0.1500 0.1146 0.0890 | 0.1499 +- 0.0050 | -0.0003
|
||||
+ scan + intercept | 0.1504 0.1147 0.0890 | 0.1503 +- 0.0051 | +0.0000
|
||||
ALL 21 | 0.1505 0.1148 0.0891 | 0.1504 +- 0.0052 | +0.0001
|
||||
|
||||
-- single-feature ridge (held-out, sorted) --
|
||||
cosPred RMSE 0.15006 (const 0.15036, gain +0.20%)
|
||||
cosRel RMSE 0.15011 (const 0.15036, gain +0.17%)
|
||||
tgtLatVel RMSE 0.15015 (const 0.15036, gain +0.14%)
|
||||
dist RMSE 0.15017 (const 0.15036, gain +0.13%)
|
||||
losRate RMSE 0.15018 (const 0.15036, gain +0.12%)
|
||||
predErr RMSE 0.15018 (const 0.15036, gain +0.12%)
|
||||
disp RMSE 0.15018 (const 0.15036, gain +0.12%)
|
||||
scanAge RMSE 0.15018 (const 0.15036, gain +0.12%)
|
||||
logScan RMSE 0.15018 (const 0.15036, gain +0.12%)
|
||||
everScanned RMSE 0.15018 (const 0.15036, gain +0.12%)
|
||||
gunHeat RMSE 0.15019 (const 0.15036, gain +0.12%)
|
||||
sinRel RMSE 0.15022 (const 0.15036, gain +0.10%)
|
||||
sinPred RMSE 0.15022 (const 0.15036, gain +0.10%)
|
||||
power RMSE 0.15025 (const 0.15036, gain +0.08%)
|
||||
scanGap RMSE 0.15025 (const 0.15036, gain +0.08%)
|
||||
ownSpeed RMSE 0.15025 (const 0.15036, gain +0.07%)
|
||||
closing RMSE 0.15028 (const 0.15036, gain +0.06%)
|
||||
tof RMSE 0.15031 (const 0.15036, gain +0.03%)
|
||||
tgtSpeed RMSE 0.15044 (const 0.15036, gain -0.05%)
|
||||
|
||||
== (C) ELM sweep H{16,32,64,128} x lambda{1e-6..1e2}, decay=1.0 (20 cfg x 5 folds) ==
|
||||
5/20 configs, 2.s
|
||||
10/20 configs, 5.s
|
||||
15/20 configs, 10.s
|
||||
20/20 configs, 20.s
|
||||
top 6 (ALL 21 features), per-fold RMSE | mean
|
||||
H= 128 lam= 1.e+02 | 0.1509 0.1492 0.1547 0.1545 0.1411 | mean 0.15007 (-0.2% vs const)
|
||||
H= 32 lam= 1.e+02 | 0.1509 0.1494 0.1552 0.1537 0.1416 | mean 0.15017 (-0.1% vs const)
|
||||
H= 64 lam= 1.e+02 | 0.1509 0.1493 0.1550 0.1544 0.1414 | mean 0.15020 (-0.1% vs const)
|
||||
H= 16 lam= 1.e+02 | 0.1509 0.1491 0.1555 0.1542 0.1419 | mean 0.15030 (-0.0% vs const)
|
||||
H= 32 lam= 1.e+00 | 0.1511 0.1494 0.1546 0.1560 0.1409 | mean 0.15041 (+0.0% vs const)
|
||||
H= 64 lam= 1.e+00 | 0.1508 0.1488 0.1539 0.1576 0.1411 | mean 0.15046 (+0.1% vs const)
|
||||
BEST H=128 lam=1.e+02: pooled RMSE/MAE/medAE 0.15021/0.11474/0.08866 delta-vs-const -0.00012 (better on 2/5)
|
||||
ELM/const pooled RMSE ratio 0.9990
|
||||
|
||||
########## LABEL = label1d (incumbent 1-D aim error) ##########
|
||||
|
||||
== (a) constant baseline, 5-fold by round-group ==
|
||||
constant per-fold 1.1494 +- 0.0428 pooled RMSE/MAE/medAE 1.1574/0.8129/0.4542
|
||||
|
||||
== (B) ridge feature ablation (pooled held-out) ==
|
||||
feature set | RMSE MAE medAE | per-fold RMSE +- sd | vs const
|
||||
baseline 6 (belief geometry) | 1.1558 0.8093 0.4724 | 1.1479 +- 0.0425 | -0.0016
|
||||
+ scan age | 1.1537 0.8064 0.4662 | 1.1459 +- 0.0420 | -0.0037
|
||||
+ believed intercept geom | 1.1496 0.7987 0.4485 | 1.1420 +- 0.0415 | -0.0078
|
||||
+ our own state | 1.1544 0.8081 0.4669 | 1.1465 +- 0.0428 | -0.0030
|
||||
+ context | 1.1534 0.8075 0.4686 | 1.1456 +- 0.0422 | -0.0040
|
||||
+ scan + intercept | 1.1492 0.8000 0.4532 | 1.1415 +- 0.0415 | -0.0082
|
||||
ALL 21 | 1.1496 0.8025 0.4566 | 1.1418 +- 0.0428 | -0.0077
|
||||
|
||||
-- single-feature ridge (held-out, sorted) --
|
||||
predErr RMSE 1.14262 (const 1.15739, gain +1.28%)
|
||||
tgtLatVel RMSE 1.14701 (const 1.15739, gain +0.90%)
|
||||
tof RMSE 1.14800 (const 1.15739, gain +0.81%)
|
||||
closing RMSE 1.14805 (const 1.15739, gain +0.81%)
|
||||
power RMSE 1.14879 (const 1.15739, gain +0.74%)
|
||||
tgtSpeed RMSE 1.14889 (const 1.15739, gain +0.73%)
|
||||
losRate RMSE 1.14918 (const 1.15739, gain +0.71%)
|
||||
sinPred RMSE 1.14940 (const 1.15739, gain +0.69%)
|
||||
gunHeat RMSE 1.14941 (const 1.15739, gain +0.69%)
|
||||
disp RMSE 1.14941 (const 1.15739, gain +0.69%)
|
||||
scanAge RMSE 1.14943 (const 1.15739, gain +0.69%)
|
||||
logScan RMSE 1.14943 (const 1.15739, gain +0.69%)
|
||||
everScanned RMSE 1.14943 (const 1.15739, gain +0.69%)
|
||||
dist RMSE 1.14943 (const 1.15739, gain +0.69%)
|
||||
scanGap RMSE 1.14943 (const 1.15739, gain +0.69%)
|
||||
sinRel RMSE 1.14945 (const 1.15739, gain +0.69%)
|
||||
cosRel RMSE 1.14970 (const 1.15739, gain +0.66%)
|
||||
ownSpeed RMSE 1.14992 (const 1.15739, gain +0.65%)
|
||||
cosPred RMSE 1.14995 (const 1.15739, gain +0.64%)
|
||||
|
||||
== (C) ELM sweep H{16,32,64,128} x lambda{1e-6..1e2}, decay=1.0 (20 cfg x 5 folds) ==
|
||||
5/20 configs, 2.s
|
||||
10/20 configs, 5.s
|
||||
15/20 configs, 10.s
|
||||
20/20 configs, 20.s
|
||||
top 6 (ALL 21 features), per-fold RMSE | mean
|
||||
H= 128 lam= 1.e+00 | 1.1599 1.1643 1.1783 1.0653 1.1213 | mean 1.13784 (-1.7% vs const)
|
||||
H= 64 lam= 1.e+00 | 1.1580 1.1654 1.1794 1.0653 1.1214 | mean 1.13789 (-1.7% vs const)
|
||||
H= 128 lam= 1.e-02 | 1.1579 1.1662 1.1839 1.0662 1.1189 | mean 1.13863 (-1.6% vs const)
|
||||
H= 64 lam= 1.e-02 | 1.1586 1.1632 1.1846 1.0667 1.1223 | mean 1.13908 (-1.6% vs const)
|
||||
H= 64 lam= 1.e-04 | 1.1587 1.1635 1.1853 1.0671 1.1233 | mean 1.13956 (-1.5% vs const)
|
||||
H= 64 lam= 1.e-06 | 1.1587 1.1635 1.1853 1.0671 1.1233 | mean 1.13957 (-1.5% vs const)
|
||||
BEST H=128 lam=1.e+00: pooled RMSE/MAE/medAE 1.14535/0.79943/0.46483 delta-vs-const -0.01158 (better on 5/5)
|
||||
ELM/const pooled RMSE ratio 0.9896
|
||||
@@ -0,0 +1,108 @@
|
||||
== dataset: ring_prev.ndjson.merged ==
|
||||
n = 8411 groups = 40 k mean = 1.03
|
||||
|
||||
== label distribution (rad, same units for both) ==
|
||||
ring mean -0.00064 sd 0.01341 |p1| 0.03532 |p50| 0.00025 |p90| 0.01636 max|.| 0.05561
|
||||
1-D aim mean +0.11759 sd 1.16371 |p1| 2.90073 |p50| 0.01136 |p90| 1.80628 max|.| 3.14139
|
||||
|
||||
########## LABEL = label (RING lateral aim correction) ##########
|
||||
|
||||
== (a) constant baseline, 5-fold by round-group ==
|
||||
constant per-fold 0.0134 +- 0.0003 pooled RMSE/MAE/medAE 0.0134/0.0106/0.0090
|
||||
|
||||
== (B) ridge feature ablation (pooled held-out) ==
|
||||
feature set | RMSE MAE medAE | per-fold RMSE +- sd | vs const
|
||||
baseline 6 (belief geometry) | 0.0134 0.0106 0.0090 | 0.0134 +- 0.0003 | -0.0000
|
||||
+ scan age | 0.0133 0.0104 0.0088 | 0.0133 +- 0.0002 | -0.0001
|
||||
+ believed intercept geom | 0.0133 0.0104 0.0088 | 0.0133 +- 0.0002 | -0.0002
|
||||
+ our own state | 0.0133 0.0104 0.0088 | 0.0133 +- 0.0003 | -0.0001
|
||||
+ context | 0.0133 0.0104 0.0087 | 0.0133 +- 0.0003 | -0.0001
|
||||
+ scan + intercept | 0.0133 0.0104 0.0087 | 0.0133 +- 0.0002 | -0.0002
|
||||
ALL 21 | 0.0133 0.0104 0.0088 | 0.0133 +- 0.0003 | -0.0001
|
||||
|
||||
-- single-feature ridge (held-out, sorted) --
|
||||
tgtLatVel RMSE 0.01327 (const 0.01341, gain +1.04%)
|
||||
predErr RMSE 0.01336 (const 0.01341, gain +0.36%)
|
||||
losRate RMSE 0.01339 (const 0.01341, gain +0.14%)
|
||||
tgtSpeed RMSE 0.01340 (const 0.01341, gain +0.13%)
|
||||
tof RMSE 0.01341 (const 0.01341, gain +0.03%)
|
||||
closing RMSE 0.01341 (const 0.01341, gain +0.03%)
|
||||
dist RMSE 0.01341 (const 0.01341, gain +0.03%)
|
||||
scanAge RMSE 0.01341 (const 0.01341, gain +0.03%)
|
||||
logScan RMSE 0.01341 (const 0.01341, gain +0.03%)
|
||||
everScanned RMSE 0.01341 (const 0.01341, gain +0.03%)
|
||||
gunHeat RMSE 0.01341 (const 0.01341, gain +0.03%)
|
||||
disp RMSE 0.01341 (const 0.01341, gain +0.03%)
|
||||
sinRel RMSE 0.01341 (const 0.01341, gain +0.03%)
|
||||
ownSpeed RMSE 0.01341 (const 0.01341, gain +0.03%)
|
||||
cosRel RMSE 0.01341 (const 0.01341, gain +0.03%)
|
||||
power RMSE 0.01341 (const 0.01341, gain +0.03%)
|
||||
sinPred RMSE 0.01341 (const 0.01341, gain +0.03%)
|
||||
scanGap RMSE 0.01341 (const 0.01341, gain +0.02%)
|
||||
cosPred RMSE 0.01341 (const 0.01341, gain -0.00%)
|
||||
|
||||
== (C) ELM sweep H{16,32,64,128} x lambda{1e-6..1e2}, decay=1.0 (20 cfg x 5 folds) ==
|
||||
5/20 configs, 2.s
|
||||
10/20 configs, 5.s
|
||||
15/20 configs, 10.s
|
||||
20/20 configs, 21.s
|
||||
top 6 (ALL 21 features), per-fold RMSE | mean
|
||||
H= 128 lam= 1.e+00 | 0.0131 0.0130 0.0135 0.0134 0.0128 | mean 0.01317 (-1.8% vs const)
|
||||
H= 64 lam= 1.e+00 | 0.0131 0.0130 0.0135 0.0134 0.0128 | mean 0.01318 (-1.8% vs const)
|
||||
H= 128 lam= 1.e-02 | 0.0132 0.0131 0.0136 0.0134 0.0128 | mean 0.01320 (-1.6% vs const)
|
||||
H= 64 lam= 1.e-02 | 0.0132 0.0131 0.0136 0.0134 0.0128 | mean 0.01320 (-1.6% vs const)
|
||||
H= 64 lam= 1.e-04 | 0.0132 0.0131 0.0136 0.0134 0.0128 | mean 0.01320 (-1.6% vs const)
|
||||
H= 64 lam= 1.e-06 | 0.0132 0.0131 0.0136 0.0134 0.0128 | mean 0.01321 (-1.6% vs const)
|
||||
BEST H=128 lam=1.e+00: pooled RMSE/MAE/medAE 0.01317/0.01033/0.00882 delta-vs-const -0.00024 (better on 5/5)
|
||||
ELM/const pooled RMSE ratio 0.9819
|
||||
|
||||
########## LABEL = label1d (incumbent 1-D aim error) ##########
|
||||
|
||||
== (a) constant baseline, 5-fold by round-group ==
|
||||
constant per-fold 1.1576 +- 0.0352 pooled RMSE/MAE/medAE 1.1638/0.8169/0.4553
|
||||
|
||||
== (B) ridge feature ablation (pooled held-out) ==
|
||||
feature set | RMSE MAE medAE | per-fold RMSE +- sd | vs const
|
||||
baseline 6 (belief geometry) | 1.1622 0.8133 0.4719 | 1.1560 +- 0.0349 | -0.0016
|
||||
+ scan age | 1.1601 0.8104 0.4646 | 1.1541 +- 0.0343 | -0.0037
|
||||
+ believed intercept geom | 1.1561 0.8027 0.4487 | 1.1502 +- 0.0338 | -0.0078
|
||||
+ our own state | 1.1609 0.8120 0.4677 | 1.1547 +- 0.0351 | -0.0030
|
||||
+ context | 1.1598 0.8117 0.4698 | 1.1537 +- 0.0346 | -0.0040
|
||||
+ scan + intercept | 1.1556 0.8041 0.4550 | 1.1496 +- 0.0340 | -0.0082
|
||||
ALL 21 | 1.1561 0.8067 0.4596 | 1.1500 +- 0.0353 | -0.0077
|
||||
|
||||
-- single-feature ridge (held-out, sorted) --
|
||||
predErr RMSE 1.15086 (const 1.16384, gain +1.12%)
|
||||
tgtLatVel RMSE 1.15522 (const 1.16384, gain +0.74%)
|
||||
tof RMSE 1.15616 (const 1.16384, gain +0.66%)
|
||||
closing RMSE 1.15625 (const 1.16384, gain +0.65%)
|
||||
power RMSE 1.15698 (const 1.16384, gain +0.59%)
|
||||
tgtSpeed RMSE 1.15709 (const 1.16384, gain +0.58%)
|
||||
losRate RMSE 1.15734 (const 1.16384, gain +0.56%)
|
||||
sinPred RMSE 1.15753 (const 1.16384, gain +0.54%)
|
||||
gunHeat RMSE 1.15757 (const 1.16384, gain +0.54%)
|
||||
sinRel RMSE 1.15758 (const 1.16384, gain +0.54%)
|
||||
disp RMSE 1.15758 (const 1.16384, gain +0.54%)
|
||||
scanAge RMSE 1.15759 (const 1.16384, gain +0.54%)
|
||||
everScanned RMSE 1.15759 (const 1.16384, gain +0.54%)
|
||||
logScan RMSE 1.15759 (const 1.16384, gain +0.54%)
|
||||
dist RMSE 1.15760 (const 1.16384, gain +0.54%)
|
||||
scanGap RMSE 1.15760 (const 1.16384, gain +0.54%)
|
||||
cosRel RMSE 1.15782 (const 1.16384, gain +0.52%)
|
||||
cosPred RMSE 1.15803 (const 1.16384, gain +0.50%)
|
||||
ownSpeed RMSE 1.15810 (const 1.16384, gain +0.49%)
|
||||
|
||||
== (C) ELM sweep H{16,32,64,128} x lambda{1e-6..1e2}, decay=1.0 (20 cfg x 5 folds) ==
|
||||
5/20 configs, 2.s
|
||||
10/20 configs, 5.s
|
||||
15/20 configs, 10.s
|
||||
20/20 configs, 20.s
|
||||
top 6 (ALL 21 features), per-fold RMSE | mean
|
||||
H= 128 lam= 1.e+00 | 1.1647 1.1678 1.1786 1.0850 1.1345 | mean 1.14613 (-1.5% vs const)
|
||||
H= 64 lam= 1.e+00 | 1.1621 1.1688 1.1798 1.0857 1.1345 | mean 1.14621 (-1.5% vs const)
|
||||
H= 128 lam= 1.e-02 | 1.1618 1.1706 1.1843 1.0842 1.1309 | mean 1.14637 (-1.5% vs const)
|
||||
H= 64 lam= 1.e-02 | 1.1632 1.1667 1.1855 1.0863 1.1346 | mean 1.14722 (-1.4% vs const)
|
||||
H= 64 lam= 1.e-04 | 1.1631 1.1668 1.1861 1.0864 1.1354 | mean 1.14756 (-1.4% vs const)
|
||||
H= 64 lam= 1.e-06 | 1.1631 1.1668 1.1861 1.0864 1.1354 | mean 1.14756 (-1.4% vs const)
|
||||
BEST H=128 lam=1.e+00: pooled RMSE/MAE/medAE 1.15207/0.80368/0.46343 delta-vs-const -0.01146 (better on 5/5)
|
||||
ELM/const pooled RMSE ratio 0.9899
|
||||
@@ -0,0 +1,108 @@
|
||||
== dataset: ring_drussgt.ndjson.merged ==
|
||||
n = 8119 groups = 40 k mean = 1.00
|
||||
|
||||
== label distribution (rad, same units for both) ==
|
||||
ring mean -0.00023 sd 0.01044 |p1| 0.02166 |p50| 0.00008 |p90| 0.01476 max|.| 0.02704
|
||||
1-D aim mean +0.11074 sd 1.17266 |p1| 2.90099 |p50| 0.00668 |p90| 1.80735 max|.| 3.14139
|
||||
|
||||
########## LABEL = label (RING lateral aim correction) ##########
|
||||
|
||||
== (a) constant baseline, 5-fold by round-group ==
|
||||
constant per-fold 0.0104 +- 0.0002 pooled RMSE/MAE/medAE 0.0104/0.0083/0.0069
|
||||
|
||||
== (B) ridge feature ablation (pooled held-out) ==
|
||||
feature set | RMSE MAE medAE | per-fold RMSE +- sd | vs const
|
||||
baseline 6 (belief geometry) | 0.0104 0.0083 0.0069 | 0.0104 +- 0.0002 | +0.0000
|
||||
+ scan age | 0.0029 0.0021 0.0015 | 0.0029 +- 0.0001 | -0.0075
|
||||
+ believed intercept geom | 0.0026 0.0018 0.0012 | 0.0026 +- 0.0001 | -0.0078
|
||||
+ our own state | 0.0029 0.0021 0.0015 | 0.0029 +- 0.0001 | -0.0075
|
||||
+ context | 0.0029 0.0021 0.0015 | 0.0029 +- 0.0001 | -0.0075
|
||||
+ scan + intercept | 0.0026 0.0018 0.0012 | 0.0026 +- 0.0001 | -0.0078
|
||||
ALL 21 | 0.0026 0.0018 0.0012 | 0.0026 +- 0.0001 | -0.0078
|
||||
|
||||
-- single-feature ridge (held-out, sorted) --
|
||||
tgtLatVel RMSE 0.00294 (const 0.01044, gain +71.84%)
|
||||
predErr RMSE 0.00803 (const 0.01044, gain +23.13%)
|
||||
closing RMSE 0.01034 (const 0.01044, gain +0.95%)
|
||||
sinRel RMSE 0.01041 (const 0.01044, gain +0.28%)
|
||||
scanAge RMSE 0.01041 (const 0.01044, gain +0.28%)
|
||||
logScan RMSE 0.01041 (const 0.01044, gain +0.28%)
|
||||
everScanned RMSE 0.01041 (const 0.01044, gain +0.28%)
|
||||
scanGap RMSE 0.01041 (const 0.01044, gain +0.28%)
|
||||
dist RMSE 0.01041 (const 0.01044, gain +0.28%)
|
||||
disp RMSE 0.01041 (const 0.01044, gain +0.28%)
|
||||
gunHeat RMSE 0.01041 (const 0.01044, gain +0.28%)
|
||||
tof RMSE 0.01041 (const 0.01044, gain +0.28%)
|
||||
power RMSE 0.01041 (const 0.01044, gain +0.28%)
|
||||
tgtSpeed RMSE 0.01041 (const 0.01044, gain +0.28%)
|
||||
ownSpeed RMSE 0.01041 (const 0.01044, gain +0.26%)
|
||||
cosRel RMSE 0.01041 (const 0.01044, gain +0.25%)
|
||||
sinPred RMSE 0.01042 (const 0.01044, gain +0.25%)
|
||||
cosPred RMSE 0.01047 (const 0.01044, gain -0.23%)
|
||||
losRate RMSE 0.01573 (const 0.01044, gain -50.70%)
|
||||
|
||||
== (C) ELM sweep H{16,32,64,128} x lambda{1e-6..1e2}, decay=1.0 (20 cfg x 5 folds) ==
|
||||
5/20 configs, 2.s
|
||||
10/20 configs, 5.s
|
||||
15/20 configs, 11.s
|
||||
20/20 configs, 22.s
|
||||
top 6 (ALL 21 features), per-fold RMSE | mean
|
||||
H= 128 lam= 1.e-02 | 0.0027 0.0026 0.0028 0.0027 0.0028 | mean 0.00274 (-73.7% vs const)
|
||||
H= 128 lam= 1.e-04 | 0.0028 0.0026 0.0029 0.0027 0.0028 | mean 0.00275 (-73.7% vs const)
|
||||
H= 128 lam= 1.e-06 | 0.0028 0.0026 0.0029 0.0027 0.0028 | mean 0.00275 (-73.7% vs const)
|
||||
H= 128 lam= 1.e+00 | 0.0028 0.0027 0.0029 0.0028 0.0029 | mean 0.00282 (-72.9% vs const)
|
||||
H= 64 lam= 1.e-02 | 0.0028 0.0028 0.0029 0.0028 0.0029 | mean 0.00285 (-72.7% vs const)
|
||||
H= 64 lam= 1.e-04 | 0.0028 0.0028 0.0029 0.0028 0.0029 | mean 0.00285 (-72.7% vs const)
|
||||
BEST H=128 lam=1.e-02: pooled RMSE/MAE/medAE 0.00274/0.00190/0.00136 delta-vs-const -0.00767 (better on 5/5)
|
||||
ELM/const pooled RMSE ratio 0.2628
|
||||
|
||||
########## LABEL = label1d (incumbent 1-D aim error) ##########
|
||||
|
||||
== (a) constant baseline, 5-fold by round-group ==
|
||||
constant per-fold 1.1674 +- 0.0310 pooled RMSE/MAE/medAE 1.1728/0.8251/0.4661
|
||||
|
||||
== (B) ridge feature ablation (pooled held-out) ==
|
||||
feature set | RMSE MAE medAE | per-fold RMSE +- sd | vs const
|
||||
baseline 6 (belief geometry) | 1.1718 0.8229 0.4801 | 1.1663 +- 0.0314 | -0.0010
|
||||
+ scan age | 0.9534 0.6431 0.3751 | 0.9531 +- 0.0228 | -0.2194
|
||||
+ believed intercept geom | 0.4436 0.1716 0.1097 | 0.4430 +- 0.0463 | -0.7293
|
||||
+ our own state | 0.9538 0.6436 0.3754 | 0.9535 +- 0.0223 | -0.2190
|
||||
+ context | 0.9534 0.6433 0.3740 | 0.9531 +- 0.0241 | -0.2195
|
||||
+ scan + intercept | 0.4436 0.1716 0.1096 | 0.4430 +- 0.0463 | -0.7293
|
||||
ALL 21 | 0.4439 0.1723 0.1108 | 0.4434 +- 0.0465 | -0.7289
|
||||
|
||||
-- single-feature ridge (held-out, sorted) --
|
||||
predErr RMSE 0.44568 (const 1.17283, gain +62.00%)
|
||||
tgtLatVel RMSE 0.95457 (const 1.17283, gain +18.61%)
|
||||
closing RMSE 1.15851 (const 1.17283, gain +1.22%)
|
||||
tof RMSE 1.16638 (const 1.17283, gain +0.55%)
|
||||
power RMSE 1.16689 (const 1.17283, gain +0.51%)
|
||||
tgtSpeed RMSE 1.16719 (const 1.17283, gain +0.48%)
|
||||
gunHeat RMSE 1.16736 (const 1.17283, gain +0.47%)
|
||||
sinRel RMSE 1.16737 (const 1.17283, gain +0.47%)
|
||||
disp RMSE 1.16737 (const 1.17283, gain +0.47%)
|
||||
scanAge RMSE 1.16738 (const 1.17283, gain +0.47%)
|
||||
logScan RMSE 1.16738 (const 1.17283, gain +0.47%)
|
||||
everScanned RMSE 1.16738 (const 1.17283, gain +0.47%)
|
||||
scanGap RMSE 1.16738 (const 1.17283, gain +0.47%)
|
||||
dist RMSE 1.16738 (const 1.17283, gain +0.46%)
|
||||
cosRel RMSE 1.16776 (const 1.17283, gain +0.43%)
|
||||
sinPred RMSE 1.16781 (const 1.17283, gain +0.43%)
|
||||
ownSpeed RMSE 1.16792 (const 1.17283, gain +0.42%)
|
||||
cosPred RMSE 1.17901 (const 1.17283, gain -0.53%)
|
||||
losRate RMSE 1.40867 (const 1.17283, gain -20.11%)
|
||||
|
||||
== (C) ELM sweep H{16,32,64,128} x lambda{1e-6..1e2}, decay=1.0 (20 cfg x 5 folds) ==
|
||||
5/20 configs, 2.s
|
||||
10/20 configs, 5.s
|
||||
15/20 configs, 10.s
|
||||
20/20 configs, 21.s
|
||||
top 6 (ALL 21 features), per-fold RMSE | mean
|
||||
H= 128 lam= 1.e-02 | 0.3672 0.4830 0.4038 0.4327 0.4402 | mean 0.42537 (-63.7% vs const)
|
||||
H= 128 lam= 1.e-04 | 0.3686 0.4839 0.4064 0.4321 0.4414 | mean 0.42647 (-63.6% vs const)
|
||||
H= 128 lam= 1.e-06 | 0.3686 0.4839 0.4065 0.4321 0.4414 | mean 0.42649 (-63.6% vs const)
|
||||
H= 128 lam= 1.e+00 | 0.3689 0.4975 0.4077 0.4485 0.4428 | mean 0.43309 (-63.1% vs const)
|
||||
H= 64 lam= 1.e-02 | 0.3769 0.5047 0.4257 0.4478 0.4447 | mean 0.43996 (-62.5% vs const)
|
||||
H= 64 lam= 1.e-04 | 0.3776 0.5045 0.4259 0.4475 0.4446 | mean 0.44002 (-62.5% vs const)
|
||||
BEST H=128 lam=1.e-02: pooled RMSE/MAE/medAE 0.42562/0.18273/0.11064 delta-vs-const -0.74201 (better on 5/5)
|
||||
ELM/const pooled RMSE ratio 0.3629
|
||||
Reference in New Issue
Block a user