Add P6 benchmark code, locked protocol_bench, T2 study and lock inputs

- ml_porosity/benchmark/ runner, scripts 32-35, scripts/run_bench.sh;
  misspec= option in synth_d2 (default path reproduces P2r bit for bit).
- configs/protocol_bench.{yaml,sha256,lock.json} locked 29/10 14:39 UTC
  (sha256 aa763f0a...), configs/d2_synth_bench.yaml.
- The eight protocol_bench inputs force-added from outputs/ (warp prior,
  wavelets, horizon cache, budgets) so load_protocol() and summarize work
  after a fresh clone. The 102 P2r reference artifacts (1.4 GB of particle
  npz) are not in git; they are only checked by posterior/train stages.
- T2 mechanism declaration and results; operations/p6_supervisor.py.
- Docs, report and paper edits of 29/10.

Main S1 runs are still training at this commit; results follow.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-30 01:06:59 +00:00
parent 0cfe202a8b
commit f3c30517fa
51 changed files with 6529 additions and 58 deletions

View File

@@ -106,6 +106,12 @@ Read first: `docs/plan.md` (plan, gates, decisions; §6 roadmap, §10 forbidden
`.gitignore`, and the 29/10 paper/docs edits. Run logs `logs/*.out` stay
untracked, as before (`docs/plan.md` §12 item 25).
- **P6 (level-B benchmark) started early on 29/10/2026** (`docs/plan.md` §12 item 26; uncommitted). Subagents: Fable for reasoning-heavy work, Opus for routine work.
- p6-gen done: `misspec=` in `ml_porosity/data/synth_d2.py` (rock physics, wavelet, drift); `misspec=None` reproduces the P2r fingerprints bit for bit (`tests/test_d2_misspec.py`); presets in `configs/d2_synth_bench.yaml` are still PLACEHOLDER; QC in `scripts/33_bench_generator_qc.py`, notes in `docs/research/bench-generator.md`. The uniform rock-physics error is absorbed by the profiled-α likelihood (control only).
- T2 done (exploratory; declared and hashed before computing; results `docs/research/t2-results.md`, `outputs/t2/summary.md`). B3d-Sa's label error is Berkson at c = 1, so 1/B_b applies and the H2b gain does not exceed the population correction; a GP-noise bank with the posterior's mean and covariance gets most of the c = 1 gain (label augmentation); implicit re-registration is real (8/8 wide cells); no evidence for the multimodal mechanism; about a third of the PM–Oracle gap is training length. Never use T2 to reselect P2r budgets.
- Runner built (`ml_porosity/benchmark/`, `scripts/34_run_bench.py`, `35_bench_calibration.py`, `scripts/run_bench.sh`; design `docs/research/bench-protocol.md`); a P2r cell reproduces bit for bit through it. S2 levels chosen on dev 902–905. `configs/protocol_bench.yaml` is **locked** (29/10 14:39 UTC; sha256 aa763f0a…; TCN budgets 125 from dev; L1 levels above the declared band are disclosed). **Main runs started 29/10 14:43 UTC; all four drivers were SIGTERMed at 15:27 when the agent session ended** (setsid nohup is not enough). Relaunched in the user's tmux server (15:41 on cuda:0; resized at 16:07 UTC when the other project released both GPUs): `p6_s2` (S2, cuda:1, 6 workers), `p6_s1a` (S1 R10/Rm5/R0, cuda:0, 5 workers), `p6_s1b` (S1 R0h/R10tb, cuda:1, 2 workers), `p6_s348` (S3+S4+S8 train, cuda:0, 4 workers); logs `logs/bench_{s2_cuda1,s1a_cuda0,s1b_cuda1,s348_cuda0}.out`. Worker count is bounded by 40 CPUs (2 threads each). Since 16:22 UTC `operations/p6_supervisor.py` (tmux `p6_supervisor`, log `logs/p6_supervisor.out`, state `logs/p6_supervisor_state.json`) checks every 5 min: it relaunches dead unfinished drivers on the card with most free memory (keeping 2.5 GB free, at most 5 restarts each) and gives the workers of a finished driver to the one with most jobs left (21 workers total since 22:26 UTC, when S1 group B was boosted from 2 to 6 workers as the critical path). To change drivers by hand, stop the supervisor first and keep its state file consistent. The GPU co-tenant is the user's own `vinhnt` job (about 80 GB per card at 16:20 UTC); never touch it. Never run two drivers over the same study/regimes (the runner does not claim jobs). Drivers resume by fingerprint: restart a stopped driver with the same command; never edit locked code or inputs. New code files break the F3/Volve code-hash checks of the working tree; acceptable because P3/P4 are never rerun.
- Another project held about 125–142 GB on each H200 from about 13:00 to 16:00 UTC on 29/10 and released it by 16:06; if it returns, keep at least 2.5 GB free per card (about 1.56 GB per SMC worker, 0.7 GB per training worker).
## Next
Schedule: `docs/plan.md` §6.1 (level B, 29/10 → 14/11/2026). Cut-scope order
@@ -115,18 +121,7 @@ if late is given there; never cut thresholds.
Add the F3 and Volve dataset citations to `paper/refs.bib`. The length pass
for the venue was dropped by the user on 29/10/2026 (plan §12 item 25): do
not schedule it. The rest of these two days is buffer.
2. **T2 mechanism study (1/11), exploratory:** declare
`docs/research/t2-mechanism.md` before running. The question is now
whether any bank gain remains beyond the population correction of the
Berkson structure. Five tests, as in the Sec. 6.4 todoblock: (i)
responsibility-weighted warp error vs. mean-warp error; (ii) random GP-noise
bank control; (iii) multimodal-cell split; (iv) Berkson-vs-classical
covariance test for the bulk offset of B3d-Sa and B3c-R, which decides which
bound applies; (v) B3d-Sa retrained at the Oracle's 500 iterations. The
declaration must disclose what was already inspected post hoc on 29/10
(`outputs/p2r/posthoc/`): the Oracle/B3d-Sa and M2-Sa/B3d-Sa ratios and
every bound, (a), (b), b60 and cross-spectral, at σ_post and at the warp
error.
2. **T2 mechanism study: done on 29/10/2026** (see Status). Write the paper's Sec. 6.4 todoblock from `docs/research/t2-results.md`.
3. **protocol_bench (2–3/11):** add misspecification parameters to
`ml_porosity/data/synth_d2.py` without changing the default path (P2r must
still reproduce); dev on new realizations 902–905 only; lock
@@ -135,7 +130,7 @@ if late is given there; never cut thresholds.
misspec axes (R10, Rm5; c = 1; N ∈ {4, 16}; Oracle, B3c-R, B3d-Sa, M2-Sa),
S3 (B4 under the SMC posterior), S4 (second backbone), S8 (controlled
cycle-skip regime). Realizations 8–15 for all main cells.
4. **Runs (4–7/11)** on both GPUs, detached with `setsid nohup`, via a
4. **Runs (4–7/11)** on both GPUs, detached in tmux, via a
`scripts/run_bench.sh` driver with runlog. Report results as they come out.
5. **S7 packaging (8–10/11):** one command to generate, one to score, reference
tables, README, hashes, Zenodo deposit; then rewrite the results sections.
@@ -153,7 +148,7 @@ if late is given there; never cut thresholds.
- **Decisions:** decide from evidence and proceed. Do not block on supervisor (GVHD) sign-off.
- **Keep docs in sync (every task):** whenever you change anything (a run starts, finishes, fails or is stopped; a result, decision, deadline, protocol, script or file is added or changed), update in the same turn every file that states it: `report.html` (task status and notes, result cards, FINDS, DECISIONS, LOG), `docs/plan.md` (§0, §6 roadmap, §12 decision log), `AGENTS.md` (Status, Next), and where relevant `README.md` (scripts, run commands), `paper/README.md` (number sources), `docs/technical_overview.md` and `docs/research/*.md`. Before ending the turn, grep these files for older statements about the same item (for example "running", old counts or dates) and correct them, so no two files disagree. After editing `report.html`, check that its data block still parses (balanced brackets and quotes).
- **GPU (shared server):** choose cuda:0 or cuda:1 by free memory and load. Never touch other users' jobs. Set `OMP_NUM_THREADS`, `MKL_NUM_THREADS` and `OPENBLAS_NUM_THREADS` explicitly when running by hand (the machine default is 40).
- **Long runs:** detach multi-hour runs with `setsid nohup ... &` so they survive the agent session. Wrap runs with `scripts/runlog.sh` or the `run_p*.sh` drivers. Scripts 11/14/15 resume by skipping finished cells.
- **Long runs:** start multi-hour runs inside the user's tmux server (`tmux new-session -d -s <name> -c <repo> "<cmd> >> logs/<name>.out 2>&1"`) so they survive the agent session; on 29/10 `setsid nohup` runs were killed when the session ended. Wrap runs with `scripts/runlog.sh` or the `run_p*.sh` drivers. Scripts 11/14/15 resume by skipping finished cells.
- `code_thesis/` is the unchanged thesis-code archive (renamed from `test 2/`): do not modify its contents.
- **User constraint:** do not rerun `04_wavelet_tie.py` or
`09_fit_warp_prior_f3.py`, or overwrite their historical artifacts. P3 uses